• Hello

    I save the status transitions of orders in the postmeta table like this:
    meta_key: order_transitioned_from_{status1}_to_{status2}
    meta_value: {date of transition change: YYYY-MM-DD}

    Now I would like to export all orders that changed from status1 to status2 (these statuses will be fix) in a specific time frame selected on the date range selector.

    I tried to use the filter: woe_get_order_ids
    But my problems are:
    1) If I select a date range, then obviously only products will be shown that were created in this date range, but I could have an order that was created before that range but changed its status in that range, thus would be ignored.
    2) I tried to use the filter ‘woe_get_order_ids’ and just replace the ids with the ids that I need by using a custom sql code that returns those IDs, but then I dont have access to the date range that was selected?

    I would really appreciate help ??

    If its needed: I have the pro version

    kind regards
    moe

Viewing 1 replies (of 1 total)
  • Plugin Author algol.plus

    (@algolplus)

    hi Moe

    2. you can modify custom SQL
    use these variables
    WC_Order_Export_Engine::$current_job_settings[‘from_date’]
    WC_Order_Export_Engine::$current_job_settings[‘to_date’]

    thanks, Alex

Viewing 1 replies (of 1 total)
  • The topic ‘filter by custom meta data’ is closed to new replies.