Documentation Center

Adding statuses to forms

Statuses can help you moderate feedback that you receive through forms. The default comment form has four statuses: New, Accept, Decline, and Complete. You can add your own statuses to suit your workflow.

Before you begin

Before you add new status types you need to add or modify a custom skin.

About this task

Statuses are available to all forms. So, if you add a status that you intend to use on comments, that status is also available for issue reports. When you change the XML files to design your comments, you decide whether and how they are displayed via form definitions.

Procedure

  1. If necessary, add a new skin.
  2. If necessary, update your skin with language files.
    1. If you are on a Legacy Content Delivery page, select Home in the breadcrumb trail.
      The Legacy Content Delivery landing page appears.
    2. In the Administration Tools pane, select Developer's Workbench.
      The Developer's Workbench page appears.
    3. In the left pane, select base.
    4. In the right pane, select Develop with this skin, and then OK.
    5. In response to the Refresh this page to develop with this skin pop-up message, press F5.
    6. In the right pane, select Configuration.
    7. Adjacent to your language resource, select Copy/Merge Language.
    8. From the Skin Name drop-down list, select the name of the skin that you just added.
    9. Select Copy/Merge Language.
    10. In the admin.add (Add Item) field, use the green arrow to move the resource from the Source Skin to the Target Skin.
    11. Select Save.
    12. Select OK.
  3. Add a new status to each language file in your custom skin.
    1. In the left pane, select your custom skin.
    2. In the right pane, select Develop with this skin, and then OK.
    3. In response to the Refresh this page to develop with this skin pop-up message, press F5.
    4. Adjacent to the appropriate language resource, select Edit Language.
    5. Select Add Item.
      A pop-up window appears.
    6. In the Name field, enter the name for the new status type. For example, xform.status.new_status.
      This becomes the key.
    7. In the Value field, enter the text that you want to associate with the new status type. For example, my_status.
    8. Select Save.
      The configuration file is updated as follows:
      <item name="xform.status.new_status" value="my_status"/>
      where new_status is the key and my_status is the string as it will appear in the status drop-down list associated with comments.
    9. Repeat the above steps for each language resource.
  4. Modify the CSS.
    1. Copy the extra.css file from the css directory in the base skin to your working directory.
      The path to the skins directory structure in a default installation is
      \Apache Software Foundation\Tomcat 7.0\webapps\LiveContent
      \WEB-INF\db\LiveContent\ui\skins
      To find the path used in your installation, select Frame Navigator > Manage Application > System Status and check the App Directory field.
    2. In a text editor, open the extra.css file in your working directory, and add the following:
      .xform_status_new_status 
      { background: url(../img/icon_status_new_status.png) 
      no-repeat 15px top; } 

      where new_status is the name of the new status type that you previously added.

    3. Select Save.
    4. In the right pane, select the CSS tab.
    5. Select Upload Resources.
    6. Select Select Resources.
    7. Select the extra.css file in your working directory, and then Open.
    8. Select Upload.
      The new status type is loaded into the database.
  5. Add the icon.
    1. Add the icon_status_new_status.png icon file to your working directory.
    2. In the right pane, select the Images tab.
    3. Select Upload Resources.
    4. Select Select Resources.
    5. Select the icon_status_new_status.png file in your working directory, and then Open.
    6. Select Upload.
      The new image icon is loaded into the database.
  6. Finishing up.
    1. In the left pane, select Form Definitions.
    2. Select the form for which you want to include your new status type.
    3. Expand the form definition.
      The Status Options field appears, and contains the default statuses as well as the status you just added.
    4. Check Allow Reply?
    5. Ctrl-click on the new status type to make it active.
    6. Select Save.
    7. Check Allow Status Change?
    8. Ctrl-click on the new status type to make it active.
    9. Select Save.