Attribute: No Secondary Ammo From Dispenser While Active - nosoop/SM-TFCustomWeaponAttributes GitHub Wiki
Sheesh, that's a mouthful.
Does what it says on the tin. If the attribute this weapon is applied to is active, then your secondary weapon's ammo will not change via dispensers.
Plugin name: custom-weapon-soup
Attributes:
no secondary ammo from dispensers while active
: any value to enable