@be-link/ecommerce-client-backend-service-node-sdk 0.1.89 → 0.1.91
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/index.d.ts +1 -0
- package/index.js +3 -1
- package/modules/data/types.d.ts +4 -0
- package/modules/roomData/types.d.ts +4 -0
- package/modules/rule/types.d.ts +1 -1
- package/modules/userData/types.d.ts +8 -0
- package/package.json +1 -1
- package/utils/http.d.ts +1 -0
- package/utils/http.js +5 -0
package/index.d.ts
CHANGED
|
@@ -13,6 +13,7 @@ export { ruleService } from './modules/rule/service';
|
|
|
13
13
|
export { miniProgramService } from './modules/miniprogram/service';
|
|
14
14
|
export { userDataService } from './modules/userData/service';
|
|
15
15
|
export { ENUM as CLIENT_BACKEND_ENUM } from './enum';
|
|
16
|
+
export { destroyHttpAgents } from './utils/http';
|
|
16
17
|
export type { Room, RoomAutoStartConfig, RoomLoopVideo, RoomTag, RoomBindStore } from './types';
|
|
17
18
|
export type { Domain, Current } from './modules/domain/types';
|
|
18
19
|
export type { MiniProgram, Info as MiniProgramInfo } from './modules/miniprogram/types';
|
package/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.CLIENT_BACKEND_ENUM = exports.userDataService = exports.miniProgramService = exports.ruleService = exports.domainService = exports.dataService = exports.roomDataService = exports.roomService = void 0;
|
|
3
|
+
exports.destroyHttpAgents = exports.CLIENT_BACKEND_ENUM = exports.userDataService = exports.miniProgramService = exports.ruleService = exports.domainService = exports.dataService = exports.roomDataService = exports.roomService = void 0;
|
|
4
4
|
var service_1 = require("./modules/room/service");
|
|
5
5
|
Object.defineProperty(exports, "roomService", { enumerable: true, get: function () { return service_1.roomService; } });
|
|
6
6
|
var service_2 = require("./modules/roomData/service");
|
|
@@ -17,4 +17,6 @@ var service_7 = require("./modules/userData/service");
|
|
|
17
17
|
Object.defineProperty(exports, "userDataService", { enumerable: true, get: function () { return service_7.userDataService; } });
|
|
18
18
|
var enum_1 = require("./enum");
|
|
19
19
|
Object.defineProperty(exports, "CLIENT_BACKEND_ENUM", { enumerable: true, get: function () { return enum_1.ENUM; } });
|
|
20
|
+
var http_1 = require("./utils/http");
|
|
21
|
+
Object.defineProperty(exports, "destroyHttpAgents", { enumerable: true, get: function () { return http_1.destroyHttpAgents; } });
|
|
20
22
|
// 服务.模块.枚举名称.枚举值 示例: DEMO_ENUM.ORDER_ENUM.STATUS.PENDING
|
package/modules/data/types.d.ts
CHANGED
|
@@ -405,6 +405,10 @@ export interface RoomStatistics {
|
|
|
405
405
|
salesVolume: number;
|
|
406
406
|
/** 待支付份数 */
|
|
407
407
|
pendingSalesVolume: number;
|
|
408
|
+
/** 开通会员卡份数 */
|
|
409
|
+
memberCardPaidOrderCount: number;
|
|
410
|
+
/** 酒旅预计尾款(单位:分) */
|
|
411
|
+
hotelTravelEstimatedFinalPayment: number;
|
|
408
412
|
}
|
|
409
413
|
export interface Product {
|
|
410
414
|
/** 直播间id */
|
|
@@ -126,6 +126,7 @@ export declare namespace RoomDataService {
|
|
|
126
126
|
productImage: string;
|
|
127
127
|
actualQuantity: number;
|
|
128
128
|
price: number;
|
|
129
|
+
remainAmount: number;
|
|
129
130
|
}
|
|
130
131
|
interface ProductSalesRanking {
|
|
131
132
|
list: ProductSalesItem[];
|
|
@@ -214,6 +215,9 @@ export declare namespace StoreAnalysisService {
|
|
|
214
215
|
interface StoreAnalysisItem {
|
|
215
216
|
storeId: string;
|
|
216
217
|
storeName: string;
|
|
218
|
+
province: string;
|
|
219
|
+
city: string;
|
|
220
|
+
area: string;
|
|
217
221
|
storeAddress: string;
|
|
218
222
|
viewerCount: number;
|
|
219
223
|
orderUserCount: number;
|
package/modules/rule/types.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ export declare namespace RuleService {
|
|
|
3
3
|
interface Info {
|
|
4
4
|
/** 直播间id */
|
|
5
5
|
liveStreamRoomId: string;
|
|
6
|
-
/** 规则分类:city-城市、delivery-配送、tag-标签、businessScope-主营业务 */
|
|
6
|
+
/** 规则分类:city-城市、delivery-配送、urbanDelivery-仓配方式(城配/非城配)、newbieLivePeriodInRoomStart-新手开播期是否覆盖直播开始时间、tag-标签、businessScope-主营业务 */
|
|
7
7
|
cate: string;
|
|
8
8
|
/** 规则值 */
|
|
9
9
|
ruleValue: string;
|
|
@@ -40,6 +40,10 @@ export declare namespace UserDataService {
|
|
|
40
40
|
lastWatchTimeRange?: number[];
|
|
41
41
|
/** 累计消费金额范围(分)[最小值, 最大值] */
|
|
42
42
|
accumulatedConsumptionAmountRange?: number[];
|
|
43
|
+
/** 总累计消费金额范围(分)[最小值, 最大值] */
|
|
44
|
+
totalAccumulatedConsumptionAmountRange?: number[];
|
|
45
|
+
/** 酒旅累计消费金额范围(分)[最小值, 最大值] */
|
|
46
|
+
hotelTravelAccumulatedConsumptionAmountRange?: number[];
|
|
43
47
|
/** 最近消费时间范围(毫秒)[开始时间, 结束时间] */
|
|
44
48
|
lastConsumptionTimeRange?: number[];
|
|
45
49
|
/** 每页数量,默认20 */
|
|
@@ -353,6 +357,10 @@ export interface UserInfo {
|
|
|
353
357
|
lastWatchTime: string;
|
|
354
358
|
/** 累计消费金额(元) */
|
|
355
359
|
accumulatedConsumptionAmount: number;
|
|
360
|
+
/** 总累计消费金额(元) */
|
|
361
|
+
totalAccumulatedConsumptionAmount: number;
|
|
362
|
+
/** 酒旅累计消费金额(元) */
|
|
363
|
+
hotelTravelAccumulatedConsumptionAmount: number;
|
|
356
364
|
/** 累计退款金额(元) */
|
|
357
365
|
accumulatedRefundAmount: number;
|
|
358
366
|
/** 7天累计消费金额(元) */
|
package/package.json
CHANGED
package/utils/http.d.ts
CHANGED
package/utils/http.js
CHANGED
|
@@ -4,6 +4,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.callApi = callApi;
|
|
7
|
+
exports.destroyHttpAgents = destroyHttpAgents;
|
|
7
8
|
const axios_1 = __importDefault(require("axios"));
|
|
8
9
|
const uuid_1 = require("uuid");
|
|
9
10
|
const axios_retry_1 = __importDefault(require("axios-retry"));
|
|
@@ -106,3 +107,7 @@ async function callApi(url, request) {
|
|
|
106
107
|
const responseData = response.data;
|
|
107
108
|
return responseData.data;
|
|
108
109
|
}
|
|
110
|
+
function destroyHttpAgents() {
|
|
111
|
+
httpAgent.destroy();
|
|
112
|
+
httpsAgent.destroy();
|
|
113
|
+
}
|