• Resolved bdtq

    (@bdtq)


    Hi, how can i turn off image auto update form woocommerce to ebay. I want to custom my product image on ebay by my self.
    Thank you for great plugin.

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Support WP Lab Support

    (@wp-lab-support)

    Hello @bdtq.

    I am happy to help you today and thank you for the kind words.

    Unfortunately at this time that is not possible – the main WC image will be sent as the main image on eBay. We do have an add on plugin (beta) that is available for our users to try out. This add on plugin will allow you to provide a custom image in the eBay listing. If you’d like to try it out you will need to open a support ticket so I can email it to you.

    Kind regards,
    John

    Thread Starter bdtq

    (@bdtq)

    One more question. Can i set ebay price as formula? i want to edit the price like this: (ebayPrice = regularPrice * 10 + 5). is there any code to add in file function.php. Thanks for quick response.

    • This reply was modified 6 years, 9 months ago by bdtq.
    Plugin Support msantamaria

    (@msantamaria)

    Hi @bdtq

    Please try this code:

    // Customize the eBay price
    add_filter( 'wplister_filter_listing_item', 'wple_custom_ebay_price', 10, 4 );
    function wple_custom_ebay_price( $item, $listing, $profile, $post_id ) {
        $product = wc_get_product( $post_id );
    
        $custom_price = $product->get_price() * 10 + 5;
        
        // Set custom start price
        $item->StartPrice = new AmountType();
        $item->StartPrice->setTypeValue( self::dbSafeFloatval( $custom_price ) );
        $item->StartPrice->setTypeAttribute('currencyID', $profile['currency'] );
    
        return $item;
    }

    Then just please set your formula.

    Kind regards,

    Menchie
    WP Lab Support

    • This reply was modified 6 years, 9 months ago by msantamaria.
    Thread Starter bdtq

    (@bdtq)

    Thank you very much, the add-on worked very well, i love it.
    The code you give me have an error ( Cannot use “self” when no class scope is active) on line:
    $item->StartPrice->setTypeValue( self::dbSafeFloatval( $custom_price ) );
    I hope in the next version we can set the price rule directly on “Edit product” page.

    Plugin Support msantamaria

    (@msantamaria)

    Hi @bdtq,

    This code should fix that up:

    // Customize the eBay price
    add_filter( 'wplister_filter_listing_item', 'wple_custom_ebay_price', 10, 4 );
    function wple_custom_ebay_price( $item, $listing, $profile, $post_id ) {
        $product = wc_get_product( $post_id );
    
        $custom_price = $product->get_price() * 10 + 5;
        
        // Set custom start price
        $item->StartPrice = new AmountType();
        $item->StartPrice->setTypeValue( ItemBuilderModel::dbSafeFloatval( $custom_price ) );
        $item->StartPrice->setTypeAttribute('currencyID', $profile['currency'] );
    
        return $item;
    }

    Kind regards,

    Menchie
    WP Lab Support

    Thread Starter bdtq

    (@bdtq)

    The code not working, but it’s ok with me. Thank you for your help

    Plugin Support msantamaria

    (@msantamaria)

    Hi @bdtq,

    You’re welcome! ??

    We can help you make the code work but I’d recommend you to please send us support ticket here – https://www.wplab.com/request-support/ and we can continue to resolve it there.

    Kind regards,

    Menchie
    WP Lab

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Turn off image auto update’ is closed to new replies.