Page History
...
The source example below shows a server routine that builds a list of all the employees in the table xEmployee, as well as the thumbnail image, then returns the complete list to the calling Web Page or Reusable Part. Data is sent in JSON format and converted to the corresponding LANSA fields and lists automatically on the Client end.
Def_list Name(#employees) Fields(#xEmployeeIdentification #xEmployeeSurname #xEmployeeGivenNames #xEmployeeImageThumbnail …) Type(*working)
SrvRoutine Name(GetEmployees)
List_Map For(*Output) List(#Employees)
* Get all employee data
Select Fields(#Employees) From_File(xEmployee)
...
Fetch Fields(#Employees) From_File(xEmployeeImages) With_key(#xEmployeeIdentification)
Add_Entry To_List(#Employees)
Endselect
Endroutine