• Resolved yajuvendra1990

    (@yajuvendra1990)


    Hi,

    How to user become a vendor in BuddyBoss theme where BuddyPress and WooCommerce activated. Please let me know any suggestion or Idea.

    1. Can we merge Dokan registration form with buddyboss registration form by using any of the available hooks.
    2. Can an existing user become a Vendor? Like clicked on button or filled another resignation form. Are there any hooks available?

    I have tried to assign vendor capabilities to a user role(subscriber) but not working. My code are given below

    $Dokan_capabilities = array(
    	'read',
    	'publish_posts',
    	'edit_posts',
    	'delete_published_posts',
    	'edit_published_posts',
    	'delete_posts',
    	'manage_categories',
    	'moderate_comments',
    	'unfiltered_html',
    	'upload_files',
    	'edit_shop_orders',
    	'edit_product',
    	'read_product',
    	'delete_product',
    	'edit_products',
    	'publish_products',
    	'read_private_products',
    	'delete_products',
    	'delete_products',
    	'delete_private_products',
    	'delete_published_products',
    	'delete_published_products',
    	'edit_private_products',
    	'edit_published_products',
    	'manage_product_terms',
    	'delete_product_terms',
    	'assign_product_terms',
    	'dokandar'
    );
    
    $role = get_role( 'subscriber' );
    
    foreach( $Dokan_capabilities as $cap ) {
            $role->add_cap( $cap );
    }

    Thanks

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