Before any city of the second class or village shall make any contract with any person or corporation within or without such city or village for the furnishing of electricity, power, steam, or other product to such city or village, or any such municipal plant within such city or village, the question shall be submitted to the electors voting at any regular or special election upon the proposition. Such city of the second class or village may, by a majority vote at such election, vote bonds or taxes for the purpose of defraying the cost of such transmission line and connection with any person, firm, corporation, or other city or village with which it may enter into a contract for the purchasing of electricity, power, steam, or other product. The question of issuing bonds for any of the purposes provided in this section shall be submitted to the electors at an election held for that purpose, after not less than twenty days' notice thereof shall have been given by publication in a legal newspaper in or of general circulation in such municipality. Such bonds may be issued only when a majority of the electors voting on the question favor their issuance. Such bonds shall bear interest, payable annually or semiannually, and shall be payable any time the municipality may determine at the time of their issuance, but in not more than twenty years after their issuance. The city council or village board of trustees shall levy annually a sufficient tax to maintain, operate, and extend any system or plant and to provide for the payment of the interest on, and the principal of, any bonds that may have been issued as provided in this section. If no tax or issuance of bonds is required, any city of the second class or village may by resolution of the city council or village board of trustees contract for the furnishing of electricity at retail to such city or village, or to any electric plant within such city or village, with any public power district, or an electric cooperative which cooperative has an approved retail service area adjoining such city or village.