Multi Vendor Marketplace Plugin | WCFM Marketplace › Forums › WCFM – Feature Request › Link to trashed products missing from Products view
Tagged: trash
- This topic has 1 reply, 1 voice, and was last updated 4 years, 7 months ago by Jitske Naberman.
- AuthorPosts
- May 29, 2020 at 4:53 pm #136529Jitske NabermanParticipant
Hi, I found there is no link on the Products view – and my vendors requested to be able to see deleted products.
This could probably be resolved by a simple addition to the wcfm-view-products.php (starting from line 10) – need to add ‘trash’ to the products menu array and in the count_products array.
$wcfmu_products_menus = apply_filters( ‘wcfmu_products_menus’, array( ‘any’ => __( ‘All’, ‘wc-frontend-manager’),
‘publish’ => __( ‘Published’, ‘wc-frontend-manager’),
‘draft’ => __( ‘Draft’, ‘wc-frontend-manager’),
‘pending’ => __( ‘Pending’, ‘wc-frontend-manager’),
‘trash’ => __( ‘Trash’, ‘wc-frontend-manager’) ) );$product_status = ! empty( $_GET[‘product_status’] ) ? sanitize_text_field( $_GET[‘product_status’] ) : ‘any’;
$current_user_id = apply_filters( ‘wcfm_current_vendor_id’, get_current_user_id() );
if( !wcfm_is_vendor() ) $current_user_id = 0;
$count_products = array();
$count_products[‘publish’] = wcfm_get_user_posts_count( $current_user_id, ‘product’, ‘publish’ );
$count_products[‘pending’] = wcfm_get_user_posts_count( $current_user_id, ‘product’, ‘pending’ );
$count_products[‘draft’] = wcfm_get_user_posts_count( $current_user_id, ‘product’, ‘draft’ );
$count_products[‘private’] = wcfm_get_user_posts_count( $current_user_id, ‘product’, ‘private’ );
$count_products[‘trash’] = wcfm_get_user_posts_count( $current_user_id, ‘product’, ‘trash’ );
$count_products = apply_filters( ‘wcfmu_products_menus_count’, $count_products, $current_user_id ); - May 29, 2020 at 4:56 pm #136531Jitske NabermanParticipant
… additionally, I’m getting the same request for Reviews – here the vendors also want to be able to view the trash folder.
- AuthorPosts
- You must be logged in to reply to this topic.