sf-i-events 1.0.770 → 1.0.772
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/package.json +1 -1
- package/sf-i-events.d.ts +8 -8
- package/sf-i-events.js +139 -86
- package/src/sf-i-events.ts +138 -94
package/src/sf-i-events.ts
CHANGED
|
@@ -2695,14 +2695,7 @@ export class SfIEvents extends LitElement {
|
|
|
2695
2695
|
right: 10px
|
|
2696
2696
|
}
|
|
2697
2697
|
#button-background-process {
|
|
2698
|
-
|
|
2699
|
-
position: fixed;
|
|
2700
|
-
top: 10px;
|
|
2701
|
-
left:0;
|
|
2702
|
-
right: 0;
|
|
2703
|
-
margin-left: auto;
|
|
2704
|
-
margin-right: auto;
|
|
2705
|
-
width: fit-content;
|
|
2698
|
+
cursor: pointer
|
|
2706
2699
|
}
|
|
2707
2700
|
|
|
2708
2701
|
.small-icon {
|
|
@@ -4258,7 +4251,7 @@ export class SfIEvents extends LitElement {
|
|
|
4258
4251
|
|
|
4259
4252
|
}
|
|
4260
4253
|
|
|
4261
|
-
renderCalendarGraphs = (showGraph: boolean, parametersTitle: string) => {
|
|
4254
|
+
renderCalendarGraphs = (showGraph: boolean, parametersTitle: string, showBackgroundButton: boolean) => {
|
|
4262
4255
|
|
|
4263
4256
|
//console.log('flowGraph', this.flowGraph);
|
|
4264
4257
|
|
|
@@ -4279,8 +4272,12 @@ export class SfIEvents extends LitElement {
|
|
|
4279
4272
|
}
|
|
4280
4273
|
html += '</div></div>'
|
|
4281
4274
|
}
|
|
4282
|
-
html += '<button id="button-refresh" part="button-duration-title" class="align-center d-flex justify-center"><h4 part="duration-title">' + parametersTitle + '</h4><span part="duration-title-icon" class="material-icons ml-10">refresh</span></
|
|
4283
|
-
|
|
4275
|
+
html += '<button id="button-refresh" part="button-duration-title" class="align-center d-flex justify-center"><h4 part="duration-title">' + parametersTitle + '</h4><span part="duration-title-icon" class="material-icons ml-10">refresh</span></div>';
|
|
4276
|
+
if(showBackgroundButton){
|
|
4277
|
+
html += '<div class="align-center d-flex flex-wrap align-center mb-10 w-100-m-0" part="last-update-title-container" id="button-background-process"><h6 part="last-update-title" class="align-center d-flex"><div class="lds-dual-ring1"></div> background processing</h6></div>'
|
|
4278
|
+
}else{
|
|
4279
|
+
html += '<div class="align-center d-flex flex-wrap align-center mb-10 w-100-m-0" part="last-update-title-container"><h6 part="last-update-title" class="align-center d-flex"><span class="material-symbols-outlined">update</span> Last Updated on ' + this.lastupdated + '</h6></div>';
|
|
4280
|
+
}
|
|
4284
4281
|
if(showGraph) {
|
|
4285
4282
|
html += '<div part="stream-event-chart-selection" class="mb-20">';
|
|
4286
4283
|
html += '<div part="td-head" class="mb-5">Select Chart</div>';
|
|
@@ -4848,7 +4845,7 @@ export class SfIEvents extends LitElement {
|
|
|
4848
4845
|
|
|
4849
4846
|
}
|
|
4850
4847
|
|
|
4851
|
-
renderEvents = (_firstDay: any, _endDay: any, iInit: number, iLast: number, showGraph: boolean, index: number, month: number, period: string, firstDate: any = null, parametersTitle: string) => {
|
|
4848
|
+
renderEvents = (_firstDay: any, _endDay: any, iInit: number, iLast: number, showGraph: boolean, index: number, month: number, period: string, firstDate: any = null, parametersTitle: string, showBackgroundButton: boolean) => {
|
|
4852
4849
|
var total = 0, notStarted = 0, approved = 0, pendingApproval = 0, rejected = 0, inTime = 0, pastDueDate = 0, lateExecuted = 0, lateApproved = 0, lateReported = 0, scheduled = 0, partiallyComplied = 0, notComplied = 0, complied = 0;
|
|
4853
4850
|
var html = '';
|
|
4854
4851
|
this.selectedItemIds = [];
|
|
@@ -4865,7 +4862,7 @@ export class SfIEvents extends LitElement {
|
|
|
4865
4862
|
this.clearSelectedGraphParam();
|
|
4866
4863
|
this.clearSelectedLegend();
|
|
4867
4864
|
|
|
4868
|
-
html += this.renderCalendarGraphs(showGraph, parametersTitle);
|
|
4865
|
+
html += this.renderCalendarGraphs(showGraph, parametersTitle, showBackgroundButton);
|
|
4869
4866
|
html += this.renderCalendarContainerDivStart(index)
|
|
4870
4867
|
html += this.renderCalendarEventSummary();
|
|
4871
4868
|
|
|
@@ -5517,6 +5514,7 @@ export class SfIEvents extends LitElement {
|
|
|
5517
5514
|
buttonClick.innerHTML = "Saving..."
|
|
5518
5515
|
const comments = (listReportingContainer.querySelector('#input-approver-comments') as HTMLInputElement).value;
|
|
5519
5516
|
const approved = (listReportingContainer.querySelector('#input-approve-yes') as HTMLInputElement).checked;
|
|
5517
|
+
let flagBulk = false;
|
|
5520
5518
|
if(this.selectedItemIds.length == 0){
|
|
5521
5519
|
await this.uploadReview(event.entityid, event.locationid, mmddyyyy, event["id"], comments, approved, event.isnotice != null ? "notices" : "events")
|
|
5522
5520
|
for( var p = 0 ; p < this.events[mmdd].length; p ++){
|
|
@@ -5578,6 +5576,7 @@ export class SfIEvents extends LitElement {
|
|
|
5578
5576
|
if(this.events[mmdd][p].id == eventId && this.events[mmdd][p].locationid == locationid && this.events[mmdd][p].entityid == entityid){
|
|
5579
5577
|
|
|
5580
5578
|
this.events[mmdd][p].isbulk = true
|
|
5579
|
+
flagBulk = true
|
|
5581
5580
|
}
|
|
5582
5581
|
}
|
|
5583
5582
|
}
|
|
@@ -5597,7 +5596,7 @@ export class SfIEvents extends LitElement {
|
|
|
5597
5596
|
await this.fetchBulkReportingData();
|
|
5598
5597
|
}
|
|
5599
5598
|
console.log('events', this.events);
|
|
5600
|
-
this.renderAppropriateStream(this.sdate,this.edate, true);
|
|
5599
|
+
this.renderAppropriateStream(this.sdate,this.edate, true, flagBulk);
|
|
5601
5600
|
}
|
|
5602
5601
|
}
|
|
5603
5602
|
|
|
@@ -5617,6 +5616,7 @@ export class SfIEvents extends LitElement {
|
|
|
5617
5616
|
}, 3000);
|
|
5618
5617
|
|
|
5619
5618
|
} else {
|
|
5619
|
+
let flagBulk = false;
|
|
5620
5620
|
if(this.selectedItemIds.length == 0){
|
|
5621
5621
|
await this.uploadAudit(event.entityid, event.locationid, mmddyyyy, event["id"], comments, approved, event.isnotice != null ? "notices" : "events")
|
|
5622
5622
|
for( var p = 0 ; p < this.events[mmdd].length; p ++){
|
|
@@ -5675,6 +5675,7 @@ export class SfIEvents extends LitElement {
|
|
|
5675
5675
|
if(this.events[mmdd][p].id == eventId && this.events[mmdd][p].locationid == locationId && this.events[mmdd][p].entityid == entityId){
|
|
5676
5676
|
|
|
5677
5677
|
this.events[mmdd][p].isbulk = true
|
|
5678
|
+
flagBulk = true;
|
|
5678
5679
|
}
|
|
5679
5680
|
}
|
|
5680
5681
|
}
|
|
@@ -5691,7 +5692,7 @@ export class SfIEvents extends LitElement {
|
|
|
5691
5692
|
if(this.selectedItemIds.length > 0) {
|
|
5692
5693
|
await this.fetchBulkReportingData();
|
|
5693
5694
|
}
|
|
5694
|
-
this.renderAppropriateStream(this.sdate,this.edate,true);
|
|
5695
|
+
this.renderAppropriateStream(this.sdate,this.edate,true, flagBulk);
|
|
5695
5696
|
// if(currentColumnButton != null) {
|
|
5696
5697
|
// currentColumnButton.click();
|
|
5697
5698
|
// }
|
|
@@ -5777,6 +5778,7 @@ export class SfIEvents extends LitElement {
|
|
|
5777
5778
|
}, 3000);
|
|
5778
5779
|
|
|
5779
5780
|
} else {
|
|
5781
|
+
let flagBulk = false;
|
|
5780
5782
|
if(this.selectedItemIds.length == 0){
|
|
5781
5783
|
|
|
5782
5784
|
await this.uploadReport(event.entityid, event.locationid, mmddyyyy, event["id"], reportercomments, reporterdoc, docs, event, reportformatvalues, reportformatschema, event.isnotice != null ? "notices" : "events")
|
|
@@ -5889,7 +5891,7 @@ export class SfIEvents extends LitElement {
|
|
|
5889
5891
|
let mmdd = mmddyyyy.split('/')[0] + '/' + mmddyyyy.split('/')[1]
|
|
5890
5892
|
for( var p = 0 ; p < this.events[mmdd].length; p ++){
|
|
5891
5893
|
if(this.events[mmdd][p].id == eventId && this.events[mmdd][p].locationid == locationId && this.events[mmdd][p].entityid == entityId){
|
|
5892
|
-
|
|
5894
|
+
flagBulk = true;
|
|
5893
5895
|
this.events[mmdd][p].isbulk = true
|
|
5894
5896
|
}
|
|
5895
5897
|
}
|
|
@@ -5908,7 +5910,7 @@ export class SfIEvents extends LitElement {
|
|
|
5908
5910
|
if(this.selectedItemIds.length > 0) {
|
|
5909
5911
|
await this.fetchBulkReportingData();
|
|
5910
5912
|
}
|
|
5911
|
-
this.renderAppropriateStream(this.sdate,this.edate,true)
|
|
5913
|
+
this.renderAppropriateStream(this.sdate,this.edate,true, flagBulk)
|
|
5912
5914
|
// if(currentColumnButton != null) {
|
|
5913
5915
|
// currentColumnButton.click();
|
|
5914
5916
|
// }
|
|
@@ -6050,7 +6052,7 @@ export class SfIEvents extends LitElement {
|
|
|
6050
6052
|
})
|
|
6051
6053
|
}
|
|
6052
6054
|
}
|
|
6053
|
-
renderStreamEvents = (index: number, month: number, year: number, showGraph: boolean = true) => {
|
|
6055
|
+
renderStreamEvents = (index: number, month: number, year: number, showGraph: boolean = true, showBackgroundButton: boolean = false) => {
|
|
6054
6056
|
|
|
6055
6057
|
//console.log('flowgraph renderStreamEvents', this.flowGraph);
|
|
6056
6058
|
|
|
@@ -6060,11 +6062,11 @@ export class SfIEvents extends LitElement {
|
|
|
6060
6062
|
endDay?.setDate(endDay.getDate() + lastDay + 1);
|
|
6061
6063
|
var period = ("0" + (month+1)).slice(-2) + "/" + ("0" + 1).slice(-2) + '/' + new Date().getFullYear() + ' - ' + ("0" + (month+1)).slice(-2) + "/" + ("0" + lastDay).slice(-2) + '/' + new Date().getFullYear()
|
|
6062
6064
|
|
|
6063
|
-
return this.renderEvents(firstDay, endDay, 1, lastDay, showGraph, index, month, period, null, this.monthNames[month] + " " + year);
|
|
6065
|
+
return this.renderEvents(firstDay, endDay, 1, lastDay, showGraph, index, month, period, null, this.monthNames[month] + " " + year, showBackgroundButton);
|
|
6064
6066
|
|
|
6065
6067
|
}
|
|
6066
6068
|
|
|
6067
|
-
renderThisEvents = (index: number, startDate: Date, showGraph: boolean = true) => {
|
|
6069
|
+
renderThisEvents = (index: number, startDate: Date, showGraph: boolean = true, showBackgroundButton: boolean = false) => {
|
|
6068
6070
|
|
|
6069
6071
|
var firstDate = new Date();
|
|
6070
6072
|
var count = 7;
|
|
@@ -6094,11 +6096,11 @@ export class SfIEvents extends LitElement {
|
|
|
6094
6096
|
|
|
6095
6097
|
var period = ("0" + (firstDate.getMonth()+1)).slice(-2) + "/" + ("0" + 1).slice(-2) + '/' + firstDate.getFullYear() + ' - ' + ("0" + (firstDate.getMonth()+1)).slice(-2) + "/" + ("0" + count).slice(-2) + '/' + firstDate.getFullYear()
|
|
6096
6098
|
|
|
6097
|
-
return this.renderEvents(firstDay, endDay, 1, lastDay, showGraph, index, (firstDate.getMonth()), period, null, "This " + (index === 0 ? "Week" : "Month"));
|
|
6099
|
+
return this.renderEvents(firstDay, endDay, 1, lastDay, showGraph, index, (firstDate.getMonth()), period, null, "This " + (index === 0 ? "Week" : "Month"), showBackgroundButton);
|
|
6098
6100
|
|
|
6099
6101
|
}
|
|
6100
6102
|
|
|
6101
|
-
renderRangeEvents = (firstDate: Date, count: number, eventsContainer: HTMLDivElement) => {
|
|
6103
|
+
renderRangeEvents = (firstDate: Date, count: number, eventsContainer: HTMLDivElement, showBackgroundButton: boolean = false) => {
|
|
6102
6104
|
|
|
6103
6105
|
|
|
6104
6106
|
var lastDate = new Date(firstDate.getTime());
|
|
@@ -6113,7 +6115,7 @@ export class SfIEvents extends LitElement {
|
|
|
6113
6115
|
|
|
6114
6116
|
//console.log('rangeperiod', period)
|
|
6115
6117
|
|
|
6116
|
-
var html = this.renderEvents(firstDay, endDay, 1, lastDay, true, 0, (firstDate.getMonth()), period, firstDate,"From " + firstDay.toLocaleDateString('en-IN') + " To " + endDay.toLocaleDateString('en-IN'));
|
|
6118
|
+
var html = this.renderEvents(firstDay, endDay, 1, lastDay, true, 0, (firstDate.getMonth()), period, firstDate,"From " + firstDay.toLocaleDateString('en-IN') + " To " + endDay.toLocaleDateString('en-IN'), showBackgroundButton);
|
|
6117
6119
|
|
|
6118
6120
|
eventsContainer.querySelector('.calendar-right-data')!.innerHTML = html;
|
|
6119
6121
|
if(eventsContainer.innerHTML.indexOf('button-select-all') < 0){
|
|
@@ -6121,6 +6123,18 @@ export class SfIEvents extends LitElement {
|
|
|
6121
6123
|
}
|
|
6122
6124
|
this.renderButtonRefresh(eventsContainer);
|
|
6123
6125
|
this.attachTimelineFilterHandlers(eventsContainer);
|
|
6126
|
+
let backgroundProcessButton = eventsContainer.querySelector('#button-background-process') as HTMLButtonElement
|
|
6127
|
+
if(showBackgroundButton){
|
|
6128
|
+
backgroundProcessButton.style.display = showBackgroundButton ? 'flex' : 'none'
|
|
6129
|
+
console.log('backgroundprocessbutton', backgroundProcessButton.style.display);
|
|
6130
|
+
if(showBackgroundButton){
|
|
6131
|
+
backgroundProcessButton.addEventListener('click',() => {
|
|
6132
|
+
console.log('bulk-progress clicked')
|
|
6133
|
+
let bulkLoader = (this._SfIEventsC as HTMLDivElement).querySelector('.bulk-loader') as HTMLDivElement
|
|
6134
|
+
bulkLoader.scrollIntoView();
|
|
6135
|
+
})
|
|
6136
|
+
}
|
|
6137
|
+
}
|
|
6124
6138
|
const filterButton = eventsContainer.querySelector('#filter-button') as HTMLButtonElement
|
|
6125
6139
|
filterButton?.addEventListener('click',() => {
|
|
6126
6140
|
const filterList = eventsContainer.querySelector('#filter-list-container') as HTMLDivElement
|
|
@@ -9844,7 +9858,7 @@ export class SfIEvents extends LitElement {
|
|
|
9844
9858
|
((this._SfCustomContainer as HTMLDivElement).querySelector('#button-year-to-date') as HTMLButtonElement).click();
|
|
9845
9859
|
}
|
|
9846
9860
|
|
|
9847
|
-
renderThis = (index: number = 1, showGraph: boolean = true) => {
|
|
9861
|
+
renderThis = (index: number = 1, showGraph: boolean = true, showBackgroundButton: boolean) => {
|
|
9848
9862
|
|
|
9849
9863
|
this.clearGraphData();
|
|
9850
9864
|
this.clearSelectedGraphParam();
|
|
@@ -9900,7 +9914,7 @@ export class SfIEvents extends LitElement {
|
|
|
9900
9914
|
|
|
9901
9915
|
// var startDate = new Date(this.calendarStartMM + '/' + this.calendarStartDD + '/' + this.calendarStartYYYY);
|
|
9902
9916
|
var startDate = new Date();
|
|
9903
|
-
html += this.renderThisEvents(index, startDate, showGraph);
|
|
9917
|
+
html += this.renderThisEvents(index, startDate, showGraph, showBackgroundButton);
|
|
9904
9918
|
startDate.setDate(startDate.getDate() + 1);
|
|
9905
9919
|
|
|
9906
9920
|
html += '</div>';
|
|
@@ -9909,6 +9923,18 @@ export class SfIEvents extends LitElement {
|
|
|
9909
9923
|
|
|
9910
9924
|
(this._SfThisContainer as HTMLDivElement).innerHTML = html;
|
|
9911
9925
|
this.renderButtonRefresh((this._SfThisContainer as HTMLDivElement));
|
|
9926
|
+
let backgroundProcessButton = (this._SfThisContainer as HTMLDivElement).querySelector('#button-background-process') as HTMLButtonElement
|
|
9927
|
+
if(backgroundProcessButton != null){
|
|
9928
|
+
backgroundProcessButton.style.display = showBackgroundButton ? 'flex' : 'none'
|
|
9929
|
+
console.log('backgroundprocessbutton', backgroundProcessButton.style.display);
|
|
9930
|
+
if(showBackgroundButton){
|
|
9931
|
+
backgroundProcessButton.addEventListener('click',() => {
|
|
9932
|
+
console.log('bulk-progress clicked')
|
|
9933
|
+
let bulkLoader = (this._SfIEventsC as HTMLDivElement).querySelector('.bulk-loader') as HTMLDivElement
|
|
9934
|
+
bulkLoader.scrollIntoView();
|
|
9935
|
+
})
|
|
9936
|
+
}
|
|
9937
|
+
}
|
|
9912
9938
|
const filterButton = (this._SfThisContainer as HTMLDivElement).querySelector('#filter-button') as HTMLButtonElement
|
|
9913
9939
|
filterButton?.addEventListener('click',() => {
|
|
9914
9940
|
const filterList = (this._SfThisContainer as HTMLDivElement).querySelector('#filter-list-container') as HTMLDivElement
|
|
@@ -9924,7 +9950,7 @@ export class SfIEvents extends LitElement {
|
|
|
9924
9950
|
await this.renderWithFeatures(dateResult.startDate, dateResult.endDate);
|
|
9925
9951
|
}
|
|
9926
9952
|
this.flowGraph = this.FLOW_GRAPH_COMPLETENESS;
|
|
9927
|
-
this.renderStream(index);
|
|
9953
|
+
this.renderStream(index, showGraph, showBackgroundButton);
|
|
9928
9954
|
})
|
|
9929
9955
|
// const selectFeatureAll = filterList.querySelector('.input-select-feature-all') as HTMLInputElement
|
|
9930
9956
|
// selectFeatureAll.addEventListener('click',async(ev: any) => {
|
|
@@ -9999,7 +10025,7 @@ export class SfIEvents extends LitElement {
|
|
|
9999
10025
|
radioCompleteness?.addEventListener('click', () => {
|
|
10000
10026
|
|
|
10001
10027
|
this.flowGraph = this.FLOW_GRAPH_COMPLETENESS;
|
|
10002
|
-
this.renderThis(index);
|
|
10028
|
+
this.renderThis(index, showGraph, showBackgroundButton);
|
|
10003
10029
|
this.renderCompletenessGraph((this._SfThisContainer as HTMLDivElement));
|
|
10004
10030
|
|
|
10005
10031
|
});
|
|
@@ -10008,7 +10034,7 @@ export class SfIEvents extends LitElement {
|
|
|
10008
10034
|
radioTimeliness?.addEventListener('click', () => {
|
|
10009
10035
|
|
|
10010
10036
|
this.flowGraph = this.FLOW_GRAPH_TIMELINESS;
|
|
10011
|
-
this.renderThis(index);
|
|
10037
|
+
this.renderThis(index, showGraph, showBackgroundButton);
|
|
10012
10038
|
this.renderTimelinessGraph((this._SfThisContainer as HTMLDivElement))
|
|
10013
10039
|
|
|
10014
10040
|
});
|
|
@@ -10017,7 +10043,7 @@ export class SfIEvents extends LitElement {
|
|
|
10017
10043
|
radioCompliance?.addEventListener('click', () => {
|
|
10018
10044
|
|
|
10019
10045
|
this.flowGraph = this.FLOW_GRAPH_COMPLIANCE;
|
|
10020
|
-
this.renderThis(index);
|
|
10046
|
+
this.renderThis(index, showGraph, showBackgroundButton);
|
|
10021
10047
|
this.renderComplianceGraph((this._SfThisContainer as HTMLDivElement))
|
|
10022
10048
|
|
|
10023
10049
|
});
|
|
@@ -10035,7 +10061,7 @@ export class SfIEvents extends LitElement {
|
|
|
10035
10061
|
radioRisk?.addEventListener('click', () => {
|
|
10036
10062
|
|
|
10037
10063
|
this.flowGraph = this.FLOW_GRAPH_RISKAREAS;
|
|
10038
|
-
this.renderThis(index);
|
|
10064
|
+
this.renderThis(index, showGraph, showBackgroundButton);
|
|
10039
10065
|
this.renderRiskGraph((this._SfThisContainer as HTMLDivElement))
|
|
10040
10066
|
|
|
10041
10067
|
});
|
|
@@ -10045,7 +10071,7 @@ export class SfIEvents extends LitElement {
|
|
|
10045
10071
|
radioFunction?.addEventListener('click', () => {
|
|
10046
10072
|
|
|
10047
10073
|
this.flowGraph = this.FLOW_GRAPH_FUNCTION;
|
|
10048
|
-
this.renderThis(index);
|
|
10074
|
+
this.renderThis(index, showGraph, showBackgroundButton);
|
|
10049
10075
|
this.renderFunctionGraph((this._SfThisContainer as HTMLDivElement))
|
|
10050
10076
|
|
|
10051
10077
|
});
|
|
@@ -10054,7 +10080,7 @@ export class SfIEvents extends LitElement {
|
|
|
10054
10080
|
radioRiskSeverity?.addEventListener('click', () => {
|
|
10055
10081
|
|
|
10056
10082
|
this.flowGraph = this.FLOW_GRAPH_RISKSEVERITY;
|
|
10057
|
-
this.renderThis(index);
|
|
10083
|
+
this.renderThis(index, showGraph, showBackgroundButton);
|
|
10058
10084
|
this.renderRiskSeverityGraph((this._SfThisContainer as HTMLDivElement))
|
|
10059
10085
|
|
|
10060
10086
|
});
|
|
@@ -10063,7 +10089,7 @@ export class SfIEvents extends LitElement {
|
|
|
10063
10089
|
radioObligationType?.addEventListener('click', () => {
|
|
10064
10090
|
|
|
10065
10091
|
this.flowGraph = this.FLOW_GRAPH_OBLIGATIONTYPE;
|
|
10066
|
-
this.renderThis(index);
|
|
10092
|
+
this.renderThis(index, showGraph, showBackgroundButton);
|
|
10067
10093
|
this.renderObligationTypeGraph((this._SfThisContainer as HTMLDivElement))
|
|
10068
10094
|
|
|
10069
10095
|
});
|
|
@@ -10072,7 +10098,7 @@ export class SfIEvents extends LitElement {
|
|
|
10072
10098
|
radioJurisdiction?.addEventListener('click', () => {
|
|
10073
10099
|
|
|
10074
10100
|
this.flowGraph = this.FLOW_GRAPH_JURISDICTION;
|
|
10075
|
-
this.renderThis(index);
|
|
10101
|
+
this.renderThis(index, showGraph, showBackgroundButton);
|
|
10076
10102
|
this.renderJurisdictionGraph((this._SfThisContainer as HTMLDivElement))
|
|
10077
10103
|
|
|
10078
10104
|
});
|
|
@@ -10081,7 +10107,7 @@ export class SfIEvents extends LitElement {
|
|
|
10081
10107
|
radioFrequency?.addEventListener('click', () => {
|
|
10082
10108
|
|
|
10083
10109
|
this.flowGraph = this.FLOW_GRAPH_FREQUENCY;
|
|
10084
|
-
this.renderThis(index);
|
|
10110
|
+
this.renderThis(index, showGraph, showBackgroundButton);
|
|
10085
10111
|
this.renderFrequencyGraph((this._SfThisContainer as HTMLDivElement))
|
|
10086
10112
|
|
|
10087
10113
|
});
|
|
@@ -10090,7 +10116,7 @@ export class SfIEvents extends LitElement {
|
|
|
10090
10116
|
radioSubcategory?.addEventListener('click', () => {
|
|
10091
10117
|
|
|
10092
10118
|
this.flowGraph = this.FLOW_GRAPH_SUBCATEGORY;
|
|
10093
|
-
this.renderThis(index);
|
|
10119
|
+
this.renderThis(index, showGraph, showBackgroundButton);
|
|
10094
10120
|
this.renderSubcategoryGraph((this._SfThisContainer as HTMLDivElement))
|
|
10095
10121
|
|
|
10096
10122
|
});
|
|
@@ -10099,7 +10125,7 @@ export class SfIEvents extends LitElement {
|
|
|
10099
10125
|
radioLocation?.addEventListener('click', () => {
|
|
10100
10126
|
|
|
10101
10127
|
this.flowGraph = this.FLOW_GRAPH_LOCATION;
|
|
10102
|
-
this.renderThis(index);
|
|
10128
|
+
this.renderThis(index, showGraph, showBackgroundButton);
|
|
10103
10129
|
this.renderLocationGraph((this._SfThisContainer as HTMLDivElement))
|
|
10104
10130
|
|
|
10105
10131
|
});
|
|
@@ -10123,7 +10149,7 @@ export class SfIEvents extends LitElement {
|
|
|
10123
10149
|
this.flowGraph = this.FLOW_GRAPH_COMPLETENESS;
|
|
10124
10150
|
this.currentColumnIndex = target + "";
|
|
10125
10151
|
await this.fetchAndYearlyRenderUserCalendar_2(dateResult.startDate, dateResult.endDate);
|
|
10126
|
-
this.renderThis(target);
|
|
10152
|
+
this.renderThis(target, showGraph, showBackgroundButton);
|
|
10127
10153
|
});
|
|
10128
10154
|
|
|
10129
10155
|
(this._SfThisContainer as HTMLDivElement).querySelector('#stream-month-' + i + '-mobile')?.addEventListener('click', async (ev: any)=> {
|
|
@@ -10133,7 +10159,7 @@ export class SfIEvents extends LitElement {
|
|
|
10133
10159
|
this.currentColumnIndex = target + "";
|
|
10134
10160
|
const dateResult = this.calculateStartAndEndDateOfThis(target);
|
|
10135
10161
|
await this.fetchAndYearlyRenderUserCalendar_2(dateResult.startDate, dateResult.endDate);
|
|
10136
|
-
this.renderThis(target);
|
|
10162
|
+
this.renderThis(target, showGraph, showBackgroundButton);
|
|
10137
10163
|
})
|
|
10138
10164
|
}
|
|
10139
10165
|
const buttonRefresh = (this._SfThisContainer as HTMLDivElement).querySelector('#button-refresh') as HTMLButtonElement
|
|
@@ -10143,7 +10169,7 @@ export class SfIEvents extends LitElement {
|
|
|
10143
10169
|
const dateResult = this.calculateStartAndEndDateOfThis(index);
|
|
10144
10170
|
// await this.fetchAndYearlyRenderUserCalendar_2(dateResult.startDate, dateResult.endDate);
|
|
10145
10171
|
await this.renderWithFeatures(dateResult.startDate, dateResult.endDate);
|
|
10146
|
-
this.renderThis(index);
|
|
10172
|
+
this.renderThis(index, showGraph, showBackgroundButton);
|
|
10147
10173
|
})
|
|
10148
10174
|
this.attachListReportingListeners(this._SfThisContainer as HTMLDivElement);
|
|
10149
10175
|
const buttonArr = (this._SfThisContainer as HTMLDivElement).querySelectorAll('.button-expand') as NodeListOf<HTMLButtonElement>;
|
|
@@ -10353,7 +10379,7 @@ export class SfIEvents extends LitElement {
|
|
|
10353
10379
|
})
|
|
10354
10380
|
}
|
|
10355
10381
|
|
|
10356
|
-
renderStream = (index: number = 0, showGraph: boolean = true) => {
|
|
10382
|
+
renderStream = (index: number = 0, showGraph: boolean = true, showBackgroundButton: boolean) => {
|
|
10357
10383
|
//console.log('flowgraph renderStream', this.flowGraph);
|
|
10358
10384
|
|
|
10359
10385
|
this.streamIndex = index;
|
|
@@ -10412,7 +10438,7 @@ export class SfIEvents extends LitElement {
|
|
|
10412
10438
|
for(i = 0; i < 12; i++) {
|
|
10413
10439
|
if(i === index) {
|
|
10414
10440
|
//console.log(i, index)
|
|
10415
|
-
html += this.renderStreamEvents(i, startDate.getMonth(), startDate.getFullYear(), showGraph)
|
|
10441
|
+
html += this.renderStreamEvents(i, startDate.getMonth(), startDate.getFullYear(), showGraph, showBackgroundButton)
|
|
10416
10442
|
}
|
|
10417
10443
|
startDate.setMonth(startDate.getMonth() + 1);
|
|
10418
10444
|
}
|
|
@@ -10440,7 +10466,7 @@ export class SfIEvents extends LitElement {
|
|
|
10440
10466
|
await this.renderWithFeatures(dateResult.startDate, dateResult.endDate,"","no",("0" + monthResult).slice(-2));
|
|
10441
10467
|
}
|
|
10442
10468
|
this.flowGraph = this.FLOW_GRAPH_COMPLETENESS;
|
|
10443
|
-
this.renderStream(index);
|
|
10469
|
+
this.renderStream(index, showGraph, showBackgroundButton);
|
|
10444
10470
|
})
|
|
10445
10471
|
// const selectFeatureAll = filterList.querySelector('.input-select-feature-all') as HTMLInputElement
|
|
10446
10472
|
// selectFeatureAll?.addEventListener('click',async(ev: any) => {
|
|
@@ -10516,7 +10542,7 @@ export class SfIEvents extends LitElement {
|
|
|
10516
10542
|
radioCompleteness?.addEventListener('click', () => {
|
|
10517
10543
|
|
|
10518
10544
|
this.flowGraph = this.FLOW_GRAPH_COMPLETENESS;
|
|
10519
|
-
this.renderStream(index);
|
|
10545
|
+
this.renderStream(index, showGraph, showBackgroundButton);
|
|
10520
10546
|
this.renderCompletenessGraph((this._SfStreamContainer as HTMLDivElement));
|
|
10521
10547
|
|
|
10522
10548
|
});
|
|
@@ -10525,7 +10551,7 @@ export class SfIEvents extends LitElement {
|
|
|
10525
10551
|
radioTimeliness?.addEventListener('click', () => {
|
|
10526
10552
|
|
|
10527
10553
|
this.flowGraph = this.FLOW_GRAPH_TIMELINESS;
|
|
10528
|
-
this.renderStream(index);
|
|
10554
|
+
this.renderStream(index, showGraph, showBackgroundButton);
|
|
10529
10555
|
this.renderTimelinessGraph((this._SfStreamContainer as HTMLDivElement))
|
|
10530
10556
|
|
|
10531
10557
|
});
|
|
@@ -10534,7 +10560,7 @@ export class SfIEvents extends LitElement {
|
|
|
10534
10560
|
radioCompliance?.addEventListener('click', () => {
|
|
10535
10561
|
|
|
10536
10562
|
this.flowGraph = this.FLOW_GRAPH_COMPLIANCE;
|
|
10537
|
-
this.renderStream(index);
|
|
10563
|
+
this.renderStream(index, showGraph, showBackgroundButton);
|
|
10538
10564
|
this.renderComplianceGraph((this._SfStreamContainer as HTMLDivElement))
|
|
10539
10565
|
|
|
10540
10566
|
});
|
|
@@ -10543,7 +10569,7 @@ export class SfIEvents extends LitElement {
|
|
|
10543
10569
|
radioRisk?.addEventListener('click', () => {
|
|
10544
10570
|
|
|
10545
10571
|
this.flowGraph = this.FLOW_GRAPH_RISKAREAS;
|
|
10546
|
-
this.renderStream(index);
|
|
10572
|
+
this.renderStream(index, showGraph, showBackgroundButton);
|
|
10547
10573
|
this.renderRiskGraph((this._SfStreamContainer as HTMLDivElement))
|
|
10548
10574
|
|
|
10549
10575
|
});
|
|
@@ -10552,7 +10578,7 @@ export class SfIEvents extends LitElement {
|
|
|
10552
10578
|
radioRiskSeverity?.addEventListener('click', () => {
|
|
10553
10579
|
|
|
10554
10580
|
this.flowGraph = this.FLOW_GRAPH_RISKSEVERITY;
|
|
10555
|
-
this.renderStream(index);
|
|
10581
|
+
this.renderStream(index, showGraph, showBackgroundButton);
|
|
10556
10582
|
this.renderRiskSeverityGraph((this._SfStreamContainer as HTMLDivElement))
|
|
10557
10583
|
|
|
10558
10584
|
});
|
|
@@ -10561,7 +10587,7 @@ export class SfIEvents extends LitElement {
|
|
|
10561
10587
|
radioFunction?.addEventListener('click', () => {
|
|
10562
10588
|
|
|
10563
10589
|
this.flowGraph = this.FLOW_GRAPH_FUNCTION;
|
|
10564
|
-
this.renderStream(index);
|
|
10590
|
+
this.renderStream(index, showGraph, showBackgroundButton);
|
|
10565
10591
|
this.renderFunctionGraph((this._SfStreamContainer as HTMLDivElement))
|
|
10566
10592
|
|
|
10567
10593
|
});
|
|
@@ -10570,7 +10596,7 @@ export class SfIEvents extends LitElement {
|
|
|
10570
10596
|
radioObligationType?.addEventListener('click', () => {
|
|
10571
10597
|
|
|
10572
10598
|
this.flowGraph = this.FLOW_GRAPH_OBLIGATIONTYPE;
|
|
10573
|
-
this.renderStream(index);
|
|
10599
|
+
this.renderStream(index, showGraph, showBackgroundButton);
|
|
10574
10600
|
this.renderObligationTypeGraph((this._SfStreamContainer as HTMLDivElement))
|
|
10575
10601
|
|
|
10576
10602
|
});
|
|
@@ -10579,7 +10605,7 @@ export class SfIEvents extends LitElement {
|
|
|
10579
10605
|
radioJurisdiction?.addEventListener('click', () => {
|
|
10580
10606
|
|
|
10581
10607
|
this.flowGraph = this.FLOW_GRAPH_JURISDICTION;
|
|
10582
|
-
this.renderStream(index);
|
|
10608
|
+
this.renderStream(index, showGraph, showBackgroundButton);
|
|
10583
10609
|
this.renderJurisdictionGraph((this._SfStreamContainer as HTMLDivElement))
|
|
10584
10610
|
|
|
10585
10611
|
});
|
|
@@ -10588,7 +10614,7 @@ export class SfIEvents extends LitElement {
|
|
|
10588
10614
|
radioFrequency?.addEventListener('click', () => {
|
|
10589
10615
|
|
|
10590
10616
|
this.flowGraph = this.FLOW_GRAPH_FREQUENCY;
|
|
10591
|
-
this.renderStream(index);
|
|
10617
|
+
this.renderStream(index, showGraph, showBackgroundButton);
|
|
10592
10618
|
this.renderFrequencyGraph((this._SfStreamContainer as HTMLDivElement))
|
|
10593
10619
|
|
|
10594
10620
|
});
|
|
@@ -10597,7 +10623,7 @@ export class SfIEvents extends LitElement {
|
|
|
10597
10623
|
radioSubcategory?.addEventListener('click', () => {
|
|
10598
10624
|
|
|
10599
10625
|
this.flowGraph = this.FLOW_GRAPH_SUBCATEGORY;
|
|
10600
|
-
this.renderStream(index);
|
|
10626
|
+
this.renderStream(index, showGraph, showBackgroundButton);
|
|
10601
10627
|
this.renderSubcategoryGraph((this._SfStreamContainer as HTMLDivElement))
|
|
10602
10628
|
|
|
10603
10629
|
});
|
|
@@ -10606,11 +10632,22 @@ export class SfIEvents extends LitElement {
|
|
|
10606
10632
|
radioLocation?.addEventListener('click', () => {
|
|
10607
10633
|
|
|
10608
10634
|
this.flowGraph = this.FLOW_GRAPH_LOCATION;
|
|
10609
|
-
this.renderStream(index);
|
|
10635
|
+
this.renderStream(index, showGraph, showBackgroundButton);
|
|
10610
10636
|
this.renderLocationGraph((this._SfStreamContainer as HTMLDivElement))
|
|
10611
10637
|
|
|
10612
10638
|
});
|
|
10613
|
-
|
|
10639
|
+
let backgroundProcessButton = (this._SfStreamContainer as HTMLDivElement).querySelector('#button-background-process') as HTMLButtonElement
|
|
10640
|
+
if(showBackgroundButton){
|
|
10641
|
+
backgroundProcessButton.style.display = showBackgroundButton ? 'flex' : 'none'
|
|
10642
|
+
console.log('backgroundprocessbutton', backgroundProcessButton.style.display);
|
|
10643
|
+
if(showBackgroundButton){
|
|
10644
|
+
backgroundProcessButton.addEventListener('click',() => {
|
|
10645
|
+
console.log('bulk-progress clicked')
|
|
10646
|
+
let bulkLoader = (this._SfIEventsC as HTMLDivElement).querySelector('.bulk-loader') as HTMLDivElement
|
|
10647
|
+
bulkLoader.scrollIntoView();
|
|
10648
|
+
})
|
|
10649
|
+
}
|
|
10650
|
+
}
|
|
10614
10651
|
|
|
10615
10652
|
// const buttonStatusMore = (this._SfStreamContainer as HTMLDivElement).querySelector('#button-status-more');
|
|
10616
10653
|
// buttonStatusMore?.addEventListener('click', () => {
|
|
@@ -10637,7 +10674,7 @@ export class SfIEvents extends LitElement {
|
|
|
10637
10674
|
// await this.fetchAndYearlyRenderUserCalendar_2(dateResult.startDate, dateResult.endDate,"","yes",("0" + monthResult).slice(-2));
|
|
10638
10675
|
}
|
|
10639
10676
|
this.flowGraph = this.FLOW_GRAPH_COMPLETENESS;
|
|
10640
|
-
this.renderStream(target);
|
|
10677
|
+
this.renderStream(target, showGraph, showBackgroundButton);
|
|
10641
10678
|
|
|
10642
10679
|
});
|
|
10643
10680
|
|
|
@@ -10652,7 +10689,7 @@ export class SfIEvents extends LitElement {
|
|
|
10652
10689
|
}
|
|
10653
10690
|
this.flowGraph = this.FLOW_GRAPH_COMPLETENESS;
|
|
10654
10691
|
this.currentColumnIndex = target + "";
|
|
10655
|
-
this.renderStream(target);
|
|
10692
|
+
this.renderStream(target, showGraph, showBackgroundButton);
|
|
10656
10693
|
|
|
10657
10694
|
})
|
|
10658
10695
|
}
|
|
@@ -10668,7 +10705,7 @@ export class SfIEvents extends LitElement {
|
|
|
10668
10705
|
// await this.fetchAndYearlyRenderUserCalendar_2(dateResult.startDate, dateResult.endDate,"","yes",("0" + monthResult).slice(-2));
|
|
10669
10706
|
}
|
|
10670
10707
|
this.flowGraph = this.FLOW_GRAPH_COMPLETENESS;
|
|
10671
|
-
this.renderStream(index);
|
|
10708
|
+
this.renderStream(index, showGraph, showBackgroundButton);
|
|
10672
10709
|
})
|
|
10673
10710
|
this.attachListReportingListeners(this._SfStreamContainer as HTMLDivElement);
|
|
10674
10711
|
const buttonArr = (this._SfStreamContainer as HTMLDivElement).querySelectorAll('.button-expand') as NodeListOf<HTMLButtonElement>;
|
|
@@ -11987,7 +12024,7 @@ export class SfIEvents extends LitElement {
|
|
|
11987
12024
|
((this._SfDetailContainer as HTMLDivElement).querySelector('#button-detail-close') as HTMLButtonElement)!.dispatchEvent(clickEvent);
|
|
11988
12025
|
|
|
11989
12026
|
// await this.uploadReview(entityId, locationId, mmddyyyy, event["id"], comments, approved)
|
|
11990
|
-
|
|
12027
|
+
let flagBulk = false;
|
|
11991
12028
|
if(this.selectedItemIds.length === 0) {
|
|
11992
12029
|
console.log('mmddyyyy', mmddyyyy)
|
|
11993
12030
|
await this.uploadReview(entityId, locationId, mmddyyyy, listEvent["id"], comments, approved, listEvent.isnotice != null ? "notices" : "events")
|
|
@@ -12048,6 +12085,7 @@ export class SfIEvents extends LitElement {
|
|
|
12048
12085
|
if(this.events[mmdd][p].id == eventId && this.events[mmdd][p].locationid == locationId && this.events[mmdd][p].entityid == entityId){
|
|
12049
12086
|
|
|
12050
12087
|
this.events[mmdd][p].isbulk = true
|
|
12088
|
+
flagBulk = true;
|
|
12051
12089
|
}
|
|
12052
12090
|
}
|
|
12053
12091
|
}
|
|
@@ -12067,7 +12105,7 @@ export class SfIEvents extends LitElement {
|
|
|
12067
12105
|
if(this.selectedItemIds.length > 0) {
|
|
12068
12106
|
await this.fetchBulkReportingData();
|
|
12069
12107
|
}
|
|
12070
|
-
this.renderAppropriateStream(this.sdate,this.edate, true);
|
|
12108
|
+
this.renderAppropriateStream(this.sdate,this.edate, true, flagBulk);
|
|
12071
12109
|
var clickEvent = new MouseEvent("click", {
|
|
12072
12110
|
"view": window,
|
|
12073
12111
|
"bubbles": true,
|
|
@@ -12097,7 +12135,7 @@ export class SfIEvents extends LitElement {
|
|
|
12097
12135
|
}, 3000);
|
|
12098
12136
|
|
|
12099
12137
|
} else {
|
|
12100
|
-
|
|
12138
|
+
let flagBulk = false;
|
|
12101
12139
|
if(this.selectedItemIds.length === 0) {
|
|
12102
12140
|
|
|
12103
12141
|
await this.uploadAudit(entityId, locationId, mmddyyyy, listEvent["id"], comments, approved, listEvent.isnotice != null ? "notices" : "events")
|
|
@@ -12155,6 +12193,7 @@ export class SfIEvents extends LitElement {
|
|
|
12155
12193
|
if(this.events[mmdd][p].id == eventId && this.events[mmdd][p].locationid == locationId && this.events[mmdd][p].entityid == entityId){
|
|
12156
12194
|
|
|
12157
12195
|
this.events[mmdd][p].isbulk = true
|
|
12196
|
+
flagBulk = true;
|
|
12158
12197
|
}
|
|
12159
12198
|
}
|
|
12160
12199
|
}
|
|
@@ -12181,7 +12220,7 @@ export class SfIEvents extends LitElement {
|
|
|
12181
12220
|
if(this.selectedItemIds.length > 0) {
|
|
12182
12221
|
await this.fetchBulkReportingData();
|
|
12183
12222
|
}
|
|
12184
|
-
this.renderAppropriateStream(this.sdate,this.edate,true);
|
|
12223
|
+
this.renderAppropriateStream(this.sdate,this.edate,true, flagBulk);
|
|
12185
12224
|
// if(currentColumnButton != null) {
|
|
12186
12225
|
// currentColumnButton.click();
|
|
12187
12226
|
// }
|
|
@@ -12276,7 +12315,7 @@ export class SfIEvents extends LitElement {
|
|
|
12276
12315
|
});
|
|
12277
12316
|
|
|
12278
12317
|
((this._SfDetailContainer as HTMLDivElement).querySelector('#button-detail-close') as HTMLButtonElement)!.dispatchEvent(clickEvent);
|
|
12279
|
-
|
|
12318
|
+
let flagBulk = false;
|
|
12280
12319
|
if(this.selectedItemIds.length === 0) {
|
|
12281
12320
|
|
|
12282
12321
|
await this.uploadReport(entityId, locationId, mmddyyyy, listEvent["id"], reportercomments, reporterdoc, docs, event, reportformatvalues, reportformatschema, "notices")
|
|
@@ -12395,6 +12434,7 @@ export class SfIEvents extends LitElement {
|
|
|
12395
12434
|
if(this.events[mmdd][p].id == eventId && this.events[mmdd][p].locationid == locationId && this.events[mmdd][p].entityid == entityId){
|
|
12396
12435
|
|
|
12397
12436
|
this.events[mmdd][p].isbulk = true
|
|
12437
|
+
flagBulk = true;
|
|
12398
12438
|
}
|
|
12399
12439
|
}
|
|
12400
12440
|
}
|
|
@@ -12413,7 +12453,7 @@ export class SfIEvents extends LitElement {
|
|
|
12413
12453
|
if(this.selectedItemIds.length > 0) {
|
|
12414
12454
|
await this.fetchBulkReportingData();
|
|
12415
12455
|
}
|
|
12416
|
-
this.renderAppropriateStream(this.sdate,this.edate,true)
|
|
12456
|
+
this.renderAppropriateStream(this.sdate,this.edate,true, flagBulk)
|
|
12417
12457
|
// if(currentColumnButton != null) {
|
|
12418
12458
|
// currentColumnButton.click();
|
|
12419
12459
|
// }
|
|
@@ -13264,7 +13304,7 @@ export class SfIEvents extends LitElement {
|
|
|
13264
13304
|
((this._SfDetailContainer as HTMLDivElement).querySelector('#button-detail-close') as HTMLButtonElement)!.dispatchEvent(clickEvent);
|
|
13265
13305
|
|
|
13266
13306
|
// await this.uploadReview(entityId, locationId, mmddyyyy, event["id"], comments, approved)
|
|
13267
|
-
|
|
13307
|
+
let flagBulk = false;
|
|
13268
13308
|
if(this.selectedItemIds.length === 0) {
|
|
13269
13309
|
// console.log('mmddyyyy', mmddyyyy)
|
|
13270
13310
|
await this.uploadReview(entityId, locationId, mmddyyyy, event["id"], comments, approved, event.isnotice != null ? "notices" : "events")
|
|
@@ -13324,6 +13364,7 @@ export class SfIEvents extends LitElement {
|
|
|
13324
13364
|
if(this.events[mmdd][p].id == eventId && this.events[mmdd][p].locationid == locationId && this.events[mmdd][p].entityid == entityId){
|
|
13325
13365
|
|
|
13326
13366
|
this.events[mmdd][p].isbulk = true
|
|
13367
|
+
flagBulk = true;
|
|
13327
13368
|
}
|
|
13328
13369
|
}
|
|
13329
13370
|
}
|
|
@@ -13342,7 +13383,7 @@ export class SfIEvents extends LitElement {
|
|
|
13342
13383
|
if(this.selectedItemIds.length > 0) {
|
|
13343
13384
|
await this.fetchBulkReportingData();
|
|
13344
13385
|
}
|
|
13345
|
-
this.renderAppropriateStream(this.sdate,this.edate, true);
|
|
13386
|
+
this.renderAppropriateStream(this.sdate,this.edate, true, flagBulk);
|
|
13346
13387
|
var clickEvent = new MouseEvent("click", {
|
|
13347
13388
|
"view": window,
|
|
13348
13389
|
"bubbles": true,
|
|
@@ -13372,7 +13413,7 @@ export class SfIEvents extends LitElement {
|
|
|
13372
13413
|
}, 3000);
|
|
13373
13414
|
|
|
13374
13415
|
} else {
|
|
13375
|
-
|
|
13416
|
+
let flagBulk = false;
|
|
13376
13417
|
if(this.selectedItemIds.length === 0) {
|
|
13377
13418
|
|
|
13378
13419
|
await this.uploadAudit(entityId, locationId, mmddyyyy, event["id"], comments, approved, event.isnotice != null ? "notices" : "events")
|
|
@@ -13429,6 +13470,7 @@ export class SfIEvents extends LitElement {
|
|
|
13429
13470
|
if(this.events[mmdd][p].id == eventId && this.events[mmdd][p].locationid == locationId && this.events[mmdd][p].entityid == entityId){
|
|
13430
13471
|
|
|
13431
13472
|
this.events[mmdd][p].isbulk = true
|
|
13473
|
+
flagBulk = true;
|
|
13432
13474
|
}
|
|
13433
13475
|
}
|
|
13434
13476
|
}
|
|
@@ -13453,7 +13495,7 @@ export class SfIEvents extends LitElement {
|
|
|
13453
13495
|
if(this.selectedItemIds.length > 0) {
|
|
13454
13496
|
await this.fetchBulkReportingData();
|
|
13455
13497
|
}
|
|
13456
|
-
this.renderAppropriateStream(this.sdate,this.edate,true);
|
|
13498
|
+
this.renderAppropriateStream(this.sdate,this.edate,true, flagBulk);
|
|
13457
13499
|
// if(currentColumnButton != null) {
|
|
13458
13500
|
// currentColumnButton.click();
|
|
13459
13501
|
// }
|
|
@@ -13548,7 +13590,7 @@ export class SfIEvents extends LitElement {
|
|
|
13548
13590
|
});
|
|
13549
13591
|
|
|
13550
13592
|
((this._SfDetailContainer as HTMLDivElement).querySelector('#button-detail-close') as HTMLButtonElement)!.dispatchEvent(clickEvent);
|
|
13551
|
-
|
|
13593
|
+
let flagBulk = false;
|
|
13552
13594
|
if(this.selectedItemIds.length === 0) {
|
|
13553
13595
|
|
|
13554
13596
|
//console.log('makerscheckers', makercheckers, reportercomments);
|
|
@@ -13682,6 +13724,7 @@ export class SfIEvents extends LitElement {
|
|
|
13682
13724
|
if(this.events[mmdd][p].id == eventId && this.events[mmdd][p].locationid == locationId && this.events[mmdd][p].entityid == entityId){
|
|
13683
13725
|
|
|
13684
13726
|
this.events[mmdd][p].isbulk = true
|
|
13727
|
+
flagBulk = true;
|
|
13685
13728
|
}
|
|
13686
13729
|
}
|
|
13687
13730
|
}
|
|
@@ -13700,7 +13743,7 @@ export class SfIEvents extends LitElement {
|
|
|
13700
13743
|
if(this.selectedItemIds.length > 0) {
|
|
13701
13744
|
await this.fetchBulkReportingData();
|
|
13702
13745
|
}
|
|
13703
|
-
this.renderAppropriateStream(this.sdate,this.edate,true)
|
|
13746
|
+
this.renderAppropriateStream(this.sdate,this.edate,true, flagBulk)
|
|
13704
13747
|
// if(currentColumnButton != null) {
|
|
13705
13748
|
// currentColumnButton.click();
|
|
13706
13749
|
// }
|
|
@@ -13861,7 +13904,7 @@ export class SfIEvents extends LitElement {
|
|
|
13861
13904
|
//console.log('render stream', id);
|
|
13862
13905
|
this.enableStream();
|
|
13863
13906
|
this.renderTabs(this.TAB_STREAM);
|
|
13864
|
-
this.renderStream(parseInt(id));
|
|
13907
|
+
this.renderStream(parseInt(id),false, false);
|
|
13865
13908
|
|
|
13866
13909
|
})
|
|
13867
13910
|
|
|
@@ -18522,7 +18565,7 @@ export class SfIEvents extends LitElement {
|
|
|
18522
18565
|
|
|
18523
18566
|
this.fill = "solid";
|
|
18524
18567
|
if(this.getCurrentTab() == this.TAB_STREAM) {
|
|
18525
|
-
this.renderStream();
|
|
18568
|
+
this.renderStream(0, true, false);
|
|
18526
18569
|
}
|
|
18527
18570
|
|
|
18528
18571
|
});
|
|
@@ -18531,7 +18574,7 @@ export class SfIEvents extends LitElement {
|
|
|
18531
18574
|
|
|
18532
18575
|
this.fill = "pattern";
|
|
18533
18576
|
if(this.getCurrentTab() == this.TAB_STREAM) {
|
|
18534
|
-
this.renderStream();
|
|
18577
|
+
this.renderStream(0, true, false);
|
|
18535
18578
|
}
|
|
18536
18579
|
|
|
18537
18580
|
});
|
|
@@ -18596,7 +18639,7 @@ export class SfIEvents extends LitElement {
|
|
|
18596
18639
|
//console.log('canceled');
|
|
18597
18640
|
if(this.getCurrentTab() == this.TAB_STREAM) {
|
|
18598
18641
|
this.renderChartSettings(container, -1, -1, ctx);
|
|
18599
|
-
this.renderStream(this.streamIndex);
|
|
18642
|
+
this.renderStream(this.streamIndex, false, false);
|
|
18600
18643
|
}
|
|
18601
18644
|
// if(this.getCurrentTab() == this.TAB_UPCOMING) {
|
|
18602
18645
|
// this.renderChartSettings(container, -1, ctx);
|
|
@@ -18604,7 +18647,7 @@ export class SfIEvents extends LitElement {
|
|
|
18604
18647
|
// }
|
|
18605
18648
|
if(this.getCurrentTab() == this.TAB_THIS) {
|
|
18606
18649
|
this.renderChartSettings(container, -1, -1, ctx);
|
|
18607
|
-
this.renderThis(this.streamIndex);
|
|
18650
|
+
this.renderThis(this.streamIndex, false, false);
|
|
18608
18651
|
}
|
|
18609
18652
|
// if(this.getCurrentTab() == this.TAB_PAST) {
|
|
18610
18653
|
// this.renderChartSettings(container, -1, ctx);
|
|
@@ -20582,7 +20625,7 @@ export class SfIEvents extends LitElement {
|
|
|
20582
20625
|
await this.renderWithFeatures(dateResult.startDate, dateResult.endDate,"","yes",("0" + monthResult).slice(-2));
|
|
20583
20626
|
// await this.fetchAndYearlyRenderUserCalendar_2(dateResult.startDate, dateResult.endDate,"","yes",("0" + monthResult).slice(-2));
|
|
20584
20627
|
}
|
|
20585
|
-
this.renderStream(idx);
|
|
20628
|
+
this.renderStream(idx, true, false);
|
|
20586
20629
|
});
|
|
20587
20630
|
|
|
20588
20631
|
// (this._SfTabContainer as HTMLDivElement).querySelector('#calendar-tab-upcoming')?.addEventListener('click', async () => {
|
|
@@ -20612,7 +20655,7 @@ export class SfIEvents extends LitElement {
|
|
|
20612
20655
|
//console.log('dateresult', dateResult)
|
|
20613
20656
|
this.currentColumnIndex = 1 + ""
|
|
20614
20657
|
await this.fetchAndYearlyRenderUserCalendar_2(dateResult.startDate, dateResult.endDate,"","yes",("0" + monthResult).slice(-2));
|
|
20615
|
-
this.renderThis();
|
|
20658
|
+
this.renderThis(0, true, false);
|
|
20616
20659
|
});
|
|
20617
20660
|
|
|
20618
20661
|
// (this._SfTabContainer as HTMLDivElement).querySelector('#calendar-tab-past')?.addEventListener('click', async () => {
|
|
@@ -23505,17 +23548,17 @@ export class SfIEvents extends LitElement {
|
|
|
23505
23548
|
});
|
|
23506
23549
|
}
|
|
23507
23550
|
|
|
23508
|
-
renderAppropriateStream = (startDate: string, endDate: string, showGraph: boolean = false) => {
|
|
23551
|
+
renderAppropriateStream = (startDate: string, endDate: string, showGraph: boolean = false, showBackgroundButton: boolean = false) => {
|
|
23509
23552
|
if(startDate == "" && endDate == "") this.renderCalendar(); // yearly
|
|
23510
23553
|
|
|
23511
23554
|
if(this.selectedTab == this.TAB_STREAM) {
|
|
23512
|
-
this.renderStream(parseInt(this.currentColumnIndex), showGraph);
|
|
23555
|
+
this.renderStream(parseInt(this.currentColumnIndex), showGraph, showBackgroundButton);
|
|
23513
23556
|
}
|
|
23514
23557
|
// if(this.selectedTab == this.TAB_UPCOMING) {
|
|
23515
23558
|
// this.renderUpcoming(parseInt(this.currentColumnIndex), false);
|
|
23516
23559
|
// }
|
|
23517
23560
|
if(this.selectedTab == this.TAB_THIS) {
|
|
23518
|
-
this.renderThis(parseInt(this.currentColumnIndex), showGraph);
|
|
23561
|
+
this.renderThis(parseInt(this.currentColumnIndex), showGraph, showBackgroundButton);
|
|
23519
23562
|
}
|
|
23520
23563
|
// if(this.selectedTab == this.TAB_PAST) {
|
|
23521
23564
|
// this.renderPast(parseInt(this.currentColumnIndex), false);
|
|
@@ -23865,11 +23908,11 @@ export class SfIEvents extends LitElement {
|
|
|
23865
23908
|
this._SfLoader.innerHTML = '';
|
|
23866
23909
|
if(xhr.status == 200) {
|
|
23867
23910
|
|
|
23868
|
-
const
|
|
23869
|
-
console.log('bulk reports
|
|
23911
|
+
const jsonResponse = JSON.parse(xhr.responseText);
|
|
23912
|
+
console.log('bulk reports jsonResponse', jsonResponse);
|
|
23870
23913
|
let flagBulk = false;
|
|
23871
|
-
if(
|
|
23872
|
-
for(let sortid of Object.keys(
|
|
23914
|
+
if(jsonResponse.result == true){
|
|
23915
|
+
for(let sortid of Object.keys(jsonResponse.data)){
|
|
23873
23916
|
let sortidArr = sortid.split(';')
|
|
23874
23917
|
let mmddyyyy = sortidArr[0]
|
|
23875
23918
|
let entityid = sortidArr[1]
|
|
@@ -23887,19 +23930,20 @@ export class SfIEvents extends LitElement {
|
|
|
23887
23930
|
}
|
|
23888
23931
|
}
|
|
23889
23932
|
}
|
|
23890
|
-
let backgroundProcessButton = (this._SfIEventsC as HTMLDivElement).querySelector('#button-background-process') as HTMLButtonElement
|
|
23891
23933
|
|
|
23892
23934
|
if(flagBulk){
|
|
23893
|
-
backgroundProcessButton.
|
|
23894
|
-
|
|
23895
|
-
|
|
23896
|
-
|
|
23897
|
-
|
|
23898
|
-
|
|
23899
|
-
|
|
23900
|
-
|
|
23935
|
+
// backgroundProcessButton.classList.remove('hide');
|
|
23936
|
+
// backgroundProcessButton.style.display = 'flex'
|
|
23937
|
+
// console.log('backgroundprocessbutton', backgroundProcessButton);
|
|
23938
|
+
// backgroundProcessButton.addEventListener('click',() => {
|
|
23939
|
+
// console.log('bulk-progress clicked')
|
|
23940
|
+
// let bulkLoader = (this._SfIEventsC as HTMLDivElement).querySelector('.bulk-loader') as HTMLDivElement
|
|
23941
|
+
// bulkLoader.scrollIntoView();
|
|
23942
|
+
// })
|
|
23943
|
+
this.renderAppropriateStream(this.sdate,this.edate,true,true)
|
|
23901
23944
|
}else{
|
|
23902
|
-
backgroundProcessButton.
|
|
23945
|
+
// backgroundProcessButton.classList.add('hide')
|
|
23946
|
+
// backgroundProcessButton.style.display = 'none'
|
|
23903
23947
|
}
|
|
23904
23948
|
}
|
|
23905
23949
|
}
|