प्लगइनयूएस.नेट - WooCommerce और WordPress के लिए व्यावसायिक उपकरण

[अपने विचार को साकार करें - अपने सपनों को साकार करें]

समर्थन फोरम

आपको समर्थन के लिए अनुरोध (विषय) बनाने के लिए लॉग-इन करने की आवश्यकता है

Support "fixed price" for custom product types

समर्थन शनिवार और रविवार को काम करता है, इसलिए शुक्रवार के कुछ अनुरोधों का जवाब सोमवार को दिया जा सकता है। अगर आपको पंजीकरण में समस्या है तो मदद मांगें हमसे संपर्क करें पेज कृपया
यदि आपको 24 ~ 36 व्यावसायिक घंटों के भीतर ईमेल नहीं मिला है, तो सबसे पहले अपने स्पैम बॉक्स की जांच करें, और यदि वहाँ समर्थन से कोई ईमेल नहीं है - मंच पर वापस जाएं और यहां उत्तर पढ़ें। नहीं ईएमईआरएस पर जवाब [noreply@pluginus.net] फोरम से! ईमेल केवल आपकी जानकारी के लिए हैं, सभी उत्तरों को केवल यहां प्रकाशित किया जाना चाहिए।
समर्थन शनिवार और रविवार को काम नहीं करता है, इसलिए शुक्रवार को कुछ अनुरोधों का जवाब दिया जा सकता है।

I needed to add support to my custom product type, and wasn't able to do so by adding the product type in a filter, so here is my suggestion:

in the file: 'classes/fixed/fixed_price.php', in the method 'woocommerce_product_options_general_product_data'

public function woocommerce_product_options_general_product_data() {
    global $WOOCS;
    global $post;
    $_product = wc_get_product($post->ID);

    add_action('admin_footer', array($this, 'admin_footer'));
    if ($_product->is_type('simple') OR $_product->is_type('external') OR $_product->is_type('subscription') OR $_product->is_type('composite') OR $_product->is_type('bundle') OR $_product->is_type('box_product')) {
        ...
    }
}

To change to:

public function woocommerce_product_options_general_product_data() {
    global $WOOCS;
    global $post;
    $_product = wc_get_product($post->ID);
    add_action('admin_footer', array($this, 'admin_footer'));
    $product_types = apply_filters('woocs_product_fixed_price_data_simple_types', array('simple', 'external', 'subscription', 'composite', 'bundle', 'box_product'));
    if (in_array($_product->get_type(), $product_types)) {
        ...
    }
}

 

नमस्ते

सहयोग के लिए धन्यवाद!

I  will pass  it  to developers