Supported Server Operations

This article contains the following topics:
casm1401
This article contains the following topics:
The following operations are supported to let you integrate the CA SDM web pages with your web pages:
  • CREATE_NEW
    Provides a generic interface to let the user create a row in a specified table. The object name must be specified, and by default a template named
    detail_xxx
    _edit.htmpl is used for object
    xxx
    . You can override the .htmpl file by specifying the HTMPL property.
    • Required specifiers:
      FACTORY=
      object
      -
      name
    • Optional specifiers:
      ALG_PRESET
      =preset_expression
      ALG_PRESET_REL=preset_expression
      CREATE_ALG=
      activity_log_type
      HTMPL=zdetailxxx_
      factory
      .htmplKEEP
      .attr_name=value
      PRESET=
      preset_expression
      PRESET_REL=
      preset expression
      SET
      .attr_name=value
      use_template=1 | 0 (0 is the default)
    To use the HTMPL specifier with CREATE_NEW, the referenced form must have a name conforming to the naming convention zdetailxxx_
    factory
    .htmpl. The name must begin with the string zdetail, followed by any alphanumeric characters (including a null string), followed by an underscore and the factory name.
  • ENDSESSION or LOGOUT
    Ends the current logged-in session. ENDSESSION is the preferred operation.
  • GENERIC_LIST
    Provides a generic interface to allow the user to display a list from any table in the database. The object name must be specified, and by default a template named list_
    xxx
    .htmpl is used for object
    xxx
    . You can override the .htmpl file by specifying the HTMPL property.
    • Required specifiers:
      FACTORY=
      object
      -
      name
      KEEP
      .attr_name=value
  • DISPLAY_FORM
    Provides a generic interface to let the user display any customized form.
    • Required specifiers:
      HTMPL=
      htmpl_file
    DISPLAY_FORM replaces JUST_GRONK_IT. Existing implementations can continue to use JUST_GRONK_IT, which functions exactly like DISPLAY_FORM. DISPLAY_FORM is the preferred operation.
  • MENU
    Displays the main menu page, which is defined in the web.cfg file in the Menu property.
    • Optional specifiers:
      HTMPL=
      menufile
      menufile
      is the name of an alternate main menu file.
  • PAGE_EXTENSION
    Allows the webmaster to specify additional extensions to the interface.
    • Required specifiers:
      NAME=
      html_file
      html_file
      is one of the file names listed in the configuration file UserPageExtensions directive.
    • Optional specifiers:
      REQUIRES_LOGIN=1
      If present, a login page appears first if the user is not currently logged in. If omitted or set to zero, the file is shown without checking if the user is currently logged in.
  • RELOG
    Displays the login page.
  • SEARCH
    Provides a generic interface to allow the searching of any table in the database. This operation assumes that an appropriate search_
    xxx
    .htmpl has been created, where
    xxx
    is the
    object-name
    , as defined in the .maj files in the majic directory in bopcfg.
    For more information, see CA Service Desk Manager Reference Commands. By default, the results of this search are displayed in list_
    xxx
    .htmpl, but this can be overridden by specifying the HTMPL property.
    • Required specifiers:
      FACTORY=
      object-name
      QBE.
      op
      .
      attr_name
      =
      value
    • Optional specifiers:
      ALG_PRESET
      =preset_expression
      ALG_PRESET_REL
      =preset_expression
      CREATE_ALG=
      activity_log_type
      HTMPL=
      list_htmpl_file
      KEEP
      .attr_name=value
  • SEC_REFRESH
    Refreshes the user access information from the security subsystem. A hyperlink for this operation is provided to users who have MODIFY privileges (for the admin functional group) on the menu screen. After updating user access privileges with the security program, this operation provides a means to refresh access information. (This operation refreshes the security information for all users.)
    Security refresh is an asynchronous process. When the security refresh is done, a message shows in the standard log file (stdlog).
  • SET_MENU
    The behavior of this operation is the same as MENU when MENU is used with the HTMPL variable. The only difference is that this operation also sets the default menu form to the menu form specified with the HTMPL property.
    • Required specifiers:
      HTMPL=
      htmpl_file
    This operation overrides the MENU set in the web.cfg until the web service is restarted.
  • SHOW_DETAIL
    Provides a generic interface to allow the user to display a read-only detail of a row in a specified table. The persistent ID name must be specified (from which the object name is inferred). By default, a template named detail_
    xxx
    _ro.htmpl is used for object
    xxx
    . The .htmpl file can be overridden by specifying the HTMPL property.
    • Required specifiers:
      PERSID=
      persistent
      -
      id
    • Optional specifiers:
      ALG_PRESET
      =preset_expression
      ALG_PRESET_REL
      =preset_expression
      CREATE_ALG=
      activity_log_type
      HTMPL=
      readonly_detail_htmpl_file
  • UPDATE
    Provides a generic interface to editing any table. The ID and object name must be passed in and a detail form that the user can edit is displayed to the user. By default, the user has exclusive access to the record for two minutes, and is guaranteed to get changes into the database if they are submitted in this time.
    • Required specifiers:
      PERSID=
      persistent-id
      orSET.id=
      id-of-row-to-update
      FACTORY=
      object-name
    • Optional specifiers:
      NEXT_PERSID=
      persistent
      -
      id
      (of record to display after successful update)KEEP
      .attr_name=value
      KEY
      .attr_name=value
      HTMPL=zdetailxxx_
      factory
      .htmpl
    To use the HTMPL specifier with UPDATE, the referenced form must have a name conforming to the naming convention zdetailxxx_
    factory
    .htmpl. The name must begin with the string “zdetail”, followed by any alphanumeric characters (including a null string), followed by an underscore and the factory name.
For information about web.cfg, see How to Configure the Web Interface.
Operation Variables
This table lists the variables that can be set for each of the operations in the supported operations:
Variables
Description
Operations
ALG_PRESET
ALG_PRESET_REL
Specifies values for one or more of the attributes of the activity log created as a result of the CREATE_ALG variable. If CREATE_ALG is not specified, ALG_PRESET and ALG_PRESET_REL are ignored.
CREATE_NEWSEARCHSHOW_DETAIL
CREATE_ALG
Specifies the activity log type of an activity log to be created as a side effect of the operation. Use the ALG_PRESET or ALG_PRESET variables to specify values for the attributes of the new activity log.
The timing of creation of the activity log depends on the operation, as follows:
CREATE_NEW
The activity log is created when the new record is saved. If the new record is not saved, no activity log is created.
SEARCH
The activity log is created when a record is selected from the list form. If the record is viewed instead of selected (that is, the user explicitly selects the View command from the list form's mouse-over menu), no activity log is created.
SHOW_DETAIL
The activity log is created before the record is displayed.
CREATE_NEWSEARCHSHOW_DETAIL
FACTORY
Specifies the class of object to be searched, created, or updated. You can use any name specified as an OBJECT in the *.maj files in $NX_ROOT/bopcfg as listed in CA Service Desk Manager Reference Commands.
CREATE_NEWGENERIC_LISTSEARCHUPDATE
HTMPL
Allows the HTMPL author to override the default template naming convention and explicitly specify the HTMPL file to display, instead of the default template.
Note:
When the HTMPL specifier is used with CREATE_NEW or UPDATE, the name of the referenced form must conform to the naming convention zdetailxxx_factory.htmpl, where xxx are any characters, and
factory
is the factory name.
CREATE_NEWDISPLAY_FORMJUST_GRONK_ITMENUSEARCHSET_MENUSHOW_DETAIL
UPDATE
KEEP.
name
Specifies the value that can be saved and passed between pages.
CREATE_NEWGENERIC_LISTSEARCHUPDATE
KEY.
attr_name
Similar to the SET.
attr_name
, except that this specifies a lookup on
attr_name
, which must be a reference to another table or object.
UPDATE
NEXT_PERSID
Specifies the persistent ID of the record to be displayed next.
UPDATE
PERSID
Specifies the persistent ID of a record to be displayed. You can specify this in either of the following ways:
Directly, with a persistent ID consisting of a factory name, a colon (:), and a unique integer database ID. For example, PERSID=chg:1234, specifies the change order with database ID 1234.
Indirectly, with a persistent ID consisting of a factory name, a colon (:), an attribute name, a second colon (:), and a value. This form of PERSID specifies the record of the specified factory that has an attribute of the specified value. For example, PERSID=chg:chg_ref_num:demo:3 specifies the change order with reference number demo:3.
SHOW_DETAILUPDATE
PRESET
PRESET_REL
Specifies values for one or more of the attributes of the record created as a result of the CREATE_NEW variable. If CREATE_NEW is not specified, PRESET is ignored.
CREATE_NEW
QBE.
op
.
attr_name
Specifies the values to use when performing a search. These values are identified using a QBE keyword, where
attr_name
identifies any attribute name on a ticket that can be set and
op
indicates to search where the attribute:
EQ is equal to the value
NE is not equal to the value
GT is greater than the value
LT is less than the value
GE is greater than or equal to the value
LE is less than or equal to the value
NU is null
NN is not null
IN matches the SQL LIKE expression
KY contains the text entered
If you do not define any QBE variables, the standard search window is displayed.
SEARCH
SET.
attr_name
Specifies an attribute name to use when a ticket is created, where
attr_name
identifies any attribute in a ticket that can be set. The attribute names will vary depending on the underlying object. All objects and their attributes can be found in the *.maj files in the majic directory in bopcfg as listed in CA Service Desk Manager Reference Commands.
CREATE_NEWUPDATE
SET.
id
Specifies the database ID of the row to be updated.
UPDATE
SKIPLIST
When set to 1, searches that result in 1 hit do not display the search result list. Instead, the read-only detail is displayed directly.
SEARCH
use_template
When set to 1, the SEARCH operation will return a list of templates. The returned template selected will be used in the CREATE_NEW operation to populate a new record. This variable is valid for change orders, issues, and requests.
CREATE_NEWSEARCH
 
Syntax of PRESET, PRESET_REL, ALG_PRESET, and ALG_PRESET_REL
The PRESET, PRESET_REL, ALG_PRESET and ALG_PRESET_REL keywords in the URL specify initial values for attributes of the ticket and its activity log, respectively. There are two possible formats:
  • [ALG_]PRESET=
    attr
    :
    value
    Indicates that the specified attribute of the ticket or activity log should be set to the specified value. For example, the following specification sets the description of the new ticket to “Hello:”
    PRESET=description:Hello
  • [ALG_]PRESET_REL=attr:obj.relattr:testattr:value
    Indicates that the specified attribute of the ticket or activity log should be set to a value copied from another database table. The value is copied from the
    relattr
    attribute of the
    obj
    whose
    testattr
    has the specified
    value
    . For example, the following specification sets the analyst attribute of the new ticket to the ID of the contact with user ID xyz123:
    PRESET_REL=analyst:cnt.id:userid:xyz123
    When this format is used, the implied query must retrieve a unique record. If more than one contact has a user ID of xyz123 (or none), the example PRESET specification has no effect.
The PRESET, PRESET_REL, ALG_PRESET and ALG_PRESET_REL keywords can occur as many times as desired in a URL, allowing the setting of multiple attributes. Alternatively, a single keyword operand can specify multiple values separated by @@. If the '@@' separator is used, you cannot mix value formats for [ALG_]PRESET and [ALG_]PRESET_REL keywords. For example, the following example shows two different ways of specifying values for ticket description, summary and analyst:
PRESET=description:Hello+PRESET=summary:HelloThere+PRESET_REL=analyst:cnt.id:userid:xyz123 PRESET=description:Hello@@summary:HelloThere+PRESET_REL=analyst:cnt.id:userid:xyz123
For requests, issues, incidents, problems, and change orders, both PRESET and PRESET_REL support a keyword attribute ASSET to link an object to an asset. The ASSET attribute updates the affected_resource attribute of a request, incident, or problem, or the asset LREL of an issue or change order.
Link Examples
The following link examples do not include the path to CA SDM. All CA SDM URLs begin with coding of the following form:
http://
hostname
[:
port
]/CAisd/pdmweb.exe
In this example,
hostname
is the name of your server and
port
(optional) is the port number if you are using Tomcat. This coding is shown as an ellipsis (…) in the following URL examples:
  • To create a request with an affected end user with the userid tooda01, use the following example URL:
    ...?OP=CREATE_NEW+FACTORY=cr+PRESET_REL=customer:cnt.id:userid:tooda01
  • To display a list of all requests assigned to userid tooda01, use the following example URL:
    ...?OP=SEARCH+FACTORY=cr+QBE.EQ.assignee.userid=tooda01
  • To display the detail form for request 1234, use the following example URLs:
    ...?OP=SHOW_DETAIL+FACTORY=cr+PERSID=cr:ref_num:1234 (read-only view) ...?OP=UPDATE+FACTORY=cr+PERSID=cr:ref_num:1234 (update view)
You can bypass the logon challenge by using Web Services for authentication. For information about the getBopsid() method, see CA Service Desk Manager Reference Commands.