Display SKU to vendors only! How? NC 4.40

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
2 years ago
NC 4.40

How to display SKU to vendors only? Using .chhtml files.

And to all other users show smth like this instead "You must login to see SKU".

Please, help!
2 years ago
Have a look at Views\Product\_SKU_Man_GTIN_Ven.cshtml
There is check for displaying the SKU

You would need to inject the code for customerSerivce to check the current customer is a Vendor
You can use the routine in
_customerService.IsVendorAsync(customer)

If the customer is a Vendor then dispay the SKU
2 years ago
Yidna wrote:
Have a look at Views\Product\_SKU_Man_GTIN_Ven.cshtml
There is check for displaying the SKU

You would need to inject the code for customerSerivce to check the current customer is a Vendor
You can use the routine in
_customerService.IsVendorAsync(customer)

If the customer is a Vendor then dispay the SKU


Can you please write the piece of code for .cshtml? How to do it?
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.