There well be a fine mesh at the bottom of the chamber (in the cistern tank) that fills up with water and has the ball cock arm attached, the mesh will probably be split, hence why it's not filling, going straight down the pan. You can either do a DIY job for virtually next to nothing, take about tops an hour, by the time you have drained the tank etc to fix it, or pay someone in the region of nigh on a 100 notes to have the job done properly, and less hassle.