Viewing 9 replies - 1 through 9 (of 9 total)
  • Plugin Author Varun Sridharan

    (@varunms)

    Hi, @DizzYa

    Thanks for pointing out the issue..

    Can you please download our WC RBP 3.0 Beta version and check ?

    it can be downloaded from https://github.com/technofreaky/woocommerce-role-based-price

    Please note: kindly update the settings once installed

    Thread Starter DiZzYZA

    (@dizzyza)

    Thanks for your response Varun

    Updating to the new beta version didn’t solve it unfortunately. If i manually run the import it works 100% but if it runs with cron it doesn’t update at all and actually removes the prices set from the manual import.

    here is an image of the fields i’ve saved Screenshot

    If there is any other information i can provide you to help diagnose please let me know

    Thread Starter DiZzYZA

    (@dizzyza)

    Any suggestions on this ?

    Plugin Contributor Arnis Arbidans

    (@arnisarbidans)

    @dizzyza

    We are trying to figure out solution for for cron updates. Are you using ACF -Advanced Custom Field plugin with WP-All-Import as well? If yes then, do you have the same problem with it or just RBP prices?

    Do you use the same file for cron update and manual update? I had problem before with file generated with wrong encoding causing error in custom price column name.

    Best regards,
    Arnis

    Thread Starter DiZzYZA

    (@dizzyza)

    Hey Arnis Arbidans

    I am not using ACF with WP AllImport, and i also use the same file for manual and cron update.

    I’ve also tried with all plugins disabled and only woocommerce, role based price and wp_allimport activate.

    Like i said previously, if i run it manually it goes through perfectly. But the moment the exact same process runs as cron it strips all the pricing out of RBP.

    Can i provide any other info ?

    Plugin Author Varun Sridharan

    (@varunms)

    Right now our plugin dose not support CronJob.

    Hello, I am facing the exact same problem with CRON executing the import, will it be fixed in version 3.0? Or is there any other solution? Otherwise it is a great plugin.

    Thank you,
    Filip

    any solution for that?

    please help

    I solved it, but you gotta know a bit of PHP to make it work.

    step #1. I created a function and placed it in my functions.php file:

    function my_prices($p1,$p2,$p3,$p4){
    $result = [];
    $result[‘cliente1’] = array (‘regular_price’ => $p1,’selling_price’ => ”);
    $result[‘cliente2’] = array (‘regular_price’ => $p2,’selling_price’ => ”);
    $result[‘cliente3’] = array (‘regular_price’ => $p3,’selling_price’ => ”);
    $result[‘cliente4’] = array (‘regular_price’ => $p4,’selling_price’ => ”);

    $x = serialize($result);
    return $x;
    }

    (You gotta replace cliente1, cliente2 etc.. with the name of the user roles.)

    Step #2 You have to add the custom field “_role_based_price” and on the value add the function like this:

    [my_prices({price1[1]},{price2[1]},{price3[1]},{price4[1]})]

    This way the field (prices) will always be updated regardless of a cron or manually. Any questions, Im free to help. I tried to solve this without programming but couldnt find a way.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Role based price not updating with cron job from wp all import’ is closed to new replies.