Developer forum

Forum » Development » Order.SecondaryUserName cannot be assigned to

Order.SecondaryUserName cannot be assigned to

Martin Grønbekk Moen
Martin Grønbekk Moen
Reply

The documentation for this says it can do both get and set, but only get is implemented.
This mean that when the order is created it do not show the secondary username in admin (see image).

Please consider to change this to get and set.

2019-06-30_00_05_20-Dynamicweb_Admin.png

Replies

 
Nicolai Pedersen
Reply

Hi Martin

You can set the user using the SecondaryUserId property.

I've updated the documenation to not say it can use set.

Sorry about the confusion!

BR Nicolai

 
Martin Grønbekk Moen
Martin Grønbekk Moen
Reply

Ok, thanks!
The problem with this is that the name of the secondary user is not shown in admin. If you look at my image I have set the SecondaryUserId and the link to the user is correct, but it only show a icon of an user, and not the user name. Would be good if the admin show the correct user name.

 
Nicolai Pedersen
Reply

It will not show the username but the name of the user.

 
Martin Grønbekk Moen
Martin Grønbekk Moen
Reply

Okay? Strange, because in this case the name of the secondary user is filled out, so it should have been visible.
Created by user - now show the username, not the name of the logged in user.
On behalf of - now show blank, because I have not set username on my secondary user.

If I add username to secondary user, it show the username. So it is evident that both fields show the username not the user name (name of the user).
We use DW 9.6.6 btw.

 
Nicolai Pedersen
Reply

Hi Martin

The code looks like the attached. But it could very well be a UI error. I'll have it checked.

BR Nicolai

Capture.PNG

 

You must be logged in to post in the forum