@hapl/api-queries 0.1.98 → 0.1.99--canary.34.40df731.0
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/api-queries.cjs.development.js +52 -0
- package/dist/api-queries.cjs.development.js.map +1 -1
- package/dist/api-queries.cjs.production.min.js +1 -1
- package/dist/api-queries.cjs.production.min.js.map +1 -1
- package/dist/api-queries.esm.js +52 -0
- package/dist/api-queries.esm.js.map +1 -1
- package/dist/clients/v1/api/index.d.ts +1 -0
- package/dist/clients/v1/api/serviceRequest/findServiceRequestShortInfo/index.d.ts +58 -0
- package/dist/clients/v1/index.d.ts +1 -0
- package/dist/clients/v1/types/ServiceRequest.d.ts +3 -1
- package/dist/clients/v1/types/ServiceRequestShortInfo.d.ts +33 -0
- package/dist/clients/v1/types/index.d.ts +1 -0
- package/package.json +1 -1
- package/src/clients/v1/api/index.ts +1 -0
- package/src/clients/v1/api/serviceRequest/findServiceRequestShortInfo/index.ts +79 -0
- package/src/clients/v1/index.ts +7 -0
- package/src/clients/v1/types/ServiceRequest.ts +2 -0
- package/src/clients/v1/types/ServiceRequestShortInfo.ts +30 -0
- package/src/clients/v1/types/index.ts +1 -0
|
@@ -841,6 +841,47 @@ function findServiceRequestsRequest(_ref) {
|
|
|
841
841
|
});
|
|
842
842
|
}
|
|
843
843
|
|
|
844
|
+
function findServiceRequestShortInfoRequest(_ref) {
|
|
845
|
+
var _ref$baseURL = _ref.baseURL,
|
|
846
|
+
baseURL = _ref$baseURL === void 0 ? 'https://clients.homeapp.ru' : _ref$baseURL,
|
|
847
|
+
headers = _ref.headers,
|
|
848
|
+
params = _ref.params;
|
|
849
|
+
return axios.get("/api/service-request/short", {
|
|
850
|
+
baseURL: baseURL,
|
|
851
|
+
params: params,
|
|
852
|
+
paramsSerializer: function paramsSerializer(params) {
|
|
853
|
+
return qs.stringify(params, {
|
|
854
|
+
arrayFormat: 'brackets'
|
|
855
|
+
});
|
|
856
|
+
},
|
|
857
|
+
headers: _extends({
|
|
858
|
+
Accept: 'application/json'
|
|
859
|
+
}, headers),
|
|
860
|
+
transformResponse: [].concat(axios.defaults.transformResponse, [function (data) {
|
|
861
|
+
var _data$data, _data$data2;
|
|
862
|
+
|
|
863
|
+
if (!data.success) return (_data$data = data.data) == null ? void 0 : _data$data.error;
|
|
864
|
+
var ids = [];
|
|
865
|
+
var byId = {};
|
|
866
|
+
((_data$data2 = data.data) != null ? _data$data2 : []).forEach(function (entity) {
|
|
867
|
+
byId[entity.id] = entity;
|
|
868
|
+
ids.push(entity.id);
|
|
869
|
+
});
|
|
870
|
+
return {
|
|
871
|
+
ids: ids,
|
|
872
|
+
byId: byId,
|
|
873
|
+
meta: {
|
|
874
|
+
total: data.pageParams.length
|
|
875
|
+
}
|
|
876
|
+
};
|
|
877
|
+
}])
|
|
878
|
+
}).then(function (res) {
|
|
879
|
+
return res;
|
|
880
|
+
})["catch"](function (err) {
|
|
881
|
+
throw err;
|
|
882
|
+
});
|
|
883
|
+
}
|
|
884
|
+
|
|
844
885
|
function findServiceRequestShortInfoByIdRequest(_ref) {
|
|
845
886
|
var _ref$baseURL = _ref.baseURL,
|
|
846
887
|
baseURL = _ref$baseURL === void 0 ? 'https://clients.homeapp.ru' : _ref$baseURL,
|
|
@@ -1661,6 +1702,8 @@ var ServiceRequestStatus;
|
|
|
1661
1702
|
ServiceRequestStatus["DealSigned"] = "deal_signed";
|
|
1662
1703
|
ServiceRequestStatus["Registered"] = "registered";
|
|
1663
1704
|
ServiceRequestStatus["DealDone"] = "deal_done";
|
|
1705
|
+
ServiceRequestStatus["NoPrepayment"] = "no_prepayment";
|
|
1706
|
+
ServiceRequestStatus["PrepaymentPlanned"] = "prepayment_planned";
|
|
1664
1707
|
})(ServiceRequestStatus || (ServiceRequestStatus = {}));
|
|
1665
1708
|
|
|
1666
1709
|
var ServiceRequestType;
|
|
@@ -2255,6 +2298,14 @@ var Api = function Api(baseURL) {
|
|
|
2255
2298
|
});
|
|
2256
2299
|
};
|
|
2257
2300
|
|
|
2301
|
+
this.findServiceRequestShortInfo = function (params, headers) {
|
|
2302
|
+
return findServiceRequestShortInfoRequest({
|
|
2303
|
+
params: params,
|
|
2304
|
+
headers: headers,
|
|
2305
|
+
baseURL: _this.baseURL
|
|
2306
|
+
});
|
|
2307
|
+
};
|
|
2308
|
+
|
|
2258
2309
|
this.findServiceRequestShortInfoById = function (urlParams, headers) {
|
|
2259
2310
|
return findServiceRequestShortInfoByIdRequest({
|
|
2260
2311
|
urlParams: urlParams,
|
|
@@ -2392,6 +2443,7 @@ var index = {
|
|
|
2392
2443
|
findServiceRequestByIdRequest: findServiceRequestByIdRequest,
|
|
2393
2444
|
findServiceRequestDuplicatesRequest: findServiceRequestDuplicatesRequest,
|
|
2394
2445
|
findServiceRequestsRequest: findServiceRequestsRequest,
|
|
2446
|
+
findServiceRequestShortInfoRequest: findServiceRequestShortInfoRequest,
|
|
2395
2447
|
findServiceRequestShortInfoByIdRequest: findServiceRequestShortInfoByIdRequest,
|
|
2396
2448
|
findServiceRequestCategorizedFilesRequest: findServiceRequestCategorizedFilesRequest,
|
|
2397
2449
|
sendServiceRequestToModerationRequest: sendServiceRequestToModerationRequest,
|