This is a typical Flood & Drain System using the Toilet Cistern with a feeder tank to flood the growth bed. Flush & Drain is more politically correct.
Diagram above showing the typical components involved. Water are fed to the Feeder tank by a pump from the fish tank.
As the water rises filing the feeder tank, there is a leak tube, that will overflow water from the feeder tank to the PET bottle, causing it to become heavier and finally pull the string that will open the toilet cistern and hence flushing the water out to the growth bed.
Water from the growth bed will be drain via a drain hole back to the fish tank
Once the Feeder tank emptied, the flushing stop just like the normal toilet do. Water in the PET bottle will drain out the drip hole causing the bottle to loose weight and reset the cistern waiting for the cycle to repeat.
This system works, however its rely on toilet cistern that may fail just like our normal toilet do, with repeated use the reliability of this system yet to be seen.
This setup was demonstrated on a Barrelponics System