sf-i-events 1.0.805 → 1.0.807
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 +20 -4
- package/package.json +1 -1
- package/sf-i-events.d.ts +1 -1
- package/sf-i-events.js +92 -87
- package/src/sf-i-events.ts +94 -95
package/dev/index.html
CHANGED
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
import {LitElement, html, css} from 'https://esm.run/lit-element/lit-element.js';
|
|
21
21
|
import {SfISelect} from 'https://esm.run/sf-i-select@1.0.92/sf-i-select.js';
|
|
22
22
|
import {SfISubSelect} from 'https://esm.run/sf-i-sub-select@1.0.83/sf-i-sub-select.js';
|
|
23
|
-
import {SfIForm} from 'https://esm.run/sf-i-form@1.0.
|
|
23
|
+
import {SfIForm} from 'https://esm.run/sf-i-form@1.0.184/sf-i-form.js';
|
|
24
24
|
import {SfIElasticText} from 'https://esm.run/sf-i-elastic-text@1.0.17/sf-i-elastic-text.js';
|
|
25
25
|
import {SfIUploader} from 'https://esm.run/sf-i-uploader@1.0.105/sf-i-uploader.js';
|
|
26
26
|
import {SfIMultitextarea} from 'https://esm.run/sf-i-multitextarea@1.0.23/sf-i-multitextarea.js';
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
// import {SfUserAuth} from 'https://unpkg.com/sf-user-auth@1.0.87/sf-user-auth.js?module';
|
|
35
35
|
// import {SfISelect} from 'https://unpkg.com/sf-i-select@1.0.91/sf-i-select.js?module';
|
|
36
36
|
// import {SfISubSelect} from 'https://unpkg.com/sf-i-sub-select@1.0.82/sf-i-sub-select.js?module';
|
|
37
|
-
// import {SfIForm} from 'https://unpkg.com/sf-i-form@1.0.
|
|
37
|
+
// import {SfIForm} from 'https://unpkg.com/sf-i-form@1.0.184/sf-i-form.js?module';
|
|
38
38
|
// import {SfIEvents} from 'https://unpkg.com/sf-i-events@1.0.423/sf-i-events.js?module';
|
|
39
39
|
// import {SfIElasticText} from 'https://unpkg.com/sf-i-elastic-text@1.0.7/sf-i-elastic-text.js?module';
|
|
40
40
|
// import {SfIUploader} from 'https://unpkg.com/sf-i-uploader@1.0.102/sf-i-uploader.js?module';
|
|
@@ -672,6 +672,22 @@
|
|
|
672
672
|
</style>
|
|
673
673
|
</head>
|
|
674
674
|
<body>
|
|
675
|
+
<!-- <sf-i-events projectid="a81b6ae1-98de-4b72-8cf0-9aaee5b61891" projectname="Khaitan" mode="onboarding" locations="{}" contractstartdate="01/01/2025" apiid="dwqyez2puoxmu.cloudfront.net/event" username="ninad.t@flagggrc.tech" apiidstatutes="dnytrdlrmxgsy.cloudfront.net/statute" apiidcompliances="dnytrdlrmxgsy.cloudfront.net/compliance" apiidtags="dnytrdlrmxgsy.cloudfront.net/tagging" apiidusers="dnytrdlrmxgsy.cloudfront.net/userprofile" disablesignoff="yes" disableclientresponse="yes">
|
|
676
|
+
|
|
677
|
+
</sf-i-events> -->
|
|
678
|
+
<sf-i-events projectid="a81b6ae1-98de-4b72-8cf0-9aaee5b61891" projectname="Khaitan" mode="onboarding" locations="{}" contractstartdate="01/01/2025" apiid="dwqyez2puoxmu.cloudfront.net/event" username="ninad.t@flagggrc.tech" apiidstatutes="dnytrdlrmxgsy.cloudfront.net/statute" apiidcompliances="dnytrdlrmxgsy.cloudfront.net/compliance" apiidtags="dnytrdlrmxgsy.cloudfront.net/tagging" apiidusers="dnytrdlrmxgsy.cloudfront.net/userprofile" disablesignoff="yes" disableclientresponse="yes">
|
|
679
|
+
|
|
680
|
+
</sf-i-events>
|
|
681
|
+
<!-- <sf-i-events name="Calendar" apiid="dwqyez2puoxmu.cloudfront.net/event" mode="consumer" apiidtags="dnytrdlrmxgsy.cloudfront.net/tagging" apiidstatutes="dnytrdlrmxgsy.cloudfront.net/statute" apiiddefinitions="dwqyez2puoxmu.cloudfront.net/definition" apiidreportformats="dwqyez2puoxmu.cloudfront.net/reportformat" apiidnotices="gghnbi7hku2qj5twrea6xxcaya0aqeis.lambda-url.us-east-1.on.aws" fill="solid" username="Precisionmed Reporter" userprofileid="fe5070fe-9982-4dcf-8458-f8d4f97c7b01" projectid="63d20443-b9cc-4a86-b39d-bf81c1c93ba5" projectname="PrecisionMed ABC" countryid="f443b70d-6609-42e0-b6a4-446bfa05d20a" myrole="reporter" showregisterexport="false" features="[]" eventfielddependencies="[{"type": "foreignkey", "parent": "country", "child": "state"},{"type": "foreignkey", "parent": "category", "child": "subcategory"},{"type": "foreignkey", "parent": "frequency", "child": "subfrequency"}]" eventfields="[{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/riskarea", "field": "riskarea"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/jurisdiction", "field": "jurisdiction"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/updatetype", "field": "updatetype"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/country", "field": "country"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/specificity", "field": "specificity"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/risk", "field": "risk"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/frequency", "field": "frequency"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/category", "field": "category"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/obligationtype", "field": "obligationtype"},{"type": "sf-i-sub-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/state", "field": "state"},{"type": "sf-i-sub-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/subfrequency", "field": "subfrequency"},{"type": "sf-i-sub-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/subcategory", "field": "subcategory"},{"type": "sf-i-form", "apiId": "dnytrdlrmxgsy.cloudfront.net/statute", "field": "statute", "projectField": "name"}]" eventpreviewfields="["obligation"]" eventhidefields="["comments","documents","lastupdated","approved","tags"]" calendarstartdd="01" calendarstartmm="04" calendarstartyyyy="2024">
|
|
682
|
+
|
|
683
|
+
<div slot="uploader">
|
|
684
|
+
<sf-i-uploader id="uploader" max="10" apiid="1peg5170d3" allowedextensions="["jpg","png","pdf","xls","xlsx","doc","docx"]" extract="yes" projectid="63d20443-b9cc-4a86-b39d-bf81c1c93ba5" maxsize="5242880" allowdownload="yes"></sf-i-uploader>
|
|
685
|
+
</div>
|
|
686
|
+
<div slot="reporting">
|
|
687
|
+
<sf-i-reporting id="reporting-format" mode="view"></sf-i-reporting>
|
|
688
|
+
</div>
|
|
689
|
+
|
|
690
|
+
</sf-i-events> -->
|
|
675
691
|
<!-- <sf-i-events name="Calendar" apiid="dwqyez2puoxmu.cloudfront.net/event" mode="consumer" apiidtags="dnytrdlrmxgsy.cloudfront.net/tagging" apiidstatutes="dnytrdlrmxgsy.cloudfront.net/statute" apiiddefinitions="dwqyez2puoxmu.cloudfront.net/definition" apiidreportformats="dwqyez2puoxmu.cloudfront.net/reportformat" apiidnotices="gghnbi7hku2qj5twrea6xxcaya0aqeis.lambda-url.us-east-1.on.aws" fill="solid" username="Chief Compliance Officer" userprofileid="5fe96caa-1a44-4a2d-921a-920d29433eca" projectid="41ab3c86-ccc0-4c0e-8e31-cd079a07a710" projectname="ABC Global" countryid="07d73b44-648d-4301-82c4-d6df43397824" myrole="functionhead" showregisterexport="false" features="["notices"]" eventfielddependencies="[{"type": "foreignkey", "parent": "country", "child": "state"},{"type": "foreignkey", "parent": "category", "child": "subcategory"},{"type": "foreignkey", "parent": "frequency", "child": "subfrequency"}]" eventfields="[{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/riskarea", "field": "riskarea"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/jurisdiction", "field": "jurisdiction"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/updatetype", "field": "updatetype"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/country", "field": "country"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/specificity", "field": "specificity"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/risk", "field": "risk"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/frequency", "field": "frequency"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/category", "field": "category"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/obligationtype", "field": "obligationtype"},{"type": "sf-i-sub-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/state", "field": "state"},{"type": "sf-i-sub-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/subfrequency", "field": "subfrequency"},{"type": "sf-i-sub-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/subcategory", "field": "subcategory"},{"type": "sf-i-form", "apiId": "dnytrdlrmxgsy.cloudfront.net/statute", "field": "statute", "projectField": "name"}]" eventpreviewfields="["obligation"]" eventhidefields="["comments","documents","lastupdated","approved","tags"]" calendarstartdd="01" calendarstartmm="04" calendarstartyyyy="2024">
|
|
676
692
|
|
|
677
693
|
<div slot="uploader">
|
|
@@ -702,7 +718,7 @@
|
|
|
702
718
|
</div>
|
|
703
719
|
|
|
704
720
|
</sf-i-events> -->
|
|
705
|
-
<sf-i-events name="Calendar" apiid="dwqyez2puoxmu.cloudfront.net/event" mode="consumer" apiidtags="dnytrdlrmxgsy.cloudfront.net/tagging" apiidstatutes="dnytrdlrmxgsy.cloudfront.net/statute" apiiddefinitions="dwqyez2puoxmu.cloudfront.net/definition" apiidreportformats="dwqyez2puoxmu.cloudfront.net/reportformat" apiidnotices="gghnbi7hku2qj5twrea6xxcaya0aqeis.lambda-url.us-east-1.on.aws" fill="solid" username="Chief Compliance Officer" userprofileid="5fe96caa-1a44-4a2d-921a-920d29433eca" projectid="41ab3c86-ccc0-4c0e-8e31-cd079a07a710" projectname="ABC Global" countryid="07d73b44-648d-4301-82c4-d6df43397824" myrole="functionhead" showregisterexport="false" features="["notices"]" eventfielddependencies="[{"type": "foreignkey", "parent": "country", "child": "state"},{"type": "foreignkey", "parent": "category", "child": "subcategory"},{"type": "foreignkey", "parent": "frequency", "child": "subfrequency"}]" eventfields="[{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/riskarea", "field": "riskarea"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/jurisdiction", "field": "jurisdiction"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/updatetype", "field": "updatetype"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/country", "field": "country"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/specificity", "field": "specificity"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/risk", "field": "risk"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/frequency", "field": "frequency"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/category", "field": "category"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/obligationtype", "field": "obligationtype"},{"type": "sf-i-sub-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/state", "field": "state"},{"type": "sf-i-sub-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/subfrequency", "field": "subfrequency"},{"type": "sf-i-sub-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/subcategory", "field": "subcategory"},{"type": "sf-i-form", "apiId": "dnytrdlrmxgsy.cloudfront.net/statute", "field": "statute", "projectField": "name"}]" eventpreviewfields="["obligation"]" eventhidefields="["comments","documents","lastupdated","approved","tags"]" calendarstartdd="01" calendarstartmm="04" calendarstartyyyy="2024">
|
|
721
|
+
<!-- <sf-i-events name="Calendar" apiid="dwqyez2puoxmu.cloudfront.net/event" mode="consumer" apiidtags="dnytrdlrmxgsy.cloudfront.net/tagging" apiidstatutes="dnytrdlrmxgsy.cloudfront.net/statute" apiiddefinitions="dwqyez2puoxmu.cloudfront.net/definition" apiidreportformats="dwqyez2puoxmu.cloudfront.net/reportformat" apiidnotices="gghnbi7hku2qj5twrea6xxcaya0aqeis.lambda-url.us-east-1.on.aws" fill="solid" username="Chief Compliance Officer" userprofileid="5fe96caa-1a44-4a2d-921a-920d29433eca" projectid="41ab3c86-ccc0-4c0e-8e31-cd079a07a710" projectname="ABC Global" countryid="07d73b44-648d-4301-82c4-d6df43397824" myrole="functionhead" showregisterexport="false" features="["notices"]" eventfielddependencies="[{"type": "foreignkey", "parent": "country", "child": "state"},{"type": "foreignkey", "parent": "category", "child": "subcategory"},{"type": "foreignkey", "parent": "frequency", "child": "subfrequency"}]" eventfields="[{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/riskarea", "field": "riskarea"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/jurisdiction", "field": "jurisdiction"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/updatetype", "field": "updatetype"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/country", "field": "country"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/specificity", "field": "specificity"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/risk", "field": "risk"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/frequency", "field": "frequency"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/category", "field": "category"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/obligationtype", "field": "obligationtype"},{"type": "sf-i-sub-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/state", "field": "state"},{"type": "sf-i-sub-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/subfrequency", "field": "subfrequency"},{"type": "sf-i-sub-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/subcategory", "field": "subcategory"},{"type": "sf-i-form", "apiId": "dnytrdlrmxgsy.cloudfront.net/statute", "field": "statute", "projectField": "name"}]" eventpreviewfields="["obligation"]" eventhidefields="["comments","documents","lastupdated","approved","tags"]" calendarstartdd="01" calendarstartmm="04" calendarstartyyyy="2024">
|
|
706
722
|
|
|
707
723
|
<div slot="uploader">
|
|
708
724
|
<sf-i-uploader id="uploader" max="10" apiid="1peg5170d3" allowedextensions="["jpg","png","pdf","xls","xlsx","doc","docx"]" extract="yes" projectid="41ab3c86-ccc0-4c0e-8e31-cd079a07a710" maxsize="5242880" allowdownload="yes"></sf-i-uploader>
|
|
@@ -711,7 +727,7 @@
|
|
|
711
727
|
<sf-i-reporting id="reporting-format" mode="view"></sf-i-reporting>
|
|
712
728
|
</div>
|
|
713
729
|
|
|
714
|
-
</sf-i-events>
|
|
730
|
+
</sf-i-events> -->
|
|
715
731
|
<!-- <sf-i-events name="Calendar" apiid="dwqyez2puoxmu.cloudfront.net/event" mode="consumer" apiidtags="dnytrdlrmxgsy.cloudfront.net/tagging" apiidstatutes="dnytrdlrmxgsy.cloudfront.net/statute" apiiddefinitions="dwqyez2puoxmu.cloudfront.net/definition" apiidreportformats="dwqyez2puoxmu.cloudfront.net/reportformat" apiidnotices="gghnbi7hku2qj5twrea6xxcaya0aqeis.lambda-url.us-east-1.on.aws" fill="solid" username="Local Reporter 1" userprofileid="e9684b5d-ddbc-46d3-ae07-51706bf75410" projectid="41ab3c86-ccc0-4c0e-8e31-cd079a07a710" projectname="ABC Global" countryid="07d73b44-648d-4301-82c4-d6df43397824" myrole="reporter" showregisterexport="false" features="["notices"]" eventfielddependencies="[{"type": "foreignkey", "parent": "country", "child": "state"},{"type": "foreignkey", "parent": "category", "child": "subcategory"},{"type": "foreignkey", "parent": "frequency", "child": "subfrequency"}]" eventfields="[{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/riskarea", "field": "riskarea"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/jurisdiction", "field": "jurisdiction"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/updatetype", "field": "updatetype"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/country", "field": "country"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/specificity", "field": "specificity"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/risk", "field": "risk"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/frequency", "field": "frequency"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/category", "field": "category"},{"type": "sf-i-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/obligationtype", "field": "obligationtype"},{"type": "sf-i-sub-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/state", "field": "state"},{"type": "sf-i-sub-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/subfrequency", "field": "subfrequency"},{"type": "sf-i-sub-select", "apiId": "dnytrdlrmxgsy.cloudfront.net/subcategory", "field": "subcategory"},{"type": "sf-i-form", "apiId": "dnytrdlrmxgsy.cloudfront.net/statute", "field": "statute", "projectField": "name"}]" eventpreviewfields="["obligation"]" eventhidefields="["comments","documents","lastupdated","approved","tags"]" calendarstartdd="01" calendarstartmm="04" calendarstartyyyy="2024">
|
|
716
732
|
|
|
717
733
|
<div slot="uploader">
|
package/package.json
CHANGED
package/sf-i-events.d.ts
CHANGED
|
@@ -93,7 +93,7 @@ export declare class SfIEvents extends LitElement {
|
|
|
93
93
|
COLOR_NOT_COMPLIED: string;
|
|
94
94
|
COLOR_PARTIALLY_COMPLIED: string;
|
|
95
95
|
COLOR_COMPLIED: string;
|
|
96
|
-
|
|
96
|
+
COLOR_COMPLIED_WITH_EXCEPTION: string;
|
|
97
97
|
COLOR_REPORTED_NON_COMPLIANCE: string;
|
|
98
98
|
STATUS_NOT_STARTED: string;
|
|
99
99
|
STATUS_PENDING_APPROVAL: string;
|
package/sf-i-events.js
CHANGED
|
@@ -113,7 +113,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
113
113
|
this.COLOR_NOT_COMPLIED = "#C80036";
|
|
114
114
|
this.COLOR_PARTIALLY_COMPLIED = "#F79256";
|
|
115
115
|
this.COLOR_COMPLIED = "#50cf01";
|
|
116
|
-
this.
|
|
116
|
+
this.COLOR_COMPLIED_WITH_EXCEPTION = "#ffe505";
|
|
117
117
|
this.COLOR_REPORTED_NON_COMPLIANCE = "#840B0F";
|
|
118
118
|
this.STATUS_NOT_STARTED = "not-started";
|
|
119
119
|
this.STATUS_PENDING_APPROVAL = "pending-approval";
|
|
@@ -2322,7 +2322,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
2322
2322
|
html += '<div part="badge-dashboard" id="chip-compliance-2" class="chip stat-compliance justify-center align-center mr-10 mb-10 no-shrink compliance-statuses"><span class="material-icons color-partially-complied">rule</span> <span>Partially Complied:</span> <span id="graph-partially-complied">DASHBOARD_PARTIALLY_COMPLIED</span></div>';
|
|
2323
2323
|
html += '<div part="badge-dashboard" id="chip-compliance-3" class="chip stat-compliance justify-center align-center mr-10 mb-10 no-shrink compliance-statuses"><span class="material-symbols-outlined color-complied">sweep</span> <span>Complied:</span> <span id="graph-complied">DASHBOARD_COMPLIED</span></div>';
|
|
2324
2324
|
html += '<div part="badge-dashboard" id="chip-compliance-4" class="chip stat-compliance justify-center align-center mr-10 mb-10 no-shrink compliance-statuses"><span class="material-symbols-outlined color-complied-with-gaps">rule</span> <span>Complied With Gaps:</span> <span id="graph-complied-with-gaps">DASHBOARD_COMPLIED_WITH_GAPS</span></div>';
|
|
2325
|
-
html += '<div part="badge-dashboard" id="chip-compliance-5" class="chip stat-compliance justify-center align-center mr-10 mb-10 no-shrink compliance-statuses"><span class="material-symbols-outlined color-reported-non-compliance">rule</span> <span>Reported Non Compliance:</span> <span id="graph-reported-non-compliance">
|
|
2325
|
+
html += '<div part="badge-dashboard" id="chip-compliance-5" class="chip stat-compliance justify-center align-center mr-10 mb-10 no-shrink compliance-statuses"><span class="material-symbols-outlined color-reported-non-compliance">rule</span> <span>Reported Non Compliance:</span> <span id="graph-reported-non-compliance">DASHBOARD_COMPLIED_WITH_GAPS</span></div>';
|
|
2326
2326
|
html += '</div>';
|
|
2327
2327
|
html += '<div id="stream-event-filter" part="stream-event-total" class="d-flex flex-wrap"></div>';
|
|
2328
2328
|
return html;
|
|
@@ -2914,15 +2914,14 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
2914
2914
|
html = html.replace("DASHBOARD_PARTIALLY_COMPLIED", partiallyComplied + "");
|
|
2915
2915
|
html = html.replace("DASHBOARD_COMPLIED", complied + "");
|
|
2916
2916
|
html = html.replace("DASHBOARD_COMPLIED_WITH_GAPS", compliedWithGaps + "");
|
|
2917
|
-
|
|
2918
|
-
this.csvDataStats
|
|
2919
|
-
this.csvDataStats += this.period + "," + total + "," + notStarted + "," + approved + "," + pendingApproval + "," + rejected + "," + pastDueDate + "," + lateReported + "," + lateExecuted + "," + lateApproved + "," + scheduled + "," + notComplied + "," + partiallyComplied + "," + complied + "," + compliedWithGaps + "," + reportedNonCompliance;
|
|
2917
|
+
this.csvDataStats = 'Period,Total,Not Started,Approved,Pending Approval,Rejected,Past Due Date,Late Reported,Late Executed,Late Approved,Scheduled,Not Complied,Partially Complied,Complied,Complied With Gaps\n';
|
|
2918
|
+
this.csvDataStats += this.period + "," + total + "," + notStarted + "," + approved + "," + pendingApproval + "," + rejected + "," + pastDueDate + "," + lateReported + "," + lateExecuted + "," + lateApproved + "," + scheduled + "," + notComplied + "," + partiallyComplied + "," + complied + "," + compliedWithGaps;
|
|
2920
2919
|
this.htmlDataStats = 'Completeness<br /><br /><table class="w-100"><tr><th class="w-14">Total</th><th class="w-14">Not Started</th><th class="w-14">Approved</th><th class="w-14">Pending Approval</th><th class="w-14">Rejected</th><tr>';
|
|
2921
2920
|
this.htmlDataStats += '<tr><td class="w-14 text-center td-odd">' + total + '</td><td class="w-14 text-center td-odd">' + notStarted + '</td><td class="w-14 text-center td-odd">' + approved + '</td><td class="w-14 text-center td-odd">' + pendingApproval + '</td><td class="w-14 text-center td-odd">' + rejected + '</td></table>';
|
|
2922
2921
|
this.htmlDataStats += '<br /><br />Timeliness<br /><br /><table class="mt-20 w-100"><tr><th class="w-14">Total</th><th class="w-14">In Time</th><th class="w-14">Past Due Date</th><th class="w-14">Late Reported</th><th class="w-14">Late Executed</th><th class="w-14">Late Approved</th><tr>';
|
|
2923
2922
|
this.htmlDataStats += '<tr><td class="w-14 text-center td-odd">' + total + '</td><td class="w-14 text-center td-odd">' + (total - (pastDueDate + lateApproved + lateExecuted)) + '</td><td class="w-14 text-center td-odd">' + pastDueDate + '</td><td class="w-14 text-center td-odd">' + lateReported + '</td><td class="w-14 text-center td-odd">' + lateExecuted + '</td><td class="w-14 text-center td-odd">' + lateApproved + '</td><tr></table>';
|
|
2924
|
-
this.htmlDataStats += '<br /><br />Compliance<br /><br /><table class="w-100"><tr><th class="w-14">Total</th><th class="w-14">Scheduled</th><th class="w-14">Not Complied</th><th class="w-14">Partially Complied</th><th class="w-14">Complied</th><th class="w-14">Complied With Gaps</th><
|
|
2925
|
-
this.htmlDataStats += '<tr><td class="w-14 text-center td-odd">' + total + '</td><td class="w-14 text-center td-odd">' + scheduled + '</td><td class="w-14 text-center td-odd">' + notComplied + '</td><td class="w-14 text-center td-odd">' + partiallyComplied + '</td><td class="w-14 text-center td-odd">' + complied + '</td><td class="w-14 text-center td-odd">' + compliedWithGaps + '</td><
|
|
2923
|
+
this.htmlDataStats += '<br /><br />Compliance<br /><br /><table class="w-100"><tr><th class="w-14">Total</th><th class="w-14">Scheduled</th><th class="w-14">Not Complied</th><th class="w-14">Partially Complied</th><th class="w-14">Complied</th><th class="w-14">Complied With Gaps</th><tr>';
|
|
2924
|
+
this.htmlDataStats += '<tr><td class="w-14 text-center td-odd">' + total + '</td><td class="w-14 text-center td-odd">' + scheduled + '</td><td class="w-14 text-center td-odd">' + notComplied + '</td><td class="w-14 text-center td-odd">' + partiallyComplied + '</td><td class="w-14 text-center td-odd">' + complied + '</td><td class="w-14 text-center td-odd">' + compliedWithGaps + '</td><tr></table>';
|
|
2926
2925
|
return html;
|
|
2927
2926
|
};
|
|
2928
2927
|
this.renderStatistics = (_firstDay, _endDay, iInit, iLast, showGraph, index, month, period, firstDate = null, parametersTitle) => {
|
|
@@ -8419,7 +8418,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
8419
8418
|
this.clearGraph(divContainer, 3);
|
|
8420
8419
|
this.clearGraph(divContainer, 4);
|
|
8421
8420
|
const data = {
|
|
8422
|
-
labels: ['Scheduled', 'Not Complied', 'Partially Complied', 'Complied', 'Complied With Gaps', 'Reported Non
|
|
8421
|
+
labels: ['Scheduled', 'Not Complied', 'Partially Complied', 'Complied', 'Complied With Gaps', 'Reported Non Complinace'],
|
|
8423
8422
|
datasets: [{
|
|
8424
8423
|
label: 'Compliances',
|
|
8425
8424
|
data: [dataScheduled, dataNotComplied, dataPartiallyComplied, dataComplied, dataCompliedWithGaps, dataReportedNonComplaince],
|
|
@@ -8429,7 +8428,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
8429
8428
|
this.COLOR_NOT_COMPLIED,
|
|
8430
8429
|
this.COLOR_PARTIALLY_COMPLIED,
|
|
8431
8430
|
this.COLOR_COMPLIED,
|
|
8432
|
-
this.
|
|
8431
|
+
this.COLOR_COMPLIED_WITH_EXCEPTION,
|
|
8433
8432
|
this.COLOR_REPORTED_NON_COMPLIANCE
|
|
8434
8433
|
]
|
|
8435
8434
|
}]
|
|
@@ -8672,7 +8671,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
8672
8671
|
for (i = 0; i < Object.keys(complianceData).length; i++) {
|
|
8673
8672
|
dataBar2['datasets'][4]['data'].push(complianceData[Object.keys(complianceData)[i]]['complied-with-gaps']);
|
|
8674
8673
|
}
|
|
8675
|
-
dataBar2['datasets'][4]['backgroundColor'] = this.
|
|
8674
|
+
dataBar2['datasets'][4]['backgroundColor'] = this.COLOR_COMPLIED_WITH_EXCEPTION;
|
|
8676
8675
|
dataBar2['datasets'][5]['label'] = 'Reported Non Compliance';
|
|
8677
8676
|
dataBar2['datasets'][5]['data'] = [];
|
|
8678
8677
|
for (i = 0; i < Object.keys(complianceData).length; i++) {
|
|
@@ -9592,7 +9591,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
9592
9591
|
};
|
|
9593
9592
|
this.fetchEventDetails = async (listEvent, mmddyyyy, currentColumnButton, eventsContainer) => {
|
|
9594
9593
|
console.log('listEvent', listEvent, listEvent.id);
|
|
9595
|
-
let url = "https://" + this.apiId + "/
|
|
9594
|
+
let url = "https://" + this.apiId + "/getalleventdetails";
|
|
9596
9595
|
//console.log('fetch calendar url', url);
|
|
9597
9596
|
let urlBody = { "projectid": this.projectId, "userprofileid": this.userProfileId, "role": this.myRole, "eventid": listEvent.id, "entityid": listEvent.entityid, "locationid": listEvent.locationid, "mmddyyyy": mmddyyyy, "year": this.calendarStartYYYY };
|
|
9598
9597
|
//console.log('urlbody', urlBody);
|
|
@@ -9645,8 +9644,8 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
9645
9644
|
//console.log('event detail documenttype', documentType);
|
|
9646
9645
|
const basicFields = ['id', 'shortid', 'entityname', 'locationname', 'functions'];
|
|
9647
9646
|
const statuteFields = ['jurisdiction', 'country', 'state', 'category', 'subcategory', 'statute'];
|
|
9648
|
-
const complianceFields = ['specificity', 'reference', 'obligation', 'penalty', 'authority', 'frequency', 'obligationtype', 'duedate', 'applicability', 'form'];
|
|
9649
|
-
const grcFields = ['internalcontrols', 'firstlineofdefence', 'risk', 'riskarea'];
|
|
9647
|
+
const complianceFields = ['specificity', 'reference', 'obligation', 'penalty', 'authority', 'frequency', 'subfrequency', 'obligationtype', 'duedate', 'applicability', 'form', 'additionalurls', 'adhocquestion', 'adhocquestionschedule', 'adhocinstances', 'uploadguidance'];
|
|
9648
|
+
const grcFields = ['internalcontrols', 'firstlineofdefence', 'secondlineofdefence', 'thirdlineofdefence', 'risk', 'riskarea'];
|
|
9650
9649
|
let listReportingContainers = eventsContainer.querySelectorAll('.list-reporting-container');
|
|
9651
9650
|
for (let tempReportingContainer of listReportingContainers) {
|
|
9652
9651
|
tempReportingContainer.style.display = 'none';
|
|
@@ -9747,16 +9746,18 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
9747
9746
|
html += '<div class="d-flex flex-wrap accordian-body body-statute" part="accordian-body">';
|
|
9748
9747
|
for (var i = 0; i < statuteFields.length; i++) {
|
|
9749
9748
|
if (!this.getEventPreviewFields().includes(statuteFields[i])) {
|
|
9750
|
-
if (
|
|
9751
|
-
|
|
9752
|
-
|
|
9753
|
-
|
|
9754
|
-
|
|
9755
|
-
|
|
9756
|
-
|
|
9757
|
-
|
|
9749
|
+
if (event[statuteFields[i]] != null && event[statuteFields[i]] != "") {
|
|
9750
|
+
if (!this.getEventHideFields().includes(statuteFields[i])) {
|
|
9751
|
+
html += '<div class="m-20">';
|
|
9752
|
+
html += '<div part="detail-head"><strong>' + statuteFields[i] + '</strong></div>';
|
|
9753
|
+
if ((event[statuteFields[i]] + "").indexOf("[") >= 0) {
|
|
9754
|
+
html += this.getEventTexts(statuteFields[i], JSON.parse(event[statuteFields[i]]), event);
|
|
9755
|
+
}
|
|
9756
|
+
else {
|
|
9757
|
+
html += '<sf-i-elastic-text text="' + (event[statuteFields[i]] + "").replace(/"/g, "") + '" minLength="80"></sf-i-elastic-text>';
|
|
9758
|
+
}
|
|
9759
|
+
html += '</div>';
|
|
9758
9760
|
}
|
|
9759
|
-
html += '</div>';
|
|
9760
9761
|
}
|
|
9761
9762
|
}
|
|
9762
9763
|
}
|
|
@@ -9774,28 +9775,30 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
9774
9775
|
//console.log(event[complianceFields[i]]);
|
|
9775
9776
|
if (!this.getEventPreviewFields().includes(complianceFields[i])) {
|
|
9776
9777
|
if (!this.getEventHideFields().includes(complianceFields[i])) {
|
|
9777
|
-
if (event[complianceFields[i]]
|
|
9778
|
-
|
|
9779
|
-
|
|
9780
|
-
|
|
9781
|
-
|
|
9782
|
-
|
|
9783
|
-
|
|
9784
|
-
|
|
9785
|
-
|
|
9786
|
-
|
|
9787
|
-
|
|
9788
|
-
|
|
9789
|
-
else {
|
|
9790
|
-
html += '<div class="m-20">';
|
|
9791
|
-
html += '<div part="detail-head"><strong>' + complianceFields[i] + '</strong></div>';
|
|
9792
|
-
if ((event[complianceFields[i]] + "").indexOf("[") >= 0) {
|
|
9793
|
-
html += this.getEventTexts(complianceFields[i], JSON.parse(event[complianceFields[i]]), event);
|
|
9778
|
+
if (event[complianceFields[i]] != null && event[complianceFields[i]] != "") {
|
|
9779
|
+
if (event[complianceFields[i]].indexOf('http://') >= 0) {
|
|
9780
|
+
let res = event[complianceFields[i]].split(" ").find((word) => word.startsWith("http"));
|
|
9781
|
+
html += '<div class="m-20">';
|
|
9782
|
+
html += '<div part="detail-head"><strong>' + complianceFields[i] + '</strong></div>';
|
|
9783
|
+
if ((event[complianceFields[i]] + "").indexOf("[") >= 0) {
|
|
9784
|
+
html += this.getEventTexts(complianceFields[i], JSON.parse(event[complianceFields[i]]), event) + " <a href=\"" + res + "\" target=\"_blank\">Open</a>";
|
|
9785
|
+
}
|
|
9786
|
+
else {
|
|
9787
|
+
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>";
|
|
9788
|
+
}
|
|
9789
|
+
html += '</div>';
|
|
9794
9790
|
}
|
|
9795
9791
|
else {
|
|
9796
|
-
html += '<
|
|
9792
|
+
html += '<div class="m-20">';
|
|
9793
|
+
html += '<div part="detail-head"><strong>' + complianceFields[i] + '</strong></div>';
|
|
9794
|
+
if ((event[complianceFields[i]] + "").indexOf("[") >= 0) {
|
|
9795
|
+
html += this.getEventTexts(complianceFields[i], JSON.parse(event[complianceFields[i]]), event);
|
|
9796
|
+
}
|
|
9797
|
+
else {
|
|
9798
|
+
html += '<sf-i-elastic-text text="' + (event[complianceFields[i]] + "").replace(/"/g, "").replace(/\n/g, '<br />') + '" minLength="80"></sf-i-elastic-text>';
|
|
9799
|
+
}
|
|
9800
|
+
html += '</div>';
|
|
9797
9801
|
}
|
|
9798
|
-
html += '</div>';
|
|
9799
9802
|
}
|
|
9800
9803
|
}
|
|
9801
9804
|
}
|
|
@@ -9811,25 +9814,27 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
9811
9814
|
for (var i = 0; i < grcFields.length; i++) {
|
|
9812
9815
|
//console.log(grcFields[i]);
|
|
9813
9816
|
if (!this.getEventPreviewFields().includes(grcFields[i])) {
|
|
9814
|
-
if (
|
|
9815
|
-
|
|
9816
|
-
|
|
9817
|
-
|
|
9818
|
-
|
|
9819
|
-
|
|
9820
|
-
|
|
9821
|
-
|
|
9822
|
-
|
|
9823
|
-
else {
|
|
9824
|
-
if ((event[grcFields[i]] + "").indexOf("[") >= 0) {
|
|
9825
|
-
html += this.getEventTexts(grcFields[i], JSON.parse(event[grcFields[i]]), event);
|
|
9817
|
+
if (event[grcFields[i]] != null && event[grcFields[i]] != "") {
|
|
9818
|
+
if (!this.getEventHideFields().includes(grcFields[i])) {
|
|
9819
|
+
html += '<div class="m-20">';
|
|
9820
|
+
html += '<div part="detail-head"><strong>' + grcFields[i] + '</strong></div>';
|
|
9821
|
+
if (grcFields[i].toLowerCase() == "riskarea") {
|
|
9822
|
+
const arrValues = event[grcFields[i]];
|
|
9823
|
+
for (var k = 0; k < arrValues.length; k++) {
|
|
9824
|
+
html += '<div part="detail-reporter-name" class="mr-10">' + arrValues[k] + '</div>';
|
|
9825
|
+
}
|
|
9826
9826
|
}
|
|
9827
9827
|
else {
|
|
9828
|
-
|
|
9829
|
-
|
|
9828
|
+
if ((event[grcFields[i]] + "").indexOf("[") >= 0) {
|
|
9829
|
+
html += this.getEventTexts(grcFields[i], JSON.parse(event[grcFields[i]]), event);
|
|
9830
|
+
}
|
|
9831
|
+
else {
|
|
9832
|
+
//console.log('grcfield', event[grcFields[i]]);
|
|
9833
|
+
html += '<sf-i-elastic-text text="' + (event[grcFields[i]] + "").replace(/"/g, "").replace(/\n/g, '<br />') + '" minLength="80"></sf-i-elastic-text>';
|
|
9834
|
+
}
|
|
9830
9835
|
}
|
|
9836
|
+
html += '</div>';
|
|
9831
9837
|
}
|
|
9832
|
-
html += '</div>';
|
|
9833
9838
|
}
|
|
9834
9839
|
}
|
|
9835
9840
|
}
|
|
@@ -15760,9 +15765,6 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
15760
15765
|
let graphparamname1Arr = graphparamnames1[i].innerHTML.toLowerCase().replace('&', '&').replace(/-/g, ' ').split(' • ');
|
|
15761
15766
|
let filterFound = false;
|
|
15762
15767
|
for (let tempFilterStr of graphparamname1Arr) {
|
|
15763
|
-
if (clickedValue == "reported non compliance") {
|
|
15764
|
-
console.log('comparing filter', tempFilterStr, this.graphParam.toLowerCase().replace('&', '&').replace(/-/g, ' '));
|
|
15765
|
-
}
|
|
15766
15768
|
if (tempFilterStr == this.graphParam.toLowerCase().replace('&', '&').replace(/-/g, ' ') || this.graphParam.toLowerCase().replace('&', '&').replace(/-/g, ' ') == "") {
|
|
15767
15769
|
filterFound = true;
|
|
15768
15770
|
break;
|
|
@@ -16934,7 +16936,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
16934
16936
|
}
|
|
16935
16937
|
};
|
|
16936
16938
|
this.uploadAudit = async (entityId, locationId, mmddyyyy, eventid, comments, approved, module = "events") => {
|
|
16937
|
-
let url = "https://" + this.apiId + "/
|
|
16939
|
+
let url = "https://" + this.apiId + "/uploadaudit";
|
|
16938
16940
|
const body = {
|
|
16939
16941
|
"mmddyyyy": mmddyyyy,
|
|
16940
16942
|
"projectid": this.projectId,
|
|
@@ -16972,7 +16974,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
16972
16974
|
}
|
|
16973
16975
|
};
|
|
16974
16976
|
this.uploadAuditsBulk = async (bulkBody) => {
|
|
16975
|
-
let url = "https://" + this.apiId + "/
|
|
16977
|
+
let url = "https://" + this.apiId + "/uploadauditsbulk";
|
|
16976
16978
|
const authorization = btoa(Util.readCookie('email') + ":" + Util.readCookie('accessToken'));
|
|
16977
16979
|
const xhr = (await this.prepareXhr(bulkBody, url, this._SfLoader, authorization));
|
|
16978
16980
|
this._SfLoader.innerHTML = '';
|
|
@@ -16988,7 +16990,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
16988
16990
|
}
|
|
16989
16991
|
};
|
|
16990
16992
|
this.uploadReview = async (entityId, locationId, mmddyyyy, eventid, comments, approved, module = "events") => {
|
|
16991
|
-
let url = "https://" + this.apiId + "/
|
|
16993
|
+
let url = "https://" + this.apiId + "/uploadreview";
|
|
16992
16994
|
const body = {
|
|
16993
16995
|
"mmddyyyy": mmddyyyy,
|
|
16994
16996
|
"projectid": this.projectId,
|
|
@@ -17030,7 +17032,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
17030
17032
|
}
|
|
17031
17033
|
};
|
|
17032
17034
|
this.uploadReportsReviewsBulk = async (bulkBody) => {
|
|
17033
|
-
let url = "https://" + this.apiId + "/
|
|
17035
|
+
let url = "https://" + this.apiId + "/uploadreportsreviewsbulk";
|
|
17034
17036
|
const authorization = btoa(Util.readCookie('email') + ":" + Util.readCookie('accessToken'));
|
|
17035
17037
|
const xhr = (await this.prepareXhr(bulkBody, url, this._SfLoader, authorization));
|
|
17036
17038
|
this._SfLoader.innerHTML = '';
|
|
@@ -17049,7 +17051,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
17049
17051
|
}
|
|
17050
17052
|
};
|
|
17051
17053
|
this.uploadReviewsBulk = async (bulkBody) => {
|
|
17052
|
-
let url = "https://" + this.apiId + "/
|
|
17054
|
+
let url = "https://" + this.apiId + "/uploadreviewsbulk";
|
|
17053
17055
|
const authorization = btoa(Util.readCookie('email') + ":" + Util.readCookie('accessToken'));
|
|
17054
17056
|
const xhr = (await this.prepareXhr(bulkBody, url, this._SfLoader, authorization));
|
|
17055
17057
|
this._SfLoader.innerHTML = '';
|
|
@@ -17068,7 +17070,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
17068
17070
|
}
|
|
17069
17071
|
};
|
|
17070
17072
|
this.uploadReport = async (entityId, locationId, mmddyyyy, eventid, comments, doc, docs, event, reportformatvalues = "", reportformatschema = "", module = "events", percentage = "100") => {
|
|
17071
|
-
let url = "https://" + this.apiId + "/
|
|
17073
|
+
let url = "https://" + this.apiId + "/uploadreport";
|
|
17072
17074
|
let body = {
|
|
17073
17075
|
"mmddyyyy": mmddyyyy,
|
|
17074
17076
|
"projectid": this.projectId,
|
|
@@ -17117,7 +17119,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
17117
17119
|
}
|
|
17118
17120
|
};
|
|
17119
17121
|
this.uploadReportsBulk = async (bulkBody, showSuccess = true) => {
|
|
17120
|
-
let url = "https://" + this.apiId + "/
|
|
17122
|
+
let url = "https://" + this.apiId + "/uploadreportsbulk";
|
|
17121
17123
|
const authorization = btoa(Util.readCookie('email') + ":" + Util.readCookie('accessToken'));
|
|
17122
17124
|
const xhr = (await this.prepareXhr(bulkBody, url, this._SfLoader, authorization));
|
|
17123
17125
|
if (showSuccess) {
|
|
@@ -17407,25 +17409,28 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
17407
17409
|
if (statute.fields.cols[0].indexOf('definitions') >= 0) {
|
|
17408
17410
|
const definitionsIndex = JSON.parse(statute.fields.cols[0]).indexOf('definitions');
|
|
17409
17411
|
const definitionsFound = JSON.parse(statute.fields.data[0])[definitionsIndex];
|
|
17410
|
-
|
|
17411
|
-
|
|
17412
|
-
|
|
17413
|
-
|
|
17414
|
-
const
|
|
17415
|
-
|
|
17416
|
-
|
|
17417
|
-
const
|
|
17418
|
-
|
|
17419
|
-
|
|
17420
|
-
|
|
17421
|
-
|
|
17422
|
-
this._SfDetailContainer.querySelector('#container-definition').innerHTML = '<div
|
|
17423
|
-
this._SfDetailContainer.querySelector('#
|
|
17424
|
-
|
|
17425
|
-
|
|
17426
|
-
|
|
17427
|
-
|
|
17428
|
-
|
|
17412
|
+
if (definitionsFound.length > 0) {
|
|
17413
|
+
console.log(JSON.parse(statute.fields.data[0])[definitionsIndex]);
|
|
17414
|
+
const definitionsName = JSON.parse(statute.fields.data[0])[definitionsIndex][0].trim();
|
|
17415
|
+
console.log('statute', statute, JSON.parse(statute.fields.cols[0]), nameIndex, statuteNameFound, definitionsFound, definitionsName);
|
|
17416
|
+
const definitionDetails = await this.fetchSearchDefinitions(definitionsName);
|
|
17417
|
+
definitionDetails.values.forEach(async (definition) => {
|
|
17418
|
+
const definitionNameIndex = JSON.parse(definition.fields.cols[0]).indexOf('name');
|
|
17419
|
+
const definitionNameFound = JSON.parse(definition.fields.data[0])[definitionNameIndex];
|
|
17420
|
+
if (definitionNameFound == definitionsName) {
|
|
17421
|
+
const attachmentIndex = JSON.parse(definition.fields.cols[0]).indexOf('attachment');
|
|
17422
|
+
const attachmentKey = JSON.parse(definition.fields.data[0])[attachmentIndex][0];
|
|
17423
|
+
console.log('definition', definition, attachmentKey);
|
|
17424
|
+
this._SfDetailContainer.querySelector('#container-definition').innerHTML = '<div class="m-20"><div part="detail-head"><strong>Definitions</strong></div><button part="button" id="button-show-definition" class="mt-5">View</button></div>';
|
|
17425
|
+
this._SfDetailContainer.querySelector('#button-show-definition').addEventListener('click', (_e) => {
|
|
17426
|
+
this._SfDetailContainer.querySelector('#container-definition').innerHTML = '<div class="m-20"><div part="detail-head" class="mb-10"><strong>Definitions</strong></div><sf-i-uploader class="gone" id="sf-i-definitions" max="10" apiid="1peg5170d3" allowedextensions="["jpg","png","pdf"]" extract="no" mandatory="" mode="view" maximize="yes"></sf-i-uploader></div>';
|
|
17427
|
+
this._SfDetailContainer.querySelector('#sf-i-definitions').classList.remove('gone');
|
|
17428
|
+
this._SfDetailContainer.querySelector('#sf-i-definitions').prepopulatedInputArr = JSON.stringify(JSON.parse('[' + attachmentKey + ']'));
|
|
17429
|
+
this._SfDetailContainer.querySelector('#sf-i-definitions').loadMode();
|
|
17430
|
+
});
|
|
17431
|
+
}
|
|
17432
|
+
});
|
|
17433
|
+
}
|
|
17429
17434
|
}
|
|
17430
17435
|
}
|
|
17431
17436
|
});
|
|
@@ -18324,7 +18329,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
18324
18329
|
};
|
|
18325
18330
|
this.fetchRegisters = async (searchString = "", meta = "", selectedCountry = "", selectedStatute = "") => {
|
|
18326
18331
|
let path = "";
|
|
18327
|
-
path = "
|
|
18332
|
+
path = "getallfunctionevents";
|
|
18328
18333
|
let url = "https://" + this.apiId + "/" + path;
|
|
18329
18334
|
let locationId = "";
|
|
18330
18335
|
let entityId = "";
|
|
@@ -18377,7 +18382,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
18377
18382
|
else {
|
|
18378
18383
|
view = "entity";
|
|
18379
18384
|
}
|
|
18380
|
-
path = "
|
|
18385
|
+
path = "getallcountryevents";
|
|
18381
18386
|
let sDate = "";
|
|
18382
18387
|
let eDate = "";
|
|
18383
18388
|
//console.log('currenttab', this.getCurrentTab());
|
package/src/sf-i-events.ts
CHANGED
|
@@ -116,7 +116,7 @@ export class SfIEvents extends LitElement {
|
|
|
116
116
|
COLOR_NOT_COMPLIED = "#C80036";
|
|
117
117
|
COLOR_PARTIALLY_COMPLIED = "#F79256";
|
|
118
118
|
COLOR_COMPLIED = "#50cf01";
|
|
119
|
-
|
|
119
|
+
COLOR_COMPLIED_WITH_EXCEPTION = "#ffe505";
|
|
120
120
|
COLOR_REPORTED_NON_COMPLIANCE = "#840B0F";
|
|
121
121
|
STATUS_NOT_STARTED = "not-started";
|
|
122
122
|
STATUS_PENDING_APPROVAL = "pending-approval";
|
|
@@ -4469,7 +4469,7 @@ export class SfIEvents extends LitElement {
|
|
|
4469
4469
|
html += '<div part="badge-dashboard" id="chip-compliance-2" class="chip stat-compliance justify-center align-center mr-10 mb-10 no-shrink compliance-statuses"><span class="material-icons color-partially-complied">rule</span> <span>Partially Complied:</span> <span id="graph-partially-complied">DASHBOARD_PARTIALLY_COMPLIED</span></div>';
|
|
4470
4470
|
html += '<div part="badge-dashboard" id="chip-compliance-3" class="chip stat-compliance justify-center align-center mr-10 mb-10 no-shrink compliance-statuses"><span class="material-symbols-outlined color-complied">sweep</span> <span>Complied:</span> <span id="graph-complied">DASHBOARD_COMPLIED</span></div>';
|
|
4471
4471
|
html += '<div part="badge-dashboard" id="chip-compliance-4" class="chip stat-compliance justify-center align-center mr-10 mb-10 no-shrink compliance-statuses"><span class="material-symbols-outlined color-complied-with-gaps">rule</span> <span>Complied With Gaps:</span> <span id="graph-complied-with-gaps">DASHBOARD_COMPLIED_WITH_GAPS</span></div>';
|
|
4472
|
-
html += '<div part="badge-dashboard" id="chip-compliance-5" class="chip stat-compliance justify-center align-center mr-10 mb-10 no-shrink compliance-statuses"><span class="material-symbols-outlined color-reported-non-compliance">rule</span> <span>Reported Non Compliance:</span> <span id="graph-reported-non-compliance">
|
|
4472
|
+
html += '<div part="badge-dashboard" id="chip-compliance-5" class="chip stat-compliance justify-center align-center mr-10 mb-10 no-shrink compliance-statuses"><span class="material-symbols-outlined color-reported-non-compliance">rule</span> <span>Reported Non Compliance:</span> <span id="graph-reported-non-compliance">DASHBOARD_COMPLIED_WITH_GAPS</span></div>';
|
|
4473
4473
|
html += '</div>';
|
|
4474
4474
|
|
|
4475
4475
|
html += '<div id="stream-event-filter" part="stream-event-total" class="d-flex flex-wrap"></div>';
|
|
@@ -5179,10 +5179,9 @@ export class SfIEvents extends LitElement {
|
|
|
5179
5179
|
html = html.replace("DASHBOARD_PARTIALLY_COMPLIED", partiallyComplied+"");
|
|
5180
5180
|
html = html.replace("DASHBOARD_COMPLIED", complied+"");
|
|
5181
5181
|
html = html.replace("DASHBOARD_COMPLIED_WITH_GAPS", compliedWithGaps+"");
|
|
5182
|
-
html = html.replace("DASHBOARD_REPORTED_NON_COMPLIANCE", reportedNonCompliance+"");
|
|
5183
5182
|
|
|
5184
|
-
this.csvDataStats = 'Period,Total,Not Started,Approved,Pending Approval,Rejected,Past Due Date,Late Reported,Late Executed,Late Approved,Scheduled,Not Complied,Partially Complied,Complied,Complied With Gaps
|
|
5185
|
-
this.csvDataStats += this.period + "," + total + "," + notStarted + "," + approved + "," + pendingApproval + "," + rejected + "," + pastDueDate + "," + lateReported + "," + lateExecuted + "," + lateApproved + "," + scheduled + "," + notComplied + "," + partiallyComplied + "," + complied+ "," + compliedWithGaps
|
|
5183
|
+
this.csvDataStats = 'Period,Total,Not Started,Approved,Pending Approval,Rejected,Past Due Date,Late Reported,Late Executed,Late Approved,Scheduled,Not Complied,Partially Complied,Complied,Complied With Gaps\n';
|
|
5184
|
+
this.csvDataStats += this.period + "," + total + "," + notStarted + "," + approved + "," + pendingApproval + "," + rejected + "," + pastDueDate + "," + lateReported + "," + lateExecuted + "," + lateApproved + "," + scheduled + "," + notComplied + "," + partiallyComplied + "," + complied+ "," + compliedWithGaps;
|
|
5186
5185
|
|
|
5187
5186
|
this.htmlDataStats = 'Completeness<br /><br /><table class="w-100"><tr><th class="w-14">Total</th><th class="w-14">Not Started</th><th class="w-14">Approved</th><th class="w-14">Pending Approval</th><th class="w-14">Rejected</th><tr>';
|
|
5188
5187
|
this.htmlDataStats += '<tr><td class="w-14 text-center td-odd">'+total+'</td><td class="w-14 text-center td-odd">'+notStarted+'</td><td class="w-14 text-center td-odd">'+approved+'</td><td class="w-14 text-center td-odd">'+pendingApproval+'</td><td class="w-14 text-center td-odd">'+rejected+'</td></table>'
|
|
@@ -5190,8 +5189,8 @@ export class SfIEvents extends LitElement {
|
|
|
5190
5189
|
this.htmlDataStats += '<br /><br />Timeliness<br /><br /><table class="mt-20 w-100"><tr><th class="w-14">Total</th><th class="w-14">In Time</th><th class="w-14">Past Due Date</th><th class="w-14">Late Reported</th><th class="w-14">Late Executed</th><th class="w-14">Late Approved</th><tr>';
|
|
5191
5190
|
this.htmlDataStats += '<tr><td class="w-14 text-center td-odd">'+total+'</td><td class="w-14 text-center td-odd">'+(total-(pastDueDate+lateApproved+lateExecuted))+'</td><td class="w-14 text-center td-odd">'+pastDueDate+'</td><td class="w-14 text-center td-odd">'+lateReported+'</td><td class="w-14 text-center td-odd">'+lateExecuted+'</td><td class="w-14 text-center td-odd">'+lateApproved+'</td><tr></table>'
|
|
5192
5191
|
|
|
5193
|
-
this.htmlDataStats += '<br /><br />Compliance<br /><br /><table class="w-100"><tr><th class="w-14">Total</th><th class="w-14">Scheduled</th><th class="w-14">Not Complied</th><th class="w-14">Partially Complied</th><th class="w-14">Complied</th><th class="w-14">Complied With Gaps</th><
|
|
5194
|
-
this.htmlDataStats += '<tr><td class="w-14 text-center td-odd">'+total+'</td><td class="w-14 text-center td-odd">'+scheduled+'</td><td class="w-14 text-center td-odd">'+notComplied+'</td><td class="w-14 text-center td-odd">'+partiallyComplied+'</td><td class="w-14 text-center td-odd">'+complied+'</td><td class="w-14 text-center td-odd">'+compliedWithGaps+'</td><
|
|
5192
|
+
this.htmlDataStats += '<br /><br />Compliance<br /><br /><table class="w-100"><tr><th class="w-14">Total</th><th class="w-14">Scheduled</th><th class="w-14">Not Complied</th><th class="w-14">Partially Complied</th><th class="w-14">Complied</th><th class="w-14">Complied With Gaps</th><tr>';
|
|
5193
|
+
this.htmlDataStats += '<tr><td class="w-14 text-center td-odd">'+total+'</td><td class="w-14 text-center td-odd">'+scheduled+'</td><td class="w-14 text-center td-odd">'+notComplied+'</td><td class="w-14 text-center td-odd">'+partiallyComplied+'</td><td class="w-14 text-center td-odd">'+complied+'</td><td class="w-14 text-center td-odd">'+compliedWithGaps+'</td><tr></table>'
|
|
5195
5194
|
|
|
5196
5195
|
return html;
|
|
5197
5196
|
|
|
@@ -11774,7 +11773,7 @@ export class SfIEvents extends LitElement {
|
|
|
11774
11773
|
this.clearGraph(divContainer, 4);
|
|
11775
11774
|
|
|
11776
11775
|
const data = {
|
|
11777
|
-
labels: ['Scheduled', 'Not Complied', 'Partially Complied', 'Complied', 'Complied With Gaps','Reported Non
|
|
11776
|
+
labels: ['Scheduled', 'Not Complied', 'Partially Complied', 'Complied', 'Complied With Gaps','Reported Non Complinace'],
|
|
11778
11777
|
datasets: [{
|
|
11779
11778
|
label: 'Compliances',
|
|
11780
11779
|
data: [dataScheduled, dataNotComplied, dataPartiallyComplied, dataComplied, dataCompliedWithGaps, dataReportedNonComplaince],
|
|
@@ -11784,7 +11783,7 @@ export class SfIEvents extends LitElement {
|
|
|
11784
11783
|
this.COLOR_NOT_COMPLIED,
|
|
11785
11784
|
this.COLOR_PARTIALLY_COMPLIED,
|
|
11786
11785
|
this.COLOR_COMPLIED,
|
|
11787
|
-
this.
|
|
11786
|
+
this.COLOR_COMPLIED_WITH_EXCEPTION,
|
|
11788
11787
|
this.COLOR_REPORTED_NON_COMPLIANCE
|
|
11789
11788
|
]
|
|
11790
11789
|
}]
|
|
@@ -12094,7 +12093,7 @@ export class SfIEvents extends LitElement {
|
|
|
12094
12093
|
for(i = 0; i < Object.keys(complianceData).length; i++) {
|
|
12095
12094
|
dataBar2['datasets'][4]['data'].push(complianceData[Object.keys(complianceData)[i]]['complied-with-gaps']);
|
|
12096
12095
|
}
|
|
12097
|
-
dataBar2['datasets'][4]['backgroundColor'] = this.
|
|
12096
|
+
dataBar2['datasets'][4]['backgroundColor'] = this.COLOR_COMPLIED_WITH_EXCEPTION;
|
|
12098
12097
|
|
|
12099
12098
|
dataBar2['datasets'][5]['label'] = 'Reported Non Compliance';
|
|
12100
12099
|
dataBar2['datasets'][5]['data'] = [];
|
|
@@ -13204,7 +13203,7 @@ export class SfIEvents extends LitElement {
|
|
|
13204
13203
|
|
|
13205
13204
|
fetchEventDetails = async (listEvent: any, mmddyyyy: any, currentColumnButton: HTMLButtonElement | null, eventsContainer: HTMLDivElement) => {
|
|
13206
13205
|
console.log('listEvent', listEvent, listEvent.id)
|
|
13207
|
-
let url = "https://"+this.apiId+"/
|
|
13206
|
+
let url = "https://"+this.apiId+"/getalleventdetails";
|
|
13208
13207
|
|
|
13209
13208
|
//console.log('fetch calendar url', url);
|
|
13210
13209
|
let urlBody :any = {"projectid": this.projectId, "userprofileid": this.userProfileId, "role": this.myRole, "eventid": listEvent.id, "entityid": listEvent.entityid, "locationid": listEvent.locationid, "mmddyyyy": mmddyyyy, "year": this.calendarStartYYYY};
|
|
@@ -13267,8 +13266,8 @@ export class SfIEvents extends LitElement {
|
|
|
13267
13266
|
//console.log('event detail documenttype', documentType);
|
|
13268
13267
|
const basicFields = ['id', 'shortid', 'entityname', 'locationname','functions'];
|
|
13269
13268
|
const statuteFields = ['jurisdiction', 'country', 'state', 'category', 'subcategory', 'statute'];
|
|
13270
|
-
const complianceFields = ['specificity', 'reference', 'obligation', 'penalty', 'authority', 'frequency', 'obligationtype', 'duedate', 'applicability', 'form'];
|
|
13271
|
-
const grcFields = ['internalcontrols', 'firstlineofdefence', 'risk', 'riskarea'];
|
|
13269
|
+
const complianceFields = ['specificity', 'reference', 'obligation', 'penalty', 'authority', 'frequency', 'subfrequency', 'obligationtype', 'duedate', 'applicability', 'form', 'additionalurls', 'adhocquestion', 'adhocquestionschedule', 'adhocinstances', 'uploadguidance'];
|
|
13270
|
+
const grcFields = ['internalcontrols', 'firstlineofdefence', 'secondlineofdefence', 'thirdlineofdefence', 'risk', 'riskarea'];
|
|
13272
13271
|
|
|
13273
13272
|
let listReportingContainers = eventsContainer.querySelectorAll('.list-reporting-container') as NodeListOf<HTMLDivElement>
|
|
13274
13273
|
for(let tempReportingContainer of listReportingContainers){
|
|
@@ -13392,18 +13391,19 @@ export class SfIEvents extends LitElement {
|
|
|
13392
13391
|
for(var i = 0; i < statuteFields.length; i++) {
|
|
13393
13392
|
|
|
13394
13393
|
if(!this.getEventPreviewFields().includes(statuteFields[i])) {
|
|
13395
|
-
|
|
13396
|
-
|
|
13394
|
+
if(event[statuteFields[i]] != null && event[statuteFields[i]] != "") {
|
|
13395
|
+
if(!this.getEventHideFields().includes(statuteFields[i])) {
|
|
13397
13396
|
|
|
13398
|
-
|
|
13399
|
-
|
|
13400
|
-
|
|
13401
|
-
|
|
13402
|
-
|
|
13403
|
-
|
|
13404
|
-
|
|
13405
|
-
|
|
13397
|
+
html += '<div class="m-20">';
|
|
13398
|
+
html += '<div part="detail-head"><strong>'+statuteFields[i]+'</strong></div>'
|
|
13399
|
+
if((event[statuteFields[i]] + "").indexOf("[") >= 0) {
|
|
13400
|
+
html += this.getEventTexts(statuteFields[i], JSON.parse(event[statuteFields[i]]), event);
|
|
13401
|
+
} else {
|
|
13402
|
+
html += '<sf-i-elastic-text text="'+(event[statuteFields[i]] + "").replace(/"/g, "")+'" minLength="80"></sf-i-elastic-text>';
|
|
13403
|
+
}
|
|
13404
|
+
html += '</div>';
|
|
13406
13405
|
|
|
13406
|
+
}
|
|
13407
13407
|
}
|
|
13408
13408
|
}
|
|
13409
13409
|
|
|
@@ -13429,33 +13429,32 @@ export class SfIEvents extends LitElement {
|
|
|
13429
13429
|
if(!this.getEventPreviewFields().includes(complianceFields[i])) {
|
|
13430
13430
|
|
|
13431
13431
|
if(!this.getEventHideFields().includes(complianceFields[i])) {
|
|
13432
|
+
if(event[complianceFields[i]] != null && event[complianceFields[i]] != "") {
|
|
13433
|
+
if(event[complianceFields[i]].indexOf('http://') >= 0) {
|
|
13434
|
+
|
|
13435
|
+
let res = event[complianceFields[i]].split(" ").find((word:any) => word.startsWith("http"));
|
|
13436
|
+
html += '<div class="m-20">';
|
|
13437
|
+
html += '<div part="detail-head"><strong>'+complianceFields[i]+'</strong></div>'
|
|
13438
|
+
if((event[complianceFields[i]] + "").indexOf("[") >= 0) {
|
|
13439
|
+
html += this.getEventTexts(complianceFields[i], JSON.parse(event[complianceFields[i]]), event) + " <a href=\""+res+"\" target=\"_blank\">Open</a>";
|
|
13440
|
+
} else {
|
|
13441
|
+
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>";
|
|
13442
|
+
}
|
|
13443
|
+
html += '</div>';
|
|
13432
13444
|
|
|
13433
|
-
if(event[complianceFields[i]].indexOf('http://') >= 0) {
|
|
13434
|
-
|
|
13435
|
-
let res = event[complianceFields[i]].split(" ").find((word:any) => word.startsWith("http"));
|
|
13436
|
-
html += '<div class="m-20">';
|
|
13437
|
-
html += '<div part="detail-head"><strong>'+complianceFields[i]+'</strong></div>'
|
|
13438
|
-
if((event[complianceFields[i]] + "").indexOf("[") >= 0) {
|
|
13439
|
-
html += this.getEventTexts(complianceFields[i], JSON.parse(event[complianceFields[i]]), event) + " <a href=\""+res+"\" target=\"_blank\">Open</a>";
|
|
13440
13445
|
} else {
|
|
13441
|
-
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>";
|
|
13442
|
-
}
|
|
13443
|
-
html += '</div>';
|
|
13444
13446
|
|
|
13445
|
-
|
|
13447
|
+
html += '<div class="m-20">';
|
|
13448
|
+
html += '<div part="detail-head"><strong>'+complianceFields[i]+'</strong></div>'
|
|
13449
|
+
if((event[complianceFields[i]] + "").indexOf("[") >= 0) {
|
|
13450
|
+
html += this.getEventTexts(complianceFields[i], JSON.parse(event[complianceFields[i]]), event);
|
|
13451
|
+
} else {
|
|
13452
|
+
html += '<sf-i-elastic-text text="'+(event[complianceFields[i]] + "").replace(/"/g, "").replace(/\n/g,'<br />')+'" minLength="80"></sf-i-elastic-text>';
|
|
13453
|
+
}
|
|
13454
|
+
html += '</div>';
|
|
13446
13455
|
|
|
13447
|
-
html += '<div class="m-20">';
|
|
13448
|
-
html += '<div part="detail-head"><strong>'+complianceFields[i]+'</strong></div>'
|
|
13449
|
-
if((event[complianceFields[i]] + "").indexOf("[") >= 0) {
|
|
13450
|
-
html += this.getEventTexts(complianceFields[i], JSON.parse(event[complianceFields[i]]), event);
|
|
13451
|
-
} else {
|
|
13452
|
-
html += '<sf-i-elastic-text text="'+(event[complianceFields[i]] + "").replace(/"/g, "").replace(/\n/g,'<br />')+'" minLength="80"></sf-i-elastic-text>';
|
|
13453
13456
|
}
|
|
13454
|
-
html += '</div>';
|
|
13455
|
-
|
|
13456
13457
|
}
|
|
13457
|
-
|
|
13458
|
-
|
|
13459
13458
|
}
|
|
13460
13459
|
}
|
|
13461
13460
|
|
|
@@ -13475,30 +13474,31 @@ export class SfIEvents extends LitElement {
|
|
|
13475
13474
|
|
|
13476
13475
|
//console.log(grcFields[i]);
|
|
13477
13476
|
if(!this.getEventPreviewFields().includes(grcFields[i])) {
|
|
13478
|
-
|
|
13479
|
-
|
|
13477
|
+
if(event[grcFields[i]] != null && event[grcFields[i]] != "") {
|
|
13478
|
+
if(!this.getEventHideFields().includes(grcFields[i])) {
|
|
13480
13479
|
|
|
13481
|
-
|
|
13482
|
-
|
|
13480
|
+
html += '<div class="m-20">';
|
|
13481
|
+
html += '<div part="detail-head"><strong>'+grcFields[i]+'</strong></div>'
|
|
13483
13482
|
|
|
13484
|
-
|
|
13483
|
+
if(grcFields[i].toLowerCase() == "riskarea") {
|
|
13485
13484
|
|
|
13486
|
-
|
|
13487
|
-
|
|
13488
|
-
|
|
13489
|
-
|
|
13485
|
+
const arrValues = event[grcFields[i]];
|
|
13486
|
+
for(var k = 0; k < arrValues.length; k++) {
|
|
13487
|
+
html += '<div part="detail-reporter-name" class="mr-10">' + arrValues[k] + '</div>';
|
|
13488
|
+
}
|
|
13490
13489
|
|
|
13491
|
-
} else {
|
|
13492
|
-
if((event[grcFields[i]] + "").indexOf("[") >= 0) {
|
|
13493
|
-
html += this.getEventTexts(grcFields[i], JSON.parse(event[grcFields[i]]), event);
|
|
13494
13490
|
} else {
|
|
13495
|
-
|
|
13496
|
-
|
|
13491
|
+
if((event[grcFields[i]] + "").indexOf("[") >= 0) {
|
|
13492
|
+
html += this.getEventTexts(grcFields[i], JSON.parse(event[grcFields[i]]), event);
|
|
13493
|
+
} else {
|
|
13494
|
+
//console.log('grcfield', event[grcFields[i]]);
|
|
13495
|
+
html += '<sf-i-elastic-text text="'+(event[grcFields[i]] + "").replace(/"/g, "").replace(/\n/g,'<br />')+'" minLength="80"></sf-i-elastic-text>';
|
|
13496
|
+
}
|
|
13497
13497
|
}
|
|
13498
|
-
|
|
13499
|
-
|
|
13500
|
-
html += '</div>';
|
|
13498
|
+
|
|
13499
|
+
html += '</div>';
|
|
13501
13500
|
|
|
13501
|
+
}
|
|
13502
13502
|
}
|
|
13503
13503
|
}
|
|
13504
13504
|
|
|
@@ -20932,7 +20932,7 @@ export class SfIEvents extends LitElement {
|
|
|
20932
20932
|
}, 10000);
|
|
20933
20933
|
}
|
|
20934
20934
|
|
|
20935
|
-
|
|
20935
|
+
|
|
20936
20936
|
for(var i = 0; i < divs.length; i++) {
|
|
20937
20937
|
|
|
20938
20938
|
// console.log('processGraphFilter', graphparamnames1[i], (graphparamnames1[i] as HTMLDivElement).innerHTML.toLowerCase().replace('&', '&').replace(/-/g, ' '), this.graphParam.toLowerCase().replace('&', '&').replace(/-/g, ' '));
|
|
@@ -20942,9 +20942,6 @@ export class SfIEvents extends LitElement {
|
|
|
20942
20942
|
let graphparamname1Arr = (graphparamnames1[i] as HTMLDivElement).innerHTML.toLowerCase().replace('&', '&').replace(/-/g, ' ').split(' • ');
|
|
20943
20943
|
let filterFound = false;
|
|
20944
20944
|
for(let tempFilterStr of graphparamname1Arr){
|
|
20945
|
-
if(clickedValue == "reported non compliance"){
|
|
20946
|
-
console.log('comparing filter', tempFilterStr, this.graphParam.toLowerCase().replace('&', '&').replace(/-/g, ' '))
|
|
20947
|
-
}
|
|
20948
20945
|
if(tempFilterStr == this.graphParam.toLowerCase().replace('&', '&').replace(/-/g, ' ') || this.graphParam.toLowerCase().replace('&', '&').replace(/-/g, ' ') == ""){
|
|
20949
20946
|
filterFound = true;
|
|
20950
20947
|
break;
|
|
@@ -22414,7 +22411,7 @@ export class SfIEvents extends LitElement {
|
|
|
22414
22411
|
}
|
|
22415
22412
|
|
|
22416
22413
|
uploadAudit = async (entityId: string, locationId: string, mmddyyyy: string, eventid: string, comments: string, approved: any, module: string = "events") => {
|
|
22417
|
-
let url = "https://"+this.apiId+"/
|
|
22414
|
+
let url = "https://"+this.apiId+"/uploadaudit";
|
|
22418
22415
|
|
|
22419
22416
|
const body = {
|
|
22420
22417
|
"mmddyyyy": mmddyyyy,
|
|
@@ -22454,7 +22451,7 @@ export class SfIEvents extends LitElement {
|
|
|
22454
22451
|
}
|
|
22455
22452
|
}
|
|
22456
22453
|
uploadAuditsBulk = async (bulkBody: any) => {
|
|
22457
|
-
let url = "https://"+this.apiId+"/
|
|
22454
|
+
let url = "https://"+this.apiId+"/uploadauditsbulk";
|
|
22458
22455
|
|
|
22459
22456
|
const authorization = btoa(Util.readCookie('email') + ":" + Util.readCookie('accessToken'));
|
|
22460
22457
|
const xhr : any = (await this.prepareXhr(bulkBody, url, this._SfLoader, authorization)) as any;
|
|
@@ -22473,7 +22470,7 @@ export class SfIEvents extends LitElement {
|
|
|
22473
22470
|
}
|
|
22474
22471
|
|
|
22475
22472
|
uploadReview = async (entityId: string, locationId: string, mmddyyyy: string, eventid: string, comments: string, approved: any, module: string = "events") => {
|
|
22476
|
-
let url = "https://"+this.apiId+"/
|
|
22473
|
+
let url = "https://"+this.apiId+"/uploadreview";
|
|
22477
22474
|
|
|
22478
22475
|
const body = {
|
|
22479
22476
|
"mmddyyyy": mmddyyyy,
|
|
@@ -22518,7 +22515,7 @@ export class SfIEvents extends LitElement {
|
|
|
22518
22515
|
}
|
|
22519
22516
|
}
|
|
22520
22517
|
uploadReportsReviewsBulk = async (bulkBody: any) => {
|
|
22521
|
-
let url = "https://"+this.apiId+"/
|
|
22518
|
+
let url = "https://"+this.apiId+"/uploadreportsreviewsbulk";
|
|
22522
22519
|
|
|
22523
22520
|
const authorization = btoa(Util.readCookie('email') + ":" + Util.readCookie('accessToken'));
|
|
22524
22521
|
const xhr : any = (await this.prepareXhr(bulkBody, url, this._SfLoader, authorization)) as any;
|
|
@@ -22538,7 +22535,7 @@ export class SfIEvents extends LitElement {
|
|
|
22538
22535
|
}
|
|
22539
22536
|
}
|
|
22540
22537
|
uploadReviewsBulk = async (bulkBody: any) => {
|
|
22541
|
-
let url = "https://"+this.apiId+"/
|
|
22538
|
+
let url = "https://"+this.apiId+"/uploadreviewsbulk";
|
|
22542
22539
|
|
|
22543
22540
|
const authorization = btoa(Util.readCookie('email') + ":" + Util.readCookie('accessToken'));
|
|
22544
22541
|
const xhr : any = (await this.prepareXhr(bulkBody, url, this._SfLoader, authorization)) as any;
|
|
@@ -22559,7 +22556,7 @@ export class SfIEvents extends LitElement {
|
|
|
22559
22556
|
}
|
|
22560
22557
|
|
|
22561
22558
|
uploadReport = async (entityId: string, locationId: string, mmddyyyy: string, eventid: string, comments: string, doc: string, docs: any, event: any, reportformatvalues: string = "", reportformatschema: string = "", module: string = "events", percentage: string = "100") => {
|
|
22562
|
-
let url = "https://"+this.apiId+"/
|
|
22559
|
+
let url = "https://"+this.apiId+"/uploadreport";
|
|
22563
22560
|
|
|
22564
22561
|
let body = {
|
|
22565
22562
|
"mmddyyyy": mmddyyyy,
|
|
@@ -22613,7 +22610,7 @@ export class SfIEvents extends LitElement {
|
|
|
22613
22610
|
}
|
|
22614
22611
|
|
|
22615
22612
|
uploadReportsBulk = async (bulkBody: any, showSuccess: boolean = true) => {
|
|
22616
|
-
let url = "https://"+this.apiId+"/
|
|
22613
|
+
let url = "https://"+this.apiId+"/uploadreportsbulk"
|
|
22617
22614
|
|
|
22618
22615
|
const authorization = btoa(Util.readCookie('email') + ":" + Util.readCookie('accessToken'));
|
|
22619
22616
|
const xhr : any = (await this.prepareXhr(bulkBody, url, this._SfLoader, authorization)) as any;
|
|
@@ -23010,29 +23007,31 @@ export class SfIEvents extends LitElement {
|
|
|
23010
23007
|
if(statute.fields.cols[0].indexOf('definitions') >= 0) {
|
|
23011
23008
|
const definitionsIndex = (JSON.parse(statute.fields.cols[0]) as Array<string>).indexOf('definitions');
|
|
23012
23009
|
const definitionsFound = JSON.parse(statute.fields.data[0])[definitionsIndex];
|
|
23013
|
-
|
|
23014
|
-
|
|
23015
|
-
|
|
23016
|
-
|
|
23017
|
-
const
|
|
23018
|
-
|
|
23019
|
-
|
|
23020
|
-
const
|
|
23021
|
-
|
|
23022
|
-
|
|
23023
|
-
|
|
23024
|
-
|
|
23025
|
-
|
|
23026
|
-
|
|
23027
|
-
((this._SfDetailContainer as HTMLDivElement).querySelector('#
|
|
23028
|
-
|
|
23029
|
-
|
|
23030
|
-
|
|
23010
|
+
if(definitionsFound.length > 0){
|
|
23011
|
+
console.log(JSON.parse(statute.fields.data[0])[definitionsIndex]);
|
|
23012
|
+
const definitionsName = JSON.parse(statute.fields.data[0])[definitionsIndex][0].trim();
|
|
23013
|
+
console.log('statute', statute, JSON.parse(statute.fields.cols[0]), nameIndex, statuteNameFound, definitionsFound, definitionsName);
|
|
23014
|
+
const definitionDetails = await this.fetchSearchDefinitions(definitionsName);
|
|
23015
|
+
definitionDetails.values.forEach(async (definition: any) => {
|
|
23016
|
+
const definitionNameIndex = (JSON.parse(definition.fields.cols[0]) as Array<string>).indexOf('name');
|
|
23017
|
+
const definitionNameFound = JSON.parse(definition.fields.data[0])[definitionNameIndex];
|
|
23018
|
+
if(definitionNameFound == definitionsName) {
|
|
23019
|
+
const attachmentIndex = (JSON.parse(definition.fields.cols[0]) as Array<string>).indexOf('attachment');
|
|
23020
|
+
const attachmentKey = JSON.parse(definition.fields.data[0])[attachmentIndex][0]
|
|
23021
|
+
console.log('definition', definition, attachmentKey);
|
|
23022
|
+
(this._SfDetailContainer as HTMLDivElement).querySelector('#container-definition')!.innerHTML = '<div class="m-20"><div part="detail-head"><strong>Definitions</strong></div><button part="button" id="button-show-definition" class="mt-5">View</button></div>';
|
|
23023
|
+
|
|
23024
|
+
((this._SfDetailContainer as HTMLDivElement).querySelector('#button-show-definition') as HTMLButtonElement)!.addEventListener('click', (_e: any) => {
|
|
23025
|
+
(this._SfDetailContainer as HTMLDivElement).querySelector('#container-definition')!.innerHTML = '<div class="m-20"><div part="detail-head" class="mb-10"><strong>Definitions</strong></div><sf-i-uploader class="gone" id="sf-i-definitions" max="10" apiid="1peg5170d3" allowedextensions="["jpg","png","pdf"]" extract="no" mandatory="" mode="view" maximize="yes"></sf-i-uploader></div>';
|
|
23026
|
+
((this._SfDetailContainer as HTMLDivElement).querySelector('#sf-i-definitions') as SfIUploader).classList.remove('gone');
|
|
23027
|
+
((this._SfDetailContainer as HTMLDivElement).querySelector('#sf-i-definitions') as SfIUploader).prepopulatedInputArr = JSON.stringify(JSON.parse('[' + attachmentKey + ']'));
|
|
23028
|
+
((this._SfDetailContainer as HTMLDivElement).querySelector('#sf-i-definitions') as SfIUploader).loadMode();
|
|
23029
|
+
});
|
|
23031
23030
|
|
|
23032
|
-
|
|
23033
|
-
|
|
23031
|
+
}
|
|
23032
|
+
});
|
|
23033
|
+
}
|
|
23034
23034
|
}
|
|
23035
|
-
|
|
23036
23035
|
}
|
|
23037
23036
|
});
|
|
23038
23037
|
|
|
@@ -24323,7 +24322,7 @@ export class SfIEvents extends LitElement {
|
|
|
24323
24322
|
|
|
24324
24323
|
let path = "";
|
|
24325
24324
|
|
|
24326
|
-
path = "
|
|
24325
|
+
path = "getallfunctionevents";
|
|
24327
24326
|
|
|
24328
24327
|
let url = "https://"+this.apiId+"/"+ path;
|
|
24329
24328
|
|
|
@@ -24386,7 +24385,7 @@ export class SfIEvents extends LitElement {
|
|
|
24386
24385
|
view = "entity";
|
|
24387
24386
|
}
|
|
24388
24387
|
|
|
24389
|
-
path = "
|
|
24388
|
+
path = "getallcountryevents";
|
|
24390
24389
|
|
|
24391
24390
|
let sDate = "";
|
|
24392
24391
|
let eDate = "";
|