sf-i-events 1.0.782 → 1.0.783
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 +1 -1
- package/package.json +1 -1
- package/sf-i-events.js +13 -3
- package/src/sf-i-events.ts +13 -6
package/dev/index.html
CHANGED
|
@@ -638,7 +638,7 @@
|
|
|
638
638
|
</div>
|
|
639
639
|
|
|
640
640
|
</sf-i-events> -->
|
|
641
|
-
<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="Ankur Singhal" userprofileid="010834e8-108e-4a87-b58d-f5b429f184be" projectid="f0f17ddb-546a-45f5-8a94-a5689fde8e64" projectname="Signode" countryid="4ab8901c-4407-4c4d-a2c7-df1a690aa0a3" myrole="viewer" showregisterexport="
|
|
641
|
+
<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="Ankur Singhal" userprofileid="010834e8-108e-4a87-b58d-f5b429f184be" projectid="f0f17ddb-546a-45f5-8a94-a5689fde8e64" projectname="Signode" countryid="4ab8901c-4407-4c4d-a2c7-df1a690aa0a3" myrole="viewer" showregisterexport="true" 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">
|
|
642
642
|
|
|
643
643
|
<div slot="uploader">
|
|
644
644
|
<sf-i-uploader id="uploader" max="10" apiid="1peg5170d3" allowedextensions="["jpg","png","pdf","xls","xlsx","doc","docx"]" extract="yes" projectid="f0f17ddb-546a-45f5-8a94-a5689fde8e64" maxsize="5242880" allowdownload="yes"></sf-i-uploader>
|
package/package.json
CHANGED
package/sf-i-events.js
CHANGED
|
@@ -4858,8 +4858,11 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
4858
4858
|
this.selectedRegisterIndex = index;
|
|
4859
4859
|
let selectedCountry = Object.keys(events)[this.selectedCountryTab];
|
|
4860
4860
|
let selectedStatute = Object.keys(events[selectedCountry])[index];
|
|
4861
|
-
|
|
4862
|
-
events[selectedCountry][selectedStatute]
|
|
4861
|
+
console.log('registerevents', Object.keys(events[selectedCountry][selectedStatute]).length);
|
|
4862
|
+
if (Object.keys(events[selectedCountry][selectedStatute]).length == 0) {
|
|
4863
|
+
let tempRegisters = await this.fetchRegisters("", "", selectedCountry, selectedStatute);
|
|
4864
|
+
events[selectedCountry][selectedStatute] = tempRegisters[selectedCountry][selectedStatute];
|
|
4865
|
+
}
|
|
4863
4866
|
this.renderRegisterEvents(events);
|
|
4864
4867
|
// const divBodys = ((this._SfRegisterContainer.querySelector('.calendar-right-data') as HTMLDivElement).querySelectorAll('.register-body-'+ index) as NodeListOf<HTMLDivElement>);
|
|
4865
4868
|
// for(let divBody of divBodys){
|
|
@@ -4873,6 +4876,10 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
4873
4876
|
// }
|
|
4874
4877
|
});
|
|
4875
4878
|
}
|
|
4879
|
+
const registerStatute = this._SfRegisterContainer.querySelector('.calendar-right-data').querySelector('#register-statute-' + this.selectedRegisterIndex);
|
|
4880
|
+
if (registerStatute != null) {
|
|
4881
|
+
registerStatute.scrollIntoView();
|
|
4882
|
+
}
|
|
4876
4883
|
}
|
|
4877
4884
|
else {
|
|
4878
4885
|
const index = 0;
|
|
@@ -6606,7 +6613,9 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
6606
6613
|
this.renderRegisterEvents(events);
|
|
6607
6614
|
}
|
|
6608
6615
|
});
|
|
6609
|
-
(_b = this._SfRegisterContainer.querySelector('#button-download')) === null || _b === void 0 ? void 0 : _b.addEventListener('click', () => {
|
|
6616
|
+
(_b = this._SfRegisterContainer.querySelector('#button-download')) === null || _b === void 0 ? void 0 : _b.addEventListener('click', async () => {
|
|
6617
|
+
let tempEvents = await this.fetchRegisters("", "all", "", "");
|
|
6618
|
+
this.renderRegisterEvents(tempEvents, "all");
|
|
6610
6619
|
const ts = new Date();
|
|
6611
6620
|
console.log(this.csvDataRegisters);
|
|
6612
6621
|
const blob = new Blob([this.csvDataRegisters], { type: 'text/csv' });
|
|
@@ -19402,6 +19411,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
19402
19411
|
super.connectedCallback();
|
|
19403
19412
|
}
|
|
19404
19413
|
render() {
|
|
19414
|
+
console.log('rendering', this.mode);
|
|
19405
19415
|
if (this.mode == "rcmnotifications") {
|
|
19406
19416
|
return html `
|
|
19407
19417
|
|
package/src/sf-i-events.ts
CHANGED
|
@@ -7441,8 +7441,11 @@ export class SfIEvents extends LitElement {
|
|
|
7441
7441
|
this.selectedRegisterIndex = index;
|
|
7442
7442
|
let selectedCountry = Object.keys(events)[this.selectedCountryTab]
|
|
7443
7443
|
let selectedStatute = Object.keys(events[selectedCountry])[index]
|
|
7444
|
-
|
|
7445
|
-
events[selectedCountry][selectedStatute]
|
|
7444
|
+
console.log('registerevents', Object.keys(events[selectedCountry][selectedStatute]).length)
|
|
7445
|
+
if(Object.keys(events[selectedCountry][selectedStatute]).length == 0){
|
|
7446
|
+
let tempRegisters = await this.fetchRegisters("","",selectedCountry,selectedStatute);
|
|
7447
|
+
events[selectedCountry][selectedStatute] = tempRegisters[selectedCountry][selectedStatute]
|
|
7448
|
+
}
|
|
7446
7449
|
this.renderRegisterEvents(events);
|
|
7447
7450
|
// const divBodys = ((this._SfRegisterContainer.querySelector('.calendar-right-data') as HTMLDivElement).querySelectorAll('.register-body-'+ index) as NodeListOf<HTMLDivElement>);
|
|
7448
7451
|
// for(let divBody of divBodys){
|
|
@@ -7458,7 +7461,10 @@ export class SfIEvents extends LitElement {
|
|
|
7458
7461
|
});
|
|
7459
7462
|
|
|
7460
7463
|
}
|
|
7461
|
-
|
|
7464
|
+
const registerStatute = (this._SfRegisterContainer.querySelector('.calendar-right-data') as HTMLDivElement).querySelector('#register-statute-' + this.selectedRegisterIndex) as HTMLDivElement;
|
|
7465
|
+
if(registerStatute != null){
|
|
7466
|
+
registerStatute.scrollIntoView();
|
|
7467
|
+
}
|
|
7462
7468
|
} else {
|
|
7463
7469
|
const index = 0;
|
|
7464
7470
|
this.selectedCountryTab = index
|
|
@@ -9599,8 +9605,9 @@ export class SfIEvents extends LitElement {
|
|
|
9599
9605
|
}
|
|
9600
9606
|
});
|
|
9601
9607
|
|
|
9602
|
-
(this._SfRegisterContainer as HTMLDivElement).querySelector('#button-download')?.addEventListener('click', () => {
|
|
9603
|
-
|
|
9608
|
+
(this._SfRegisterContainer as HTMLDivElement).querySelector('#button-download')?.addEventListener('click', async() => {
|
|
9609
|
+
let tempEvents = await this.fetchRegisters("","all","","")
|
|
9610
|
+
this.renderRegisterEvents(tempEvents,"all");
|
|
9604
9611
|
const ts = new Date();
|
|
9605
9612
|
console.log(this.csvDataRegisters);
|
|
9606
9613
|
const blob = new Blob([this.csvDataRegisters], { type: 'text/csv' });
|
|
@@ -25702,7 +25709,7 @@ export class SfIEvents extends LitElement {
|
|
|
25702
25709
|
}
|
|
25703
25710
|
|
|
25704
25711
|
override render() {
|
|
25705
|
-
|
|
25712
|
+
console.log('rendering', this.mode);
|
|
25706
25713
|
if(this.mode == "rcmnotifications") {
|
|
25707
25714
|
|
|
25708
25715
|
return html`
|