Fish are osmoregulators, which means that they regulate the water levels inside their bodies by means of a process called osmoregulation to keep the salt concentrations inside their body constant, regardless of the fluctuations of salt outside their bodies. The process differs in freshwater fish and marine fish because of the environment, I will write about the freshwater process as that is what concerns this aquarium.
Some species of fish, such as some Poecilia spp., are able to tolerate a very wide range of salt concentrations in water, all the way from fresh to marine water: these fish are called euryhaline. But most (common freshwater aquarium) fish are not able to tolerate changes in salinity: they are referred to as stenohaline.
Water hardness is made up of metal ions and carbonates, both of which form salts, so harder water contains more salts than soft water. This means that it takes more work for fish to maintain body salt concentrations in softer water and less in harder water: keeping hard water fish in soft water can affect their health as they would constantly be putting more effort than is usual into maintaining their bodily functions.
Most fish have a blood salt concentration of 9 ppt, while fresh water has a salt concentration of under 0.5 ppt, so freshwater fish tend to try to maintain salt concentrations in their blood at higher levels than the water is at, which is achieved by ion intake through food and gills and by excretion of excess water by means of a dilute urine.
Most fish are not able to instantly adapt between different water hardnesses, which is why moving a fish from one water type to another quickly can result in death or serious injury. To avoid problems, it is important to acclimatise the fish to the new water parameters over a long period of time and with only small changes in the water parameters. In theory, if the start and end water hardness, pH and temperature are same or very similar, acclimatisation can be skipped.
Long term exposure to water types the fish are not suitable for cause increased susceptibility to diseases, because of the extra work that hard water fish have to do in soft water and because many diseases do not do as well in soft water, so soft water fish are not always as able to resist them.