First off, it isn't the OPs fault. Rainbowfish all around the world die from Fish TB and it's caused by TB coming out of Asian fish farms, and because rainbowfish were never exposed to it. Rainbowfish have only been around for about 10,000 years and Fish TB (Mycobacteria species) have been around since the dawn of time. They are really old species of bacteria that have evolved ways of avoiding the immune system and surviving in places most other bacteria die. They produce a waxy coating around their cell and this protects them from the elements, medications, and the body's immune system.
Mycobacteria have been in European, Asian, African and American waterways for hundreds of millions of years. The fish in those areas have evolved alongside the Mycobacteria and even though they still catch it, they don't die as quickly from it. Because rainbowfish have never evolved with it (Fish TB is not found in wild fish in Australia or New Guinea), they have no way of dealing with it. So when rainbowfish are kept in aquariums with barbs, tetras, gouramis, etc, they pick up these new diseases and die from them. Many rainbowfish breeders also have the disease in their tanks and don't always know, and they spread the disease with fish they sell.
-------------------
Dumping used aquarium water on the lawn or garden is fine but do not use it on fruit/ vegetables or plants you eat. Avoid getting it on things like green leafy veges, tomatoes, capsicum, carrots, etc. You can use the water on any sort of plant just don't get it on the parts you plan on eating. I used to water my lawn with water from the tank.
Mycobacteria can live for months or even years in the soil so just because it's in full sunlight for a few days, doesn't mean it's dead. A fish health vet I was working with back around the start of this century had found Fish TB under rocks in dry river beds and they had been dry for 8 years. So this genus of bacteria is incredibly tough.
Mycobacteria are also responsible for TB in birds, reptiles and mammals. People get a number of types including lung TB, leprosy and there is a white tail spider that has a species of Mycobacteria on its fangs, and when it bites you, you get a flesh eating bacteria dissolving the tissue around the bite site.
-------------------
The fact the fish was still eating even though it was bloated up, would suggest it is something else, probably food poisoning caused by something bad it ate, or if it was Fish TB, it didn't do as much damage to the organ it was growing in. However, any fish that is bloated up, has scales sticking out, and is breathing heavily/ rapidly, should be euthanised because the fish is in pain and is probably going to die shortly.
At this stage, just let the tank run. Do regular water changes and gravel cleaning. Clean the filter each month. Feed the fish lots of plant matter. Avoid frozen bloodworms. If more fish start to die from the same symptoms, get them necropsied by a fish vet and find out what the actual cause is. If it does turn out to be Fish TB, you either let the tank run until most or all of the fish die, and then disinfect and start again. Or you euthanise the lot now and disinfect before starting again. But if you euthanise now, you could buy new fish next week and they could have it too.
Adrian Tappin used to breed his fish when they had TB and transfer the eggs to clean containers with clean water. Then as soon as they hatched, he scooped the baby fish out and move them to a clean container with clean water. Apparently he managed to get clean stock by doing that and when he had sufficient numbers of clean fish, he destroyed the old infected fish, disinfected the tank and started again.