kwikid-agent-dashboard 0.0.12 → 0.0.14

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