XactCommerce Xact Objects
Home
News
XactCommerce
Typical Applications
Custom Development
Private Backend
XactScript Language
Performance
Deployment
Partners
Portfolio
About Us
leXml Language < Interface Modules & Commands < If_EmployeeBrowser

If_EmployeeBrowser
EmployeeBrowser interface provides commands to view lists of contact, employee and location records

load
Called to load a list of items into the session.
 
Optional arguments:
owner_id = Owner ID of employees to browse or 0 for all owners (default=0)
cli_id = Client ID of employees to browse or 0 for all clients (default=0)
emp_id = Employee ID if wer're just looking at one employee (default=0)
emp_status = Employee status to look for (default=all)
orderby = Valid values: name,priceasc,pricedesc,id,partno,none (default=name)
title = emp_title search field
search_text = Any text used to search in item name or descriptions
is_location = Wheather the search is for location type employee records
nomainlocations = Don't show main records (default = no)
pipelist = a pipe delimited list of emp_ids to show


resume
Resumes an existing item browse session
Optional arguments:
startat - Item counter to start at (default=-1)
Returns 'yes' or 'no' depending on whether there was a session to resume


isready
Returns 'yes' or 'no' depending on if we have any more items to view. This will also return 'no' if we've just loaded an item list but haven't called next yet!


hasnext
Returns 'yes' or 'no' depending on whether there is a next item


next
Moves to next item and returns 'yes' or 'no' like isready


getcounter
Returns and prints the item counter


templateemployeelist
This command allows a different approach to the listing of items. It loops 'itemcount' times and uses 'template' to create the HTML to list. 'template' contains HTML and can contain a series of special macros that will be replaced with specific info about the item. The item list also stops if no more items are available.
 
Here are the macros that can be included in the template:
 
##COUNT## - Replaced with a counter starting at 0
##FNAME## - Replaced with First Name of employee
##MNAME## - Replaced with Middle Name of employee
##LNAME## - Replaced with Last Name of employee
##CLI_ID## - Replaced with employee ID
##CLI_NAME## - Replaced with Client Name
##EMP_ID## - Replaced with employee main employee ID
##OWNER_ID## - Replaced with owner ID
##ADDR1## - Replaced with employee main employee address line 1
##ADDR2## - Replaced with employee main employee address line 2
##CITY## - Replaced with employee main employee city
##STATE## - Replaced with employee main employee state
##ZIP## - Replaced with employee main employee zip
##PHONE## - Replaced with employee main employee phone #
##FAX## - Replaced with employee main employee fax #
##EMAIL## - Replaced with employee main employee email
##EMP_STATUS## - Replaced with employee status
##EMP_PERM## - Replaced with the employee permission level
##PREF(count)## - (count) value found in EMP_PREFERENCES properties field
 
Arguments:
counterstartsat - ##COUNT## will start at this value (default=0)
itemcount - Number of items to display (default=10)
template - The main HTML template as described above (required)
jsescape -Wheather to jsEscape the results (default=no)
 
Returns how many employees were actually printed or "error:..." if an error occurred.


These are commands to print/get info about the current item They do nothing if we're not ready with an item in the result cursor! All of these that print something support 'prefix' and 'postfix'.


name
Prints employee name


getname
Prints employee name


cli_id
Prints and returns cli_id


totalemployeecount
Prints and returns total number of items in current cursor


remainingemployeecount
Prints and returns number of items remaining
If 'truncateto' is set, this value will be limited to 'truncateto'
(e.g. for doing 'view next ## items')