@hapl/api-queries 0.1.152 → 0.1.153--canary.80.033beeb.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/CHANGELOG.md +0 -12
- package/dist/api-queries.cjs.development.js +28 -60
- 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 +28 -60
- package/dist/api-queries.esm.js.map +1 -1
- package/dist/clients/v1/api/crossSale/updateCrossSale/index.d.ts +3 -3
- package/dist/clients/v1/api/index.d.ts +1 -2
- package/dist/clients/v1/api/serviceRequest/findServiceRequests/index.d.ts +0 -3
- package/dist/clients/v1/dictionaries/ServiceRequest.d.ts +9 -9
- package/dist/clients/v1/index.d.ts +1 -2
- package/dist/clients/v1/types/CrossSale.d.ts +2 -2
- package/dist/clients/v2/api/realty/findRealties/index.d.ts +3 -3
- package/dist/clients/v2/api/realty/findRealtyById/index.d.ts +3 -3
- package/dist/clients/v2/types/ExternalLink.d.ts +7 -0
- package/dist/clients/v2/types/Realty.d.ts +16 -4
- package/dist/clients/v2/types/index.d.ts +1 -0
- package/dist/publisher/v1/api/findScoring/index.d.ts +13 -12
- package/dist/publisher/v1/index.d.ts +1 -1
- package/package.json +1 -1
- package/src/clients/v1/api/crossSale/updateCrossSale/index.ts +3 -3
- package/src/clients/v1/api/index.ts +1 -2
- package/src/clients/v1/api/serviceRequest/findServiceRequests/index.ts +0 -3
- package/src/clients/v1/dictionaries/ServiceRequest.ts +9 -9
- package/src/clients/v1/index.ts +4 -11
- package/src/clients/v1/types/CrossSale.ts +2 -2
- package/src/clients/v2/api/realty/findRealties/index.ts +11 -2
- package/src/clients/v2/api/realty/findRealtyById/index.ts +11 -2
- package/src/clients/v2/types/ExternalLink.ts +7 -0
- package/src/clients/v2/types/Realty.ts +3 -1
- package/src/clients/v2/types/index.ts +1 -0
- package/src/publisher/v1/api/findScoring/index.ts +27 -32
- package/src/publisher/v1/index.ts +1 -1
- package/dist/clients/v1/api/serviceRequest/findServiceRequestStatisticsById/index.d.ts +0 -32
- package/src/clients/v1/api/serviceRequest/findServiceRequestStatisticsById/index.ts +0 -40
package/dist/api-queries.esm.js
CHANGED
|
@@ -2176,26 +2176,6 @@ function findServiceRequestShortInfoRequest(_ref) {
|
|
|
2176
2176
|
});
|
|
2177
2177
|
}
|
|
2178
2178
|
|
|
2179
|
-
function findServiceRequestShortInfoByDealIdRequest(_ref) {
|
|
2180
|
-
var _ref$baseURL = _ref.baseURL,
|
|
2181
|
-
baseURL = _ref$baseURL === void 0 ? 'https://clients.homeapp.ru' : _ref$baseURL,
|
|
2182
|
-
urlParams = _ref.urlParams,
|
|
2183
|
-
headers = _ref.headers;
|
|
2184
|
-
return axios.get("/api/service-request-by-deal-id/short/" + urlParams.id, {
|
|
2185
|
-
baseURL: baseURL,
|
|
2186
|
-
headers: _extends({
|
|
2187
|
-
Accept: 'application/json'
|
|
2188
|
-
}, headers),
|
|
2189
|
-
transformResponse: [].concat(axios.defaults.transformResponse, [function (data) {
|
|
2190
|
-
return data.success ? data.data : data.data.error;
|
|
2191
|
-
}])
|
|
2192
|
-
}).then(function (res) {
|
|
2193
|
-
return res;
|
|
2194
|
-
})["catch"](function (err) {
|
|
2195
|
-
throw err;
|
|
2196
|
-
});
|
|
2197
|
-
}
|
|
2198
|
-
|
|
2199
2179
|
function findServiceRequestShortInfoByIdRequest(_ref) {
|
|
2200
2180
|
var _ref$baseURL = _ref.baseURL,
|
|
2201
2181
|
baseURL = _ref$baseURL === void 0 ? 'https://clients.homeapp.ru' : _ref$baseURL,
|
|
@@ -2216,12 +2196,12 @@ function findServiceRequestShortInfoByIdRequest(_ref) {
|
|
|
2216
2196
|
});
|
|
2217
2197
|
}
|
|
2218
2198
|
|
|
2219
|
-
function
|
|
2199
|
+
function findServiceRequestShortInfoByDealIdRequest(_ref) {
|
|
2220
2200
|
var _ref$baseURL = _ref.baseURL,
|
|
2221
2201
|
baseURL = _ref$baseURL === void 0 ? 'https://clients.homeapp.ru' : _ref$baseURL,
|
|
2222
2202
|
urlParams = _ref.urlParams,
|
|
2223
2203
|
headers = _ref.headers;
|
|
2224
|
-
return axios.get("/api/service-request/
|
|
2204
|
+
return axios.get("/api/service-request-by-deal-id/short/" + urlParams.id, {
|
|
2225
2205
|
baseURL: baseURL,
|
|
2226
2206
|
headers: _extends({
|
|
2227
2207
|
Accept: 'application/json'
|
|
@@ -3740,7 +3720,7 @@ var _Category$2, _ModerationStatus, _Status$4, _Type$8, _InvestType, _DepublishR
|
|
|
3740
3720
|
var ServiceRequestDictionary = {
|
|
3741
3721
|
Category: (_Category$2 = {}, _Category$2[ServiceRequestCategory.Depublished] = 'Неликвидный', _Category$2[ServiceRequestCategory.Discounted] = 'Цена снижена', _Category$2[ServiceRequestCategory.Cold] = 'Холодный', _Category$2[ServiceRequestCategory.Warm] = 'Тёплый', _Category$2[ServiceRequestCategory.New] = 'Новый', _Category$2[ServiceRequestCategory.Hot] = 'Горячий', _Category$2),
|
|
3742
3722
|
ModerationStatus: (_ModerationStatus = {}, _ModerationStatus[ServiceRequestModerationStatus.None] = 'Нет', _ModerationStatus[ServiceRequestModerationStatus.Sent] = 'Отправлен', _ModerationStatus[ServiceRequestModerationStatus.Booked] = 'Взят в работу', _ModerationStatus[ServiceRequestModerationStatus.Done] = 'Готов', _ModerationStatus),
|
|
3743
|
-
Status: (_Status$4 = {}, _Status$4[ServiceRequestStatus.
|
|
3723
|
+
Status: (_Status$4 = {}, _Status$4[ServiceRequestStatus.Approved] = 'Бронь одобренная РОП', _Status$4[ServiceRequestStatus.Booked] = 'Неподтверждённая бронь', _Status$4[ServiceRequestStatus.BookingCanceled] = 'ЗОУ закрыто', _Status$4[ServiceRequestStatus.DealDone] = 'Сделка закрыта', _Status$4[ServiceRequestStatus.DealSigned] = 'Сделка подписана', _Status$4[ServiceRequestStatus.Declined] = 'Бронь отклонённая РОП', _Status$4[ServiceRequestStatus.LeadAdv] = 'Лид пришедший с рекламы', _Status$4[ServiceRequestStatus.LeadExpert] = 'Лид заведённый экспертом', _Status$4[ServiceRequestStatus.NoPrepayment] = 'Запланирована сделка без аванса', _Status$4[ServiceRequestStatus.Prepaid] = 'Получен аванс по сделке', _Status$4[ServiceRequestStatus.PrepaymentPlanned] = 'Запланирован аванс', _Status$4[ServiceRequestStatus.Registered] = 'Документы зарегистрированы', _Status$4[ServiceRequestStatus.Signed] = 'Контракт подписан', _Status$4[ServiceRequestStatus.Terminated] = 'Контракт расторгнут', _Status$4),
|
|
3744
3724
|
Type: (_Type$8 = {}, _Type$8[ServiceRequestType.Buy] = 'Покупка', _Type$8[ServiceRequestType.Sell] = 'Продажа', _Type$8),
|
|
3745
3725
|
InvestType: (_InvestType = {}, _InvestType[ServiceRequestInvestType.Buyout] = 'Инвестпроект 1 этапа', _InvestType[ServiceRequestInvestType.Sell] = 'Инвестпроект 2 этапа', _InvestType),
|
|
3746
3726
|
DepublishReason: (_DepublishReason = {}, _DepublishReason[ServiceRequestDepublishReason.TemporaryDepublish] = 'Временное снятие объекта', _DepublishReason[ServiceRequestDepublishReason.DepublishOnAdvance] = 'Снятие объекта на время аванса', _DepublishReason[ServiceRequestDepublishReason.ClientRequest] = 'Просьба клиента убрать объект из рекламы', _DepublishReason[ServiceRequestDepublishReason.DeveloperRequest] = 'Запрет застройщика на размещение рекламы', _DepublishReason[ServiceRequestDepublishReason.BadObject] = 'Неликвидный объект, требуется работа с клиентом', _DepublishReason[ServiceRequestDepublishReason.BadObjectElite] = 'Неликвидный элитный объект', _DepublishReason[ServiceRequestDepublishReason.HardToSellObject] = '“Сложный“ в реализации объект', _DepublishReason[ServiceRequestDepublishReason.CrossSell] = 'Кросспродажи', _DepublishReason),
|
|
@@ -4488,14 +4468,6 @@ var Api = function Api(baseURL) {
|
|
|
4488
4468
|
});
|
|
4489
4469
|
};
|
|
4490
4470
|
|
|
4491
|
-
this.findServiceRequestShortInfoByDealId = function (urlParams, headers) {
|
|
4492
|
-
return findServiceRequestShortInfoByDealIdRequest({
|
|
4493
|
-
urlParams: urlParams,
|
|
4494
|
-
headers: headers,
|
|
4495
|
-
baseURL: _this.baseURL
|
|
4496
|
-
});
|
|
4497
|
-
};
|
|
4498
|
-
|
|
4499
4471
|
this.findServiceRequestShortInfoById = function (urlParams, headers) {
|
|
4500
4472
|
return findServiceRequestShortInfoByIdRequest({
|
|
4501
4473
|
urlParams: urlParams,
|
|
@@ -4504,8 +4476,8 @@ var Api = function Api(baseURL) {
|
|
|
4504
4476
|
});
|
|
4505
4477
|
};
|
|
4506
4478
|
|
|
4507
|
-
this.
|
|
4508
|
-
return
|
|
4479
|
+
this.findServiceRequestShortInfoByDealId = function (urlParams, headers) {
|
|
4480
|
+
return findServiceRequestShortInfoByDealIdRequest({
|
|
4509
4481
|
urlParams: urlParams,
|
|
4510
4482
|
headers: headers,
|
|
4511
4483
|
baseURL: _this.baseURL
|
|
@@ -4786,9 +4758,8 @@ var index = {
|
|
|
4786
4758
|
findServiceRequestsRequest: findServiceRequestsRequest,
|
|
4787
4759
|
findServiceRequestSellerReportsRequest: findServiceRequestSellerReportsRequest,
|
|
4788
4760
|
findServiceRequestShortInfoRequest: findServiceRequestShortInfoRequest,
|
|
4789
|
-
findServiceRequestShortInfoByDealIdRequest: findServiceRequestShortInfoByDealIdRequest,
|
|
4790
4761
|
findServiceRequestShortInfoByIdRequest: findServiceRequestShortInfoByIdRequest,
|
|
4791
|
-
|
|
4762
|
+
findServiceRequestShortInfoByDealIdRequest: findServiceRequestShortInfoByDealIdRequest,
|
|
4792
4763
|
findServiceRequestCategorizedFilesRequest: findServiceRequestCategorizedFilesRequest,
|
|
4793
4764
|
findServiceRequestCategorizedFileCreatedDateRequest: findServiceRequestCategorizedFileCreatedDateRequest,
|
|
4794
4765
|
returnDeferredServiceRequestRequest: returnDeferredServiceRequestRequest,
|
|
@@ -6404,32 +6375,29 @@ function findScoringRequest(_ref) {
|
|
|
6404
6375
|
},
|
|
6405
6376
|
headers: _extends({
|
|
6406
6377
|
Accept: 'application/json'
|
|
6407
|
-
}, headers)
|
|
6408
|
-
transformResponse: [].concat(axios.defaults.transformResponse, [function (data) {
|
|
6409
|
-
var _ref2, _data$data$error, _data$data;
|
|
6410
|
-
|
|
6411
|
-
if (data.success) {
|
|
6412
|
-
var ids = [];
|
|
6413
|
-
var byId = {};
|
|
6414
|
-
data.data.forEach(function (entity) {
|
|
6415
|
-
byId[entity.id] = entity;
|
|
6416
|
-
ids.push(entity.id);
|
|
6417
|
-
});
|
|
6418
|
-
return {
|
|
6419
|
-
ids: ids,
|
|
6420
|
-
byId: byId,
|
|
6421
|
-
meta: {
|
|
6422
|
-
total: data.pageParams.length
|
|
6423
|
-
}
|
|
6424
|
-
};
|
|
6425
|
-
}
|
|
6426
|
-
|
|
6427
|
-
return (_ref2 = (_data$data$error = (_data$data = data.data) == null ? void 0 : _data$data.error) != null ? _data$data$error : data.message) != null ? _ref2 : 'Unknown Error';
|
|
6428
|
-
}])
|
|
6378
|
+
}, headers)
|
|
6429
6379
|
}).then(function (res) {
|
|
6430
|
-
|
|
6380
|
+
var data = {
|
|
6381
|
+
data: {
|
|
6382
|
+
byId: {},
|
|
6383
|
+
ids: []
|
|
6384
|
+
},
|
|
6385
|
+
meta: {
|
|
6386
|
+
total: res.data.pageParams.length
|
|
6387
|
+
}
|
|
6388
|
+
};
|
|
6389
|
+
res.data.data.forEach(function (entity) {
|
|
6390
|
+
data.data.byId[entity.id] = entity;
|
|
6391
|
+
data.data.ids.push(entity.id);
|
|
6392
|
+
});
|
|
6393
|
+
return data;
|
|
6431
6394
|
})["catch"](function (err) {
|
|
6432
|
-
|
|
6395
|
+
var _err$response$status, _err$response, _ref2, _err$response$data$me, _err$response2, _err$response3, _err$response3$data$d;
|
|
6396
|
+
|
|
6397
|
+
var error = new Error(err.message);
|
|
6398
|
+
error.status = (_err$response$status = (_err$response = err.response) == null ? void 0 : _err$response.status) != null ? _err$response$status : 520;
|
|
6399
|
+
error.data = (_ref2 = (_err$response$data$me = (_err$response2 = err.response) == null ? void 0 : _err$response2.data.message) != null ? _err$response$data$me : (_err$response3 = err.response) == null ? void 0 : (_err$response3$data$d = _err$response3.data.data) == null ? void 0 : _err$response3$data$d.error) != null ? _ref2 : 'Unknown Error';
|
|
6400
|
+
throw error;
|
|
6433
6401
|
});
|
|
6434
6402
|
}
|
|
6435
6403
|
|
|
@@ -6724,7 +6692,7 @@ var Api$2 = function Api(baseURL) {
|
|
|
6724
6692
|
});
|
|
6725
6693
|
};
|
|
6726
6694
|
|
|
6727
|
-
this.
|
|
6695
|
+
this.getScoring = function (params, headers) {
|
|
6728
6696
|
return findScoringRequest({
|
|
6729
6697
|
params: params,
|
|
6730
6698
|
headers: headers,
|