Forum

[SOLVED] Multiple i...
 
Notifications
Retirer tout

[SOLVED] Multiple instance of personnalized list in personnalized screen

3 Posts
2 Utilisateurs
0 Reactions
1,110 Vu
jmmbb
(@jmmbb)
Posts: 561
Noble Member
Début du sujet
 
[#8954]

Hello,

In customised screens, customised lists can be used, but is it possible to use several instances of the same list in the same screen?
Example: I want to be able to define the context in which a component version can be used. I have a custom STATUS list defining the status of the component (authorised, restricted, prohibited, etc.) and I want to be able to use this information for several contexts, so I need to set up four CONTEXT 1 to 4 fields, each using the same STATUS list.
However, when defining the field, it is only possible to define idETAT as the name to refer to the custom list. idETAT1, idETAT2, etc doesn't seem to work.
Is there any way of implementing this requirement?

Best regards,


 
Posté : 27/06/2023 1:44 pm
(@babynus)
Posts: 14952
Membre Admin
 

Yes, it is possible.
If your class is Xxxx, you already used idXxxx as name for a field.
Then you can add fields names idYyyy__idXxxx when idYyyy must be different for each new field.
First id with following uppercase sets field as a list, __idXxxx defines the class used to populate the list.
Take care it requires double underscrore...
NB : this is explained in the plugin manual 
 


 
Posté : 29/06/2023 12:57 pm
jmmbb
(@jmmbb)
Posts: 561
Noble Member
Début du sujet
 

Thanks !

You're right, I forgot the RTFM (Read The F*** Manual) rule 🙂 !


 
Posté : 29/06/2023 2:04 pm
Share:
Retour en haut