You are mixing two things:
1- Voting in the assembly.
2- Declaration of defection.
According to the law, the voting of the member in the assembly is to be done according to the directions of the parliamentary party. This is the parliamentary head.
Now, if the member does not vote according to the parliamentary head, then the parliamentary head can write to the 'party' head and then the 'party' head declare him defected.
So, to declare someone as defected, the 'party' head is the authorized person.
But how will he declare someone defected? Only when he goes against the 'parliamentary' party.
I quoted the relevant sentence in the above quoted post. The bold part says 'declaration', which of defection.
Aitzaz Ahsan was on TV (ARY) and he explained the 'wisdom of the law'. In this case, the reason both steps are given to two different people is because in an ideal democracy, the party head looks over ALOT of affairs across the board, while the parliamentary party is more suited for deciding upon affairs within the assembly. So that is why, the parliamentary party should decide what to vote for within the assembly. The reason the declaration for defection is in the hands of the 'party' head is because the party head can take note of all the affairs which led to a member not voting according to the direction given. He may have COVID, or a broken leg, or in hospital, or whatever. There can be any compulsion that he couldn't vote, and the parliamentary leader cannot be made aware of those circumstances because he looks over parliamentary affairs, not those outside.
Hope you understand.