sf-i-events 1.0.909 → 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/dev/index.html +40 -1
- package/package.json +3 -2
- package/sf-i-events.d.ts +8 -1
- package/sf-i-events.js +411 -119
- package/src/sf-i-events.ts +433 -131
- package/src/util.ts +372 -326
- package/util.d.ts +2 -0
- package/util.js +39 -1
package/sf-i-events.js
CHANGED
|
@@ -913,7 +913,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
913
913
|
tempHtml += ', ';
|
|
914
914
|
}
|
|
915
915
|
}
|
|
916
|
-
html += ('<div><sf-i-elastic-text class="statute-summary id-9" text="' + tempHtml + '" minlength="50"></sf-i-elastic-text></div>');
|
|
916
|
+
html += ('<div><sf-i-elastic-text exportparts="highlight,highlight-count" class="statute-summary id-9" text="' + tempHtml + '" minlength="50"></sf-i-elastic-text></div>');
|
|
917
917
|
html += '</td>';
|
|
918
918
|
html += '</tr>';
|
|
919
919
|
count++;
|
|
@@ -965,14 +965,14 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
965
965
|
html += '<td part="td-body1" class="' + classBg + '">';
|
|
966
966
|
if (jsonFilterOnboarding[i].excludestatutes != null) {
|
|
967
967
|
for (var j = 0; j < jsonFilterOnboarding[i].excludestatutes.length; j++) {
|
|
968
|
-
html += ('<div><sf-i-elastic-text class="statute-summary id-9" text="' + jsonFilterOnboarding[i].excludestatutes[j] + '" minlength="10"></sf-i-elastic-text></div>');
|
|
968
|
+
html += ('<div><sf-i-elastic-text exportparts="highlight,highlight-count" class="statute-summary id-9" text="' + jsonFilterOnboarding[i].excludestatutes[j] + '" minlength="10"></sf-i-elastic-text></div>');
|
|
969
969
|
}
|
|
970
970
|
}
|
|
971
971
|
html += '</td>';
|
|
972
972
|
html += '<td part="td-body1" class="' + classBg + '">';
|
|
973
973
|
if (jsonFilterOnboarding[i].includestatutes != null) {
|
|
974
974
|
for (var j = 0; j < jsonFilterOnboarding[i].includestatutes.length; j++) {
|
|
975
|
-
html += ('<div><sf-i-elastic-text class="statute-summary id-9" text="' + jsonFilterOnboarding[i].includestatutes[j] + '" minlength="20"></sf-i-elastic-text></div>');
|
|
975
|
+
html += ('<div><sf-i-elastic-text exportparts="highlight,highlight-count" class="statute-summary id-9" text="' + jsonFilterOnboarding[i].includestatutes[j] + '" minlength="20"></sf-i-elastic-text></div>');
|
|
976
976
|
}
|
|
977
977
|
}
|
|
978
978
|
html += '</td>';
|
|
@@ -1253,6 +1253,8 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
1253
1253
|
this.selectallblock = "100";
|
|
1254
1254
|
this.graphFilter = "";
|
|
1255
1255
|
this.recentlyReported = {};
|
|
1256
|
+
this.registerFilters = {};
|
|
1257
|
+
this.tablecols = [];
|
|
1256
1258
|
this.isSelectedLegend = (value) => {
|
|
1257
1259
|
return this.chartSelectedLegend.includes(value);
|
|
1258
1260
|
};
|
|
@@ -2549,7 +2551,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
2549
2551
|
html += '<div class="stream-events-container flex-grow" part="' + bgStatus + '">';
|
|
2550
2552
|
html += '<div class="hidden-tags hide">' + JSON.stringify(event['tags']) + '</div>';
|
|
2551
2553
|
html += '<div class="hidden-title hide"><table><thead><th part="badge-filtered"><i>not filtered</i></th></thead></table></div>';
|
|
2552
|
-
// html += '<div part="stream-events-event-title" class="stream-events-event-title d-flex align-center pl-5 pb-5">' + '<input id="button-select-' + mmdd.replace('/', '-') + '-' + itemNumber + '-' + (((event.makercheckers != null && (event.makercheckers).length > 0)) ? '1' : '0') + '-' + (((event.docs != null && (event.docs).length > 0)) ? '1' : '0') + '-' + event.entityid.replace(/-/g, '_') + '-' + event.locationid.replace(/-/g, '_') + '-' + event.id.replace(/-/g, '_') + '-' + event.duedate.split('/')[1] + '-' + event.duedate.split('/')[0] + '-' + event.duedate.split('/')[2] + '-' + partStatus.replace(/-/g, '_') + '-' + ((event.module ?? false) ? event.module : 'compliance') + '-' + ((event.isbulk == null || event.isbulk == false) ? "" : "bulk") + (((event.reportformat != null && event.reportformat.length > 0) || (event.isbulk != null && event.isbulk == true) || (event.customreporting != null)) ? "reportformat" : "") + '" class="button-select mr-10 ' + (((event.reportformat != null && event.reportformat.length > 0) || (event.isbulk != null && event.isbulk == true) || (event.customreporting != null)) ? 'hide' : '') + '" type="checkbox"/>' + (event.isbulk != null && event.isbulk == true ? '<div class="lds-dual-ring1 bulk-loader mr-10"></div>' : '') + '<sf-i-elastic-text class="stream-event-title' + (event.isbulk == null || event.isbulk == false ? ' button-event-title' : '') + '" id="stream-event-title-' + mmdd.replace(/\//g, '-') + '-' + itemNumber + '-' + ((event.module ?? false) ? event.module : 'compliance') + '" text="' + event['obligationtitle'] + '" minLength="' + (event.concise == null ? "100" : "60") + '"></sf-i-elastic-text>' + event.concise == null ? ('') : ('<div part="stream-event-location" class="stream-event-location ml-5">' + event.locationname.replace(/ *\([^)]*\) */g, "") + '</div><div part="stream-event-risk-' + event.risk[0].toLowerCase().replace(/ /g, '-') + '" class="stream-event-risk ml-5">' + event.risk[0] + '</div>') + (((event.reportformat != null && event.reportformat.length > 0) || (event.customreporting != null)) ? '' : ('<button id="button-list-reporting-' + mmdd.replace('/', '-') + '-' + itemNumber + '" part="button-list-reporting" class="material-icons ml-10 button-list-reporting">edit_note</button>')) + ((event.concise == null && lastUpdated.length > 0) ? (' <div part="event-last-updated-time" class="d-flex align-center">' + lastUpdated + '</div>') : "") + '</div>';
|
|
2554
|
+
// html += '<div part="stream-events-event-title" class="stream-events-event-title d-flex align-center pl-5 pb-5">' + '<input id="button-select-' + mmdd.replace('/', '-') + '-' + itemNumber + '-' + (((event.makercheckers != null && (event.makercheckers).length > 0)) ? '1' : '0') + '-' + (((event.docs != null && (event.docs).length > 0)) ? '1' : '0') + '-' + event.entityid.replace(/-/g, '_') + '-' + event.locationid.replace(/-/g, '_') + '-' + event.id.replace(/-/g, '_') + '-' + event.duedate.split('/')[1] + '-' + event.duedate.split('/')[0] + '-' + event.duedate.split('/')[2] + '-' + partStatus.replace(/-/g, '_') + '-' + ((event.module ?? false) ? event.module : 'compliance') + '-' + ((event.isbulk == null || event.isbulk == false) ? "" : "bulk") + (((event.reportformat != null && event.reportformat.length > 0) || (event.isbulk != null && event.isbulk == true) || (event.customreporting != null)) ? "reportformat" : "") + '" class="button-select mr-10 ' + (((event.reportformat != null && event.reportformat.length > 0) || (event.isbulk != null && event.isbulk == true) || (event.customreporting != null)) ? 'hide' : '') + '" type="checkbox"/>' + (event.isbulk != null && event.isbulk == true ? '<div class="lds-dual-ring1 bulk-loader mr-10"></div>' : '') + '<sf-i-elastic-text exportparts="highlight,highlight-count" class="stream-event-title' + (event.isbulk == null || event.isbulk == false ? ' button-event-title' : '') + '" id="stream-event-title-' + mmdd.replace(/\//g, '-') + '-' + itemNumber + '-' + ((event.module ?? false) ? event.module : 'compliance') + '" text="' + event['obligationtitle'] + '" minLength="' + (event.concise == null ? "100" : "60") + '"></sf-i-elastic-text>' + event.concise == null ? ('') : ('<div part="stream-event-location" class="stream-event-location ml-5">' + event.locationname.replace(/ *\([^)]*\) */g, "") + '</div><div part="stream-event-risk-' + event.risk[0].toLowerCase().replace(/ /g, '-') + '" class="stream-event-risk ml-5">' + event.risk[0] + '</div>') + (((event.reportformat != null && event.reportformat.length > 0) || (event.customreporting != null)) ? '' : ('<button id="button-list-reporting-' + mmdd.replace('/', '-') + '-' + itemNumber + '" part="button-list-reporting" class="material-icons ml-10 button-list-reporting">edit_note</button>')) + ((event.concise == null && lastUpdated.length > 0) ? (' <div part="event-last-updated-time" class="d-flex align-center">' + lastUpdated + '</div>') : "") + '</div>';
|
|
2553
2555
|
const isBulk = event.isbulk === true;
|
|
2554
2556
|
const hasReportFormat = ((_a = event.reportformat) === null || _a === void 0 ? void 0 : _a.length) > 0;
|
|
2555
2557
|
const hasCustomReporting = event.customreporting != null;
|
|
@@ -2579,7 +2581,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
2579
2581
|
/>
|
|
2580
2582
|
${isBulk ? '<div class="lds-dual-ring1 bulk-loader mr-10"></div>' : ''}
|
|
2581
2583
|
${isReportedLocation ? '<div class="material-symbols-outlined mr-10">arrow_or_edge</div>' : ''}
|
|
2582
|
-
<sf-i-elastic-text
|
|
2584
|
+
<sf-i-elastic-text exportparts="highlight,highlight-count"
|
|
2583
2585
|
class="stream-event-title${!isBulk ? ' button-event-title' : ''}"
|
|
2584
2586
|
id="stream-event-title-${mmddSanitized}-${itemNumber}-${moduleType}-${(isReportedLocation) ? 'reportedlocations' : ''}"
|
|
2585
2587
|
text="${event.obligationtitle}"
|
|
@@ -2738,13 +2740,13 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
2738
2740
|
html += this.renderStatusHtml(partStatus, lateStatus, complianceStatus, i);
|
|
2739
2741
|
html += '</td>';
|
|
2740
2742
|
if (event["locationname"] != null) {
|
|
2741
|
-
html += '<td part="td-body"><sf-i-elastic-text text="' + event["locationname"].replace(/ *\([^)]*\) */g, "") + '" minLength="10"></sf-i-elastic-text></td>';
|
|
2743
|
+
html += '<td part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + event["locationname"].replace(/ *\([^)]*\) */g, "") + '" minLength="10"></sf-i-elastic-text></td>';
|
|
2742
2744
|
}
|
|
2743
2745
|
if (event["entityname"] != null) {
|
|
2744
|
-
html += '<td part="td-body"><sf-i-elastic-text text="' + event["entityname"].replace(/ *\([^)]*\) */g, "") + '" minLength="10"></sf-i-elastic-text></td>';
|
|
2746
|
+
html += '<td part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + event["entityname"].replace(/ *\([^)]*\) */g, "") + '" minLength="10"></sf-i-elastic-text></td>';
|
|
2745
2747
|
}
|
|
2746
2748
|
if (event["countryname"] != null) {
|
|
2747
|
-
html += '<td part="td-body"><sf-i-elastic-text text="' + event["countryname"].replace(/ *\([^)]*\) */g, "") + '" minLength="10"></sf-i-elastic-text></td>';
|
|
2749
|
+
html += '<td part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + event["countryname"].replace(/ *\([^)]*\) */g, "") + '" minLength="10"></sf-i-elastic-text></td>';
|
|
2748
2750
|
}
|
|
2749
2751
|
if (event["functions"] != null) {
|
|
2750
2752
|
var functions = '';
|
|
@@ -2752,7 +2754,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
2752
2754
|
functions += (element.split(';')[0].replace(/ *\([^)]*\) */g, "") + ",");
|
|
2753
2755
|
}
|
|
2754
2756
|
functions = functions.replace(/,\s*$/, "");
|
|
2755
|
-
html += '<td part="td-body"><sf-i-elastic-text text="' + functions + '" minLength="10"></sf-i-elastic-text></td>';
|
|
2757
|
+
html += '<td part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + functions + '" minLength="10"></sf-i-elastic-text></td>';
|
|
2756
2758
|
}
|
|
2757
2759
|
if (event["risk"] != null) {
|
|
2758
2760
|
html += '<td part="td-body"><div part="nc-stream-event-risk-' + event["risk"][0].toLowerCase().replace(/ /g, '-') + '">' + event["risk"][0] + '</div></td>';
|
|
@@ -2764,7 +2766,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
2764
2766
|
html += this.getEventTexts(Object.keys(event)[k], JSON.parse(event[Object.keys(event)[k]]), event);
|
|
2765
2767
|
}
|
|
2766
2768
|
else {
|
|
2767
|
-
html += ' <sf-i-elastic-text text="' + event[Object.keys(event)[k]].replace(/"/g, "") + '" minLength="20"></sf-i-elastic-text>';
|
|
2769
|
+
html += ' <sf-i-elastic-text exportparts="highlight,highlight-count" text="' + event[Object.keys(event)[k]].replace(/"/g, "") + '" minLength="20"></sf-i-elastic-text>';
|
|
2768
2770
|
}
|
|
2769
2771
|
html += '</td>';
|
|
2770
2772
|
}
|
|
@@ -2893,7 +2895,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
2893
2895
|
let approverStr = event.concise == null ? this.getApproverStringFromEvent(event) : "";
|
|
2894
2896
|
let graphParam = this.getGraphParam(event);
|
|
2895
2897
|
// console.log("graphParam", graphParam.split(';')[0]);
|
|
2896
|
-
html += '<div class="d-flex align-center event-user-labels-container"><div part="badge-filter-name" class="graphparamname graphparamname1 mb-20' + (event.concise == null ? "" : ' hide') + '">' + graphParam.split(';')[0] + '</div>' + reporterStr + approverStr + ((event.concise == null && ((event.reportformat == null || event.reportformat.length == 0) && (event.customreporting == null) && (event.reportedlocationsflag != true))) ? ('<button id="button-list-reporting-' + mmdd.replace('/', '-') + '-' + j + '" part="button-list-reporting" class="material-icons ml-10 mb-20 button-list-reporting">edit_note</button>') : '') + '</div>';
|
|
2898
|
+
html += '<div class="d-flex align-center event-user-labels-container"><div part="badge-filter-name" class="graphparamname graphparamname1 mb-20' + (event.concise == null ? "" : ' hide') + '">' + graphParam.split(';')[0] + '</div>' + reporterStr + approverStr + ((event.concise == null && ((event.reportformat == null || event.reportformat.length == 0) && (event.customreporting == null) && (event.reportedlocationsflag != true))) ? ('<button id="button-list-reporting-' + mmdd.replace('/', '-') + '-' + j + '-" part="button-list-reporting" class="material-icons ml-10 mb-20 button-list-reporting">edit_note</button>') : '') + '</div>';
|
|
2897
2899
|
// }
|
|
2898
2900
|
return html;
|
|
2899
2901
|
};
|
|
@@ -3206,9 +3208,9 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
3206
3208
|
+ '</tr>');
|
|
3207
3209
|
}
|
|
3208
3210
|
if (this.selectedFeatures.indexOf('contracts') >= 0) {
|
|
3209
|
-
htmlSummaryValues += ('<tr><td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-thin"><sf-i-elastic-text text="' + this.events[mmdd][j]["id"] + '" minLength="10"></sf-i-elastic-text></td>'
|
|
3210
|
-
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text text="' + this.events[mmdd][j]["obligationtitle"] + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3211
|
-
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text text="' + this.renderStatusString(partStatus, lateStatus, complianceStatus) + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3211
|
+
htmlSummaryValues += ('<tr><td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-thin"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.events[mmdd][j]["id"] + '" minLength="10"></sf-i-elastic-text></td>'
|
|
3212
|
+
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.events[mmdd][j]["obligationtitle"] + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3213
|
+
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.renderStatusString(partStatus, lateStatus, complianceStatus) + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3212
3214
|
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide">');
|
|
3213
3215
|
for (let document of (_44 = this.events[mmdd][j].contractdocuments) !== null && _44 !== void 0 ? _44 : []) {
|
|
3214
3216
|
htmlSummaryValues += `<sf-i-uploader class="summary-report-doc" max="10" apiid="1peg5170d3" allowedextensions="["jpg","png","pdf","xls","xlsx","doc","docx"]" prepopulatedInputArr="${JSON.stringify([{ "key": document.key, "ext": document.ext }]).replace(/"/g, '"')}" projectid="${this.projectId} " extract="no" mode="view" maximize="yes" hidepreview="yes"></sf-i-uploader><br />`;
|
|
@@ -3216,9 +3218,9 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
3216
3218
|
htmlSummaryValues += '</td></tr>';
|
|
3217
3219
|
}
|
|
3218
3220
|
else if (this.selectedFeatures.indexOf('licenses') >= 0) {
|
|
3219
|
-
htmlSummaryValues += ('<tr><td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-thin"><sf-i-elastic-text text="' + this.events[mmdd][j]["id"] + '" minLength="10"></sf-i-elastic-text></td>'
|
|
3220
|
-
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text text="' + this.events[mmdd][j]["obligationtitle"] + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3221
|
-
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text text="' + this.renderStatusString(partStatus, lateStatus, complianceStatus) + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3221
|
+
htmlSummaryValues += ('<tr><td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-thin"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.events[mmdd][j]["id"] + '" minLength="10"></sf-i-elastic-text></td>'
|
|
3222
|
+
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.events[mmdd][j]["obligationtitle"] + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3223
|
+
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.renderStatusString(partStatus, lateStatus, complianceStatus) + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3222
3224
|
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide">');
|
|
3223
3225
|
for (let document of (_45 = this.events[mmdd][j].licensedocuments) !== null && _45 !== void 0 ? _45 : []) {
|
|
3224
3226
|
htmlSummaryValues += `<sf-i-uploader class="summary-report-doc" max="10" apiid="1peg5170d3" allowedextensions="["jpg","png","pdf","xls","xlsx","doc","docx"]" prepopulatedInputArr="${JSON.stringify([{ "key": document.key, "ext": document.ext }]).replace(/"/g, '"')}" projectid="${this.projectId} " extract="no" mode="view" maximize="yes" hidepreview="yes"></sf-i-uploader><br />`;
|
|
@@ -3226,16 +3228,16 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
3226
3228
|
htmlSummaryValues += '</td></tr>';
|
|
3227
3229
|
}
|
|
3228
3230
|
else if (this.selectedFeatures.indexOf('rcmresources') >= 0) {
|
|
3229
|
-
htmlSummaryValues += ('<tr><td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-thin"><sf-i-elastic-text text="' + this.events[mmdd][j]["id"] + '" minLength="10"></sf-i-elastic-text></td>'
|
|
3230
|
-
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text text="' + this.events[mmdd][j]["obligationtitle"] + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3231
|
-
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text text="' + this.renderStatusString(partStatus, lateStatus, complianceStatus) + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3232
|
-
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text text="' + this.events[mmdd][j]["url"] + '" minLength="100" lineSize="4"></sf-i-elastic-text></td></tr>');
|
|
3231
|
+
htmlSummaryValues += ('<tr><td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-thin"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.events[mmdd][j]["id"] + '" minLength="10"></sf-i-elastic-text></td>'
|
|
3232
|
+
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.events[mmdd][j]["obligationtitle"] + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3233
|
+
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.renderStatusString(partStatus, lateStatus, complianceStatus) + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3234
|
+
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.events[mmdd][j]["url"] + '" minLength="100" lineSize="4"></sf-i-elastic-text></td></tr>');
|
|
3233
3235
|
}
|
|
3234
3236
|
else {
|
|
3235
|
-
htmlSummaryValues += ('<tr><td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-thin"><sf-i-elastic-text text="' + this.events[mmdd][j]["id"] + '" minLength="10"></sf-i-elastic-text></td>'
|
|
3236
|
-
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text text="' + this.events[mmdd][j]["obligationtitle"] + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3237
|
-
// + '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text text="' + this.events[mmdd][j]["obligation"] + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3238
|
-
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text text="' + this.renderStatusString(partStatus, lateStatus, complianceStatus) + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3237
|
+
htmlSummaryValues += ('<tr><td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-thin"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.events[mmdd][j]["id"] + '" minLength="10"></sf-i-elastic-text></td>'
|
|
3238
|
+
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.events[mmdd][j]["obligationtitle"] + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3239
|
+
// + '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.events[mmdd][j]["obligation"] + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3240
|
+
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.renderStatusString(partStatus, lateStatus, complianceStatus) + '" minLength="100" lineSize="4"></sf-i-elastic-text></td>'
|
|
3239
3241
|
+ '<td class="' + (total % 2 === 0 ? 'td-odd' : 'td-even') + ' td-wide">');
|
|
3240
3242
|
for (let document of this.events[mmdd][j].documents) {
|
|
3241
3243
|
htmlSummaryValues += `<sf-i-uploader class="summary-report-doc" max="10" apiid="1peg5170d3" allowedextensions="["jpg","png","pdf","xls","xlsx","doc","docx"]" prepopulatedInputArr="${JSON.stringify([{ "key": document.key, "ext": document.ext }]).replace(/"/g, '"')}" projectid="${this.projectId} " extract="no" mode="view" maximize="yes" hidepreview="yes"></sf-i-uploader><br />`;
|
|
@@ -3640,7 +3642,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
3640
3642
|
else if (uploadGuidance != 0) {
|
|
3641
3643
|
html += '<div part="upload-guidance-content">';
|
|
3642
3644
|
html += '<div part="detail-head" class="mb-5"><strong>Upload Guidance</strong></div>';
|
|
3643
|
-
html += '<sf-i-elastic-text text="' + (event['uploadguidance'] + "").replace(/"/g, "").replace(/\n/g, '<br />') + '" minLength="150"></sf-i-elastic-text>';
|
|
3645
|
+
html += '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + (event['uploadguidance'] + "").replace(/"/g, "").replace(/\n/g, '<br />') + '" minLength="150"></sf-i-elastic-text>';
|
|
3644
3646
|
html += '</div>';
|
|
3645
3647
|
}
|
|
3646
3648
|
html += '<div part="uploader-analysis-message" class="uploader-analysis-message mt-20">The analysis is running in the background. You can proceed further.</div>';
|
|
@@ -3753,8 +3755,8 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
3753
3755
|
const j = idArr[5];
|
|
3754
3756
|
let buttonListReportings = eventsContainer.querySelectorAll('.button-list-reporting');
|
|
3755
3757
|
for (let buttonListReporting of buttonListReportings) {
|
|
3756
|
-
|
|
3757
|
-
|
|
3758
|
+
if (buttonListReporting.id == 'button-list-reporting-' + mmdd.replace(/\//g, '-') + '-' + j + '-') {
|
|
3759
|
+
console.log('buttonListReporting', buttonListReporting.id, 'button-list-reporting-' + mmdd.replace(/\//g, '-') + '-' + j + '-');
|
|
3758
3760
|
buttonListReporting.setAttribute('part', 'button-list-reporting-selected');
|
|
3759
3761
|
}
|
|
3760
3762
|
else {
|
|
@@ -4168,8 +4170,30 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
4168
4170
|
let docs = [];
|
|
4169
4171
|
//console.log('reporter comments 2', reportercomments);
|
|
4170
4172
|
// if(docsOptional.length === 0) {
|
|
4173
|
+
let percentage = "100";
|
|
4174
|
+
if (listReportingContainer.querySelector('#input-reporter-percentage') != null) {
|
|
4175
|
+
percentage = listReportingContainer.querySelector('#input-reporter-percentage').value;
|
|
4176
|
+
}
|
|
4171
4177
|
docs = this._SfUploader[0].querySelector('#uploader').selectedValues();
|
|
4172
4178
|
// }
|
|
4179
|
+
let flag = false;
|
|
4180
|
+
do {
|
|
4181
|
+
if (docs.length > 0 && event.docsOptional != null && event.docsOptional.length === 0 && parseInt(percentage) > 0) {
|
|
4182
|
+
for (let doc of docs) {
|
|
4183
|
+
if ((doc.jobId == null || doc.jobId.length === 0) && (doc.ext.toLowerCase() == 'pdf' || doc.ext.toLowerCase() == 'png' || doc.ext.toLowerCase() == 'jpeg' || doc.ext.toLowerCase() == 'jpg')) {
|
|
4184
|
+
flag = false;
|
|
4185
|
+
}
|
|
4186
|
+
else {
|
|
4187
|
+
flag = true;
|
|
4188
|
+
}
|
|
4189
|
+
}
|
|
4190
|
+
}
|
|
4191
|
+
if (flag === false) {
|
|
4192
|
+
await this.sleep(1000);
|
|
4193
|
+
console.log('waiting for docs', docs);
|
|
4194
|
+
docs = this._SfUploader[0].querySelector('#uploader').selectedValues();
|
|
4195
|
+
}
|
|
4196
|
+
} while (flag === false);
|
|
4173
4197
|
//console.log('docs', docs);
|
|
4174
4198
|
let reportformatvalues = "";
|
|
4175
4199
|
let reportformatschema = "";
|
|
@@ -4177,10 +4201,6 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
4177
4201
|
reportformatvalues = (_a = JSON.stringify(this._SfReporting[0].querySelector('#reporting-format').selectedValues())) !== null && _a !== void 0 ? _a : "";
|
|
4178
4202
|
reportformatschema = (_b = this._SfReporting[0].querySelector('#reporting-format').configjson) !== null && _b !== void 0 ? _b : "";
|
|
4179
4203
|
}
|
|
4180
|
-
let percentage = "100";
|
|
4181
|
-
if (listReportingContainer.querySelector('#input-reporter-percentage') != null) {
|
|
4182
|
-
percentage = listReportingContainer.querySelector('#input-reporter-percentage').value;
|
|
4183
|
-
}
|
|
4184
4204
|
console.log('percentage', percentage, listReportingContainer.querySelector('#input-reporter-percentage').value);
|
|
4185
4205
|
if (Number.isNaN(parseInt(percentage)) || parseInt(percentage) < 0 || parseInt(percentage) > 100) {
|
|
4186
4206
|
//console.log('reporter comments 3', reportercomments);
|
|
@@ -4797,7 +4817,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
4797
4817
|
let listReportingContainer = eventsContainer.querySelector('#list-reporting-container-' + mmdd.replace(/\//g, '-') + '-' + j);
|
|
4798
4818
|
listReportingContainer.style.display = 'none';
|
|
4799
4819
|
listReportingContainer.innerHTML = '';
|
|
4800
|
-
let buttonListReporting = eventsContainer.querySelector('#button-list-reporting-' + mmdd.replace(/\//g, '-') + '-' + j);
|
|
4820
|
+
let buttonListReporting = eventsContainer.querySelector('#button-list-reporting-' + mmdd.replace(/\//g, '-') + '-' + j + '-');
|
|
4801
4821
|
buttonListReporting.setAttribute('part', 'button-list-reporting');
|
|
4802
4822
|
let streamEventTitle = eventsContainer.querySelector('#stream-event-title-' + mmdd.replace(/\//g, '-') + '-' + j + '-' + module);
|
|
4803
4823
|
streamEventTitle.removeAttribute('part');
|
|
@@ -4996,7 +5016,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
4996
5016
|
// html += '<div class="stream-events-container flex-grow">';
|
|
4997
5017
|
// html += '<div class="hidden-tags hide">'+JSON.stringify(this.events[mmdd][j]['tags'])+'</div>'
|
|
4998
5018
|
// html += '<div class="hidden-title hide"><table><thead><th part="badge-filtered"><i>filtered out</i></th></thead></table></div>'
|
|
4999
|
-
// html += '<div part="stream-events-event-title" class="stream-events-event-title d-flex align-center pl-5 pb-5">' + ('<input id="button-select-'+mmdd.replace('/', '-')+'-'+j + '-' + (((this.events[mmdd][j].makercheckers != null && (this.events[mmdd][j].makercheckers).length > 0)) ? '1' : '0') + '-' + (((this.events[mmdd][j].docs != null && (this.events[mmdd][j].docs).length > 0)) ? '1' : '0') + '-' + this.events[mmdd][j].entityid.replace(/-/g, '_') + '-' + this.events[mmdd][j].locationid.replace(/-/g, '_') + '-' + this.events[mmdd][j].id.replace(/-/g, '_') + '-' + this.events[mmdd][j].duedate.split('/')[1] + '-' + this.events[mmdd][j].duedate.split('/')[0] + '-' + this.events[mmdd][j].duedate.split('/')[2] + '-' + partStatus.replace(/-/g,'_') + '" class="button-select mr-10" type="checkbox" />') + '<sf-i-elastic-text text="'+this.events[mmdd][j]['obligationtitle']+'" minLength="100"></sf-i-elastic-text></div>';
|
|
5019
|
+
// html += '<div part="stream-events-event-title" class="stream-events-event-title d-flex align-center pl-5 pb-5">' + ('<input id="button-select-'+mmdd.replace('/', '-')+'-'+j + '-' + (((this.events[mmdd][j].makercheckers != null && (this.events[mmdd][j].makercheckers).length > 0)) ? '1' : '0') + '-' + (((this.events[mmdd][j].docs != null && (this.events[mmdd][j].docs).length > 0)) ? '1' : '0') + '-' + this.events[mmdd][j].entityid.replace(/-/g, '_') + '-' + this.events[mmdd][j].locationid.replace(/-/g, '_') + '-' + this.events[mmdd][j].id.replace(/-/g, '_') + '-' + this.events[mmdd][j].duedate.split('/')[1] + '-' + this.events[mmdd][j].duedate.split('/')[0] + '-' + this.events[mmdd][j].duedate.split('/')[2] + '-' + partStatus.replace(/-/g,'_') + '" class="button-select mr-10" type="checkbox" />') + '<sf-i-elastic-text exportparts="highlight,highlight-count" text="'+this.events[mmdd][j]['obligationtitle']+'" minLength="100"></sf-i-elastic-text></div>';
|
|
5000
5020
|
// html += '<table class="stream-events-container-table">';
|
|
5001
5021
|
// html += '<thead>';
|
|
5002
5022
|
// html += '<th part="td-head">';
|
|
@@ -5150,22 +5170,22 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5150
5170
|
// html += '<td id="td-expand-'+i+'" part="td-body">';
|
|
5151
5171
|
// html += '<button id="button-unmapped-expand-'+mmdd.replace('/', '-')+'-'+j+'" part="button-icon-small" class="material-icons button-expand mr-10">open_in_new</button>'
|
|
5152
5172
|
// html += '</td>';
|
|
5153
|
-
// html += '<td part="td-body"><sf-i-elastic-text text="'+this.events[mmdd][j]["locationname"].replace(/ *\([^)]*\) */g, "")+'" minLength="10"></sf-i-elastic-text></td>';
|
|
5154
|
-
// html += '<td part="td-body"><sf-i-elastic-text text="'+this.events[mmdd][j]["entityname"].replace(/ *\([^)]*\) */g, "")+'" minLength="10"></sf-i-elastic-text></td>';
|
|
5155
|
-
// html += '<td part="td-body"><sf-i-elastic-text text="'+this.events[mmdd][j]["countryname"].replace(/ *\([^)]*\) */g, "")+'" minLength="10"></sf-i-elastic-text></td>';
|
|
5173
|
+
// html += '<td part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="'+this.events[mmdd][j]["locationname"].replace(/ *\([^)]*\) */g, "")+'" minLength="10"></sf-i-elastic-text></td>';
|
|
5174
|
+
// html += '<td part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="'+this.events[mmdd][j]["entityname"].replace(/ *\([^)]*\) */g, "")+'" minLength="10"></sf-i-elastic-text></td>';
|
|
5175
|
+
// html += '<td part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="'+this.events[mmdd][j]["countryname"].replace(/ *\([^)]*\) */g, "")+'" minLength="10"></sf-i-elastic-text></td>';
|
|
5156
5176
|
// var functions = '';
|
|
5157
5177
|
// for(const element of this.events[mmdd][j]["functions"]) {
|
|
5158
5178
|
// functions += (element.split(';')[0].replace(/ *\([^)]*\) */g, "") + ",");
|
|
5159
5179
|
// }
|
|
5160
5180
|
// functions = functions.replace(/,\s*$/, "");
|
|
5161
|
-
// html += '<td part="td-body"><sf-i-elastic-text text="'+functions+'" minLength="10"></sf-i-elastic-text></td>';
|
|
5181
|
+
// html += '<td part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="'+functions+'" minLength="10"></sf-i-elastic-text></td>';
|
|
5162
5182
|
// for(var k = 0; k < Object.keys(this.events[mmdd][j]).length; k++) {
|
|
5163
5183
|
// if(this.getEventPreviewFields().includes(Object.keys(this.events[mmdd][j])[k])) {
|
|
5164
5184
|
// html += '<td part="td-body">';
|
|
5165
5185
|
// if(this.events[mmdd][j][Object.keys(this.events[mmdd][j])[k]].indexOf("[") >= 0) {
|
|
5166
5186
|
// html += this.getEventTexts(Object.keys(this.events[mmdd][j])[k], JSON.parse(this.events[mmdd][j][Object.keys(this.events[mmdd][j])[k]]), this.events[mmdd][j]);
|
|
5167
5187
|
// } else {
|
|
5168
|
-
// html += ' <sf-i-elastic-text text="'+this.events[mmdd][j][Object.keys(this.events[mmdd][j])[k]].replace(/"/g, "")+'" minLength="20"></sf-i-elastic-text>';
|
|
5188
|
+
// html += ' <sf-i-elastic-text exportparts="highlight,highlight-count" text="'+this.events[mmdd][j][Object.keys(this.events[mmdd][j])[k]].replace(/"/g, "")+'" minLength="20"></sf-i-elastic-text>';
|
|
5169
5189
|
// }
|
|
5170
5190
|
// html += '</td>';
|
|
5171
5191
|
// }
|
|
@@ -5594,9 +5614,11 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5594
5614
|
});
|
|
5595
5615
|
return [buttonSelectAll, buttonUnselectAll];
|
|
5596
5616
|
};
|
|
5597
|
-
this.renderRegisterEvents = (events, meta = "") => {
|
|
5617
|
+
this.renderRegisterEvents = (events, meta = "", searchCountryIndex = -1, searchIndex = -1, searchVal = "") => {
|
|
5618
|
+
var _a;
|
|
5598
5619
|
var html = '';
|
|
5599
5620
|
this.csvDataRegisters = '';
|
|
5621
|
+
let flagUpdateFilters = Object.keys(this.registerFilters).length == 0;
|
|
5600
5622
|
html += '<div class="d-flex scroll-x w-100p">';
|
|
5601
5623
|
for (var i = 0; i < Object.keys(events).length; i++) {
|
|
5602
5624
|
const country = Object.keys(events)[i];
|
|
@@ -5616,6 +5638,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5616
5638
|
this.renderRegisterEvents(events);
|
|
5617
5639
|
});
|
|
5618
5640
|
}
|
|
5641
|
+
this.tablecols = [];
|
|
5619
5642
|
if (this.selectedCountryTab >= 0) {
|
|
5620
5643
|
const index = this.selectedCountryTab;
|
|
5621
5644
|
//console.log('indexclicked', index);
|
|
@@ -5641,29 +5664,64 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5641
5664
|
this.csvDataRegisters += ('\n');
|
|
5642
5665
|
}
|
|
5643
5666
|
html += '<div class="w-100p scroll-x ' + (i != this.selectedRegisterIndex ? 'hide' : '') + ' register-body-' + i + '">';
|
|
5667
|
+
html += '<div class="d-flex align-end">';
|
|
5668
|
+
html += '<div class="title-item-date">';
|
|
5669
|
+
html += '<label part="input-label">Search In Statute</label><br />';
|
|
5670
|
+
html += '<input id="stream-search-statute-' + index + '-' + i + '" class="stream-search-statute" part="input" type="text" value="' + ((searchCountryIndex == index && searchIndex == i) ? searchVal : "") + '"/>';
|
|
5671
|
+
html += '</div>';
|
|
5672
|
+
html += '<div class="title-item-date">';
|
|
5673
|
+
html += '<button id="button-download-statute-' + index + '-' + i + '" part="button" class="button-download-statute d-flex justify-center align-center ml-10"><span class="material-symbols-outlined">download</span> <span>Export</span></button>';
|
|
5674
|
+
html += '</div>';
|
|
5675
|
+
html += '</div>';
|
|
5644
5676
|
html += '<table>';
|
|
5645
|
-
let
|
|
5677
|
+
let tableBodyHtml = '';
|
|
5646
5678
|
for (var j = 0; j < Object.keys(objCountry[statute]).length; j++) {
|
|
5647
5679
|
const complianceId = Object.keys(objCountry[statute])[j];
|
|
5648
5680
|
const compliance = objCountry[statute][complianceId];
|
|
5681
|
+
console.log('hidecompliances', compliance.hide, complianceId);
|
|
5649
5682
|
const data = JSON.parse(compliance.data);
|
|
5650
5683
|
const cols = JSON.parse(compliance.cols);
|
|
5684
|
+
if (!this.tablecols.includes('ID') && !this.EXCLUDE_COLS_FROM_REGS.includes('ID')) {
|
|
5685
|
+
this.tablecols.push('ID');
|
|
5686
|
+
}
|
|
5651
5687
|
for (let col of cols) {
|
|
5652
|
-
if (!tablecols.includes(col.toLowerCase()) && !this.EXCLUDE_COLS_FROM_REGS.includes(col.toLowerCase())) {
|
|
5653
|
-
tablecols.push(col);
|
|
5688
|
+
if (!this.tablecols.includes(col.toLowerCase()) && !this.EXCLUDE_COLS_FROM_REGS.includes(col.toLowerCase())) {
|
|
5689
|
+
this.tablecols.push(col);
|
|
5690
|
+
if (flagUpdateFilters && this.registerFilters[col] == null) {
|
|
5691
|
+
this.registerFilters[col] = {};
|
|
5692
|
+
}
|
|
5654
5693
|
}
|
|
5655
5694
|
}
|
|
5695
|
+
if (compliance.hide != null && compliance.hide == true) {
|
|
5696
|
+
continue;
|
|
5697
|
+
}
|
|
5656
5698
|
this.csvDataRegisters += ('"' + complianceId + '",');
|
|
5657
5699
|
// html += '<div class="w-100p scroll-x ' + (i != this.selectedRegisterIndex ? 'hide' : '') + ' register-body-' + i + '">';
|
|
5658
5700
|
// html += '<table>';
|
|
5659
|
-
|
|
5660
|
-
|
|
5661
|
-
|
|
5701
|
+
tableBodyHtml += '<tr>';
|
|
5702
|
+
tableBodyHtml += ('<td class="td-body left-sticky" part="td-body-register"><button part="button-icon" id="button-icon-country-' + index + '-' + i + '-' + j + '" class="button-icon-country"><span class="material-symbols-outlined">open_in_new</span></button></td>');
|
|
5703
|
+
if (flagUpdateFilters) {
|
|
5704
|
+
if (this.registerFilters["ID"] == null) {
|
|
5705
|
+
this.registerFilters["ID"] = {};
|
|
5706
|
+
}
|
|
5707
|
+
this.registerFilters["ID"][complianceId] = true;
|
|
5708
|
+
}
|
|
5709
|
+
tableBodyHtml += ('<td class="td-body" part="td-body-register"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + complianceId + '" highlight="' + searchVal + '" minLength="10" lineSize="4"></sf-i-elastic-text></td>');
|
|
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>');
|
|
5711
|
+
let tempCount = 0;
|
|
5662
5712
|
for (var k = 0; k < cols.length; k++) {
|
|
5663
|
-
if (!this.EXCLUDE_COLS_FROM_REGS.includes(cols[k].toLowerCase())) {
|
|
5664
|
-
|
|
5713
|
+
if (!this.EXCLUDE_COLS_FROM_REGS.includes(cols[k].toLowerCase()) && this.tablecols.indexOf(cols[k]) == tempCount + 1) {
|
|
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>');
|
|
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>');
|
|
5665
5716
|
this.csvDataRegisters += ('"' + (data[k] + "").replace(/"/g, '') + '",');
|
|
5666
5717
|
// this.csvDataRegisters += ('",');
|
|
5718
|
+
if (flagUpdateFilters) {
|
|
5719
|
+
this.registerFilters[cols[k]][data[k]] = true;
|
|
5720
|
+
}
|
|
5721
|
+
tempCount++;
|
|
5722
|
+
}
|
|
5723
|
+
else {
|
|
5724
|
+
console.log('skipping col', cols[k], this.tablecols.indexOf(cols[k]), k + 1);
|
|
5667
5725
|
}
|
|
5668
5726
|
}
|
|
5669
5727
|
if (compliance['entities'] != null && Array.isArray(compliance['entities'])) {
|
|
@@ -5672,7 +5730,16 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5672
5730
|
entities += entity.split(';')[0].replace(/\([^)]*\)/g, "") + ',';
|
|
5673
5731
|
}
|
|
5674
5732
|
entities = entities.slice(0, entities.length - 1);
|
|
5675
|
-
|
|
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>');
|
|
5734
|
+
if (!this.tablecols.includes('entities') && !this.EXCLUDE_COLS_FROM_REGS.includes('entities')) {
|
|
5735
|
+
this.tablecols.push('entities');
|
|
5736
|
+
}
|
|
5737
|
+
if (flagUpdateFilters) {
|
|
5738
|
+
if (this.registerFilters["entities"] == null) {
|
|
5739
|
+
this.registerFilters["entities"] = {};
|
|
5740
|
+
}
|
|
5741
|
+
this.registerFilters["entities"][entities] = true;
|
|
5742
|
+
}
|
|
5676
5743
|
// this.csvDataRegisters += ('"' + (data[k] + "").replace(/"/g, '') + '",');
|
|
5677
5744
|
}
|
|
5678
5745
|
if (compliance['locations'] != null && Array.isArray(compliance['locations'])) {
|
|
@@ -5681,23 +5748,54 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5681
5748
|
locations += location.split(';')[0].replace(/\([^)]*\)/g, "") + ',';
|
|
5682
5749
|
}
|
|
5683
5750
|
locations = locations.slice(0, locations.length - 1);
|
|
5684
|
-
|
|
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>');
|
|
5752
|
+
if (!this.tablecols.includes('locations') && !this.EXCLUDE_COLS_FROM_REGS.includes('locations')) {
|
|
5753
|
+
this.tablecols.push('locations');
|
|
5754
|
+
}
|
|
5755
|
+
if (flagUpdateFilters) {
|
|
5756
|
+
if (this.registerFilters["locations"] == null) {
|
|
5757
|
+
this.registerFilters["locations"] = {};
|
|
5758
|
+
}
|
|
5759
|
+
this.registerFilters["locations"][locations] = true;
|
|
5760
|
+
}
|
|
5685
5761
|
// this.csvDataRegisters += ('"' + (data[k] + "").replace(/"/g, '') + '",');
|
|
5686
5762
|
}
|
|
5687
5763
|
this.csvDataRegisters = this.csvDataRegisters.replace(/,\s*$/, "");
|
|
5688
5764
|
this.csvDataRegisters += ('\n');
|
|
5689
5765
|
console.log('enter');
|
|
5690
|
-
|
|
5766
|
+
tableBodyHtml += '</tr>';
|
|
5691
5767
|
// html += '</table>';
|
|
5692
5768
|
// html += '</div>';
|
|
5693
5769
|
}
|
|
5770
|
+
html += '<thead><tr>';
|
|
5771
|
+
html += '<th class="td-body" part="td-body-register"><span part="td-head" style="padding-left: 0px !important"></span></th>';
|
|
5772
|
+
for (let colName of this.tablecols) {
|
|
5773
|
+
let allSelected = true;
|
|
5774
|
+
for (let subfilterObj of Object.keys((_a = this.registerFilters[colName]) !== null && _a !== void 0 ? _a : {})) {
|
|
5775
|
+
if (this.registerFilters[colName][subfilterObj] == false) {
|
|
5776
|
+
allSelected = false;
|
|
5777
|
+
break;
|
|
5778
|
+
}
|
|
5779
|
+
}
|
|
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>`;
|
|
5783
|
+
for (let [index, filterKey] of Object.keys(this.registerFilters[colName]).entries()) {
|
|
5784
|
+
console.log('rendering filter', filterKey);
|
|
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>`;
|
|
5786
|
+
}
|
|
5787
|
+
html += '</div></div></th>';
|
|
5788
|
+
}
|
|
5789
|
+
html += '</tr></thead>';
|
|
5790
|
+
html += tableBodyHtml;
|
|
5694
5791
|
html += '</table>';
|
|
5695
5792
|
html += '</div>';
|
|
5696
5793
|
// html += '</table>';
|
|
5697
5794
|
// html += '</div>';
|
|
5698
5795
|
}
|
|
5699
5796
|
divRegisterList.innerHTML = html;
|
|
5700
|
-
console.log('
|
|
5797
|
+
console.log('registerFilters', flagUpdateFilters, this.registerFilters);
|
|
5798
|
+
// console.log('csvdataregisters', this.csvDataRegisters);
|
|
5701
5799
|
const arrButtonCountries = this._SfRegisterContainer.querySelector('.calendar-right-data-register').querySelectorAll('.button-icon-country');
|
|
5702
5800
|
for (i = 0; i < arrButtonCountries.length; i++) {
|
|
5703
5801
|
const button = Util.clearListeners(arrButtonCountries[i]);
|
|
@@ -5746,6 +5844,122 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5746
5844
|
// }
|
|
5747
5845
|
});
|
|
5748
5846
|
}
|
|
5847
|
+
const arrInputStatuteSearch = this._SfRegisterContainer.querySelector('.calendar-right-data-register').querySelectorAll('.stream-search-statute');
|
|
5848
|
+
for (i = 0; i < arrInputStatuteSearch.length; i++) {
|
|
5849
|
+
const input = Util.clearListeners(arrInputStatuteSearch[i]);
|
|
5850
|
+
input.addEventListener('change', (e) => {
|
|
5851
|
+
const searchedValue = e.currentTarget.value;
|
|
5852
|
+
const countryIndex = e.currentTarget.id.split('-')[3];
|
|
5853
|
+
const searchIndex = e.currentTarget.id.split('-')[4];
|
|
5854
|
+
// const objCountry = events[Object.keys(events)[countryIndex]]
|
|
5855
|
+
// const statute = Object.keys(objCountry)[searchIndex];
|
|
5856
|
+
// for (var j = 0; j < Object.keys(objCountry[statute]).length; j++) {
|
|
5857
|
+
// const complianceId = Object.keys(objCountry[statute])[j];
|
|
5858
|
+
// const compliance = objCountry[statute][complianceId];
|
|
5859
|
+
// if (JSON.stringify(compliance).toLowerCase().includes(searchedValue.toLowerCase())) {
|
|
5860
|
+
// events[Object.keys(events)[countryIndex]][statute][complianceId].hide = false;
|
|
5861
|
+
// } else {
|
|
5862
|
+
// events[Object.keys(events)[countryIndex]][statute][complianceId].hide = true;
|
|
5863
|
+
// }
|
|
5864
|
+
// }
|
|
5865
|
+
this.processRegisterFilters(events, meta, countryIndex, searchIndex, searchedValue);
|
|
5866
|
+
// this.renderRegisterEvents(events, meta, countryIndex, searchIndex, searchedValue);
|
|
5867
|
+
});
|
|
5868
|
+
}
|
|
5869
|
+
const arrButtonDownloadStatute = this._SfRegisterContainer.querySelector('.calendar-right-data-register').querySelectorAll('.button-download-statute');
|
|
5870
|
+
for (i = 0; i < arrButtonDownloadStatute.length; i++) {
|
|
5871
|
+
const button = Util.clearListeners(arrButtonDownloadStatute[i]);
|
|
5872
|
+
button.addEventListener('click', (e) => {
|
|
5873
|
+
const countryIndex = e.currentTarget.id.split('-')[3];
|
|
5874
|
+
const searchIndex = e.currentTarget.id.split('-')[4];
|
|
5875
|
+
const objCountry = events[Object.keys(events)[countryIndex]];
|
|
5876
|
+
const statute = Object.keys(objCountry)[searchIndex];
|
|
5877
|
+
let csvData = '"ID","Country","Entities","Locations","Statute","Reference","Obligation"\n';
|
|
5878
|
+
for (var j = 0; j < Object.keys(objCountry[statute]).length; j++) {
|
|
5879
|
+
const complianceId = Object.keys(objCountry[statute])[j];
|
|
5880
|
+
const compliance = objCountry[statute][complianceId];
|
|
5881
|
+
console.log('hidecompliances', compliance.hide, complianceId);
|
|
5882
|
+
if (compliance.hide != null && compliance.hide == true) {
|
|
5883
|
+
continue;
|
|
5884
|
+
}
|
|
5885
|
+
const data = JSON.parse(compliance.data);
|
|
5886
|
+
const cols = JSON.parse(compliance.cols);
|
|
5887
|
+
csvData += ('"' + complianceId + '",');
|
|
5888
|
+
csvData += ('"' + Object.keys(events)[countryIndex] + '",');
|
|
5889
|
+
csvData += ('"' + (compliance['entities'] != null && Array.isArray(compliance['entities']) ? compliance['entities'].map((e) => e.split(';')[0].replace(/\([^)]*\)/g, "")).join(',') : '') + '",');
|
|
5890
|
+
csvData += ('"' + (compliance['locations'] != null && Array.isArray(compliance['locations']) ? compliance['locations'].map((e) => e.split(';')[0].replace(/\([^)]*\)/g, "")).join(',') : '') + '",');
|
|
5891
|
+
csvData += ('"' + statute + '",');
|
|
5892
|
+
csvData += ('"' + data[cols.indexOf('reference')] + '",');
|
|
5893
|
+
csvData += ('"' + data[cols.indexOf('obligation')] + '"\n');
|
|
5894
|
+
}
|
|
5895
|
+
console.log('csvData', csvData);
|
|
5896
|
+
const ts = new Date();
|
|
5897
|
+
let fileName = 'register_' + statute.replace(/ /g, '_').slice(0, 25) + '_' + ts + '.xlsx';
|
|
5898
|
+
Util.downloadExcelFromCSV(csvData, fileName, "Register Export", this.projectName);
|
|
5899
|
+
});
|
|
5900
|
+
}
|
|
5901
|
+
const arrFilterButtons = this._SfRegisterContainer.querySelector('.calendar-right-data-register').querySelectorAll('.filter-button');
|
|
5902
|
+
for (i = 0; i < arrFilterButtons.length; i++) {
|
|
5903
|
+
const button = Util.clearListeners(arrFilterButtons[i]);
|
|
5904
|
+
button.addEventListener('click', (e) => {
|
|
5905
|
+
const index = e.currentTarget.id.split('-')[2];
|
|
5906
|
+
let filterListContainer = this._SfRegisterContainer.querySelector('.calendar-right-data-register').querySelector('#filter-list-container-' + index);
|
|
5907
|
+
if (filterListContainer != null) {
|
|
5908
|
+
if (filterListContainer.classList.contains('hide')) {
|
|
5909
|
+
filterListContainer.classList.remove('hide');
|
|
5910
|
+
}
|
|
5911
|
+
else {
|
|
5912
|
+
filterListContainer.classList.add('hide');
|
|
5913
|
+
}
|
|
5914
|
+
}
|
|
5915
|
+
});
|
|
5916
|
+
}
|
|
5917
|
+
const arrFilterInputs = this._SfRegisterContainer.querySelector('.calendar-right-data-register').querySelectorAll('.input-select-filter');
|
|
5918
|
+
for (i = 0; i < arrFilterInputs.length; i++) {
|
|
5919
|
+
const input = Util.clearListeners(arrFilterInputs[i]);
|
|
5920
|
+
input.addEventListener('change', (e) => {
|
|
5921
|
+
let checked = e.currentTarget.checked;
|
|
5922
|
+
let selectedColIndex = e.currentTarget.id.split('-')[3];
|
|
5923
|
+
let selectedFilterIndex = e.currentTarget.id.split('-')[4];
|
|
5924
|
+
let colName = this.tablecols[selectedColIndex];
|
|
5925
|
+
// for (let [colIndex, colName] of Object.keys(this.registerFilters).entries()) {
|
|
5926
|
+
if (colName != null) {
|
|
5927
|
+
for (let [filterIndex, filterKey] of Object.keys(this.registerFilters[colName]).entries()) {
|
|
5928
|
+
if (filterIndex == parseInt(selectedFilterIndex) || selectedFilterIndex == 'all') {
|
|
5929
|
+
this.registerFilters[colName][filterKey] = checked;
|
|
5930
|
+
console.log('registerFilters entry', this.registerFilters[colName][filterKey], colName, filterKey);
|
|
5931
|
+
}
|
|
5932
|
+
if (selectedFilterIndex == 'all') {
|
|
5933
|
+
this._SfRegisterContainer.querySelector('.calendar-right-data-register').querySelector('#input-select-filter-' + selectedColIndex + '-' + filterIndex).checked = checked;
|
|
5934
|
+
}
|
|
5935
|
+
}
|
|
5936
|
+
if (!checked) {
|
|
5937
|
+
this._SfRegisterContainer.querySelector('.calendar-right-data-register').querySelector('#input-select-filter-' + selectedColIndex + '-all').checked = checked;
|
|
5938
|
+
}
|
|
5939
|
+
if (selectedFilterIndex == 'all') {
|
|
5940
|
+
for (let [filterIndex, filterKey] of Object.keys(this.registerFilters[colName]).entries()) {
|
|
5941
|
+
this._SfRegisterContainer.querySelector('.calendar-right-data-register').querySelector('#input-select-filter-' + selectedColIndex + '-' + filterIndex).checked = checked;
|
|
5942
|
+
console.log('Changing Key', filterKey);
|
|
5943
|
+
}
|
|
5944
|
+
}
|
|
5945
|
+
}
|
|
5946
|
+
// }
|
|
5947
|
+
// this.processRegisterFilters(events, meta, searchCountryIndex, searchIndex, searchVal);
|
|
5948
|
+
const buttonSubmitFilters = this._SfRegisterContainer.querySelector('.calendar-right-data-register').querySelector('#button-submit-filters-' + selectedColIndex);
|
|
5949
|
+
if (buttonSubmitFilters != null) {
|
|
5950
|
+
buttonSubmitFilters.style.visibility = 'visible';
|
|
5951
|
+
}
|
|
5952
|
+
console.log('registerFilters applying', colName, selectedFilterIndex, this.tablecols);
|
|
5953
|
+
});
|
|
5954
|
+
}
|
|
5955
|
+
const arrButtonSubmitFilters = this._SfRegisterContainer.querySelector('.calendar-right-data-register').querySelectorAll('.button-submit-filters');
|
|
5956
|
+
for (i = 0; i < arrButtonSubmitFilters.length; i++) {
|
|
5957
|
+
const button = Util.clearListeners(arrButtonSubmitFilters[i]);
|
|
5958
|
+
button.addEventListener('click', (e) => {
|
|
5959
|
+
console.log('registerFilters applied', e.currentTarget.id);
|
|
5960
|
+
this.processRegisterFilters(events, meta, searchCountryIndex, searchIndex, searchVal);
|
|
5961
|
+
});
|
|
5962
|
+
}
|
|
5749
5963
|
const registerStatute = this._SfRegisterContainer.querySelector('.calendar-right-data-register').querySelector('#register-statute-' + this.selectedRegisterIndex);
|
|
5750
5964
|
if (registerStatute != null) {
|
|
5751
5965
|
registerStatute.scrollIntoView();
|
|
@@ -5757,6 +5971,46 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
5757
5971
|
this.renderRegisterEvents(events, meta);
|
|
5758
5972
|
}
|
|
5759
5973
|
};
|
|
5974
|
+
this.processRegisterFilters = (events, meta = "", searchCountryIndex = -1, searchIndex = -1, searchVal = "") => {
|
|
5975
|
+
if (this.selectedCountryTab >= 0) {
|
|
5976
|
+
const index = this.selectedCountryTab;
|
|
5977
|
+
//console.log('indexclicked', index);
|
|
5978
|
+
const objCountry = events[Object.keys(events)[index]];
|
|
5979
|
+
for (var i = 0; i < Object.keys(objCountry).length; i++) {
|
|
5980
|
+
const statute = Object.keys(objCountry)[i];
|
|
5981
|
+
for (var j = 0; j < Object.keys(objCountry[statute]).length; j++) {
|
|
5982
|
+
let flagFilter = true;
|
|
5983
|
+
const complianceId = Object.keys(objCountry[statute])[j];
|
|
5984
|
+
events[Object.keys(events)[index]][statute][complianceId].hide = false;
|
|
5985
|
+
if (this.registerFilters['ID'][complianceId] == false) {
|
|
5986
|
+
flagFilter = false;
|
|
5987
|
+
events[Object.keys(events)[index]][statute][complianceId].hide = true;
|
|
5988
|
+
}
|
|
5989
|
+
const compliance = objCountry[statute][complianceId];
|
|
5990
|
+
const data = JSON.parse(compliance.data);
|
|
5991
|
+
const cols = JSON.parse(compliance.cols);
|
|
5992
|
+
for (var k = 0; k < cols.length; k++) {
|
|
5993
|
+
if (this.registerFilters[cols[k]] != null && this.registerFilters[cols[k]][data[k]] == false) {
|
|
5994
|
+
flagFilter = false;
|
|
5995
|
+
events[Object.keys(events)[index]][statute][complianceId].hide = true;
|
|
5996
|
+
}
|
|
5997
|
+
else {
|
|
5998
|
+
console.log('notFound', k, this.registerFilters[cols[k]]);
|
|
5999
|
+
}
|
|
6000
|
+
}
|
|
6001
|
+
if (JSON.stringify(compliance).toLowerCase().includes(searchVal.toLowerCase())) {
|
|
6002
|
+
if (flagFilter) {
|
|
6003
|
+
events[Object.keys(events)[index]][statute][complianceId].hide = false;
|
|
6004
|
+
}
|
|
6005
|
+
}
|
|
6006
|
+
else {
|
|
6007
|
+
events[Object.keys(events)[index]][statute][complianceId].hide = true;
|
|
6008
|
+
}
|
|
6009
|
+
}
|
|
6010
|
+
}
|
|
6011
|
+
}
|
|
6012
|
+
this.renderRegisterEvents(events, meta, searchCountryIndex, searchIndex, searchVal);
|
|
6013
|
+
};
|
|
5760
6014
|
this.checkStartDateEarliness = (value) => {
|
|
5761
6015
|
var startDateCalendar = new Date(this.calendarStartMM + '/' + this.calendarStartDD + '/' + this.calendarStartYYYY);
|
|
5762
6016
|
var startDateChosen = new Date(value);
|
|
@@ -6190,7 +6444,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
6190
6444
|
html += ",";
|
|
6191
6445
|
}
|
|
6192
6446
|
}
|
|
6193
|
-
divTagsArr[i].innerHTML = '<sf-i-elastic-text text="' + html + '" minLength="20"></sf-i-elastic-text>';
|
|
6447
|
+
divTagsArr[i].innerHTML = '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + html + '" minLength="20"></sf-i-elastic-text>';
|
|
6194
6448
|
this.mappedValuesTags[i] = value;
|
|
6195
6449
|
}
|
|
6196
6450
|
if (param == "users") {
|
|
@@ -6207,7 +6461,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
6207
6461
|
html += ",";
|
|
6208
6462
|
}
|
|
6209
6463
|
}
|
|
6210
|
-
divUsersArr[i].innerHTML = '<sf-i-elastic-text text="' + html + '" minLength="20"></sf-i-elastic-text>';
|
|
6464
|
+
divUsersArr[i].innerHTML = '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + html + '" minLength="20"></sf-i-elastic-text>';
|
|
6211
6465
|
this.mappedValuesUsers[i] = value;
|
|
6212
6466
|
this.updateMappingStatus(value, i);
|
|
6213
6467
|
this.calculateAndShowSummary();
|
|
@@ -7192,7 +7446,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
7192
7446
|
for (var j = 0; j < adhocQuestions[Object.keys(adhocQuestions)[i]].length; j++) {
|
|
7193
7447
|
const compliance = adhocQuestions[Object.keys(adhocQuestions)[i]][j];
|
|
7194
7448
|
html += '<tr>';
|
|
7195
|
-
html += ('<td part="td-body"><sf-i-elastic-text text="' + compliance.id + '" minLength="10" lineSize="6"></sf-i-elastic-text></td><td part="td-body"><sf-i-elastic-text text="' + compliance.locationname.replace(/ *\([^)]*\) */g, "").trim() + '" minLength="80" lineSize="6"></sf-i-elastic-text></td><td part="td-body"><sf-i-elastic-text text="' + compliance.obligationtitle.replace(/ *\([^)]*\) */g, "").trim() + '" minLength="80" lineSize="6"></sf-i-elastic-text></td><td part="td-body"><sf-i-elastic-text text="' + compliance.obligation + '" minLength="80" lineSize="6"></sf-i-elastic-text></td>');
|
|
7449
|
+
html += ('<td part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + compliance.id + '" minLength="10" lineSize="6"></sf-i-elastic-text></td><td part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + compliance.locationname.replace(/ *\([^)]*\) */g, "").trim() + '" minLength="80" lineSize="6"></sf-i-elastic-text></td><td part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + compliance.obligationtitle.replace(/ *\([^)]*\) */g, "").trim() + '" minLength="80" lineSize="6"></sf-i-elastic-text></td><td part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + compliance.obligation + '" minLength="80" lineSize="6"></sf-i-elastic-text></td>');
|
|
7196
7450
|
html += '</tr>';
|
|
7197
7451
|
}
|
|
7198
7452
|
html += '</table>';
|
|
@@ -7269,10 +7523,10 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
7269
7523
|
for (var j = 0; j < arrTriggerIds.length; j++) {
|
|
7270
7524
|
html += '<div class="d-flex align-center mt-20">';
|
|
7271
7525
|
html += '<span class="badge-counter" part="badge-counter">' + (j + 1) + '</span>';
|
|
7272
|
-
html += '<div part="results-title"><sf-i-elastic-text text="' + arrTriggerRemarks[j] + '" minLength="40"></sf-i-elastic-text></div>';
|
|
7526
|
+
html += '<div part="results-title"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + arrTriggerRemarks[j] + '" minLength="40"></sf-i-elastic-text></div>';
|
|
7273
7527
|
html += '</div>';
|
|
7274
7528
|
html += '<div part="td-body" class="d-flex align-center">';
|
|
7275
|
-
html += '<div>Trigger Id: </div> <sf-i-elastic-text text="' + arrTriggerIds[j] + '" minLength="10" lineSize="6"></sf-i-elastic-text> <button id="adhoc-delete-start-' + arrTriggerIds[j].replace(/-/g, "_") + '" class="mr-10 adhoc-delete-start">Retract</button><button id="adhoc-delete-cancel-' + arrTriggerIds[j].replace(/-/g, "_") + '" class="mr-10 hide adhoc-delete-cancel">Cancel</button><button id="adhoc-delete-confirm-' + arrTriggerIds[j].replace(/-/g, "_") + '" class="mr-10 hide adhoc-delete-confirm">Confirm Retract</button>';
|
|
7529
|
+
html += '<div>Trigger Id: </div> <sf-i-elastic-text exportparts="highlight,highlight-count" text="' + arrTriggerIds[j] + '" minLength="10" lineSize="6"></sf-i-elastic-text> <button id="adhoc-delete-start-' + arrTriggerIds[j].replace(/-/g, "_") + '" class="mr-10 adhoc-delete-start">Retract</button><button id="adhoc-delete-cancel-' + arrTriggerIds[j].replace(/-/g, "_") + '" class="mr-10 hide adhoc-delete-cancel">Cancel</button><button id="adhoc-delete-confirm-' + arrTriggerIds[j].replace(/-/g, "_") + '" class="mr-10 hide adhoc-delete-confirm">Confirm Retract</button>';
|
|
7276
7530
|
html += '</div>';
|
|
7277
7531
|
for (var k = 0; k < Object.keys(arrTriggers[arrTriggerIds[j]]).length; k++) {
|
|
7278
7532
|
const dateTrigger = Object.keys(arrTriggers[arrTriggerIds[j]])[k];
|
|
@@ -7282,7 +7536,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
7282
7536
|
const complianceTrigger = Object.keys(arrTriggers[arrTriggerIds[j]][dateTrigger][locationTrigger])[m];
|
|
7283
7537
|
const dateOccurrence = arrTriggers[arrTriggerIds[j]][dateTrigger][locationTrigger][complianceTrigger];
|
|
7284
7538
|
html += '<div part="td-head" class="d-flex align-center ml-10">';
|
|
7285
|
-
html += '<div>Occurred on ' + dateOccurrence + ', Triggered on ' + dateTrigger + ' at ' + locationTrigger.replace(/ *\([^)]*\) */g, "").trim() + ' for Compliance Id </div><sf-i-elastic-text text="' + complianceTrigger + '" minLength="10" lineSize="6"></sf-i-elastic-text>';
|
|
7539
|
+
html += '<div>Occurred on ' + dateOccurrence + ', Triggered on ' + dateTrigger + ' at ' + locationTrigger.replace(/ *\([^)]*\) */g, "").trim() + ' for Compliance Id </div><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + complianceTrigger + '" minLength="10" lineSize="6"></sf-i-elastic-text>';
|
|
7286
7540
|
html += '</div>';
|
|
7287
7541
|
}
|
|
7288
7542
|
}
|
|
@@ -8358,7 +8612,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
8358
8612
|
let listReportingContainer = this._SfThisContainer.querySelector('#list-reporting-container-' + mmdd.replace(/\//g, '-') + '-' + j);
|
|
8359
8613
|
listReportingContainer.style.display = 'none';
|
|
8360
8614
|
listReportingContainer.innerHTML = '';
|
|
8361
|
-
let buttonListReporting = this._SfThisContainer.querySelector('#button-list-reporting-' + mmdd.replace(/\//g, '-') + '-' + j);
|
|
8615
|
+
let buttonListReporting = this._SfThisContainer.querySelector('#button-list-reporting-' + mmdd.replace(/\//g, '-') + '-' + j + '-');
|
|
8362
8616
|
buttonListReporting.setAttribute('part', 'button-list-reporting');
|
|
8363
8617
|
let streamEventTitle = this._SfThisContainer.querySelector('#stream-event-title-' + mmdd.replace(/\//g, '-') + '-' + j + '-' + module);
|
|
8364
8618
|
streamEventTitle.removeAttribute('part');
|
|
@@ -8883,7 +9137,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
8883
9137
|
let listReportingContainer = this._SfStreamContainer.querySelector('#list-reporting-container-' + mmdd.replace(/\//g, '-') + '-' + j);
|
|
8884
9138
|
listReportingContainer.style.display = 'none';
|
|
8885
9139
|
listReportingContainer.innerHTML = '';
|
|
8886
|
-
let buttonListReporting = this._SfStreamContainer.querySelector('#button-list-reporting-' + mmdd.replace(/\//g, '-') + '-' + j);
|
|
9140
|
+
let buttonListReporting = this._SfStreamContainer.querySelector('#button-list-reporting-' + mmdd.replace(/\//g, '-') + '-' + j + '-');
|
|
8887
9141
|
buttonListReporting.setAttribute('part', 'button-list-reporting');
|
|
8888
9142
|
let streamEventTitle = this._SfStreamContainer.querySelector('#stream-event-title-' + mmdd.replace(/\//g, '-') + '-' + j + '-' + module);
|
|
8889
9143
|
streamEventTitle.removeAttribute('part');
|
|
@@ -9810,7 +10064,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
9810
10064
|
if (!this.EXCLUDE_COLS_FROM_REGS.includes(cols[k].toLowerCase())) {
|
|
9811
10065
|
html += '<div class="m-20">';
|
|
9812
10066
|
html += '<div part="detail-head"><strong>' + cols[k] + '</strong></div>';
|
|
9813
|
-
html += '<sf-i-elastic-text text="' + data[k] + '" minLength="80" lineSize="6"></sf-i-elastic-text>';
|
|
10067
|
+
html += '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + data[k] + '" minLength="80" lineSize="6"></sf-i-elastic-text>';
|
|
9814
10068
|
html += '</div>';
|
|
9815
10069
|
}
|
|
9816
10070
|
if (cols[k].toLowerCase() == "shortid") {
|
|
@@ -9982,7 +10236,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
9982
10236
|
for (var j = 0; j < Object.keys(jsonComments).length; j++) {
|
|
9983
10237
|
htmlTable += '<div class="mb-20">';
|
|
9984
10238
|
htmlTable += ('<div part="detail-head">' + Object.keys(jsonComments)[j] + '</div>');
|
|
9985
|
-
htmlTable += ('<sf-i-elastic-text text="' + jsonComments[Object.keys(jsonComments)[j]] + '" minLength="20"></sf-i-elastic-text>');
|
|
10239
|
+
htmlTable += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + jsonComments[Object.keys(jsonComments)[j]] + '" minLength="20"></sf-i-elastic-text>');
|
|
9986
10240
|
htmlTable += '</div>';
|
|
9987
10241
|
}
|
|
9988
10242
|
html += '<div class="">' + htmlTable + '<small><span class="muted">' + Util.getDateTimeStrings(new Date(comments[i].timestamp).getTime()) + '</span></small></div>';
|
|
@@ -10353,9 +10607,31 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
10353
10607
|
const reporterdoc = this._SfDetailContainer.querySelector('#input-reporter-doc').value.length > 0 ? (new Date(this._SfDetailContainer.querySelector('#input-reporter-doc').value).getTime() + "") : "";
|
|
10354
10608
|
let docs = [];
|
|
10355
10609
|
//console.log('reporter comments 2', reportercomments);
|
|
10610
|
+
let percentage = "100";
|
|
10611
|
+
if (this._SfDetailContainer.querySelector('#input-reporter-percentage') != null) {
|
|
10612
|
+
percentage = this._SfDetailContainer.querySelector('#input-reporter-percentage').value;
|
|
10613
|
+
}
|
|
10356
10614
|
// if(docsOptional.length === 0) {
|
|
10357
10615
|
docs = this._SfUploader[0].querySelector('#uploader').selectedValues();
|
|
10358
10616
|
// }
|
|
10617
|
+
let flag = false;
|
|
10618
|
+
do {
|
|
10619
|
+
if (docs.length > 0 && docsOptional != null && docsOptional.length === 0 && parseInt(percentage) > 0) {
|
|
10620
|
+
for (let doc of docs) {
|
|
10621
|
+
if ((doc.jobId == null || doc.jobId.length === 0) && (doc.ext.toLowerCase() == 'pdf' || doc.ext.toLowerCase() == 'png' || doc.ext.toLowerCase() == 'jpeg' || doc.ext.toLowerCase() == 'jpg')) {
|
|
10622
|
+
flag = false;
|
|
10623
|
+
}
|
|
10624
|
+
else {
|
|
10625
|
+
flag = true;
|
|
10626
|
+
}
|
|
10627
|
+
}
|
|
10628
|
+
}
|
|
10629
|
+
if (flag === false) {
|
|
10630
|
+
await this.sleep(1000);
|
|
10631
|
+
console.log('waiting for docs', docs);
|
|
10632
|
+
docs = this._SfUploader[0].querySelector('#uploader').selectedValues();
|
|
10633
|
+
}
|
|
10634
|
+
} while (flag === false);
|
|
10359
10635
|
//console.log('docs', docs);
|
|
10360
10636
|
let reportformatvalues = "";
|
|
10361
10637
|
let reportformatschema = "";
|
|
@@ -10363,10 +10639,6 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
10363
10639
|
reportformatvalues = (_a = JSON.stringify(this._SfReporting[0].querySelector('#reporting-format').selectedValues())) !== null && _a !== void 0 ? _a : "";
|
|
10364
10640
|
reportformatschema = (_b = this._SfReporting[0].querySelector('#reporting-format').configjson) !== null && _b !== void 0 ? _b : "";
|
|
10365
10641
|
}
|
|
10366
|
-
let percentage = "100";
|
|
10367
|
-
if (this._SfDetailContainer.querySelector('#input-reporter-percentage') != null) {
|
|
10368
|
-
percentage = this._SfDetailContainer.querySelector('#input-reporter-percentage').value;
|
|
10369
|
-
}
|
|
10370
10642
|
if (Number.isNaN(parseInt(percentage)) || parseInt(percentage) < 0 || parseInt(percentage) > 100) {
|
|
10371
10643
|
//console.log('reporter comments 3', reportercomments);
|
|
10372
10644
|
buttonClick.innerHTML = "Save";
|
|
@@ -10750,7 +11022,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
10750
11022
|
for (var j = 0; j < Object.keys(jsonComments).length; j++) {
|
|
10751
11023
|
htmlTable += '<div class="mb-20">';
|
|
10752
11024
|
htmlTable += ('<div part="detail-head">' + Object.keys(jsonComments)[j] + '</div>');
|
|
10753
|
-
htmlTable += ('<sf-i-elastic-text text="' + jsonComments[Object.keys(jsonComments)[j]] + '" minLength="20"></sf-i-elastic-text>');
|
|
11025
|
+
htmlTable += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + jsonComments[Object.keys(jsonComments)[j]] + '" minLength="20"></sf-i-elastic-text>');
|
|
10754
11026
|
htmlTable += '</div>';
|
|
10755
11027
|
}
|
|
10756
11028
|
html += '<div class="">' + htmlTable + '<small><span class="muted">' + Util.getDateTimeStrings(new Date(comments[i].timestamp).getTime()) + '</span></small></div>';
|
|
@@ -11541,7 +11813,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
11541
11813
|
for (var j = 0; j < Object.keys(jsonComments).length; j++) {
|
|
11542
11814
|
htmlTable += '<div class="mb-20">';
|
|
11543
11815
|
htmlTable += ('<div part="detail-head">' + Object.keys(jsonComments)[j] + '</div>');
|
|
11544
|
-
htmlTable += ('<sf-i-elastic-text text="' + jsonComments[Object.keys(jsonComments)[j]] + '" minLength="20"></sf-i-elastic-text>');
|
|
11816
|
+
htmlTable += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + jsonComments[Object.keys(jsonComments)[j]] + '" minLength="20"></sf-i-elastic-text>');
|
|
11545
11817
|
htmlTable += '</div>';
|
|
11546
11818
|
}
|
|
11547
11819
|
html += '<div class="">' + htmlTable + '<small><span class="muted">' + Util.getDateTimeStrings(new Date(comments[i].timestamp).getTime()) + '</span></small></div>';
|
|
@@ -12333,7 +12605,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
12333
12605
|
for (var j = 0; j < Object.keys(jsonComments).length; j++) {
|
|
12334
12606
|
htmlTable += '<div class="mb-20">';
|
|
12335
12607
|
htmlTable += ('<div part="detail-head">' + Object.keys(jsonComments)[j] + '</div>');
|
|
12336
|
-
htmlTable += ('<sf-i-elastic-text text="' + jsonComments[Object.keys(jsonComments)[j]] + '" minLength="20"></sf-i-elastic-text>');
|
|
12608
|
+
htmlTable += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + jsonComments[Object.keys(jsonComments)[j]] + '" minLength="20"></sf-i-elastic-text>');
|
|
12337
12609
|
htmlTable += '</div>';
|
|
12338
12610
|
}
|
|
12339
12611
|
html += '<div class="">' + htmlTable + '<small><span class="muted">' + Util.getDateTimeStrings(new Date(comments[i].timestamp).getTime()) + '</span></small></div>';
|
|
@@ -13151,9 +13423,9 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
13151
13423
|
html += ('<div part="detail-summary-subtitle" class="pl-20 pr-20"><h3>' + obligationArr[0].replace(/\n/g, '<br />') + '</h3></div>');
|
|
13152
13424
|
if (obligationArr.length > 1) {
|
|
13153
13425
|
let tempObligationArr = obligationArr.slice(1);
|
|
13154
|
-
html += ('<div part="detail-summary-subtitle-more-info" class="pl-20 pr-20 pb-10">' + ('<sf-i-elastic-text text="More information:' + (tempObligationArr.join('')).replace(/"/g, "").replace(/\n/g, '<br />') + '" minLength="80"></sf-i-elastic-text>') + '</div>');
|
|
13426
|
+
html += ('<div part="detail-summary-subtitle-more-info" class="pl-20 pr-20 pb-10">' + ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="More information:' + (tempObligationArr.join('')).replace(/"/g, "").replace(/\n/g, '<br />') + '" minLength="80"></sf-i-elastic-text>') + '</div>');
|
|
13155
13427
|
}
|
|
13156
|
-
html += ('<div part="detail-summary-content" class="pl-20 pr-20 pt-20">' + ('<sf-i-elastic-text text="' + (event['internalcontrols'] + "").replace(/"/g, "").replace(/\n/g, '<br />') + '" minLength="80"></sf-i-elastic-text>') + '</div>');
|
|
13428
|
+
html += ('<div part="detail-summary-content" class="pl-20 pr-20 pt-20">' + ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + (event['internalcontrols'] + "").replace(/"/g, "").replace(/\n/g, '<br />') + '" minLength="80"></sf-i-elastic-text>') + '</div>');
|
|
13157
13429
|
html += '</div>';
|
|
13158
13430
|
html += '<br />';
|
|
13159
13431
|
html += '<div class="accordian-section section-basic pl-20 pr-20" part="accordian-section">';
|
|
@@ -13175,7 +13447,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
13175
13447
|
else {
|
|
13176
13448
|
html += '<div class="m-20">';
|
|
13177
13449
|
html += '<div part="detail-head"><strong>' + basicFields[i] + '</strong></div>';
|
|
13178
|
-
html += '<sf-i-elastic-text text="' + (event[basicFields[i]] + "").replace(/"/g, "").replace(/ *\([^)]*\) */g, "").trim().split(';')[0] + '" minLength="80"></sf-i-elastic-text>';
|
|
13450
|
+
html += '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + (event[basicFields[i]] + "").replace(/"/g, "").replace(/ *\([^)]*\) */g, "").trim().split(';')[0] + '" minLength="80"></sf-i-elastic-text>';
|
|
13179
13451
|
html += '</div>';
|
|
13180
13452
|
}
|
|
13181
13453
|
}
|
|
@@ -13229,7 +13501,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
13229
13501
|
html += this.getEventTexts(statuteFields[i], JSON.parse(event[statuteFields[i]]), event);
|
|
13230
13502
|
}
|
|
13231
13503
|
else {
|
|
13232
|
-
html += '<sf-i-elastic-text text="' + (event[statuteFields[i]] + "").replace(/"/g, "") + '" minLength="80"></sf-i-elastic-text>';
|
|
13504
|
+
html += '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + (event[statuteFields[i]] + "").replace(/"/g, "") + '" minLength="80"></sf-i-elastic-text>';
|
|
13233
13505
|
}
|
|
13234
13506
|
html += '</div>';
|
|
13235
13507
|
}
|
|
@@ -13259,7 +13531,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
13259
13531
|
html += this.getEventTexts(complianceFields[i], JSON.parse(event[complianceFields[i]]), event) + " <a href=\"" + res + "\" target=\"_blank\">Open</a>";
|
|
13260
13532
|
}
|
|
13261
13533
|
else {
|
|
13262
|
-
html += '<sf-i-elastic-text text="' + (event[complianceFields[i]] + "").replace(/"/g, "").replace(/\n/g, '<br />') + '" minLength="80"></sf-i-elastic-text>' + " <a href=\"" + res + "\" target=\"_blank\">Open</a>";
|
|
13534
|
+
html += '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + (event[complianceFields[i]] + "").replace(/"/g, "").replace(/\n/g, '<br />') + '" minLength="80"></sf-i-elastic-text>' + " <a href=\"" + res + "\" target=\"_blank\">Open</a>";
|
|
13263
13535
|
}
|
|
13264
13536
|
html += '</div>';
|
|
13265
13537
|
}
|
|
@@ -13288,7 +13560,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
13288
13560
|
html += this.getEventTexts(complianceFields[i], JSON.parse(event[complianceFields[i]]), event);
|
|
13289
13561
|
}
|
|
13290
13562
|
else {
|
|
13291
|
-
html += '<sf-i-elastic-text text="' + (event[complianceFields[i]] + "").replace(/"/g, "").replace(/\n/g, '<br />') + '" minLength="80"></sf-i-elastic-text>';
|
|
13563
|
+
html += '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + (event[complianceFields[i]] + "").replace(/"/g, "").replace(/\n/g, '<br />') + '" minLength="80"></sf-i-elastic-text>';
|
|
13292
13564
|
}
|
|
13293
13565
|
html += '</div>';
|
|
13294
13566
|
}
|
|
@@ -13323,7 +13595,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
13323
13595
|
}
|
|
13324
13596
|
else {
|
|
13325
13597
|
//console.log('grcfield', event[grcFields[i]]);
|
|
13326
|
-
html += '<sf-i-elastic-text text="' + (event[grcFields[i]] + "").replace(/"/g, "").replace(/\n/g, '<br />') + '" minLength="80"></sf-i-elastic-text>';
|
|
13598
|
+
html += '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + (event[grcFields[i]] + "").replace(/"/g, "").replace(/\n/g, '<br />') + '" minLength="80"></sf-i-elastic-text>';
|
|
13327
13599
|
}
|
|
13328
13600
|
}
|
|
13329
13601
|
html += '</div>';
|
|
@@ -13382,7 +13654,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
13382
13654
|
for (var j = 0; j < Object.keys(jsonComments).length; j++) {
|
|
13383
13655
|
htmlTable += '<div class="mb-20">';
|
|
13384
13656
|
htmlTable += ('<div part="detail-head">' + Object.keys(jsonComments)[j] + '</div>');
|
|
13385
|
-
htmlTable += ('<sf-i-elastic-text text="' + jsonComments[Object.keys(jsonComments)[j]] + '" minLength="20"></sf-i-elastic-text>');
|
|
13657
|
+
htmlTable += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + jsonComments[Object.keys(jsonComments)[j]] + '" minLength="20"></sf-i-elastic-text>');
|
|
13386
13658
|
htmlTable += '</div>';
|
|
13387
13659
|
}
|
|
13388
13660
|
html += '<div class="">' + htmlTable + '<small><span class="muted">' + Util.getDateTimeStrings(new Date(comments[i].timestamp).getTime()) + '</span></small></div>';
|
|
@@ -13413,7 +13685,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
13413
13685
|
if (!this.EXCLUDE_COLS_FROM_REGS.includes(Object.keys(jsonReportEvent)[i].toLowerCase())) {
|
|
13414
13686
|
html += '<td part="td-body-register">';
|
|
13415
13687
|
html += ('<span part="td-head" style="padding-left: 0px !important">' + Object.keys(jsonReportEvent)[i] + '</span>');
|
|
13416
|
-
html += ('<span part="td-body"><sf-i-elastic-text text="' + jsonReportEvent[Object.keys(jsonReportEvent)[i]] + '" lineSize="4" minLength="60"></sf-i-elastic-text>' + '</span>');
|
|
13688
|
+
html += ('<span part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + jsonReportEvent[Object.keys(jsonReportEvent)[i]] + '" lineSize="4" minLength="60"></sf-i-elastic-text>' + '</span>');
|
|
13417
13689
|
html += '</td>';
|
|
13418
13690
|
}
|
|
13419
13691
|
}
|
|
@@ -13988,9 +14260,31 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
13988
14260
|
const reporterdoc = this._SfDetailContainer.querySelector('#input-reporter-doc').value.length > 0 ? (new Date(this._SfDetailContainer.querySelector('#input-reporter-doc').value).getTime() + "") : "";
|
|
13989
14261
|
let docs = [];
|
|
13990
14262
|
//console.log('reporter comments 2', reportercomments);
|
|
14263
|
+
let percentage = "100";
|
|
14264
|
+
if (this._SfDetailContainer.querySelector('#input-reporter-percentage') != null) {
|
|
14265
|
+
percentage = this._SfDetailContainer.querySelector('#input-reporter-percentage').value;
|
|
14266
|
+
}
|
|
13991
14267
|
// if(docsOptional.length === 0) {
|
|
13992
14268
|
docs = this._SfUploader[0].querySelector('#uploader').selectedValues();
|
|
13993
14269
|
// }
|
|
14270
|
+
let flag = false;
|
|
14271
|
+
do {
|
|
14272
|
+
if (docs.length > 0 && docsOptional != null && docsOptional.length === 0 && parseInt(percentage) > 0) {
|
|
14273
|
+
for (let doc of docs) {
|
|
14274
|
+
if ((doc.jobId == null || doc.jobId.length === 0) && (doc.ext.toLowerCase() == 'pdf' || doc.ext.toLowerCase() == 'png' || doc.ext.toLowerCase() == 'jpeg' || doc.ext.toLowerCase() == 'jpg')) {
|
|
14275
|
+
flag = false;
|
|
14276
|
+
}
|
|
14277
|
+
else {
|
|
14278
|
+
flag = true;
|
|
14279
|
+
}
|
|
14280
|
+
}
|
|
14281
|
+
}
|
|
14282
|
+
if (flag === false) {
|
|
14283
|
+
await this.sleep(1000);
|
|
14284
|
+
console.log('waiting for docs', docs);
|
|
14285
|
+
docs = this._SfUploader[0].querySelector('#uploader').selectedValues();
|
|
14286
|
+
}
|
|
14287
|
+
} while (flag === false);
|
|
13994
14288
|
//console.log('docs', docs);
|
|
13995
14289
|
let reportformatvalues = "";
|
|
13996
14290
|
let reportformatschema = "";
|
|
@@ -13998,10 +14292,6 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
13998
14292
|
reportformatvalues = (_a = JSON.stringify(this._SfReporting[0].querySelector('#reporting-format').selectedValues())) !== null && _a !== void 0 ? _a : "";
|
|
13999
14293
|
reportformatschema = (_b = this._SfReporting[0].querySelector('#reporting-format').configjson) !== null && _b !== void 0 ? _b : "";
|
|
14000
14294
|
}
|
|
14001
|
-
let percentage = "100";
|
|
14002
|
-
if (this._SfDetailContainer.querySelector('#input-reporter-percentage') != null) {
|
|
14003
|
-
percentage = this._SfDetailContainer.querySelector('#input-reporter-percentage').value;
|
|
14004
|
-
}
|
|
14005
14295
|
if (Number.isNaN(parseInt(percentage)) || parseInt(percentage) < 0 || parseInt(percentage) > 100) {
|
|
14006
14296
|
//console.log('reporter comments 3', reportercomments);
|
|
14007
14297
|
buttonClick.innerHTML = "Save";
|
|
@@ -15007,7 +15297,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
15007
15297
|
// this.clearMessages();
|
|
15008
15298
|
// }, 20000);
|
|
15009
15299
|
// } else {
|
|
15010
|
-
// html += '<sf-i-elastic-text text="'+JSON.stringify(arrFeedbackReference[JSON.parse(sourceArray.data.mappings.mappings[i].data)[1][0].trim()][JSON.parse(sourceArray.data.mappings.mappings[i].data)[6][0].trim().replace(/&/g, "&")]).replace(/"/g,"").replace(/\\n/g,"").replace(/{/g,"").replace(/}/g,"").replace(/\\/g,"")+'" lineSize="4" minLength="60"></sf-i-elastic-text>';
|
|
15300
|
+
// html += '<sf-i-elastic-text exportparts="highlight,highlight-count" text="'+JSON.stringify(arrFeedbackReference[JSON.parse(sourceArray.data.mappings.mappings[i].data)[1][0].trim()][JSON.parse(sourceArray.data.mappings.mappings[i].data)[6][0].trim().replace(/&/g, "&")]).replace(/"/g,"").replace(/\\n/g,"").replace(/{/g,"").replace(/}/g,"").replace(/\\/g,"")+'" lineSize="4" minLength="60"></sf-i-elastic-text>';
|
|
15011
15301
|
// }
|
|
15012
15302
|
// html += '</div>';
|
|
15013
15303
|
// html += '</td>'
|
|
@@ -15016,7 +15306,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
15016
15306
|
// console.log('uniqcolval', uniqCols[l], sourceArray.data.mappings.mappings[i], sourceArray.data.mappings.mappings[i][uniqCols[l]]);
|
|
15017
15307
|
html += '<td class="td-body ' + classBg + '" part="td-key">';
|
|
15018
15308
|
html += '<div class="' + (!showSearch ? 'truncate' : '') + '">';
|
|
15019
|
-
html += '<sf-i-elastic-text text="' + sourceArray.data.mappings.mappings[i][uniqCols[l]].replace(/ *\([^)]*\) */g, "") + '" minLength="20"></sf-i-elastic-text>';
|
|
15309
|
+
html += '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + sourceArray.data.mappings.mappings[i][uniqCols[l]].replace(/ *\([^)]*\) */g, "") + '" minLength="20"></sf-i-elastic-text>';
|
|
15020
15310
|
html += '</div>';
|
|
15021
15311
|
html += '</td>';
|
|
15022
15312
|
}
|
|
@@ -15042,11 +15332,11 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
15042
15332
|
//console.log('isArray', sourceCols[l], Array.isArray(JSON.parse(sourceArray.data.mappings.mappings[i].data)[j]));
|
|
15043
15333
|
if (Array.isArray(JSON.parse(sourceArray.data.mappings.mappings[i].data)[j])) {
|
|
15044
15334
|
for (var k = 0; k < JSON.parse(sourceArray.data.mappings.mappings[i].data)[j].length; k++) {
|
|
15045
|
-
html += ('<sf-i-elastic-text text="' + JSON.parse(sourceArray.data.mappings.mappings[i].data)[j][k] + '" minLength="100" lineSize="4"></sf-i-elastic-text>');
|
|
15335
|
+
html += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + JSON.parse(sourceArray.data.mappings.mappings[i].data)[j][k] + '" minLength="100" lineSize="4"></sf-i-elastic-text>');
|
|
15046
15336
|
}
|
|
15047
15337
|
}
|
|
15048
15338
|
else {
|
|
15049
|
-
html += ('<sf-i-elastic-text text="' + JSON.parse(sourceArray.data.mappings.mappings[i].data)[j] + '" minLength="100" lineSize="4"></sf-i-elastic-text>');
|
|
15339
|
+
html += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + JSON.parse(sourceArray.data.mappings.mappings[i].data)[j] + '" minLength="100" lineSize="4"></sf-i-elastic-text>');
|
|
15050
15340
|
}
|
|
15051
15341
|
html += '</div>';
|
|
15052
15342
|
html += '</td>';
|
|
@@ -15713,7 +16003,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
15713
16003
|
html += '</td>';
|
|
15714
16004
|
}
|
|
15715
16005
|
html += '<td part="td-body">';
|
|
15716
|
-
html += '<sf-i-elastic-text class="statute id-' + i + '" text="' + (jsonData[i].id) + '" minLength="10"></sf-i-elastic-text>';
|
|
16006
|
+
html += '<sf-i-elastic-text exportparts="highlight,highlight-count" class="statute id-' + i + '" text="' + (jsonData[i].id) + '" minLength="10"></sf-i-elastic-text>';
|
|
15717
16007
|
html += '</td>';
|
|
15718
16008
|
html += '</tr>';
|
|
15719
16009
|
continue;
|
|
@@ -15866,7 +16156,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
15866
16156
|
html += '</td>';
|
|
15867
16157
|
}
|
|
15868
16158
|
html += '<td part="td-body" class="' + classBg + ' ' + (jsonData[i].mapped ? 'chosen' : '') + '">';
|
|
15869
|
-
html += '<div class="' + (!showSearch ? 'truncate' : '') + '"><sf-i-elastic-text class="statute id-' + i + '" text="' + (jsonData[i].id) + '" minLength="10"></sf-i-elastic-text></div>';
|
|
16159
|
+
html += '<div class="' + (!showSearch ? 'truncate' : '') + '"><sf-i-elastic-text exportparts="highlight,highlight-count" class="statute id-' + i + '" text="' + (jsonData[i].id) + '" minLength="10"></sf-i-elastic-text></div>';
|
|
15870
16160
|
html += '</td>';
|
|
15871
16161
|
//let data = JSON.parse(jsonData[i].fields.data);
|
|
15872
16162
|
for (var j = 0; j < JSON.parse(jsonData[i].data.cols).length; j++) {
|
|
@@ -15890,13 +16180,13 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
15890
16180
|
html += ('<div part="td-head" class="pl-0-imp w-100">' + JSON.parse(jsonData[i].data.cols)[j] + '</div>');
|
|
15891
16181
|
if (Array.isArray(JSON.parse(jsonData[i].data.data)[j])) {
|
|
15892
16182
|
for (var k = 0; k < JSON.parse(jsonData[i].data.data)[j].length; k++) {
|
|
15893
|
-
html += ('<sf-i-elastic-text text="' + JSON.parse(jsonData[i].data.data)[j][k] + '" minLength="80" lineSize="4"></sf-i-elastic-text>');
|
|
15894
|
-
//console.log('Considering', JSON.parse(jsonData[i].data.cols)[j], jsonData[i].cols, j, JSON.parse(jsonData[i].data.data)[j], '<sf-i-elastic-text text="'+JSON.parse(jsonData[i].data.data)[j][k]+'" minLength="80"></sf-i-elastic-text>');
|
|
16183
|
+
html += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + JSON.parse(jsonData[i].data.data)[j][k] + '" minLength="80" lineSize="4"></sf-i-elastic-text>');
|
|
16184
|
+
//console.log('Considering', JSON.parse(jsonData[i].data.cols)[j], jsonData[i].cols, j, JSON.parse(jsonData[i].data.data)[j], '<sf-i-elastic-text exportparts="highlight,highlight-count" text="'+JSON.parse(jsonData[i].data.data)[j][k]+'" minLength="80"></sf-i-elastic-text>');
|
|
15895
16185
|
}
|
|
15896
16186
|
}
|
|
15897
16187
|
else {
|
|
15898
|
-
html += ('<sf-i-elastic-text text="' + JSON.parse(jsonData[i].data.data)[j] + '" minLength="80" lineSize="4"></sf-i-elastic-text>');
|
|
15899
|
-
//console.log('Considering', JSON.parse(jsonData[i].data.cols)[j], jsonData[i].cols, j, JSON.parse(jsonData[i].data.data)[j], '<sf-i-elastic-text text="'+JSON.parse(jsonData[i].data.data)[j]+'" minLength="80"></sf-i-elastic-text>');
|
|
16188
|
+
html += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + JSON.parse(jsonData[i].data.data)[j] + '" minLength="80" lineSize="4"></sf-i-elastic-text>');
|
|
16189
|
+
//console.log('Considering', JSON.parse(jsonData[i].data.cols)[j], jsonData[i].cols, j, JSON.parse(jsonData[i].data.data)[j], '<sf-i-elastic-text exportparts="highlight,highlight-count" text="'+JSON.parse(jsonData[i].data.data)[j]+'" minLength="80"></sf-i-elastic-text>');
|
|
15900
16190
|
}
|
|
15901
16191
|
html += '</div>';
|
|
15902
16192
|
html += '</div>';
|
|
@@ -16116,7 +16406,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
16116
16406
|
if (val == '') {
|
|
16117
16407
|
val = '-';
|
|
16118
16408
|
}
|
|
16119
|
-
html += ('<sf-i-elastic-text text="' + val + '" minLength="80"></sf-i-elastic-text>');
|
|
16409
|
+
html += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + val + '" minLength="80"></sf-i-elastic-text>');
|
|
16120
16410
|
}
|
|
16121
16411
|
}
|
|
16122
16412
|
html += '</div>';
|
|
@@ -16126,7 +16416,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
16126
16416
|
if (val == '') {
|
|
16127
16417
|
val = '-';
|
|
16128
16418
|
}
|
|
16129
|
-
html += ('<div part="td-body">' + '<sf-i-elastic-text text="' + val + '" minLength="80"></sf-i-elastic-text>' + '</div><br />');
|
|
16419
|
+
html += ('<div part="td-body">' + '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + val + '" minLength="80"></sf-i-elastic-text>' + '</div><br />');
|
|
16130
16420
|
}
|
|
16131
16421
|
html += '</div>';
|
|
16132
16422
|
}
|
|
@@ -16844,7 +17134,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
16844
17134
|
if (arrStatus[0].toLowerCase().indexOf('entities') >= 0) {
|
|
16845
17135
|
this._SfOnboardingTabContainer.querySelector('#button-status-entities').innerHTML = arrStatus[1];
|
|
16846
17136
|
}
|
|
16847
|
-
if (arrStatus[0].toLowerCase().indexOf('locations') >= 0) {
|
|
17137
|
+
if (arrStatus[0].toLowerCase().indexOf('locations') >= 0 && arrStatus[0].toLowerCase().indexOf('reportedlocations') < 0) {
|
|
16848
17138
|
this._SfOnboardingTabContainer.querySelector('#button-status-locations').innerHTML = arrStatus[1];
|
|
16849
17139
|
}
|
|
16850
17140
|
if (arrStatus[0].toLowerCase().indexOf('functions') >= 0) {
|
|
@@ -17161,7 +17451,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
17161
17451
|
classBg = 'td-light';
|
|
17162
17452
|
html += '<tr>';
|
|
17163
17453
|
html += '<td part="td-body" class="' + classBg + '">';
|
|
17164
|
-
html += '<sf-i-elastic-text class="statute id-' + i + '" text="' + (this.rcmSelectedCompliance.id) + '" minLength="80"></sf-i-elastic-text>';
|
|
17454
|
+
html += '<sf-i-elastic-text exportparts="highlight,highlight-count" class="statute id-' + i + '" text="' + (this.rcmSelectedCompliance.id) + '" minLength="80"></sf-i-elastic-text>';
|
|
17165
17455
|
html += '</td>';
|
|
17166
17456
|
//let data = JSON.parse(jsonData[i].fields.data);
|
|
17167
17457
|
for (var j = 0; j < Object.keys(this.rcmSelectedCompliance.values).length; j++) {
|
|
@@ -17171,10 +17461,10 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
17171
17461
|
if (Array.isArray(this.rcmSelectedCompliance.values[objectKey].value)) {
|
|
17172
17462
|
for (var k = 0; k < this.rcmSelectedCompliance.values[objectKey].value.length; k++) {
|
|
17173
17463
|
if (this.rcmSelectedCompliance.values[objectKey].text != null) {
|
|
17174
|
-
html += ('<sf-i-elastic-text text="' + this.rcmSelectedCompliance.values[objectKey].text[k] + '" minLength="80"></sf-i-elastic-text>');
|
|
17464
|
+
html += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.rcmSelectedCompliance.values[objectKey].text[k] + '" minLength="80"></sf-i-elastic-text>');
|
|
17175
17465
|
}
|
|
17176
17466
|
else {
|
|
17177
|
-
html += ('<sf-i-elastic-text text="' + this.rcmSelectedCompliance.values[objectKey].value[k] + '" minLength="80"></sf-i-elastic-text>');
|
|
17467
|
+
html += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.rcmSelectedCompliance.values[objectKey].value[k] + '" minLength="80"></sf-i-elastic-text>');
|
|
17178
17468
|
}
|
|
17179
17469
|
if (k < (this.rcmSelectedCompliance.values[objectKey].value.length - 1)) {
|
|
17180
17470
|
html += "; ";
|
|
@@ -17183,10 +17473,10 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
17183
17473
|
}
|
|
17184
17474
|
else {
|
|
17185
17475
|
if (this.rcmSelectedCompliance.values[objectKey].text != null) {
|
|
17186
|
-
html += ('<sf-i-elastic-text text="' + this.rcmSelectedCompliance.values[objectKey].value + '" minLength="80"></sf-i-elastic-text>');
|
|
17476
|
+
html += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.rcmSelectedCompliance.values[objectKey].value + '" minLength="80"></sf-i-elastic-text>');
|
|
17187
17477
|
}
|
|
17188
17478
|
else {
|
|
17189
|
-
html += ('<sf-i-elastic-text text="' + this.rcmSelectedCompliance.values[objectKey].value + '" minLength="80"></sf-i-elastic-text>');
|
|
17479
|
+
html += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + this.rcmSelectedCompliance.values[objectKey].value + '" minLength="80"></sf-i-elastic-text>');
|
|
17190
17480
|
}
|
|
17191
17481
|
}
|
|
17192
17482
|
html += '</td>';
|
|
@@ -17238,7 +17528,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
17238
17528
|
html += '<div class="d-flex"><button id="button-lock-' + (updatedCompliances[i].id) + '" class="mr-10 button-lock-icon button-lock-' + i + '" part="button-icon-small"><span class="material-symbols-outlined">done</span></button></div>';
|
|
17239
17529
|
html += '</td>';
|
|
17240
17530
|
html += '<td part="td-body" class="' + classBg + '">';
|
|
17241
|
-
html += '<sf-i-elastic-text class="statute id-' + i + '" text="' + (updatedCompliances[i].id) + '" minLength="80"></sf-i-elastic-text>';
|
|
17531
|
+
html += '<sf-i-elastic-text exportparts="highlight,highlight-count" class="statute id-' + i + '" text="' + (updatedCompliances[i].id) + '" minLength="80"></sf-i-elastic-text>';
|
|
17242
17532
|
html += '</td>';
|
|
17243
17533
|
//let data = JSON.parse(jsonData[i].fields.data);
|
|
17244
17534
|
for (var j = 0; j < Object.keys(updatedCompliances[i].values).length; j++) {
|
|
@@ -17248,10 +17538,10 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
17248
17538
|
if (Array.isArray(updatedCompliances[i].values[objectKey].value)) {
|
|
17249
17539
|
for (var k = 0; k < updatedCompliances[i].values[objectKey].value.length; k++) {
|
|
17250
17540
|
if (updatedCompliances[i].values[objectKey].text != null) {
|
|
17251
|
-
html += ('<sf-i-elastic-text text="' + updatedCompliances[i].values[objectKey].text[k] + '" minLength="80"></sf-i-elastic-text>');
|
|
17541
|
+
html += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + updatedCompliances[i].values[objectKey].text[k] + '" minLength="80"></sf-i-elastic-text>');
|
|
17252
17542
|
}
|
|
17253
17543
|
else {
|
|
17254
|
-
html += ('<sf-i-elastic-text text="' + updatedCompliances[i].values[objectKey].value[k] + '" minLength="80"></sf-i-elastic-text>');
|
|
17544
|
+
html += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + updatedCompliances[i].values[objectKey].value[k] + '" minLength="80"></sf-i-elastic-text>');
|
|
17255
17545
|
}
|
|
17256
17546
|
if (k < (updatedCompliances[i].values[objectKey].value.length - 1)) {
|
|
17257
17547
|
html += "; ";
|
|
@@ -17260,10 +17550,10 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
17260
17550
|
}
|
|
17261
17551
|
else {
|
|
17262
17552
|
if (updatedCompliances[i].values[objectKey].text != null) {
|
|
17263
|
-
html += ('<sf-i-elastic-text text="' + updatedCompliances[i].values[objectKey].value + '" minLength="80"></sf-i-elastic-text>');
|
|
17553
|
+
html += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + updatedCompliances[i].values[objectKey].value + '" minLength="80"></sf-i-elastic-text>');
|
|
17264
17554
|
}
|
|
17265
17555
|
else {
|
|
17266
|
-
html += ('<sf-i-elastic-text text="' + updatedCompliances[i].values[objectKey].value + '" minLength="80"></sf-i-elastic-text>');
|
|
17556
|
+
html += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + updatedCompliances[i].values[objectKey].value + '" minLength="80"></sf-i-elastic-text>');
|
|
17267
17557
|
}
|
|
17268
17558
|
}
|
|
17269
17559
|
html += '</td>';
|
|
@@ -17333,7 +17623,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
17333
17623
|
// html += '<div id="select-'+i+'"><button id="button-'+i+'" class="button-icon button-'+i+'"><span class="material-symbols-outlined">navigate_next</span></button></div>';
|
|
17334
17624
|
// html += '</td>';
|
|
17335
17625
|
html += '<td part="td-body" class="' + classBg + '">';
|
|
17336
|
-
html += '<sf-i-elastic-text class="statute id-' + i + '" text="' + (projects[i].id) + '" minLength="80"></sf-i-elastic-text>';
|
|
17626
|
+
html += '<sf-i-elastic-text exportparts="highlight,highlight-count" class="statute id-' + i + '" text="' + (projects[i].id) + '" minLength="80"></sf-i-elastic-text>';
|
|
17337
17627
|
html += '</td>';
|
|
17338
17628
|
// //let data = JSON.parse(jsonData[i].fields.data);
|
|
17339
17629
|
for (var j = 0; j < Object.keys(projects[i]).length; j++) {
|
|
@@ -17343,12 +17633,12 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
17343
17633
|
//console.log('value',projects[i][objectKey]);
|
|
17344
17634
|
if (Array.isArray(projects[i][objectKey])) {
|
|
17345
17635
|
for (var k = 0; k < projects[i][objectKey].value.length; k++) {
|
|
17346
|
-
html += ('<sf-i-elastic-text text="' + projects[i][objectKey][0] + '" minLength="80"></sf-i-elastic-text>');
|
|
17636
|
+
html += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + projects[i][objectKey][0] + '" minLength="80"></sf-i-elastic-text>');
|
|
17347
17637
|
}
|
|
17348
17638
|
}
|
|
17349
17639
|
else {
|
|
17350
17640
|
//console.log('not array');
|
|
17351
|
-
html += ('<sf-i-elastic-text text="' + projects[i][objectKey].replace(/"/g, '') + '" minLength="80"></sf-i-elastic-text>');
|
|
17641
|
+
html += ('<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + projects[i][objectKey].replace(/"/g, '') + '" minLength="80"></sf-i-elastic-text>');
|
|
17352
17642
|
}
|
|
17353
17643
|
html += '</td>';
|
|
17354
17644
|
}
|
|
@@ -19966,7 +20256,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
19966
20256
|
html += this.getEventTexts(Object.keys(events[index])[k], JSON.parse(events[index][Object.keys(events[index])[k]]), events[index]);
|
|
19967
20257
|
}
|
|
19968
20258
|
else {
|
|
19969
|
-
html += '<sf-i-elastic-text text="' + events[index][Object.keys(events[index])[k]].replace(/"/g, "") + '" minLength="20"></sf-i-elastic-text>';
|
|
20259
|
+
html += '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + events[index][Object.keys(events[index])[k]].replace(/"/g, "") + '" minLength="20"></sf-i-elastic-text>';
|
|
19970
20260
|
}
|
|
19971
20261
|
html += '</td>';
|
|
19972
20262
|
}
|
|
@@ -20114,7 +20404,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
20114
20404
|
html += this.getEventTexts(Object.keys(unmappedEvents[i])[k], JSON.parse(unmappedEvents[i][Object.keys(unmappedEvents[i])[k]]), unmappedEvents[i]);
|
|
20115
20405
|
}
|
|
20116
20406
|
else {
|
|
20117
|
-
html += ' <sf-i-elastic-text text="' + unmappedEvents[i][Object.keys(unmappedEvents[i])[k]].replace(/"/g, "") + '" minLength="20"></sf-i-elastic-text>';
|
|
20407
|
+
html += ' <sf-i-elastic-text exportparts="highlight,highlight-count" text="' + unmappedEvents[i][Object.keys(unmappedEvents[i])[k]].replace(/"/g, "") + '" minLength="20"></sf-i-elastic-text>';
|
|
20118
20408
|
}
|
|
20119
20409
|
html += '</td>';
|
|
20120
20410
|
}
|
|
@@ -20196,7 +20486,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
20196
20486
|
html += ",";
|
|
20197
20487
|
}
|
|
20198
20488
|
}
|
|
20199
|
-
div.innerHTML = '<sf-i-elastic-text text="' + html + '" minLength="20"></sf-i-elastic-text>';
|
|
20489
|
+
div.innerHTML = '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + html + '" minLength="20"></sf-i-elastic-text>';
|
|
20200
20490
|
this.mappedValuesTags[clickIndex] = form.selectedValues();
|
|
20201
20491
|
// const div = ((this._SfMappingContainer as HTMLDivElement).querySelector('#row-unmapped-div-tags-'+clickIndex) as HTMLDivElement);
|
|
20202
20492
|
// const input = ((this._SfMappingContainer as HTMLDivElement).querySelector('#row-unmapped-input-tags-'+clickIndex) as HTMLInputElement);
|
|
@@ -20215,7 +20505,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
20215
20505
|
html += ",";
|
|
20216
20506
|
}
|
|
20217
20507
|
}
|
|
20218
|
-
div.innerHTML = '<sf-i-elastic-text text="' + html + '" minLength="20"></sf-i-elastic-text>';
|
|
20508
|
+
div.innerHTML = '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + html + '" minLength="20"></sf-i-elastic-text>';
|
|
20219
20509
|
this.mappedValuesUsers[clickIndex] = form.selectedValues();
|
|
20220
20510
|
this.updateMappingStatus(form.selectedValues(), clickIndex);
|
|
20221
20511
|
this.calculateAndShowSummary();
|
|
@@ -20361,7 +20651,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
20361
20651
|
html += ',';
|
|
20362
20652
|
}
|
|
20363
20653
|
}
|
|
20364
|
-
this._SfMappingContainer.querySelector('#row-unmapped-div-tags-' + i).innerHTML = '<sf-i-elastic-text text="' + html + '" minLength="20"></sf-i-elastic-text>';
|
|
20654
|
+
this._SfMappingContainer.querySelector('#row-unmapped-div-tags-' + i).innerHTML = '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + html + '" minLength="20"></sf-i-elastic-text>';
|
|
20365
20655
|
this._SfMappingContainer.querySelector('#row-unmapped-input-tags-' + i).preselectedValues = JSON.stringify(this.mappedValuesTags[i]);
|
|
20366
20656
|
//((this._SfMappingContainer as HTMLDivElement).querySelector('#row-unmapped-input-tags-'+i) as SfIForm)!.populatePreselected();
|
|
20367
20657
|
}
|
|
@@ -20373,7 +20663,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
20373
20663
|
html += ',';
|
|
20374
20664
|
}
|
|
20375
20665
|
}
|
|
20376
|
-
this._SfMappingContainer.querySelector('#row-unmapped-div-users-' + i).innerHTML = '<sf-i-elastic-text text="' + html + '" minLength="20"></sf-i-elastic-text>';
|
|
20666
|
+
this._SfMappingContainer.querySelector('#row-unmapped-div-users-' + i).innerHTML = '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + html + '" minLength="20"></sf-i-elastic-text>';
|
|
20377
20667
|
this._SfMappingContainer.querySelector('#row-unmapped-input-users-' + i).preselectedValues = JSON.stringify(this.mappedValuesUsers[i]);
|
|
20378
20668
|
//((this._SfMappingContainer as HTMLDivElement).querySelector('#row-unmapped-input-users-'+i) as SfIForm)!.populatePreselected();
|
|
20379
20669
|
}
|
|
@@ -22070,6 +22360,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
22070
22360
|
console.log('jsonRespose', jsonRespose);
|
|
22071
22361
|
const registers = (await this.fetchPresignedUrl(jsonRespose.signedUrlGet));
|
|
22072
22362
|
await this.fetchPresignedUrlDelete(jsonRespose.signedUrlDelete);
|
|
22363
|
+
this.registerFilters = {};
|
|
22073
22364
|
// this.renderAppropriateStream(startDate, endDate);
|
|
22074
22365
|
// const jsonRespose = JSON.parse(xhr.responseText);
|
|
22075
22366
|
//console.log(jsonRespose);
|
|
@@ -23364,10 +23655,10 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
23364
23655
|
eventHtml += '<div class="stream-events-container flex-grow">';
|
|
23365
23656
|
eventHtml += '<div class="hidden-tags hide">' + JSON.stringify(eventsData[role][mmdd][j]['tags']) + '</div>';
|
|
23366
23657
|
eventHtml += '<div class="hidden-title hide"><table><thead><th part="badge-filtered"><i>not filtered</i></th></thead></table></div>';
|
|
23367
|
-
eventHtml += '<div part="stream-events-event-title" class="stream-events-event-title d-flex align-center pl-5 pb-5 mb-10">' + (eventsData[role][mmdd][j].isbulk ? ('<div class="lds-dual-ring1 bulk-loader mr-10"></div>') : ('<input id="button-select-' + mmdd.replace('/', '-') + '-' + j + '-' + (((eventsData[role][mmdd][j].makercheckers != null && (eventsData[role][mmdd][j].makercheckers).length > 0)) ? '1' : '0') + '-' + (((eventsData[role][mmdd][j].docs != null && (eventsData[role][mmdd][j].docs).length > 0)) ? '1' : '0') + '-' + eventsData[role][mmdd][j].entityid.replace(/-/g, '_') + '-' + eventsData[role][mmdd][j].locationid.replace(/-/g, '_') + '-' + eventsData[role][mmdd][j].id.replace(/-/g, '_') + '-' + eventsData[role][mmdd][j].duedate.split('/')[1] + '-' + eventsData[role][mmdd][j].duedate.split('/')[0] + '-' + eventsData[role][mmdd][j].duedate.split('/')[2] + '-' + partStatus.replace(/-/g, '_') + '" class="button-select mr-10 ' + ((eventsData[role][mmdd][j].reportformat != null && eventsData[role][mmdd][j].reportformat.length > 0) ? 'hide' : '') + '" type="checkbox" />')) + (eventsData[role][mmdd][j].isbulk ? '' : ('<button id="button-unmapped-expand-' + mmdd.replace('/', '-') + '-' + j + '" part="button-icon-small" class="material-icons button-expand mr-10">open_in_new</button>')) + '<sf-i-elastic-text text="' + eventsData[role][mmdd][j]['obligationtitle'] + '" minLength="100"></sf-i-elastic-text> ' + '<div part="td-body"><sf-i-elastic-text text="' + eventsData[role][mmdd][j]["locationname"].replace(/ *\([^)]*\) */g, "") + '" minLength="30"></sf-i-elastic-text></div> <div part="upcoming-function">' + functionStr + '</div> ' + this.renderStatusHtml(partStatus, lateStatus, complianceStatus, i);
|
|
23658
|
+
eventHtml += '<div part="stream-events-event-title" class="stream-events-event-title d-flex align-center pl-5 pb-5 mb-10">' + (eventsData[role][mmdd][j].isbulk ? ('<div class="lds-dual-ring1 bulk-loader mr-10"></div>') : ('<input id="button-select-' + mmdd.replace('/', '-') + '-' + j + '-' + (((eventsData[role][mmdd][j].makercheckers != null && (eventsData[role][mmdd][j].makercheckers).length > 0)) ? '1' : '0') + '-' + (((eventsData[role][mmdd][j].docs != null && (eventsData[role][mmdd][j].docs).length > 0)) ? '1' : '0') + '-' + eventsData[role][mmdd][j].entityid.replace(/-/g, '_') + '-' + eventsData[role][mmdd][j].locationid.replace(/-/g, '_') + '-' + eventsData[role][mmdd][j].id.replace(/-/g, '_') + '-' + eventsData[role][mmdd][j].duedate.split('/')[1] + '-' + eventsData[role][mmdd][j].duedate.split('/')[0] + '-' + eventsData[role][mmdd][j].duedate.split('/')[2] + '-' + partStatus.replace(/-/g, '_') + '" class="button-select mr-10 ' + ((eventsData[role][mmdd][j].reportformat != null && eventsData[role][mmdd][j].reportformat.length > 0) ? 'hide' : '') + '" type="checkbox" />')) + (eventsData[role][mmdd][j].isbulk ? '' : ('<button id="button-unmapped-expand-' + mmdd.replace('/', '-') + '-' + j + '" part="button-icon-small" class="material-icons button-expand mr-10">open_in_new</button>')) + '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + eventsData[role][mmdd][j]['obligationtitle'] + '" minLength="100"></sf-i-elastic-text> ' + '<div part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + eventsData[role][mmdd][j]["locationname"].replace(/ *\([^)]*\) */g, "") + '" minLength="30"></sf-i-elastic-text></div> <div part="upcoming-function">' + functionStr + '</div> ' + this.renderStatusHtml(partStatus, lateStatus, complianceStatus, i);
|
|
23368
23659
|
console.log('next isBulk', eventsData[role][mmdd][j].isbulk);
|
|
23369
23660
|
if (eventsData[role][mmdd][j].isbulk == null || eventsData[role][mmdd][j].isbulk == false) {
|
|
23370
|
-
eventHtml += '<button id="button-list-reporting-' + mmdd.replace('/', '-') + '-' + j + '" part="button-list-reporting" class="material-icons ml-10 button-list-reporting">edit_note</button>';
|
|
23661
|
+
eventHtml += '<button id="button-list-reporting-' + mmdd.replace('/', '-') + '-' + j + '-" part="button-list-reporting" class="material-icons ml-10 button-list-reporting">edit_note</button>';
|
|
23371
23662
|
eventHtml += '</div>';
|
|
23372
23663
|
eventHtml += '<div class="list-reporting-container d-flex flex-col hide" part="list-reporting-container" id="list-reporting-container-' + mmdd.replace(/\//g, '-') + '-' + j + '"></div>';
|
|
23373
23664
|
}
|
|
@@ -23631,7 +23922,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
23631
23922
|
if (!this.EXCLUDE_COLS_FROM_REGS.includes(Object.keys(JSON.parse(report['event']))[i].toLowerCase())) {
|
|
23632
23923
|
html += '<td part="td-body-register">';
|
|
23633
23924
|
html += ('<span part="td-head" style="padding-left: 0px !important">' + Object.keys(JSON.parse(report['event']))[i] + '</span>');
|
|
23634
|
-
html += ('<span part="td-body"><sf-i-elastic-text text="' + JSON.parse(report['event'])[Object.keys(JSON.parse(report['event']))[i]] + '" lineSize="4" minLength="60"></sf-i-elastic-text>' + '</span>');
|
|
23925
|
+
html += ('<span part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + JSON.parse(report['event'])[Object.keys(JSON.parse(report['event']))[i]] + '" lineSize="4" minLength="60"></sf-i-elastic-text>' + '</span>');
|
|
23635
23926
|
html += '</td>';
|
|
23636
23927
|
}
|
|
23637
23928
|
}
|
|
@@ -23913,7 +24204,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
23913
24204
|
eventHtml += '<div class="stream-events-container flex-grow">';
|
|
23914
24205
|
eventHtml += '<div class="hidden-tags hide">' + JSON.stringify(eventsData[mmdd][j]['tags']) + '</div>';
|
|
23915
24206
|
eventHtml += '<div class="hidden-title hide"><table><thead><th part="badge-filtered"><i>not filtered</i></th></thead></table></div>';
|
|
23916
|
-
eventHtml += '<div part="stream-events-event-title" class="stream-events-event-title d-flex align-center pl-5 pb-5 mb-10">' + '<button id="button-unmapped-expand-' + mmdd.replace('/', '-') + '-' + j + '" part="button-icon-small" class="material-icons button-expand mr-10">check</button>' + '<sf-i-elastic-text text="' + eventsData[mmdd][j]['obligationtitle'] + '" minLength="100"></sf-i-elastic-text> ' + '<div part="td-body"><sf-i-elastic-text text="' + eventsData[mmdd][j]["locationname"].replace(/ *\([^)]*\) */g, "") + '" minLength="30"></sf-i-elastic-text></div> <div part="upcoming-function">' + functionStr + '</div> ' + this.renderStatusHtml(partStatus, lateStatus, complianceStatus, i) + '</div>';
|
|
24207
|
+
eventHtml += '<div part="stream-events-event-title" class="stream-events-event-title d-flex align-center pl-5 pb-5 mb-10">' + '<button id="button-unmapped-expand-' + mmdd.replace('/', '-') + '-' + j + '" part="button-icon-small" class="material-icons button-expand mr-10">check</button>' + '<sf-i-elastic-text exportparts="highlight,highlight-count" text="' + eventsData[mmdd][j]['obligationtitle'] + '" minLength="100"></sf-i-elastic-text> ' + '<div part="td-body"><sf-i-elastic-text exportparts="highlight,highlight-count" text="' + eventsData[mmdd][j]["locationname"].replace(/ *\([^)]*\) */g, "") + '" minLength="30"></sf-i-elastic-text></div> <div part="upcoming-function">' + functionStr + '</div> ' + this.renderStatusHtml(partStatus, lateStatus, complianceStatus, i) + '</div>';
|
|
23917
24208
|
eventHtml += '</div>';
|
|
23918
24209
|
html += eventHtml;
|
|
23919
24210
|
}
|
|
@@ -25623,7 +25914,8 @@ SfIEvents.styles = css `
|
|
|
25623
25914
|
right: 5px;
|
|
25624
25915
|
background-color: white;
|
|
25625
25916
|
border: solid 1px #888;
|
|
25626
|
-
border-radius: 5px
|
|
25917
|
+
border-radius: 5px;
|
|
25918
|
+
width: max-content;
|
|
25627
25919
|
}
|
|
25628
25920
|
|
|
25629
25921
|
.filter-button-container{
|