In any action or proceeding brought in the housing part of the New York city civil court, the court, on motion of any party or on its own motion, may issue such preliminary, temporary or final orders requiring the owner of property or other responsible person to abate or correct violations of this code, or to comply with an order or notice of the department, or to take such other steps as the court may deem necessary to assure continuing compliance with the requirements of this code, including direction of correction of violations of this code by a contractor, materialman or municipal department and payment of rent or release of funds deposited with the court in an appropriate amount to (i) such contractor or materialman upon the proper presentation of bills for the correction of such conditions or (ii) such municipal department.