@be-link/ecommerce-backend-bff-service-node-sdk 0.0.13 → 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.
@@ -50,8 +50,8 @@ class HttpClient {
50
50
  'Content-Type': 'application/json',
51
51
  'X-Request-Id': requestId,
52
52
  'x-belink-authorization': token,
53
- 'x-belink-pandora-userId': userId,
54
- 'x-belink-pandora-roleId': roleId,
53
+ 'x-belink-pandora-userid': userId,
54
+ 'x-belink-pandora-roleid': roleId,
55
55
  };
56
56
  // 合并自定义请求头(自定义请求头优先)
57
57
  const headers = {
package/cjs/index.d.ts CHANGED
@@ -1,8 +1,6 @@
1
1
  import { PandoraExampleService } from './bff/modules/pandora/example/service';
2
- import { PandoraStoreService } from './bff/modules/pandora/store/service';
3
- import { PandoraStoreSelectionService } from './bff/modules/pandora/storeSelection/service';
4
2
  import { MiniProgramDemoService } from './bff/modules/miniprogram/demo/service';
5
- import type { SdkOptions } from './types';
3
+ import { SdkOptions } from './types';
6
4
  /**
7
5
  * Pandora 平台 SDK(管理后台)
8
6
  * 包含所有 Pandora 平台相关的服务
@@ -16,14 +14,6 @@ export declare class PandoraSDK {
16
14
  * Pandora 示例服务模块
17
15
  */
18
16
  example: PandoraExampleService;
19
- /**
20
- * Pandora 门店服务模块
21
- */
22
- store: PandoraStoreService;
23
- /**
24
- * Pandora 圈选门店服务模块
25
- */
26
- storeSelection: PandoraStoreSelectionService;
27
17
  /**
28
18
  * 使用配置选项初始化 Pandora SDK
29
19
  * @param options - SDK 配置,包含凭证回调函数
@@ -50,12 +40,6 @@ export declare class MiniProgramSDK {
50
40
  constructor(options: SdkOptions);
51
41
  }
52
42
  export { SdkError, BizError, SystemError } from './errors';
53
- export type { SdkOptions, IRequestStrategy, StandardResponse } from './types';
54
- export { MiniProgramDemoService } from './bff/modules/miniprogram/demo/service';
55
- export { PandoraExampleService } from './bff/modules/pandora/example/service';
56
- export { PandoraStoreService } from './bff/modules/pandora/store/service';
57
- export { PandoraStoreSelectionService } from './bff/modules/pandora/storeSelection/service';
58
- export type { Service as MiniProgramDemoTypes } from './bff/modules/miniprogram/demo/types';
59
- export type { Service as PandoraExampleTypes } from './bff/modules/pandora/example/types';
60
- export type { Service as PandoraStoreTypes } from './bff/modules/pandora/store/types';
61
- export type { Service as PandoraStoreSelectionTypes } from './bff/modules/pandora/storeSelection/types';
43
+ export { SdkOptions, IRequestStrategy, StandardResponse } from './types';
44
+ export { Service as MiniProgramDemoTypes } from './bff/modules/miniprogram/demo/types';
45
+ export { Service as PandoraExampleTypes } from './bff/modules/pandora/example/types';
package/cjs/index.js CHANGED
@@ -1,11 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.PandoraStoreSelectionService = exports.PandoraStoreService = exports.PandoraExampleService = exports.MiniProgramDemoService = exports.SystemError = exports.BizError = exports.SdkError = exports.MiniProgramSDK = exports.PandoraSDK = void 0;
3
+ exports.SystemError = exports.BizError = exports.SdkError = exports.MiniProgramSDK = exports.PandoraSDK = void 0;
4
4
  const client_1 = require("./bff/request/client");
5
5
  const service_1 = require("./bff/modules/pandora/example/service");
6
- const service_2 = require("./bff/modules/pandora/store/service");
7
- const service_3 = require("./bff/modules/pandora/storeSelection/service");
8
- const service_4 = require("./bff/modules/miniprogram/demo/service");
6
+ const service_2 = require("./bff/modules/miniprogram/demo/service");
9
7
  /**
10
8
  * Pandora 平台 SDK(管理后台)
11
9
  * 包含所有 Pandora 平台相关的服务
@@ -20,8 +18,6 @@ class PandoraSDK {
20
18
  this.http = new client_1.HttpClient(options);
21
19
  // 使用 HttpClient 实例化所有 Pandora 服务模块
22
20
  this.example = new service_1.PandoraExampleService(this.http);
23
- this.store = new service_2.PandoraStoreService(this.http);
24
- this.storeSelection = new service_3.PandoraStoreSelectionService(this.http);
25
21
  }
26
22
  }
27
23
  exports.PandoraSDK = PandoraSDK;
@@ -38,7 +34,7 @@ class MiniProgramSDK {
38
34
  // 使用提供的选项初始化 HttpClient
39
35
  this.http = new client_1.HttpClient(options);
40
36
  // 使用 HttpClient 实例化所有小程序服务模块
41
- this.demo = new service_4.MiniProgramDemoService(this.http);
37
+ this.demo = new service_2.MiniProgramDemoService(this.http);
42
38
  }
43
39
  }
44
40
  exports.MiniProgramSDK = MiniProgramSDK;
@@ -48,12 +44,3 @@ var errors_1 = require("./errors");
48
44
  Object.defineProperty(exports, "SdkError", { enumerable: true, get: function () { return errors_1.SdkError; } });
49
45
  Object.defineProperty(exports, "BizError", { enumerable: true, get: function () { return errors_1.BizError; } });
50
46
  Object.defineProperty(exports, "SystemError", { enumerable: true, get: function () { return errors_1.SystemError; } });
51
- // 服务类(按平台分组)
52
- var service_5 = require("./bff/modules/miniprogram/demo/service");
53
- Object.defineProperty(exports, "MiniProgramDemoService", { enumerable: true, get: function () { return service_5.MiniProgramDemoService; } });
54
- var service_6 = require("./bff/modules/pandora/example/service");
55
- Object.defineProperty(exports, "PandoraExampleService", { enumerable: true, get: function () { return service_6.PandoraExampleService; } });
56
- var service_7 = require("./bff/modules/pandora/store/service");
57
- Object.defineProperty(exports, "PandoraStoreService", { enumerable: true, get: function () { return service_7.PandoraStoreService; } });
58
- var service_8 = require("./bff/modules/pandora/storeSelection/service");
59
- Object.defineProperty(exports, "PandoraStoreSelectionService", { enumerable: true, get: function () { return service_8.PandoraStoreSelectionService; } });
@@ -47,8 +47,8 @@ export class HttpClient {
47
47
  'Content-Type': 'application/json',
48
48
  'X-Request-Id': requestId,
49
49
  'x-belink-authorization': token,
50
- 'x-belink-pandora-userId': userId,
51
- 'x-belink-pandora-roleId': roleId,
50
+ 'x-belink-pandora-userid': userId,
51
+ 'x-belink-pandora-roleid': roleId,
52
52
  };
53
53
  // 合并自定义请求头(自定义请求头优先)
54
54
  const headers = {
package/esm/index.d.ts CHANGED
@@ -1,8 +1,6 @@
1
1
  import { PandoraExampleService } from './bff/modules/pandora/example/service';
2
- import { PandoraStoreService } from './bff/modules/pandora/store/service';
3
- import { PandoraStoreSelectionService } from './bff/modules/pandora/storeSelection/service';
4
2
  import { MiniProgramDemoService } from './bff/modules/miniprogram/demo/service';
5
- import type { SdkOptions } from './types';
3
+ import { SdkOptions } from './types';
6
4
  /**
7
5
  * Pandora 平台 SDK(管理后台)
8
6
  * 包含所有 Pandora 平台相关的服务
@@ -16,14 +14,6 @@ export declare class PandoraSDK {
16
14
  * Pandora 示例服务模块
17
15
  */
18
16
  example: PandoraExampleService;
19
- /**
20
- * Pandora 门店服务模块
21
- */
22
- store: PandoraStoreService;
23
- /**
24
- * Pandora 圈选门店服务模块
25
- */
26
- storeSelection: PandoraStoreSelectionService;
27
17
  /**
28
18
  * 使用配置选项初始化 Pandora SDK
29
19
  * @param options - SDK 配置,包含凭证回调函数
@@ -50,12 +40,6 @@ export declare class MiniProgramSDK {
50
40
  constructor(options: SdkOptions);
51
41
  }
52
42
  export { SdkError, BizError, SystemError } from './errors';
53
- export type { SdkOptions, IRequestStrategy, StandardResponse } from './types';
54
- export { MiniProgramDemoService } from './bff/modules/miniprogram/demo/service';
55
- export { PandoraExampleService } from './bff/modules/pandora/example/service';
56
- export { PandoraStoreService } from './bff/modules/pandora/store/service';
57
- export { PandoraStoreSelectionService } from './bff/modules/pandora/storeSelection/service';
58
- export type { Service as MiniProgramDemoTypes } from './bff/modules/miniprogram/demo/types';
59
- export type { Service as PandoraExampleTypes } from './bff/modules/pandora/example/types';
60
- export type { Service as PandoraStoreTypes } from './bff/modules/pandora/store/types';
61
- export type { Service as PandoraStoreSelectionTypes } from './bff/modules/pandora/storeSelection/types';
43
+ export { SdkOptions, IRequestStrategy, StandardResponse } from './types';
44
+ export { Service as MiniProgramDemoTypes } from './bff/modules/miniprogram/demo/types';
45
+ export { Service as PandoraExampleTypes } from './bff/modules/pandora/example/types';
package/esm/index.mjs CHANGED
@@ -1,7 +1,5 @@
1
1
  import { HttpClient } from './bff/request/client.mjs';
2
2
  import { PandoraExampleService } from './bff/modules/pandora/example/service.mjs';
3
- import { PandoraStoreService } from './bff/modules/pandora/store/service.mjs';
4
- import { PandoraStoreSelectionService } from './bff/modules/pandora/storeSelection/service.mjs';
5
3
  import { MiniProgramDemoService } from './bff/modules/miniprogram/demo/service.mjs';
6
4
  /**
7
5
  * Pandora 平台 SDK(管理后台)
@@ -17,8 +15,6 @@ export class PandoraSDK {
17
15
  this.http = new HttpClient(options);
18
16
  // 使用 HttpClient 实例化所有 Pandora 服务模块
19
17
  this.example = new PandoraExampleService(this.http);
20
- this.store = new PandoraStoreService(this.http);
21
- this.storeSelection = new PandoraStoreSelectionService(this.http);
22
18
  }
23
19
  }
24
20
  /**
@@ -40,8 +36,3 @@ export class MiniProgramSDK {
40
36
  // ==================== 导出 ====================
41
37
  // 错误类
42
38
  export { SdkError, BizError, SystemError } from './errors/index.mjs';
43
- // 服务类(按平台分组)
44
- export { MiniProgramDemoService } from './bff/modules/miniprogram/demo/service.mjs';
45
- export { PandoraExampleService } from './bff/modules/pandora/example/service.mjs';
46
- export { PandoraStoreService } from './bff/modules/pandora/store/service.mjs';
47
- export { PandoraStoreSelectionService } from './bff/modules/pandora/storeSelection/service.mjs';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@be-link/ecommerce-backend-bff-service-node-sdk",
3
- "version": "0.0.13",
3
+ "version": "0.0.14",
4
4
  "description": "EcommerceBackendBffService Node.js SDK",
5
5
  "type": "commonjs",
6
6
  "main": "./cjs/index.js",
@@ -1,53 +0,0 @@
1
- import { Service } from './types';
2
- import BaseService from '../../BaseService';
3
- import type { StandardResponse } from '../../../../types';
4
- /**
5
- * PandoraStoreService - Pandora Store 服务模块
6
- * 提供门店管理相关的 API 方法
7
- * 平台: pandora
8
- */
9
- export declare class PandoraStoreService extends BaseService {
10
- protected prefixUrl: string;
11
- /**
12
- * 创建门店
13
- * @param request - 请求参数
14
- * @returns Promise,解析为标准响应格式
15
- */
16
- createStore(request: Service.Request.createStore): Promise<StandardResponse<Service.Response.createStore>>;
17
- /**
18
- * 编辑门店信息
19
- * @param request - 请求参数
20
- * @returns Promise,解析为标准响应格式
21
- */
22
- updateStoreInfo(request: Service.Request.updateStoreInfo): Promise<StandardResponse<Service.Response.updateStoreInfo>>;
23
- /**
24
- * 获取门店详情
25
- * @param request - 请求参数
26
- * @returns Promise,解析为标准响应格式
27
- */
28
- getStoreDetail(request: Service.Request.getStoreDetail): Promise<StandardResponse<Service.Response.getStoreDetail>>;
29
- /**
30
- * 获取门店列表
31
- * @param request - 请求参数
32
- * @returns Promise,解析为标准响应格式
33
- */
34
- getStoreList(request: Service.Request.getStoreList): Promise<StandardResponse<Service.Response.getStoreList>>;
35
- /**
36
- * 批量修改门店经营状态
37
- * @param request - 请求参数
38
- * @returns Promise,解析为标准响应格式
39
- */
40
- batchUpdateBusinessStatus(request: Service.Request.batchUpdateBusinessStatus): Promise<StandardResponse<Service.Response.batchUpdateBusinessStatus>>;
41
- /**
42
- * 绑定用户到门店
43
- * @param request - 请求参数
44
- * @returns Promise,解析为标准响应格式
45
- */
46
- bindUserToStore(request: Service.Request.bindUserToStore): Promise<StandardResponse<Service.Response.bindUserToStore>>;
47
- /**
48
- * 解绑用户
49
- * @param request - 请求参数
50
- * @returns Promise,解析为标准响应格式
51
- */
52
- unbindUserFromStore(request: Service.Request.unbindUserFromStore): Promise<StandardResponse<Service.Response.unbindUserFromStore>>;
53
- }
@@ -1,75 +0,0 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.PandoraStoreService = void 0;
7
- const BaseService_1 = __importDefault(require("../../BaseService"));
8
- /**
9
- * PandoraStoreService - Pandora Store 服务模块
10
- * 提供门店管理相关的 API 方法
11
- * 平台: pandora
12
- */
13
- class PandoraStoreService extends BaseService_1.default {
14
- constructor() {
15
- super(...arguments);
16
- this.prefixUrl = '/pandora/store';
17
- }
18
- /**
19
- * 创建门店
20
- * @param request - 请求参数
21
- * @returns Promise,解析为标准响应格式
22
- */
23
- createStore(request) {
24
- return this.request(this.createStore, request);
25
- }
26
- /**
27
- * 编辑门店信息
28
- * @param request - 请求参数
29
- * @returns Promise,解析为标准响应格式
30
- */
31
- updateStoreInfo(request) {
32
- return this.request(this.updateStoreInfo, request);
33
- }
34
- /**
35
- * 获取门店详情
36
- * @param request - 请求参数
37
- * @returns Promise,解析为标准响应格式
38
- */
39
- getStoreDetail(request) {
40
- return this.request(this.getStoreDetail, request);
41
- }
42
- /**
43
- * 获取门店列表
44
- * @param request - 请求参数
45
- * @returns Promise,解析为标准响应格式
46
- */
47
- getStoreList(request) {
48
- return this.request(this.getStoreList, request);
49
- }
50
- /**
51
- * 批量修改门店经营状态
52
- * @param request - 请求参数
53
- * @returns Promise,解析为标准响应格式
54
- */
55
- batchUpdateBusinessStatus(request) {
56
- return this.request(this.batchUpdateBusinessStatus, request);
57
- }
58
- /**
59
- * 绑定用户到门店
60
- * @param request - 请求参数
61
- * @returns Promise,解析为标准响应格式
62
- */
63
- bindUserToStore(request) {
64
- return this.request(this.bindUserToStore, request);
65
- }
66
- /**
67
- * 解绑用户
68
- * @param request - 请求参数
69
- * @returns Promise,解析为标准响应格式
70
- */
71
- unbindUserFromStore(request) {
72
- return this.request(this.unbindUserFromStore, request);
73
- }
74
- }
75
- exports.PandoraStoreService = PandoraStoreService;