The first amendment doesn't apply to my employer as I work for a private company, so you are right there. But is that true for cops who work for the government? I'm honestly not sure.
However, the police unions would never allow such a thing.
Second, I suspect that a majority of the officers in question were not on the job while attending that funeral.
And the fact that my employer can't have me beaten up has nothing to do with the 1st amendment. That would be assault no matter what their motivation.