Hiding Vendor Menu Items

Its working!

Thank you!

I left you a private message.

A

You are welcome!

Is there a way to restrict vendors to specific export layouts for products & orders?

In other words, I setup export layouts specifically for our vendors for products & orders. Can I remove all other layout options from the screen so they cannot select a different one or customize it?

There is no easy way to do it. Code changes are required

I understand - thank you!

We’ve developed an easy to use addon tha allows you to hide selected menus, tabs and fields from Vendors.

It can also optionally modify email fields for:
+ From customer to Vendor - hide customer email/phone fields, change from/reply-to email headers to be from site
+ From Vendor to Customer - change From/Reply-to to Site email address (TBD - change Vendor’s email/phone to site’s email/phone).

Purchase site: https://ez-ms.com/ez-vendor-fields.html
Documentation: https;//ez-ms.com/docs/ez_vendor_fields.pdf
Marketplace: https://marketplace.cs-cart.com/ez-vendor-fields.html

We've developed an easy to use addon tha allows you to hide selected menus, tabs and fields from Vendors.

It can also optionally modify email fields for:
+ From customer to Vendor - hide customer email/phone fields, change from/reply-to email headers to be from site
+ From Vendor to Customer - change From/Reply-to to Site email address (TBD - change Vendor's email/phone to site's email/phone).

Purchase site: https://ez-ms.com/ez-vendor-fields.html
Documentation: https;//ez-ms.com/docs/ez_vendor_fields.pdf
Marketplace: https://marketplace.cs-cart.com/ez-vendor-fields.html

Thanks. What we need. Just purchased.

Hi can we use permission false only vendor user_id=10

app/schemas/permissions/vendor_multivendor.php

i write this but cant work

$schema['controllers']['sales_reports']['modes']['view']['permissions']['user_id'][10] = false;

Try something like

if (Tygh::$app['session']['auth']['user_id'] == 10) {
    $schema['controllers']['sales_reports']['modes']['view']['permissions'] = false;
}

I am not sure that it will work since this schema is cached

Thanks ecomlabs its work

How can we hide vendor_communication. Thanks a lot.

Go to Message center addon.

Uncheck `Vendor-to-admin communication`.

if specific vendor user_id like this i found thanks nmb
My example vendor user_id = 10
app\addons\vendor_communication\schemas\permissions\vendor_multivendor.post.php
if (Tygh::$app['session']['auth']['user_id'] == 10) {
$schema['controllers']['vendor_communication']['permissions'] = false;
}
if different way i want to hear thanks.

if specific vendor user_id like this i found thanks nmb
My example vendor user_id = 10
app\addons\vendor_communication\schemas\permissions\vendor_multivendor.post.php
if (Tygh::$app['session']['auth']['user_id'] == 10) {
$schema['controllers']['vendor_communication']['permissions'] = false;
}
if different way i want to hear thanks.

So does it work?

Anyone know how to hide "Pages" menu from vendors but not the "Blog" menu?

When I try the following code it not only hide pages but also blog menu.

$schema['controllers']['pages']['permissions'] = false; 

Anyone know how to hide "Pages" menu from vendors but not the "Blog" menu?

When I try the following code it not only hide pages but also blog menu.

$schema['controllers']['pages']['permissions'] = false; 

See https://forum.cs-cart.com/topic/50008-hiding-vendor-menu-items/?view=findpost&p=333501

Anyone know how to hide "Pages" menu from vendors but not the "Blog" menu?

When I try the following code it not only hide pages but also blog menu.

$schema['controllers']['pages']['permissions'] = false; 

Try

$schema['controllers']['pages'] = [
    'modes' => [
         'manage' => [
                   'param_permissions' => [
                        'page_type' => [
                            'B' => true,
                        ],
                        'default_permission' => false,
                    ]
        ],
    ],
    'permissions' => true
];

(!) Not tested

Hi!

I tested but it didnt worked. When I use the code it an error:

Message
Use of undefined constant permissions - assumed 'permissions' (this will throw an Error in a future version of PHP)

Error at
app/addons/my_changes/schemas/permissions/vendor_multivendor.post.php, line: 40

I thought that maybe if unset the pages firstly and after set blog it would work, but worked also.

$schema['controllers']['pages']['modes']['manage']['permissions'] = false;
$schema['controllers']['pages']['modes']['manage']['param_permissions']['page_type']['B'] = true; 

Hi!

I tested but it didnt worked. When I use the code it an error:

Message
Use of undefined constant permissions - assumed 'permissions' (this will throw an Error in a future version of PHP)

Error at
app/addons/my_changes/schemas/permissions/vendor_multivendor.post.php, line: 40

I thought that maybe if unset the pages firstly and after set blog it would work, but worked also.

$schema['controllers']['pages']['modes']['manage']['permissions'] = false;
$schema['controllers']['pages']['modes']['manage']['param_permissions']['page_type']['B'] = true; 

I made a mistake, what I would say in the last line is that the last code also didnt worked.

I have corrected the code in my post. Please try