Skip to Main Content

DevOps, CI/CD and Automation

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Header check box selection of rows using ojet 7.2.0

3037336Apr 23 2020 — edited Apr 24 2020

Hi,

We are using Ojet 7.2.0. We have check box to select rows in ojet table. header checkbox selection (ie select All) is not working with this version. Can you please guide. Please find the code. below. Please take this as high priority. I tried in 7.2.0 version of cookbook also. It is not working.

this.columnArray = [{ "headerTemplate": "headerCheckTemplate",

      "headerText":"Select All",

      "template": "checkTemplate",

      "sortable": "disabled"

    },

                         {"headerText": "Instrument Code",

                          "field": "instrumentCode"},

                         {"headerText": "Instrument Name",

                          "field": "instrumentName"},

                         {"headerText": "Instrument Type Code",

                          "field": "instrumentTypeCode"},

                          {"headerText": "InstrumentType Desc",

                              "field": "instrumentTypeDesc"},

                         {"headerText": "CounterParty Name",

                          "field": "counterPartyName"},

                          {"headerText": "Currency Code",

                              "field": "currencyCode"}

                          ];

  <template slot="headerCheckTemplate" >

                  <oj-checkboxset value='[[headerCheckStatus]]'

                                  on-value-changed='[[headerCheckboxListener]]'

                                  class='oj-checkboxset-no-chrome oj-selection-checkbox'

                                  id="table_header_checkbox">

                      <oj-option  aria-label="Checkbox Select All" value="checked"></oj-option>

                  </oj-checkboxset>  

this.headerCheckboxListener = function (event) {

    

          if (event.detail != null) {

            var value = event.detail.value;

            if (value.length > 0) {

            if(self.masterInstrumentList().length!=0){

        for(var i=0;i<self.masterInstrumentList().length;i++){

        this.selectedItems.add([self.masterInstrumentList()[i].instrumentCode]);

           self.selectedInstArray.push(self.masterInstrumentList()[i].instrumentCode);

        }

          }

            } else if (value.length === 0 && event.detail.updatedFrom == 'internal') {

              this.selectedItems.clear();

              self.selectedInstArray([]);

            }

          }

        }.bind(this);

Comments

Post Details

Added on Apr 23 2020
3 comments
367 views