sf-i-events 1.0.890 → 1.0.891
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 +4 -4
- package/package.json +1 -1
- package/sf-i-events.js +10 -6
- package/src/sf-i-events.ts +9 -6
package/dev/index.html
CHANGED
|
@@ -786,7 +786,7 @@
|
|
|
786
786
|
</div>
|
|
787
787
|
|
|
788
788
|
</sf-i-events> -->
|
|
789
|
-
|
|
789
|
+
<sf-i-events name="Calendar" apiid="dwqyez2puoxmu.cloudfront.net/event" mode="consumer"
|
|
790
790
|
apiidtags="dnytrdlrmxgsy.cloudfront.net/tagging" apiidstatutes="dnytrdlrmxgsy.cloudfront.net/statute"
|
|
791
791
|
apiiddefinitions="dwqyez2puoxmu.cloudfront.net/definition"
|
|
792
792
|
apiidreportformats="dwqyez2puoxmu.cloudfront.net/reportformat"
|
|
@@ -813,8 +813,8 @@
|
|
|
813
813
|
<sf-i-reporting id="reporting-format" mode="view"></sf-i-reporting>
|
|
814
814
|
</div>
|
|
815
815
|
|
|
816
|
-
</sf-i-events>
|
|
817
|
-
<sf-i-events name="Calendar" apiid="dwqyez2puoxmu.cloudfront.net/event" mode="consumer"
|
|
816
|
+
</sf-i-events>
|
|
817
|
+
<!-- <sf-i-events name="Calendar" apiid="dwqyez2puoxmu.cloudfront.net/event" mode="consumer"
|
|
818
818
|
apiidtags="dnytrdlrmxgsy.cloudfront.net/tagging" apiidstatutes="dnytrdlrmxgsy.cloudfront.net/statute"
|
|
819
819
|
apiiddefinitions="dwqyez2puoxmu.cloudfront.net/definition"
|
|
820
820
|
apiidreportformats="dwqyez2puoxmu.cloudfront.net/reportformat"
|
|
@@ -841,7 +841,7 @@
|
|
|
841
841
|
<sf-i-reporting id="reporting-format" mode="view"></sf-i-reporting>
|
|
842
842
|
</div>
|
|
843
843
|
|
|
844
|
-
</sf-i-events>
|
|
844
|
+
</sf-i-events> -->
|
|
845
845
|
<!-- <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="Viewer J1" userprofileid="344c84d2-5976-47ff-949b-49f6fa9627eb" projectid="41ab3c86-ccc0-4c0e-8e31-cd079a07a710" projectname="ABC Global" countryid="07d73b44-648d-4301-82c4-d6df43397824" myrole="viewer" 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="2025">
|
|
846
846
|
|
|
847
847
|
<div slot="uploader">
|
package/package.json
CHANGED
package/sf-i-events.js
CHANGED
|
@@ -2561,9 +2561,11 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
2561
2561
|
const mmddSanitized = mmdd.replace(/\//g, '-');
|
|
2562
2562
|
const dueDateParts = event.duedate.split('/');
|
|
2563
2563
|
const showCheckbox = !(hasReportFormat || isBulk || hasCustomReporting);
|
|
2564
|
-
const showReportingButton = !hasReportFormat && !hasCustomReporting && event.reporters == null;
|
|
2565
|
-
const
|
|
2564
|
+
// const showReportingButton = !hasReportFormat && !hasCustomReporting && event.reporters == null;
|
|
2565
|
+
const showReportingButton = !hasReportFormat && !hasCustomReporting && event.concise != null;
|
|
2566
|
+
const showLocationRisk = event.concise != null;
|
|
2566
2567
|
const showLastUpdated = event.concise == null && lastUpdated.length > 0;
|
|
2568
|
+
console.log('showReportingButton', showReportingButton);
|
|
2567
2569
|
html += `
|
|
2568
2570
|
<div part="stream-events-event-title" class="stream-events-event-title d-flex align-center pl-5 pb-5">
|
|
2569
2571
|
<input
|
|
@@ -2879,7 +2881,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
2879
2881
|
html += '<div class="hidden-filtername hide"><table><thead><th part="badge-filter-name" class="filtername"></th></thead></table></div>';
|
|
2880
2882
|
// if(event.concise == null && event.approvers != null){
|
|
2881
2883
|
let reporterStr = event.concise == null ? this.getReporterStringFromEvent(event) : "";
|
|
2882
|
-
let approverStr = event.
|
|
2884
|
+
let approverStr = event.concise == null ? this.getApproverStringFromEvent(event) : "";
|
|
2883
2885
|
let graphParam = this.getGraphParam(event);
|
|
2884
2886
|
// console.log("graphParam", graphParam.split(';')[0]);
|
|
2885
2887
|
html += '<div class="d-flex align-center event-user-labels-container"><div part="badge-filter-name" class="graphparamname graphparamname1 mb-20' + (event.concise == null ? "" : ' hide') + '">' + graphParam.split(';')[0] + '</div>' + reporterStr + approverStr + ((event.concise == null && ((event.reportformat == null || event.reportformat.length == 0) && (event.customreporting == null))) ? ('<button id="button-list-reporting-' + mmdd.replace('/', '-') + '-' + j + '" part="button-list-reporting" class="material-icons ml-10 mb-20 button-list-reporting">edit_note</button>') : '') + '</div>';
|
|
@@ -3234,7 +3236,8 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
3234
3236
|
}
|
|
3235
3237
|
}
|
|
3236
3238
|
html += this.renderCalendarRowDivItemDivStart(mmdd, this.events[mmdd][j], j, partStatus, bgStatus);
|
|
3237
|
-
if (this.events[mmdd][j]["countryname"] != null) {
|
|
3239
|
+
// if (this.events[mmdd][j]["countryname"] != null) {
|
|
3240
|
+
if (this.events[mmdd][j]["concise"] == null) {
|
|
3238
3241
|
html += this.renderCalendarRowDivItemDivTableHead(this.events[mmdd][j], partStatus);
|
|
3239
3242
|
html += this.renderCalendarRowDivItemDivTableBody(this.events[mmdd][j], partStatus, lateStatus, complianceStatus, mmdd, i, j);
|
|
3240
3243
|
}
|
|
@@ -13431,7 +13434,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
13431
13434
|
});
|
|
13432
13435
|
if (this.mode == "consumer" || this.mode == "next") {
|
|
13433
13436
|
(_t = this._SfDetailContainer.querySelector('#button-uploader-submit-approve')) === null || _t === void 0 ? void 0 : _t.addEventListener('click', async (ev) => {
|
|
13434
|
-
var _a, _b;
|
|
13437
|
+
var _a, _b, _c;
|
|
13435
13438
|
let buttonClick = ev.target;
|
|
13436
13439
|
buttonClick.innerHTML = "Saving...";
|
|
13437
13440
|
const comments = this._SfDetailContainer.querySelector('#input-approver-comments').value;
|
|
@@ -13462,6 +13465,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
13462
13465
|
if (await this.uploadReview(entityId, locationId, mmddyyyy, event["id"], comments, approved, (_a = event.module) !== null && _a !== void 0 ? _a : "compliance")) {
|
|
13463
13466
|
for (var p = 0; p < this.events[mmdd].length; p++) {
|
|
13464
13467
|
if (this.events[mmdd][p].id == event.id && this.events[mmdd][p].locationid == locationId && this.events[mmdd][p].entityid == entityId) {
|
|
13468
|
+
this.events[mmdd][p].approved = approved;
|
|
13465
13469
|
this.events[mmdd][p].comments.push({ 'author': 'Approver', 'comment': comments + ` (Approved: ${approved ? 'Yes' : 'No'})`, 'timestamp': new Date().toString() });
|
|
13466
13470
|
this.events[mmdd][p].lastupdated = new Date().toString();
|
|
13467
13471
|
}
|
|
@@ -13546,7 +13550,7 @@ let SfIEvents = class SfIEvents extends LitElement {
|
|
|
13546
13550
|
"bubbles": true,
|
|
13547
13551
|
"cancelable": false
|
|
13548
13552
|
});
|
|
13549
|
-
this._SfDetailContainer.querySelector('#button-detail-close').dispatchEvent(clickEvent);
|
|
13553
|
+
(_c = this._SfDetailContainer.querySelector('#button-detail-close')) === null || _c === void 0 ? void 0 : _c.dispatchEvent(clickEvent);
|
|
13550
13554
|
// if(currentColumnButton != null) {
|
|
13551
13555
|
// currentColumnButton.click();
|
|
13552
13556
|
// }
|
package/src/sf-i-events.ts
CHANGED
|
@@ -4774,10 +4774,11 @@ export class SfIEvents extends LitElement {
|
|
|
4774
4774
|
const mmddSanitized = mmdd.replace(/\//g, '-');
|
|
4775
4775
|
const dueDateParts = event.duedate.split('/');
|
|
4776
4776
|
const showCheckbox = !(hasReportFormat || isBulk || hasCustomReporting);
|
|
4777
|
-
const showReportingButton = !hasReportFormat && !hasCustomReporting && event.reporters == null;
|
|
4778
|
-
const
|
|
4777
|
+
// const showReportingButton = !hasReportFormat && !hasCustomReporting && event.reporters == null;
|
|
4778
|
+
const showReportingButton = !hasReportFormat && !hasCustomReporting && event.concise != null;
|
|
4779
|
+
const showLocationRisk = event.concise != null;
|
|
4779
4780
|
const showLastUpdated = event.concise == null && lastUpdated.length > 0;
|
|
4780
|
-
|
|
4781
|
+
console.log('showReportingButton', showReportingButton)
|
|
4781
4782
|
html += `
|
|
4782
4783
|
<div part="stream-events-event-title" class="stream-events-event-title d-flex align-center pl-5 pb-5">
|
|
4783
4784
|
<input
|
|
@@ -5134,7 +5135,7 @@ export class SfIEvents extends LitElement {
|
|
|
5134
5135
|
html += '<div class="hidden-filtername hide"><table><thead><th part="badge-filter-name" class="filtername"></th></thead></table></div>'
|
|
5135
5136
|
// if(event.concise == null && event.approvers != null){
|
|
5136
5137
|
let reporterStr = event.concise == null ? this.getReporterStringFromEvent(event) : "";
|
|
5137
|
-
let approverStr = event.
|
|
5138
|
+
let approverStr = event.concise == null ? this.getApproverStringFromEvent(event) : "";
|
|
5138
5139
|
|
|
5139
5140
|
let graphParam = this.getGraphParam(event);
|
|
5140
5141
|
// console.log("graphParam", graphParam.split(';')[0]);
|
|
@@ -5506,7 +5507,8 @@ export class SfIEvents extends LitElement {
|
|
|
5506
5507
|
}
|
|
5507
5508
|
|
|
5508
5509
|
html += this.renderCalendarRowDivItemDivStart(mmdd, this.events[mmdd][j], j, partStatus, bgStatus);
|
|
5509
|
-
if (this.events[mmdd][j]["countryname"] != null) {
|
|
5510
|
+
// if (this.events[mmdd][j]["countryname"] != null) {
|
|
5511
|
+
if (this.events[mmdd][j]["concise"] == null) {
|
|
5510
5512
|
html += this.renderCalendarRowDivItemDivTableHead(this.events[mmdd][j], partStatus);
|
|
5511
5513
|
html += this.renderCalendarRowDivItemDivTableBody(this.events[mmdd][j], partStatus, lateStatus, complianceStatus, mmdd, i, j);
|
|
5512
5514
|
}
|
|
@@ -17534,6 +17536,7 @@ export class SfIEvents extends LitElement {
|
|
|
17534
17536
|
for (var p = 0; p < this.events[mmdd].length; p++) {
|
|
17535
17537
|
if (this.events[mmdd][p].id == event.id && this.events[mmdd][p].locationid == locationId && this.events[mmdd][p].entityid == entityId) {
|
|
17536
17538
|
|
|
17539
|
+
this.events[mmdd][p].approved = approved
|
|
17537
17540
|
this.events[mmdd][p].comments.push({ 'author': 'Approver', 'comment': comments + ` (Approved: ${approved ? 'Yes' : 'No'})`, 'timestamp': new Date().toString() })
|
|
17538
17541
|
this.events[mmdd][p].lastupdated = new Date().toString()
|
|
17539
17542
|
}
|
|
@@ -17623,7 +17626,7 @@ export class SfIEvents extends LitElement {
|
|
|
17623
17626
|
"bubbles": true,
|
|
17624
17627
|
"cancelable": false
|
|
17625
17628
|
});
|
|
17626
|
-
((this._SfDetailContainer as HTMLDivElement).querySelector('#button-detail-close') as HTMLButtonElement)
|
|
17629
|
+
((this._SfDetailContainer as HTMLDivElement).querySelector('#button-detail-close') as HTMLButtonElement)?.dispatchEvent(clickEvent);
|
|
17627
17630
|
|
|
17628
17631
|
// if(currentColumnButton != null) {
|
|
17629
17632
|
// currentColumnButton.click();
|