Texture units parameters in OpenGL
Your understanding of the behavior of texture units and state is confused. That's to be expected: OpenGL's pre-DSA API is not making it easy to understand this.

As far as core profile OpenGL is concerned, the only texture unit state is what textures are bound to which targets. That's all. Therefore, all glTexParameter calls affect the state of the texture object bound to the currently active texture unit, not of the texture unit itself.

So there is no "precedence". Texture objects have state, which are modified by glTexParameter calls. This is made more clear in direct state access APIs, because glTextureParameter directly takes a texture object, rather than a bound texture target.

If you call glTexParameter when texture object 0 is bound to the given texture target, then you're setting the parameter of the default texture object for that unit/target. And you shouldn't do that.