Change product edit tab order 2
add_filter( ‘wcv_product_meta_tabs’, ‘wcv_change_product_tab_order_alphabetical’ ); function wcv_change_product_tab_order_alphabetical( $tabs ){ ksort( $tabs ); return $tabs; }Continue reading
Join 2,000,000+ Professionals who use WPCode to Future-Proof Their Websites!
add_filter( ‘wcv_product_meta_tabs’, ‘wcv_change_product_tab_order_alphabetical’ ); function wcv_change_product_tab_order_alphabetical( $tabs ){ ksort( $tabs ); return $tabs; }Continue reading
add_filter( ‘wcv_product_meta_tabs’, ‘wcv_change_product_tab_order_manual’ ); function wcv_change_product_tab_order_manual( $tabs ){ WC_Vendors::log( array_keys( $tabs ) ); $new_tabs = array(); $new_tabs[ ‘general’ ] = $tabs[ ‘general’ ]; $new_tabs[ ‘seo’ ] = $tabs[ ‘seo’ ]; $new_tabs[ ‘shipping’ ] = $tabs[ ‘shipping’ ]; $new_tabs[ ‘inventory’ ]…Continue reading
add_filter( ‘wcv_product_description_editor_settings’, ‘wcv_full_editor’ ); add_filter( ‘wcv_product_short_description_editor_settings’, ‘wcv_full_editor’ ); function wcv_full_editor( $settings ){ $settings[‘teeny’] = false; return $settings; }Continue reading
/* Lets Shop Managers edit users with these user roles */ function wcv_allow_shop_manager_role_edit_capabilities( $roles ) { $roles[] = ‘vendor’; // insert the role you want them to be able to access here, copy+paste this line for additional user roles return…Continue reading
// Add this to your themes functions.php function add_menu_item( $pages ){ $pages[] = array( ‘label’ => ‘Help’, ‘slug’ => ‘http://wcvendors.com/support’, ‘actions’ => array() ); return $pages; } add_filter( ‘wcv_pro_dashboard_urls’, ‘add_menu_item’ );Continue reading
add_filter( ‘wcv_product_ships_from’, ‘ships_from_address’ ); function ships_from_address( $field ){ global $post, $product; $shipping_disabled = wc_string_to_bool( get_option( ‘wcvendors_shipping_management_cap’, ‘no’ ) ); $post = get_post( $product->get_id() ); if ( $product->needs_shipping() && ! $shipping_disabled && WCV_Vendors::is_vendor( $post->post_author ) ) { $vendor_id = WCV_Vendors::get_vendor_from_product( $product->get_id()…Continue reading
add_filter( ‘wcv_export_orders_use_shipping_address’, ‘wcv_order_export_use_shipping_address’ ); function wcv_order_export_use_shipping_address( ){ return false;Continue reading
// Add this to your themes functions.php to change the order, rearrage the lines. First line is first item, last is last etc. add_filter( ‘wcv_dashboard_pages_nav’, ‘change_nav_order’); function change_nav_order( $pages ){ $new_nav_order = array(); $new_nav_order[‘dashboard_home’] = $pages[‘dashboard_home’]; $new_nav_order[‘order’] = $pages[‘order’]; $new_nav_order[‘product’]…Continue reading