A hydraulic circuit consists of a water through the pipe. The flow is created and maintained by supplying mechanical energy with the pump.
The water particles at the highest potential ‘A’ flow through the pipe and lose their potential energy to overcome the friction in the pipe.
Thus the water goes back to the lowest potential level-B.
Electric circuit
The electric circuit consists of a follow of charges or electric current through the wire. The current is created and maintained by supplying the electrical energy with the battery.
The charges at –B at are at the lowest or zero potential (negative potential).
The battery supplies electric energy or does the work to the charges. So the charges gain the potential energy and reach the highest (positive potential) at level –A.
Then the charges travel from the higher potential at ‘A’ to the lower potential ‘B’ through the wire and do the work of overcoming the electric friction i.e resistance . in doing so, they lose their potential or energy and come back to the zero potential at ‘B’.