sf-i-events 1.0.806 → 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.js +73 -64
- package/src/sf-i-events.ts +74 -71
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.js
CHANGED
|
@@ -9644,8 +9644,8 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
9644
9644
|
//console.log('event detail documenttype', documentType);
|
|
9645
9645
|
const basicFields = ['id', 'shortid', 'entityname', 'locationname', 'functions'];
|
|
9646
9646
|
const statuteFields = ['jurisdiction', 'country', 'state', 'category', 'subcategory', 'statute'];
|
|
9647
|
-
const complianceFields = ['specificity', 'reference', 'obligation', 'penalty', 'authority', 'frequency', 'obligationtype', 'duedate', 'applicability', 'form'];
|
|
9648
|
-
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'];
|
|
9649
9649
|
let listReportingContainers = eventsContainer.querySelectorAll('.list-reporting-container');
|
|
9650
9650
|
for (let tempReportingContainer of listReportingContainers) {
|
|
9651
9651
|
tempReportingContainer.style.display = 'none';
|
|
@@ -9746,16 +9746,18 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
9746
9746
|
html += '<div class="d-flex flex-wrap accordian-body body-statute" part="accordian-body">';
|
|
9747
9747
|
for (var i = 0; i < statuteFields.length; i++) {
|
|
9748
9748
|
if (!this.getEventPreviewFields().includes(statuteFields[i])) {
|
|
9749
|
-
if (
|
|
9750
|
-
|
|
9751
|
-
|
|
9752
|
-
|
|
9753
|
-
|
|
9754
|
-
|
|
9755
|
-
|
|
9756
|
-
|
|
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>';
|
|
9757
9760
|
}
|
|
9758
|
-
html += '</div>';
|
|
9759
9761
|
}
|
|
9760
9762
|
}
|
|
9761
9763
|
}
|
|
@@ -9773,28 +9775,30 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
9773
9775
|
//console.log(event[complianceFields[i]]);
|
|
9774
9776
|
if (!this.getEventPreviewFields().includes(complianceFields[i])) {
|
|
9775
9777
|
if (!this.getEventHideFields().includes(complianceFields[i])) {
|
|
9776
|
-
if (event[complianceFields[i]]
|
|
9777
|
-
|
|
9778
|
-
|
|
9779
|
-
|
|
9780
|
-
|
|
9781
|
-
|
|
9782
|
-
|
|
9783
|
-
|
|
9784
|
-
|
|
9785
|
-
|
|
9786
|
-
|
|
9787
|
-
|
|
9788
|
-
else {
|
|
9789
|
-
html += '<div class="m-20">';
|
|
9790
|
-
html += '<div part="detail-head"><strong>' + complianceFields[i] + '</strong></div>';
|
|
9791
|
-
if ((event[complianceFields[i]] + "").indexOf("[") >= 0) {
|
|
9792
|
-
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>';
|
|
9793
9790
|
}
|
|
9794
9791
|
else {
|
|
9795
|
-
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>';
|
|
9796
9801
|
}
|
|
9797
|
-
html += '</div>';
|
|
9798
9802
|
}
|
|
9799
9803
|
}
|
|
9800
9804
|
}
|
|
@@ -9810,25 +9814,27 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
9810
9814
|
for (var i = 0; i < grcFields.length; i++) {
|
|
9811
9815
|
//console.log(grcFields[i]);
|
|
9812
9816
|
if (!this.getEventPreviewFields().includes(grcFields[i])) {
|
|
9813
|
-
if (
|
|
9814
|
-
|
|
9815
|
-
|
|
9816
|
-
|
|
9817
|
-
|
|
9818
|
-
|
|
9819
|
-
|
|
9820
|
-
|
|
9821
|
-
|
|
9822
|
-
else {
|
|
9823
|
-
if ((event[grcFields[i]] + "").indexOf("[") >= 0) {
|
|
9824
|
-
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
|
+
}
|
|
9825
9826
|
}
|
|
9826
9827
|
else {
|
|
9827
|
-
|
|
9828
|
-
|
|
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
|
+
}
|
|
9829
9835
|
}
|
|
9836
|
+
html += '</div>';
|
|
9830
9837
|
}
|
|
9831
|
-
html += '</div>';
|
|
9832
9838
|
}
|
|
9833
9839
|
}
|
|
9834
9840
|
}
|
|
@@ -17403,25 +17409,28 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
17403
17409
|
if (statute.fields.cols[0].indexOf('definitions') >= 0) {
|
|
17404
17410
|
const definitionsIndex = JSON.parse(statute.fields.cols[0]).indexOf('definitions');
|
|
17405
17411
|
const definitionsFound = JSON.parse(statute.fields.data[0])[definitionsIndex];
|
|
17406
|
-
|
|
17407
|
-
|
|
17408
|
-
|
|
17409
|
-
|
|
17410
|
-
const
|
|
17411
|
-
|
|
17412
|
-
|
|
17413
|
-
const
|
|
17414
|
-
|
|
17415
|
-
|
|
17416
|
-
|
|
17417
|
-
|
|
17418
|
-
this._SfDetailContainer.querySelector('#container-definition').innerHTML = '<div
|
|
17419
|
-
this._SfDetailContainer.querySelector('#
|
|
17420
|
-
|
|
17421
|
-
|
|
17422
|
-
|
|
17423
|
-
|
|
17424
|
-
|
|
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
|
+
}
|
|
17425
17434
|
}
|
|
17426
17435
|
}
|
|
17427
17436
|
});
|
package/src/sf-i-events.ts
CHANGED
|
@@ -13266,8 +13266,8 @@ export class SfIEvents extends LitElement {
|
|
|
13266
13266
|
//console.log('event detail documenttype', documentType);
|
|
13267
13267
|
const basicFields = ['id', 'shortid', 'entityname', 'locationname','functions'];
|
|
13268
13268
|
const statuteFields = ['jurisdiction', 'country', 'state', 'category', 'subcategory', 'statute'];
|
|
13269
|
-
const complianceFields = ['specificity', 'reference', 'obligation', 'penalty', 'authority', 'frequency', 'obligationtype', 'duedate', 'applicability', 'form'];
|
|
13270
|
-
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'];
|
|
13271
13271
|
|
|
13272
13272
|
let listReportingContainers = eventsContainer.querySelectorAll('.list-reporting-container') as NodeListOf<HTMLDivElement>
|
|
13273
13273
|
for(let tempReportingContainer of listReportingContainers){
|
|
@@ -13391,18 +13391,19 @@ export class SfIEvents extends LitElement {
|
|
|
13391
13391
|
for(var i = 0; i < statuteFields.length; i++) {
|
|
13392
13392
|
|
|
13393
13393
|
if(!this.getEventPreviewFields().includes(statuteFields[i])) {
|
|
13394
|
-
|
|
13395
|
-
|
|
13394
|
+
if(event[statuteFields[i]] != null && event[statuteFields[i]] != "") {
|
|
13395
|
+
if(!this.getEventHideFields().includes(statuteFields[i])) {
|
|
13396
13396
|
|
|
13397
|
-
|
|
13398
|
-
|
|
13399
|
-
|
|
13400
|
-
|
|
13401
|
-
|
|
13402
|
-
|
|
13403
|
-
|
|
13404
|
-
|
|
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>';
|
|
13405
13405
|
|
|
13406
|
+
}
|
|
13406
13407
|
}
|
|
13407
13408
|
}
|
|
13408
13409
|
|
|
@@ -13428,33 +13429,32 @@ export class SfIEvents extends LitElement {
|
|
|
13428
13429
|
if(!this.getEventPreviewFields().includes(complianceFields[i])) {
|
|
13429
13430
|
|
|
13430
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>';
|
|
13431
13444
|
|
|
13432
|
-
if(event[complianceFields[i]].indexOf('http://') >= 0) {
|
|
13433
|
-
|
|
13434
|
-
let res = event[complianceFields[i]].split(" ").find((word:any) => word.startsWith("http"));
|
|
13435
|
-
html += '<div class="m-20">';
|
|
13436
|
-
html += '<div part="detail-head"><strong>'+complianceFields[i]+'</strong></div>'
|
|
13437
|
-
if((event[complianceFields[i]] + "").indexOf("[") >= 0) {
|
|
13438
|
-
html += this.getEventTexts(complianceFields[i], JSON.parse(event[complianceFields[i]]), event) + " <a href=\""+res+"\" target=\"_blank\">Open</a>";
|
|
13439
13445
|
} else {
|
|
13440
|
-
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>";
|
|
13441
|
-
}
|
|
13442
|
-
html += '</div>';
|
|
13443
13446
|
|
|
13444
|
-
|
|
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>';
|
|
13445
13455
|
|
|
13446
|
-
html += '<div class="m-20">';
|
|
13447
|
-
html += '<div part="detail-head"><strong>'+complianceFields[i]+'</strong></div>'
|
|
13448
|
-
if((event[complianceFields[i]] + "").indexOf("[") >= 0) {
|
|
13449
|
-
html += this.getEventTexts(complianceFields[i], JSON.parse(event[complianceFields[i]]), event);
|
|
13450
|
-
} else {
|
|
13451
|
-
html += '<sf-i-elastic-text text="'+(event[complianceFields[i]] + "").replace(/"/g, "").replace(/\n/g,'<br />')+'" minLength="80"></sf-i-elastic-text>';
|
|
13452
13456
|
}
|
|
13453
|
-
html += '</div>';
|
|
13454
|
-
|
|
13455
13457
|
}
|
|
13456
|
-
|
|
13457
|
-
|
|
13458
13458
|
}
|
|
13459
13459
|
}
|
|
13460
13460
|
|
|
@@ -13474,30 +13474,31 @@ export class SfIEvents extends LitElement {
|
|
|
13474
13474
|
|
|
13475
13475
|
//console.log(grcFields[i]);
|
|
13476
13476
|
if(!this.getEventPreviewFields().includes(grcFields[i])) {
|
|
13477
|
-
|
|
13478
|
-
|
|
13477
|
+
if(event[grcFields[i]] != null && event[grcFields[i]] != "") {
|
|
13478
|
+
if(!this.getEventHideFields().includes(grcFields[i])) {
|
|
13479
13479
|
|
|
13480
|
-
|
|
13481
|
-
|
|
13480
|
+
html += '<div class="m-20">';
|
|
13481
|
+
html += '<div part="detail-head"><strong>'+grcFields[i]+'</strong></div>'
|
|
13482
13482
|
|
|
13483
|
-
|
|
13483
|
+
if(grcFields[i].toLowerCase() == "riskarea") {
|
|
13484
13484
|
|
|
13485
|
-
|
|
13486
|
-
|
|
13487
|
-
|
|
13488
|
-
|
|
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
|
+
}
|
|
13489
13489
|
|
|
13490
|
-
} else {
|
|
13491
|
-
if((event[grcFields[i]] + "").indexOf("[") >= 0) {
|
|
13492
|
-
html += this.getEventTexts(grcFields[i], JSON.parse(event[grcFields[i]]), event);
|
|
13493
13490
|
} else {
|
|
13494
|
-
|
|
13495
|
-
|
|
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
|
+
}
|
|
13496
13497
|
}
|
|
13497
|
-
|
|
13498
|
-
|
|
13499
|
-
html += '</div>';
|
|
13498
|
+
|
|
13499
|
+
html += '</div>';
|
|
13500
13500
|
|
|
13501
|
+
}
|
|
13501
13502
|
}
|
|
13502
13503
|
}
|
|
13503
13504
|
|
|
@@ -23006,29 +23007,31 @@ export class SfIEvents extends LitElement {
|
|
|
23006
23007
|
if(statute.fields.cols[0].indexOf('definitions') >= 0) {
|
|
23007
23008
|
const definitionsIndex = (JSON.parse(statute.fields.cols[0]) as Array<string>).indexOf('definitions');
|
|
23008
23009
|
const definitionsFound = JSON.parse(statute.fields.data[0])[definitionsIndex];
|
|
23009
|
-
|
|
23010
|
-
|
|
23011
|
-
|
|
23012
|
-
|
|
23013
|
-
const
|
|
23014
|
-
|
|
23015
|
-
|
|
23016
|
-
const
|
|
23017
|
-
|
|
23018
|
-
|
|
23019
|
-
|
|
23020
|
-
|
|
23021
|
-
|
|
23022
|
-
|
|
23023
|
-
((this._SfDetailContainer as HTMLDivElement).querySelector('#
|
|
23024
|
-
|
|
23025
|
-
|
|
23026
|
-
|
|
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
|
+
});
|
|
23027
23030
|
|
|
23028
|
-
|
|
23029
|
-
|
|
23031
|
+
}
|
|
23032
|
+
});
|
|
23033
|
+
}
|
|
23030
23034
|
}
|
|
23031
|
-
|
|
23032
23035
|
}
|
|
23033
23036
|
});
|
|
23034
23037
|
|