A federal judge ruled this week that Los Angeles Police Department officers should be paid for the time it takes them to put on and take off their uniforms and safety equipment, a decision that could cost the city millions of dollars in back pay and higher salaries.