tango-app-ui-manage-tickets 3.7.0-beta.60 → 3.7.0-beta.62

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.
Files changed (177) hide show
  1. package/esm2022/lib/components/add-csm-modal/add-csm-modal.component.mjs +98 -0
  2. package/esm2022/lib/components/audit-log/audit-log.component.mjs +11 -0
  3. package/esm2022/lib/components/audit-mapping-list/audit-mapping-list.component.mjs +486 -0
  4. package/esm2022/lib/components/audit-metrics/audit-metrics.component.mjs +298 -0
  5. package/esm2022/lib/components/audit-report-popup/audit-report-popup.component.mjs +389 -0
  6. package/esm2022/lib/components/audit-retag/audit-retag.component.mjs +472 -0
  7. package/esm2022/lib/components/comment-model/comment-model.component.mjs +58 -0
  8. package/esm2022/lib/components/count/count.component.mjs +89 -0
  9. package/esm2022/lib/components/custom-select/custom-select.component.mjs +187 -0
  10. package/esm2022/lib/components/filter-options/filter-options.component.mjs +41 -0
  11. package/esm2022/lib/components/footfall-dic/footfall-dic.component.mjs +1061 -0
  12. package/esm2022/lib/components/footfall-dicview/footfall-dicview.component.mjs +1014 -0
  13. package/esm2022/lib/components/footfall-popup/footfall-popup.component.mjs +15 -0
  14. package/esm2022/lib/components/group-select/group-select.component.mjs +155 -0
  15. package/esm2022/lib/components/re-trigger/re-trigger.component.mjs +96 -0
  16. package/esm2022/lib/components/reactive-select/reactive-select.component.mjs +108 -0
  17. package/esm2022/lib/components/remove-audit/remove-audit.component.mjs +81 -0
  18. package/esm2022/lib/components/start-audit/start-audit.component.mjs +761 -0
  19. package/esm2022/lib/components/tango-manage-tickets/tango-manage-tickets.component.mjs +131 -0
  20. package/esm2022/lib/components/ticket-filter-panel/ticket-filter-panel.component.mjs +435 -0
  21. package/esm2022/lib/components/ticket-footfall-new/ticket-footfall-new.component.mjs +2748 -0
  22. package/esm2022/lib/components/ticketclosepopup/ticketclosepopup.component.mjs +43 -0
  23. package/esm2022/lib/components/tickets/tickets.component.mjs +847 -0
  24. package/esm2022/lib/components/viewcategory/viewcategory.component.mjs +89 -0
  25. package/esm2022/lib/services/audit.service.mjs +88 -0
  26. package/esm2022/lib/services/excel.service.mjs +45 -0
  27. package/esm2022/lib/services/ticket.service.mjs +319 -0
  28. package/esm2022/lib/services/timer.service.mjs +84 -0
  29. package/esm2022/lib/tango-manage-tickets-routing.module.mjs +44 -0
  30. package/esm2022/lib/tango-manage-tickets.module.mjs +109 -0
  31. package/esm2022/public-api.mjs +6 -0
  32. package/esm2022/tango-app-ui-manage-tickets.mjs +5 -0
  33. package/fesm2022/tango-app-ui-manage-tickets.mjs +10165 -0
  34. package/fesm2022/tango-app-ui-manage-tickets.mjs.map +1 -0
  35. package/index.d.ts +5 -0
  36. package/lib/components/add-csm-modal/add-csm-modal.component.d.ts +30 -0
  37. package/lib/components/audit-log/audit-log.component.d.ts +5 -0
  38. package/lib/components/audit-mapping-list/audit-mapping-list.component.d.ts +73 -0
  39. package/lib/components/audit-metrics/audit-metrics.component.d.ts +59 -0
  40. package/lib/components/audit-report-popup/audit-report-popup.component.d.ts +52 -0
  41. package/lib/components/audit-retag/audit-retag.component.d.ts +59 -0
  42. package/lib/components/comment-model/comment-model.component.d.ts +17 -0
  43. package/lib/components/count/count.component.d.ts +23 -0
  44. package/lib/components/custom-select/custom-select.component.d.ts +35 -0
  45. package/lib/components/filter-options/filter-options.component.d.ts +15 -0
  46. package/lib/components/footfall-dic/footfall-dic.component.d.ts +143 -0
  47. package/lib/components/footfall-dicview/footfall-dicview.component.d.ts +132 -0
  48. package/lib/components/footfall-popup/footfall-popup.component.d.ts +8 -0
  49. package/lib/components/group-select/group-select.component.d.ts +33 -0
  50. package/lib/components/re-trigger/re-trigger.component.d.ts +32 -0
  51. package/lib/components/reactive-select/reactive-select.component.d.ts +32 -0
  52. package/lib/components/remove-audit/remove-audit.component.d.ts +16 -0
  53. package/lib/components/start-audit/start-audit.component.d.ts +86 -0
  54. package/lib/components/tango-manage-tickets/tango-manage-tickets.component.d.ts +28 -0
  55. package/lib/components/ticket-filter-panel/ticket-filter-panel.component.d.ts +79 -0
  56. package/lib/components/ticket-footfall-new/ticket-footfall-new.component.d.ts +287 -0
  57. package/lib/components/ticketclosepopup/ticketclosepopup.component.d.ts +15 -0
  58. package/lib/components/tickets/tickets.component.d.ts +88 -0
  59. package/lib/components/viewcategory/viewcategory.component.d.ts +16 -0
  60. package/lib/services/audit.service.d.ts +36 -0
  61. package/lib/services/excel.service.d.ts +10 -0
  62. package/lib/services/ticket.service.d.ts +87 -0
  63. package/lib/services/timer.service.d.ts +22 -0
  64. package/lib/tango-manage-tickets-routing.module.d.ts +7 -0
  65. package/lib/tango-manage-tickets.module.d.ts +38 -0
  66. package/package.json +25 -12
  67. package/{src/public-api.ts → public-api.d.ts} +2 -8
  68. package/.eslintrc.json +0 -37
  69. package/ng-package.json +0 -7
  70. package/src/lib/components/add-csm-modal/add-csm-modal.component.html +0 -32
  71. package/src/lib/components/add-csm-modal/add-csm-modal.component.scss +0 -14
  72. package/src/lib/components/add-csm-modal/add-csm-modal.component.spec.ts +0 -23
  73. package/src/lib/components/add-csm-modal/add-csm-modal.component.ts +0 -94
  74. package/src/lib/components/audit-log/audit-log.component.html +0 -1
  75. package/src/lib/components/audit-log/audit-log.component.scss +0 -0
  76. package/src/lib/components/audit-log/audit-log.component.spec.ts +0 -23
  77. package/src/lib/components/audit-log/audit-log.component.ts +0 -10
  78. package/src/lib/components/audit-mapping-list/audit-mapping-list.component.html +0 -234
  79. package/src/lib/components/audit-mapping-list/audit-mapping-list.component.scss +0 -186
  80. package/src/lib/components/audit-mapping-list/audit-mapping-list.component.spec.ts +0 -23
  81. package/src/lib/components/audit-mapping-list/audit-mapping-list.component.ts +0 -520
  82. package/src/lib/components/audit-metrics/audit-metrics.component.html +0 -345
  83. package/src/lib/components/audit-metrics/audit-metrics.component.scss +0 -34
  84. package/src/lib/components/audit-metrics/audit-metrics.component.spec.ts +0 -23
  85. package/src/lib/components/audit-metrics/audit-metrics.component.ts +0 -292
  86. package/src/lib/components/audit-report-popup/audit-report-popup.component.html +0 -111
  87. package/src/lib/components/audit-report-popup/audit-report-popup.component.scss +0 -101
  88. package/src/lib/components/audit-report-popup/audit-report-popup.component.spec.ts +0 -23
  89. package/src/lib/components/audit-report-popup/audit-report-popup.component.ts +0 -397
  90. package/src/lib/components/audit-retag/audit-retag.component.html +0 -129
  91. package/src/lib/components/audit-retag/audit-retag.component.scss +0 -146
  92. package/src/lib/components/audit-retag/audit-retag.component.spec.ts +0 -23
  93. package/src/lib/components/audit-retag/audit-retag.component.ts +0 -489
  94. package/src/lib/components/comment-model/comment-model.component.html +0 -24
  95. package/src/lib/components/comment-model/comment-model.component.scss +0 -20
  96. package/src/lib/components/comment-model/comment-model.component.spec.ts +0 -23
  97. package/src/lib/components/comment-model/comment-model.component.ts +0 -53
  98. package/src/lib/components/count/count.component.html +0 -54
  99. package/src/lib/components/count/count.component.scss +0 -14
  100. package/src/lib/components/count/count.component.spec.ts +0 -23
  101. package/src/lib/components/count/count.component.ts +0 -82
  102. package/src/lib/components/custom-select/custom-select.component.html +0 -134
  103. package/src/lib/components/custom-select/custom-select.component.scss +0 -204
  104. package/src/lib/components/custom-select/custom-select.component.spec.ts +0 -23
  105. package/src/lib/components/custom-select/custom-select.component.ts +0 -189
  106. package/src/lib/components/filter-options/filter-options.component.html +0 -51
  107. package/src/lib/components/filter-options/filter-options.component.scss +0 -102
  108. package/src/lib/components/filter-options/filter-options.component.spec.ts +0 -23
  109. package/src/lib/components/filter-options/filter-options.component.ts +0 -38
  110. package/src/lib/components/footfall-dic/footfall-dic.component.html +0 -1275
  111. package/src/lib/components/footfall-dic/footfall-dic.component.scss +0 -273
  112. package/src/lib/components/footfall-dic/footfall-dic.component.spec.ts +0 -23
  113. package/src/lib/components/footfall-dic/footfall-dic.component.ts +0 -1206
  114. package/src/lib/components/footfall-dicview/footfall-dicview.component.html +0 -1136
  115. package/src/lib/components/footfall-dicview/footfall-dicview.component.scss +0 -416
  116. package/src/lib/components/footfall-dicview/footfall-dicview.component.spec.ts +0 -23
  117. package/src/lib/components/footfall-dicview/footfall-dicview.component.ts +0 -1168
  118. package/src/lib/components/footfall-popup/footfall-popup.component.html +0 -61
  119. package/src/lib/components/footfall-popup/footfall-popup.component.scss +0 -20
  120. package/src/lib/components/footfall-popup/footfall-popup.component.spec.ts +0 -23
  121. package/src/lib/components/footfall-popup/footfall-popup.component.ts +0 -12
  122. package/src/lib/components/group-select/group-select.component.html +0 -44
  123. package/src/lib/components/group-select/group-select.component.scss +0 -144
  124. package/src/lib/components/group-select/group-select.component.spec.ts +0 -23
  125. package/src/lib/components/group-select/group-select.component.ts +0 -145
  126. package/src/lib/components/re-trigger/re-trigger.component.html +0 -53
  127. package/src/lib/components/re-trigger/re-trigger.component.scss +0 -16
  128. package/src/lib/components/re-trigger/re-trigger.component.spec.ts +0 -23
  129. package/src/lib/components/re-trigger/re-trigger.component.ts +0 -96
  130. package/src/lib/components/reactive-select/reactive-select.component.html +0 -18
  131. package/src/lib/components/reactive-select/reactive-select.component.scss +0 -52
  132. package/src/lib/components/reactive-select/reactive-select.component.spec.ts +0 -23
  133. package/src/lib/components/reactive-select/reactive-select.component.ts +0 -104
  134. package/src/lib/components/remove-audit/remove-audit.component.html +0 -38
  135. package/src/lib/components/remove-audit/remove-audit.component.scss +0 -27
  136. package/src/lib/components/remove-audit/remove-audit.component.spec.ts +0 -23
  137. package/src/lib/components/remove-audit/remove-audit.component.ts +0 -81
  138. package/src/lib/components/start-audit/start-audit.component.html +0 -174
  139. package/src/lib/components/start-audit/start-audit.component.scss +0 -185
  140. package/src/lib/components/start-audit/start-audit.component.spec.ts +0 -23
  141. package/src/lib/components/start-audit/start-audit.component.ts +0 -761
  142. package/src/lib/components/tango-manage-tickets/tango-manage-tickets.component.html +0 -43
  143. package/src/lib/components/tango-manage-tickets/tango-manage-tickets.component.scss +0 -35
  144. package/src/lib/components/tango-manage-tickets/tango-manage-tickets.component.spec.ts +0 -23
  145. package/src/lib/components/tango-manage-tickets/tango-manage-tickets.component.ts +0 -118
  146. package/src/lib/components/ticket-filter-panel/ticket-filter-panel.component.html +0 -386
  147. package/src/lib/components/ticket-filter-panel/ticket-filter-panel.component.scss +0 -87
  148. package/src/lib/components/ticket-filter-panel/ticket-filter-panel.component.spec.ts +0 -23
  149. package/src/lib/components/ticket-filter-panel/ticket-filter-panel.component.ts +0 -494
  150. package/src/lib/components/ticket-footfall-new/ticket-footfall-new.component.html +0 -4743
  151. package/src/lib/components/ticket-footfall-new/ticket-footfall-new.component.scss +0 -1208
  152. package/src/lib/components/ticket-footfall-new/ticket-footfall-new.component.spec.ts +0 -23
  153. package/src/lib/components/ticket-footfall-new/ticket-footfall-new.component.ts +0 -3351
  154. package/src/lib/components/ticketclosepopup/ticketclosepopup.component.html +0 -100
  155. package/src/lib/components/ticketclosepopup/ticketclosepopup.component.scss +0 -34
  156. package/src/lib/components/ticketclosepopup/ticketclosepopup.component.spec.ts +0 -23
  157. package/src/lib/components/ticketclosepopup/ticketclosepopup.component.ts +0 -48
  158. package/src/lib/components/tickets/tickets.component.html +0 -451
  159. package/src/lib/components/tickets/tickets.component.scss +0 -131
  160. package/src/lib/components/tickets/tickets.component.spec.ts +0 -23
  161. package/src/lib/components/tickets/tickets.component.ts +0 -809
  162. package/src/lib/components/viewcategory/viewcategory.component.html +0 -38
  163. package/src/lib/components/viewcategory/viewcategory.component.scss +0 -29
  164. package/src/lib/components/viewcategory/viewcategory.component.spec.ts +0 -23
  165. package/src/lib/components/viewcategory/viewcategory.component.ts +0 -79
  166. package/src/lib/services/audit.service.spec.ts +0 -16
  167. package/src/lib/services/audit.service.ts +0 -98
  168. package/src/lib/services/excel.service.ts +0 -48
  169. package/src/lib/services/ticket.service.spec.ts +0 -16
  170. package/src/lib/services/ticket.service.ts +0 -501
  171. package/src/lib/services/timer.service.spec.ts +0 -16
  172. package/src/lib/services/timer.service.ts +0 -92
  173. package/src/lib/tango-manage-tickets-routing.module.ts +0 -37
  174. package/src/lib/tango-manage-tickets.module.ts +0 -68
  175. package/tsconfig.lib.json +0 -14
  176. package/tsconfig.lib.prod.json +0 -10
  177. package/tsconfig.spec.json +0 -14
@@ -1,18 +0,0 @@
1
- <div class="custom-select">
2
- <div class="form-group">
3
- <label *ngIf="label" class="form-label">{{label}}</label>
4
- <div class="position-relative">
5
- <div (click)="openDropdown()" [ngClass]="isDisabled ? 'disable' : ''" class="form-select dropselect text-nowrap">
6
- {{selected?.[nameField]}}</div>
7
- <div *ngIf="isOpened" class="card py-2 w-100 position-absolute end-0 z-1 drop-list">
8
- <ul class="list-unstyled mb-2">
9
- <li *ngFor="let item of data" (click)="onSelect(item)"
10
- [ngClass]="item?.[idField] === selected?.[idField] ? 'active' : ''"
11
- class="text px-5 items cursor-pointer py-4 ">
12
- {{item?.[nameField]}}
13
- </li>
14
- </ul>
15
- </div>
16
- </div>
17
- </div>
18
- </div>
@@ -1,52 +0,0 @@
1
- .custom-select {
2
- min-width: 100px;
3
- .items:hover,
4
- .tems.focus,
5
- .items.active,
6
- .camera.focus-visible {
7
- background: var(--Gray-50, #F9FAFB);
8
- }
9
-
10
- .drop-list{
11
- max-height: 300px;
12
- overflow-y: scroll;
13
- }
14
-
15
- .dropselect {
16
- color: var(--Gray-500, #667085);
17
- font-family: 'Inter';
18
- font-size: 16px;
19
- font-style: normal;
20
- font-weight: 400;
21
- line-height: 24px;
22
- /* 150% */
23
- height: 45px !important;
24
- cursor: default;
25
- white-space: nowrap;
26
- overflow: hidden;
27
- }
28
-
29
- .text {
30
- color: var(--Gray-700, #344054);
31
- font-size: 14px;
32
- font-weight: 500;
33
- line-height: 20px;
34
- }
35
-
36
- .disable{
37
- pointer-events: none;
38
- background-color: #F9FAFB !important;
39
- }
40
- }
41
-
42
- .ellipse1{
43
- min-width:auto;
44
- max-width:100%;
45
- white-space: nowrap;
46
- overflow: hidden;
47
- text-overflow: ellipsis;
48
- }
49
-
50
- .z-1 {
51
- z-index: 9 !important;
52
- }
@@ -1,23 +0,0 @@
1
- import { ComponentFixture, TestBed } from '@angular/core/testing';
2
-
3
- import { ReactiveSelectComponent } from './reactive-select.component';
4
-
5
- describe('ReactiveSelectComponent', () => {
6
- let component: ReactiveSelectComponent;
7
- let fixture: ComponentFixture<ReactiveSelectComponent>;
8
-
9
- beforeEach(async () => {
10
- await TestBed.configureTestingModule({
11
- declarations: [ReactiveSelectComponent]
12
- })
13
- .compileComponents();
14
-
15
- fixture = TestBed.createComponent(ReactiveSelectComponent);
16
- component = fixture.componentInstance;
17
- fixture.detectChanges();
18
- });
19
-
20
- it('should create', () => {
21
- expect(component).toBeTruthy();
22
- });
23
- });
@@ -1,104 +0,0 @@
1
- import { ChangeDetectorRef, Component, EventEmitter, HostListener, Input, OnInit, Output, Provider, forwardRef } from '@angular/core';
2
- import { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';
3
- import { TicketService } from '../../services/ticket.service';
4
-
5
- const SELECT_CONTROL_VALUE_ACCESSOR: Provider = {
6
- provide: NG_VALUE_ACCESSOR,
7
- useExisting: forwardRef(() => ReactiveSelectComponent),
8
- multi: true,
9
- };
10
-
11
- @Component({
12
- selector: 'lib-reactive-select',
13
- templateUrl: './reactive-select.component.html',
14
- styleUrl: './reactive-select.component.scss',
15
- providers: [SELECT_CONTROL_VALUE_ACCESSOR]
16
- })
17
- export class ReactiveSelectComponent implements ControlValueAccessor, OnInit {
18
-
19
- private onTouched: Function;
20
- private onChanged: Function;
21
- @Input() isDisabled: boolean;
22
- @Input() idField: string
23
- @Input() nameField: string
24
- @Input() label: string
25
- @Input() data: any
26
- @Output() itemChange = new EventEmitter()
27
- protected isOpened: boolean = false
28
- protected selected: Record<string, any> | null = null
29
- protected selectedId: string | number
30
- instanceId: string;
31
-
32
-
33
- constructor(private apiService: TicketService, private cd: ChangeDetectorRef) {
34
-
35
- }
36
-
37
- ngOnInit(): void {
38
- this.instanceId = crypto.randomUUID();
39
- this.apiService.dropDownTrigger.subscribe((e) => {
40
- if (e !== this.instanceId) {
41
- this.isOpened = false
42
- this.cd.detectChanges()
43
- }
44
- })
45
- }
46
-
47
-
48
- writeValue(val: string | number): void {
49
- this.selectedId = val
50
- this.selected = this.data.filter((item: Record<string, any>) => item?.[this.idField] === val)[0]
51
-
52
- }
53
- registerOnChange(fn: any): void {
54
- this.onChanged = fn
55
-
56
- }
57
- registerOnTouched(fn: any): void {
58
- this.onTouched = fn
59
- }
60
- setDisabledState?(isDisabled: boolean): void {
61
- this.isDisabled = isDisabled
62
-
63
- }
64
-
65
- onSelect(item: Record<string, any>) {
66
- this.onTouched()
67
- this.selected = item
68
- this.selectedId = item?.[this.idField]
69
- this.isOpened = false
70
- this.itemChange.next(this.selectedId)
71
- this.onChanged(this.selectedId)
72
- }
73
-
74
- @HostListener('document:click', ['$event'])
75
- onClick(event: MouseEvent) {
76
- // console.log(this.isDisabled)
77
- if (!this.isDisabled) {
78
- const targetElement = event.target as HTMLElement;
79
- if (!this.isComponentClicked(targetElement)) {
80
- this.isOpened = false;
81
- }
82
- }
83
- }
84
-
85
- isComponentClicked(targetElement: HTMLElement): boolean {
86
- const parentElement = targetElement.parentElement;
87
- if (parentElement) {
88
- const clickedOnComponent = parentElement.classList.contains('custom-select');
89
- if (clickedOnComponent) {
90
- return true;
91
- } else {
92
- return this.isComponentClicked(parentElement);
93
- }
94
- }
95
- return false;
96
- }
97
-
98
- openDropdown(){
99
- this.isOpened = !this.isOpened;
100
- this.apiService.dropDownTrigger.next(this.instanceId)
101
- }
102
-
103
-
104
- }
@@ -1,38 +0,0 @@
1
- <div class="modal-body mt-5">
2
- <div class=" d-flex">
3
- <div class="d-flex justify-content-between w-100">
4
- <div class="d-flex flex-column">
5
- <div class="d-flex align-items-center mb-2">
6
- <div class="fs-2 text-dark fw-bolder my-3 mx-7"> <span class="card-label fw-bold text-dark">
7
- {{maindata?.detectionType ? maindata?.detectionType : 'Customer' }} Files -
8
- <span>{{maindata?.count}}</span></span></div>
9
- </div>
10
- </div>
11
- </div>
12
- <div class="btn btn-sm btn-icon btn-active-color-primary me-5" (click)="closepopup()" data-bs-dismiss="modal">
13
- <span class="svg-icon svg-icon-1">
14
- <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none">
15
- <rect opacity="0.5" x="6" y="17.3137" width="16" height="2" rx="1" transform="rotate(-45 6 17.3137)"
16
- fill="black"></rect>
17
- <rect x="7.41422" y="6" width="16" height="2" rx="1" transform="rotate(45 7.41422 6)" fill="black">
18
- </rect>
19
- </svg>
20
- </span>
21
- </div>
22
- </div>
23
- <div class="card-body">
24
- <div class="row mx-3">
25
- <div class="col-md-12 item scroll-y">
26
- <div class="item" *ngFor="let item of imagelist;let i=index" style="padding: 10px;">
27
-
28
- <img class="mx-3 mb-3 img" [src]="item.img_path">
29
- <div class="text-center m-0 fs-7 fw-bold">{{item.img_name}}</div>
30
- <span *ngIf="i" class="notify-badge1 cursor-pointer" (click)="removeimage(item)"><i class="fa fa-close" aria-hidden="true"
31
- style="font-size:15px;color:#00A3FF"></i>
32
- </span>
33
-
34
- </div>
35
- </div>
36
- </div>
37
- </div>
38
- </div>
@@ -1,27 +0,0 @@
1
- .img {
2
- width: 95px;
3
- height: 200px;
4
- }
5
- .item {
6
- position: relative;
7
- padding-top: 20px;
8
- display: inline-block;
9
- max-height: 595px;
10
- }
11
-
12
- .scroll-y{
13
- overflow-y: auto !important;
14
- position: relative !important;
15
- }
16
-
17
- .notify-badge1 {
18
- position: absolute;
19
- right: 14px;
20
- top: 5px;
21
- background: var(--Primary-50, #EAF8FF);
22
- text-align: center;
23
- border-radius: 6px;
24
- color: #00A3FF;border: 2px solid var(--Primary-600, #00A3FF);
25
- padding: 0px 8px;
26
- font-size: 20px;
27
- }
@@ -1,23 +0,0 @@
1
- import { ComponentFixture, TestBed } from '@angular/core/testing';
2
-
3
- import { RemoveAuditComponent } from './remove-audit.component';
4
-
5
- describe('RemoveAuditComponent', () => {
6
- let component: RemoveAuditComponent;
7
- let fixture: ComponentFixture<RemoveAuditComponent>;
8
-
9
- beforeEach(async () => {
10
- await TestBed.configureTestingModule({
11
- declarations: [RemoveAuditComponent]
12
- })
13
- .compileComponents();
14
-
15
- fixture = TestBed.createComponent(RemoveAuditComponent);
16
- component = fixture.componentInstance;
17
- fixture.detectChanges();
18
- });
19
-
20
- it('should create', () => {
21
- expect(component).toBeTruthy();
22
- });
23
- });
@@ -1,81 +0,0 @@
1
- import { Component, OnInit, Input } from '@angular/core';
2
- import { NgbModal, NgbActiveModal } from '@ng-bootstrap/ng-bootstrap';
3
- import * as LZString from 'lz-string';
4
-
5
- @Component({
6
- selector: 'lib-remove-audit',
7
- templateUrl: './remove-audit.component.html',
8
- styleUrl: './remove-audit.component.scss'
9
- })
10
- export class RemoveAuditComponent implements OnInit {
11
-
12
- imagelist: any = []
13
- maindata: any;
14
- @Input() data: any;
15
-
16
- constructor(private modalService: NgbModal, public activeModal: NgbActiveModal) {
17
- }
18
-
19
- ngOnInit(): void {
20
- if (this.data) {
21
- this.maindata = this.data
22
- this.imagelist = this.data.mappedid
23
- }
24
- }
25
- removeimage(data: any) {
26
- this.imagelist.splice(this.imagelist.findIndex(({ img_name }: { img_name: string }) => img_name == data.img_name), 1);
27
- this.maindata.mappedid = this.imagelist
28
- this.maindata.count = this.maindata.count - 1
29
- var framedobj: any = {}
30
- framedobj.img_name = data.img_name
31
- framedobj.img_id = data.img_id
32
- framedobj.img_path = data.img_path
33
- framedobj.mappedid = [{
34
- img_name: data.img_name,
35
- img_id: data.img_id,
36
- img_path: data.img_path
37
- }]
38
- framedobj.count = 1
39
- framedobj.selected = false
40
- framedobj.demographic = ""
41
- framedobj.dropped = false
42
- let stringifydata = sessionStorage.getItem('audit') || '{}'
43
- const decompressedData = LZString.decompress(stringifydata);
44
- var customer = JSON.parse(decompressedData || '{}')
45
- var foundIndex = customer.findIndex((x: any) => x.img_id == this.maindata.img_id);
46
- if (foundIndex == -1) {
47
- var retag = JSON.parse(sessionStorage.getItem('retag') || '{}')
48
- var newindex = retag.findIndex((x: any) => x.img_id == this.maindata.img_id);
49
- retag[newindex] = this.maindata;
50
- retag.push(framedobj)
51
- sessionStorage.setItem('retag', JSON.stringify(retag))
52
- } else {
53
- customer[foundIndex] = this.maindata;
54
- customer.push(framedobj)
55
- const jsonString = JSON.stringify(customer);
56
- const compressedData = LZString.compress(jsonString);
57
- sessionStorage.setItem('audit', compressedData)
58
- }
59
-
60
-
61
- console.log(this.maindata,framedobj)
62
- if ('duplicate' in sessionStorage) {
63
- let filedata = JSON.parse(sessionStorage.getItem('duplicate') || '{}')
64
- console.log("🚀 ~ RemoveAuditComponent ~ removeimage ~ filedata:", filedata)
65
- let filterData = filedata.filter((x: any) => x.img_name != framedobj.img_name)
66
- console.log(filterData)
67
-
68
- sessionStorage.setItem('duplicate', JSON.stringify(filterData))
69
-
70
- }
71
-
72
-
73
- if (this.imagelist.length == 1) {
74
- this.activeModal.close({ reload: true });
75
- }
76
- }
77
- closepopup() {
78
- this.activeModal.close({ reload: true });
79
- }
80
-
81
- }
@@ -1,174 +0,0 @@
1
- <div class="mb-5 d-flex justify-content-between align-items-center w-100">
2
- <div class="d-flex align-items-center">
3
- <div class="border w-40px bg-white cursor-pointer me-5 text-center" (click)="backtotickets()"><svg
4
- xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
5
- <path d="M15.8334 10H4.16669M4.16669 10L10 15.8334M4.16669 10L10 4.16669" stroke="#344054"
6
- stroke-width="1.67" stroke-linecap="round" stroke-linejoin="round" />
7
- </svg>
8
- </div>
9
- <a (click)="cameraPreview()"><span *ngIf="filedetails?.Date">{{filedetails?.Date}}</span><span> -
10
- </span><span *ngIf="filedetails?.storeId">{{filedetails?.storeId}}</span><span> - </span><span
11
- *ngIf="storedetails?.storeName">{{storedetails?.storeName}}</span><span *ngIf="selectedType ==='zone'">
12
- - </span><span
13
- *ngIf="filedetails?.zoneName && selectedType ==='zone'">{{filedetails?.zoneName}}</span><span
14
- *ngIf="storedetails?.address"> | {{storedetails?.address}} </span></a>
15
- </div>
16
- <div class="rounded-3 d-flex align-items-center bg-timer">
17
- <span class="me-3 text-timer fw-semibold">{{ formattedTime }}</span>
18
- <span><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none">
19
- <path
20
- d="M9.16667 2.87071C9.16667 2.62023 9.26617 2.38001 9.44329 2.20289C9.62041 2.02577 9.86063 1.92627 10.1111 1.92627H13.8889C14.1394 1.92627 14.3796 2.02577 14.5567 2.20289C14.7338 2.38001 14.8333 2.62023 14.8333 2.87071C14.8333 3.1212 14.7338 3.36142 14.5567 3.53854C14.3796 3.71565 14.1394 3.81516 13.8889 3.81516H12.9444V5.07442L12.9432 5.12605C14.5396 5.30097 16.0528 5.92787 17.3053 6.93308L17.3141 6.92553L18.2585 5.98108C18.374 5.85676 18.5208 5.76588 18.6835 5.71801C18.8463 5.67014 19.019 5.66706 19.1833 5.70908C19.3477 5.75111 19.4977 5.83669 19.6175 5.9568C19.7373 6.07692 19.8225 6.22713 19.8641 6.3916C19.906 6.55578 19.903 6.72823 19.8554 6.89085C19.8077 7.05348 19.7172 7.20029 19.5933 7.3159L18.6489 8.26034L18.6413 8.26915C19.6403 9.51974 20.2658 11.027 20.446 12.6174C20.6261 14.2078 20.3536 15.8167 19.6597 17.2591C18.9658 18.7014 17.8788 19.9185 16.5237 20.7704C15.1686 21.6222 13.6006 22.0741 12 22.0741C10.3994 22.0741 8.83137 21.6222 7.47629 20.7704C6.12122 19.9185 5.03419 18.7014 4.3403 17.2591C3.64641 15.8167 3.37386 14.2078 3.55402 12.6174C3.73418 11.027 4.35973 9.51974 5.35867 8.26915L5.35111 8.26034L4.40667 7.3159C4.23964 7.1369 4.14865 6.90003 4.15287 6.65524C4.1571 6.41045 4.25622 6.17687 4.42934 6.00375C4.60246 5.83063 4.83604 5.73151 5.08083 5.72728C5.32562 5.72306 5.56249 5.81405 5.74149 5.98108L6.68593 6.92553L6.69474 6.93308C7.94681 5.92809 9.45963 5.3012 11.0556 5.12605V3.81516H10.1111C9.86063 3.81516 9.62041 3.71565 9.44329 3.53854C9.26617 3.36142 9.16667 3.1212 9.16667 2.87071ZM12 20.1855C13.7535 20.1854 15.4352 19.4886 16.675 18.2485C17.9148 17.0085 18.6113 15.3267 18.6111 13.5732C18.6109 11.8196 17.9142 10.138 16.6741 8.89813C15.4341 7.65831 13.7523 6.96188 11.9987 6.96204C10.2452 6.96221 8.56354 7.65896 7.32372 8.89902C6.0839 10.1391 5.38747 11.8209 5.38763 13.5744C5.3878 15.328 6.08455 17.0096 7.32461 18.2494C8.56467 19.4893 10.2465 20.1857 12 20.1855ZM12.4899 11.7485L14.1647 10.0737C14.2517 9.98343 14.3559 9.91143 14.4711 9.86188C14.5863 9.81233 14.7102 9.78622 14.8356 9.78507C14.9611 9.78392 15.0854 9.80776 15.2015 9.85519C15.3176 9.90262 15.4231 9.9727 15.5118 10.0613C15.6005 10.15 15.6707 10.2554 15.7182 10.3714C15.7658 10.4875 15.7897 10.6118 15.7887 10.7372C15.7877 10.8626 15.7617 10.9866 15.7122 11.1018C15.6628 11.2171 15.5909 11.3213 15.5007 11.4085L13.8259 13.0846C13.9003 13.3645 13.9095 13.6579 13.8526 13.942C13.7958 14.226 13.6745 14.4933 13.4981 14.7231C13.3217 14.9529 13.0949 15.1391 12.8352 15.2675C12.5754 15.3958 12.2897 15.4628 12 15.4633C11.7327 15.461 11.4688 15.4019 11.226 15.29C10.9832 15.1781 10.767 15.0159 10.5916 14.8141C10.4162 14.6123 10.2857 14.3755 10.2087 14.1195C10.1316 13.8635 10.1099 13.594 10.1448 13.329C10.1798 13.0639 10.2706 12.8093 10.4114 12.582C10.5522 12.3547 10.7396 12.1599 10.9613 12.0104C11.183 11.861 11.4339 11.7604 11.6974 11.7152C11.9609 11.6701 12.231 11.6814 12.4899 11.7485Z"
21
- fill="black" />
22
- </svg></span>
23
- </div>
24
- </div>
25
- <div class="card py-2">
26
- <div class="card-header align-items-center border-0 overflow">
27
- <div class="card-title border-0">
28
- <!-- <div class="w-50px h-50px badge-light-primary text-center align-content-center rounded-3">
29
- <svg xmlns="http://www.w3.org/2000/svg" width="28" height="28" viewBox="0 0 28 28" fill="none">
30
- <path d="M21 15.1667V23.3334H4.66665V7.00004H10.5233C10.5816 6.17171 10.78 5.39004 11.0833 4.66671H4.66665C3.38331 4.66671 2.33331 5.71671 2.33331 7.00004V23.3334C2.33331 24.6167 3.38331 25.6667 4.66665 25.6667H21C22.2833 25.6667 23.3333 24.6167 23.3333 23.3334V17.5L21 15.1667ZM19.25 21H6.41665L9.62498 16.8817L11.9116 19.635L15.12 15.505L19.25 21ZM22.5166 10.3717C23.03 9.55504 23.3333 8.61004 23.3333 7.58337C23.3333 4.67837 20.9883 2.33337 18.0833 2.33337C15.1783 2.33337 12.8333 4.67837 12.8333 7.58337C12.8333 10.4884 15.1783 12.8334 18.0716 12.8334C19.0983 12.8334 20.055 12.53 20.86 12.0167L24.5 15.6567L26.1566 14L22.5166 10.3717ZM18.0833 10.5C17.3098 10.5 16.5679 10.1927 16.0209 9.64577C15.4739 9.09879 15.1666 8.35692 15.1666 7.58337C15.1666 6.80983 15.4739 6.06796 16.0209 5.52098C16.5679 4.974 17.3098 4.66671 18.0833 4.66671C18.8569 4.66671 19.5987 4.974 20.1457 5.52098C20.6927 6.06796 21 6.80983 21 7.58337C21 8.35692 20.6927 9.09879 20.1457 9.64577C19.5987 10.1927 18.8569 10.5 18.0833 10.5Z" fill="#00A3FF"/>
31
- </svg>
32
- </div> -->
33
- <div class="d-grid">
34
- <div class="card-label ms-2"><span *ngIf="filedetails?.type">{{filedetails?.type ? filedetails?.type :
35
- ''}}</span>
36
- </div>
37
- <div *ngIf="filedetails" class="sub-text mt-2">
38
- <span class="badge badge-light-default"><svg class="me-2" xmlns="http://www.w3.org/2000/svg"
39
- width="12" height="12" viewBox="0 0 12 12" fill="none">
40
- <g clip-path="url(#clip0_14508_18583)">
41
- <path
42
- d="M2.5 10.5H9.5C10.0523 10.5 10.5 10.0523 10.5 9.5V2.5C10.5 1.94772 10.0523 1.5 9.5 1.5H2.5C1.94772 1.5 1.5 1.94772 1.5 2.5V9.5C1.5 10.0523 1.94772 10.5 2.5 10.5ZM2.5 10.5L8 5L10.5 7.5M5 4.25C5 4.66421 4.66421 5 4.25 5C3.83579 5 3.5 4.66421 3.5 4.25C3.5 3.83579 3.83579 3.5 4.25 3.5C4.66421 3.5 5 3.83579 5 4.25Z"
43
- stroke="#667085" stroke-width="1.1" stroke-linecap="round"
44
- stroke-linejoin="round" />
45
- </g>
46
- <defs>
47
- <clipPath id="clip0_14508_18583">
48
- <rect width="12" height="12" fill="white" />
49
- </clipPath>
50
- </defs>
51
- </svg>{{totalfile ? totalfile : 0}} After Count</span>
52
- </div>
53
- </div>
54
- </div>
55
- <div class="d-flex align align-items-center gap-2">
56
- <div class="border border-1 rounded-3 w-auto h-45px px-2 d-flex justify-content-between align-items-center"
57
- *ngFor="let item of category">
58
- <div class="h-100 align-content-center text-nowrap fw-semibold cursor-pointer mx-2" (click)="viewcategory(item)">
59
- <span class="badge badge-light-primary me-2">{{item?.count}}</span>{{item?.name}}<span class=" ms-3 badge badge-light-primary me-5 text-capitalize">{{item?.key}}</span></div>
60
- </div>
61
- <!-- <div class="border border-1 rounded-3 w-auto h-45px px-4 d-flex justify-content-between align-items-center">
62
- <div class="px-5 h-100 align-content-center text fw-semibold pe-none"><span
63
- class="badge badge-light-primary me-5">{{auditmappingdata?.length ? auditmappingdata?.length : 0
64
- }}</span>Unique Customers</div>
65
- </div> -->
66
- <div *ngIf="!auditLoading && !Nodata" class="card-toolbar text-nowrap ms-5">
67
- <button type="button" class="btn btn-sm btn-default btn-outline ms-3 py-2"
68
- [disabled]="!employeecount && !junkcount && (auditmappingdata?.length === totalfile)"
69
- (click)="savedraft()">Save Draft</button>
70
- <button type="submit" class="btn btn-sm btn-primary py-2 ms-3" [disabled]="submitted"
71
- (click)="Reviewdata()">Review <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20"
72
- viewBox="0 0 20 20" fill="none">
73
- <path
74
- d="M4.16666 9.99996H15.8333M15.8333 9.99996L9.99999 4.16663M15.8333 9.99996L9.99999 15.8333"
75
- stroke="white" stroke-width="1.67" stroke-linecap="round" stroke-linejoin="round" />
76
- </svg></button>
77
- </div>
78
- </div>
79
- </div>
80
- </div>
81
-
82
- <!-- scroll-top -->
83
- <div class="card mt-5">
84
- <div class="card-body">
85
- <div class="row">
86
- <div *ngIf="auditLoading">
87
- <div class="row loader d-flex justify-content-center align-items-center">
88
- <div class="shimmer">
89
- <div class="wrapper">
90
- <div class="stroke animate title"></div>
91
- <div class="stroke animate link"></div>
92
- <div class="stroke animate description"></div>
93
- </div>
94
- </div>
95
- <div class="shimmer">
96
- <div class="wrapper">
97
- <div class="stroke animate title"></div>
98
- <div class="stroke animate link"></div>
99
- <div class="stroke animate description"></div>
100
- </div>
101
- </div>
102
- </div>
103
-
104
- </div>
105
- <ng-container *ngIf="Nodata">
106
- <div class="row">
107
- <div class="col-lg-12 mb-3">
108
- <div class="card-body d-flex justify-content-center align-items-center flex-column">
109
- <img class="img-nodata" src="./assets/tango/Icons/Nodata1.svg" alt="">
110
- <div class="nodata-title">No data found</div>
111
- <div class="nodata-sub">There is no result for this conversion funnel</div>
112
- </div>
113
- </div>
114
- </div>
115
- </ng-container>
116
- <!-- scroll-y h-500px -->
117
- <div *ngIf="!auditLoading" class="col-md-12 item ">
118
-
119
- <div class="item" *ngFor="let item of auditmappingdata;let i=index" style="padding: 5px 10px;">
120
-
121
- <img class="mx-3 my-3 img" [src]="item?.img_path" id="{{item?.img_name}}" alt="Image"
122
- (dragover)="allowDrop($event)" (drop)="dropImage($event)" draggable="true"
123
- (dragstart)="dragImage($event)" (click)="toggleImage(item?.img_name )">
124
- <div class="text-center m-0 fs-7 fw-bold">{{item?.img_name}}</div>
125
-
126
- <span *ngIf="item?.selected" class="notify-badge1"><i class="fa fa-check" aria-hidden="true"
127
- style="font-size:15px;color:#00A3FF"></i></span>
128
- <!-- (click)="removeaudit(item)" -->
129
- <span class="notify-badge cursor-pointer" (click)="removeaudit(item)" *ngIf="item?.count>1">{{item?.count}}</span>
130
- </div>
131
-
132
- <ngx-spinner size="medium" type="ball-atom"></ngx-spinner>
133
-
134
- </div>
135
- </div>
136
- </div>
137
- </div>
138
-
139
- <ng-template #confirmDraft let-modal>
140
- <div class="card h-auto p-10">
141
- <div class="card-header d-grid p-0 border-0">
142
- <span><img src="./assets/tango/Images/Successtoast.png"></span>
143
- <!-- <span *ngIf="getBack"><img src="./assets/tango/custompopup-Icons/danger-icon.svg"></span> -->
144
- <div class="card-label mt-5">Save Changes</div>
145
- <!-- <div *ngIf="getBack" class="card-label mt-5">Unsaved Changes</div> -->
146
- </div>
147
- <div class="card-body p-0">
148
- <p class="text-sub mt-5">Do you want to draft the file?</p>
149
- <!-- <p *ngIf="getBack" class="text-sub mt-5">Do you want to get back?</p> -->
150
- <textarea class="form-control mt-5" [(ngModel)]="datareason"
151
- placeholder="Type your reason (Required) ..."></textarea>
152
- <div class="w-100 d-flex mt-10">
153
- <button class="btn btn-outline w-50 me-2 fw-bold" [disabled]="!datareason"
154
- (click)="modal.close('isConfirmed')">Save & Exit</button>
155
- <button class="btn btn-primary savebtn w-50 ms-2" (click)="modal.close('isDenied')">save &
156
- Continue</button>
157
- </div>
158
- </div>
159
- </div>
160
- </ng-template>
161
-
162
- <ng-template #confirmerror let-modal>
163
- <div class="w-400px h-auto p-10 card">
164
- <div class="card-header border-0">
165
- <div class="card-label">{{Errormsg}}</div>
166
- </div>
167
- <div class="card-body mt-5">
168
- <div class="w-100 d-flex mt-10">
169
- <button class="btn btn-outline w-50 me-2" (click)="modal.close('isDenied')">Cancel</button>
170
- <button class="btn btn-primary w-50 ms-2" (click)="modal.close('isConfirmed')">Confirm</button>
171
- </div>
172
- </div>
173
- </div>
174
- </ng-template>