VirtueMart Forum

VirtueMart 2 + 3 + 4 => Virtuemart Development and bug reports => Topic started by: Metabern1 on July 24, 2018, 16:54:10 PM

Title: Want to add custom fields only visible to specific user
Post by: Metabern1 on July 24, 2018, 16:54:10 PM
Client's company sells products to their customers who have their own part numbers for those products.

I want to be able to add customers' part numbers and show them in VM detail page only when specific customer is logged in.

Any ideas on how I could do this?
Title: Re: Want to add custom fields only visible to specific user
Post by: GJC Web Design on July 24, 2018, 18:11:53 PM
how many customers are u talking about?

It is going to have to be something like detect the user id and display the custom field that matches by "some factor"

e.g. custom field title and layout position same as the userid

then in the template

if userid== custom field layout position-> display
Title: Re: Want to add custom fields only visible to specific user
Post by: Studio 42 on July 25, 2018, 15:03:53 PM
https://shop.st42.fr/en/shorcodes-english-doc#specification can display customfields by user groups, but i think what you need is specific to each user and not shopper group ?