. . "to have used a controlled substance, whether or not on duty, except as allowed for medical purposes by law or regulation." . .