sf-i-events 1.0.926 → 1.0.927

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 CHANGED
@@ -732,7 +732,7 @@
732
732
  <!-- <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">
733
733
 
734
734
  </sf-i-events> -->
735
- <sf-i-events name="Calendar" apiid="dwqyez2puoxmu.cloudfront.net/event" mode="consumer"
735
+ <!-- <sf-i-events name="Calendar" apiid="dwqyez2puoxmu.cloudfront.net/event" mode="consumer"
736
736
  apiidtags="dnytrdlrmxgsy.cloudfront.net/tagging" apiidstatutes="dnytrdlrmxgsy.cloudfront.net/statute"
737
737
  apiiddefinitions="dwqyez2puoxmu.cloudfront.net/definition"
738
738
  apiidreportformats="dwqyez2puoxmu.cloudfront.net/reportformat"
@@ -759,7 +759,7 @@
759
759
  <sf-i-reporting id="reporting-format" mode="view"></sf-i-reporting>
760
760
  </div>
761
761
 
762
- </sf-i-events>
762
+ </sf-i-events> -->
763
763
  <!-- <sf-i-events name="Calendar" apiid="dwqyez2puoxmu.cloudfront.net/event" mode="consumer"
764
764
  apiidtags="dnytrdlrmxgsy.cloudfront.net/tagging" apiidstatutes="dnytrdlrmxgsy.cloudfront.net/statute"
765
765
  apiiddefinitions="dwqyez2puoxmu.cloudfront.net/definition"
@@ -808,7 +808,7 @@
808
808
  </div>
809
809
 
810
810
  </sf-i-events> -->
811
- <!-- <sf-i-events name="Calendar" apiid="dwqyez2puoxmu.cloudfront.net/event" mode="consumer"
811
+ <sf-i-events name="Calendar" apiid="dwqyez2puoxmu.cloudfront.net/event" mode="consumer"
812
812
  apiidtags="dnytrdlrmxgsy.cloudfront.net/tagging" apiidstatutes="dnytrdlrmxgsy.cloudfront.net/statute"
813
813
  apiiddefinitions="dwqyez2puoxmu.cloudfront.net/definition"
814
814
  apiidreportformats="dwqyez2puoxmu.cloudfront.net/reportformat"
@@ -833,7 +833,7 @@
833
833
  <sf-i-reporting id="reporting-format" mode="view"></sf-i-reporting>
834
834
  </div>
835
835
 
836
- </sf-i-events> -->
836
+ </sf-i-events>
837
837
  <!-- <sf-i-events name="Calendar" apiid="dwqyez2puoxmu.cloudfront.net/event" mode="consumer"
838
838
  apiidtags="dnytrdlrmxgsy.cloudfront.net/tagging" apiidstatutes="dnytrdlrmxgsy.cloudfront.net/statute"
839
839
  apiiddefinitions="dwqyez2puoxmu.cloudfront.net/definition"
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "sf-i-events",
3
3
  "private": false,
4
- "version": "1.0.926",
4
+ "version": "1.0.927",
5
5
  "description": "Superflows Navigation Component",
6
6
  "main": "sf-i-events.js",
7
7
  "module": "sf-i-events.js",
package/sf-i-events.d.ts CHANGED
@@ -270,6 +270,7 @@ export declare class SfIEvents extends LitElement {
270
270
  locationPartStatusData: any;
271
271
  locationLateStatusData: any;
272
272
  locationComplianceStatusData: any;
273
+ suspenseCount: Number;
273
274
  selectedItemIds: Array<string>;
274
275
  selectedItems: Array<any>;
275
276
  selectedStatus: string;
package/sf-i-events.js CHANGED
@@ -1226,6 +1226,7 @@ let SfIEvents = class SfIEvents extends LitElement {
1226
1226
  this.locationPartStatusData = null;
1227
1227
  this.locationLateStatusData = null;
1228
1228
  this.locationComplianceStatusData = null;
1229
+ this.suspenseCount = 0;
1229
1230
  this.selectedItemIds = [];
1230
1231
  this.selectedItems = [];
1231
1232
  this.selectedStatus = "";
@@ -2402,6 +2403,7 @@ let SfIEvents = class SfIEvents extends LitElement {
2402
2403
  html += '<div part="badge-dashboard" id="chip-completeness-1" class="chip stat-completeness d-flex justify-center align-center mr-10 mb-10 no-shrink"><span class="material-symbols-outlined color-pending">pending</span>&nbsp;&nbsp;<span>Pending Approval:</span>&nbsp;<span id="graph-pending-approval">DASHBOARD_PENDING_APPROVAL</span></div>';
2403
2404
  html += '<div part="badge-dashboard" id="chip-completeness-2" class="chip stat-completeness d-flex justify-center align-center mr-10 mb-10 no-shrink"><span class="material-symbols-outlined color-rejected">block</span>&nbsp;&nbsp;<span>Rejected:</span>&nbsp;<span id="graph-rejected">DASHBOARD_REJECTED</span></div>';
2404
2405
  html += '<div part="badge-dashboard" id="chip-completeness-3" class="chip stat-completeness d-flex justify-center align-center mr-10 mb-10 no-shrink"><span class="material-symbols-outlined color-done">check_circle</span>&nbsp;&nbsp;<span>Approved:</span>&nbsp;<span id="graph-approved">DASHBOARD_APPROVED</span></div>';
2406
+ html += '<div part="badge-dashboard" class="mr-10 mb-10 no-shrink"><span>Suspense:</span>&nbsp;<span id="graph-total">DASHBOARD_SUSPENSE</span></div>';
2405
2407
  html += '<div part="badge-dashboard" id="chip-timeliness-0" class="chip stat-timeliness justify-center align-center mr-10 mb-10 no-shrink late-statuses"><span class="material-icons color-in-time">schedule</span>&nbsp;&nbsp;<span>In Time:</span>&nbsp;<span id="graph-in-time">DASHBOARD_IN_TIME</span></div>';
2406
2408
  html += '<div part="badge-dashboard" id="chip-timeliness-1" class="chip stat-timeliness justify-center align-center mr-10 mb-10 no-shrink late-statuses"><span class="material-icons color-past-due-date">timer</span>&nbsp;&nbsp;<span>Past Due Date:</span>&nbsp;<span id="graph-past-due-date">DASHBOARD_PAST_DUE_DATE</span></div>';
2407
2409
  html += '<div part="badge-dashboard" id="chip-timeliness-2" class="chip stat-timeliness justify-center align-center mr-10 mb-10 no-shrink late-statuses"><span class="material-icons color-late-reported">report_off</span>&nbsp;&nbsp;<span>Late Reported:</span>&nbsp;<span id="graph-late-reported">DASHBOARD_LATE_REPORTED</span></div>';
@@ -3277,6 +3279,7 @@ let SfIEvents = class SfIEvents extends LitElement {
3277
3279
  //console.log('renderevents htmlcols', this.htmlDataCompliances);
3278
3280
  //console.log('progress', this.period, total, notStarted, approved)
3279
3281
  html = html.replace("DASHBOARD_TOTAL", total + "");
3282
+ html = html.replace("DASHBOARD_SUSPENSE", this.suspenseCount + "");
3280
3283
  html = html.replace("DASHBOARD_NOT_STARTED", notStarted + "");
3281
3284
  html = html.replace("DASHBOARD_APPROVED", approved + "");
3282
3285
  html = html.replace("DASHBOARD_PENDING_APPROVAL", pendingApproval + "");
@@ -13755,10 +13758,12 @@ let SfIEvents = class SfIEvents extends LitElement {
13755
13758
  html += '<div class="d-flex justify-end w-100 mb-10">';
13756
13759
  html += '<textarea part="input" id="feedback-message" class="w-100 mt-10 mb-10 hide" placeholder="Type your feedback message here..."></textarea>';
13757
13760
  html += '</div>';
13758
- // html += '<div class="d-flex justify-end w-100">'
13759
- // html += '<input part="input" id="feedback-suspense" class="mb-10 hide" type="checkbox"/>'
13760
- // html += '<label part="input-label" id="feedback-suspense-label" class="ml-10 mb-10 hide">Move to suspense account</label>'
13761
- // html += '</div>'
13761
+ if (this.myRole == this.TAB_FUNCTION_HEAD) {
13762
+ html += '<div class="d-flex justify-end w-100">';
13763
+ html += '<input part="input" id="feedback-suspense" class="mb-10 hide" type="checkbox"/>';
13764
+ html += '<label part="input-label" id="feedback-suspense-label" class="ml-10 mb-10 hide">Move to suspense account</label>';
13765
+ html += '</div>';
13766
+ }
13762
13767
  html += '<div class="d-flex w-100">';
13763
13768
  html += ('<button part="button-lg-short" id="button-feedback" class="d-flex justify-center align-center"><span class="material-symbols-outlined">comment</span><span>&nbsp;&nbsp;Send Feedback</span></button>');
13764
13769
  html += ('<button part="button-lg-short-secondary" id="button-feedback-cancel" class="hide d-flex justify-center align-center mr-10"><span class="material-symbols-outlined">close</span><span>&nbsp;&nbsp;Cancel</span></button>');
@@ -22639,6 +22644,7 @@ let SfIEvents = class SfIEvents extends LitElement {
22639
22644
  }
22640
22645
  };
22641
22646
  this.fetchAndYearlyRenderUserCalendar_2 = async (startDate = "", endDate = "", searchString = "", list = "yes", month = "00", year = this.calendarStartYYYY) => {
22647
+ var _a;
22642
22648
  let path = "", view = "";
22643
22649
  this.sdate = startDate;
22644
22650
  this.edate = endDate;
@@ -22654,7 +22660,7 @@ let SfIEvents = class SfIEvents extends LitElement {
22654
22660
  else {
22655
22661
  view = "entity";
22656
22662
  }
22657
- path = "getallcountryevents3";
22663
+ path = "getallcountryevents4";
22658
22664
  let sDate = "";
22659
22665
  let eDate = "";
22660
22666
  //console.log('currenttab', this.getCurrentTab());
@@ -22689,6 +22695,7 @@ let SfIEvents = class SfIEvents extends LitElement {
22689
22695
  await this.fetchPresignedUrlDelete(jsonRespose.signedUrlDelete);
22690
22696
  if (JSON.stringify(urlBody) == this.getallcountryevetsParams) {
22691
22697
  this.lastupdated = Util.getDateTimeStrings(new Date().getTime());
22698
+ this.suspenseCount = (_a = jsonRespose.suspensecount) !== null && _a !== void 0 ? _a : 0;
22692
22699
  console.log('rendering appropriate string', list, this.selectedTab);
22693
22700
  this.renderAppropriateStream(startDate, endDate, true);
22694
22701
  this.fetchBulkReportingData();
@@ -22748,6 +22755,7 @@ let SfIEvents = class SfIEvents extends LitElement {
22748
22755
  }
22749
22756
  };
22750
22757
  this.fetchOnlyYearlyUserCalendar = async (startDate = "", endDate = "", searchString = "", list = "yes", month = "00", year = this.calendarStartYYYY, userprofileid = this.userProfileId, userrole = this.myRole, entityid = this.entityId, countryid = this.countryId, locationid = this.locationId, tagid = this.tagId, functionid = this.functionId) => {
22758
+ var _a;
22751
22759
  let path = "", view = "";
22752
22760
  if (tagid != null && tagid != "") {
22753
22761
  view = "tag";
@@ -22761,7 +22769,7 @@ let SfIEvents = class SfIEvents extends LitElement {
22761
22769
  else {
22762
22770
  view = "entity";
22763
22771
  }
22764
- path = "getallcountryevents3";
22772
+ path = "getallcountryevents4";
22765
22773
  let url = "https://" + this.apiId + "/" + path;
22766
22774
  let temptagid = tagid;
22767
22775
  if (temptagid == "" && locationid != "") {
@@ -22788,6 +22796,7 @@ let SfIEvents = class SfIEvents extends LitElement {
22788
22796
  // if (JSON.stringify(urlBody) == this.getallcountryevetsParams) {
22789
22797
  this.events = (await this.fetchPresignedUrl(jsonRespose.signedUrlGet));
22790
22798
  // }
22799
+ this.suspenseCount = (_a = jsonRespose.suspensecount) !== null && _a !== void 0 ? _a : 0;
22791
22800
  await this.fetchPresignedUrlDelete(jsonRespose.signedUrlDelete);
22792
22801
  }
22793
22802
  else {
@@ -24234,7 +24243,7 @@ let SfIEvents = class SfIEvents extends LitElement {
24234
24243
  day = '0' + day;
24235
24244
  let eDate = month + "/" + day + "/" + year;
24236
24245
  let urlBody = { "projectid": this.projectId, "userprofileid": this.userProfileId, "role": this.myRole, "entityid": complianceEntityId, "countryid": "", "functionid": "", "locationid": complianceLocationId, "tagid": this.tagId, "adhoc": "false", "exclusivestartkey": 0, "sdate": sDate, "edate": eDate, "view": "location", "year": this.calendarStartYYYY };
24237
- let url = "https://" + this.apiId + "/getallcountryevents3";
24246
+ let url = "https://" + this.apiId + "/getallcountryevents4";
24238
24247
  const authorization = btoa(Util.readCookie('email') + ":" + Util.readCookie('accessToken'));
24239
24248
  const xhr = (await this.prepareXhr(urlBody, url, this._SfLoader, authorization, 'Preparing'));
24240
24249
  this._SfLoader.innerHTML = '';
@@ -24319,7 +24328,7 @@ let SfIEvents = class SfIEvents extends LitElement {
24319
24328
  console.log('fetching compliances', sortid);
24320
24329
  let complianceEntityId = sortid.split(';')[1];
24321
24330
  let complianceLocationId = sortid.split(';')[2];
24322
- let url = "https://" + this.apiId + "/getallcountryevents3";
24331
+ let url = "https://" + this.apiId + "/getallcountryevents4";
24323
24332
  let sDateObj = selectedDate;
24324
24333
  sDateObj.setDate(selectedDate.getDate() - 60);
24325
24334
  let day = '' + sDateObj.getDate();
@@ -26633,6 +26642,9 @@ __decorate([
26633
26642
  __decorate([
26634
26643
  property()
26635
26644
  ], SfIEvents.prototype, "locationComplianceStatusData", void 0);
26645
+ __decorate([
26646
+ property()
26647
+ ], SfIEvents.prototype, "suspenseCount", void 0);
26636
26648
  __decorate([
26637
26649
  property({ type: Array })
26638
26650
  ], SfIEvents.prototype, "selectedItemIds", void 0);
@@ -1617,6 +1617,9 @@ export class SfIEvents extends LitElement {
1617
1617
  @property()
1618
1618
  locationComplianceStatusData: any = null;
1619
1619
 
1620
+ @property()
1621
+ suspenseCount: Number = 0;
1622
+
1620
1623
  @property({ type: Array })
1621
1624
  selectedItemIds: Array<string> = [];
1622
1625
 
@@ -4578,6 +4581,7 @@ export class SfIEvents extends LitElement {
4578
4581
  html += '<div part="badge-dashboard" id="chip-completeness-1" class="chip stat-completeness d-flex justify-center align-center mr-10 mb-10 no-shrink"><span class="material-symbols-outlined color-pending">pending</span>&nbsp;&nbsp;<span>Pending Approval:</span>&nbsp;<span id="graph-pending-approval">DASHBOARD_PENDING_APPROVAL</span></div>';
4579
4582
  html += '<div part="badge-dashboard" id="chip-completeness-2" class="chip stat-completeness d-flex justify-center align-center mr-10 mb-10 no-shrink"><span class="material-symbols-outlined color-rejected">block</span>&nbsp;&nbsp;<span>Rejected:</span>&nbsp;<span id="graph-rejected">DASHBOARD_REJECTED</span></div>';
4580
4583
  html += '<div part="badge-dashboard" id="chip-completeness-3" class="chip stat-completeness d-flex justify-center align-center mr-10 mb-10 no-shrink"><span class="material-symbols-outlined color-done">check_circle</span>&nbsp;&nbsp;<span>Approved:</span>&nbsp;<span id="graph-approved">DASHBOARD_APPROVED</span></div>';
4584
+ html += '<div part="badge-dashboard" class="mr-10 mb-10 no-shrink"><span>Suspense:</span>&nbsp;<span id="graph-total">DASHBOARD_SUSPENSE</span></div>';
4581
4585
 
4582
4586
  html += '<div part="badge-dashboard" id="chip-timeliness-0" class="chip stat-timeliness justify-center align-center mr-10 mb-10 no-shrink late-statuses"><span class="material-icons color-in-time">schedule</span>&nbsp;&nbsp;<span>In Time:</span>&nbsp;<span id="graph-in-time">DASHBOARD_IN_TIME</span></div>';
4583
4587
  html += '<div part="badge-dashboard" id="chip-timeliness-1" class="chip stat-timeliness justify-center align-center mr-10 mb-10 no-shrink late-statuses"><span class="material-icons color-past-due-date">timer</span>&nbsp;&nbsp;<span>Past Due Date:</span>&nbsp;<span id="graph-past-due-date">DASHBOARD_PAST_DUE_DATE</span></div>';
@@ -5569,6 +5573,7 @@ export class SfIEvents extends LitElement {
5569
5573
  //console.log('progress', this.period, total, notStarted, approved)
5570
5574
 
5571
5575
  html = html.replace("DASHBOARD_TOTAL", total + "");
5576
+ html = html.replace("DASHBOARD_SUSPENSE", this.suspenseCount + "");
5572
5577
  html = html.replace("DASHBOARD_NOT_STARTED", notStarted + "");
5573
5578
  html = html.replace("DASHBOARD_APPROVED", approved + "");
5574
5579
  html = html.replace("DASHBOARD_PENDING_APPROVAL", pendingApproval + "");
@@ -17766,10 +17771,12 @@ export class SfIEvents extends LitElement {
17766
17771
  html += '<div class="d-flex justify-end w-100 mb-10">'
17767
17772
  html += '<textarea part="input" id="feedback-message" class="w-100 mt-10 mb-10 hide" placeholder="Type your feedback message here..."></textarea>'
17768
17773
  html += '</div>'
17769
- // html += '<div class="d-flex justify-end w-100">'
17770
- // html += '<input part="input" id="feedback-suspense" class="mb-10 hide" type="checkbox"/>'
17771
- // html += '<label part="input-label" id="feedback-suspense-label" class="ml-10 mb-10 hide">Move to suspense account</label>'
17772
- // html += '</div>'
17774
+ if(this.myRole == this.TAB_FUNCTION_HEAD) {
17775
+ html += '<div class="d-flex justify-end w-100">'
17776
+ html += '<input part="input" id="feedback-suspense" class="mb-10 hide" type="checkbox"/>'
17777
+ html += '<label part="input-label" id="feedback-suspense-label" class="ml-10 mb-10 hide">Move to suspense account</label>'
17778
+ html += '</div>'
17779
+ }
17773
17780
  html += '<div class="d-flex w-100">'
17774
17781
  html += ('<button part="button-lg-short" id="button-feedback" class="d-flex justify-center align-center"><span class="material-symbols-outlined">comment</span><span>&nbsp;&nbsp;Send Feedback</span></button>');
17775
17782
  html += ('<button part="button-lg-short-secondary" id="button-feedback-cancel" class="hide d-flex justify-center align-center mr-10"><span class="material-symbols-outlined">close</span><span>&nbsp;&nbsp;Cancel</span></button>');
@@ -28874,7 +28881,7 @@ export class SfIEvents extends LitElement {
28874
28881
  view = "entity";
28875
28882
  }
28876
28883
 
28877
- path = "getallcountryevents3";
28884
+ path = "getallcountryevents4";
28878
28885
 
28879
28886
  let sDate = "";
28880
28887
  let eDate = "";
@@ -28917,6 +28924,7 @@ export class SfIEvents extends LitElement {
28917
28924
  await this.fetchPresignedUrlDelete(jsonRespose.signedUrlDelete)
28918
28925
  if (JSON.stringify(urlBody) == this.getallcountryevetsParams) {
28919
28926
  this.lastupdated = Util.getDateTimeStrings(new Date().getTime())
28927
+ this.suspenseCount = jsonRespose.suspensecount ?? 0;
28920
28928
  console.log('rendering appropriate string', list, this.selectedTab);
28921
28929
  this.renderAppropriateStream(startDate, endDate, true);
28922
28930
  this.fetchBulkReportingData();
@@ -29014,7 +29022,7 @@ export class SfIEvents extends LitElement {
29014
29022
  view = "entity";
29015
29023
  }
29016
29024
 
29017
- path = "getallcountryevents3";
29025
+ path = "getallcountryevents4";
29018
29026
 
29019
29027
  let url = "https://" + this.apiId + "/" + path;
29020
29028
  let temptagid = tagid;
@@ -29044,6 +29052,7 @@ export class SfIEvents extends LitElement {
29044
29052
  // if (JSON.stringify(urlBody) == this.getallcountryevetsParams) {
29045
29053
  this.events = (await this.fetchPresignedUrl(jsonRespose.signedUrlGet));
29046
29054
  // }
29055
+ this.suspenseCount = jsonRespose.suspensecount ?? 0;
29047
29056
  await this.fetchPresignedUrlDelete(jsonRespose.signedUrlDelete)
29048
29057
 
29049
29058
  } else {
@@ -30740,7 +30749,7 @@ export class SfIEvents extends LitElement {
30740
30749
  day = '0' + day;
30741
30750
  let eDate = month + "/" + day + "/" + year
30742
30751
  let urlBody: any = { "projectid": this.projectId, "userprofileid": this.userProfileId, "role": this.myRole, "entityid": complianceEntityId, "countryid": "", "functionid": "", "locationid": complianceLocationId, "tagid": this.tagId, "adhoc": "false", "exclusivestartkey": 0, "sdate": sDate, "edate": eDate, "view": "location", "year": this.calendarStartYYYY };
30743
- let url = "https://" + this.apiId + "/getallcountryevents3";
30752
+ let url = "https://" + this.apiId + "/getallcountryevents4";
30744
30753
  const authorization = btoa(Util.readCookie('email') + ":" + Util.readCookie('accessToken'));
30745
30754
  const xhr: any = (await this.prepareXhr(urlBody, url, this._SfLoader, authorization, 'Preparing')) as any;
30746
30755
  this._SfLoader.innerHTML = '';
@@ -30833,7 +30842,7 @@ export class SfIEvents extends LitElement {
30833
30842
  console.log('fetching compliances', sortid)
30834
30843
  let complianceEntityId = sortid.split(';')[1]
30835
30844
  let complianceLocationId = sortid.split(';')[2]
30836
- let url = "https://" + this.apiId + "/getallcountryevents3";
30845
+ let url = "https://" + this.apiId + "/getallcountryevents4";
30837
30846
  let sDateObj = selectedDate
30838
30847
  sDateObj.setDate(selectedDate.getDate() - 60)
30839
30848
  let day = '' + sDateObj.getDate();