@tulipnpm/timekit_project_selector 3.0.0-rc.0 → 3.0.0-rc.1
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.
- package/dist/timekit_project_selector.js +220 -125
- package/dist/timekit_project_selector.min.js +1 -1
- package/package-lock.json +25103 -0
- package/package.json +1 -1
|
@@ -25455,13 +25455,52 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25455
25455
|
}() // New function
|
|
25456
25456
|
|
|
25457
25457
|
}, {
|
|
25458
|
-
key: "
|
|
25458
|
+
key: "getLocationByServices",
|
|
25459
25459
|
value: function () {
|
|
25460
|
-
var
|
|
25461
|
-
var
|
|
25460
|
+
var _getLocationByServices = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee7() {
|
|
25461
|
+
var serviceId,
|
|
25462
|
+
query,
|
|
25463
|
+
_args7 = arguments;
|
|
25462
25464
|
return regenerator_default().wrap(function _callee7$(_context7) {
|
|
25463
25465
|
while (1) {
|
|
25464
25466
|
switch (_context7.prev = _context7.next) {
|
|
25467
|
+
case 0:
|
|
25468
|
+
serviceId = _args7.length > 0 && _args7[0] !== undefined ? _args7[0] : null;
|
|
25469
|
+
query = this.getMetaQueryForLocations();
|
|
25470
|
+
|
|
25471
|
+
if (serviceId) {
|
|
25472
|
+
query = query + ";services.uuid:".concat(serviceId);
|
|
25473
|
+
}
|
|
25474
|
+
|
|
25475
|
+
_context7.next = 5;
|
|
25476
|
+
return this.getLocationsByMetaQuery(query);
|
|
25477
|
+
|
|
25478
|
+
case 5:
|
|
25479
|
+
return _context7.abrupt("return", _context7.sent);
|
|
25480
|
+
|
|
25481
|
+
case 6:
|
|
25482
|
+
case "end":
|
|
25483
|
+
return _context7.stop();
|
|
25484
|
+
}
|
|
25485
|
+
}
|
|
25486
|
+
}, _callee7, this);
|
|
25487
|
+
}));
|
|
25488
|
+
|
|
25489
|
+
function getLocationByServices() {
|
|
25490
|
+
return _getLocationByServices.apply(this, arguments);
|
|
25491
|
+
}
|
|
25492
|
+
|
|
25493
|
+
return getLocationByServices;
|
|
25494
|
+
}() // New function
|
|
25495
|
+
|
|
25496
|
+
}, {
|
|
25497
|
+
key: "getServiceLocations",
|
|
25498
|
+
value: function () {
|
|
25499
|
+
var _getServiceLocations = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee8(includePrivate) {
|
|
25500
|
+
var query;
|
|
25501
|
+
return regenerator_default().wrap(function _callee8$(_context8) {
|
|
25502
|
+
while (1) {
|
|
25503
|
+
switch (_context8.prev = _context8.next) {
|
|
25465
25504
|
case 0:
|
|
25466
25505
|
query = this.getMetaQueryForServiceLocations();
|
|
25467
25506
|
|
|
@@ -25469,18 +25508,18 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25469
25508
|
query = query + ';meta.t_private:0';
|
|
25470
25509
|
}
|
|
25471
25510
|
|
|
25472
|
-
|
|
25511
|
+
_context8.next = 4;
|
|
25473
25512
|
return this.getProjectsByMetaQuery(query);
|
|
25474
25513
|
|
|
25475
25514
|
case 4:
|
|
25476
|
-
return
|
|
25515
|
+
return _context8.abrupt("return", _context8.sent);
|
|
25477
25516
|
|
|
25478
25517
|
case 5:
|
|
25479
25518
|
case "end":
|
|
25480
|
-
return
|
|
25519
|
+
return _context8.stop();
|
|
25481
25520
|
}
|
|
25482
25521
|
}
|
|
25483
|
-
},
|
|
25522
|
+
}, _callee8, this);
|
|
25484
25523
|
}));
|
|
25485
25524
|
|
|
25486
25525
|
function getServiceLocations(_x5) {
|
|
@@ -25493,11 +25532,11 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25493
25532
|
}, {
|
|
25494
25533
|
key: "getServices",
|
|
25495
25534
|
value: function () {
|
|
25496
|
-
var _getServices = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function
|
|
25535
|
+
var _getServices = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee9(includePrivate) {
|
|
25497
25536
|
var query;
|
|
25498
|
-
return regenerator_default().wrap(function
|
|
25537
|
+
return regenerator_default().wrap(function _callee9$(_context9) {
|
|
25499
25538
|
while (1) {
|
|
25500
|
-
switch (
|
|
25539
|
+
switch (_context9.prev = _context9.next) {
|
|
25501
25540
|
case 0:
|
|
25502
25541
|
query = this.getMetaQueryForServices();
|
|
25503
25542
|
|
|
@@ -25505,18 +25544,18 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25505
25544
|
query = query + ';meta.t_private:0';
|
|
25506
25545
|
}
|
|
25507
25546
|
|
|
25508
|
-
|
|
25547
|
+
_context9.next = 4;
|
|
25509
25548
|
return this.getServicesByMetaQuery(query + '&include=locations');
|
|
25510
25549
|
|
|
25511
25550
|
case 4:
|
|
25512
|
-
return
|
|
25551
|
+
return _context9.abrupt("return", _context9.sent);
|
|
25513
25552
|
|
|
25514
25553
|
case 5:
|
|
25515
25554
|
case "end":
|
|
25516
|
-
return
|
|
25555
|
+
return _context9.stop();
|
|
25517
25556
|
}
|
|
25518
25557
|
}
|
|
25519
|
-
},
|
|
25558
|
+
}, _callee9, this);
|
|
25520
25559
|
}));
|
|
25521
25560
|
|
|
25522
25561
|
function getServices(_x6) {
|
|
@@ -25529,33 +25568,33 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25529
25568
|
}, {
|
|
25530
25569
|
key: "getStoreProjects",
|
|
25531
25570
|
value: function () {
|
|
25532
|
-
var _getStoreProjects = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function
|
|
25571
|
+
var _getStoreProjects = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee10() {
|
|
25533
25572
|
var storeQuery,
|
|
25534
25573
|
query,
|
|
25535
|
-
|
|
25536
|
-
return regenerator_default().wrap(function
|
|
25574
|
+
_args10 = arguments;
|
|
25575
|
+
return regenerator_default().wrap(function _callee10$(_context10) {
|
|
25537
25576
|
while (1) {
|
|
25538
|
-
switch (
|
|
25577
|
+
switch (_context10.prev = _context10.next) {
|
|
25539
25578
|
case 0:
|
|
25540
|
-
storeQuery =
|
|
25579
|
+
storeQuery = _args10.length > 0 && _args10[0] !== undefined ? _args10[0] : null;
|
|
25541
25580
|
query = this.getMetaQueryForStores();
|
|
25542
25581
|
|
|
25543
25582
|
if (storeQuery) {
|
|
25544
25583
|
query = query + ";".concat(storeQuery);
|
|
25545
25584
|
}
|
|
25546
25585
|
|
|
25547
|
-
|
|
25586
|
+
_context10.next = 5;
|
|
25548
25587
|
return this.getProjectsByMetaQuery(query);
|
|
25549
25588
|
|
|
25550
25589
|
case 5:
|
|
25551
|
-
return
|
|
25590
|
+
return _context10.abrupt("return", _context10.sent);
|
|
25552
25591
|
|
|
25553
25592
|
case 6:
|
|
25554
25593
|
case "end":
|
|
25555
|
-
return
|
|
25594
|
+
return _context10.stop();
|
|
25556
25595
|
}
|
|
25557
25596
|
}
|
|
25558
|
-
},
|
|
25597
|
+
}, _callee10, this);
|
|
25559
25598
|
}));
|
|
25560
25599
|
|
|
25561
25600
|
function getStoreProjects() {
|
|
@@ -25568,11 +25607,11 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25568
25607
|
}, {
|
|
25569
25608
|
key: "getStoreAppointmentProjects",
|
|
25570
25609
|
value: function () {
|
|
25571
|
-
var _getStoreAppointmentProjects = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function
|
|
25610
|
+
var _getStoreAppointmentProjects = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee11(includePrivate) {
|
|
25572
25611
|
var query;
|
|
25573
|
-
return regenerator_default().wrap(function
|
|
25612
|
+
return regenerator_default().wrap(function _callee11$(_context11) {
|
|
25574
25613
|
while (1) {
|
|
25575
|
-
switch (
|
|
25614
|
+
switch (_context11.prev = _context11.next) {
|
|
25576
25615
|
case 0:
|
|
25577
25616
|
query = this.getMetaQueryForServiceLocations();
|
|
25578
25617
|
|
|
@@ -25580,18 +25619,18 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25580
25619
|
query = query + ';meta.t_private:0';
|
|
25581
25620
|
}
|
|
25582
25621
|
|
|
25583
|
-
|
|
25622
|
+
_context11.next = 4;
|
|
25584
25623
|
return this.getProjectsByMetaQuery(query);
|
|
25585
25624
|
|
|
25586
25625
|
case 4:
|
|
25587
|
-
return
|
|
25626
|
+
return _context11.abrupt("return", _context11.sent);
|
|
25588
25627
|
|
|
25589
25628
|
case 5:
|
|
25590
25629
|
case "end":
|
|
25591
|
-
return
|
|
25630
|
+
return _context11.stop();
|
|
25592
25631
|
}
|
|
25593
25632
|
}
|
|
25594
|
-
},
|
|
25633
|
+
}, _callee11, this);
|
|
25595
25634
|
}));
|
|
25596
25635
|
|
|
25597
25636
|
function getStoreAppointmentProjects(_x7) {
|
|
@@ -25604,11 +25643,11 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25604
25643
|
}, {
|
|
25605
25644
|
key: "getGlobalAppointmentProjects",
|
|
25606
25645
|
value: function () {
|
|
25607
|
-
var _getGlobalAppointmentProjects = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function
|
|
25646
|
+
var _getGlobalAppointmentProjects = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee12(includePrivate) {
|
|
25608
25647
|
var query;
|
|
25609
|
-
return regenerator_default().wrap(function
|
|
25648
|
+
return regenerator_default().wrap(function _callee12$(_context12) {
|
|
25610
25649
|
while (1) {
|
|
25611
|
-
switch (
|
|
25650
|
+
switch (_context12.prev = _context12.next) {
|
|
25612
25651
|
case 0:
|
|
25613
25652
|
query = this.getMetaQueryForGlobalAppointments();
|
|
25614
25653
|
|
|
@@ -25616,18 +25655,18 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25616
25655
|
query = query + ';meta.t_private:0';
|
|
25617
25656
|
}
|
|
25618
25657
|
|
|
25619
|
-
|
|
25658
|
+
_context12.next = 4;
|
|
25620
25659
|
return this.getProjectsByMetaQuery(query);
|
|
25621
25660
|
|
|
25622
25661
|
case 4:
|
|
25623
|
-
return
|
|
25662
|
+
return _context12.abrupt("return", _context12.sent);
|
|
25624
25663
|
|
|
25625
25664
|
case 5:
|
|
25626
25665
|
case "end":
|
|
25627
|
-
return
|
|
25666
|
+
return _context12.stop();
|
|
25628
25667
|
}
|
|
25629
25668
|
}
|
|
25630
|
-
},
|
|
25669
|
+
}, _callee12, this);
|
|
25631
25670
|
}));
|
|
25632
25671
|
|
|
25633
25672
|
function getGlobalAppointmentProjects(_x8) {
|
|
@@ -25639,10 +25678,10 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25639
25678
|
}, {
|
|
25640
25679
|
key: "getGlobalAppointments",
|
|
25641
25680
|
value: function () {
|
|
25642
|
-
var _getGlobalAppointments = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function
|
|
25643
|
-
return regenerator_default().wrap(function
|
|
25681
|
+
var _getGlobalAppointments = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee13(includePrivate) {
|
|
25682
|
+
return regenerator_default().wrap(function _callee13$(_context13) {
|
|
25644
25683
|
while (1) {
|
|
25645
|
-
switch (
|
|
25684
|
+
switch (_context13.prev = _context13.next) {
|
|
25646
25685
|
case 0:
|
|
25647
25686
|
if (!includePrivate) {
|
|
25648
25687
|
query = query + 'meta.t_private:0';
|
|
@@ -25650,10 +25689,10 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25650
25689
|
|
|
25651
25690
|
case 1:
|
|
25652
25691
|
case "end":
|
|
25653
|
-
return
|
|
25692
|
+
return _context13.stop();
|
|
25654
25693
|
}
|
|
25655
25694
|
}
|
|
25656
|
-
},
|
|
25695
|
+
}, _callee13);
|
|
25657
25696
|
}));
|
|
25658
25697
|
|
|
25659
25698
|
function getGlobalAppointments(_x9) {
|
|
@@ -25666,34 +25705,34 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25666
25705
|
}, {
|
|
25667
25706
|
key: "getLocationsByMetaQuery",
|
|
25668
25707
|
value: function () {
|
|
25669
|
-
var _getLocationsByMetaQuery = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function
|
|
25708
|
+
var _getLocationsByMetaQuery = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee15(query) {
|
|
25670
25709
|
var _this = this;
|
|
25671
25710
|
|
|
25672
25711
|
var limit,
|
|
25673
|
-
|
|
25674
|
-
return regenerator_default().wrap(function
|
|
25712
|
+
_args15 = arguments;
|
|
25713
|
+
return regenerator_default().wrap(function _callee15$(_context15) {
|
|
25675
25714
|
while (1) {
|
|
25676
|
-
switch (
|
|
25715
|
+
switch (_context15.prev = _context15.next) {
|
|
25677
25716
|
case 0:
|
|
25678
|
-
limit =
|
|
25679
|
-
return
|
|
25680
|
-
var _ref = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function
|
|
25681
|
-
return regenerator_default().wrap(function
|
|
25717
|
+
limit = _args15.length > 1 && _args15[1] !== undefined ? _args15[1] : 100;
|
|
25718
|
+
return _context15.abrupt("return", this.timeKitPaginate( /*#__PURE__*/function () {
|
|
25719
|
+
var _ref = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee14(page) {
|
|
25720
|
+
return regenerator_default().wrap(function _callee14$(_context14) {
|
|
25682
25721
|
while (1) {
|
|
25683
|
-
switch (
|
|
25722
|
+
switch (_context14.prev = _context14.next) {
|
|
25684
25723
|
case 0:
|
|
25685
|
-
|
|
25724
|
+
_context14.next = 2;
|
|
25686
25725
|
return _this.getLocationsEndpoint("search=".concat(query, "&limit=").concat(limit, "&page=").concat(page));
|
|
25687
25726
|
|
|
25688
25727
|
case 2:
|
|
25689
|
-
return
|
|
25728
|
+
return _context14.abrupt("return", _context14.sent);
|
|
25690
25729
|
|
|
25691
25730
|
case 3:
|
|
25692
25731
|
case "end":
|
|
25693
|
-
return
|
|
25732
|
+
return _context14.stop();
|
|
25694
25733
|
}
|
|
25695
25734
|
}
|
|
25696
|
-
},
|
|
25735
|
+
}, _callee14);
|
|
25697
25736
|
}));
|
|
25698
25737
|
|
|
25699
25738
|
return function (_x11) {
|
|
@@ -25703,10 +25742,10 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25703
25742
|
|
|
25704
25743
|
case 2:
|
|
25705
25744
|
case "end":
|
|
25706
|
-
return
|
|
25745
|
+
return _context15.stop();
|
|
25707
25746
|
}
|
|
25708
25747
|
}
|
|
25709
|
-
},
|
|
25748
|
+
}, _callee15, this);
|
|
25710
25749
|
}));
|
|
25711
25750
|
|
|
25712
25751
|
function getLocationsByMetaQuery(_x10) {
|
|
@@ -25719,34 +25758,34 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25719
25758
|
}, {
|
|
25720
25759
|
key: "getServicesByMetaQuery",
|
|
25721
25760
|
value: function () {
|
|
25722
|
-
var _getServicesByMetaQuery = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function
|
|
25761
|
+
var _getServicesByMetaQuery = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee17(query) {
|
|
25723
25762
|
var _this2 = this;
|
|
25724
25763
|
|
|
25725
25764
|
var limit,
|
|
25726
|
-
|
|
25727
|
-
return regenerator_default().wrap(function
|
|
25765
|
+
_args17 = arguments;
|
|
25766
|
+
return regenerator_default().wrap(function _callee17$(_context17) {
|
|
25728
25767
|
while (1) {
|
|
25729
|
-
switch (
|
|
25768
|
+
switch (_context17.prev = _context17.next) {
|
|
25730
25769
|
case 0:
|
|
25731
|
-
limit =
|
|
25732
|
-
return
|
|
25733
|
-
var _ref2 = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function
|
|
25734
|
-
return regenerator_default().wrap(function
|
|
25770
|
+
limit = _args17.length > 1 && _args17[1] !== undefined ? _args17[1] : 100;
|
|
25771
|
+
return _context17.abrupt("return", this.timeKitPaginate( /*#__PURE__*/function () {
|
|
25772
|
+
var _ref2 = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee16(page) {
|
|
25773
|
+
return regenerator_default().wrap(function _callee16$(_context16) {
|
|
25735
25774
|
while (1) {
|
|
25736
|
-
switch (
|
|
25775
|
+
switch (_context16.prev = _context16.next) {
|
|
25737
25776
|
case 0:
|
|
25738
|
-
|
|
25777
|
+
_context16.next = 2;
|
|
25739
25778
|
return _this2.getServicesEndpoint("search=".concat(query, "&limit=").concat(limit, "&page=").concat(page));
|
|
25740
25779
|
|
|
25741
25780
|
case 2:
|
|
25742
|
-
return
|
|
25781
|
+
return _context16.abrupt("return", _context16.sent);
|
|
25743
25782
|
|
|
25744
25783
|
case 3:
|
|
25745
25784
|
case "end":
|
|
25746
|
-
return
|
|
25785
|
+
return _context16.stop();
|
|
25747
25786
|
}
|
|
25748
25787
|
}
|
|
25749
|
-
},
|
|
25788
|
+
}, _callee16);
|
|
25750
25789
|
}));
|
|
25751
25790
|
|
|
25752
25791
|
return function (_x13) {
|
|
@@ -25756,10 +25795,10 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25756
25795
|
|
|
25757
25796
|
case 2:
|
|
25758
25797
|
case "end":
|
|
25759
|
-
return
|
|
25798
|
+
return _context17.stop();
|
|
25760
25799
|
}
|
|
25761
25800
|
}
|
|
25762
|
-
},
|
|
25801
|
+
}, _callee17, this);
|
|
25763
25802
|
}));
|
|
25764
25803
|
|
|
25765
25804
|
function getServicesByMetaQuery(_x12) {
|
|
@@ -25771,34 +25810,34 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25771
25810
|
}, {
|
|
25772
25811
|
key: "getProjectsByMetaQuery",
|
|
25773
25812
|
value: function () {
|
|
25774
|
-
var _getProjectsByMetaQuery = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function
|
|
25813
|
+
var _getProjectsByMetaQuery = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee19(query) {
|
|
25775
25814
|
var _this3 = this;
|
|
25776
25815
|
|
|
25777
25816
|
var limit,
|
|
25778
|
-
|
|
25779
|
-
return regenerator_default().wrap(function
|
|
25817
|
+
_args19 = arguments;
|
|
25818
|
+
return regenerator_default().wrap(function _callee19$(_context19) {
|
|
25780
25819
|
while (1) {
|
|
25781
|
-
switch (
|
|
25820
|
+
switch (_context19.prev = _context19.next) {
|
|
25782
25821
|
case 0:
|
|
25783
|
-
limit =
|
|
25784
|
-
return
|
|
25785
|
-
var _ref3 = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function
|
|
25786
|
-
return regenerator_default().wrap(function
|
|
25822
|
+
limit = _args19.length > 1 && _args19[1] !== undefined ? _args19[1] : 100;
|
|
25823
|
+
return _context19.abrupt("return", this.timeKitPaginate( /*#__PURE__*/function () {
|
|
25824
|
+
var _ref3 = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee18(page) {
|
|
25825
|
+
return regenerator_default().wrap(function _callee18$(_context18) {
|
|
25787
25826
|
while (1) {
|
|
25788
|
-
switch (
|
|
25827
|
+
switch (_context18.prev = _context18.next) {
|
|
25789
25828
|
case 0:
|
|
25790
|
-
|
|
25829
|
+
_context18.next = 2;
|
|
25791
25830
|
return _this3.getProjects("search=".concat(query, "&limit=").concat(limit, "&page=").concat(page, "&include=locations"));
|
|
25792
25831
|
|
|
25793
25832
|
case 2:
|
|
25794
|
-
return
|
|
25833
|
+
return _context18.abrupt("return", _context18.sent);
|
|
25795
25834
|
|
|
25796
25835
|
case 3:
|
|
25797
25836
|
case "end":
|
|
25798
|
-
return
|
|
25837
|
+
return _context18.stop();
|
|
25799
25838
|
}
|
|
25800
25839
|
}
|
|
25801
|
-
},
|
|
25840
|
+
}, _callee18);
|
|
25802
25841
|
}));
|
|
25803
25842
|
|
|
25804
25843
|
return function (_x15) {
|
|
@@ -25808,10 +25847,10 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25808
25847
|
|
|
25809
25848
|
case 2:
|
|
25810
25849
|
case "end":
|
|
25811
|
-
return
|
|
25850
|
+
return _context19.stop();
|
|
25812
25851
|
}
|
|
25813
25852
|
}
|
|
25814
|
-
},
|
|
25853
|
+
}, _callee19, this);
|
|
25815
25854
|
}));
|
|
25816
25855
|
|
|
25817
25856
|
function getProjectsByMetaQuery(_x14) {
|
|
@@ -25824,34 +25863,34 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25824
25863
|
}, {
|
|
25825
25864
|
key: "getProjectsByMetaValue",
|
|
25826
25865
|
value: function () {
|
|
25827
|
-
var _getProjectsByMetaValue = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function
|
|
25866
|
+
var _getProjectsByMetaValue = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee21(key, value) {
|
|
25828
25867
|
var _this4 = this;
|
|
25829
25868
|
|
|
25830
25869
|
var limit,
|
|
25831
|
-
|
|
25832
|
-
return regenerator_default().wrap(function
|
|
25870
|
+
_args21 = arguments;
|
|
25871
|
+
return regenerator_default().wrap(function _callee21$(_context21) {
|
|
25833
25872
|
while (1) {
|
|
25834
|
-
switch (
|
|
25873
|
+
switch (_context21.prev = _context21.next) {
|
|
25835
25874
|
case 0:
|
|
25836
|
-
limit =
|
|
25837
|
-
return
|
|
25838
|
-
var _ref4 = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function
|
|
25839
|
-
return regenerator_default().wrap(function
|
|
25875
|
+
limit = _args21.length > 2 && _args21[2] !== undefined ? _args21[2] : 100;
|
|
25876
|
+
return _context21.abrupt("return", this.timeKitPaginate( /*#__PURE__*/function () {
|
|
25877
|
+
var _ref4 = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee20(page) {
|
|
25878
|
+
return regenerator_default().wrap(function _callee20$(_context20) {
|
|
25840
25879
|
while (1) {
|
|
25841
|
-
switch (
|
|
25880
|
+
switch (_context20.prev = _context20.next) {
|
|
25842
25881
|
case 0:
|
|
25843
|
-
|
|
25882
|
+
_context20.next = 2;
|
|
25844
25883
|
return _this4.getProjects("search=meta.".concat(key, ":").concat(value, "&limit=").concat(limit, "&page=").concat(page));
|
|
25845
25884
|
|
|
25846
25885
|
case 2:
|
|
25847
|
-
return
|
|
25886
|
+
return _context20.abrupt("return", _context20.sent);
|
|
25848
25887
|
|
|
25849
25888
|
case 3:
|
|
25850
25889
|
case "end":
|
|
25851
|
-
return
|
|
25890
|
+
return _context20.stop();
|
|
25852
25891
|
}
|
|
25853
25892
|
}
|
|
25854
|
-
},
|
|
25893
|
+
}, _callee20);
|
|
25855
25894
|
}));
|
|
25856
25895
|
|
|
25857
25896
|
return function (_x18) {
|
|
@@ -25861,10 +25900,10 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25861
25900
|
|
|
25862
25901
|
case 2:
|
|
25863
25902
|
case "end":
|
|
25864
|
-
return
|
|
25903
|
+
return _context21.stop();
|
|
25865
25904
|
}
|
|
25866
25905
|
}
|
|
25867
|
-
},
|
|
25906
|
+
}, _callee21, this);
|
|
25868
25907
|
}));
|
|
25869
25908
|
|
|
25870
25909
|
function getProjectsByMetaValue(_x16, _x17) {
|
|
@@ -25876,34 +25915,34 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25876
25915
|
}, {
|
|
25877
25916
|
key: "getLocationProjects",
|
|
25878
25917
|
value: function () {
|
|
25879
|
-
var _getLocationProjects = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function
|
|
25918
|
+
var _getLocationProjects = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee23(locationId) {
|
|
25880
25919
|
var _this5 = this;
|
|
25881
25920
|
|
|
25882
25921
|
var limit,
|
|
25883
|
-
|
|
25884
|
-
return regenerator_default().wrap(function
|
|
25922
|
+
_args23 = arguments;
|
|
25923
|
+
return regenerator_default().wrap(function _callee23$(_context23) {
|
|
25885
25924
|
while (1) {
|
|
25886
|
-
switch (
|
|
25925
|
+
switch (_context23.prev = _context23.next) {
|
|
25887
25926
|
case 0:
|
|
25888
|
-
limit =
|
|
25889
|
-
return
|
|
25890
|
-
var _ref5 = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function
|
|
25891
|
-
return regenerator_default().wrap(function
|
|
25927
|
+
limit = _args23.length > 1 && _args23[1] !== undefined ? _args23[1] : 100;
|
|
25928
|
+
return _context23.abrupt("return", this.timeKitPaginate( /*#__PURE__*/function () {
|
|
25929
|
+
var _ref5 = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee22(page) {
|
|
25930
|
+
return regenerator_default().wrap(function _callee22$(_context22) {
|
|
25892
25931
|
while (1) {
|
|
25893
|
-
switch (
|
|
25932
|
+
switch (_context22.prev = _context22.next) {
|
|
25894
25933
|
case 0:
|
|
25895
|
-
|
|
25934
|
+
_context22.next = 2;
|
|
25896
25935
|
return _this5.getProjects("search=locations.uuid:".concat(locationId, "&limit=").concat(limit, "&page=").concat(page));
|
|
25897
25936
|
|
|
25898
25937
|
case 2:
|
|
25899
|
-
return
|
|
25938
|
+
return _context22.abrupt("return", _context22.sent);
|
|
25900
25939
|
|
|
25901
25940
|
case 3:
|
|
25902
25941
|
case "end":
|
|
25903
|
-
return
|
|
25942
|
+
return _context22.stop();
|
|
25904
25943
|
}
|
|
25905
25944
|
}
|
|
25906
|
-
},
|
|
25945
|
+
}, _callee22);
|
|
25907
25946
|
}));
|
|
25908
25947
|
|
|
25909
25948
|
return function (_x20) {
|
|
@@ -25913,10 +25952,10 @@ var TimekitApiClient = /*#__PURE__*/function () {
|
|
|
25913
25952
|
|
|
25914
25953
|
case 2:
|
|
25915
25954
|
case "end":
|
|
25916
|
-
return
|
|
25955
|
+
return _context23.stop();
|
|
25917
25956
|
}
|
|
25918
25957
|
}
|
|
25919
|
-
},
|
|
25958
|
+
}, _callee23, this);
|
|
25920
25959
|
}));
|
|
25921
25960
|
|
|
25922
25961
|
function getLocationProjects(_x19) {
|
|
@@ -26460,17 +26499,17 @@ var DefaultProjectStrategy = /*#__PURE__*/function () {
|
|
|
26460
26499
|
}();
|
|
26461
26500
|
|
|
26462
26501
|
/* harmony default export */ const Strategy_DefaultProjectStrategy = (DefaultProjectStrategy);
|
|
26463
|
-
;// CONCATENATED MODULE: ./src/Strategy/
|
|
26502
|
+
;// CONCATENATED MODULE: ./src/Strategy/ServiceProjectsStatergy.js
|
|
26464
26503
|
|
|
26465
26504
|
|
|
26466
26505
|
|
|
26467
26506
|
|
|
26468
|
-
var
|
|
26469
|
-
function
|
|
26470
|
-
classCallCheck_default()(this,
|
|
26507
|
+
var ServiceProjectsStatergy = /*#__PURE__*/function () {
|
|
26508
|
+
function ServiceProjectsStatergy() {
|
|
26509
|
+
classCallCheck_default()(this, ServiceProjectsStatergy);
|
|
26471
26510
|
}
|
|
26472
26511
|
|
|
26473
|
-
createClass_default()(
|
|
26512
|
+
createClass_default()(ServiceProjectsStatergy, [{
|
|
26474
26513
|
key: "getProjects",
|
|
26475
26514
|
value: function getProjects() {
|
|
26476
26515
|
var projectType = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
|
|
@@ -26479,10 +26518,60 @@ var LocationServiceStatergy = /*#__PURE__*/function () {
|
|
|
26479
26518
|
}
|
|
26480
26519
|
}]);
|
|
26481
26520
|
|
|
26521
|
+
return ServiceProjectsStatergy;
|
|
26522
|
+
}();
|
|
26523
|
+
|
|
26524
|
+
/* harmony default export */ const Strategy_ServiceProjectsStatergy = (ServiceProjectsStatergy);
|
|
26525
|
+
;// CONCATENATED MODULE: ./src/Strategy/ServiceLocationStatergy.js
|
|
26526
|
+
|
|
26527
|
+
|
|
26528
|
+
|
|
26529
|
+
|
|
26530
|
+
|
|
26531
|
+
|
|
26532
|
+
|
|
26533
|
+
var LocationServiceStatergy = /*#__PURE__*/function () {
|
|
26534
|
+
function LocationServiceStatergy() {
|
|
26535
|
+
classCallCheck_default()(this, LocationServiceStatergy);
|
|
26536
|
+
}
|
|
26537
|
+
|
|
26538
|
+
createClass_default()(LocationServiceStatergy, [{
|
|
26539
|
+
key: "getProjects",
|
|
26540
|
+
value: function () {
|
|
26541
|
+
var _getProjects = asyncToGenerator_default()( /*#__PURE__*/regenerator_default().mark(function _callee(serviceId) {
|
|
26542
|
+
var apiClient;
|
|
26543
|
+
return regenerator_default().wrap(function _callee$(_context) {
|
|
26544
|
+
while (1) {
|
|
26545
|
+
switch (_context.prev = _context.next) {
|
|
26546
|
+
case 0:
|
|
26547
|
+
apiClient = new TimekitApiClient();
|
|
26548
|
+
apiClient.setAppKey(instance.app_key);
|
|
26549
|
+
_context.next = 4;
|
|
26550
|
+
return apiClient.getLocationByServices(serviceId);
|
|
26551
|
+
|
|
26552
|
+
case 4:
|
|
26553
|
+
return _context.abrupt("return", _context.sent);
|
|
26554
|
+
|
|
26555
|
+
case 5:
|
|
26556
|
+
case "end":
|
|
26557
|
+
return _context.stop();
|
|
26558
|
+
}
|
|
26559
|
+
}
|
|
26560
|
+
}, _callee);
|
|
26561
|
+
}));
|
|
26562
|
+
|
|
26563
|
+
function getProjects(_x) {
|
|
26564
|
+
return _getProjects.apply(this, arguments);
|
|
26565
|
+
}
|
|
26566
|
+
|
|
26567
|
+
return getProjects;
|
|
26568
|
+
}()
|
|
26569
|
+
}]);
|
|
26570
|
+
|
|
26482
26571
|
return LocationServiceStatergy;
|
|
26483
26572
|
}();
|
|
26484
26573
|
|
|
26485
|
-
/* harmony default export */ const
|
|
26574
|
+
/* harmony default export */ const ServiceLocationStatergy = (LocationServiceStatergy);
|
|
26486
26575
|
;// CONCATENATED MODULE: ./src/Strategy/ProjectsStrategy.js
|
|
26487
26576
|
|
|
26488
26577
|
|
|
@@ -26491,6 +26580,7 @@ var LocationServiceStatergy = /*#__PURE__*/function () {
|
|
|
26491
26580
|
|
|
26492
26581
|
|
|
26493
26582
|
|
|
26583
|
+
|
|
26494
26584
|
var ProjectsStrategy = /*#__PURE__*/function () {
|
|
26495
26585
|
function ProjectsStrategy() {
|
|
26496
26586
|
classCallCheck_default()(this, ProjectsStrategy);
|
|
@@ -26498,7 +26588,8 @@ var ProjectsStrategy = /*#__PURE__*/function () {
|
|
|
26498
26588
|
this.store = ProjectsStore_instance;
|
|
26499
26589
|
this.storeProjectsStrategy = new Strategy_StoreProjectsStrategy();
|
|
26500
26590
|
this.defaultStrategy = new Strategy_DefaultProjectStrategy();
|
|
26501
|
-
this.
|
|
26591
|
+
this.serviceProjectsStrategy = new Strategy_ServiceProjectsStatergy();
|
|
26592
|
+
this.serviceLocationStatergy = new ServiceLocationStatergy();
|
|
26502
26593
|
}
|
|
26503
26594
|
|
|
26504
26595
|
createClass_default()(ProjectsStrategy, [{
|
|
@@ -26512,7 +26603,11 @@ var ProjectsStrategy = /*#__PURE__*/function () {
|
|
|
26512
26603
|
break;
|
|
26513
26604
|
|
|
26514
26605
|
case 'service_project':
|
|
26515
|
-
strategy = this.
|
|
26606
|
+
strategy = this.serviceProjectsStrategy;
|
|
26607
|
+
break;
|
|
26608
|
+
|
|
26609
|
+
case 'service_location':
|
|
26610
|
+
strategy = this.serviceLocationStatergy;
|
|
26516
26611
|
break;
|
|
26517
26612
|
|
|
26518
26613
|
default:
|