sf-i-events 1.0.910 → 1.0.911
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/sf-i-events.d.ts +1 -0
- package/sf-i-events.js +21 -20
- package/src/sf-i-events.ts +20 -20
package/package.json
CHANGED
package/sf-i-events.d.ts
CHANGED
package/sf-i-events.js
CHANGED
|
@@ -1254,6 +1254,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
1254
1254
|
this.graphFilter = "";
|
|
1255
1255
|
this.recentlyReported = {};
|
|
1256
1256
|
this.registerFilters = {};
|
|
1257
|
+
this.tablecols = [];
|
|
1257
1258
|
this.isSelectedLegend = (value) => {
|
|
1258
1259
|
return this.chartSelectedLegend.includes(value);
|
|
1259
1260
|
};
|
|
@@ -5614,6 +5615,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5614
5615
|
return [buttonSelectAll, buttonUnselectAll];
|
|
5615
5616
|
};
|
|
5616
5617
|
this.renderRegisterEvents = (events, meta = "", searchCountryIndex = -1, searchIndex = -1, searchVal = "") => {
|
|
5618
|
+
var _a;
|
|
5617
5619
|
var html = '';
|
|
5618
5620
|
this.csvDataRegisters = '';
|
|
5619
5621
|
let flagUpdateFilters = Object.keys(this.registerFilters).length == 0;
|
|
@@ -5636,7 +5638,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5636
5638
|
this.renderRegisterEvents(events);
|
|
5637
5639
|
});
|
|
5638
5640
|
}
|
|
5639
|
-
|
|
5641
|
+
this.tablecols = [];
|
|
5640
5642
|
if (this.selectedCountryTab >= 0) {
|
|
5641
5643
|
const index = this.selectedCountryTab;
|
|
5642
5644
|
//console.log('indexclicked', index);
|
|
@@ -5672,7 +5674,6 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5672
5674
|
html += '</div>';
|
|
5673
5675
|
html += '</div>';
|
|
5674
5676
|
html += '<table>';
|
|
5675
|
-
tablecols = [];
|
|
5676
5677
|
let tableBodyHtml = '';
|
|
5677
5678
|
for (var j = 0; j < Object.keys(objCountry[statute]).length; j++) {
|
|
5678
5679
|
const complianceId = Object.keys(objCountry[statute])[j];
|
|
@@ -5680,12 +5681,12 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5680
5681
|
console.log('hidecompliances', compliance.hide, complianceId);
|
|
5681
5682
|
const data = JSON.parse(compliance.data);
|
|
5682
5683
|
const cols = JSON.parse(compliance.cols);
|
|
5683
|
-
if (!tablecols.includes('ID') && !this.EXCLUDE_COLS_FROM_REGS.includes('ID')) {
|
|
5684
|
-
tablecols.push('ID');
|
|
5684
|
+
if (!this.tablecols.includes('ID') && !this.EXCLUDE_COLS_FROM_REGS.includes('ID')) {
|
|
5685
|
+
this.tablecols.push('ID');
|
|
5685
5686
|
}
|
|
5686
5687
|
for (let col of cols) {
|
|
5687
|
-
if (!tablecols.includes(col.toLowerCase()) && !this.EXCLUDE_COLS_FROM_REGS.includes(col.toLowerCase())) {
|
|
5688
|
-
tablecols.push(col);
|
|
5688
|
+
if (!this.tablecols.includes(col.toLowerCase()) && !this.EXCLUDE_COLS_FROM_REGS.includes(col.toLowerCase())) {
|
|
5689
|
+
this.tablecols.push(col);
|
|
5689
5690
|
if (flagUpdateFilters && this.registerFilters[col] == null) {
|
|
5690
5691
|
this.registerFilters[col] = {};
|
|
5691
5692
|
}
|
|
@@ -5709,7 +5710,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5709
5710
|
// tableBodyHtml += ('<td class="td-body" part="td-body-register"><span part="td-head" style="padding-left: 0px !important">ID</span><br /><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + complianceId + '" minLength="10" lineSize="4"></sf-i-elastic-text></td>');
|
|
5710
5711
|
let tempCount = 0;
|
|
5711
5712
|
for (var k = 0; k < cols.length; k++) {
|
|
5712
|
-
if (!this.EXCLUDE_COLS_FROM_REGS.includes(cols[k].toLowerCase()) && tablecols.indexOf(cols[k]) == tempCount + 1) {
|
|
5713
|
+
if (!this.EXCLUDE_COLS_FROM_REGS.includes(cols[k].toLowerCase()) && this.tablecols.indexOf(cols[k]) == tempCount + 1) {
|
|
5713
5714
|
// tableBodyHtml += ('<td class="td-body" part="td-body-register"><span part="td-head" style="padding-left: 0px !important">' + cols[k] + '</span><br /><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + data[k] + '" minLength="80" lineSize="4"></sf-i-elastic-text></td>');
|
|
5714
5715
|
tableBodyHtml += ('<td class="td-body" part="td-body-register"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + data[k] + '" highlight="' + searchVal + '" minLength="80" lineSize="4"></sf-i-elastic-text></td>');
|
|
5715
5716
|
this.csvDataRegisters += ('"' + (data[k] + "").replace(/"/g, '') + '",');
|
|
@@ -5720,7 +5721,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5720
5721
|
tempCount++;
|
|
5721
5722
|
}
|
|
5722
5723
|
else {
|
|
5723
|
-
console.log('skipping col', cols[k], tablecols.indexOf(cols[k]), k + 1);
|
|
5724
|
+
console.log('skipping col', cols[k], this.tablecols.indexOf(cols[k]), k + 1);
|
|
5724
5725
|
}
|
|
5725
5726
|
}
|
|
5726
5727
|
if (compliance['entities'] != null && Array.isArray(compliance['entities'])) {
|
|
@@ -5730,8 +5731,8 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5730
5731
|
}
|
|
5731
5732
|
entities = entities.slice(0, entities.length - 1);
|
|
5732
5733
|
tableBodyHtml += ('<td class="td-body" part="td-body-register"><span part="td-head" style="padding-left: 0px !important">entities</span><br /><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + entities + '" highlight="' + searchVal + '" minLength="80" lineSize="4"></sf-i-elastic-text></td>');
|
|
5733
|
-
if (!tablecols.includes('entities') && !this.EXCLUDE_COLS_FROM_REGS.includes('entities')) {
|
|
5734
|
-
tablecols.push('entities');
|
|
5734
|
+
if (!this.tablecols.includes('entities') && !this.EXCLUDE_COLS_FROM_REGS.includes('entities')) {
|
|
5735
|
+
this.tablecols.push('entities');
|
|
5735
5736
|
}
|
|
5736
5737
|
if (flagUpdateFilters) {
|
|
5737
5738
|
if (this.registerFilters["entities"] == null) {
|
|
@@ -5748,8 +5749,8 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5748
5749
|
}
|
|
5749
5750
|
locations = locations.slice(0, locations.length - 1);
|
|
5750
5751
|
tableBodyHtml += ('<td class="td-body" part="td-body-register"><span part="td-head" style="padding-left: 0px !important">locations</span><br /><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + locations + '" highlight="' + searchVal + '" minLength="80" lineSize="4"></sf-i-elastic-text></td>');
|
|
5751
|
-
if (!tablecols.includes('locations') && !this.EXCLUDE_COLS_FROM_REGS.includes('locations')) {
|
|
5752
|
-
tablecols.push('locations');
|
|
5752
|
+
if (!this.tablecols.includes('locations') && !this.EXCLUDE_COLS_FROM_REGS.includes('locations')) {
|
|
5753
|
+
this.tablecols.push('locations');
|
|
5753
5754
|
}
|
|
5754
5755
|
if (flagUpdateFilters) {
|
|
5755
5756
|
if (this.registerFilters["locations"] == null) {
|
|
@@ -5768,20 +5769,20 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5768
5769
|
}
|
|
5769
5770
|
html += '<thead><tr>';
|
|
5770
5771
|
html += '<th class="td-body" part="td-body-register"><span part="td-head" style="padding-left: 0px !important"></span></th>';
|
|
5771
|
-
for (let colName of tablecols) {
|
|
5772
|
+
for (let colName of this.tablecols) {
|
|
5772
5773
|
let allSelected = true;
|
|
5773
|
-
for (let subfilterObj of Object.keys(this.registerFilters[colName])) {
|
|
5774
|
+
for (let subfilterObj of Object.keys((_a = this.registerFilters[colName]) !== null && _a !== void 0 ? _a : {})) {
|
|
5774
5775
|
if (this.registerFilters[colName][subfilterObj] == false) {
|
|
5775
5776
|
allSelected = false;
|
|
5776
5777
|
break;
|
|
5777
5778
|
}
|
|
5778
5779
|
}
|
|
5779
|
-
html += '<th class="td-body" part="td-body-register"><div class="d-flex align-start"><span part="' + (allSelected ? 'td-head' : 'td-head-selected') + '" style="padding-left: 0px !important">' + colName + '</span><div class="filter-button-container ml-10"><button part="' + (allSelected ? 'button-icon' : 'button-icon-selected') + '" id="filter-button-' + tablecols.indexOf(colName) + '" class="filter-button material-symbols-outlined">filter_list</button>';
|
|
5780
|
-
html += '<div id="filter-list-container-' + tablecols.indexOf(colName) + '" class="filter-list-container hide flex-col justify-between align-start p-10" part="filter-list-container" anchor="filter-button">';
|
|
5781
|
-
html += `<div id="filter-label-container-${tablecols.indexOf(colName)}" class="filter-label-container d-flex justify-between align-center" part="filter-label-container"><div class="d-flex align-center"><input class="input-select-filter" type="checkbox" ${allSelected ? 'checked' : ''} id="input-select-filter-${tablecols.indexOf(colName)}-all" name="features" part="input-select-feature" value="all-${colName}"></input><label class="filter-label" part="filter-label" for="input-select-filter-${tablecols.indexOf(colName)}-all">All</label></div><button id="button-submit-filters-${tablecols.indexOf(colName)}" part="button-icon-small" class="button-submit-filters material-icons invisible">check</button></div>`;
|
|
5780
|
+
html += '<th class="td-body" part="td-body-register"><div class="d-flex align-start"><span part="' + (allSelected ? 'td-head' : 'td-head-selected') + '" style="padding-left: 0px !important">' + colName + '</span><div class="filter-button-container ml-10"><button part="' + (allSelected ? 'button-icon' : 'button-icon-selected') + '" id="filter-button-' + this.tablecols.indexOf(colName) + '" class="filter-button material-symbols-outlined">filter_list</button>';
|
|
5781
|
+
html += '<div id="filter-list-container-' + this.tablecols.indexOf(colName) + '" class="filter-list-container hide flex-col justify-between align-start p-10" part="filter-list-container" anchor="filter-button">';
|
|
5782
|
+
html += `<div id="filter-label-container-${this.tablecols.indexOf(colName)}" class="filter-label-container d-flex justify-between align-center" part="filter-label-container"><div class="d-flex align-center"><input class="input-select-filter" type="checkbox" ${allSelected ? 'checked' : ''} id="input-select-filter-${this.tablecols.indexOf(colName)}-all" name="features" part="input-select-feature" value="all-${colName}"></input><label class="filter-label" part="filter-label" for="input-select-filter-${this.tablecols.indexOf(colName)}-all">All</label></div><button id="button-submit-filters-${this.tablecols.indexOf(colName)}" part="button-icon-small" class="button-submit-filters material-icons invisible">check</button></div>`;
|
|
5782
5783
|
for (let [index, filterKey] of Object.keys(this.registerFilters[colName]).entries()) {
|
|
5783
5784
|
console.log('rendering filter', filterKey);
|
|
5784
|
-
html += `<div class="filter-input-container d-flex justify-start align-start"><input class="input-select-filter" type="checkbox" ${this.registerFilters[colName][filterKey] == true ? 'checked' : ''} id="input-select-filter-${tablecols.indexOf(colName)}-${index}" name="features" part="input-select-feature" value="${filterKey}"></input><label for="input-select-filter-${tablecols.indexOf(colName)}-${index}" id="input-select-filter-label-${tablecols.indexOf(colName)}-${index}" class="input-select-filter-label" part="input-select-feature-label">${filterKey}</label></div>`;
|
|
5785
|
+
html += `<div class="filter-input-container d-flex justify-start align-start"><input class="input-select-filter" type="checkbox" ${this.registerFilters[colName][filterKey] == true ? 'checked' : ''} id="input-select-filter-${this.tablecols.indexOf(colName)}-${index}" name="features" part="input-select-feature" value="${filterKey}"></input><label for="input-select-filter-${this.tablecols.indexOf(colName)}-${index}" id="input-select-filter-label-${this.tablecols.indexOf(colName)}-${index}" class="input-select-filter-label" part="input-select-feature-label">${filterKey}</label></div>`;
|
|
5785
5786
|
}
|
|
5786
5787
|
html += '</div></div></th>';
|
|
5787
5788
|
}
|
|
@@ -5920,7 +5921,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5920
5921
|
let checked = e.currentTarget.checked;
|
|
5921
5922
|
let selectedColIndex = e.currentTarget.id.split('-')[3];
|
|
5922
5923
|
let selectedFilterIndex = e.currentTarget.id.split('-')[4];
|
|
5923
|
-
let colName = tablecols[selectedColIndex];
|
|
5924
|
+
let colName = this.tablecols[selectedColIndex];
|
|
5924
5925
|
// for (let [colIndex, colName] of Object.keys(this.registerFilters).entries()) {
|
|
5925
5926
|
if (colName != null) {
|
|
5926
5927
|
for (let [filterIndex, filterKey] of Object.keys(this.registerFilters[colName]).entries()) {
|
|
@@ -5948,7 +5949,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5948
5949
|
if (buttonSubmitFilters != null) {
|
|
5949
5950
|
buttonSubmitFilters.style.visibility = 'visible';
|
|
5950
5951
|
}
|
|
5951
|
-
console.log('registerFilters applying', colName, selectedFilterIndex);
|
|
5952
|
+
console.log('registerFilters applying', colName, selectedFilterIndex, this.tablecols);
|
|
5952
5953
|
});
|
|
5953
5954
|
}
|
|
5954
5955
|
const arrButtonSubmitFilters = this._SfRegisterContainer.querySelector('.calendar-right-data-register').querySelectorAll('.button-submit-filters');
|
package/src/sf-i-events.ts
CHANGED
|
@@ -1685,6 +1685,7 @@ export class SfIEvents extends LitElement {
|
|
|
1685
1685
|
|
|
1686
1686
|
registerFilters: { [key: string]: { [key: string]: boolean } } = {};
|
|
1687
1687
|
|
|
1688
|
+
tablecols: string[] = []
|
|
1688
1689
|
static override styles = css`
|
|
1689
1690
|
|
|
1690
1691
|
.bg-white {
|
|
@@ -8189,7 +8190,7 @@ export class SfIEvents extends LitElement {
|
|
|
8189
8190
|
this.renderRegisterEvents(events);
|
|
8190
8191
|
});
|
|
8191
8192
|
}
|
|
8192
|
-
|
|
8193
|
+
this.tablecols = []
|
|
8193
8194
|
if (this.selectedCountryTab >= 0) {
|
|
8194
8195
|
|
|
8195
8196
|
const index = this.selectedCountryTab;
|
|
@@ -8235,7 +8236,6 @@ export class SfIEvents extends LitElement {
|
|
|
8235
8236
|
html += '</div>';
|
|
8236
8237
|
html += '</div>';
|
|
8237
8238
|
html += '<table>';
|
|
8238
|
-
tablecols = []
|
|
8239
8239
|
let tableBodyHtml = ''
|
|
8240
8240
|
for (var j = 0; j < Object.keys(objCountry[statute]).length; j++) {
|
|
8241
8241
|
|
|
@@ -8245,13 +8245,13 @@ export class SfIEvents extends LitElement {
|
|
|
8245
8245
|
|
|
8246
8246
|
const data = JSON.parse(compliance.data);
|
|
8247
8247
|
const cols = JSON.parse(compliance.cols);
|
|
8248
|
-
if (!tablecols.includes('ID') && !this.EXCLUDE_COLS_FROM_REGS.includes('ID')) {
|
|
8249
|
-
tablecols.push('ID')
|
|
8248
|
+
if (!this.tablecols.includes('ID') && !this.EXCLUDE_COLS_FROM_REGS.includes('ID')) {
|
|
8249
|
+
this.tablecols.push('ID')
|
|
8250
8250
|
}
|
|
8251
8251
|
|
|
8252
8252
|
for (let col of cols) {
|
|
8253
|
-
if (!tablecols.includes(col.toLowerCase()) && !this.EXCLUDE_COLS_FROM_REGS.includes(col.toLowerCase())) {
|
|
8254
|
-
tablecols.push(col)
|
|
8253
|
+
if (!this.tablecols.includes(col.toLowerCase()) && !this.EXCLUDE_COLS_FROM_REGS.includes(col.toLowerCase())) {
|
|
8254
|
+
this.tablecols.push(col)
|
|
8255
8255
|
if (flagUpdateFilters && this.registerFilters[col] == null) {
|
|
8256
8256
|
this.registerFilters[col] = {}
|
|
8257
8257
|
}
|
|
@@ -8277,7 +8277,7 @@ export class SfIEvents extends LitElement {
|
|
|
8277
8277
|
// tableBodyHtml += ('<td class="td-body" part="td-body-register"><span part="td-head" style="padding-left: 0px !important">ID</span><br /><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + complianceId + '" minLength="10" lineSize="4"></sf-i-elastic-text></td>');
|
|
8278
8278
|
let tempCount = 0;
|
|
8279
8279
|
for (var k = 0; k < cols.length; k++) {
|
|
8280
|
-
if (!this.EXCLUDE_COLS_FROM_REGS.includes(cols[k].toLowerCase()) && tablecols.indexOf(cols[k]) == tempCount + 1) {
|
|
8280
|
+
if (!this.EXCLUDE_COLS_FROM_REGS.includes(cols[k].toLowerCase()) && this.tablecols.indexOf(cols[k]) == tempCount + 1) {
|
|
8281
8281
|
// tableBodyHtml += ('<td class="td-body" part="td-body-register"><span part="td-head" style="padding-left: 0px !important">' + cols[k] + '</span><br /><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + data[k] + '" minLength="80" lineSize="4"></sf-i-elastic-text></td>');
|
|
8282
8282
|
tableBodyHtml += ('<td class="td-body" part="td-body-register"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + data[k] + '" highlight="' + searchVal + '" minLength="80" lineSize="4"></sf-i-elastic-text></td>');
|
|
8283
8283
|
this.csvDataRegisters += ('"' + (data[k] + "").replace(/"/g, '') + '",');
|
|
@@ -8287,7 +8287,7 @@ export class SfIEvents extends LitElement {
|
|
|
8287
8287
|
}
|
|
8288
8288
|
tempCount++;
|
|
8289
8289
|
} else {
|
|
8290
|
-
console.log('skipping col', cols[k], tablecols.indexOf(cols[k]), k + 1)
|
|
8290
|
+
console.log('skipping col', cols[k], this.tablecols.indexOf(cols[k]), k + 1)
|
|
8291
8291
|
}
|
|
8292
8292
|
}
|
|
8293
8293
|
if (compliance['entities'] != null && Array.isArray(compliance['entities'])) {
|
|
@@ -8297,8 +8297,8 @@ export class SfIEvents extends LitElement {
|
|
|
8297
8297
|
}
|
|
8298
8298
|
entities = entities.slice(0, entities.length - 1)
|
|
8299
8299
|
tableBodyHtml += ('<td class="td-body" part="td-body-register"><span part="td-head" style="padding-left: 0px !important">entities</span><br /><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + entities + '" highlight="' + searchVal + '" minLength="80" lineSize="4"></sf-i-elastic-text></td>');
|
|
8300
|
-
if (!tablecols.includes('entities') && !this.EXCLUDE_COLS_FROM_REGS.includes('entities')) {
|
|
8301
|
-
tablecols.push('entities')
|
|
8300
|
+
if (!this.tablecols.includes('entities') && !this.EXCLUDE_COLS_FROM_REGS.includes('entities')) {
|
|
8301
|
+
this.tablecols.push('entities')
|
|
8302
8302
|
}
|
|
8303
8303
|
if (flagUpdateFilters) {
|
|
8304
8304
|
if (this.registerFilters["entities"] == null) {
|
|
@@ -8315,8 +8315,8 @@ export class SfIEvents extends LitElement {
|
|
|
8315
8315
|
}
|
|
8316
8316
|
locations = locations.slice(0, locations.length - 1)
|
|
8317
8317
|
tableBodyHtml += ('<td class="td-body" part="td-body-register"><span part="td-head" style="padding-left: 0px !important">locations</span><br /><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + locations + '" highlight="' + searchVal + '" minLength="80" lineSize="4"></sf-i-elastic-text></td>');
|
|
8318
|
-
if (!tablecols.includes('locations') && !this.EXCLUDE_COLS_FROM_REGS.includes('locations')) {
|
|
8319
|
-
tablecols.push('locations')
|
|
8318
|
+
if (!this.tablecols.includes('locations') && !this.EXCLUDE_COLS_FROM_REGS.includes('locations')) {
|
|
8319
|
+
this.tablecols.push('locations')
|
|
8320
8320
|
}
|
|
8321
8321
|
if (flagUpdateFilters) {
|
|
8322
8322
|
if (this.registerFilters["locations"] == null) {
|
|
@@ -8336,21 +8336,21 @@ export class SfIEvents extends LitElement {
|
|
|
8336
8336
|
html += '<thead><tr>';
|
|
8337
8337
|
html += '<th class="td-body" part="td-body-register"><span part="td-head" style="padding-left: 0px !important"></span></th>'
|
|
8338
8338
|
|
|
8339
|
-
for (let colName of tablecols) {
|
|
8339
|
+
for (let colName of this.tablecols) {
|
|
8340
8340
|
let allSelected = true;
|
|
8341
|
-
for (let subfilterObj of Object.keys(this.registerFilters[colName])) {
|
|
8341
|
+
for (let subfilterObj of Object.keys(this.registerFilters[colName] ?? {})) {
|
|
8342
8342
|
if (this.registerFilters[colName][subfilterObj] == false) {
|
|
8343
8343
|
allSelected = false;
|
|
8344
8344
|
break;
|
|
8345
8345
|
}
|
|
8346
8346
|
}
|
|
8347
8347
|
|
|
8348
|
-
html += '<th class="td-body" part="td-body-register"><div class="d-flex align-start"><span part="' + (allSelected ? 'td-head' : 'td-head-selected') + '" style="padding-left: 0px !important">' + colName + '</span><div class="filter-button-container ml-10"><button part="' + (allSelected ? 'button-icon' : 'button-icon-selected') + '" id="filter-button-' + tablecols.indexOf(colName) + '" class="filter-button material-symbols-outlined">filter_list</button>'
|
|
8349
|
-
html += '<div id="filter-list-container-' + tablecols.indexOf(colName) + '" class="filter-list-container hide flex-col justify-between align-start p-10" part="filter-list-container" anchor="filter-button">'
|
|
8350
|
-
html += `<div id="filter-label-container-${tablecols.indexOf(colName)}" class="filter-label-container d-flex justify-between align-center" part="filter-label-container"><div class="d-flex align-center"><input class="input-select-filter" type="checkbox" ${allSelected ? 'checked' : ''} id="input-select-filter-${tablecols.indexOf(colName)}-all" name="features" part="input-select-feature" value="all-${colName}"></input><label class="filter-label" part="filter-label" for="input-select-filter-${tablecols.indexOf(colName)}-all">All</label></div><button id="button-submit-filters-${tablecols.indexOf(colName)}" part="button-icon-small" class="button-submit-filters material-icons invisible">check</button></div>`
|
|
8348
|
+
html += '<th class="td-body" part="td-body-register"><div class="d-flex align-start"><span part="' + (allSelected ? 'td-head' : 'td-head-selected') + '" style="padding-left: 0px !important">' + colName + '</span><div class="filter-button-container ml-10"><button part="' + (allSelected ? 'button-icon' : 'button-icon-selected') + '" id="filter-button-' + this.tablecols.indexOf(colName) + '" class="filter-button material-symbols-outlined">filter_list</button>'
|
|
8349
|
+
html += '<div id="filter-list-container-' + this.tablecols.indexOf(colName) + '" class="filter-list-container hide flex-col justify-between align-start p-10" part="filter-list-container" anchor="filter-button">'
|
|
8350
|
+
html += `<div id="filter-label-container-${this.tablecols.indexOf(colName)}" class="filter-label-container d-flex justify-between align-center" part="filter-label-container"><div class="d-flex align-center"><input class="input-select-filter" type="checkbox" ${allSelected ? 'checked' : ''} id="input-select-filter-${this.tablecols.indexOf(colName)}-all" name="features" part="input-select-feature" value="all-${colName}"></input><label class="filter-label" part="filter-label" for="input-select-filter-${this.tablecols.indexOf(colName)}-all">All</label></div><button id="button-submit-filters-${this.tablecols.indexOf(colName)}" part="button-icon-small" class="button-submit-filters material-icons invisible">check</button></div>`
|
|
8351
8351
|
for (let [index, filterKey] of Object.keys(this.registerFilters[colName]).entries()) {
|
|
8352
8352
|
console.log('rendering filter', filterKey);
|
|
8353
|
-
html += `<div class="filter-input-container d-flex justify-start align-start"><input class="input-select-filter" type="checkbox" ${this.registerFilters[colName][filterKey] == true ? 'checked' : ''} id="input-select-filter-${tablecols.indexOf(colName)}-${index}" name="features" part="input-select-feature" value="${filterKey}"></input><label for="input-select-filter-${tablecols.indexOf(colName)}-${index}" id="input-select-filter-label-${tablecols.indexOf(colName)}-${index}" class="input-select-filter-label" part="input-select-feature-label">${filterKey}</label></div>`
|
|
8353
|
+
html += `<div class="filter-input-container d-flex justify-start align-start"><input class="input-select-filter" type="checkbox" ${this.registerFilters[colName][filterKey] == true ? 'checked' : ''} id="input-select-filter-${this.tablecols.indexOf(colName)}-${index}" name="features" part="input-select-feature" value="${filterKey}"></input><label for="input-select-filter-${this.tablecols.indexOf(colName)}-${index}" id="input-select-filter-label-${this.tablecols.indexOf(colName)}-${index}" class="input-select-filter-label" part="input-select-feature-label">${filterKey}</label></div>`
|
|
8354
8354
|
}
|
|
8355
8355
|
html += '</div></div></th>'
|
|
8356
8356
|
}
|
|
@@ -8509,7 +8509,7 @@ export class SfIEvents extends LitElement {
|
|
|
8509
8509
|
let checked = e.currentTarget.checked;
|
|
8510
8510
|
let selectedColIndex = e.currentTarget.id.split('-')[3];
|
|
8511
8511
|
let selectedFilterIndex = e.currentTarget.id.split('-')[4];
|
|
8512
|
-
let colName = tablecols[selectedColIndex]
|
|
8512
|
+
let colName = this.tablecols[selectedColIndex]
|
|
8513
8513
|
// for (let [colIndex, colName] of Object.keys(this.registerFilters).entries()) {
|
|
8514
8514
|
if (colName != null) {
|
|
8515
8515
|
for (let [filterIndex, filterKey] of Object.keys(this.registerFilters[colName]).entries()) {
|
|
@@ -8537,7 +8537,7 @@ export class SfIEvents extends LitElement {
|
|
|
8537
8537
|
if (buttonSubmitFilters != null) {
|
|
8538
8538
|
buttonSubmitFilters.style.visibility = 'visible'
|
|
8539
8539
|
}
|
|
8540
|
-
console.log('registerFilters applying', colName, selectedFilterIndex)
|
|
8540
|
+
console.log('registerFilters applying', colName, selectedFilterIndex, this.tablecols)
|
|
8541
8541
|
})
|
|
8542
8542
|
}
|
|
8543
8543
|
|