This chapter applies to and is the exclusive remedy to regulate and determine rights, obligations, and remedies under a rental agreement, wherever made, for a dwelling unit located within this state. No resolution or ordinance relative to residential landlords, rental housing codes, or the rights and obligations governing residential landlord and tenant relationships shall be enacted or enforced by any county or municipality, and any such resolution or ordinance enacted both prior to or after January 1, 2007, is superseded by this chapter. Notwithstanding these provisions, a county or municipality may enact and enforce building codes, health codes, and other general laws that affect rental property provided that such codes equally affect similarly situated owner-occupied residential property.