I bought a used Hayward AquaRite controller and new T-15 SWG cell. I recently added a big Hayward filter and Pentair Superflo VS pump. The previous homeowner had the original single speed pump connected via wall plug and a Christmas lights extension cord. I did the same temporarily until I figure out a better up to code setup. Today the extension cord was hot and smelled like melted plastic when running the pump at 2500 rpm (not good I know). The 10 year old Summit R-22 heat pump is hooked to 240V correctly with outdoor conduit and a fuse box outside by the GFCI outlet. The piping is an 1.5 inch ABS/PVC mess, and I am slowly replacing it with all 1.5 PVC where appropriate (so far from pump through filter). The SWG will be downstream from the heat pump with a check valve to protect the heatpump heat exchanger. The home's low voltage landscape lights transformer is also plugged into the GFCI outlet behind my pool equipment shed so I need to move it inside or keep the plug outside. I know the pump power config must not be up to code. Pump and heatpump are bonded correctly.
Here is the waterproof outlet enclosure and GFCI outlet powering the pump and lights:

Here is the new filter and VS pump and green extension cord to the pump:

Heat pump:

I think I need to put a digital timer on my SWG so it stays on schedule if power is interrupted. I think the Superflo VS pump keeps time/schedule up to 24hrs if power is interrupted. Any advice on getting the electrical sorted out and up to code and SWG installed correctly?
Here is the waterproof outlet enclosure and GFCI outlet powering the pump and lights:

Here is the new filter and VS pump and green extension cord to the pump:

Heat pump:

I think I need to put a digital timer on my SWG so it stays on schedule if power is interrupted. I think the Superflo VS pump keeps time/schedule up to 24hrs if power is interrupted. Any advice on getting the electrical sorted out and up to code and SWG installed correctly?