• hunchopreneur

    (@hunchopreneur)


    Generally with Woocommerce, when using the different shipping methods, whenever the Customer has a product in their cart and adds the number of products in their cart, it can be configured for an additional charge to be made for the delivery. With WCFM distance shipping, this is not possible. I purchased the premium version thinking it will be possible with it, but it is not yet possible. Can a snippet be used to make sure this is done? I use personal contractors and if this method is not implemented, it will mean a loss on my end for every order.

    Or is it possible for a snippet to be used to even add an additional cost to any location selected by the Customer as long as they add the number of products in their cart?

    The page I need help with: [log in to see the link]

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author WC Lovers

    (@wclovers)

    What do you mean by “additional cost”?

    Distance shipping cost works as distance rules, no other costs consider here.

    Thread Starter hunchopreneur

    (@hunchopreneur)

    Does this mean there is no way it can be calculated per the number of products in the cart too?

    Additional cost according to the number of products in the cart. Let me say if a customer is buying 1 single product from Mumbai, it costs 100lakh for delivery. Also, if the customer is buying 2 products it will charge the same 100 lakh. So I was asking if there is a snippet that will add an additional shipping charge if the customer adds the number of products in their cart. That is if they are buying 2 or more products from Mumbai or any other location, that amount adds t the shipping fee.

    Plugin Author WC Lovers

    (@wclovers)

    NO, product count does not consider here.

    Thread Starter hunchopreneur

    (@hunchopreneur)

    Ok, Ok
    I need help with this snippet. I implemented it so Vendors cannot upload a product if they don’t choose an attribute. Instead, it forces vendors to select all attributes.

    add_filter( 'wcfm_product_custom_attributes', function( $taxonomy_fields, $att_taxonomy ) {
    if( isset( $taxonomy_fields[$att_taxonomy] ) && isset( $taxonomy_fields[$att_taxonomy]['options'] ) ) {
    if( isset( $taxonomy_fields[$att_taxonomy]['options']['is_active'] ) ) {
    $taxonomy_fields[$att_taxonomy]['options']['is_active']['custom_attributes'] = array( 'required' => 1, 'required_message' => 'Attributes are required' );
    }
    if( isset( $taxonomy_fields[$att_taxonomy]['options']['value'] ) ) {
    $taxonomy_fields[$att_taxonomy]['options']['value']['custom_attributes'] = array( 'required' => 1, 'required_message' => 'Attributes are required' );
    }
    }
    return $taxonomy_fields;
    }, 50, 2);
    Plugin Author WC Lovers

    (@wclovers)

    I need help with this snippet. I implemented it so Vendors cannot upload a product if they don’t choose an attribute. Instead,

    – DO you want to apply this on any particular attribute? If so, then know me “slug” for that attribute.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘!IMPORTANT. Shipping cost calculation’ is closed to new replies.