List Manager Forum

Lookup List

User sandvelder 2021-03-11 16:07:12

Hi, I need to know if the following is possible:

I want to create two lists:
1. Staff Name List
2. IT Asset List

I want to capture (import) all staff members' name to the Staff Name List, and also capture all IT Assets (computers) with their serial numbers to the second list.

Then I need to assign an asset to a staff member with a lookup field. If the staff member resigns, the asset should be reassigned to somebody else.

Is there a way I can create a field in the Staff Name List that links with the IT Asset List's serial number? I used to do this a lot back in the day when I programmed in PAL (DOS version), so I guess it should be possible, but do not know if it is an available feature in the List Manager software.

Regards,

Francois

Edited by sandvelder - 11.03.2021 16:07

Moonsoft support 2021-03-12 09:36:39

Hi,
this is not a built-in function of the extension, but you can create such a field using this configuration, here the steps:
- Go to your Asset List->Fields, and check the serial number field. Get the ID number of this field (the first, non-editable parameter you will find on top). Let's say is number 5.
- Go to your Staff List->Fields, and create a new field, type 'option list' and click 'SQL actions' button from Multivalues section.
- Insert this query at the free textarea:
select value,value from #__listmanager_values where idfield=5;

(using the proper field number from above)

Save the query and the field configuration. You should get an option list to choose that will show the serial number from the other list.

With this type of field, you would be able to configure the
Link to other table
as well, in case you want this field to link with the other table using this key field (for ex if you want to see the details of the IT Asset record assigned , this option will create a link at the cell that will show the secondary table 'assets' already filtered by this serial number). Please let us know if you need further details about this option.

Thanks, regards
Moonsoft Team

Edited by MSTeam - 12.03.2021 10:44

User sandvelder 2021-03-14 11:43:51

Thank you, but I am still battling with this. I followed the above instructions and it created a text area where I only need a text string.

Moonsoft support 2021-03-15 09:30:54

Hi,
please double check you have selected the right type for the field at your Staff Name List . It can't be a free text area if you want to link it to another table, it needs to be an 'option list', so you can configure the proper sql query and get the right values.

If following above steps you can't make it work, you can place a private ticket at the helpdesk sharing an access and we'll take a look at your configuration.

Thanks, regards
Moonsoft Team

...
Support/development 40 hours

With the peace of mind of having a professional team at your service (20% discount)

Buy now!
...
List Manager

Build different lists for your site

Buy now!