Impossible to set commission to 0

WCMp Vendor Membership

Impossible to set commission to 0 Resolved

Viewing 7 reply threads
  • Author
    Posts
    • #109911
      Gregory
      Participant

      Hello,

      how can i set commission to zero for specifi plans ?

      if i set % or fixed amount at 0, it didn’t save the value and still use normal commission.
      if i set % to 0,0 it save, but it give 10% to vendor and 90% for me o_O

    • #109913
      Gregory
      Participant

      what is strange, is that if i set to 0

      i don’t understand, it says commission 0
      perhaps, total earned is also 0 ?

    • #109958
      abhirup
      Moderator

      Hi,
      By default if membership commission is 0, then it can not show on membership plan you have to put a positive integer value( not 0 ) otherwise the commission will calculate as global commission.

      If you want to change the default flow then you have to code for your end.

      Regards,

    • #110001
      Gregory
      Participant

      So, i don’t understand, how do i set commission to 0 for a specific membership ?

    • #110030
      abhirup
      Moderator

      Hi,
      As per our default flow you can not save 0 as a commission as this is a null value. You have to set commission 1 or any positive value.
      If you change the default flow you have to add some custom code for your end.
      Let me know if you need hooks and filter.

      Regards,

    • #110130
      Gregory
      Participant

      Yes, i really need an option to have some comission set to “no commission”.
      i asked this to your support chat before i order the plugin addons, and he says me : “yes, if you have member subscription, it’s possible”.
      So whatever the way to do it, even with an option “no commission” or setting to “0”, i need it to work.

    • #110200
      abhirup
      Moderator

      Hi,
      as per your requirement you can use below code and add your custom code into the function.
      Please add this code in the function.php of the current active theme and add custom code as per your requirement.

      add_action('init', 'wcmp_custom_commission_membership');
      function wcmp_custom_commission_membership(){
          global $WCMP_Vendor_Membership;
          remove_filter('wcmp_get_commission_amount', array($WCMP_Vendor_Membership, 'wcmp_vendor_membership_get_commission_amount'), 10, 6);
      
          add_filter('wcmp_get_commission_amount', 'wcmp_vendor_membership_get_commission_amount', 10, 6);
      }
      
      function wcmp_vendor_membership_get_commission_amount($commission, $product_id, $vendor_id, $variation_id, $item_id, $order) {
             // your custom code here
          return $commission;
      }
      Copy

      Please check wcmp-vendor_membership/classes/class-wcmp-vendor-membership.php line no 144 to 262 to understand the commission flow.

      Regards,

    • #114018

      We have not received any update from you for a long. Hope this ticket is already been resolved.

      We are now closing this ticket. Kindly create a new one if you need any further help.

Viewing 7 reply threads

The topic ‘Impossible to set commission to 0’ is closed to new replies.

Buy all Marketplace addons together, check out our Bundle

Buy at Slashed Price