kwikid-agent-dashboard 0.0.12 → 0.0.13

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.
@@ -1,8 +1,8 @@
1
1
  (function (global, factory) {
2
- typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/google-maps'), require('@taiga-ui/core'), require('rxjs'), require('rxjs/operators'), require('@angular/common/http'), require('kwikui'), require('@angular/forms'), require('@taiga-ui/cdk'), require('@angular/cdk/scrolling'), require('kwikid-toolkit'), require('@angular/common'), require('kwikid-forms'), require('@taiga-ui/addon-mobile')) :
3
- typeof define === 'function' && define.amd ? define('kwikid-agent-dashboard', ['exports', '@angular/core', '@angular/google-maps', '@taiga-ui/core', 'rxjs', 'rxjs/operators', '@angular/common/http', 'kwikui', '@angular/forms', '@taiga-ui/cdk', '@angular/cdk/scrolling', 'kwikid-toolkit', '@angular/common', 'kwikid-forms', '@taiga-ui/addon-mobile'], factory) :
4
- (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["kwikid-agent-dashboard"] = {}, global.ng.core, global.ng.googleMaps, global["@taiga-ui/core"], global.rxjs, global.rxjs.operators, global.ng.common.http, global.i4$1, global.ng.forms, global["@taiga-ui/cdk"], global.ng.cdk.scrolling, global.kwikidToolkit, global.ng.common, global.i6, global["@taiga-ui/addon-mobile"]));
5
- })(this, (function (exports, i0, i4, i9, rxjs, operators, i2, i4$1, i5$1, i8, i3, kwikidToolkit, i5, i6, addonMobile) { 'use strict';
2
+ typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/google-maps'), require('@taiga-ui/core'), require('rxjs'), require('rxjs/operators'), require('@angular/common/http'), require('kwikui'), require('kwikid-toolkit'), require('@angular/common'), require('@angular/forms'), require('@taiga-ui/cdk'), require('@angular/cdk/scrolling'), require('kwikid-forms'), require('@taiga-ui/addon-mobile')) :
3
+ typeof define === 'function' && define.amd ? define('kwikid-agent-dashboard', ['exports', '@angular/core', '@angular/google-maps', '@taiga-ui/core', 'rxjs', 'rxjs/operators', '@angular/common/http', 'kwikui', 'kwikid-toolkit', '@angular/common', '@angular/forms', '@taiga-ui/cdk', '@angular/cdk/scrolling', 'kwikid-forms', '@taiga-ui/addon-mobile'], factory) :
4
+ (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["kwikid-agent-dashboard"] = {}, global.ng.core, global.ng.googleMaps, global["@taiga-ui/core"], global.rxjs, global.rxjs.operators, global.ng.common.http, global.i2, global.kwikidToolkit, global.ng.common, global.ng.forms, global["@taiga-ui/cdk"], global.ng.cdk.scrolling, global.i8, global["@taiga-ui/addon-mobile"]));
5
+ })(this, (function (exports, i0, i5, i11, rxjs, operators, i3$1, i2, kwikidToolkit, i6, i5$1, i10, i3, i8, addonMobile) { 'use strict';
6
6
 
7
7
  function _interopNamespace(e) {
8
8
  if (e && e.__esModule) return e;
@@ -23,15 +23,15 @@
23
23
  }
24
24
 
25
25
  var i0__namespace = /*#__PURE__*/_interopNamespace(i0);
26
- var i4__namespace = /*#__PURE__*/_interopNamespace(i4);
27
- var i9__namespace = /*#__PURE__*/_interopNamespace(i9);
26
+ var i5__namespace = /*#__PURE__*/_interopNamespace(i5);
27
+ var i11__namespace = /*#__PURE__*/_interopNamespace(i11);
28
+ var i3__namespace$1 = /*#__PURE__*/_interopNamespace(i3$1);
28
29
  var i2__namespace = /*#__PURE__*/_interopNamespace(i2);
29
- var i4__namespace$1 = /*#__PURE__*/_interopNamespace(i4$1);
30
+ var i6__namespace = /*#__PURE__*/_interopNamespace(i6);
30
31
  var i5__namespace$1 = /*#__PURE__*/_interopNamespace(i5$1);
31
- var i8__namespace = /*#__PURE__*/_interopNamespace(i8);
32
+ var i10__namespace = /*#__PURE__*/_interopNamespace(i10);
32
33
  var i3__namespace = /*#__PURE__*/_interopNamespace(i3);
33
- var i5__namespace = /*#__PURE__*/_interopNamespace(i5);
34
- var i6__namespace = /*#__PURE__*/_interopNamespace(i6);
34
+ var i8__namespace = /*#__PURE__*/_interopNamespace(i8);
35
35
 
36
36
  /******************************************************************************
37
37
  Copyright (c) Microsoft Corporation.
@@ -126,11 +126,11 @@
126
126
  if (_ = accept(result.set))
127
127
  descriptor.set = _;
128
128
  if (_ = accept(result.init))
129
- initializers.push(_);
129
+ initializers.unshift(_);
130
130
  }
131
131
  else if (_ = accept(result)) {
132
132
  if (kind === "field")
133
- initializers.push(_);
133
+ initializers.unshift(_);
134
134
  else
135
135
  descriptor[key] = _;
136
136
  }
@@ -417,6 +417,33 @@
417
417
  throw new TypeError("Cannot use 'in' operator on non-object");
418
418
  return typeof state === "function" ? receiver === state : state.has(receiver);
419
419
  }
420
+ var tslib_es6 = {
421
+ __extends: __extends,
422
+ __assign: __assign,
423
+ __rest: __rest,
424
+ __decorate: __decorate,
425
+ __param: __param,
426
+ __metadata: __metadata,
427
+ __awaiter: __awaiter,
428
+ __generator: __generator,
429
+ __createBinding: __createBinding,
430
+ __exportStar: __exportStar,
431
+ __values: __values,
432
+ __read: __read,
433
+ __spread: __spread,
434
+ __spreadArrays: __spreadArrays,
435
+ __spreadArray: __spreadArray,
436
+ __await: __await,
437
+ __asyncGenerator: __asyncGenerator,
438
+ __asyncDelegator: __asyncDelegator,
439
+ __asyncValues: __asyncValues,
440
+ __makeTemplateObject: __makeTemplateObject,
441
+ __importStar: __importStar,
442
+ __importDefault: __importDefault,
443
+ __classPrivateFieldGet: __classPrivateFieldGet,
444
+ __classPrivateFieldSet: __classPrivateFieldSet,
445
+ __classPrivateFieldIn: __classPrivateFieldIn,
446
+ };
420
447
 
421
448
  var MapService = /** @class */ (function () {
422
449
  function MapService(mapDirectionsService) {
@@ -514,726 +541,176 @@
514
541
  };
515
542
  return MapService;
516
543
  }());
517
- /** @nocollapse */ MapService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: MapService, deps: [{ token: i4__namespace.MapDirectionsService }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
544
+ /** @nocollapse */ MapService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: MapService, deps: [{ token: i5__namespace.MapDirectionsService }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
518
545
  /** @nocollapse */ MapService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: MapService, providedIn: 'root' });
519
546
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: MapService, decorators: [{
520
547
  type: i0.Injectable,
521
548
  args: [{
522
549
  providedIn: 'root'
523
550
  }]
524
- }], ctorParameters: function () { return [{ type: i4__namespace.MapDirectionsService }]; }, propDecorators: { directionsRenders: [{
551
+ }], ctorParameters: function () { return [{ type: i5__namespace.MapDirectionsService }]; }, propDecorators: { directionsRenders: [{
525
552
  type: i0.ViewChildren,
526
553
  args: ['directionsRender']
527
554
  }] } });
528
555
 
529
- var InfoWindowService = /** @class */ (function () {
530
- function InfoWindowService(mapService) {
531
- this.mapService = mapService;
532
- this.config = {
533
- fields: {
534
- name: {
535
- label: 'Name',
536
- value: 'name',
537
- display: 'value',
538
- style: {
539
- fontSize: '1rem',
540
- fontWeight: 600
541
- }
542
- },
543
- phone: {
544
- label: 'Call',
545
- value: 'phone',
546
- display: 'label',
547
- style: {
548
- fontSize: '0.8rem',
549
- padding: '0.1rem 0',
550
- textAlign: 'justify'
556
+ var UserService = /** @class */ (function () {
557
+ function UserService() {
558
+ this.isListOpen = true;
559
+ this.showMapview = false;
560
+ this.showTaskDetails = 0;
561
+ this.addTaskFormConfig = {
562
+ key: 'ADD_TASK',
563
+ title: 'Add Task',
564
+ fields: [
565
+ {
566
+ key: 'name',
567
+ label: 'Customer Name',
568
+ disabled: false,
569
+ messages: [],
570
+ default: {
571
+ value: {
572
+ is_found: false,
573
+ value: '',
574
+ sources: [
575
+ {
576
+ key: 'OBJECT',
577
+ props: {
578
+ object: {
579
+ key: 'ALL_FORMS_DATA',
580
+ path: '$.ADD_TASK.name'
581
+ }
582
+ },
583
+ value: '',
584
+ validation: {
585
+ is_valid: false,
586
+ triggers: ['ON_INIT'],
587
+ rules: [
588
+ {
589
+ id: '1',
590
+ key: 'VALUE_CHECK',
591
+ props: {
592
+ value: {
593
+ source: {
594
+ key: 'OBJECT',
595
+ props: {
596
+ object: {
597
+ key: 'ALL_FORMS_DATA',
598
+ path: '$.ADD_TASK.name'
599
+ }
600
+ }
601
+ }
602
+ },
603
+ pattern: {
604
+ key: 'IS_NOT_EMPTY'
605
+ }
606
+ }
607
+ }
608
+ ],
609
+ actions: [
610
+ {
611
+ id: '1',
612
+ key: 'SET_FIELD_DEFAULT_VALUE',
613
+ condition: '1',
614
+ props: {
615
+ fieldKey: 'name',
616
+ value: {
617
+ source: {
618
+ key: 'OBJECT',
619
+ props: {
620
+ object: {
621
+ key: 'ALL_FORMS_DATA',
622
+ path: '$.ADD_TASK.name'
623
+ }
624
+ }
625
+ }
626
+ }
627
+ }
628
+ }
629
+ ]
630
+ }
631
+ }
632
+ ]
633
+ }
551
634
  },
552
- icon: 'https://cdn-icons-png.flaticon.com/512/60/60720.png'
635
+ validators: {
636
+ required: true
637
+ },
638
+ properties: {
639
+ placeholder: 'Please enter the Customer Name',
640
+ readOnly: false,
641
+ case: 'default'
642
+ },
643
+ type: 'text'
553
644
  },
554
- address: {
555
- label: 'Directions',
556
- value: 'address',
557
- display: 'label',
558
- style: {
559
- fontSize: '0.8rem',
560
- padding: '0.1rem 0'
561
- },
562
- icon: 'https://cdn-icons-png.flaticon.com/512/62/62516.png'
563
- }
564
- }
565
- };
566
- this.mainInfoWindowStyle = {
567
- display: 'flex',
568
- 'flex-direction': 'column',
569
- 'justify-content': 'center',
570
- 'align-items': 'stretch',
571
- gap: '0.5rem',
572
- padding: '0.5rem'
573
- };
574
- this.fieldDivStyle = {
575
- gap: ' 0.5rem',
576
- display: 'flex',
577
- 'flex-direction': 'row'
578
- };
579
- }
580
- InfoWindowService.prototype.getOpenMarker = function () {
581
- return this.openMarker;
582
- };
583
- InfoWindowService.prototype.setOpenMarker = function (value) {
584
- this.openMarker = value;
585
- };
586
- /**
587
- * @description
588
- * Wrapper method to show Customer Info Window
589
- *
590
- * @function showInfo
591
- * @func showInfo
592
- * @method showInfo
593
- */
594
- InfoWindowService.prototype.showCustomerInformation = function (customer, marker) {
595
- var map = this.mapService.map;
596
- var contentString = this.createInfoContent(customer);
597
- var infowindow = new google.maps.InfoWindow({
598
- content: contentString
599
- });
600
- this.addEventListeners(customer, infowindow);
601
- this.closeLastOpenedInfoWindow();
602
- infowindow.open(map, marker);
603
- this.lastInfoWindowOpened = infowindow;
604
- this.mapService.map = Object.assign(Object.assign({}, this.mapService.map), { center: marker.getPosition });
605
- // map.setCenter(marker.getPosition());
606
- return { infowindow: infowindow };
607
- };
608
- InfoWindowService.prototype.addEventListeners = function (customer, infowindow) {
609
- // chnage -
610
- var addressLink = "http://maps.google.com/?q=" + customer.extras.loc[0] + ", " + customer.extras.loc[1];
611
- google.maps.event.addListener(infowindow, 'domready', function () {
612
- document.getElementById('Call').addEventListener('click', function (e) {
613
- window.open("tel:" + customer.extras.phone, '_self');
614
- });
615
- document
616
- .getElementById('Directions')
617
- .addEventListener('click', function (e) {
618
- window.open("" + addressLink, '_blank');
619
- });
620
- document
621
- .getElementsByClassName('gm-ui-hover-effect')[0]
622
- .setAttribute('style', ' background: none;\
623
- display: block; \
624
- border: 0px; \
625
- margin: 0px; \
626
- padding: 0px; \
627
- text-transform: none; \
628
- appearance: none; \
629
- position: absolute; \
630
- cursor: pointer; \
631
- user-select: none; \
632
- top: 0px; \
633
- right: 0px; \
634
- width: 30px; \
635
- height: 30px; \
636
- ');
637
- });
638
- };
639
- /**
640
- * @description
641
- * Wrapper method to close Last Info Window
642
- *
643
- * @function closeLastOpenedInfoWindow
644
- * @func closeLastOpenedInfoWindow
645
- * @method closeLastOpenedInfoWindow
646
- */
647
- InfoWindowService.prototype.closeLastOpenedInfoWindow = function () {
648
- if (this.lastInfoWindowOpened) {
649
- this.lastInfoWindowOpened.close();
650
- }
651
- };
652
- /**
653
- * @description
654
- * Closes the previously opened info window.
655
- *
656
- * @function infoData
657
- * @func infoData
658
- * @method infoData
659
- */
660
- InfoWindowService.prototype.createInfoContent = function (customer) {
661
- var content = "<div style='padding:4px; font-family: Manrope;' >";
662
- content += this.createFields(customer, this.config.fields);
663
- content += '</div>';
664
- return content;
665
- };
666
- /**
667
- * @description
668
- * Wrapper method to create Fields Container
669
- *
670
- * @function createFields
671
- * @func createFields
672
- * @method createFields
673
- */
674
- InfoWindowService.prototype.createFields = function (customer, fields) {
675
- var e_1, _a;
676
- var _div = document.createElement('div');
677
- for (var property in this.mainInfoWindowStyle)
678
- _div.style[property] = this.mainInfoWindowStyle[property];
679
- try {
680
- for (var _b = __values(Object.keys(fields)), _c = _b.next(); !_c.done; _c = _b.next()) {
681
- var key = _c.value;
682
- var field = fields[key];
683
- var _fieldDiv = document.createElement('div');
684
- _fieldDiv.setAttribute('id', field.label);
685
- for (var property in this.fieldDivStyle)
686
- _fieldDiv.style[property] = this.fieldDivStyle[property];
687
- for (var property in field.style)
688
- _fieldDiv.style[property] = field.style[property];
689
- var string = field.display == 'label' ? field.label : customer.extras[field.value];
690
- if (field.icon) {
691
- var _icon = document.createElement('img');
692
- _icon.src = field.icon;
693
- _icon.style.width = field.style.fontSize;
694
- _icon.style.height = field.style.fontSize;
695
- _fieldDiv.appendChild(_icon);
696
- }
697
- var _fieldText = document.createElement('div');
698
- _fieldText.innerHTML = string;
699
- _fieldDiv.appendChild(_fieldText);
700
- _div.appendChild(_fieldDiv);
701
- }
702
- }
703
- catch (e_1_1) { e_1 = { error: e_1_1 }; }
704
- finally {
705
- try {
706
- if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
707
- }
708
- finally { if (e_1) throw e_1.error; }
709
- }
710
- return _div.outerHTML;
711
- };
712
- return InfoWindowService;
713
- }());
714
- /** @nocollapse */ InfoWindowService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: InfoWindowService, deps: [{ token: MapService }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
715
- /** @nocollapse */ InfoWindowService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: InfoWindowService, providedIn: 'root' });
716
- i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: InfoWindowService, decorators: [{
717
- type: i0.Injectable,
718
- args: [{
719
- providedIn: 'root'
720
- }]
721
- }], ctorParameters: function () { return [{ type: MapService }]; } });
722
-
723
- var EStatus;
724
- (function (EStatus) {
725
- EStatus["NOT_STARTED"] = "not started";
726
- EStatus["ON_GOING"] = "on going";
727
- EStatus["AUDITING"] = "auditing";
728
- EStatus["REJECTED"] = "rejected";
729
- EStatus["AFTER_AUDIT"] = "after audit";
730
- EStatus["COMPLETE"] = "complete";
731
- })(EStatus || (EStatus = {}));
732
- var VStatus = [
733
- EStatus.NOT_STARTED,
734
- EStatus.ON_GOING,
735
- EStatus.AUDITING,
736
- EStatus.REJECTED,
737
- EStatus.AFTER_AUDIT,
738
- EStatus.COMPLETE
739
- ];
740
-
741
- var StatusPillComponent = /** @class */ (function () {
742
- function StatusPillComponent() {
743
- }
744
- StatusPillComponent.prototype.ngOnInit = function () {
745
- if (kwikidToolkit.isEmptyValue(this.status)) {
746
- this.status = EStatus.NOT_STARTED;
747
- }
748
- };
749
- StatusPillComponent.prototype.getStatusPillClass = function (status) {
750
- var newStatus = status.replace(' ', '-');
751
- return "status-pill " + newStatus;
752
- };
753
- return StatusPillComponent;
754
- }());
755
- /** @nocollapse */ StatusPillComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: StatusPillComponent, deps: [], target: i0__namespace.ɵɵFactoryTarget.Component });
756
- /** @nocollapse */ StatusPillComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: StatusPillComponent, selector: "status-pill", inputs: { status: "status" }, ngImport: i0__namespace, template: "<div [ngClass]=\"getStatusPillClass(status)\">{{status}}</div>\n", styles: [".status-pill{background-color:#555;padding:.1rem .5rem;border-radius:1rem;font-size:.7rem;color:#fff}.complete{background-color:var(--tui-positive)}.rejected{background-color:var(--tui-negative)}.auditing{background-color:var(--tui-primary)}.on-going{background-color:var(--tui-primary)}.after-audit{background-color:var(--tui-warning-fill);color:#222}\n"], directives: [{ type: i5__namespace.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
757
- i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: StatusPillComponent, decorators: [{
758
- type: i0.Component,
759
- args: [{
760
- selector: 'status-pill',
761
- templateUrl: './status-pill.component.html',
762
- styleUrls: ['./status-pill.component.css']
763
- }]
764
- }], propDecorators: { status: [{
765
- type: i0.Input
766
- }] } });
767
-
768
- var CustomerTileComponent = /** @class */ (function () {
769
- /**
770
- * @description
771
- *
772
- * @constructor
773
- */
774
- function CustomerTileComponent(mapService, infoWindowService) {
775
- this.mapService = mapService;
776
- this.infoWindowService = infoWindowService;
777
- /**
778
- * @description
779
- * Determines Customer Data
780
- *
781
- * @default
782
- * `{}`
783
- */
784
- this.customer = {};
785
- /**
786
- * @description
787
- * Determines Index of Customer Data in Customer List
788
- *
789
- * @default
790
- *
791
- */
792
- this.index = undefined;
793
- this.viewTaskDetails = [];
794
- /**
795
- * @description
796
- * Emitter to emit next Step
797
- *
798
- * @emits KwikIDAgentDashboardComponent#nextStep
799
- * @fires KwikIDAgentDashboardComponent#nextStep
800
- */
801
- this.nextStep = new i0.EventEmitter();
802
- this.removeTask = new i0.EventEmitter();
803
- }
804
- /**
805
- * @description
806
- * To set Google Maps API on script
807
- *
808
- * @ngOnInit
809
- */
810
- CustomerTileComponent.prototype.ngOnInit = function () {
811
- var _a, _b, _c;
812
- this.viewTaskDetails = (_c = (_b = (_a = this.agentConfig) === null || _a === void 0 ? void 0 : _a.dashboardConfig) === null || _b === void 0 ? void 0 : _b.viewTaskDetails) !== null && _c !== void 0 ? _c : this.viewTaskDetails;
813
- };
814
- CustomerTileComponent.prototype.getTaskDetails = function (taskData) {
815
- return kwikidToolkit.getObjectValueFromPath(this.customer, taskData);
816
- };
817
- CustomerTileComponent.prototype.tileClick = function () {
818
- if (this.index == this.infoWindowService.getOpenMarker()) {
819
- this.infoWindowService.setOpenMarker(null);
820
- //this.infoWindowService.lastInfoWindowOpened.close();
821
- }
822
- else {
823
- this.showDetails(this.customer, this.index);
824
- }
825
- };
826
- /**
827
- * @description
828
- * Wrapper method to show Customer Info Window
829
- *
830
- * @function showDetails
831
- * @func showDetails
832
- * @method showDetails
833
- */
834
- CustomerTileComponent.prototype.showDetails = function (customer, index) {
835
- var markers = this.mapService.getMarkers();
836
- var marker = markers[index + 1];
837
- // let { infowindow } = this.infoWindowService.showCustomerInformation(
838
- // customer,
839
- // marker
840
- // );
841
- this.infoWindowService.setOpenMarker(index);
842
- };
843
- CustomerTileComponent.prototype.goToMaps = function (location) {
844
- window.open("" + location, '_blank');
845
- };
846
- CustomerTileComponent.prototype.goToNextStep = function (e) {
847
- this.nextStep.emit(e);
848
- };
849
- CustomerTileComponent.prototype.handleOnClickRemoveTask = function (task) {
850
- this.removeTask.emit(task);
851
- };
852
- return CustomerTileComponent;
853
- }());
854
- /** @nocollapse */ CustomerTileComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerTileComponent, deps: [{ token: MapService }, { token: InfoWindowService }], target: i0__namespace.ɵɵFactoryTarget.Component });
855
- /** @nocollapse */ CustomerTileComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: CustomerTileComponent, selector: "customer-tile", inputs: { customer: "customer", index: "index", agentConfig: "agentConfig" }, outputs: { nextStep: "nextStep", removeTask: "removeTask" }, viewQueries: [{ propertyName: "infoWindow", first: true, predicate: i4.MapInfoWindow, descendants: true }], ngImport: i0__namespace, template: "<div class=\"customer-tile-wrapper\">\n <div class=\"customer-tile-primary-container\">\n <div class=\"customer-tile-primary-container-data\">\n <div class=\"customer-tile-primary-container-userid\">\n {{ customer.user_id }}\n </div>\n <status-pill *ngIf=\"agentConfig?.dashboardConfig?.showTaskStatus\" [status]=\"customer.session_status\"></status-pill>\n </div>\n <kwikui-button-icon\n [icon]=\"\n index == infoWindowService.getOpenMarker()\n ? 'tuiIconChevronUpLarge'\n : 'tuiIconChevronDownLarge'\n \"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"tileClick()\"\n ></kwikui-button-icon>\n </div>\n <div\n [ngClass]=\"\n index == infoWindowService.getOpenMarker()\n ? 'customer-tile-secondary-container'\n : 'data-collasped'\n \"\n >\n <div class=\"customer-tile-secondary-container-data\">\n <div\n *ngFor=\"let taskData of viewTaskDetails\"\n class=\"customer-tile-secondary-container-custom-details\"\n >\n {{ getTaskDetails(taskData) }}\n </div>\n </div>\n <div class=\"customer-tile-secondary-container-actions\">\n <div class=\"customer-tile-secondary-container-task-buttons\">\n <kwikui-button-icon\n *ngIf=\"agentConfig.dashboardConfig?.allowRemoveTask\"\n [icon]=\"'tuiIconTrash2'\"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"handleOnClickRemoveTask(customer)\"\n ></kwikui-button-icon>\n <kwikui-button-icon\n *ngIf=\"agentConfig.dashboardConfig?.showCopyLink\"\n icon=\"tuiIconCopy\"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"\n goToNextStep({ customer: customer, stepType: 'SHARE_JOURNEY_LINK' })\n \"\n ></kwikui-button-icon>\n </div>\n <div class=\"customer-tile-secondary-container-journey-buttons\">\n <kwikui-button\n *ngIf=\"\n agentConfig.dashboardConfig?.showMaps &&\n customer?.task_details?.customer_details?.location\n \"\n label=\"Show Directions\"\n appearance=\"flat\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"goToMaps(customer.task_details.customer_details.location)\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"\n agentConfig.dashboardConfig?.showStartJourneyButton &&\n customer.session_status !== 'complete' &&\n customer.session_status !== ''\n \"\n label=\"Edit Journey\"\n appearance=\"primary\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"\n goToNextStep({ customer: customer, stepType: 'EDIT_JOURNEY' })\n \"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"\n agentConfig.dashboardConfig?.showStartJourneyButton &&\n customer.session_status == ''\n \"\n label=\"Start Journey\"\n appearance=\"primary\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"\n goToNextStep({ customer: customer, stepType: 'START_JOURNEY' })\n \"\n ></kwikui-button>\n </div>\n </div>\n </div>\n</div>\n", styles: [".customer-tile-wrapper{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:stretch;flex:1;overflow:auto;grid-gap:.5rem;gap:.5rem;padding:1rem;border-bottom:.5px solid #ddd}.customer-tile-wrapper .customer-tile-primary-container{display:flex;grid-gap:.5rem;gap:.5rem;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;width:100%;height:100%}.customer-tile-wrapper .customer-tile-primary-container .customer-tile-primary-container-data{padding-left:.2rem;grid-gap:.6rem;gap:.6rem;display:flex;flex-direction:row;flex-wrap:wrap;align-content:stretch;justify-content:space-evenly;align-items:center}.customer-tile-wrapper .customer-tile-primary-container .customer-tile-primary-container-data .customer-tile-primary-container-userid{font-weight:500;font-size:1.1rem;line-height:1rem}.customer-tile-wrapper .customer-tile-secondary-container{width:100%;height:100%;display:flex;flex-direction:column;overflow:auto;grid-gap:.5rem;gap:.5rem}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-data{padding:.4rem .2rem;display:flex;flex-direction:column;font-size:.7rem;grid-gap:.3rem;gap:.3rem}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-data .customer-tile-secondary-container-custom-details{width:100%;height:100%;line-height:.9rem}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions .customer-tile-secondary-container-task-buttons{display:flex;flex-direction:row;align-items:center;justify-content:flex-start}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions .customer-tile-secondary-container-journey-buttons{padding-right:.2rem;display:flex;flex-direction:row;grid-gap:.2rem;gap:.2rem;align-items:center;justify-content:flex-end}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions .customer-tile-secondary-container-journey-buttons .customer-share-link{font-size:.7rem}.customer-tile-wrapper .data-collasped{display:none}\n"], components: [{ type: StatusPillComponent, selector: "status-pill", inputs: ["status"] }, { type: i4__namespace$1.KwikUIButtonIconComponent, selector: "kwikui-button-icon", inputs: ["disabled", "id", "showLoader", "styles", "class", "type", "appearance", "icon", "shape", "size"], outputs: ["onClick"] }, { type: i4__namespace$1.KwikUIButtonComponent, selector: "kwikui-button", inputs: ["disabled", "id", "label", "showLoader", "styles", "class", "type", "appearance", "icon", "iconRight", "shape", "size"], outputs: ["onClick"] }], directives: [{ type: i5__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5__namespace.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i5__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
856
- i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerTileComponent, decorators: [{
857
- type: i0.Component,
858
- args: [{
859
- selector: 'customer-tile',
860
- templateUrl: './customer-tile.component.html',
861
- styleUrls: ['./customer-tile.component.scss']
862
- }]
863
- }], ctorParameters: function () { return [{ type: MapService }, { type: InfoWindowService }]; }, propDecorators: { customer: [{
864
- type: i0.Input
865
- }], index: [{
866
- type: i0.Input
867
- }], agentConfig: [{
868
- type: i0.Input
869
- }], nextStep: [{
870
- type: i0.Output
871
- }], removeTask: [{
872
- type: i0.Output
873
- }], infoWindow: [{
874
- type: i0.ViewChild,
875
- args: [i4.MapInfoWindow]
876
- }] } });
877
-
878
- var Ng2SearchPipe = /** @class */ (function () {
879
- function Ng2SearchPipe() {
880
- }
881
- /**
882
- * @param items object from array
883
- * @param term term's search
884
- * @param excludes array of strings which will ignored during search
885
- */
886
- Ng2SearchPipe.prototype.transform = function (items, term, excludes) {
887
- if (excludes === void 0) { excludes = []; }
888
- if (!term || !items)
889
- return items;
890
- return Ng2SearchPipe.filter(items, term, excludes);
891
- };
892
- /**
893
- *
894
- * @param items List of items to filter
895
- * @param term a string term to compare with every property of the list
896
- * @param excludes List of keys which will be ignored during search
897
- *
898
- */
899
- Ng2SearchPipe.filter = function (items, term, excludes) {
900
- var toCompare = term.toLowerCase();
901
- function checkInside(item, term) {
902
- if (typeof item === 'string' &&
903
- item.toString().toLowerCase().includes(toCompare)) {
904
- return true;
905
- }
906
- for (var property in item) {
907
- if (item[property] === null ||
908
- item[property] == undefined ||
909
- excludes.includes(property)) {
910
- continue;
911
- }
912
- if (typeof item[property] === 'object') {
913
- if (checkInside(item[property], term)) {
914
- return true;
915
- }
916
- }
917
- else if (item[property].toString().toLowerCase().includes(toCompare)) {
918
- return true;
919
- }
920
- }
921
- return false;
922
- }
923
- return items.filter(function (item) {
924
- return checkInside(item, term);
925
- });
926
- };
927
- return Ng2SearchPipe;
928
- }());
929
- /** @nocollapse */ Ng2SearchPipe.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: Ng2SearchPipe, deps: [], target: i0__namespace.ɵɵFactoryTarget.Pipe });
930
- /** @nocollapse */ Ng2SearchPipe.ɵpipe = i0__namespace.ɵɵngDeclarePipe({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: Ng2SearchPipe, name: "filter", pure: false });
931
- /** @nocollapse */ Ng2SearchPipe.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: Ng2SearchPipe });
932
- i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: Ng2SearchPipe, decorators: [{
933
- type: i0.Pipe,
934
- args: [{
935
- name: 'filter',
936
- pure: false
937
- }]
938
- }, {
939
- type: i0.Injectable
940
- }] });
941
-
942
- var CustomerListComponent = /** @class */ (function () {
943
- function CustomerListComponent(mapService) {
944
- this.mapService = mapService;
945
- this.nextStep = new i0.EventEmitter();
946
- this.removeTask = new i0.EventEmitter();
947
- this.filterTaskList = new i0.EventEmitter();
948
- this.filteredData = [];
949
- this.formGroup = new i5$1.FormGroup({});
950
- this.maxLength = { month: 1 };
951
- this.fromDate = this.getDate(null);
952
- this.toDate = this.getDate(null);
953
- this.dateRangeFormControl = new i5$1.FormControl({
954
- value: new i8.TuiDayRange(new i8.TuiDay(new Date().getFullYear(), new Date().getMonth(), new Date().getDate()), new i8.TuiDay(new Date().getFullYear(), new Date().getMonth(), new Date().getDate())),
955
- disabled: false
956
- });
957
- this.formGroup.addControl('dateRange', this.dateRangeFormControl);
958
- this.searchFormControl = new i5$1.FormControl('');
959
- this.formGroup.addControl('search', this.searchFormControl);
960
- }
961
- CustomerListComponent.prototype.ngOnInit = function () { };
962
- CustomerListComponent.prototype.ngAfterViewInit = function () {
963
- var _this = this;
964
- setTimeout(function () { return __awaiter(_this, void 0, void 0, function () {
965
- var _a;
966
- return __generator(this, function (_b) {
967
- switch (_b.label) {
968
- case 0:
969
- if (!this.agentConfig.dashboardConfig.showMaps) return [3 /*break*/, 3];
970
- return [4 /*yield*/, this.mapService.initMap()];
971
- case 1:
972
- _b.sent();
973
- _a = this;
974
- return [4 /*yield*/, this.plotMarkers(this.customers)];
975
- case 2:
976
- _a.filteredData = _b.sent();
977
- return [3 /*break*/, 4];
978
- case 3:
979
- this.filteredData = this.customers;
980
- _b.label = 4;
981
- case 4: return [2 /*return*/];
982
- }
983
- });
984
- }); }, 1000);
985
- };
986
- CustomerListComponent.prototype.ngOnChanges = function () {
987
- if (this.agentConfig.dashboardConfig.showMaps) {
988
- this.filteredData = this.plotMarkers(this.customers);
989
- }
990
- else {
991
- this.filteredData = this.customers;
992
- }
993
- };
994
- CustomerListComponent.prototype.goToNextStep = function (e) {
995
- this.nextStep.emit(e);
996
- };
997
- CustomerListComponent.prototype.getDate = function (d) {
998
- var date = d ? new Date(d) : new Date();
999
- var year = date.getFullYear();
1000
- var month = date.getMonth() + 1;
1001
- var day = date.getDate();
1002
- if (month < 10)
1003
- month = '0' + month;
1004
- if (day < 10)
1005
- day = '0' + day;
1006
- var today = year + "-" + month + "-" + day;
1007
- return today;
1008
- };
1009
- CustomerListComponent.prototype.plotMarkers = function (customers) {
1010
- var _this = this;
1011
- var directionsResults$ = this.mapService.plotMarkers(customers);
1012
- directionsResults$.subscribe(function (val) {
1013
- _this.filteredData = _this.mapService.sortList(val.routes[0].waypoint_order, customers);
1014
- });
1015
- return customers;
1016
- };
1017
- CustomerListComponent.prototype.getTuiDate = function (event) {
1018
- var year = event.year;
1019
- var month = event.month + 1;
1020
- var date = event.day;
1021
- month = month < 10 ? '0' + month : month;
1022
- date = date < 10 ? '0' + date : date;
1023
- return year + "-" + month + "-" + date;
1024
- };
1025
- CustomerListComponent.prototype.onDateRangeChange = function (event) {
1026
- this.fromDate = this.getTuiDate(event.value.from);
1027
- this.toDate = this.getTuiDate(event.value.to);
1028
- this.handleOnFilterTaskList({
1029
- from_date: this.fromDate,
1030
- to_date: this.toDate
1031
- });
1032
- };
1033
- CustomerListComponent.prototype.onSearchFilter = function (event) {
1034
- this.searchText = event.value;
1035
- };
1036
- CustomerListComponent.prototype.handleOnClickRemoveTask = function (task) {
1037
- this.removeTask.emit(task);
1038
- };
1039
- CustomerListComponent.prototype.handleOnFilterTaskList = function (filter) {
1040
- this.filterTaskList.emit(filter);
1041
- };
1042
- return CustomerListComponent;
1043
- }());
1044
- /** @nocollapse */ CustomerListComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerListComponent, deps: [{ token: MapService }], target: i0__namespace.ɵɵFactoryTarget.Component });
1045
- /** @nocollapse */ CustomerListComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: CustomerListComponent, selector: "customer-list", inputs: { customers: "customers", agentConfig: "agentConfig" }, outputs: { nextStep: "nextStep", removeTask: "removeTask", filterTaskList: "filterTaskList" }, usesOnChanges: true, ngImport: i0__namespace, template: "<div class=\"customer-list-wrapper\">\n <div class=\"customer-list-filter\" [formGroup]=\"formGroup\">\n <kwikui-input-date-range\n *ngIf=\"agentConfig?.dashboardConfig?.showDateFilter\"\n [label]=\"'Date Range'\"\n [id]=\"'dateRange'\"\n [size]=\"'m'\"\n [maxLength]=\"maxLength\"\n [formControlName]=\"'dateRange'\"\n [formControl]=\"dateRangeFormControl\"\n (getKeyValue)=\"onDateRangeChange($event)\"\n ></kwikui-input-date-range>\n <kwikui-input\n *ngIf=\"agentConfig?.dashboardConfig?.showSearchFilter\"\n [label]=\"'Search'\"\n [id]=\"'search'\"\n icon=\"tuiIconSearch\"\n size=\"m\"\n placeholder=\"Search Any Task\"\n [formControlName]=\"'search'\"\n [formControl]=\"searchFormControl\"\n (getKeyValue)=\"onSearchFilter($event)\"\n ></kwikui-input>\n </div>\n\n <div class=\"customer-task-list\">\n <cdk-virtual-scroll-viewport itemSize=\"1\" class=\"customer-task-list-scroll\">\n <div\n *cdkVirtualFor=\"\n let customer of filteredData | filter: searchText;\n index as index\n \"\n >\n <customer-tile\n class=\"example-item\"\n [customer]=\"customer\"\n [agentConfig]=\"agentConfig\"\n [index]=\"index\"\n (nextStep)=\"goToNextStep($event)\"\n (removeTask)=\"handleOnClickRemoveTask($event)\"\n ></customer-tile>\n </div>\n </cdk-virtual-scroll-viewport>\n </div>\n\n <div class=\"customer-list-empty\" *ngIf=\"filteredData.length === 0\">\n {{agentConfig?.dashboardConfig?.emptyTaskListMessage ?? '0 Tasks for the given Date.'}}\n </div>\n</div>\n", styles: [".customer-list-wrapper{width:100%;height:100%;display:flex;flex-direction:column}.customer-list-filter{height:-moz-fit-content;height:fit-content;width:100%;display:flex;flex-direction:column;padding:1rem;grid-gap:.8rem;gap:.8rem;border-bottom:.5px solid #ddd}.customer-list-empty{height:100%;width:100%;margin-top:.5rem;font-size:1rem;text-align:center}.customer-task-list{height:100%}.customer-task-list-scroll{height:100%;width:100%}.cdk-virtual-scroll-spacer{height:0!important}.example-item{height:50px}::-webkit-scrollbar{width:8px}::-webkit-scrollbar-track{border-radius:10px}::-webkit-scrollbar-thumb{background:lightgray;border-radius:10px}::-webkit-scrollbar-thumb:hover{background:gray}\n"], components: [{ type: i4__namespace$1.KwikUIInputDateRangeComponent, selector: "kwikui-input-date-range", inputs: ["label", "id", "formControlName", "formControl", "placeholder", "focus", "invalid", "disabled", "min", "minLength", "max", "maxLength", "size", "validators", "properties"], outputs: ["getKeyValue"] }, { type: i4__namespace$1.KwikUIInputComponent, selector: "kwikui-input", inputs: ["label", "id", "type", "formControlName", "formControl", "placeholder", "focus", "invalid", "disabled", "validators", "case", "size", "icon", "properties"], outputs: ["getKeyValue"] }, { type: i3__namespace.CdkVirtualScrollViewport, selector: "cdk-virtual-scroll-viewport", inputs: ["orientation", "appendOnly"], outputs: ["scrolledIndexChange"] }, { type: CustomerTileComponent, selector: "customer-tile", inputs: ["customer", "index", "agentConfig"], outputs: ["nextStep", "removeTask"] }], directives: [{ type: i5__namespace$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i5__namespace$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i5__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5__namespace$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i5__namespace$1.FormControlName, selector: "[formControlName]", inputs: ["disabled", "formControlName", "ngModel"], outputs: ["ngModelChange"] }, { type: i5__namespace$1.FormControlDirective, selector: "[formControl]", inputs: ["disabled", "formControl", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { type: i3__namespace.CdkFixedSizeVirtualScroll, selector: "cdk-virtual-scroll-viewport[itemSize]", inputs: ["itemSize", "minBufferPx", "maxBufferPx"] }, { type: i3__namespace.CdkVirtualForOf, selector: "[cdkVirtualFor][cdkVirtualForOf]", inputs: ["cdkVirtualForOf", "cdkVirtualForTrackBy", "cdkVirtualForTemplate", "cdkVirtualForTemplateCacheSize"] }], pipes: { "filter": Ng2SearchPipe } });
1046
- i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerListComponent, decorators: [{
1047
- type: i0.Component,
1048
- args: [{
1049
- selector: 'customer-list',
1050
- templateUrl: './customer-list.component.html',
1051
- styleUrls: ['./customer-list.component.css']
1052
- }]
1053
- }], ctorParameters: function () { return [{ type: MapService }]; }, propDecorators: { customers: [{
1054
- type: i0.Input
1055
- }], agentConfig: [{
1056
- type: i0.Input
1057
- }], nextStep: [{
1058
- type: i0.Output
1059
- }], removeTask: [{
1060
- type: i0.Output
1061
- }], filterTaskList: [{
1062
- type: i0.Output
1063
- }] } });
1064
-
1065
- var KwikIDAgentDashboardComponent = /** @class */ (function () {
1066
- function KwikIDAgentDashboardComponent(mapService, httpClient, hostElement, dialogService) {
1067
- this.mapService = mapService;
1068
- this.httpClient = httpClient;
1069
- this.hostElement = hostElement;
1070
- this.dialogService = dialogService;
1071
- this.agentConfig = {};
1072
- this.taskList = [];
1073
- this.nextStep = new i0.EventEmitter();
1074
- this.addTask = new i0.EventEmitter();
1075
- this.removeTask = new i0.EventEmitter();
1076
- this.filterTaskList = new i0.EventEmitter();
1077
- this.loading = true;
1078
- this.showMapview = true;
1079
- this.isMobileView = false;
1080
- this.listOpen = true;
1081
- this.options = {
1082
- stops: ['calc(5rem + 74vw)', 'calc(9rem + 74vw)']
1083
- };
1084
- this.addTaskFormConfig = {
1085
- key: 'ADD_TASK',
1086
- title: 'Add Task',
1087
- fields: [
1088
- {
1089
- key: 'name',
1090
- label: 'Customer Name',
1091
- disabled: false,
1092
- messages: [],
1093
- default: {
1094
- value: {
1095
- is_found: false,
1096
- value: '',
1097
- sources: [
1098
- {
1099
- key: 'OBJECT',
1100
- props: {
1101
- object: {
1102
- key: 'ALL_FORMS_DATA',
1103
- path: '$.ADD_TASK.name'
1104
- }
1105
- },
1106
- value: '',
1107
- validation: {
1108
- is_valid: false,
1109
- triggers: ['ON_INIT'],
1110
- rules: [
1111
- {
1112
- id: '1',
1113
- key: 'VALUE_CHECK',
1114
- props: {
1115
- value: {
1116
- source: {
1117
- key: 'OBJECT',
1118
- props: {
1119
- object: {
1120
- key: 'ALL_FORMS_DATA',
1121
- path: '$.ADD_TASK.name'
1122
- }
1123
- }
1124
- }
1125
- },
1126
- pattern: {
1127
- key: 'IS_NOT_EMPTY'
1128
- }
1129
- }
1130
- }
1131
- ],
1132
- actions: [
1133
- {
1134
- id: '1',
1135
- key: 'SET_FIELD_DEFAULT_VALUE',
1136
- condition: '1',
1137
- props: {
1138
- fieldKey: 'name',
1139
- value: {
1140
- source: {
1141
- key: 'OBJECT',
1142
- props: {
1143
- object: {
1144
- key: 'ALL_FORMS_DATA',
1145
- path: '$.ADD_TASK.name'
1146
- }
1147
- }
1148
- }
1149
- }
1150
- }
1151
- }
1152
- ]
1153
- }
1154
- }
1155
- ]
1156
- }
1157
- },
1158
- validators: {
1159
- required: true
1160
- },
1161
- properties: {
1162
- placeholder: 'Please enter the Customer Name',
1163
- readOnly: false,
1164
- case: 'default'
1165
- },
1166
- type: 'text'
1167
- },
1168
- {
1169
- key: 'phone',
1170
- label: 'Phone Number',
1171
- disabled: false,
1172
- messages: [],
1173
- default: {
1174
- value: {
1175
- is_found: false,
1176
- value: '',
1177
- sources: [
1178
- {
1179
- key: 'OBJECT',
1180
- props: {
1181
- object: {
1182
- key: 'ALL_FORMS_DATA',
1183
- path: '$.ADD_TASK.phone'
1184
- }
1185
- },
1186
- value: '',
1187
- validation: {
1188
- is_valid: false,
1189
- triggers: ['ON_INIT'],
1190
- rules: [
1191
- {
1192
- id: '1',
1193
- key: 'VALUE_CHECK',
1194
- props: {
1195
- value: {
1196
- source: {
1197
- key: 'OBJECT',
1198
- props: {
1199
- object: {
1200
- key: 'ALL_FORMS_DATA',
1201
- path: '$.ADD_TASK.phone'
1202
- }
1203
- }
1204
- }
1205
- },
1206
- pattern: {
1207
- key: 'IS_NOT_EMPTY'
1208
- }
1209
- }
1210
- }
1211
- ],
1212
- actions: [
1213
- {
1214
- id: '1',
1215
- key: 'SET_FIELD_DEFAULT_VALUE',
1216
- condition: '1',
1217
- props: {
1218
- fieldKey: 'phone',
1219
- value: {
1220
- source: {
1221
- key: 'OBJECT',
1222
- props: {
1223
- object: {
1224
- key: 'ALL_FORMS_DATA',
1225
- path: '$.ADD_TASK.phone'
1226
- }
1227
- }
1228
- }
1229
- }
1230
- }
1231
- }
1232
- ]
1233
- }
1234
- }
1235
- ]
1236
- }
645
+ {
646
+ key: 'phone',
647
+ label: 'Phone Number',
648
+ disabled: false,
649
+ messages: [],
650
+ default: {
651
+ value: {
652
+ is_found: false,
653
+ value: '',
654
+ sources: [
655
+ {
656
+ key: 'OBJECT',
657
+ props: {
658
+ object: {
659
+ key: 'ALL_FORMS_DATA',
660
+ path: '$.ADD_TASK.phone'
661
+ }
662
+ },
663
+ value: '',
664
+ validation: {
665
+ is_valid: false,
666
+ triggers: ['ON_INIT'],
667
+ rules: [
668
+ {
669
+ id: '1',
670
+ key: 'VALUE_CHECK',
671
+ props: {
672
+ value: {
673
+ source: {
674
+ key: 'OBJECT',
675
+ props: {
676
+ object: {
677
+ key: 'ALL_FORMS_DATA',
678
+ path: '$.ADD_TASK.phone'
679
+ }
680
+ }
681
+ }
682
+ },
683
+ pattern: {
684
+ key: 'IS_NOT_EMPTY'
685
+ }
686
+ }
687
+ }
688
+ ],
689
+ actions: [
690
+ {
691
+ id: '1',
692
+ key: 'SET_FIELD_DEFAULT_VALUE',
693
+ condition: '1',
694
+ props: {
695
+ fieldKey: 'phone',
696
+ value: {
697
+ source: {
698
+ key: 'OBJECT',
699
+ props: {
700
+ object: {
701
+ key: 'ALL_FORMS_DATA',
702
+ path: '$.ADD_TASK.phone'
703
+ }
704
+ }
705
+ }
706
+ }
707
+ }
708
+ }
709
+ ]
710
+ }
711
+ }
712
+ ]
713
+ }
1237
714
  },
1238
715
  validators: {
1239
716
  required: true
@@ -1487,28 +964,724 @@
1487
964
  },
1488
965
  type: 'text'
1489
966
  }
1490
- ],
1491
- properties: {
1492
- header: {
1493
- title: {
1494
- hidden: true,
1495
- label: 'Add Task'
1496
- },
1497
- steps: {
1498
- hidden: true
1499
- }
1500
- },
1501
- footer: {
1502
- viewFormsButton: {
1503
- hidden: true,
1504
- label: 'View Forms'
1505
- },
1506
- saveButton: {
1507
- hidden: false,
1508
- label: 'Submit'
967
+ ],
968
+ properties: {
969
+ header: {
970
+ title: {
971
+ hidden: true,
972
+ label: 'Add Task'
973
+ },
974
+ steps: {
975
+ hidden: true
976
+ }
977
+ },
978
+ footer: {
979
+ viewFormsButton: {
980
+ hidden: true,
981
+ label: 'View Forms'
982
+ },
983
+ saveButton: {
984
+ hidden: false,
985
+ label: 'Submit'
986
+ }
987
+ }
988
+ }
989
+ };
990
+ }
991
+ UserService.prototype.ngOnInit = function () { };
992
+ UserService.prototype.setAgentConfig = function (agentConfig) {
993
+ this.agentConfig = agentConfig;
994
+ };
995
+ UserService.prototype.toggleMapview = function () {
996
+ this.showMapview = !this.showMapview;
997
+ };
998
+ return UserService;
999
+ }());
1000
+ /** @nocollapse */ UserService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: UserService, deps: [], target: i0__namespace.ɵɵFactoryTarget.Injectable });
1001
+ /** @nocollapse */ UserService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: UserService, providedIn: 'root' });
1002
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: UserService, decorators: [{
1003
+ type: i0.Injectable,
1004
+ args: [{
1005
+ providedIn: 'root'
1006
+ }]
1007
+ }], ctorParameters: function () { return []; } });
1008
+
1009
+ var CustomerDetailsComponent = /** @class */ (function () {
1010
+ function CustomerDetailsComponent(userService) {
1011
+ this.userService = userService;
1012
+ this.customer = {
1013
+ agent_id: 'sparkcpaital_dev_agent_1',
1014
+ client_name: 'sparkcpaital_dev',
1015
+ extras: {},
1016
+ session_status: '',
1017
+ task_completed_time: '',
1018
+ task_creation_time: '1679469532.340057',
1019
+ task_details: {
1020
+ customer_details: {
1021
+ email: 'gaurang.thakkar1997@gmail.com',
1022
+ phone: '9930607033',
1023
+ lc_lg_code: 'LC123456',
1024
+ branch_code: 'HDFC56475H',
1025
+ business_code: 'ABCD12345H'
1026
+ },
1027
+ link_details: {
1028
+ queryParams: {
1029
+ autoSendMobileOtp: true,
1030
+ client_id: 'sparkcpaital_dev',
1031
+ mobileOtpVerification: true,
1032
+ mobile_number: '9930607033',
1033
+ user_id: '9930607033'
1034
+ }
1035
+ }
1036
+ },
1037
+ task_id: 'sparkcpaital_dev_4632c291-1b4c-4f5b-bb95-f9acaab45e27',
1038
+ task_schedule_time: '1679469532.340057',
1039
+ user_id: '9930607033'
1040
+ };
1041
+ this.viewTaskDetails = [];
1042
+ this.nextStep = new i0.EventEmitter();
1043
+ this.removeTask = new i0.EventEmitter();
1044
+ }
1045
+ CustomerDetailsComponent.prototype.ngOnInit = function () {
1046
+ var _a, _b, _c;
1047
+ this.viewTaskDetails =
1048
+ (_c = (_b = (_a = this.agentConfig) === null || _a === void 0 ? void 0 : _a.dashboardConfig) === null || _b === void 0 ? void 0 : _b.viewTaskDetails) !== null && _c !== void 0 ? _c : this.viewTaskDetails;
1049
+ };
1050
+ CustomerDetailsComponent.prototype.convertToTitleCase = function (inputString) {
1051
+ inputString = inputString.replace('$.task_details.customer_details.', '');
1052
+ var words = inputString.split('_');
1053
+ var capitalizedWords = words.map(function (word) { return word.charAt(0).toUpperCase() + word.slice(1); });
1054
+ var titleCaseString = capitalizedWords.join(' ');
1055
+ return titleCaseString;
1056
+ };
1057
+ CustomerDetailsComponent.prototype.convertEpochToDate = function (epochTime) {
1058
+ if (typeof epochTime == 'string')
1059
+ epochTime = Number(epochTime);
1060
+ var date = new Date(epochTime * 1000); // Convert to milliseconds
1061
+ var day = date.getDate().toString().padStart(2, '0');
1062
+ var month = (date.getMonth() + 1).toString().padStart(2, '0'); // Months are zero-based
1063
+ var year = date.getFullYear().toString();
1064
+ return day + "-" + month + "-" + year;
1065
+ };
1066
+ CustomerDetailsComponent.prototype.getTaskDetails = function (taskData) {
1067
+ return kwikidToolkit.getObjectValueFromPath(this.customer, taskData);
1068
+ };
1069
+ CustomerDetailsComponent.prototype.goToMaps = function (location) {
1070
+ window.open("" + location, '_blank');
1071
+ };
1072
+ CustomerDetailsComponent.prototype.goToNextStep = function (e) {
1073
+ this.nextStep.emit(e);
1074
+ };
1075
+ CustomerDetailsComponent.prototype.close = function () {
1076
+ this.userService.showTaskDetails = undefined;
1077
+ };
1078
+ CustomerDetailsComponent.prototype.handleOnClickRemoveTask = function (task) {
1079
+ this.removeTask.emit(task);
1080
+ };
1081
+ return CustomerDetailsComponent;
1082
+ }());
1083
+ /** @nocollapse */ CustomerDetailsComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerDetailsComponent, deps: [{ token: UserService }], target: i0__namespace.ɵɵFactoryTarget.Component });
1084
+ /** @nocollapse */ CustomerDetailsComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: CustomerDetailsComponent, selector: "customer-details", inputs: { customer: "customer", agentConfig: "agentConfig" }, outputs: { nextStep: "nextStep", removeTask: "removeTask" }, ngImport: i0__namespace, template: "<div class=\"customer-details-wrapper\">\n <div class=\"customer-details-heading\">\n Task Details\n </div>\n <div class=\"customer-details-body\">\n <div class=\"customer-details-user-id\">{{ customer.user_id }}</div>\n\n <div class=\"customer-details-table\">\n <div\n class=\"customer-details-table-data\"\n *ngFor=\"let taskData of viewTaskDetails\"\n >\n <div class=\"customer-details-table-detail-value\">\n {{ getTaskDetails(taskData) }}\n </div>\n </div>\n </div>\n\n <div class=\"customer-details-date\">\n Task Created on: {{convertEpochToDate(customer.task_creation_time)}}\n </div>\n\n <div class=\"customer-details-actions\">\n <div class=\"customer-details-task-buttons\">\n <kwikui-button-icon\n *ngIf=\"agentConfig.dashboardConfig?.allowRemoveTask\"\n [icon]=\"'tuiIconTrash2'\"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"handleOnClickRemoveTask(customer)\"\n ></kwikui-button-icon>\n <kwikui-button-icon\n *ngIf=\"agentConfig.dashboardConfig?.showCopyLink\"\n icon=\"tuiIconCopy\"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"\n goToNextStep({ customer: customer, stepType: 'SHARE_JOURNEY_LINK' })\n \"\n ></kwikui-button-icon>\n </div>\n <div class=\"customer-details-journey-buttons\">\n <kwikui-button\n *ngIf=\"\n agentConfig.dashboardConfig?.showMaps &&\n customer?.task_details?.customer_details?.location\n \"\n label=\"Show Directions\"\n appearance=\"flat\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"goToMaps(customer?.task_details?.customer_details?.location)\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"\n agentConfig.dashboardConfig?.showStartJourneyButton &&\n customer.session_status !== 'complete' &&\n customer.session_status !== ''\n \"\n label=\"Edit Journey\"\n appearance=\"primary\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"\n goToNextStep({ customer: customer, stepType: 'EDIT_JOURNEY' })\n \"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"\n agentConfig.dashboardConfig?.showStartJourneyButton &&\n customer.session_status == ''\n \"\n label=\"Start Journey\"\n appearance=\"primary\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"\n goToNextStep({ customer: customer, stepType: 'START_JOURNEY' })\n \"\n ></kwikui-button>\n </div>\n </div>\n </div>\n</div>\n", styles: [".customer-details-wrapper{display:flex;flex-direction:column;align-items:stretch;overflow:hidden;grid-gap:.5rem;gap:.5rem;padding:1.5rem;height:100%;width:100%}.customer-details-wrapper .customer-details-heading{display:flex;flex-direction:row;justify-content:space-between;align-items:center;padding:1rem 0;font-size:1.5rem;font-weight:600}.customer-details-wrapper .customer-details-body{display:flex;flex-direction:column;grid-gap:1.25rem;gap:1.25rem}.customer-details-wrapper .customer-details-body .customer-details-user-id{font-size:1.25rem;font-weight:500;padding:.5rem 0}.customer-details-wrapper .customer-details-body .customer-details-table{display:flex;grid-gap:.5rem;gap:.5rem;flex-direction:column}.customer-details-wrapper .customer-details-body .customer-details-table .customer-details-table-data .customer-details-table-detail-name{font-weight:500}.customer-details-wrapper .customer-details-body .customer-details-table .customer-details-table-data .customer-details-table-detail-value{word-wrap:break-word}.customer-details-wrapper .customer-details-body .customer-details-date{padding-top:1rem}.customer-details-wrapper .customer-details-body .customer-details-actions{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center}.customer-details-wrapper .customer-details-body .customer-details-actions .customer-details-task-buttons{display:flex;flex-direction:row;align-items:center;justify-content:flex-start;padding:1rem 0}.customer-details-wrapper .customer-details-body .customer-details-actions .customer-details-journey-buttons{padding-right:.2rem;display:flex;flex-direction:row;grid-gap:.2rem;gap:.2rem;align-items:center;justify-content:flex-end}.customer-details-wrapper .customer-details-body .customer-details-actions .customer-details-journey-buttons .customer-share-link{font-size:.7rem}\n"], components: [{ type: i2__namespace.KwikUIButtonIconComponent, selector: "kwikui-button-icon", inputs: ["disabled", "id", "showLoader", "styles", "class", "type", "appearance", "icon", "shape", "size"], outputs: ["onClick"] }, { type: i2__namespace.KwikUIButtonComponent, selector: "kwikui-button", inputs: ["disabled", "id", "label", "showLoader", "styles", "class", "type", "appearance", "icon", "iconRight", "shape", "size"], outputs: ["onClick"] }], directives: [{ type: i6__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i6__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
1085
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerDetailsComponent, decorators: [{
1086
+ type: i0.Component,
1087
+ args: [{
1088
+ selector: 'customer-details',
1089
+ templateUrl: './customer-details.component.html',
1090
+ styleUrls: ['./customer-details.component.scss']
1091
+ }]
1092
+ }], ctorParameters: function () { return [{ type: UserService }]; }, propDecorators: { customer: [{
1093
+ type: i0.Input
1094
+ }], agentConfig: [{
1095
+ type: i0.Input
1096
+ }], nextStep: [{
1097
+ type: i0.Output
1098
+ }], removeTask: [{
1099
+ type: i0.Output
1100
+ }] } });
1101
+
1102
+ var InfoWindowService = /** @class */ (function () {
1103
+ function InfoWindowService(mapService) {
1104
+ this.mapService = mapService;
1105
+ this.config = {
1106
+ fields: {
1107
+ name: {
1108
+ label: 'Name',
1109
+ value: 'name',
1110
+ display: 'value',
1111
+ style: {
1112
+ fontSize: '1rem',
1113
+ fontWeight: 600
1114
+ }
1115
+ },
1116
+ phone: {
1117
+ label: 'Call',
1118
+ value: 'phone',
1119
+ display: 'label',
1120
+ style: {
1121
+ fontSize: '0.8rem',
1122
+ padding: '0.1rem 0',
1123
+ textAlign: 'justify'
1124
+ },
1125
+ icon: 'https://cdn-icons-png.flaticon.com/512/60/60720.png'
1126
+ },
1127
+ address: {
1128
+ label: 'Directions',
1129
+ value: 'address',
1130
+ display: 'label',
1131
+ style: {
1132
+ fontSize: '0.8rem',
1133
+ padding: '0.1rem 0'
1134
+ },
1135
+ icon: 'https://cdn-icons-png.flaticon.com/512/62/62516.png'
1136
+ }
1137
+ }
1138
+ };
1139
+ this.mainInfoWindowStyle = {
1140
+ display: 'flex',
1141
+ 'flex-direction': 'column',
1142
+ 'justify-content': 'center',
1143
+ 'align-items': 'stretch',
1144
+ gap: '0.5rem',
1145
+ padding: '0.5rem'
1146
+ };
1147
+ this.fieldDivStyle = {
1148
+ gap: ' 0.5rem',
1149
+ display: 'flex',
1150
+ 'flex-direction': 'row'
1151
+ };
1152
+ }
1153
+ InfoWindowService.prototype.getOpenMarker = function () {
1154
+ return this.openMarker;
1155
+ };
1156
+ InfoWindowService.prototype.setOpenMarker = function (value) {
1157
+ this.openMarker = value;
1158
+ };
1159
+ /**
1160
+ * @description
1161
+ * Wrapper method to show Customer Info Window
1162
+ *
1163
+ * @function showInfo
1164
+ * @func showInfo
1165
+ * @method showInfo
1166
+ */
1167
+ InfoWindowService.prototype.showCustomerInformation = function (customer, marker) {
1168
+ var map = this.mapService.map;
1169
+ var contentString = this.createInfoContent(customer);
1170
+ var infowindow = new google.maps.InfoWindow({
1171
+ content: contentString
1172
+ });
1173
+ this.addEventListeners(customer, infowindow);
1174
+ this.closeLastOpenedInfoWindow();
1175
+ infowindow.open(map, marker);
1176
+ this.lastInfoWindowOpened = infowindow;
1177
+ this.mapService.map = Object.assign(Object.assign({}, this.mapService.map), { center: marker.getPosition });
1178
+ // map.setCenter(marker.getPosition());
1179
+ return { infowindow: infowindow };
1180
+ };
1181
+ InfoWindowService.prototype.addEventListeners = function (customer, infowindow) {
1182
+ // chnage -
1183
+ var addressLink = "http://maps.google.com/?q=" + customer.extras.loc[0] + ", " + customer.extras.loc[1];
1184
+ google.maps.event.addListener(infowindow, 'domready', function () {
1185
+ document.getElementById('Call').addEventListener('click', function (e) {
1186
+ window.open("tel:" + customer.extras.phone, '_self');
1187
+ });
1188
+ document
1189
+ .getElementById('Directions')
1190
+ .addEventListener('click', function (e) {
1191
+ window.open("" + addressLink, '_blank');
1192
+ });
1193
+ document
1194
+ .getElementsByClassName('gm-ui-hover-effect')[0]
1195
+ .setAttribute('style', ' background: none;\
1196
+ display: block; \
1197
+ border: 0px; \
1198
+ margin: 0px; \
1199
+ padding: 0px; \
1200
+ text-transform: none; \
1201
+ appearance: none; \
1202
+ position: absolute; \
1203
+ cursor: pointer; \
1204
+ user-select: none; \
1205
+ top: 0px; \
1206
+ right: 0px; \
1207
+ width: 30px; \
1208
+ height: 30px; \
1209
+ ');
1210
+ });
1211
+ };
1212
+ /**
1213
+ * @description
1214
+ * Wrapper method to close Last Info Window
1215
+ *
1216
+ * @function closeLastOpenedInfoWindow
1217
+ * @func closeLastOpenedInfoWindow
1218
+ * @method closeLastOpenedInfoWindow
1219
+ */
1220
+ InfoWindowService.prototype.closeLastOpenedInfoWindow = function () {
1221
+ if (this.lastInfoWindowOpened) {
1222
+ this.lastInfoWindowOpened.close();
1223
+ }
1224
+ };
1225
+ /**
1226
+ * @description
1227
+ * Closes the previously opened info window.
1228
+ *
1229
+ * @function infoData
1230
+ * @func infoData
1231
+ * @method infoData
1232
+ */
1233
+ InfoWindowService.prototype.createInfoContent = function (customer) {
1234
+ var content = "<div style='padding:4px; font-family: Manrope;' >";
1235
+ content += this.createFields(customer, this.config.fields);
1236
+ content += '</div>';
1237
+ return content;
1238
+ };
1239
+ /**
1240
+ * @description
1241
+ * Wrapper method to create Fields Container
1242
+ *
1243
+ * @function createFields
1244
+ * @func createFields
1245
+ * @method createFields
1246
+ */
1247
+ InfoWindowService.prototype.createFields = function (customer, fields) {
1248
+ var e_1, _a;
1249
+ var _div = document.createElement('div');
1250
+ for (var property in this.mainInfoWindowStyle)
1251
+ _div.style[property] = this.mainInfoWindowStyle[property];
1252
+ try {
1253
+ for (var _b = __values(Object.keys(fields)), _c = _b.next(); !_c.done; _c = _b.next()) {
1254
+ var key = _c.value;
1255
+ var field = fields[key];
1256
+ var _fieldDiv = document.createElement('div');
1257
+ _fieldDiv.setAttribute('id', field.label);
1258
+ for (var property in this.fieldDivStyle)
1259
+ _fieldDiv.style[property] = this.fieldDivStyle[property];
1260
+ for (var property in field.style)
1261
+ _fieldDiv.style[property] = field.style[property];
1262
+ var string = field.display == 'label' ? field.label : customer.extras[field.value];
1263
+ if (field.icon) {
1264
+ var _icon = document.createElement('img');
1265
+ _icon.src = field.icon;
1266
+ _icon.style.width = field.style.fontSize;
1267
+ _icon.style.height = field.style.fontSize;
1268
+ _fieldDiv.appendChild(_icon);
1269
+ }
1270
+ var _fieldText = document.createElement('div');
1271
+ _fieldText.innerHTML = string;
1272
+ _fieldDiv.appendChild(_fieldText);
1273
+ _div.appendChild(_fieldDiv);
1274
+ }
1275
+ }
1276
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
1277
+ finally {
1278
+ try {
1279
+ if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
1280
+ }
1281
+ finally { if (e_1) throw e_1.error; }
1282
+ }
1283
+ return _div.outerHTML;
1284
+ };
1285
+ return InfoWindowService;
1286
+ }());
1287
+ /** @nocollapse */ InfoWindowService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: InfoWindowService, deps: [{ token: MapService }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
1288
+ /** @nocollapse */ InfoWindowService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: InfoWindowService, providedIn: 'root' });
1289
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: InfoWindowService, decorators: [{
1290
+ type: i0.Injectable,
1291
+ args: [{
1292
+ providedIn: 'root'
1293
+ }]
1294
+ }], ctorParameters: function () { return [{ type: MapService }]; } });
1295
+
1296
+ var EStatus;
1297
+ (function (EStatus) {
1298
+ EStatus["NOT_STARTED"] = "not started";
1299
+ EStatus["ON_GOING"] = "on going";
1300
+ EStatus["AUDITING"] = "auditing";
1301
+ EStatus["REJECTED"] = "rejected";
1302
+ EStatus["AFTER_AUDIT"] = "after audit";
1303
+ EStatus["COMPLETE"] = "complete";
1304
+ })(EStatus || (EStatus = {}));
1305
+ var VStatus = [
1306
+ EStatus.NOT_STARTED,
1307
+ EStatus.ON_GOING,
1308
+ EStatus.AUDITING,
1309
+ EStatus.REJECTED,
1310
+ EStatus.AFTER_AUDIT,
1311
+ EStatus.COMPLETE
1312
+ ];
1313
+
1314
+ var StatusPillComponent = /** @class */ (function () {
1315
+ function StatusPillComponent() {
1316
+ }
1317
+ StatusPillComponent.prototype.ngOnInit = function () {
1318
+ if (kwikidToolkit.isEmptyValue(this.status)) {
1319
+ this.status = EStatus.NOT_STARTED;
1320
+ }
1321
+ };
1322
+ StatusPillComponent.prototype.getStatusPillClass = function (status) {
1323
+ var newStatus = status.replace(' ', '-');
1324
+ return "status-pill " + newStatus;
1325
+ };
1326
+ return StatusPillComponent;
1327
+ }());
1328
+ /** @nocollapse */ StatusPillComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: StatusPillComponent, deps: [], target: i0__namespace.ɵɵFactoryTarget.Component });
1329
+ /** @nocollapse */ StatusPillComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: StatusPillComponent, selector: "status-pill", inputs: { status: "status" }, ngImport: i0__namespace, template: "<div [ngClass]=\"getStatusPillClass(status)\">{{status}}</div>\n", styles: [".status-pill{background-color:#555;padding:.1rem .5rem;border-radius:1rem;font-size:.7rem;color:#fff}.complete{background-color:var(--tui-positive)}.rejected{background-color:var(--tui-negative)}.auditing{background-color:var(--tui-primary)}.on-going{background-color:var(--tui-primary)}.after-audit{background-color:var(--tui-warning-fill);color:#222}\n"], directives: [{ type: i6__namespace.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
1330
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: StatusPillComponent, decorators: [{
1331
+ type: i0.Component,
1332
+ args: [{
1333
+ selector: 'status-pill',
1334
+ templateUrl: './status-pill.component.html',
1335
+ styleUrls: ['./status-pill.component.css']
1336
+ }]
1337
+ }], propDecorators: { status: [{
1338
+ type: i0.Input
1339
+ }] } });
1340
+
1341
+ var CustomerTileComponent = /** @class */ (function () {
1342
+ /**
1343
+ * @description
1344
+ *
1345
+ * @constructor
1346
+ */
1347
+ function CustomerTileComponent(mapService, infoWindowService, userService, hostElement) {
1348
+ this.mapService = mapService;
1349
+ this.infoWindowService = infoWindowService;
1350
+ this.userService = userService;
1351
+ this.hostElement = hostElement;
1352
+ /**
1353
+ * @description
1354
+ * Determines Customer Data
1355
+ *
1356
+ * @default
1357
+ * `{}`
1358
+ */
1359
+ this.customer = {};
1360
+ /**
1361
+ * @description
1362
+ * Determines Index of Customer Data in Customer List
1363
+ *
1364
+ * @default
1365
+ *
1366
+ */
1367
+ this.index = undefined;
1368
+ this.isMobileView = false;
1369
+ this.viewTaskDetails = [];
1370
+ /**
1371
+ * @description
1372
+ * Emitter to emit next Step
1373
+ *
1374
+ * @emits KwikIDAgentDashboardComponent#nextStep
1375
+ * @fires KwikIDAgentDashboardComponent#nextStep
1376
+ */
1377
+ this.nextStep = new i0.EventEmitter();
1378
+ this.removeTask = new i0.EventEmitter();
1379
+ }
1380
+ CustomerTileComponent.prototype.windowResizeWatcher = function () {
1381
+ if (this.hostElement.nativeElement.offsetWidth < 600) {
1382
+ this.isMobileView = true;
1383
+ }
1384
+ else {
1385
+ this.isMobileView = false;
1386
+ }
1387
+ };
1388
+ /**
1389
+ * @description
1390
+ * To set Google Maps API on script
1391
+ *
1392
+ * @ngOnInit
1393
+ */
1394
+ CustomerTileComponent.prototype.ngOnInit = function () {
1395
+ var _a, _b, _c;
1396
+ this.viewTaskDetails =
1397
+ (_c = (_b = (_a = this.agentConfig) === null || _a === void 0 ? void 0 : _a.dashboardConfig) === null || _b === void 0 ? void 0 : _b.viewTaskDetails) !== null && _c !== void 0 ? _c : this.viewTaskDetails;
1398
+ };
1399
+ CustomerTileComponent.prototype.getTaskDetails = function (taskData) {
1400
+ return kwikidToolkit.getObjectValueFromPath(this.customer, taskData);
1401
+ };
1402
+ CustomerTileComponent.prototype.openDetails = function () {
1403
+ if (this.userService.showTaskDetails !== this.index) {
1404
+ this.userService.showTaskDetails = this.index;
1405
+ }
1406
+ else {
1407
+ this.userService.showTaskDetails = undefined;
1408
+ }
1409
+ };
1410
+ CustomerTileComponent.prototype.tileClick = function () {
1411
+ this.openDetails();
1412
+ if (this.index == this.infoWindowService.getOpenMarker()) {
1413
+ this.infoWindowService.setOpenMarker(null);
1414
+ //this.infoWindowService.lastInfoWindowOpened.close();
1415
+ }
1416
+ else {
1417
+ this.showDetails(this.customer, this.index);
1418
+ }
1419
+ };
1420
+ /**
1421
+ * @description
1422
+ * Wrapper method to show Customer Info Window
1423
+ *
1424
+ * @function showDetails
1425
+ * @func showDetails
1426
+ * @method showDetails
1427
+ */
1428
+ CustomerTileComponent.prototype.showDetails = function (customer, index) {
1429
+ var markers = this.mapService.getMarkers();
1430
+ var marker = markers[index + 1];
1431
+ // let { infowindow } = this.infoWindowService.showCustomerInformation(
1432
+ // customer,
1433
+ // marker
1434
+ // );
1435
+ this.infoWindowService.setOpenMarker(index);
1436
+ };
1437
+ CustomerTileComponent.prototype.getClass = function () {
1438
+ var string = "customer-tile-wrapper";
1439
+ if (this.userService.showTaskDetails == this.index) {
1440
+ string += " customer-tile-active";
1441
+ }
1442
+ return string;
1443
+ };
1444
+ CustomerTileComponent.prototype.goToMaps = function (location) {
1445
+ window.open("" + location, '_blank');
1446
+ };
1447
+ CustomerTileComponent.prototype.goToNextStep = function (e) {
1448
+ this.nextStep.emit(e);
1449
+ };
1450
+ CustomerTileComponent.prototype.handleOnClickRemoveTask = function (task) {
1451
+ this.removeTask.emit(task);
1452
+ };
1453
+ return CustomerTileComponent;
1454
+ }());
1455
+ /** @nocollapse */ CustomerTileComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerTileComponent, deps: [{ token: MapService }, { token: InfoWindowService }, { token: UserService }, { token: i0__namespace.ElementRef }], target: i0__namespace.ɵɵFactoryTarget.Component });
1456
+ /** @nocollapse */ CustomerTileComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: CustomerTileComponent, selector: "customer-tile", inputs: { customer: "customer", index: "index", agentConfig: "agentConfig" }, outputs: { nextStep: "nextStep", removeTask: "removeTask" }, host: { listeners: { "window:resize": "windowResizeWatcher($event)" } }, viewQueries: [{ propertyName: "infoWindow", first: true, predicate: i5.MapInfoWindow, descendants: true }], ngImport: i0__namespace, template: "<div [ngClass]=\"getClass()\">\n <div class=\"customer-tile-primary-container\">\n <div class=\"customer-tile-primary-container-data\">\n <div class=\"customer-tile-primary-container-userid\">\n {{ customer.user_id }}\n </div>\n <status-pill\n *ngIf=\"agentConfig?.dashboardConfig?.showTaskStatus\"\n [status]=\"customer.session_status\"\n ></status-pill>\n </div>\n <kwikui-button-icon\n *ngIf=\"!userService.isMobileView && !userService.showMapview\"\n [icon]=\"\n userService.showTaskDetails==index\n ? 'tuiIconChevronLeftLarge'\n : 'tuiIconChevronRightLarge'\n \"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"openDetails()\"\n ></kwikui-button-icon>\n <kwikui-button-icon\n *ngIf=\"userService.isMobileView || userService.showMapview\"\n [icon]=\"\n userService.showTaskDetails==index\n ? 'tuiIconChevronUpLarge'\n : 'tuiIconChevronDownLarge'\n \"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"openDetails()\"\n ></kwikui-button-icon>\n </div>\n <div\n [ngClass]=\"\n index == userService.showTaskDetails && userService.isMobileView\n ? 'customer-tile-secondary-container'\n : 'data-collasped'\n \"\n >\n <div class=\"customer-tile-secondary-container-data\">\n <div\n *ngFor=\"let taskData of viewTaskDetails\"\n class=\"customer-tile-secondary-container-custom-details\"\n >\n {{ getTaskDetails(taskData) }}\n </div>\n </div>\n <div class=\"customer-tile-secondary-container-actions\">\n <div class=\"customer-tile-secondary-container-task-buttons\">\n <kwikui-button-icon\n *ngIf=\"agentConfig.dashboardConfig?.allowRemoveTask\"\n [icon]=\"'tuiIconTrash2'\"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"handleOnClickRemoveTask(customer)\"\n ></kwikui-button-icon>\n <kwikui-button-icon\n *ngIf=\"agentConfig.dashboardConfig?.showCopyLink\"\n icon=\"tuiIconCopy\"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"\n goToNextStep({ customer: customer, stepType: 'SHARE_JOURNEY_LINK' })\n \"\n ></kwikui-button-icon>\n </div>\n <div class=\"customer-tile-secondary-container-journey-buttons\">\n <kwikui-button\n *ngIf=\"\n agentConfig.dashboardConfig?.showMaps &&\n customer?.task_details?.customer_details?.location\n \"\n label=\"Show Directions\"\n appearance=\"flat\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"goToMaps(customer.task_details.customer_details.location)\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"\n agentConfig.dashboardConfig?.showStartJourneyButton &&\n customer.session_status !== 'complete' &&\n customer.session_status !== ''\n \"\n label=\"Edit Journey\"\n appearance=\"primary\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"\n goToNextStep({ customer: customer, stepType: 'EDIT_JOURNEY' })\n \"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"\n agentConfig.dashboardConfig?.showStartJourneyButton &&\n customer.session_status == ''\n \"\n label=\"Start Journey\"\n appearance=\"primary\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"\n goToNextStep({ customer: customer, stepType: 'START_JOURNEY' })\n \"\n ></kwikui-button>\n </div>\n </div>\n </div>\n</div>\n", styles: [".customer-tile-wrapper{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:stretch;flex:1;overflow:auto;grid-gap:.5rem;gap:.5rem;padding:1rem;border-bottom:.5px solid #ddd}.customer-tile-wrapper .customer-tile-primary-container{display:flex;grid-gap:.5rem;gap:.5rem;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;width:100%;height:100%}.customer-tile-wrapper .customer-tile-primary-container .customer-tile-primary-container-data{padding-left:.2rem;grid-gap:.6rem;gap:.6rem;display:flex;flex-direction:row;flex-wrap:wrap;align-content:stretch;justify-content:space-evenly;align-items:center}.customer-tile-wrapper .customer-tile-primary-container .customer-tile-primary-container-data .customer-tile-primary-container-userid{font-weight:500;font-size:1.1rem;line-height:1rem}.customer-tile-wrapper .customer-tile-secondary-container{width:100%;height:100%;display:flex;flex-direction:column;overflow:auto;grid-gap:.5rem;gap:.5rem}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-data{padding:.4rem .2rem;display:flex;flex-direction:column;font-size:.7rem;grid-gap:.3rem;gap:.3rem}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-data .customer-tile-secondary-container-custom-details{width:100%;height:100%;line-height:.9rem;word-wrap:break-word}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions .customer-tile-secondary-container-task-buttons{display:flex;flex-direction:row;align-items:center;justify-content:flex-start}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions .customer-tile-secondary-container-journey-buttons{padding-right:.2rem;display:flex;flex-direction:row;grid-gap:.2rem;gap:.2rem;align-items:center;justify-content:flex-end}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions .customer-tile-secondary-container-journey-buttons .customer-share-link{font-size:.7rem}.customer-tile-wrapper .data-collasped{display:none}.customer-tile-active{background-color:#dcedfd}\n"], components: [{ type: StatusPillComponent, selector: "status-pill", inputs: ["status"] }, { type: i2__namespace.KwikUIButtonIconComponent, selector: "kwikui-button-icon", inputs: ["disabled", "id", "showLoader", "styles", "class", "type", "appearance", "icon", "shape", "size"], outputs: ["onClick"] }, { type: i2__namespace.KwikUIButtonComponent, selector: "kwikui-button", inputs: ["disabled", "id", "label", "showLoader", "styles", "class", "type", "appearance", "icon", "iconRight", "shape", "size"], outputs: ["onClick"] }], directives: [{ type: i6__namespace.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i6__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i6__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
1457
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerTileComponent, decorators: [{
1458
+ type: i0.Component,
1459
+ args: [{
1460
+ selector: 'customer-tile',
1461
+ templateUrl: './customer-tile.component.html',
1462
+ styleUrls: ['./customer-tile.component.scss']
1463
+ }]
1464
+ }], ctorParameters: function () { return [{ type: MapService }, { type: InfoWindowService }, { type: UserService }, { type: i0__namespace.ElementRef }]; }, propDecorators: { windowResizeWatcher: [{
1465
+ type: i0.HostListener,
1466
+ args: ['window:resize', ['$event']]
1467
+ }], customer: [{
1468
+ type: i0.Input
1469
+ }], index: [{
1470
+ type: i0.Input
1471
+ }], agentConfig: [{
1472
+ type: i0.Input
1473
+ }], nextStep: [{
1474
+ type: i0.Output
1475
+ }], removeTask: [{
1476
+ type: i0.Output
1477
+ }], infoWindow: [{
1478
+ type: i0.ViewChild,
1479
+ args: [i5.MapInfoWindow]
1480
+ }] } });
1481
+
1482
+ var Ng2SearchPipe = /** @class */ (function () {
1483
+ function Ng2SearchPipe() {
1484
+ }
1485
+ /**
1486
+ * @param items object from array
1487
+ * @param term term's search
1488
+ * @param excludes array of strings which will ignored during search
1489
+ */
1490
+ Ng2SearchPipe.prototype.transform = function (items, term, excludes) {
1491
+ if (excludes === void 0) { excludes = []; }
1492
+ if (!term || !items)
1493
+ return items;
1494
+ return Ng2SearchPipe.filter(items, term, excludes);
1495
+ };
1496
+ /**
1497
+ *
1498
+ * @param items List of items to filter
1499
+ * @param term a string term to compare with every property of the list
1500
+ * @param excludes List of keys which will be ignored during search
1501
+ *
1502
+ */
1503
+ Ng2SearchPipe.filter = function (items, term, excludes) {
1504
+ var toCompare = term.toLowerCase();
1505
+ function checkInside(item, term) {
1506
+ if (typeof item === 'string' &&
1507
+ item.toString().toLowerCase().includes(toCompare)) {
1508
+ return true;
1509
+ }
1510
+ for (var property in item) {
1511
+ if (item[property] === null ||
1512
+ item[property] == undefined ||
1513
+ excludes.includes(property)) {
1514
+ continue;
1515
+ }
1516
+ if (typeof item[property] === 'object') {
1517
+ if (checkInside(item[property], term)) {
1518
+ return true;
1509
1519
  }
1510
1520
  }
1521
+ else if (item[property].toString().toLowerCase().includes(toCompare)) {
1522
+ return true;
1523
+ }
1511
1524
  }
1525
+ return false;
1526
+ }
1527
+ return items.filter(function (item) {
1528
+ return checkInside(item, term);
1529
+ });
1530
+ };
1531
+ return Ng2SearchPipe;
1532
+ }());
1533
+ /** @nocollapse */ Ng2SearchPipe.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: Ng2SearchPipe, deps: [], target: i0__namespace.ɵɵFactoryTarget.Pipe });
1534
+ /** @nocollapse */ Ng2SearchPipe.ɵpipe = i0__namespace.ɵɵngDeclarePipe({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: Ng2SearchPipe, name: "filter", pure: false });
1535
+ /** @nocollapse */ Ng2SearchPipe.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: Ng2SearchPipe });
1536
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: Ng2SearchPipe, decorators: [{
1537
+ type: i0.Pipe,
1538
+ args: [{
1539
+ name: 'filter',
1540
+ pure: false
1541
+ }]
1542
+ }, {
1543
+ type: i0.Injectable
1544
+ }] });
1545
+
1546
+ var CustomerListComponent = /** @class */ (function () {
1547
+ function CustomerListComponent(mapService) {
1548
+ this.mapService = mapService;
1549
+ this.nextStep = new i0.EventEmitter();
1550
+ this.removeTask = new i0.EventEmitter();
1551
+ this.filterTaskList = new i0.EventEmitter();
1552
+ this.filteredData = [];
1553
+ this.formGroup = new i5$1.FormGroup({});
1554
+ this.maxLength = { month: 1 };
1555
+ this.fromDate = this.getDate(null);
1556
+ this.toDate = this.getDate(null);
1557
+ this.dateRangeFormControl = new i5$1.FormControl({
1558
+ value: new i10.TuiDayRange(new i10.TuiDay(new Date().getFullYear(), new Date().getMonth(), new Date().getDate()), new i10.TuiDay(new Date().getFullYear(), new Date().getMonth(), new Date().getDate())),
1559
+ disabled: false
1560
+ });
1561
+ this.formGroup.addControl('dateRange', this.dateRangeFormControl);
1562
+ this.searchFormControl = new i5$1.FormControl('');
1563
+ this.formGroup.addControl('search', this.searchFormControl);
1564
+ }
1565
+ CustomerListComponent.prototype.ngOnInit = function () { };
1566
+ CustomerListComponent.prototype.ngAfterViewInit = function () {
1567
+ var _this = this;
1568
+ setTimeout(function () { return __awaiter(_this, void 0, void 0, function () {
1569
+ var _a;
1570
+ return __generator(this, function (_b) {
1571
+ switch (_b.label) {
1572
+ case 0:
1573
+ if (!this.agentConfig.dashboardConfig.showMaps) return [3 /*break*/, 3];
1574
+ return [4 /*yield*/, this.mapService.initMap()];
1575
+ case 1:
1576
+ _b.sent();
1577
+ _a = this;
1578
+ return [4 /*yield*/, this.plotMarkers(this.customers)];
1579
+ case 2:
1580
+ _a.filteredData = _b.sent();
1581
+ return [3 /*break*/, 4];
1582
+ case 3:
1583
+ this.filteredData = this.customers;
1584
+ _b.label = 4;
1585
+ case 4: return [2 /*return*/];
1586
+ }
1587
+ });
1588
+ }); }, 1000);
1589
+ };
1590
+ CustomerListComponent.prototype.ngOnChanges = function () {
1591
+ if (this.agentConfig.dashboardConfig.showMaps) {
1592
+ this.filteredData = this.plotMarkers(this.customers);
1593
+ }
1594
+ else {
1595
+ this.filteredData = this.customers;
1596
+ }
1597
+ };
1598
+ CustomerListComponent.prototype.goToNextStep = function (e) {
1599
+ this.nextStep.emit(e);
1600
+ };
1601
+ CustomerListComponent.prototype.getDate = function (d) {
1602
+ var date = d ? new Date(d) : new Date();
1603
+ var year = date.getFullYear();
1604
+ var month = date.getMonth() + 1;
1605
+ var day = date.getDate();
1606
+ if (month < 10)
1607
+ month = '0' + month;
1608
+ if (day < 10)
1609
+ day = '0' + day;
1610
+ var today = year + "-" + month + "-" + day;
1611
+ return today;
1612
+ };
1613
+ CustomerListComponent.prototype.plotMarkers = function (customers) {
1614
+ var _this = this;
1615
+ var directionsResults$ = this.mapService.plotMarkers(customers);
1616
+ directionsResults$.subscribe(function (val) {
1617
+ _this.filteredData = _this.mapService.sortList(val.routes[0].waypoint_order, customers);
1618
+ });
1619
+ return customers;
1620
+ };
1621
+ CustomerListComponent.prototype.getTuiDate = function (event) {
1622
+ var year = event.year;
1623
+ var month = event.month + 1;
1624
+ var date = event.day;
1625
+ month = month < 10 ? '0' + month : month;
1626
+ date = date < 10 ? '0' + date : date;
1627
+ return year + "-" + month + "-" + date;
1628
+ };
1629
+ CustomerListComponent.prototype.onDateRangeChange = function (event) {
1630
+ this.fromDate = this.getTuiDate(event.value.from);
1631
+ this.toDate = this.getTuiDate(event.value.to);
1632
+ this.handleOnFilterTaskList({
1633
+ from_date: this.fromDate,
1634
+ to_date: this.toDate
1635
+ });
1636
+ };
1637
+ CustomerListComponent.prototype.onSearchFilter = function (event) {
1638
+ this.searchText = event.value;
1639
+ };
1640
+ CustomerListComponent.prototype.handleOnClickRemoveTask = function (task) {
1641
+ this.removeTask.emit(task);
1642
+ };
1643
+ CustomerListComponent.prototype.handleOnFilterTaskList = function (filter) {
1644
+ this.filterTaskList.emit(filter);
1645
+ };
1646
+ return CustomerListComponent;
1647
+ }());
1648
+ /** @nocollapse */ CustomerListComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerListComponent, deps: [{ token: MapService }], target: i0__namespace.ɵɵFactoryTarget.Component });
1649
+ /** @nocollapse */ CustomerListComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: CustomerListComponent, selector: "customer-list", inputs: { customers: "customers", agentConfig: "agentConfig" }, outputs: { nextStep: "nextStep", removeTask: "removeTask", filterTaskList: "filterTaskList" }, usesOnChanges: true, ngImport: i0__namespace, template: "<div class=\"customer-list-wrapper\">\n <div class=\"customer-list-filter\" [formGroup]=\"formGroup\">\n <kwikui-input-date-range\n *ngIf=\"agentConfig?.dashboardConfig?.showDateFilter\"\n [label]=\"'Date Range'\"\n [id]=\"'dateRange'\"\n [size]=\"'m'\"\n [maxLength]=\"maxLength\"\n [formControlName]=\"'dateRange'\"\n [formControl]=\"dateRangeFormControl\"\n (getKeyValue)=\"onDateRangeChange($event)\"\n ></kwikui-input-date-range>\n <kwikui-input\n *ngIf=\"agentConfig?.dashboardConfig?.showSearchFilter\"\n [label]=\"'Search'\"\n [id]=\"'search'\"\n icon=\"tuiIconSearch\"\n size=\"m\"\n placeholder=\"Search Any Task\"\n [formControlName]=\"'search'\"\n [formControl]=\"searchFormControl\"\n (getKeyValue)=\"onSearchFilter($event)\"\n ></kwikui-input>\n </div>\n\n <div class=\"customer-task-list\">\n <cdk-virtual-scroll-viewport itemSize=\"1\" class=\"customer-task-list-scroll\">\n <div\n *cdkVirtualFor=\"\n let customer of filteredData | filter: searchText;\n index as index\n \"\n >\n <customer-tile\n class=\"example-item\"\n [customer]=\"customer\"\n [agentConfig]=\"agentConfig\"\n [index]=\"index\"\n (nextStep)=\"goToNextStep($event)\"\n (removeTask)=\"handleOnClickRemoveTask($event)\"\n ></customer-tile>\n </div>\n </cdk-virtual-scroll-viewport>\n </div>\n\n <div class=\"customer-list-empty\" *ngIf=\"filteredData.length === 0\">\n {{agentConfig?.dashboardConfig?.emptyTaskListMessage ?? '0 Tasks for the given Date.'}}\n </div>\n</div>\n", styles: [".customer-list-wrapper{width:100%;height:100%;display:flex;flex-direction:column}.customer-list-filter{height:-moz-fit-content;height:fit-content;width:100%;display:flex;flex-direction:column;padding:1rem;grid-gap:.8rem;gap:.8rem;border-bottom:.5px solid #ddd}.customer-list-empty{height:100%;width:100%;margin-top:.5rem;font-size:1rem;text-align:center}.customer-task-list{height:100%}.customer-task-list-scroll{height:100%;width:100%}.cdk-virtual-scroll-spacer{height:0!important}.example-item{height:50px}::-webkit-scrollbar{width:8px}::-webkit-scrollbar-track{border-radius:10px}::-webkit-scrollbar-thumb{background:lightgray;border-radius:10px}::-webkit-scrollbar-thumb:hover{background:gray}\n"], components: [{ type: i2__namespace.KwikUIInputDateRangeComponent, selector: "kwikui-input-date-range", inputs: ["label", "id", "formControlName", "formControl", "placeholder", "focus", "invalid", "disabled", "min", "minLength", "max", "maxLength", "size", "validators", "properties"], outputs: ["getKeyValue"] }, { type: i2__namespace.KwikUIInputComponent, selector: "kwikui-input", inputs: ["label", "id", "type", "formControlName", "formControl", "placeholder", "focus", "invalid", "disabled", "validators", "case", "size", "icon", "properties"], outputs: ["getKeyValue"] }, { type: i3__namespace.CdkVirtualScrollViewport, selector: "cdk-virtual-scroll-viewport", inputs: ["orientation", "appendOnly"], outputs: ["scrolledIndexChange"] }, { type: CustomerTileComponent, selector: "customer-tile", inputs: ["customer", "index", "agentConfig"], outputs: ["nextStep", "removeTask"] }], directives: [{ type: i5__namespace$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i5__namespace$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i6__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5__namespace$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i5__namespace$1.FormControlName, selector: "[formControlName]", inputs: ["disabled", "formControlName", "ngModel"], outputs: ["ngModelChange"] }, { type: i5__namespace$1.FormControlDirective, selector: "[formControl]", inputs: ["disabled", "formControl", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { type: i3__namespace.CdkFixedSizeVirtualScroll, selector: "cdk-virtual-scroll-viewport[itemSize]", inputs: ["itemSize", "minBufferPx", "maxBufferPx"] }, { type: i3__namespace.CdkVirtualForOf, selector: "[cdkVirtualFor][cdkVirtualForOf]", inputs: ["cdkVirtualForOf", "cdkVirtualForTrackBy", "cdkVirtualForTemplate", "cdkVirtualForTemplateCacheSize"] }], pipes: { "filter": Ng2SearchPipe } });
1650
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerListComponent, decorators: [{
1651
+ type: i0.Component,
1652
+ args: [{
1653
+ selector: 'customer-list',
1654
+ templateUrl: './customer-list.component.html',
1655
+ styleUrls: ['./customer-list.component.css']
1656
+ }]
1657
+ }], ctorParameters: function () { return [{ type: MapService }]; }, propDecorators: { customers: [{
1658
+ type: i0.Input
1659
+ }], agentConfig: [{
1660
+ type: i0.Input
1661
+ }], nextStep: [{
1662
+ type: i0.Output
1663
+ }], removeTask: [{
1664
+ type: i0.Output
1665
+ }], filterTaskList: [{
1666
+ type: i0.Output
1667
+ }] } });
1668
+
1669
+ var KwikIDAgentDashboardComponent = /** @class */ (function () {
1670
+ function KwikIDAgentDashboardComponent(mapService, userService, httpClient, hostElement, dialogService) {
1671
+ this.mapService = mapService;
1672
+ this.userService = userService;
1673
+ this.httpClient = httpClient;
1674
+ this.hostElement = hostElement;
1675
+ this.dialogService = dialogService;
1676
+ this.agentConfig = {};
1677
+ this.taskList = [];
1678
+ this.nextStep = new i0.EventEmitter();
1679
+ this.addTask = new i0.EventEmitter();
1680
+ this.removeTask = new i0.EventEmitter();
1681
+ this.filterTaskList = new i0.EventEmitter();
1682
+ this.loading = true;
1683
+ this.options = {
1684
+ stops: ['calc(5rem + 74vw)', 'calc(9rem + 74vw)']
1512
1685
  };
1513
1686
  this.open = false;
1514
1687
  this.allFormsData = {};
@@ -1517,12 +1690,28 @@
1517
1690
  .jsonp('https://maps.googleapis.com/maps/api/js?key=AIzaSyA63JY0ja6ZGIR796vJqZARc0c2j8Vgpik&v=3.exp&libraries=geometry,drawing,places', 'callback')
1518
1691
  .pipe(operators.map(function () { return true; }), operators.catchError(function () { return rxjs.of(false); }));
1519
1692
  }
1693
+ KwikIDAgentDashboardComponent.prototype.windowResizeWatcher = function () {
1694
+ if (this.hostElement.nativeElement.offsetWidth < 600) {
1695
+ this.isMobileView = true;
1696
+ this.userService.isMobileView = true;
1697
+ }
1698
+ else {
1699
+ this.isMobileView = false;
1700
+ this.userService.isMobileView = false;
1701
+ }
1702
+ };
1520
1703
  KwikIDAgentDashboardComponent.prototype.ngOnInit = function () {
1704
+ var _this = this;
1521
1705
  var _a, _b, _c, _d, _e, _f;
1522
- this.showMapview = (_c = (_b = (_a = this.agentConfig) === null || _a === void 0 ? void 0 : _a.dashboardConfig) === null || _b === void 0 ? void 0 : _b.showMaps) !== null && _c !== void 0 ? _c : false;
1523
- this.addTaskFormConfig =
1524
- (_f = (_e = (_d = this.agentConfig) === null || _d === void 0 ? void 0 : _d.dashboardConfig) === null || _e === void 0 ? void 0 : _e.addTaskFormConfig) !== null && _f !== void 0 ? _f : this.addTaskFormConfig;
1706
+ this.userService.agentConfig = this.agentConfig;
1707
+ this.userService.showMapview =
1708
+ (_c = (_b = (_a = this.agentConfig) === null || _a === void 0 ? void 0 : _a.dashboardConfig) === null || _b === void 0 ? void 0 : _b.showMaps) !== null && _c !== void 0 ? _c : false;
1709
+ this.userService.addTaskFormConfig =
1710
+ (_f = (_e = (_d = this.agentConfig) === null || _d === void 0 ? void 0 : _d.dashboardConfig) === null || _e === void 0 ? void 0 : _e.addTaskFormConfig) !== null && _f !== void 0 ? _f : this.userService.addTaskFormConfig;
1525
1711
  this.loading = false;
1712
+ setTimeout(function () {
1713
+ _this.windowResizeWatcher();
1714
+ }, 1000);
1526
1715
  };
1527
1716
  KwikIDAgentDashboardComponent.prototype.goToNextStep = function (e) {
1528
1717
  this.nextStep.emit(e);
@@ -1539,9 +1728,6 @@
1539
1728
  KwikIDAgentDashboardComponent.prototype.refresh = function () {
1540
1729
  window.location.reload();
1541
1730
  };
1542
- KwikIDAgentDashboardComponent.prototype.toggleMapview = function () {
1543
- this.showMapview = !this.showMapview;
1544
- };
1545
1731
  KwikIDAgentDashboardComponent.prototype.onClick = function () {
1546
1732
  this.open = !this.open;
1547
1733
  };
@@ -1567,8 +1753,8 @@
1567
1753
  KwikIDAgentDashboardComponent.prototype.handleOnClickViewForms = function (e) { };
1568
1754
  return KwikIDAgentDashboardComponent;
1569
1755
  }());
1570
- /** @nocollapse */ KwikIDAgentDashboardComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: KwikIDAgentDashboardComponent, deps: [{ token: MapService }, { token: i2__namespace.HttpClient }, { token: i0__namespace.ElementRef }, { token: i9.TuiDialogService }], target: i0__namespace.ɵɵFactoryTarget.Component });
1571
- /** @nocollapse */ KwikIDAgentDashboardComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: KwikIDAgentDashboardComponent, selector: "kwikid-agent-dashboard", inputs: { agentConfig: "agentConfig", taskList: "taskList" }, outputs: { nextStep: "nextStep", addTask: "addTask", removeTask: "removeTask", filterTaskList: "filterTaskList" }, viewQueries: [{ propertyName: "infoWindow", first: true, predicate: i4.MapInfoWindow, descendants: true }], ngImport: i0__namespace, template: "<div class=\"kwikid-agent-dashboard\" *ngIf=\"!loading\">\n <div class=\"wrapper\">\n <div class=\"dashboard-header\">\n <div class=\"dashboard-header-client-name\">\n <kwikui-button-icon\n [icon]=\"'tuiIconLink'\"\n appearance=\"mono\"\n size=\"m\"\n ></kwikui-button-icon>\n\n {{ agentConfig.clientName }}\n </div>\n <span (tuiActiveZoneChange)=\"onActiveZone($event)\">\n <kwikui-button-icon\n [icon]=\"'tuiIconSettingsLarge'\"\n (onClick)=\"onClick()\"\n appearance=\"mono\"\n size=\"m\"\n [tuiDropdown]=\"dropdownContent\"\n [tuiDropdownManual]=\"open\"\n (tuiObscured)=\"onObscured($event)\"\n ></kwikui-button-icon>\n <ng-template #dropdownContent>\n <div class=\"menu-dropdown\">\n <div class=\"menu-dropdown-header\">\n <div class=\"menu-dropdown-header-agent-name\">\n {{ agentConfig.agentName }}\n </div>\n <div class=\"menu-dropdown-header-agent-id\">\n Agent ID: {{ agentConfig.agentId }}\n </div>\n </div>\n <hr />\n <div\n class=\"menu-dropdown-body\"\n tuiGroup\n [collapsed]=\"true\"\n [rounded]=\"false\"\n [orientation]=\"'vertical'\"\n [size]=\"'m'\"\n >\n <kwikui-button\n *ngIf=\"this.agentConfig.dashboardConfig.showMaps\"\n id=\"\"\n label=\"{{ showMapview ? 'Hide Maps' : 'Show Maps' }}\"\n styles=\"\"\n class=\"menu-dropdown-buttons\"\n type=\"button\"\n appearance=\"mono\"\n icon=\"{{ showMapview ? 'tuiIconEyeOff' : 'tuiIconEye' }}\"\n iconRight=\"\"\n [shape]=\"null\"\n size=\"m\"\n styles=\"padding: 0rem !important\"\n (onClick)=\"toggleMapview()\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"this.agentConfig?.dashboardConfig?.allowAddTask\"\n id=\"\"\n label=\"Add Task\"\n styles=\"\"\n class=\"menu-dropdown-buttons\"\n type=\"button\"\n appearance=\"mono\"\n [icon]=\"'tuiIconAddRowLarge'\"\n iconRight=\"\"\n [shape]=\"null\"\n size=\"m\"\n (onClick)=\"showDialog(template)\"\n ></kwikui-button>\n <kwikui-button\n id=\"\"\n label=\"Refresh\"\n styles=\"\"\n class=\"menu-dropdown-buttons\"\n type=\"button\"\n appearance=\"mono\"\n [icon]=\"'tuiIconRefreshCw'\"\n iconRight=\"\"\n [shape]=\"null\"\n size=\"m\"\n (onClick)=\"refresh()\"\n ></kwikui-button>\n </div>\n <hr />\n <div class=\"menu-dropdown-footer\">\n <kwikui-button\n id=\"\"\n label=\"Logout\"\n styles=\"\"\n class=\"menu-dropdown-buttons\"\n type=\"button\"\n appearance=\"mono\"\n [icon]=\"'tuiIconLogOut'\"\n iconRight=\"\"\n [shape]=\"null\"\n size=\"m\"\n (onClick)=\"goToNextStep({ stepType: 'LOGOUT' })\"\n ></kwikui-button>\n </div>\n </div>\n </ng-template>\n </span>\n </div>\n\n <div class=\"dashboard-body\">\n <div\n *ngIf=\"apiLoaded | async\"\n [class]=\"showMapview ? 'map' : 'map-hidden'\"\n >\n <google-map height=\"100%\" width=\"100%\" [options]=\"this.mapService.map\">\n <map-marker\n #marker=\"mapMarker\"\n *ngFor=\"\n let markerPosition of this.mapService.markers;\n let index = index\n \"\n [position]=\"markerPosition\"\n [label]=\"{ text: String(index), color: '#FFF' }\"\n (mapClick)=\"openInfoWindow(marker)\"\n ></map-marker>\n <map-directions-renderer\n *ngIf=\"\n this.mapService.directionsResults$ | async as directionsResults\n \"\n [directions]=\"directionsResults\"\n [options]=\"this.mapService.directionsRenderOption\"\n ></map-directions-renderer>\n <map-info-window>Info Window content</map-info-window>\n </google-map>\n </div>\n <div class=\"customer-list\">\n <customer-list\n [customers]=\"taskList\"\n [agentConfig]=\"agentConfig\"\n (nextStep)=\"goToNextStep($event)\"\n (removeTask)=\"handleOnClickRemoveTask($event)\"\n (filterTaskList)=\"handleOnFilterTaskList($event)\"\n ></customer-list>\n </div>\n </div>\n </div>\n</div>\n<div class=\"kwikid-agent-dashboard-loader\" *ngIf=\"loading\">\n <span class=\"loader\"></span>\n</div>\n\n<ng-template #template let-observer>\n <div class=\"add-task-header\">\n <h2>Add Task</h2>\n <kwikui-button-icon\n icon=\"tuiIconX\"\n id=\"\"\n label=\"Close\"\n styles=\"\"\n type=\"button\"\n appearance=\"mono\"\n [shape]=\"null\"\n size=\"m\"\n (onClick)=\"observer.complete()\"\n ></kwikui-button-icon>\n </div>\n <kwikid-form-view\n [formConfig]=\"addTaskFormConfig\"\n [allFormsData]=\"allFormsData\"\n [isMobileView]=\"true\"\n (onClickViewForms)=\"this.handleOnClickViewForms($event)\"\n (onClickSaveForm)=\"this.handleOnClickSaveForm($event)\"\n ></kwikid-form-view>\n</ng-template>\n", styles: [".kwikid-agent-dashboard{display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;align-content:center;width:100%;height:100%;position:relative}.kwikid-agent-dashboard .wrapper{width:100%;height:100%;display:flex;flex-direction:column;align-content:center;justify-content:space-between;align-items:stretch}.kwikid-agent-dashboard .wrapper .dashboard-header{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;grid-column-gap:1rem;column-gap:1rem;padding:.2rem;max-height:max-content;border:1px solid #fafafa;box-shadow:0 2px 10px -6px #000}.kwikid-agent-dashboard .wrapper .dashboard-header .dashboard-header-client-name{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;font-size:1rem;font-weight:600}.kwikid-agent-dashboard .wrapper .dashboard-body{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:stretch;flex:1;overflow:auto}.kwikid-agent-dashboard .wrapper .dashboard-body .map{width:100%;height:100%;position:relative;overflow:hidden}.kwikid-agent-dashboard .wrapper .dashboard-body .map-hidden{visibility:collapse}.kwikid-agent-dashboard .wrapper .dashboard-body .customer-list{width:100%;height:100%;background-color:#fafafa;overflow:hidden}@media screen and (min-width: 600px){.kwikid-agent-dashboard{display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;align-content:center;width:100%;height:100%}.kwikid-agent-dashboard .wrapper{width:100%;height:100%;display:flex;flex-direction:column;align-content:center;justify-content:space-between;align-items:stretch}.kwikid-agent-dashboard .wrapper .dashboard-header{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;grid-column-gap:1rem;column-gap:1rem;padding:.2rem;max-height:max-content;border:1px solid #fafafa;box-shadow:0 2px 10px -6px #000}.kwikid-agent-dashboard .wrapper .dashboard-header .dashboard-header-client-name{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;font-size:1rem;font-weight:600}.kwikid-agent-dashboard .wrapper .dashboard-body{display:flex;flex-direction:row-reverse;align-content:center;justify-content:center;align-items:stretch;padding:1.5rem;grid-gap:1.5rem;gap:1.5rem;overflow:auto;background-color:#fafafa}.kwikid-agent-dashboard .wrapper .dashboard-body .map{width:100%;height:100%;position:relative;overflow:hidden;box-shadow:#0000001a 0 4px 6px -1px,#0000000f 0 2px 4px -1px;border-radius:.5rem}.kwikid-agent-dashboard .wrapper .dashboard-body .map-hidden{visibility:collapse}.kwikid-agent-dashboard .wrapper .dashboard-body .customer-list{min-width:300px;max-width:400px;width:100%;height:100%;overflow:hidden;box-shadow:#0000001a 0 4px 6px -1px,#0000000f 0 2px 4px -1px;border-radius:.5rem}}.menu{position:absolute;transition:\"0.15s linear 0s\"}.kwikid-agent-dashboard-loader{position:absolute;top:0;left:0;width:100%;height:100%;background:rgba(0,0,0,.75);display:flex;flex-direction:row;align-content:center;justify-content:center;align-items:center;z-index:100}.kwikid-agent-dashboard-loader .loader{width:48px;height:48px;border-radius:50%;display:inline-block;position:relative;border:3px solid;border-color:#fff #fff transparent;box-sizing:border-box;animation:rotation 1s linear infinite}.kwikid-agent-dashboard-loader .loader:after{content:\"\";box-sizing:border-box;position:absolute;left:0;right:0;top:0;bottom:0;margin:auto;border:3px solid;border-color:transparent var(--tui-primary) var(--tui-primary);width:24px;height:24px;border-radius:50%;animation:rotationBack .5s linear infinite;transform-origin:center center}@keyframes rotation{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes rotationBack{0%{transform:rotate(0)}to{transform:rotate(-360deg)}}.kwikid-agent-dashboard-loader .t-loader{display:none!important}.add-task-header{display:flex;flex-direction:row;justify-content:space-between;align-items:center;padding:.5rem 0 1rem 1rem}:host{width:100%;height:100%}::-webkit-scrollbar{width:8px}::-webkit-scrollbar-track{border-radius:10px}::-webkit-scrollbar-thumb{background:lightgray;border-radius:10px}::-webkit-scrollbar-thumb:hover{background:gray}.menu-dropdown{display:flex;flex-direction:column;justify-content:space-between;align-items:stretch;grid-gap:.5rem;gap:.5rem;padding:1rem 1.5rem}.menu-dropdown .menu-dropdown-header{display:flex;flex-direction:column;align-content:flex-start;justify-content:space-between;align-items:flex-start;grid-gap:1rem;gap:1rem}.menu-dropdown .menu-dropdown-header .menu-dropdown-header-agent-name{font-size:1.2rem;font-weight:600}.menu-dropdown .menu-dropdown-header .menu-dropdown-header-agent-id{font-size:.8rem;font-weight:600}.menu-dropdown .menu-dropdown-buttons ::ng-deep .t-wrapper{padding:0!important}\n"], components: [{ type: i4__namespace$1.KwikUIButtonIconComponent, selector: "kwikui-button-icon", inputs: ["disabled", "id", "showLoader", "styles", "class", "type", "appearance", "icon", "shape", "size"], outputs: ["onClick"] }, { type: i4__namespace$1.KwikUIButtonComponent, selector: "kwikui-button", inputs: ["disabled", "id", "label", "showLoader", "styles", "class", "type", "appearance", "icon", "iconRight", "shape", "size"], outputs: ["onClick"] }, { type: i4__namespace.GoogleMap, selector: "google-map", inputs: ["height", "width", "center", "zoom", "options", "mapTypeId"], outputs: ["authFailure", "boundsChanged", "centerChanged", "mapClick", "mapDblclick", "mapDrag", "mapDragend", "mapDragstart", "headingChanged", "idle", "maptypeidChanged", "mapMousemove", "mapMouseout", "mapMouseover", "projectionChanged", "mapRightclick", "tilesloaded", "tiltChanged", "zoomChanged"], exportAs: ["googleMap"] }, { type: CustomerListComponent, selector: "customer-list", inputs: ["customers", "agentConfig"], outputs: ["nextStep", "removeTask", "filterTaskList"] }, { type: i6__namespace.KwikIDFormViewComponent, selector: "kwikid-form-view", inputs: ["formConfig", "formData", "isMobileView", "allFormsData"], outputs: ["onClickViewForms", "onClickSaveForm", "onClickApiCall"] }], directives: [{ type: i5__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8__namespace.TuiActiveZoneDirective, selector: "[tuiActiveZone]:not(ng-container), [tuiActiveZoneChange]:not(ng-container), [tuiActiveZoneParent]:not(ng-container)", inputs: ["tuiActiveZoneParent"], outputs: ["tuiActiveZoneChange"], exportAs: ["tuiActiveZone"] }, { type: i9__namespace.TuiDropdownDirective, selector: "[tuiDropdown]:not(ng-container)", inputs: ["tuiDropdown"], exportAs: ["tuiDropdown"] }, { type: i9__namespace.TuiDropdownDriverDirective, selector: "[tuiDropdown]" }, { type: i9__namespace.TuiDropdownPositionDirective, selector: "[tuiDropdown]:not([tuiDropdownCustomPosition]):not([tuiDropdownSided])" }, { type: i9__namespace.TuiDropdownManualDirective, selector: "[tuiDropdown][tuiDropdownManual]", inputs: ["tuiDropdownManual"] }, { type: i9__namespace.TuiGroupDirective, selector: "[tuiGroup]:not(ng-container)", inputs: ["orientation", "adaptive", "collapsed", "rounded", "size"] }, { type: i5__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i4__namespace.MapMarker, selector: "map-marker", inputs: ["title", "position", "label", "clickable", "options", "icon", "visible"], outputs: ["animationChanged", "mapClick", "clickableChanged", "cursorChanged", "mapDblclick", "mapDrag", "mapDragend", "draggableChanged", "mapDragstart", "flatChanged", "iconChanged", "mapMousedown", "mapMouseout", "mapMouseover", "mapMouseup", "positionChanged", "mapRightclick", "shapeChanged", "titleChanged", "visibleChanged", "zindexChanged"], exportAs: ["mapMarker"] }, { type: i4__namespace.MapDirectionsRenderer, selector: "map-directions-renderer", inputs: ["directions", "options"], outputs: ["directionsChanged"], exportAs: ["mapDirectionsRenderer"] }, { type: i4__namespace.MapInfoWindow, selector: "map-info-window", inputs: ["options", "position"], outputs: ["closeclick", "contentChanged", "domready", "positionChanged", "zindexChanged"], exportAs: ["mapInfoWindow"] }], pipes: { "async": i5__namespace.AsyncPipe } });
1756
+ /** @nocollapse */ KwikIDAgentDashboardComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: KwikIDAgentDashboardComponent, deps: [{ token: MapService }, { token: UserService }, { token: i3__namespace$1.HttpClient }, { token: i0__namespace.ElementRef }, { token: i11.TuiDialogService }], target: i0__namespace.ɵɵFactoryTarget.Component });
1757
+ /** @nocollapse */ KwikIDAgentDashboardComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: KwikIDAgentDashboardComponent, selector: "kwikid-agent-dashboard", inputs: { agentConfig: "agentConfig", taskList: "taskList" }, outputs: { nextStep: "nextStep", addTask: "addTask", removeTask: "removeTask", filterTaskList: "filterTaskList" }, host: { listeners: { "window:resize": "windowResizeWatcher($event)" } }, viewQueries: [{ propertyName: "infoWindow", first: true, predicate: i5.MapInfoWindow, descendants: true }], ngImport: i0__namespace, template: "<div class=\"kwikid-agent-dashboard\" *ngIf=\"!loading\">\n <div class=\"wrapper\">\n <div class=\"dashboard-header\">\n <img\n *ngIf=\"userService.agentConfig.clientLogo && userService.agentConfig?.dashboardConfig?.showClientLogo\"\n [src]=\"userService.agentConfig.clientLogo\"\n class=\"dashboard-header-client-logo\"\n />\n <div\n *ngIf=\"!userService.agentConfig.clientLogo || !userService.agentConfig?.dashboardConfig?.showClientLogo\"\n class=\"dashboard-header-client-name\"\n >\n <kwikui-button-icon\n [icon]=\"'tuiIconLink'\"\n appearance=\"mono\"\n size=\"m\"\n ></kwikui-button-icon>\n\n {{ userService.agentConfig.clientName }}\n </div>\n <div>\n <kwikui-button-icon\n *ngIf=\"userService.agentConfig?.dashboardConfig?.allowAddTask\"\n class=\"menu-dropdown-buttons\"\n type=\"button\"\n appearance=\"mono\"\n [icon]=\"'tuiIconAddRowLarge'\"\n iconRight=\"\"\n [shape]=\"null\"\n size=\"m\"\n (onClick)=\"showDialog(template)\"\n ></kwikui-button-icon>\n <span (tuiActiveZoneChange)=\"onActiveZone($event)\">\n <kwikui-button-icon\n [icon]=\"'tuiIconSettingsLarge'\"\n (onClick)=\"onClick()\"\n appearance=\"mono\"\n size=\"m\"\n [tuiDropdown]=\"dropdownContent\"\n [tuiDropdownManual]=\"open\"\n (tuiObscured)=\"onObscured($event)\"\n ></kwikui-button-icon>\n <ng-template #dropdownContent>\n <div class=\"menu-dropdown\">\n <div class=\"menu-dropdown-header\">\n <div class=\"menu-dropdown-header-agent-name\">\n {{ userService.agentConfig.agentName }}\n </div>\n <div class=\"menu-dropdown-header-agent-id\">\n Agent ID: {{ userService.agentConfig.agentId }}\n </div>\n </div>\n <hr />\n <div\n class=\"menu-dropdown-body\"\n tuiGroup\n [collapsed]=\"true\"\n [rounded]=\"false\"\n [orientation]=\"'vertical'\"\n [size]=\"'m'\"\n >\n <kwikui-button\n *ngIf=\"this.agentConfig.dashboardConfig.showMaps\"\n id=\"\"\n label=\"{{\n userService.showMapview ? 'Hide Maps' : 'Show Maps'\n }}\"\n styles=\"\"\n class=\"menu-dropdown-buttons\"\n type=\"button\"\n appearance=\"mono\"\n icon=\"{{\n userService.showMapview ? 'tuiIconEyeOff' : 'tuiIconEye'\n }}\"\n iconRight=\"\"\n [shape]=\"null\"\n size=\"m\"\n styles=\"padding: 0rem !important\"\n (onClick)=\"userService.toggleMapview()\"\n ></kwikui-button>\n <kwikui-button\n id=\"\"\n label=\"Refresh\"\n styles=\"\"\n class=\"menu-dropdown-buttons\"\n type=\"button\"\n appearance=\"mono\"\n [icon]=\"'tuiIconRefreshCw'\"\n iconRight=\"\"\n [shape]=\"null\"\n size=\"m\"\n (onClick)=\"refresh()\"\n ></kwikui-button>\n </div>\n <div class=\"menu-dropdown-footer\">\n <kwikui-button\n id=\"\"\n label=\"Logout\"\n styles=\"\"\n class=\"menu-dropdown-buttons\"\n type=\"button\"\n appearance=\"mono\"\n [icon]=\"'tuiIconLogOut'\"\n iconRight=\"\"\n [shape]=\"null\"\n size=\"m\"\n (onClick)=\"goToNextStep({ stepType: 'LOGOUT' })\"\n ></kwikui-button>\n </div>\n </div>\n </ng-template>\n </span>\n </div>\n </div>\n\n <div class=\"dashboard-body\">\n <div\n *ngIf=\"apiLoaded | async\"\n [class]=\"userService.showMapview ? 'map' : 'map-hidden'\"\n >\n <google-map height=\"100%\" width=\"100%\" [options]=\"this.mapService.map\">\n <map-marker\n #marker=\"mapMarker\"\n *ngFor=\"\n let markerPosition of this.mapService.markers;\n let index = index\n \"\n [position]=\"markerPosition\"\n [label]=\"{ text: String(index), color: '#FFF' }\"\n (mapClick)=\"openInfoWindow(marker)\"\n ></map-marker>\n <map-directions-renderer\n *ngIf=\"\n this.mapService.directionsResults$ | async as directionsResults\n \"\n [directions]=\"directionsResults\"\n [options]=\"this.mapService.directionsRenderOption\"\n ></map-directions-renderer>\n <map-info-window>Info Window content</map-info-window>\n </google-map>\n </div>\n <div\n class=\"task-details\"\n *ngIf=\"\n !userService.isMobileView && userService.showTaskDetails != undefined\n \"\n >\n <customer-details\n [customer]=\"taskList[userService.showTaskDetails]\"\n [agentConfig]=\"agentConfig\"\n (nextStep)=\"goToNextStep($event)\"\n (removeTask)=\"handleOnClickRemoveTask($event)\"\n ></customer-details>\n </div>\n <div class=\"customer-list\">\n <customer-list\n [customers]=\"taskList\"\n [agentConfig]=\"agentConfig\"\n (nextStep)=\"goToNextStep($event)\"\n (removeTask)=\"handleOnClickRemoveTask($event)\"\n (filterTaskList)=\"handleOnFilterTaskList($event)\"\n ></customer-list>\n </div>\n </div>\n </div>\n</div>\n<div class=\"kwikid-agent-dashboard-loader\" *ngIf=\"loading\">\n <span class=\"loader\"></span>\n</div>\n\n<ng-template #template let-observer>\n <div class=\"add-task-header\">\n <h2>Add Task</h2>\n <kwikui-button-icon\n icon=\"tuiIconX\"\n id=\"\"\n label=\"Close\"\n styles=\"\"\n type=\"button\"\n appearance=\"mono\"\n [shape]=\"null\"\n size=\"m\"\n (onClick)=\"observer.complete()\"\n ></kwikui-button-icon>\n </div>\n <kwikid-form-view\n [formConfig]=\"userService.addTaskFormConfig\"\n [allFormsData]=\"allFormsData\"\n [isMobileView]=\"true\"\n (onClickViewForms)=\"this.handleOnClickViewForms($event)\"\n (onClickSaveForm)=\"this.handleOnClickSaveForm($event)\"\n ></kwikid-form-view>\n</ng-template>\n", styles: [".kwikid-agent-dashboard{display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;align-content:center;width:100%;height:100%;position:relative}.kwikid-agent-dashboard .wrapper{width:100%;height:100%;display:flex;flex-direction:column;align-content:center;justify-content:space-between;align-items:stretch}.kwikid-agent-dashboard .wrapper .dashboard-header{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;grid-column-gap:1rem;column-gap:1rem;padding:.2rem;max-height:max-content;border:1px solid #fafafa;box-shadow:0 2px 10px -6px #000}.kwikid-agent-dashboard .wrapper .dashboard-header .dashboard-header-client-logo{max-height:50px;padding-left:1rem}.kwikid-agent-dashboard .wrapper .dashboard-header .dashboard-header-client-name{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;font-size:1rem;font-weight:600}.kwikid-agent-dashboard .wrapper .dashboard-body{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:stretch;flex:1;overflow:auto}.kwikid-agent-dashboard .wrapper .dashboard-body .map{width:100%;height:100%;position:relative;overflow:hidden}.kwikid-agent-dashboard .wrapper .dashboard-body .map-hidden{visibility:collapse}.kwikid-agent-dashboard .wrapper .dashboard-body .customer-list{width:100%;height:100%;background-color:#fafafa;overflow:hidden}@media screen and (min-width: 600px){.kwikid-agent-dashboard{display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;align-content:center;width:100%;height:100%}.kwikid-agent-dashboard .wrapper{width:100%;height:100%;display:flex;flex-direction:column;align-content:center;justify-content:space-between;align-items:stretch}.kwikid-agent-dashboard .wrapper .dashboard-header{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;grid-column-gap:1rem;column-gap:1rem;padding:.2rem;max-height:max-content;border:1px solid #fafafa;box-shadow:0 2px 10px -6px #000}.kwikid-agent-dashboard .wrapper .dashboard-header .dashboard-header-client-name{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;font-size:1rem;font-weight:600}.kwikid-agent-dashboard .wrapper .dashboard-body{display:flex;flex-direction:row-reverse;align-content:center;justify-content:flex-end;align-items:stretch;padding:1.5rem;grid-gap:1.5rem;gap:1.5rem;overflow:auto;background-color:#fafafa}.kwikid-agent-dashboard .wrapper .dashboard-body .map{width:100%;height:100%;position:relative;overflow:hidden;box-shadow:#0000001a 0 4px 6px -1px,#0000000f 0 2px 4px -1px;border-radius:.5rem}.kwikid-agent-dashboard .wrapper .dashboard-body .map-hidden{visibility:collapse}.kwikid-agent-dashboard .wrapper .dashboard-body .task-details{width:100%;height:100%;position:relative;overflow:hidden;box-shadow:#0000001a 0 4px 6px -1px,#0000000f 0 2px 4px -1px;border-radius:.5rem}.kwikid-agent-dashboard .wrapper .dashboard-body .customer-list{min-width:300px;max-width:400px;width:100%;height:100%;overflow:hidden;box-shadow:#0000001a 0 4px 6px -1px,#0000000f 0 2px 4px -1px;border-radius:.5rem}}.menu{position:absolute;transition:\"0.15s linear 0s\"}.kwikid-agent-dashboard-loader{position:absolute;top:0;left:0;width:100%;height:100%;background:rgba(0,0,0,.75);display:flex;flex-direction:row;align-content:center;justify-content:center;align-items:center;z-index:100}.kwikid-agent-dashboard-loader .loader{width:48px;height:48px;border-radius:50%;display:inline-block;position:relative;border:3px solid;border-color:#fff #fff transparent;box-sizing:border-box;animation:rotation 1s linear infinite}.kwikid-agent-dashboard-loader .loader:after{content:\"\";box-sizing:border-box;position:absolute;left:0;right:0;top:0;bottom:0;margin:auto;border:3px solid;border-color:transparent var(--tui-primary) var(--tui-primary);width:24px;height:24px;border-radius:50%;animation:rotationBack .5s linear infinite;transform-origin:center center}@keyframes rotation{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes rotationBack{0%{transform:rotate(0)}to{transform:rotate(-360deg)}}.kwikid-agent-dashboard-loader .t-loader{display:none!important}.add-task-header{display:flex;flex-direction:row;justify-content:space-between;align-items:center;padding:.5rem 0 1rem 1rem}:host{width:100%;height:100%}::-webkit-scrollbar{width:8px}::-webkit-scrollbar-track{border-radius:10px}::-webkit-scrollbar-thumb{background:lightgray;border-radius:10px}::-webkit-scrollbar-thumb:hover{background:gray}.menu-dropdown{display:flex;flex-direction:column;justify-content:space-between;align-items:stretch;grid-gap:.5rem;gap:.5rem;padding:1rem 1.5rem}.menu-dropdown .menu-dropdown-header{display:flex;flex-direction:column;align-content:flex-start;justify-content:space-between;align-items:flex-start;grid-gap:1rem;gap:1rem}.menu-dropdown .menu-dropdown-header .menu-dropdown-header-agent-name{font-size:1.2rem;font-weight:600}.menu-dropdown .menu-dropdown-header .menu-dropdown-header-agent-id{font-size:.8rem;font-weight:600}.menu-dropdown .menu-dropdown-buttons ::ng-deep .t-wrapper{padding:0!important}\n"], components: [{ type: i2__namespace.KwikUIButtonIconComponent, selector: "kwikui-button-icon", inputs: ["disabled", "id", "showLoader", "styles", "class", "type", "appearance", "icon", "shape", "size"], outputs: ["onClick"] }, { type: i2__namespace.KwikUIButtonComponent, selector: "kwikui-button", inputs: ["disabled", "id", "label", "showLoader", "styles", "class", "type", "appearance", "icon", "iconRight", "shape", "size"], outputs: ["onClick"] }, { type: i5__namespace.GoogleMap, selector: "google-map", inputs: ["height", "width", "center", "zoom", "options", "mapTypeId"], outputs: ["authFailure", "boundsChanged", "centerChanged", "mapClick", "mapDblclick", "mapDrag", "mapDragend", "mapDragstart", "headingChanged", "idle", "maptypeidChanged", "mapMousemove", "mapMouseout", "mapMouseover", "projectionChanged", "mapRightclick", "tilesloaded", "tiltChanged", "zoomChanged"], exportAs: ["googleMap"] }, { type: CustomerDetailsComponent, selector: "customer-details", inputs: ["customer", "agentConfig"], outputs: ["nextStep", "removeTask"] }, { type: CustomerListComponent, selector: "customer-list", inputs: ["customers", "agentConfig"], outputs: ["nextStep", "removeTask", "filterTaskList"] }, { type: i8__namespace.KwikIDFormViewComponent, selector: "kwikid-form-view", inputs: ["formConfig", "formData", "isMobileView", "allFormsData", "userConfig", "popupFormCallback"], outputs: ["onClickGoBack", "onClickViewForms", "onClickSaveForm", "onClickApiCall", "onActionShowPopupForm"] }], directives: [{ type: i6__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i10__namespace.TuiActiveZoneDirective, selector: "[tuiActiveZone]:not(ng-container), [tuiActiveZoneChange]:not(ng-container), [tuiActiveZoneParent]:not(ng-container)", inputs: ["tuiActiveZoneParent"], outputs: ["tuiActiveZoneChange"], exportAs: ["tuiActiveZone"] }, { type: i11__namespace.TuiDropdownDirective, selector: "[tuiDropdown]:not(ng-container)", inputs: ["tuiDropdown"], exportAs: ["tuiDropdown"] }, { type: i11__namespace.TuiDropdownDriverDirective, selector: "[tuiDropdown]" }, { type: i11__namespace.TuiDropdownPositionDirective, selector: "[tuiDropdown]:not([tuiDropdownCustomPosition]):not([tuiDropdownSided])" }, { type: i11__namespace.TuiDropdownManualDirective, selector: "[tuiDropdown][tuiDropdownManual]", inputs: ["tuiDropdownManual"] }, { type: i11__namespace.TuiGroupDirective, selector: "[tuiGroup]:not(ng-container)", inputs: ["orientation", "adaptive", "collapsed", "rounded", "size"] }, { type: i6__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i5__namespace.MapMarker, selector: "map-marker", inputs: ["title", "position", "label", "clickable", "options", "icon", "visible"], outputs: ["animationChanged", "mapClick", "clickableChanged", "cursorChanged", "mapDblclick", "mapDrag", "mapDragend", "draggableChanged", "mapDragstart", "flatChanged", "iconChanged", "mapMousedown", "mapMouseout", "mapMouseover", "mapMouseup", "positionChanged", "mapRightclick", "shapeChanged", "titleChanged", "visibleChanged", "zindexChanged"], exportAs: ["mapMarker"] }, { type: i5__namespace.MapDirectionsRenderer, selector: "map-directions-renderer", inputs: ["directions", "options"], outputs: ["directionsChanged"], exportAs: ["mapDirectionsRenderer"] }, { type: i5__namespace.MapInfoWindow, selector: "map-info-window", inputs: ["options", "position"], outputs: ["closeclick", "contentChanged", "domready", "positionChanged", "zindexChanged"], exportAs: ["mapInfoWindow"] }], pipes: { "async": i6__namespace.AsyncPipe } });
1572
1758
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: KwikIDAgentDashboardComponent, decorators: [{
1573
1759
  type: i0.Component,
1574
1760
  args: [{
@@ -1577,11 +1763,14 @@
1577
1763
  styleUrls: ['./kwikid-agent-dashboard.component.scss']
1578
1764
  }]
1579
1765
  }], ctorParameters: function () {
1580
- return [{ type: MapService }, { type: i2__namespace.HttpClient }, { type: i0__namespace.ElementRef }, { type: i9__namespace.TuiDialogService, decorators: [{
1766
+ return [{ type: MapService }, { type: UserService }, { type: i3__namespace$1.HttpClient }, { type: i0__namespace.ElementRef }, { type: i11__namespace.TuiDialogService, decorators: [{
1581
1767
  type: i0.Inject,
1582
- args: [i9.TuiDialogService]
1768
+ args: [i11.TuiDialogService]
1583
1769
  }] }];
1584
- }, propDecorators: { agentConfig: [{
1770
+ }, propDecorators: { windowResizeWatcher: [{
1771
+ type: i0.HostListener,
1772
+ args: ['window:resize', ['$event']]
1773
+ }], agentConfig: [{
1585
1774
  type: i0.Input
1586
1775
  }], taskList: [{
1587
1776
  type: i0.Input
@@ -1595,7 +1784,7 @@
1595
1784
  type: i0.Output
1596
1785
  }], infoWindow: [{
1597
1786
  type: i0.ViewChild,
1598
- args: [i4.MapInfoWindow, { static: false }]
1787
+ args: [i5.MapInfoWindow, { static: false }]
1599
1788
  }] } });
1600
1789
 
1601
1790
  var KwikIDAgentDashboardModule = /** @class */ (function () {
@@ -1608,55 +1797,56 @@
1608
1797
  CustomerListComponent,
1609
1798
  CustomerTileComponent,
1610
1799
  Ng2SearchPipe,
1611
- StatusPillComponent], imports: [i5.CommonModule,
1612
- i2.HttpClientModule,
1800
+ StatusPillComponent,
1801
+ CustomerDetailsComponent], imports: [i6.CommonModule,
1802
+ i3$1.HttpClientModule,
1613
1803
  i5$1.FormsModule,
1614
1804
  i5$1.ReactiveFormsModule,
1615
- i4$1.KwikUIButtonModule,
1616
- i4$1.KwikUIButtonIconModule,
1617
- i4$1.KwikUIInputModule,
1618
- i4$1.KwikUIInputDateModule,
1619
- i4$1.KwikUIInputDateRangeModule,
1620
- i4$1.KwikUISelectComboboxModule,
1621
- i4$1.KwikUITableModule,
1622
- i4$1.KwikUITablePaginationModule,
1623
- i6.KwikIDFormViewModule,
1624
- i9.TuiRootModule,
1625
- i9.TuiDialogModule,
1626
- i9.TuiDropdownModule,
1805
+ i2.KwikUIButtonModule,
1806
+ i2.KwikUIButtonIconModule,
1807
+ i2.KwikUIInputModule,
1808
+ i2.KwikUIInputDateModule,
1809
+ i2.KwikUIInputDateRangeModule,
1810
+ i2.KwikUISelectComboboxModule,
1811
+ i2.KwikUITableModule,
1812
+ i2.KwikUITablePaginationModule,
1813
+ i8.KwikIDFormViewModule,
1814
+ i11.TuiRootModule,
1815
+ i11.TuiDialogModule,
1816
+ i11.TuiDropdownModule,
1627
1817
  addonMobile.TuiSidebarModule,
1628
- i8.TuiActiveZoneModule,
1629
- i9.TuiGroupModule,
1630
- i9.TuiSvgModule,
1818
+ i10.TuiActiveZoneModule,
1819
+ i11.TuiGroupModule,
1820
+ i11.TuiSvgModule,
1631
1821
  i3.ScrollingModule,
1632
- i4.GoogleMapsModule,
1633
- i2.HttpClientModule,
1634
- i2.HttpClientJsonpModule], exports: [KwikIDAgentDashboardComponent] });
1822
+ i5.GoogleMapsModule,
1823
+ i3$1.HttpClientModule,
1824
+ i3$1.HttpClientJsonpModule], exports: [KwikIDAgentDashboardComponent] });
1635
1825
  /** @nocollapse */ KwikIDAgentDashboardModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: KwikIDAgentDashboardModule, imports: [[
1636
- i5.CommonModule,
1637
- i2.HttpClientModule,
1826
+ i6.CommonModule,
1827
+ i3$1.HttpClientModule,
1638
1828
  i5$1.FormsModule,
1639
1829
  i5$1.ReactiveFormsModule,
1640
- i4$1.KwikUIButtonModule,
1641
- i4$1.KwikUIButtonIconModule,
1642
- i4$1.KwikUIInputModule,
1643
- i4$1.KwikUIInputDateModule,
1644
- i4$1.KwikUIInputDateRangeModule,
1645
- i4$1.KwikUISelectComboboxModule,
1646
- i4$1.KwikUITableModule,
1647
- i4$1.KwikUITablePaginationModule,
1648
- i6.KwikIDFormViewModule,
1649
- i9.TuiRootModule,
1650
- i9.TuiDialogModule,
1651
- i9.TuiDropdownModule,
1830
+ i2.KwikUIButtonModule,
1831
+ i2.KwikUIButtonIconModule,
1832
+ i2.KwikUIInputModule,
1833
+ i2.KwikUIInputDateModule,
1834
+ i2.KwikUIInputDateRangeModule,
1835
+ i2.KwikUISelectComboboxModule,
1836
+ i2.KwikUITableModule,
1837
+ i2.KwikUITablePaginationModule,
1838
+ i8.KwikIDFormViewModule,
1839
+ i11.TuiRootModule,
1840
+ i11.TuiDialogModule,
1841
+ i11.TuiDropdownModule,
1652
1842
  addonMobile.TuiSidebarModule,
1653
- i8.TuiActiveZoneModule,
1654
- i9.TuiGroupModule,
1655
- i9.TuiSvgModule,
1843
+ i10.TuiActiveZoneModule,
1844
+ i11.TuiGroupModule,
1845
+ i11.TuiSvgModule,
1656
1846
  i3.ScrollingModule,
1657
- i4.GoogleMapsModule,
1658
- i2.HttpClientModule,
1659
- i2.HttpClientJsonpModule
1847
+ i5.GoogleMapsModule,
1848
+ i3$1.HttpClientModule,
1849
+ i3$1.HttpClientJsonpModule
1660
1850
  ]] });
1661
1851
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: KwikIDAgentDashboardModule, decorators: [{
1662
1852
  type: i0.NgModule,
@@ -1666,33 +1856,34 @@
1666
1856
  CustomerListComponent,
1667
1857
  CustomerTileComponent,
1668
1858
  Ng2SearchPipe,
1669
- StatusPillComponent
1859
+ StatusPillComponent,
1860
+ CustomerDetailsComponent
1670
1861
  ],
1671
1862
  imports: [
1672
- i5.CommonModule,
1673
- i2.HttpClientModule,
1863
+ i6.CommonModule,
1864
+ i3$1.HttpClientModule,
1674
1865
  i5$1.FormsModule,
1675
1866
  i5$1.ReactiveFormsModule,
1676
- i4$1.KwikUIButtonModule,
1677
- i4$1.KwikUIButtonIconModule,
1678
- i4$1.KwikUIInputModule,
1679
- i4$1.KwikUIInputDateModule,
1680
- i4$1.KwikUIInputDateRangeModule,
1681
- i4$1.KwikUISelectComboboxModule,
1682
- i4$1.KwikUITableModule,
1683
- i4$1.KwikUITablePaginationModule,
1684
- i6.KwikIDFormViewModule,
1685
- i9.TuiRootModule,
1686
- i9.TuiDialogModule,
1687
- i9.TuiDropdownModule,
1867
+ i2.KwikUIButtonModule,
1868
+ i2.KwikUIButtonIconModule,
1869
+ i2.KwikUIInputModule,
1870
+ i2.KwikUIInputDateModule,
1871
+ i2.KwikUIInputDateRangeModule,
1872
+ i2.KwikUISelectComboboxModule,
1873
+ i2.KwikUITableModule,
1874
+ i2.KwikUITablePaginationModule,
1875
+ i8.KwikIDFormViewModule,
1876
+ i11.TuiRootModule,
1877
+ i11.TuiDialogModule,
1878
+ i11.TuiDropdownModule,
1688
1879
  addonMobile.TuiSidebarModule,
1689
- i8.TuiActiveZoneModule,
1690
- i9.TuiGroupModule,
1691
- i9.TuiSvgModule,
1880
+ i10.TuiActiveZoneModule,
1881
+ i11.TuiGroupModule,
1882
+ i11.TuiSvgModule,
1692
1883
  i3.ScrollingModule,
1693
- i4.GoogleMapsModule,
1694
- i2.HttpClientModule,
1695
- i2.HttpClientJsonpModule
1884
+ i5.GoogleMapsModule,
1885
+ i3$1.HttpClientModule,
1886
+ i3$1.HttpClientJsonpModule
1696
1887
  ],
1697
1888
  exports: [KwikIDAgentDashboardComponent]
1698
1889
  }]