Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Support Fitri Sinta

    (@supportfitri)

    Hi @eftcolumbus,

    Thanks for contacting us.

    I have submitted this as a feature request to show the product quantity in a separate column. However, I cannot guarantee that this will be included in future updates, nor can I provide an official ETA for when it might be implemented.

    We appreciate your patience and will inform you if there are any updates.

    Best regards,

    Thread Starter eftcolumbus

    (@eftcolumbus)

    Hi Fitri, thank you for checking. So for now I cannot upgrade my live site to the latest version of WC Vendor because the reports are not useful if the vendor cannot use it to import orders into his own system as is.

    For previous versions of WC Vendor, on the Orders tab, quantity and title are separate columns I double checked. I’m not sure why they decided to combine the columns and add an x for this release?

    In the meantime, you were very helpful with code for showing only certain order statuses, can you give me any suggestions for hooks or filters to use to accomplish this as a snippet? I tried to have Claude.ai write it but it wasn’t successful, mostly gave me critical errors lol. When you gave me the code snippet for statuses, I shared that with claude and it was able to use the logic to provide me another modification to the Vendor dashboard (hide the settings tab). So I’m hoping if you can point me in the right direction, he can help me.

    Also, for above snippet, I personally don’t even need a quantity column because people only ever order one of my items, so if the code accomplished just not having the “1 x” appended to the beginning of the column and the product title literally just included the product title, that would work for me. I just suggested a separate quantity because I know your other customers probably would want that and if you are updating it, it should work for everyone. But for snippet purposes if it just deleted the “1 x” from the output that would work for me.

    Thank you!

    Plugin Support Fitri Sinta

    (@supportfitri)

    Hi @eftcolumbus,

    Thanks for the reply.

    I have raised the issue to show the product quantity in a separate column to our development team. In the meantime, you can remove the product quantity from the exported orders CSV file by adding the PHP code snippet below to your child theme’s functions.php file or via a code snippet plugin:

    add_filter( 'wcv_order_export_csv_rows', 'wcv_order_export_csv_rows_1', 10, 2 );

    /**
    * Remove the product quantity in the CSV export.
    *
    * @param array $rows Array of rows.
    * @param array $orders Array of orders.
    */
    function wcv_order_export_csv_rows_1( $rows, $orders ) {

    if ( empty( $orders ) ) {
    return $rows;
    }

    foreach ( $rows as &$row ) {
    // Fetch the order using the order_number from the row.
    $row_order = wc_get_order( $row['order_number'] );

    if ( ! $row_order ) {
    continue; // Skip if the order couldn't be retrieved.
    }

    // Initialize products string.
    $products = '';

    // Fetch the order items from the WC_Order object.
    $vendor_order_items = $row_order->get_items();

    foreach ( $vendor_order_items as $item_id => $item ) {
    // Get the product name for each order item.
    $item_name = $item->get_name();
    $products .= $item_name . '\n'; // Add product name to the products list.
    }

    // Add the products list to the row data.
    $row['products'] = $products;
    }

    unset( $row );

    return $rows;
    }

    I hope this helps, let me know how it goes.

    Best regards,

    Thread Starter eftcolumbus

    (@eftcolumbus)

    Hi Fitri, thank you for that code. I just tested but it didn’t change things for me. I can confirm that I copied the entire code and that the snippet is activated. When I did a test download it still showed

    1 x Test Pkg A

    In the Product Title column.

    It looks like it wasn’t meant to change the table on the Orders screen in the dashboard, and it did not, the Orders screen also says 1 x Test Pkg A. I wonder if it has to be changed on the Dashboard first?

    Any other ideas?

    Thank you.

    Plugin Support Fitri Sinta

    (@supportfitri)

    Hi @eftcolumbus, the PHP code snippet removes the product quantity from the “Product Title” column on the exported orders CSV file as seen on the screenshot below. However, it doesn’t remove the product quantity shown on the Orders screen in the dashboard.

    Thread Starter eftcolumbus

    (@eftcolumbus)

    Yes, I understood that it was for download only. I can re-confirm that as mentioned, I just did another test DOWNLOAD with snippet activated and it still showed, in the Product Title column of the CSV:

    1 x Test Pkg A

    Same as my previous screenshot. And yes dashboard is not affected as expected.

    I am in version WCV 2.5.3 and have Woocommerce version 9.5.1 (most recent as of writing this).

    I confirmed I have no other WCV related snippets running and that in my child-theme files there is nothing that affects WCV.

    Why do you think it’s working for you and not for me?

    Plugin Support Fitri Sinta

    (@supportfitri)

    Hi @eftcolumbus,

    Sorry to hear that! It seems there could be some conflicting plugins or themes on your site. If you’d like, you can invite us as an admin via our email at [email protected], and we’d be happy to take a look.

    Let me know if you’re OK with us doing some basic troubleshooting such as turning plugins on and off to see if there are any conflicts, changing minor settings temporarily, creating temporary users, etc.

    If the answer to this is no, then ideally we’ll need access to a staging site where we can narrow down and debug the issue without disturbing your live site.

    Also, have you recently done a full backup of the site? If not, do so now. I’m happy to recommend backup solutions if needed.

    Thanks in advance! Looking forward to helping you get to the bottom of this!

    Best regards,

    Plugin Support Fitri Sinta

    (@supportfitri)

    Hi @eftcolumbus,

    We’ll close this ticket as we haven’t heard from you again in a while. If you’re still having any problems with the code snippet, please send an email directly to support [at] wcvendors.com.

Viewing 8 replies - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.