If a pharmacy is not, for whatever reason, a *full service* pharmacy, they should post that fact where it can be clearly seen before entering the store -- and the location of the nearest one that is.
The only acceptable grounds for keeping an unfilled prescription, so far as I can see, is if there are reasons to believe that it is fraudulent. In which case, the cops should be called and either the customer charged (if warranted) or the prescription returned. (Too many false alarms, and the cops may begin to consider charging the pharmacist....)
I don't think pharmacists can be required to dispense everything to everyone, but I see nothing wrong with having them bear a very visible cost of choosing not to do so.