tango-app-ui-manage-tickets 3.7.0-beta.18 → 3.7.0-beta.19

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.
@@ -401,6 +401,8 @@ class TicketsComponent {
401
401
  assignStores = [];
402
402
  issueTypeList = [];
403
403
  queryTypeList = [];
404
+ ClusterList;
405
+ filterByCluster;
404
406
  constructor(cd, router, route, gs, modalService, service, excelservice) {
405
407
  this.cd = cd;
406
408
  this.router = router;
@@ -427,6 +429,8 @@ class TicketsComponent {
427
429
  this.issueTypeList = [];
428
430
  this.filterByQueryType = [];
429
431
  this.queryTypeList = [];
432
+ this.filterByCluster = [];
433
+ this.ClusterList = [];
430
434
  this.dataObject = [];
431
435
  this.gs.manageRefreshTrigger.next(true);
432
436
  this.getInitload();
@@ -440,6 +444,7 @@ class TicketsComponent {
440
444
  userType: this.users.userType,
441
445
  };
442
446
  this.getstoreFilter();
447
+ this.getAllGroups();
443
448
  }
444
449
  },
445
450
  });
@@ -511,17 +516,20 @@ class TicketsComponent {
511
516
  this.dataObject = [
512
517
  { Description: "Store ID", Issues: this.storeList },
513
518
  { Description: "Deployed Status", Issues: this.statusType },
519
+ { Description: "Clusters", Issues: this.ClusterList },
514
520
  ];
515
521
  }
516
522
  else if (this.type === 'infra' || this.type === 'dataMismatch') {
517
523
  this.dataObject = [
518
524
  { Description: "Store ID", Issues: this.storeList },
519
525
  { Description: "Status", Issues: this.statusType },
526
+ { Description: "Clusters", Issues: this.ClusterList },
520
527
  ];
521
528
  }
522
529
  else if (this.type === 'mat') {
523
530
  this.dataObject = [
524
531
  { Description: "Status", Issues: this.statusType },
532
+ { Description: "Clusters", Issues: this.ClusterList },
525
533
  ];
526
534
  }
527
535
  }
@@ -556,6 +564,7 @@ class TicketsComponent {
556
564
  { Description: "Store ID", Issues: this.storeList },
557
565
  { Description: "Deployed Status", Issues: this.statusType },
558
566
  { Description: this.typeName, Issues: this.userList },
567
+ { Description: "Clusters", Issues: this.ClusterList },
559
568
  ];
560
569
  }
561
570
  else if (this.users.userType === "tango" && this.type === 'infra') {
@@ -563,6 +572,7 @@ class TicketsComponent {
563
572
  { Description: "Store ID", Issues: this.storeList },
564
573
  { Description: "Status", Issues: this.statusType },
565
574
  { Description: this.typeName, Issues: this.userList },
575
+ { Description: "Clusters", Issues: this.ClusterList },
566
576
  ];
567
577
  }
568
578
  else if (this.users.userType === "tango" && this.type === 'dataMismatch') {
@@ -570,11 +580,13 @@ class TicketsComponent {
570
580
  { Description: "Store ID", Issues: this.storeList },
571
581
  { Description: "Query Type", Issues: this.queryTypeList },
572
582
  { Description: "Status", Issues: this.statusType },
583
+ { Description: "Clusters", Issues: this.ClusterList },
573
584
  ];
574
585
  }
575
586
  else if (this.type === 'mat') {
576
587
  this.dataObject = [
577
588
  { Description: "Status", Issues: this.statusType },
589
+ { Description: "Cluster", Issues: this.ClusterList },
578
590
  ];
579
591
  }
580
592
  });
@@ -640,6 +652,9 @@ class TicketsComponent {
640
652
  if (this.filterByQueryType?.length) {
641
653
  obj.filterByQueryType = this.filterByQueryType ? this.filterByQueryType : [];
642
654
  }
655
+ if (this.filterByCluster?.length) {
656
+ obj.filterByCluster = this.filterByCluster ? this.filterByCluster : [];
657
+ }
643
658
  }
644
659
  if (this.type === "installation") {
645
660
  this.service
@@ -753,6 +768,24 @@ class TicketsComponent {
753
768
  : [];
754
769
  this.assignTicket = this.selectAll; // Update assignTicket based on selectAll state
755
770
  }
771
+ getAllGroups() {
772
+ console.log(this.headerFilters?.clients);
773
+ this.ClusterList = [];
774
+ this.service.getclusters({ clientId: this.headerFilters?.clients[0], group: [], city: [] }).subscribe({
775
+ next: (res) => {
776
+ if (res && res.code == 200) {
777
+ this.ClusterList = res?.data?.groupData;
778
+ this.ClusterList.forEach((element) => {
779
+ element.text = element.groupName;
780
+ element.id = element.groupName;
781
+ });
782
+ }
783
+ else {
784
+ this.ClusterList = [];
785
+ }
786
+ }
787
+ });
788
+ }
756
789
  updateCheck(event, ticketId) {
757
790
  const ticket = this.tableListArray.find((obj) => obj.ticketId === ticketId);
758
791
  if (ticket) {
@@ -818,9 +851,9 @@ class TicketsComponent {
818
851
  if (element.Description === "Query Type") {
819
852
  this.filterByQueryType = element.Issues.map((val) => val?.id);
820
853
  }
821
- // if (element.Description === "Issue Type") {
822
- // this.issueType = element.Issues.map((val: any) => val?.id);
823
- // }
854
+ if (element.Description === "Clusters") {
855
+ this.filterByCluster = element.Issues.map((val) => val?.id);
856
+ }
824
857
  });
825
858
  }
826
859
  this.currentPage = 1;
@@ -878,6 +911,9 @@ class TicketsComponent {
878
911
  obj.filterByQueryType = this.filterByQueryType ? this.filterByQueryType : [];
879
912
  }
880
913
  }
914
+ if (this.filterByCluster?.length) {
915
+ obj.filterByCluster = this.filterByCluster ? this.filterByCluster : [];
916
+ }
881
917
  // console.log(obj)
882
918
  // return
883
919
  if (this.type === "installation") {