Uploaded image for project: 'Forms for Confluence - Development'
  1. Forms for Confluence - Development
  2. FORMS-892

Checkboxes with same name confuse Javascript

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Done
    • Priority: L3
    • Resolution: Done
    • Affects Version/s: None
    • Fix Version/s: 8.3.0
    • Labels:
      None
    • Sprint:
      Boeing Q2-4
    • Story Points:
      3
    • Critical Points:
      0

      Description

      Steps to Reproduce

      1. Create a page with two form (Form 1 and Form 2) with a Checkbox field and set the name to be identical.
      2. Provided storage format:
        <p class="auto-cursor-target">
          <br/>
        </p>
        <ac:structured-macro ac:macro-id="83481bd3-fd88-44bd-8c09-e84f7be036bd" ac:name="mail-form" ac:schema-version="1">
          <ac:parameter ac:name="captcha">false</ac:parameter>
          <ac:parameter ac:name="hideSubmitButton">false</ac:parameter>
          <ac:parameter ac:name="generatedUUID">80033b56-b47b-41ef-87b5-cbe8b465100b</ac:parameter>
          <ac:parameter ac:name="destination">test form</ac:parameter>
          <ac:parameter ac:name="includeDestinations">false</ac:parameter>
          <ac:parameter ac:name="receipt">false</ac:parameter>
          <ac:parameter ac:name="submitButtonText">Submit</ac:parameter>
          <ac:parameter ac:name="allowSubmitAsAnonymous">false</ac:parameter>
          <ac:rich-text-body>
            <p>
              <br/>
            </p>
            <p>
              <ac:structured-macro ac:macro-id="97bbf43a-4924-4cea-97b0-71b9e4dfe92d" ac:name="checkbox-button-group" ac:schema-version="1">
                <ac:parameter ac:name="0_label">1</ac:parameter>
                <ac:parameter ac:name="2_value">3</ac:parameter>
                <ac:parameter ac:name="1_label">2</ac:parameter>
                <ac:parameter ac:name="2_selected">false</ac:parameter>
                <ac:parameter ac:name="counter">3</ac:parameter>
                <ac:parameter ac:name="label">Label</ac:parameter>
                <ac:parameter ac:name="required">false</ac:parameter>
                <ac:parameter ac:name="1_selected">false</ac:parameter>
                <ac:parameter ac:name="multiselect">false</ac:parameter>
                <ac:parameter ac:name="2_label">3</ac:parameter>
                <ac:parameter ac:name="0_value">1</ac:parameter>
                <ac:parameter ac:name="name">names</ac:parameter>
                <ac:parameter ac:name="1_value">2</ac:parameter>
                <ac:parameter ac:name="0_selected">false</ac:parameter>
              </ac:structured-macro>
            </p>
          </ac:rich-text-body>
        </ac:structured-macro>
        <p>
          <br/>
        </p>
        <p>
          <br/>
        </p>
        <ac:structured-macro ac:macro-id="6117ebfe-7d91-419f-93d4-c39b2fe33771" ac:name="mail-form" ac:schema-version="1">
          <ac:parameter ac:name="captcha">false</ac:parameter>
          <ac:parameter ac:name="hideSubmitButton">false</ac:parameter>
          <ac:parameter ac:name="generatedUUID">e2829703-418c-48c8-9adf-cc679677f1c4</ac:parameter>
          <ac:parameter ac:name="destination">test form</ac:parameter>
          <ac:parameter ac:name="includeDestinations">false</ac:parameter>
          <ac:parameter ac:name="receipt">false</ac:parameter>
          <ac:parameter ac:name="submitButtonText">Submit</ac:parameter>
          <ac:parameter ac:name="allowSubmitAsAnonymous">false</ac:parameter>
          <ac:rich-text-body>
            <p>
              <br/>
            </p>
            <p>
              <ac:structured-macro ac:macro-id="581ee9c3-2caa-437a-abab-7ac56999f6f5" ac:name="checkbox-button-group" ac:schema-version="1">
                <ac:parameter ac:name="0_label">a</ac:parameter>
                <ac:parameter ac:name="2_value">c</ac:parameter>
                <ac:parameter ac:name="1_label">b</ac:parameter>
                <ac:parameter ac:name="2_selected">false</ac:parameter>
                <ac:parameter ac:name="counter">3</ac:parameter>
                <ac:parameter ac:name="label">Labels</ac:parameter>
                <ac:parameter ac:name="required">false</ac:parameter>
                <ac:parameter ac:name="1_selected">false</ac:parameter>
                <ac:parameter ac:name="multiselect">false</ac:parameter>
                <ac:parameter ac:name="2_label">c</ac:parameter>
                <ac:parameter ac:name="0_value">a</ac:parameter>
                <ac:parameter ac:name="name">names</ac:parameter>
                <ac:parameter ac:name="1_value">b</ac:parameter>
                <ac:parameter ac:name="0_selected">false</ac:parameter>
              </ac:structured-macro>
            </p>
          </ac:rich-text-body>
        </ac:structured-macro>
        <p class="auto-cursor-target">
          <br/>
        </p>
        
      3. Click the Form 2 checkbox.
         
      Expected Outcome

      If the Form 2 checkbox are being click, it should check the correct checkbox form inside Form 2.

      Actual Outcome

      If the Form 2 checkbox are being click, it check the checkbox form inside Form 1.

      Recording: Recording #75.mp4

      Intermittent?

      False

      Affected Versions

      Plugin Confluence
      8.2.3 7.13.4
      8.2.3 7.13.5

        Attachments

          Activity

            People

            Assignee:
            anazarudin Amalina Nazarudin
            Reporter:
            aomar Amirul Omar
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: