Form Section Group

From All n One's bxp software Wixi

Jump to: navigation, search

1 Overview

Section Groups are a divider for a script in the same way a section header is.


A section group however has the ability to group a number of questions for a number of uses, specifically hiding and showing large groups of questions quickly.


Section Group is also extensively used in Quality Assurance forms to allow the grouping of answers for scoring purposes.


Section Group Collapsible.png


2 Creating a Section Group

  1. Add a "Section Group" to your script, giving it an appropriate title
  2. Check the script to ensure it is in the right position. (Reorder questions as necessary)
  3. From the Form - Edit console on the left of the screen click "Answer Values - Modify" (Main Menu > Form Management > Form - Primary > Form - Edit > Choose your form > Modify Answer Values)
  4. Choose the "Section Group" you just added
  5. It allows you to enter values as if it was another closed question type. Enter the Ids of the questions to manage with this group, from the list at the bottom of the screen.
  6. When you have finished adding all you need, retest your script. The Section Group should now have a - image to the far right. Click this should hide the group of questions.


Please note to NOT add the same Id as that of the question.


3 Managing a Section Group

From time to time new questions come along and need to be added to existing section groups. These are the steps for managing that process.

  1. Log into bxp
  2. Form Management > Form - Primary Management > Form - Edit > Choose your form
  3. Click the yellow Question Management option and the console will change
  4. Choose "Field Mapping - Original" and scroll to the bottom
  5. New fields are usually named "New" so update any new questions to titles more appropriate. Don't forget to "Update Mappings" down the bottom.
  6. Next choose "Question Reorder" and in the "Current Order" column adjust the numbers until the new fields are grouped together as you want them. You can test and retest using the "Add a Record" button in the console.
  7. Once they are together choose "Answer Values - Modify"
  8. Choose the Section Group you want to add your new questions to
  9. Down below each question has its own Id. Find the id of your new questions to add and put the numbers in the available empty text box called "Question". Don't forget to click "Update answers" for each question.
  10. You can test each new addition is working correctly simply by clicking "Add a record" and checking.


4 Data Usage

If the form is a Quality Assurance type then the CDA field contains the contents of a grouped scoring result will be stored in the CDA field for the Section Group.


If the form is of any other types then the CDA field will not hold any data just like a Section Header.


5 JavaScript notes

The Section Group also creates three custom JavaScript functions on the page. If we create a group and it is in Campaign 1149 and the Section Group is field_0_19. The function names would be:


function fn_SectionGroup_strCDA_1149_field_0_19_Show(strObject)   //This will show all the questions in this group, regardless of shown or hidden
function fn_SectionGroup_strCDA_1149_field_0_19_Hide(strObject)   //This will hide all the questions in this group, regardless of shown or hidden
function fn_SectionGroup_Toggle_strCDA_1149_field_0_19()          //This inspects the image of the group.  Using the src of the image, if + (plus) shows, if - (minus) shown, hides.