kwikid-agent-dashboard 0.0.11 → 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,729 +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
- "$.task_details.customer_details.name",
795
- "$.task_details.customer_details.address"
796
- ];
797
- /**
798
- * @description
799
- * Emitter to emit next Step
800
- *
801
- * @emits KwikIDAgentDashboardComponent#nextStep
802
- * @fires KwikIDAgentDashboardComponent#nextStep
803
- */
804
- this.nextStep = new i0.EventEmitter();
805
- this.removeTask = new i0.EventEmitter();
806
- }
807
- /**
808
- * @description
809
- * To set Google Maps API on script
810
- *
811
- * @ngOnInit
812
- */
813
- CustomerTileComponent.prototype.ngOnInit = function () {
814
- var _a, _b, _c;
815
- 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;
816
- };
817
- CustomerTileComponent.prototype.getTaskDetails = function (taskData) {
818
- return kwikidToolkit.getObjectValueFromPath(this.customer, taskData);
819
- };
820
- CustomerTileComponent.prototype.tileClick = function () {
821
- if (this.index == this.infoWindowService.getOpenMarker()) {
822
- this.infoWindowService.setOpenMarker(null);
823
- //this.infoWindowService.lastInfoWindowOpened.close();
824
- }
825
- else {
826
- this.showDetails(this.customer, this.index);
827
- }
828
- };
829
- /**
830
- * @description
831
- * Wrapper method to show Customer Info Window
832
- *
833
- * @function showDetails
834
- * @func showDetails
835
- * @method showDetails
836
- */
837
- CustomerTileComponent.prototype.showDetails = function (customer, index) {
838
- var markers = this.mapService.getMarkers();
839
- var marker = markers[index + 1];
840
- // let { infowindow } = this.infoWindowService.showCustomerInformation(
841
- // customer,
842
- // marker
843
- // );
844
- this.infoWindowService.setOpenMarker(index);
845
- };
846
- CustomerTileComponent.prototype.goToMaps = function (location) {
847
- window.open("" + location, '_blank');
848
- };
849
- CustomerTileComponent.prototype.goToNextStep = function (e) {
850
- this.nextStep.emit(e);
851
- };
852
- CustomerTileComponent.prototype.handleOnClickRemoveTask = function (task) {
853
- this.removeTask.emit(task);
854
- };
855
- return CustomerTileComponent;
856
- }());
857
- /** @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 });
858
- /** @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 [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.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i5__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i5__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
859
- i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerTileComponent, decorators: [{
860
- type: i0.Component,
861
- args: [{
862
- selector: 'customer-tile',
863
- templateUrl: './customer-tile.component.html',
864
- styleUrls: ['./customer-tile.component.scss']
865
- }]
866
- }], ctorParameters: function () { return [{ type: MapService }, { type: InfoWindowService }]; }, propDecorators: { customer: [{
867
- type: i0.Input
868
- }], index: [{
869
- type: i0.Input
870
- }], agentConfig: [{
871
- type: i0.Input
872
- }], nextStep: [{
873
- type: i0.Output
874
- }], removeTask: [{
875
- type: i0.Output
876
- }], infoWindow: [{
877
- type: i0.ViewChild,
878
- args: [i4.MapInfoWindow]
879
- }] } });
880
-
881
- var Ng2SearchPipe = /** @class */ (function () {
882
- function Ng2SearchPipe() {
883
- }
884
- /**
885
- * @param items object from array
886
- * @param term term's search
887
- * @param excludes array of strings which will ignored during search
888
- */
889
- Ng2SearchPipe.prototype.transform = function (items, term, excludes) {
890
- if (excludes === void 0) { excludes = []; }
891
- if (!term || !items)
892
- return items;
893
- return Ng2SearchPipe.filter(items, term, excludes);
894
- };
895
- /**
896
- *
897
- * @param items List of items to filter
898
- * @param term a string term to compare with every property of the list
899
- * @param excludes List of keys which will be ignored during search
900
- *
901
- */
902
- Ng2SearchPipe.filter = function (items, term, excludes) {
903
- var toCompare = term.toLowerCase();
904
- function checkInside(item, term) {
905
- if (typeof item === 'string' &&
906
- item.toString().toLowerCase().includes(toCompare)) {
907
- return true;
908
- }
909
- for (var property in item) {
910
- if (item[property] === null ||
911
- item[property] == undefined ||
912
- excludes.includes(property)) {
913
- continue;
914
- }
915
- if (typeof item[property] === 'object') {
916
- if (checkInside(item[property], term)) {
917
- return true;
918
- }
919
- }
920
- else if (item[property].toString().toLowerCase().includes(toCompare)) {
921
- return true;
922
- }
923
- }
924
- return false;
925
- }
926
- return items.filter(function (item) {
927
- return checkInside(item, term);
928
- });
929
- };
930
- return Ng2SearchPipe;
931
- }());
932
- /** @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 });
933
- /** @nocollapse */ Ng2SearchPipe.ɵpipe = i0__namespace.ɵɵngDeclarePipe({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: Ng2SearchPipe, name: "filter", pure: false });
934
- /** @nocollapse */ Ng2SearchPipe.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: Ng2SearchPipe });
935
- i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: Ng2SearchPipe, decorators: [{
936
- type: i0.Pipe,
937
- args: [{
938
- name: 'filter',
939
- pure: false
940
- }]
941
- }, {
942
- type: i0.Injectable
943
- }] });
944
-
945
- var CustomerListComponent = /** @class */ (function () {
946
- function CustomerListComponent(mapService) {
947
- this.mapService = mapService;
948
- this.nextStep = new i0.EventEmitter();
949
- this.removeTask = new i0.EventEmitter();
950
- this.filterTaskList = new i0.EventEmitter();
951
- this.filteredData = [];
952
- this.formGroup = new i5$1.FormGroup({});
953
- this.maxLength = { month: 1 };
954
- this.fromDate = this.getDate(null);
955
- this.toDate = this.getDate(null);
956
- this.dateRangeFormControl = new i5$1.FormControl({
957
- 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())),
958
- disabled: false
959
- });
960
- this.formGroup.addControl('dateRange', this.dateRangeFormControl);
961
- this.searchFormControl = new i5$1.FormControl('');
962
- this.formGroup.addControl('search', this.searchFormControl);
963
- }
964
- CustomerListComponent.prototype.ngOnInit = function () { };
965
- CustomerListComponent.prototype.ngAfterViewInit = function () {
966
- var _this = this;
967
- setTimeout(function () { return __awaiter(_this, void 0, void 0, function () {
968
- var _a;
969
- return __generator(this, function (_b) {
970
- switch (_b.label) {
971
- case 0:
972
- if (!this.agentConfig.dashboardConfig.showMaps) return [3 /*break*/, 3];
973
- return [4 /*yield*/, this.mapService.initMap()];
974
- case 1:
975
- _b.sent();
976
- _a = this;
977
- return [4 /*yield*/, this.plotMarkers(this.customers)];
978
- case 2:
979
- _a.filteredData = _b.sent();
980
- return [3 /*break*/, 4];
981
- case 3:
982
- this.filteredData = this.customers;
983
- _b.label = 4;
984
- case 4: return [2 /*return*/];
985
- }
986
- });
987
- }); }, 1000);
988
- };
989
- CustomerListComponent.prototype.ngOnChanges = function () {
990
- if (this.agentConfig.dashboardConfig.showMaps) {
991
- this.filteredData = this.plotMarkers(this.customers);
992
- }
993
- else {
994
- this.filteredData = this.customers;
995
- }
996
- };
997
- CustomerListComponent.prototype.goToNextStep = function (e) {
998
- this.nextStep.emit(e);
999
- };
1000
- CustomerListComponent.prototype.getDate = function (d) {
1001
- var date = d ? new Date(d) : new Date();
1002
- var year = date.getFullYear();
1003
- var month = date.getMonth() + 1;
1004
- var day = date.getDate();
1005
- if (month < 10)
1006
- month = '0' + month;
1007
- if (day < 10)
1008
- day = '0' + day;
1009
- var today = year + "-" + month + "-" + day;
1010
- return today;
1011
- };
1012
- CustomerListComponent.prototype.plotMarkers = function (customers) {
1013
- var _this = this;
1014
- var directionsResults$ = this.mapService.plotMarkers(customers);
1015
- directionsResults$.subscribe(function (val) {
1016
- _this.filteredData = _this.mapService.sortList(val.routes[0].waypoint_order, customers);
1017
- });
1018
- return customers;
1019
- };
1020
- CustomerListComponent.prototype.getTuiDate = function (event) {
1021
- var year = event.year;
1022
- var month = event.month + 1;
1023
- var date = event.day;
1024
- month = month < 10 ? '0' + month : month;
1025
- date = date < 10 ? '0' + date : date;
1026
- return year + "-" + month + "-" + date;
1027
- };
1028
- CustomerListComponent.prototype.onDateRangeChange = function (event) {
1029
- this.fromDate = this.getTuiDate(event.value.from);
1030
- this.toDate = this.getTuiDate(event.value.to);
1031
- this.handleOnFilterTaskList({
1032
- from_date: this.fromDate,
1033
- to_date: this.toDate
1034
- });
1035
- };
1036
- CustomerListComponent.prototype.onSearchFilter = function (event) {
1037
- this.searchText = event.value;
1038
- };
1039
- CustomerListComponent.prototype.handleOnClickRemoveTask = function (task) {
1040
- this.removeTask.emit(task);
1041
- };
1042
- CustomerListComponent.prototype.handleOnFilterTaskList = function (filter) {
1043
- this.filterTaskList.emit(filter);
1044
- };
1045
- return CustomerListComponent;
1046
- }());
1047
- /** @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 });
1048
- /** @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 [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 [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$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"] }, { type: i5__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], pipes: { "filter": Ng2SearchPipe } });
1049
- i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerListComponent, decorators: [{
1050
- type: i0.Component,
1051
- args: [{
1052
- selector: 'customer-list',
1053
- templateUrl: './customer-list.component.html',
1054
- styleUrls: ['./customer-list.component.css']
1055
- }]
1056
- }], ctorParameters: function () { return [{ type: MapService }]; }, propDecorators: { customers: [{
1057
- type: i0.Input
1058
- }], agentConfig: [{
1059
- type: i0.Input
1060
- }], nextStep: [{
1061
- type: i0.Output
1062
- }], removeTask: [{
1063
- type: i0.Output
1064
- }], filterTaskList: [{
1065
- type: i0.Output
1066
- }] } });
1067
-
1068
- var KwikIDAgentDashboardComponent = /** @class */ (function () {
1069
- function KwikIDAgentDashboardComponent(mapService, httpClient, hostElement, dialogService) {
1070
- this.mapService = mapService;
1071
- this.httpClient = httpClient;
1072
- this.hostElement = hostElement;
1073
- this.dialogService = dialogService;
1074
- this.agentConfig = {};
1075
- this.taskList = [];
1076
- this.nextStep = new i0.EventEmitter();
1077
- this.addTask = new i0.EventEmitter();
1078
- this.removeTask = new i0.EventEmitter();
1079
- this.filterTaskList = new i0.EventEmitter();
1080
- this.loading = true;
1081
- this.showMapview = true;
1082
- this.isMobileView = false;
1083
- this.listOpen = true;
1084
- this.options = {
1085
- stops: ['calc(5rem + 74vw)', 'calc(9rem + 74vw)']
1086
- };
1087
- this.addTaskFormConfig = {
1088
- key: 'ADD_TASK',
1089
- title: 'Add Task',
1090
- fields: [
1091
- {
1092
- key: 'name',
1093
- label: 'Customer Name',
1094
- disabled: false,
1095
- messages: [],
1096
- default: {
1097
- value: {
1098
- is_found: false,
1099
- value: '',
1100
- sources: [
1101
- {
1102
- key: 'OBJECT',
1103
- props: {
1104
- object: {
1105
- key: 'ALL_FORMS_DATA',
1106
- path: '$.ADD_TASK.name'
1107
- }
1108
- },
1109
- value: '',
1110
- validation: {
1111
- is_valid: false,
1112
- triggers: ['ON_INIT'],
1113
- rules: [
1114
- {
1115
- id: '1',
1116
- key: 'VALUE_CHECK',
1117
- props: {
1118
- value: {
1119
- source: {
1120
- key: 'OBJECT',
1121
- props: {
1122
- object: {
1123
- key: 'ALL_FORMS_DATA',
1124
- path: '$.ADD_TASK.name'
1125
- }
1126
- }
1127
- }
1128
- },
1129
- pattern: {
1130
- key: 'IS_NOT_EMPTY'
1131
- }
1132
- }
1133
- }
1134
- ],
1135
- actions: [
1136
- {
1137
- id: '1',
1138
- key: 'SET_FIELD_DEFAULT_VALUE',
1139
- condition: '1',
1140
- props: {
1141
- fieldKey: 'name',
1142
- value: {
1143
- source: {
1144
- key: 'OBJECT',
1145
- props: {
1146
- object: {
1147
- key: 'ALL_FORMS_DATA',
1148
- path: '$.ADD_TASK.name'
1149
- }
1150
- }
1151
- }
1152
- }
1153
- }
1154
- }
1155
- ]
1156
- }
1157
- }
1158
- ]
1159
- }
1160
- },
1161
- validators: {
1162
- required: true
1163
- },
1164
- properties: {
1165
- placeholder: 'Please enter the Customer Name',
1166
- readOnly: false,
1167
- case: 'default'
1168
- },
1169
- type: 'text'
1170
- },
1171
- {
1172
- key: 'phone',
1173
- label: 'Phone Number',
1174
- disabled: false,
1175
- messages: [],
1176
- default: {
1177
- value: {
1178
- is_found: false,
1179
- value: '',
1180
- sources: [
1181
- {
1182
- key: 'OBJECT',
1183
- props: {
1184
- object: {
1185
- key: 'ALL_FORMS_DATA',
1186
- path: '$.ADD_TASK.phone'
1187
- }
1188
- },
1189
- value: '',
1190
- validation: {
1191
- is_valid: false,
1192
- triggers: ['ON_INIT'],
1193
- rules: [
1194
- {
1195
- id: '1',
1196
- key: 'VALUE_CHECK',
1197
- props: {
1198
- value: {
1199
- source: {
1200
- key: 'OBJECT',
1201
- props: {
1202
- object: {
1203
- key: 'ALL_FORMS_DATA',
1204
- path: '$.ADD_TASK.phone'
1205
- }
1206
- }
1207
- }
1208
- },
1209
- pattern: {
1210
- key: 'IS_NOT_EMPTY'
1211
- }
1212
- }
1213
- }
1214
- ],
1215
- actions: [
1216
- {
1217
- id: '1',
1218
- key: 'SET_FIELD_DEFAULT_VALUE',
1219
- condition: '1',
1220
- props: {
1221
- fieldKey: 'phone',
1222
- value: {
1223
- source: {
1224
- key: 'OBJECT',
1225
- props: {
1226
- object: {
1227
- key: 'ALL_FORMS_DATA',
1228
- path: '$.ADD_TASK.phone'
1229
- }
1230
- }
1231
- }
1232
- }
1233
- }
1234
- }
1235
- ]
1236
- }
1237
- }
1238
- ]
1239
- }
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
+ }
1240
714
  },
1241
715
  validators: {
1242
716
  required: true
@@ -1490,28 +964,724 @@
1490
964
  },
1491
965
  type: 'text'
1492
966
  }
1493
- ],
1494
- properties: {
1495
- header: {
1496
- title: {
1497
- hidden: true,
1498
- label: 'Add Task'
1499
- },
1500
- steps: {
1501
- hidden: true
1502
- }
1503
- },
1504
- footer: {
1505
- viewFormsButton: {
1506
- hidden: true,
1507
- label: 'View Forms'
1508
- },
1509
- saveButton: {
1510
- hidden: false,
1511
- 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;
1512
1519
  }
1513
1520
  }
1521
+ else if (item[property].toString().toLowerCase().includes(toCompare)) {
1522
+ return true;
1523
+ }
1514
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)']
1515
1685
  };
1516
1686
  this.open = false;
1517
1687
  this.allFormsData = {};
@@ -1520,12 +1690,28 @@
1520
1690
  .jsonp('https://maps.googleapis.com/maps/api/js?key=AIzaSyA63JY0ja6ZGIR796vJqZARc0c2j8Vgpik&v=3.exp&libraries=geometry,drawing,places', 'callback')
1521
1691
  .pipe(operators.map(function () { return true; }), operators.catchError(function () { return rxjs.of(false); }));
1522
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
+ };
1523
1703
  KwikIDAgentDashboardComponent.prototype.ngOnInit = function () {
1704
+ var _this = this;
1524
1705
  var _a, _b, _c, _d, _e, _f;
1525
- 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;
1526
- this.addTaskFormConfig =
1527
- (_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;
1528
1711
  this.loading = false;
1712
+ setTimeout(function () {
1713
+ _this.windowResizeWatcher();
1714
+ }, 1000);
1529
1715
  };
1530
1716
  KwikIDAgentDashboardComponent.prototype.goToNextStep = function (e) {
1531
1717
  this.nextStep.emit(e);
@@ -1542,9 +1728,6 @@
1542
1728
  KwikIDAgentDashboardComponent.prototype.refresh = function () {
1543
1729
  window.location.reload();
1544
1730
  };
1545
- KwikIDAgentDashboardComponent.prototype.toggleMapview = function () {
1546
- this.showMapview = !this.showMapview;
1547
- };
1548
1731
  KwikIDAgentDashboardComponent.prototype.onClick = function () {
1549
1732
  this.open = !this.open;
1550
1733
  };
@@ -1570,8 +1753,8 @@
1570
1753
  KwikIDAgentDashboardComponent.prototype.handleOnClickViewForms = function (e) { };
1571
1754
  return KwikIDAgentDashboardComponent;
1572
1755
  }());
1573
- /** @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 });
1574
- /** @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 } });
1575
1758
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: KwikIDAgentDashboardComponent, decorators: [{
1576
1759
  type: i0.Component,
1577
1760
  args: [{
@@ -1580,11 +1763,14 @@
1580
1763
  styleUrls: ['./kwikid-agent-dashboard.component.scss']
1581
1764
  }]
1582
1765
  }], ctorParameters: function () {
1583
- 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: [{
1584
1767
  type: i0.Inject,
1585
- args: [i9.TuiDialogService]
1768
+ args: [i11.TuiDialogService]
1586
1769
  }] }];
1587
- }, propDecorators: { agentConfig: [{
1770
+ }, propDecorators: { windowResizeWatcher: [{
1771
+ type: i0.HostListener,
1772
+ args: ['window:resize', ['$event']]
1773
+ }], agentConfig: [{
1588
1774
  type: i0.Input
1589
1775
  }], taskList: [{
1590
1776
  type: i0.Input
@@ -1598,7 +1784,7 @@
1598
1784
  type: i0.Output
1599
1785
  }], infoWindow: [{
1600
1786
  type: i0.ViewChild,
1601
- args: [i4.MapInfoWindow, { static: false }]
1787
+ args: [i5.MapInfoWindow, { static: false }]
1602
1788
  }] } });
1603
1789
 
1604
1790
  var KwikIDAgentDashboardModule = /** @class */ (function () {
@@ -1611,55 +1797,56 @@
1611
1797
  CustomerListComponent,
1612
1798
  CustomerTileComponent,
1613
1799
  Ng2SearchPipe,
1614
- StatusPillComponent], imports: [i5.CommonModule,
1615
- i2.HttpClientModule,
1800
+ StatusPillComponent,
1801
+ CustomerDetailsComponent], imports: [i6.CommonModule,
1802
+ i3$1.HttpClientModule,
1616
1803
  i5$1.FormsModule,
1617
1804
  i5$1.ReactiveFormsModule,
1618
- i4$1.KwikUIButtonModule,
1619
- i4$1.KwikUIButtonIconModule,
1620
- i4$1.KwikUIInputModule,
1621
- i4$1.KwikUIInputDateModule,
1622
- i4$1.KwikUIInputDateRangeModule,
1623
- i4$1.KwikUISelectComboboxModule,
1624
- i4$1.KwikUITableModule,
1625
- i4$1.KwikUITablePaginationModule,
1626
- i6.KwikIDFormViewModule,
1627
- i9.TuiRootModule,
1628
- i9.TuiDialogModule,
1629
- 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,
1630
1817
  addonMobile.TuiSidebarModule,
1631
- i8.TuiActiveZoneModule,
1632
- i9.TuiGroupModule,
1633
- i9.TuiSvgModule,
1818
+ i10.TuiActiveZoneModule,
1819
+ i11.TuiGroupModule,
1820
+ i11.TuiSvgModule,
1634
1821
  i3.ScrollingModule,
1635
- i4.GoogleMapsModule,
1636
- i2.HttpClientModule,
1637
- i2.HttpClientJsonpModule], exports: [KwikIDAgentDashboardComponent] });
1822
+ i5.GoogleMapsModule,
1823
+ i3$1.HttpClientModule,
1824
+ i3$1.HttpClientJsonpModule], exports: [KwikIDAgentDashboardComponent] });
1638
1825
  /** @nocollapse */ KwikIDAgentDashboardModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: KwikIDAgentDashboardModule, imports: [[
1639
- i5.CommonModule,
1640
- i2.HttpClientModule,
1826
+ i6.CommonModule,
1827
+ i3$1.HttpClientModule,
1641
1828
  i5$1.FormsModule,
1642
1829
  i5$1.ReactiveFormsModule,
1643
- i4$1.KwikUIButtonModule,
1644
- i4$1.KwikUIButtonIconModule,
1645
- i4$1.KwikUIInputModule,
1646
- i4$1.KwikUIInputDateModule,
1647
- i4$1.KwikUIInputDateRangeModule,
1648
- i4$1.KwikUISelectComboboxModule,
1649
- i4$1.KwikUITableModule,
1650
- i4$1.KwikUITablePaginationModule,
1651
- i6.KwikIDFormViewModule,
1652
- i9.TuiRootModule,
1653
- i9.TuiDialogModule,
1654
- 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,
1655
1842
  addonMobile.TuiSidebarModule,
1656
- i8.TuiActiveZoneModule,
1657
- i9.TuiGroupModule,
1658
- i9.TuiSvgModule,
1843
+ i10.TuiActiveZoneModule,
1844
+ i11.TuiGroupModule,
1845
+ i11.TuiSvgModule,
1659
1846
  i3.ScrollingModule,
1660
- i4.GoogleMapsModule,
1661
- i2.HttpClientModule,
1662
- i2.HttpClientJsonpModule
1847
+ i5.GoogleMapsModule,
1848
+ i3$1.HttpClientModule,
1849
+ i3$1.HttpClientJsonpModule
1663
1850
  ]] });
1664
1851
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: KwikIDAgentDashboardModule, decorators: [{
1665
1852
  type: i0.NgModule,
@@ -1669,33 +1856,34 @@
1669
1856
  CustomerListComponent,
1670
1857
  CustomerTileComponent,
1671
1858
  Ng2SearchPipe,
1672
- StatusPillComponent
1859
+ StatusPillComponent,
1860
+ CustomerDetailsComponent
1673
1861
  ],
1674
1862
  imports: [
1675
- i5.CommonModule,
1676
- i2.HttpClientModule,
1863
+ i6.CommonModule,
1864
+ i3$1.HttpClientModule,
1677
1865
  i5$1.FormsModule,
1678
1866
  i5$1.ReactiveFormsModule,
1679
- i4$1.KwikUIButtonModule,
1680
- i4$1.KwikUIButtonIconModule,
1681
- i4$1.KwikUIInputModule,
1682
- i4$1.KwikUIInputDateModule,
1683
- i4$1.KwikUIInputDateRangeModule,
1684
- i4$1.KwikUISelectComboboxModule,
1685
- i4$1.KwikUITableModule,
1686
- i4$1.KwikUITablePaginationModule,
1687
- i6.KwikIDFormViewModule,
1688
- i9.TuiRootModule,
1689
- i9.TuiDialogModule,
1690
- 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,
1691
1879
  addonMobile.TuiSidebarModule,
1692
- i8.TuiActiveZoneModule,
1693
- i9.TuiGroupModule,
1694
- i9.TuiSvgModule,
1880
+ i10.TuiActiveZoneModule,
1881
+ i11.TuiGroupModule,
1882
+ i11.TuiSvgModule,
1695
1883
  i3.ScrollingModule,
1696
- i4.GoogleMapsModule,
1697
- i2.HttpClientModule,
1698
- i2.HttpClientJsonpModule
1884
+ i5.GoogleMapsModule,
1885
+ i3$1.HttpClientModule,
1886
+ i3$1.HttpClientJsonpModule
1699
1887
  ],
1700
1888
  exports: [KwikIDAgentDashboardComponent]
1701
1889
  }]