@be-link/ecommerce-backend-bff-service-node-sdk 0.0.112 → 0.0.115
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/cjs/bff/modules/miniprogram/auth/service.d.ts +46 -0
- package/cjs/bff/modules/miniprogram/auth/service.js +66 -0
- package/cjs/bff/modules/miniprogram/auth/types.d.ts +133 -0
- package/cjs/bff/modules/miniprogram/auth/types.js +2 -0
- package/cjs/bff/modules/miniprogram/franchisee/service.d.ts +12 -0
- package/cjs/bff/modules/miniprogram/franchisee/service.js +22 -0
- package/cjs/bff/modules/miniprogram/franchisee/types.d.ts +25 -0
- package/cjs/bff/modules/miniprogram/franchisee/types.js +2 -0
- package/cjs/bff/modules/pandora/auth/service.d.ts +28 -0
- package/cjs/bff/modules/pandora/auth/service.js +42 -0
- package/cjs/bff/modules/pandora/auth/types.d.ts +94 -0
- package/cjs/bff/modules/pandora/auth/types.js +2 -0
- package/cjs/bff/modules/pandora/award/service.d.ts +17 -0
- package/cjs/bff/modules/pandora/award/service.js +27 -0
- package/cjs/bff/modules/pandora/award/types.d.ts +17 -0
- package/cjs/bff/modules/pandora/award/types.js +2 -0
- package/cjs/bff/modules/pandora/bd/service.d.ts +47 -0
- package/cjs/bff/modules/pandora/bd/service.js +67 -0
- package/cjs/bff/modules/pandora/bd/types.d.ts +157 -0
- package/cjs/bff/modules/pandora/bd/types.js +2 -0
- package/cjs/bff/modules/pandora/bdm/service.d.ts +35 -0
- package/cjs/bff/modules/pandora/bdm/service.js +51 -0
- package/cjs/bff/modules/pandora/bdm/types.d.ts +104 -0
- package/cjs/bff/modules/pandora/bdm/types.js +2 -0
- package/cjs/bff/modules/pandora/common/service.d.ts +34 -0
- package/cjs/bff/modules/pandora/common/service.js +50 -0
- package/cjs/bff/modules/pandora/common/types.d.ts +125 -0
- package/cjs/bff/modules/pandora/common/types.js +2 -0
- package/cjs/bff/modules/pandora/coupon/service.d.ts +59 -0
- package/cjs/bff/modules/pandora/coupon/service.js +83 -0
- package/cjs/bff/modules/pandora/coupon/types.d.ts +409 -0
- package/cjs/bff/modules/pandora/coupon/types.js +2 -0
- package/cjs/bff/modules/pandora/franchisee/service.d.ts +19 -0
- package/cjs/bff/modules/pandora/franchisee/service.js +43 -0
- package/cjs/bff/modules/pandora/franchisee/types.d.ts +204 -0
- package/cjs/bff/modules/pandora/franchisee/types.js +2 -0
- package/cjs/bff/modules/pandora/orderCore/service.d.ts +7 -1
- package/cjs/bff/modules/pandora/orderCore/service.js +9 -1
- package/cjs/bff/modules/pandora/orderCore/types.d.ts +5 -2
- package/cjs/bff/modules/pandora/orderQuery/types.d.ts +9 -4
- package/cjs/bff/modules/pandora/pointRule/service.d.ts +53 -0
- package/cjs/bff/modules/pandora/pointRule/service.js +75 -0
- package/cjs/bff/modules/pandora/pointRule/types.d.ts +38 -0
- package/cjs/bff/modules/pandora/pointRule/types.js +2 -0
- package/cjs/bff/modules/pandora/pointsMall/service.d.ts +47 -0
- package/cjs/bff/modules/pandora/pointsMall/service.js +67 -0
- package/cjs/bff/modules/pandora/pointsMall/types.d.ts +177 -0
- package/cjs/bff/modules/pandora/pointsMall/types.js +2 -0
- package/cjs/bff/modules/pandora/product/service.d.ts +20 -2
- package/cjs/bff/modules/pandora/product/service.js +24 -0
- package/cjs/bff/modules/pandora/product/types.d.ts +258 -16
- package/cjs/bff/modules/pandora/productExp/service.d.ts +18 -6
- package/cjs/bff/modules/pandora/productExp/service.js +25 -9
- package/cjs/bff/modules/pandora/productExp/types.d.ts +84 -16
- package/cjs/bff/modules/pandora/productLive/service.d.ts +1 -1
- package/cjs/bff/modules/pandora/productLive/types.d.ts +11 -1
- package/cjs/bff/modules/pandora/role/service.d.ts +47 -0
- package/cjs/bff/modules/pandora/role/service.js +67 -0
- package/cjs/bff/modules/pandora/role/types.d.ts +135 -0
- package/cjs/bff/modules/pandora/role/types.js +2 -0
- package/cjs/bff/modules/pandora/room/service.d.ts +6 -0
- package/cjs/bff/modules/pandora/room/service.js +8 -0
- package/cjs/bff/modules/pandora/room/types.d.ts +21 -2
- package/cjs/bff/modules/pandora/store/service.d.ts +95 -0
- package/cjs/bff/modules/pandora/store/service.js +131 -0
- package/cjs/bff/modules/pandora/store/types.d.ts +879 -0
- package/cjs/bff/modules/pandora/store/types.js +2 -0
- package/cjs/bff/modules/pandora/storeClerk/service.d.ts +41 -0
- package/cjs/bff/modules/pandora/storeClerk/service.js +59 -0
- package/cjs/bff/modules/pandora/storeClerk/types.d.ts +130 -0
- package/cjs/bff/modules/pandora/storeClerk/types.js +2 -0
- package/cjs/bff/modules/pandora/storeManager/service.d.ts +47 -0
- package/cjs/bff/modules/pandora/storeManager/service.js +67 -0
- package/cjs/bff/modules/pandora/storeManager/types.d.ts +148 -0
- package/cjs/bff/modules/pandora/storeManager/types.js +2 -0
- package/cjs/bff/modules/pandora/task/service.d.ts +65 -0
- package/cjs/bff/modules/pandora/task/service.js +91 -0
- package/cjs/bff/modules/pandora/task/types.d.ts +36 -0
- package/cjs/bff/modules/pandora/task/types.js +2 -0
- package/cjs/bff/modules/pandora/taskWatch/service.d.ts +23 -0
- package/cjs/bff/modules/pandora/taskWatch/service.js +35 -0
- package/cjs/bff/modules/pandora/taskWatch/types.d.ts +15 -0
- package/cjs/bff/modules/pandora/taskWatch/types.js +2 -0
- package/cjs/bff/modules/pandora/user/service.d.ts +20 -0
- package/cjs/bff/modules/pandora/user/service.js +46 -0
- package/cjs/bff/modules/pandora/user/types.d.ts +194 -0
- package/cjs/bff/modules/pandora/user/types.js +2 -0
- package/cjs/bff/modules/pandora/userManager/service/address.service.d.ts +12 -0
- package/cjs/bff/modules/pandora/userManager/service/address.service.js +32 -0
- package/cjs/bff/modules/pandora/userManager/service/coupon.service.d.ts +11 -0
- package/cjs/bff/modules/pandora/userManager/service/coupon.service.js +29 -0
- package/cjs/bff/modules/pandora/userManager/service/index.d.ts +5 -0
- package/cjs/bff/modules/pandora/userManager/service/index.js +21 -0
- package/cjs/bff/modules/pandora/userManager/service/point.service.d.ts +13 -0
- package/cjs/bff/modules/pandora/userManager/service/point.service.js +35 -0
- package/cjs/bff/modules/pandora/userManager/service/region.service.d.ts +14 -0
- package/cjs/bff/modules/pandora/userManager/service/region.service.js +38 -0
- package/cjs/bff/modules/pandora/userManager/service/user.service.d.ts +12 -0
- package/cjs/bff/modules/pandora/userManager/service/user.service.js +32 -0
- package/cjs/bff/modules/pandora/userManager/types/address.types.d.ts +94 -0
- package/cjs/bff/modules/pandora/userManager/types/address.types.js +2 -0
- package/cjs/bff/modules/pandora/userManager/types/coupon.types.d.ts +99 -0
- package/cjs/bff/modules/pandora/userManager/types/coupon.types.js +2 -0
- package/cjs/bff/modules/pandora/userManager/types/index.d.ts +5 -0
- package/cjs/bff/modules/pandora/userManager/types/index.js +21 -0
- package/cjs/bff/modules/pandora/userManager/types/point.types.d.ts +113 -0
- package/cjs/bff/modules/pandora/userManager/types/point.types.js +2 -0
- package/cjs/bff/modules/pandora/userManager/types/region.types.d.ts +77 -0
- package/cjs/bff/modules/pandora/userManager/types/region.types.js +2 -0
- package/cjs/bff/modules/pandora/userManager/types/user.types.d.ts +124 -0
- package/cjs/bff/modules/pandora/userManager/types/user.types.js +2 -0
- package/cjs/bff/request/strategy.js +1 -0
- package/cjs/enums.d.ts +7 -0
- package/cjs/enums.js +22 -3
- package/cjs/index.d.ts +91 -3
- package/cjs/index.js +69 -16
- package/cjs/utils/env.js +1 -0
- package/cjs/utils/string.js +1 -0
- package/esm/bff/modules/miniprogram/auth/service.d.ts +46 -0
- package/esm/bff/modules/miniprogram/auth/service.mjs +59 -0
- package/esm/bff/modules/miniprogram/auth/types.d.ts +133 -0
- package/esm/bff/modules/miniprogram/auth/types.mjs +1 -0
- package/esm/bff/modules/miniprogram/franchisee/service.d.ts +12 -0
- package/esm/bff/modules/miniprogram/franchisee/service.mjs +15 -0
- package/esm/bff/modules/miniprogram/franchisee/types.d.ts +25 -0
- package/esm/bff/modules/miniprogram/franchisee/types.mjs +1 -0
- package/esm/bff/modules/pandora/auth/service.d.ts +28 -0
- package/esm/bff/modules/pandora/auth/service.mjs +35 -0
- package/esm/bff/modules/pandora/auth/types.d.ts +94 -0
- package/esm/bff/modules/pandora/auth/types.mjs +1 -0
- package/esm/bff/modules/pandora/award/service.d.ts +17 -0
- package/esm/bff/modules/pandora/award/service.mjs +20 -0
- package/esm/bff/modules/pandora/award/types.d.ts +17 -0
- package/esm/bff/modules/pandora/award/types.mjs +1 -0
- package/esm/bff/modules/pandora/bd/service.d.ts +47 -0
- package/esm/bff/modules/pandora/bd/service.mjs +60 -0
- package/esm/bff/modules/pandora/bd/types.d.ts +157 -0
- package/esm/bff/modules/pandora/bd/types.mjs +1 -0
- package/esm/bff/modules/pandora/bdm/service.d.ts +35 -0
- package/esm/bff/modules/pandora/bdm/service.mjs +44 -0
- package/esm/bff/modules/pandora/bdm/types.d.ts +104 -0
- package/esm/bff/modules/pandora/bdm/types.mjs +1 -0
- package/esm/bff/modules/pandora/common/service.d.ts +34 -0
- package/esm/bff/modules/pandora/common/service.mjs +43 -0
- package/esm/bff/modules/pandora/common/types.d.ts +125 -0
- package/esm/bff/modules/pandora/common/types.mjs +1 -0
- package/esm/bff/modules/pandora/coupon/service.d.ts +59 -0
- package/esm/bff/modules/pandora/coupon/service.mjs +76 -0
- package/esm/bff/modules/pandora/coupon/types.d.ts +409 -0
- package/esm/bff/modules/pandora/coupon/types.mjs +1 -0
- package/esm/bff/modules/pandora/franchisee/service.d.ts +19 -0
- package/esm/bff/modules/pandora/franchisee/service.mjs +36 -0
- package/esm/bff/modules/pandora/franchisee/types.d.ts +204 -0
- package/esm/bff/modules/pandora/franchisee/types.mjs +1 -0
- package/esm/bff/modules/pandora/orderCore/service.d.ts +7 -1
- package/esm/bff/modules/pandora/orderCore/service.mjs +9 -1
- package/esm/bff/modules/pandora/orderCore/types.d.ts +5 -2
- package/esm/bff/modules/pandora/orderQuery/types.d.ts +9 -4
- package/esm/bff/modules/pandora/pointRule/service.d.ts +53 -0
- package/esm/bff/modules/pandora/pointRule/service.mjs +68 -0
- package/esm/bff/modules/pandora/pointRule/types.d.ts +38 -0
- package/esm/bff/modules/pandora/pointRule/types.mjs +1 -0
- package/esm/bff/modules/pandora/pointsMall/service.d.ts +47 -0
- package/esm/bff/modules/pandora/pointsMall/service.mjs +60 -0
- package/esm/bff/modules/pandora/pointsMall/types.d.ts +177 -0
- package/esm/bff/modules/pandora/pointsMall/types.mjs +1 -0
- package/esm/bff/modules/pandora/product/service.d.ts +20 -2
- package/esm/bff/modules/pandora/product/service.mjs +24 -0
- package/esm/bff/modules/pandora/product/types.d.ts +258 -16
- package/esm/bff/modules/pandora/productExp/service.d.ts +18 -6
- package/esm/bff/modules/pandora/productExp/service.mjs +25 -9
- package/esm/bff/modules/pandora/productExp/types.d.ts +84 -16
- package/esm/bff/modules/pandora/productLive/service.d.ts +1 -1
- package/esm/bff/modules/pandora/productLive/types.d.ts +11 -1
- package/esm/bff/modules/pandora/role/service.d.ts +47 -0
- package/esm/bff/modules/pandora/role/service.mjs +60 -0
- package/esm/bff/modules/pandora/role/types.d.ts +135 -0
- package/esm/bff/modules/pandora/role/types.mjs +1 -0
- package/esm/bff/modules/pandora/room/service.d.ts +6 -0
- package/esm/bff/modules/pandora/room/service.mjs +8 -0
- package/esm/bff/modules/pandora/room/types.d.ts +21 -2
- package/esm/bff/modules/pandora/store/service.d.ts +95 -0
- package/esm/bff/modules/pandora/store/service.mjs +124 -0
- package/esm/bff/modules/pandora/store/types.d.ts +879 -0
- package/esm/bff/modules/pandora/store/types.mjs +1 -0
- package/esm/bff/modules/pandora/storeClerk/service.d.ts +41 -0
- package/esm/bff/modules/pandora/storeClerk/service.mjs +52 -0
- package/esm/bff/modules/pandora/storeClerk/types.d.ts +130 -0
- package/esm/bff/modules/pandora/storeClerk/types.mjs +1 -0
- package/esm/bff/modules/pandora/storeManager/service.d.ts +47 -0
- package/esm/bff/modules/pandora/storeManager/service.mjs +60 -0
- package/esm/bff/modules/pandora/storeManager/types.d.ts +148 -0
- package/esm/bff/modules/pandora/storeManager/types.mjs +1 -0
- package/esm/bff/modules/pandora/task/service.d.ts +65 -0
- package/esm/bff/modules/pandora/task/service.mjs +84 -0
- package/esm/bff/modules/pandora/task/types.d.ts +36 -0
- package/esm/bff/modules/pandora/task/types.mjs +1 -0
- package/esm/bff/modules/pandora/taskWatch/service.d.ts +23 -0
- package/esm/bff/modules/pandora/taskWatch/service.mjs +28 -0
- package/esm/bff/modules/pandora/taskWatch/types.d.ts +15 -0
- package/esm/bff/modules/pandora/taskWatch/types.mjs +1 -0
- package/esm/bff/modules/pandora/user/service.d.ts +20 -0
- package/esm/bff/modules/pandora/user/service.mjs +39 -0
- package/esm/bff/modules/pandora/user/types.d.ts +194 -0
- package/esm/bff/modules/pandora/user/types.mjs +1 -0
- package/esm/bff/modules/pandora/userManager/service/address.service.d.ts +12 -0
- package/esm/bff/modules/pandora/userManager/service/address.service.mjs +25 -0
- package/esm/bff/modules/pandora/userManager/service/coupon.service.d.ts +11 -0
- package/esm/bff/modules/pandora/userManager/service/coupon.service.mjs +22 -0
- package/esm/bff/modules/pandora/userManager/service/index.d.ts +5 -0
- package/esm/bff/modules/pandora/userManager/service/index.mjs +5 -0
- package/esm/bff/modules/pandora/userManager/service/point.service.d.ts +13 -0
- package/esm/bff/modules/pandora/userManager/service/point.service.mjs +28 -0
- package/esm/bff/modules/pandora/userManager/service/region.service.d.ts +14 -0
- package/esm/bff/modules/pandora/userManager/service/region.service.mjs +31 -0
- package/esm/bff/modules/pandora/userManager/service/user.service.d.ts +12 -0
- package/esm/bff/modules/pandora/userManager/service/user.service.mjs +25 -0
- package/esm/bff/modules/pandora/userManager/types/address.types.d.ts +94 -0
- package/esm/bff/modules/pandora/userManager/types/address.types.mjs +1 -0
- package/esm/bff/modules/pandora/userManager/types/coupon.types.d.ts +99 -0
- package/esm/bff/modules/pandora/userManager/types/coupon.types.mjs +1 -0
- package/esm/bff/modules/pandora/userManager/types/index.d.ts +5 -0
- package/esm/bff/modules/pandora/userManager/types/index.mjs +5 -0
- package/esm/bff/modules/pandora/userManager/types/point.types.d.ts +113 -0
- package/esm/bff/modules/pandora/userManager/types/point.types.mjs +1 -0
- package/esm/bff/modules/pandora/userManager/types/region.types.d.ts +77 -0
- package/esm/bff/modules/pandora/userManager/types/region.types.mjs +1 -0
- package/esm/bff/modules/pandora/userManager/types/user.types.d.ts +124 -0
- package/esm/bff/modules/pandora/userManager/types/user.types.mjs +1 -0
- package/esm/bff/request/strategy.mjs +1 -0
- package/esm/enums.d.ts +7 -0
- package/esm/enums.mjs +12 -0
- package/esm/index.d.ts +91 -3
- package/esm/index.mjs +55 -3
- package/esm/utils/env.mjs +1 -0
- package/esm/utils/string.mjs +1 -0
- package/package.json +10 -3
package/cjs/index.d.ts
CHANGED
|
@@ -1,10 +1,35 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { PandoraStoreService } from './bff/modules/pandora/store/service';
|
|
2
|
+
import { PandoraStoreUserRelationService } from './bff/modules/pandora/storeUserRelation/service';
|
|
2
3
|
import { MiniProgramDemoService } from './bff/modules/miniprogram/demo/service';
|
|
4
|
+
import { MiniprogramAuthServiceClass } from './bff/modules/miniprogram/auth/service';
|
|
5
|
+
import { PandoraAuthService } from './bff/modules/pandora/auth/service';
|
|
6
|
+
import { PandoraBDService } from './bff/modules/pandora/bd/service';
|
|
7
|
+
import { PandoraBDMService } from './bff/modules/pandora/bdm/service';
|
|
8
|
+
import { PandoraCommonService } from './bff/modules/pandora/common/service';
|
|
9
|
+
import { PandoraCouponService } from './bff/modules/pandora/coupon/service';
|
|
10
|
+
import { PandoraExampleService } from './bff/modules/pandora/example/service';
|
|
3
11
|
import { PandoraProductService } from './bff/modules/pandora/product/service';
|
|
4
12
|
import { PandoraProductExpService } from './bff/modules/pandora/productExp/service';
|
|
5
13
|
import { PandoraProductLiveService } from './bff/modules/pandora/productLive/service';
|
|
14
|
+
import { PandoraRoleService } from './bff/modules/pandora/role/service';
|
|
15
|
+
import { PandoraRoomService } from './bff/modules/pandora/room/service';
|
|
16
|
+
import { PandoraStoreClerkService } from './bff/modules/pandora/storeClerk/service';
|
|
17
|
+
import { PandoraStoreManagerService } from './bff/modules/pandora/storeManager/service';
|
|
18
|
+
import { PandoraUserService } from './bff/modules/pandora/user/service';
|
|
19
|
+
import { PandoraUserManagementService } from './bff/modules/pandora/userManager/service/user.service';
|
|
20
|
+
import { PandoraPointManagementService } from './bff/modules/pandora/userManager/service/point.service';
|
|
21
|
+
import { PandoraCouponManagementService } from './bff/modules/pandora/userManager/service/coupon.service';
|
|
22
|
+
import { PandoraAddressManagementService } from './bff/modules/pandora/userManager/service/address.service';
|
|
23
|
+
import { PandoraRegionManagementService } from './bff/modules/pandora/userManager/service/region.service';
|
|
24
|
+
import { PandoraPointsMallService } from './bff/modules/pandora/pointsMall/service';
|
|
6
25
|
import { PandoraOrderQueryService } from './bff/modules/pandora/orderQuery/service';
|
|
7
26
|
import { PandoraOrderCoreService } from './bff/modules/pandora/orderCore/service';
|
|
27
|
+
import { PandoraTaskService } from './bff/modules/pandora/task/service';
|
|
28
|
+
import { PandoraTaskWatchService } from './bff/modules/pandora/taskWatch/service';
|
|
29
|
+
import { PandoraPointRuleService } from './bff/modules/pandora/pointRule/service';
|
|
30
|
+
import { PandoraAwardService } from './bff/modules/pandora/award/service';
|
|
31
|
+
import { PandoraFranchiseeService } from './bff/modules/pandora/franchisee/service';
|
|
32
|
+
import { MiniprogramFranchiseeService } from './bff/modules/miniprogram/franchisee/service';
|
|
8
33
|
import { SdkOptions } from './types';
|
|
9
34
|
/**
|
|
10
35
|
* Pandora 平台 SDK(管理后台)
|
|
@@ -19,11 +44,46 @@ export declare class PandoraSDK {
|
|
|
19
44
|
* Pandora 示例服务模块
|
|
20
45
|
*/
|
|
21
46
|
example: PandoraExampleService;
|
|
47
|
+
auth: PandoraAuthService;
|
|
48
|
+
bd: PandoraBDService;
|
|
49
|
+
bdm: PandoraBDMService;
|
|
50
|
+
common: PandoraCommonService;
|
|
51
|
+
role: PandoraRoleService;
|
|
52
|
+
storeClerk: PandoraStoreClerkService;
|
|
53
|
+
storeManager: PandoraStoreManagerService;
|
|
54
|
+
user: PandoraUserService;
|
|
55
|
+
userManagement: PandoraUserManagementService;
|
|
56
|
+
pointManagement: PandoraPointManagementService;
|
|
57
|
+
couponManagement: PandoraCouponManagementService;
|
|
58
|
+
addressManagement: PandoraAddressManagementService;
|
|
59
|
+
regionManagement: PandoraRegionManagementService;
|
|
22
60
|
product: PandoraProductService;
|
|
23
61
|
productExp: PandoraProductExpService;
|
|
24
62
|
productLive: PandoraProductLiveService;
|
|
63
|
+
coupon: PandoraCouponService;
|
|
64
|
+
pointMall: PandoraPointsMallService;
|
|
65
|
+
/**
|
|
66
|
+
* Pandora 门店服务模块
|
|
67
|
+
*/
|
|
68
|
+
store: PandoraStoreService;
|
|
69
|
+
/**
|
|
70
|
+
* Pandora 门店用户关系服务模块
|
|
71
|
+
*/
|
|
72
|
+
storeUserRelation: PandoraStoreUserRelationService;
|
|
73
|
+
award: PandoraAwardService;
|
|
74
|
+
/**
|
|
75
|
+
* 直播间模块
|
|
76
|
+
*/
|
|
77
|
+
room: PandoraRoomService;
|
|
25
78
|
orderQuery: PandoraOrderQueryService;
|
|
26
79
|
orderCore: PandoraOrderCoreService;
|
|
80
|
+
task: PandoraTaskService;
|
|
81
|
+
taskWatch: PandoraTaskWatchService;
|
|
82
|
+
pointRule: PandoraPointRuleService;
|
|
83
|
+
/**
|
|
84
|
+
* 加盟商模块
|
|
85
|
+
*/
|
|
86
|
+
franchisee: PandoraFranchiseeService;
|
|
27
87
|
/**
|
|
28
88
|
* 使用配置选项初始化 Pandora SDK
|
|
29
89
|
* @param options - SDK 配置,包含凭证回调函数
|
|
@@ -43,20 +103,48 @@ export declare class MiniProgramSDK {
|
|
|
43
103
|
* 小程序 Demo 服务模块
|
|
44
104
|
*/
|
|
45
105
|
demo: MiniProgramDemoService;
|
|
106
|
+
/**
|
|
107
|
+
* 小程序认证服务模块
|
|
108
|
+
*/
|
|
109
|
+
auth: MiniprogramAuthServiceClass;
|
|
110
|
+
/**
|
|
111
|
+
* 加盟商模块
|
|
112
|
+
*/
|
|
113
|
+
franchisee: MiniprogramFranchiseeService;
|
|
46
114
|
/**
|
|
47
115
|
* 使用配置选项初始化小程序 SDK
|
|
48
116
|
* @param options - SDK 配置,包含凭证回调函数
|
|
49
117
|
*/
|
|
50
118
|
constructor(options: SdkOptions);
|
|
51
119
|
}
|
|
52
|
-
export {
|
|
53
|
-
export {
|
|
120
|
+
export { BizError, SdkError, SystemError } from './errors';
|
|
121
|
+
export { IRequestStrategy, SdkOptions, StandardResponse } from './types';
|
|
54
122
|
export * from './enums';
|
|
55
123
|
export { Service as MiniProgramDemoTypes } from './bff/modules/miniprogram/demo/types';
|
|
124
|
+
export { MiniprogramAuthService as MiniprogramAuthServiceTypes } from './bff/modules/miniprogram/auth/types';
|
|
56
125
|
export { Service as PandoraExampleTypes } from './bff/modules/pandora/example/types';
|
|
126
|
+
export { StoreService as PandoraStoreServiceTypes } from './bff/modules/pandora/store/types';
|
|
127
|
+
export { StoreUserRelationService as PandoraStoreUserRelationServiceTypes } from './bff/modules/pandora/storeUserRelation/types';
|
|
128
|
+
export { PandoraAuthService as PandoraAuthServiceTypes } from './bff/modules/pandora/auth/types';
|
|
129
|
+
export { PandoraBDService as PandoraBDServiceTypes } from './bff/modules/pandora/bd/types';
|
|
130
|
+
export { PandoraBDMService as PandoraBDMServiceTypes } from './bff/modules/pandora/bdm/types';
|
|
131
|
+
export { PandoraCommonService as PandoraCommonServiceTypes } from './bff/modules/pandora/common/types';
|
|
132
|
+
export { PandoraRoleService as PandoraRoleServiceTypes } from './bff/modules/pandora/role/types';
|
|
133
|
+
export { PandoraStoreClerkService as PandoraStoreClerkServiceTypes } from './bff/modules/pandora/storeClerk/types';
|
|
134
|
+
export { PandoraStoreManagerService as PandoraStoreManagerServiceTypes } from './bff/modules/pandora/storeManager/types';
|
|
135
|
+
export { PandoraUserService as PandoraUserServiceTypes } from './bff/modules/pandora/user/types';
|
|
136
|
+
export * from './bff/modules/pandora/userManager/types';
|
|
57
137
|
export { PandoraProductService as PandoraProductServiceTypes } from './bff/modules/pandora/product/types';
|
|
58
138
|
export { PandoraProductExpService as PandoraProductExpServiceTypes } from './bff/modules/pandora/productExp/types';
|
|
59
139
|
export { PandoraProductLiveService as PandoraProductLiveServiceTypes } from './bff/modules/pandora/productLive/types';
|
|
60
140
|
export { PandoraOrderQueryService as PandoraOrderQueryServiceTypes } from './bff/modules/pandora/orderQuery/types';
|
|
61
141
|
export { PandoraOrderCoreService as PandoraOrderCoreServiceTypes } from './bff/modules/pandora/orderCore/types';
|
|
142
|
+
export { PandoraTaskService as PandoraTaskServiceTypes } from './bff/modules/pandora/task/types';
|
|
143
|
+
export { PandoraTaskWatchService as PandoraTaskWatchServiceTypes } from './bff/modules/pandora/taskWatch/types';
|
|
144
|
+
export { PandoraPointRuleService as PandoraPointRuleServiceTypes } from './bff/modules/pandora/pointRule/types';
|
|
62
145
|
export { RoomService as PandoraRoomServiceTypes } from './bff/modules/pandora/room/types';
|
|
146
|
+
export { CouponService as PandoraCouponServiceTypes } from './bff/modules/pandora/coupon/types';
|
|
147
|
+
export { PointMallService as PointMallServiceTypes } from './bff/modules/pandora/pointsMall/types';
|
|
148
|
+
export { AwardService as PandoraAwardServiceTypes } from './bff/modules/pandora/award/types';
|
|
149
|
+
export { PandoraFranchiseeService as PandoraFranchiseeServiceTypes } from './bff/modules/pandora/franchisee/types';
|
|
150
|
+
export { MiniprogramFranchiseeService as MiniprogramFranchiseeServiceTypes } from './bff/modules/miniprogram/franchisee/types';
|
package/cjs/index.js
CHANGED
|
@@ -14,15 +14,40 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
exports.
|
|
17
|
+
exports.PandoraStoreUserRelationServiceTypes = exports.SystemError = exports.SdkError = exports.BizError = exports.MiniProgramSDK = exports.PandoraSDK = void 0;
|
|
18
|
+
const service_1 = require("./bff/modules/pandora/store/service");
|
|
19
|
+
const service_2 = require("./bff/modules/pandora/storeUserRelation/service");
|
|
20
|
+
const service_3 = require("./bff/modules/miniprogram/demo/service");
|
|
21
|
+
const service_4 = require("./bff/modules/miniprogram/auth/service");
|
|
22
|
+
const service_5 = require("./bff/modules/pandora/auth/service");
|
|
23
|
+
const service_6 = require("./bff/modules/pandora/bd/service");
|
|
24
|
+
const service_7 = require("./bff/modules/pandora/bdm/service");
|
|
25
|
+
const service_8 = require("./bff/modules/pandora/common/service");
|
|
26
|
+
const service_9 = require("./bff/modules/pandora/coupon/service");
|
|
27
|
+
const service_10 = require("./bff/modules/pandora/example/service");
|
|
28
|
+
const service_11 = require("./bff/modules/pandora/product/service");
|
|
29
|
+
const service_12 = require("./bff/modules/pandora/productExp/service");
|
|
30
|
+
const service_13 = require("./bff/modules/pandora/productLive/service");
|
|
31
|
+
const service_14 = require("./bff/modules/pandora/role/service");
|
|
32
|
+
const service_15 = require("./bff/modules/pandora/room/service");
|
|
33
|
+
const service_16 = require("./bff/modules/pandora/storeClerk/service");
|
|
34
|
+
const service_17 = require("./bff/modules/pandora/storeManager/service");
|
|
35
|
+
const service_18 = require("./bff/modules/pandora/user/service");
|
|
36
|
+
const user_service_1 = require("./bff/modules/pandora/userManager/service/user.service");
|
|
37
|
+
const point_service_1 = require("./bff/modules/pandora/userManager/service/point.service");
|
|
38
|
+
const coupon_service_1 = require("./bff/modules/pandora/userManager/service/coupon.service");
|
|
39
|
+
const address_service_1 = require("./bff/modules/pandora/userManager/service/address.service");
|
|
40
|
+
const region_service_1 = require("./bff/modules/pandora/userManager/service/region.service");
|
|
18
41
|
const client_1 = require("./bff/request/client");
|
|
19
|
-
const
|
|
20
|
-
const
|
|
21
|
-
const
|
|
22
|
-
const
|
|
23
|
-
const
|
|
24
|
-
const
|
|
25
|
-
const
|
|
42
|
+
const service_19 = require("./bff/modules/pandora/pointsMall/service");
|
|
43
|
+
const service_20 = require("./bff/modules/pandora/orderQuery/service");
|
|
44
|
+
const service_21 = require("./bff/modules/pandora/orderCore/service");
|
|
45
|
+
const service_22 = require("./bff/modules/pandora/task/service");
|
|
46
|
+
const service_23 = require("./bff/modules/pandora/taskWatch/service");
|
|
47
|
+
const service_24 = require("./bff/modules/pandora/pointRule/service");
|
|
48
|
+
const service_25 = require("./bff/modules/pandora/award/service");
|
|
49
|
+
const service_26 = require("./bff/modules/pandora/franchisee/service");
|
|
50
|
+
const service_27 = require("./bff/modules/miniprogram/franchisee/service");
|
|
26
51
|
/**
|
|
27
52
|
* Pandora 平台 SDK(管理后台)
|
|
28
53
|
* 包含所有 Pandora 平台相关的服务
|
|
@@ -36,12 +61,35 @@ class PandoraSDK {
|
|
|
36
61
|
// 使用提供的选项初始化 HttpClient
|
|
37
62
|
this.http = new client_1.HttpClient(options);
|
|
38
63
|
// 使用 HttpClient 实例化所有 Pandora 服务模块
|
|
39
|
-
this.example = new
|
|
40
|
-
this.
|
|
41
|
-
this.
|
|
42
|
-
this.
|
|
43
|
-
this.
|
|
44
|
-
this.
|
|
64
|
+
this.example = new service_10.PandoraExampleService(this.http);
|
|
65
|
+
this.auth = new service_5.PandoraAuthService(this.http);
|
|
66
|
+
this.bd = new service_6.PandoraBDService(this.http);
|
|
67
|
+
this.bdm = new service_7.PandoraBDMService(this.http);
|
|
68
|
+
this.common = new service_8.PandoraCommonService(this.http);
|
|
69
|
+
this.role = new service_14.PandoraRoleService(this.http);
|
|
70
|
+
this.storeClerk = new service_16.PandoraStoreClerkService(this.http);
|
|
71
|
+
this.storeManager = new service_17.PandoraStoreManagerService(this.http);
|
|
72
|
+
this.user = new service_18.PandoraUserService(this.http);
|
|
73
|
+
this.product = new service_11.PandoraProductService(this.http);
|
|
74
|
+
this.productExp = new service_12.PandoraProductExpService(this.http);
|
|
75
|
+
this.productLive = new service_13.PandoraProductLiveService(this.http);
|
|
76
|
+
this.store = new service_1.PandoraStoreService(this.http);
|
|
77
|
+
this.storeUserRelation = new service_2.PandoraStoreUserRelationService(this.http);
|
|
78
|
+
this.room = new service_15.PandoraRoomService(this.http);
|
|
79
|
+
this.coupon = new service_9.PandoraCouponService(this.http);
|
|
80
|
+
this.userManagement = new user_service_1.PandoraUserManagementService(this.http);
|
|
81
|
+
this.pointManagement = new point_service_1.PandoraPointManagementService(this.http);
|
|
82
|
+
this.couponManagement = new coupon_service_1.PandoraCouponManagementService(this.http);
|
|
83
|
+
this.addressManagement = new address_service_1.PandoraAddressManagementService(this.http);
|
|
84
|
+
this.regionManagement = new region_service_1.PandoraRegionManagementService(this.http);
|
|
85
|
+
this.pointMall = new service_19.PandoraPointsMallService(this.http);
|
|
86
|
+
this.orderQuery = new service_20.PandoraOrderQueryService(this.http);
|
|
87
|
+
this.orderCore = new service_21.PandoraOrderCoreService(this.http);
|
|
88
|
+
this.task = new service_22.PandoraTaskService(this.http);
|
|
89
|
+
this.taskWatch = new service_23.PandoraTaskWatchService(this.http);
|
|
90
|
+
this.pointRule = new service_24.PandoraPointRuleService(this.http);
|
|
91
|
+
this.award = new service_25.PandoraAwardService(this.http);
|
|
92
|
+
this.franchisee = new service_26.PandoraFranchiseeService(this.http);
|
|
45
93
|
}
|
|
46
94
|
}
|
|
47
95
|
exports.PandoraSDK = PandoraSDK;
|
|
@@ -58,15 +106,20 @@ class MiniProgramSDK {
|
|
|
58
106
|
// 使用提供的选项初始化 HttpClient
|
|
59
107
|
this.http = new client_1.HttpClient(options);
|
|
60
108
|
// 使用 HttpClient 实例化所有小程序服务模块
|
|
61
|
-
this.demo = new
|
|
109
|
+
this.demo = new service_3.MiniProgramDemoService(this.http);
|
|
110
|
+
this.auth = new service_4.MiniprogramAuthServiceClass(this.http);
|
|
111
|
+
this.franchisee = new service_27.MiniprogramFranchiseeService(this.http);
|
|
62
112
|
}
|
|
63
113
|
}
|
|
64
114
|
exports.MiniProgramSDK = MiniProgramSDK;
|
|
65
115
|
// ==================== 导出 ====================
|
|
66
116
|
// 错误类
|
|
67
117
|
var errors_1 = require("./errors");
|
|
68
|
-
Object.defineProperty(exports, "SdkError", { enumerable: true, get: function () { return errors_1.SdkError; } });
|
|
69
118
|
Object.defineProperty(exports, "BizError", { enumerable: true, get: function () { return errors_1.BizError; } });
|
|
119
|
+
Object.defineProperty(exports, "SdkError", { enumerable: true, get: function () { return errors_1.SdkError; } });
|
|
70
120
|
Object.defineProperty(exports, "SystemError", { enumerable: true, get: function () { return errors_1.SystemError; } });
|
|
71
121
|
// 枚举和常量
|
|
72
122
|
__exportStar(require("./enums"), exports);
|
|
123
|
+
var types_1 = require("./bff/modules/pandora/storeUserRelation/types");
|
|
124
|
+
Object.defineProperty(exports, "PandoraStoreUserRelationServiceTypes", { enumerable: true, get: function () { return types_1.StoreUserRelationService; } });
|
|
125
|
+
__exportStar(require("./bff/modules/pandora/userManager/types"), exports);
|
package/cjs/utils/env.js
CHANGED
package/cjs/utils/string.js
CHANGED
|
@@ -43,6 +43,7 @@ function generateUUID() {
|
|
|
43
43
|
return `${hex.slice(0, 8)}-${hex.slice(8, 12)}-${hex.slice(12, 16)}-${hex.slice(16, 20)}-${hex.slice(20, 32)}`;
|
|
44
44
|
}
|
|
45
45
|
// 降级方案 2:微信小程序环境(尝试使用 wx.getRandomValues)
|
|
46
|
+
// @ts-ignore
|
|
46
47
|
if (typeof wx !== 'undefined' && typeof wx.getRandomValues === 'function') {
|
|
47
48
|
try {
|
|
48
49
|
const bytes = new Uint8Array(16);
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { MiniprogramAuthService as Service } from './types';
|
|
2
|
+
import BaseService from '../../BaseService';
|
|
3
|
+
import type { StandardResponse } from '../../../../types';
|
|
4
|
+
/**
|
|
5
|
+
* MiniprogramAuthService - 小程序认证服务模块
|
|
6
|
+
* 提供小程序认证相关的 API 方法
|
|
7
|
+
* 平台: miniprogram
|
|
8
|
+
*/
|
|
9
|
+
export declare class MiniprogramAuthServiceClass extends BaseService implements Service.AuthController {
|
|
10
|
+
protected prefixUrl: string;
|
|
11
|
+
/**
|
|
12
|
+
* 小程序端获取用户菜单权限
|
|
13
|
+
* @returns Promise,解析为标准响应格式
|
|
14
|
+
*/
|
|
15
|
+
getUserMenuPermissions(): Promise<StandardResponse<Service.Response.getUserMenuPermissions>>;
|
|
16
|
+
/**
|
|
17
|
+
* 获取微信UnionId
|
|
18
|
+
* @param request - 请求参数
|
|
19
|
+
* @returns Promise,解析为标准响应格式
|
|
20
|
+
*/
|
|
21
|
+
getUnionId(request: Service.Request.getUnionId): Promise<StandardResponse<Service.Response.getUnionId>>;
|
|
22
|
+
/**
|
|
23
|
+
* UnionId登录
|
|
24
|
+
* @param request - 请求参数
|
|
25
|
+
* @returns Promise,解析为标准响应格式
|
|
26
|
+
*/
|
|
27
|
+
unionIdLogin(request: Service.Request.unionIdLogin): Promise<StandardResponse<Service.Response.unionIdLogin>>;
|
|
28
|
+
/**
|
|
29
|
+
* 获取微信绑定手机号
|
|
30
|
+
* @param request - 请求参数
|
|
31
|
+
* @returns Promise,解析为标准响应格式
|
|
32
|
+
*/
|
|
33
|
+
getBindPhone(request: Service.Request.getBindPhone): Promise<StandardResponse<Service.Response.getBindPhone>>;
|
|
34
|
+
/**
|
|
35
|
+
* 绑定手机号到UnionId
|
|
36
|
+
* @param request - 请求参数
|
|
37
|
+
* @returns Promise,解析为标准响应格式
|
|
38
|
+
*/
|
|
39
|
+
unionIdBindPhone(request: Service.Request.bindPhoneToUnionId): Promise<StandardResponse<Service.Response.bindPhoneToUnionId>>;
|
|
40
|
+
/**
|
|
41
|
+
* 账号密码登录(新格式)
|
|
42
|
+
* @param request - 请求参数
|
|
43
|
+
* @returns Promise,解析为标准响应格式
|
|
44
|
+
*/
|
|
45
|
+
accountLogin(request: Service.Request.accountLogin): Promise<StandardResponse<Service.Response.accountLogin>>;
|
|
46
|
+
}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import BaseService from '../../BaseService.mjs';
|
|
2
|
+
/**
|
|
3
|
+
* MiniprogramAuthService - 小程序认证服务模块
|
|
4
|
+
* 提供小程序认证相关的 API 方法
|
|
5
|
+
* 平台: miniprogram
|
|
6
|
+
*/
|
|
7
|
+
export class MiniprogramAuthServiceClass extends BaseService {
|
|
8
|
+
constructor() {
|
|
9
|
+
super(...arguments);
|
|
10
|
+
this.prefixUrl = '/miniprogram/auth';
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* 小程序端获取用户菜单权限
|
|
14
|
+
* @returns Promise,解析为标准响应格式
|
|
15
|
+
*/
|
|
16
|
+
getUserMenuPermissions() {
|
|
17
|
+
return this.request(this.getUserMenuPermissions, {});
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* 获取微信UnionId
|
|
21
|
+
* @param request - 请求参数
|
|
22
|
+
* @returns Promise,解析为标准响应格式
|
|
23
|
+
*/
|
|
24
|
+
getUnionId(request) {
|
|
25
|
+
return this.request(this.getUnionId, request);
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* UnionId登录
|
|
29
|
+
* @param request - 请求参数
|
|
30
|
+
* @returns Promise,解析为标准响应格式
|
|
31
|
+
*/
|
|
32
|
+
unionIdLogin(request) {
|
|
33
|
+
return this.request(this.unionIdLogin, request);
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* 获取微信绑定手机号
|
|
37
|
+
* @param request - 请求参数
|
|
38
|
+
* @returns Promise,解析为标准响应格式
|
|
39
|
+
*/
|
|
40
|
+
getBindPhone(request) {
|
|
41
|
+
return this.request(this.getBindPhone, request);
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* 绑定手机号到UnionId
|
|
45
|
+
* @param request - 请求参数
|
|
46
|
+
* @returns Promise,解析为标准响应格式
|
|
47
|
+
*/
|
|
48
|
+
unionIdBindPhone(request) {
|
|
49
|
+
return this.request(this.unionIdBindPhone, request);
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* 账号密码登录(新格式)
|
|
53
|
+
* @param request - 请求参数
|
|
54
|
+
* @returns Promise,解析为标准响应格式
|
|
55
|
+
*/
|
|
56
|
+
accountLogin(request) {
|
|
57
|
+
return this.request(this.accountLogin, request);
|
|
58
|
+
}
|
|
59
|
+
}
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
import { StandardResponse } from '../../../../types';
|
|
2
|
+
/**
|
|
3
|
+
* Miniprogram Auth Module Type Definitions
|
|
4
|
+
* 小程序认证模块类型定义
|
|
5
|
+
*/
|
|
6
|
+
export declare namespace MiniprogramAuthService {
|
|
7
|
+
interface RoleItem {
|
|
8
|
+
id: string;
|
|
9
|
+
name: string;
|
|
10
|
+
}
|
|
11
|
+
namespace Request {
|
|
12
|
+
/**
|
|
13
|
+
* 获取微信UnionId请求
|
|
14
|
+
*/
|
|
15
|
+
interface getUnionId {
|
|
16
|
+
code: string;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* UnionId登录请求
|
|
20
|
+
*/
|
|
21
|
+
interface unionIdLogin {
|
|
22
|
+
unionId: string;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* 获取微信绑定手机号请求
|
|
26
|
+
*/
|
|
27
|
+
interface getBindPhone {
|
|
28
|
+
code: string;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* 绑定手机号到UnionId请求
|
|
32
|
+
*/
|
|
33
|
+
interface bindPhoneToUnionId {
|
|
34
|
+
openId: string;
|
|
35
|
+
unionId: string;
|
|
36
|
+
phone: string;
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* 账号密码登录请求(新格式)
|
|
40
|
+
*/
|
|
41
|
+
interface accountLogin {
|
|
42
|
+
account: string;
|
|
43
|
+
password: string;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
namespace Response {
|
|
47
|
+
/**
|
|
48
|
+
* 获取用户菜单权限响应
|
|
49
|
+
*/
|
|
50
|
+
interface getUserMenuPermissions {
|
|
51
|
+
rules: Array<{
|
|
52
|
+
id: string;
|
|
53
|
+
name: string;
|
|
54
|
+
path: string;
|
|
55
|
+
isShow: number;
|
|
56
|
+
sort: number;
|
|
57
|
+
pid: string;
|
|
58
|
+
type: string;
|
|
59
|
+
icon: string;
|
|
60
|
+
status: string;
|
|
61
|
+
platform: string;
|
|
62
|
+
background: string;
|
|
63
|
+
ruleKey: string;
|
|
64
|
+
}>;
|
|
65
|
+
}
|
|
66
|
+
/**
|
|
67
|
+
* 获取微信UnionId响应
|
|
68
|
+
*/
|
|
69
|
+
interface getUnionId {
|
|
70
|
+
openId: string;
|
|
71
|
+
unionId: string;
|
|
72
|
+
token: string;
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* UnionId登录响应
|
|
76
|
+
*/
|
|
77
|
+
interface unionIdLogin {
|
|
78
|
+
code: 0 | 1;
|
|
79
|
+
msg: string;
|
|
80
|
+
token: string;
|
|
81
|
+
roles: RoleItem[];
|
|
82
|
+
}
|
|
83
|
+
type getBindPhone = string;
|
|
84
|
+
/**
|
|
85
|
+
* 绑定手机号到UnionId响应
|
|
86
|
+
*/
|
|
87
|
+
interface bindPhoneToUnionId {
|
|
88
|
+
code: 0;
|
|
89
|
+
msg: string;
|
|
90
|
+
token: string;
|
|
91
|
+
roles: RoleItem[];
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* 账号密码登录响应(新格式)
|
|
95
|
+
*/
|
|
96
|
+
interface accountLogin {
|
|
97
|
+
code: 0;
|
|
98
|
+
msg: string;
|
|
99
|
+
token: string;
|
|
100
|
+
roles: RoleItem[];
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* Miniprogram Auth Controller 接口定义
|
|
105
|
+
* 由 packages/server/src/api/controller/miniprogram/auth.ts 实现
|
|
106
|
+
*/
|
|
107
|
+
interface AuthController {
|
|
108
|
+
/**
|
|
109
|
+
* 小程序端获取用户菜单权限
|
|
110
|
+
*/
|
|
111
|
+
getUserMenuPermissions(): Promise<StandardResponse<Response.getUserMenuPermissions>>;
|
|
112
|
+
/**
|
|
113
|
+
* 获取微信UnionId
|
|
114
|
+
*/
|
|
115
|
+
getUnionId(request: Request.getUnionId): Promise<StandardResponse<Response.getUnionId>>;
|
|
116
|
+
/**
|
|
117
|
+
* UnionId登录
|
|
118
|
+
*/
|
|
119
|
+
unionIdLogin(request: Request.unionIdLogin): Promise<StandardResponse<Response.unionIdLogin>>;
|
|
120
|
+
/**
|
|
121
|
+
* 获取微信绑定手机号
|
|
122
|
+
*/
|
|
123
|
+
getBindPhone(request: Request.getBindPhone): Promise<StandardResponse<Response.getBindPhone>>;
|
|
124
|
+
/**
|
|
125
|
+
* 绑定手机号到UnionId
|
|
126
|
+
*/
|
|
127
|
+
unionIdBindPhone(request: Request.bindPhoneToUnionId): Promise<StandardResponse<Response.bindPhoneToUnionId>>;
|
|
128
|
+
/**
|
|
129
|
+
* 账号密码登录(新格式)
|
|
130
|
+
*/
|
|
131
|
+
accountLogin(request: Request.accountLogin): Promise<StandardResponse<Response.accountLogin>>;
|
|
132
|
+
}
|
|
133
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { MiniprogramFranchiseeService as Service } from './types';
|
|
2
|
+
import BaseService from '../../BaseService';
|
|
3
|
+
import type { StandardResponse } from '../../../../types';
|
|
4
|
+
/**
|
|
5
|
+
* MiniprogramFranchiseeService - Miniprogram Franchisee 服务模块
|
|
6
|
+
* 提供 Miniprogram Franchisee 相关的 API 方法
|
|
7
|
+
* 平台: miniprogram
|
|
8
|
+
*/
|
|
9
|
+
export declare class MiniprogramFranchiseeService extends BaseService implements Service.FranchiseeController {
|
|
10
|
+
protected prefixUrl: string;
|
|
11
|
+
getFranchiseeIdByUserId(request: Service.Request.getFranchiseeIdByUserId): Promise<StandardResponse<Service.Response.getFranchiseeIdByUserId>>;
|
|
12
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import BaseService from '../../BaseService.mjs';
|
|
2
|
+
/**
|
|
3
|
+
* MiniprogramFranchiseeService - Miniprogram Franchisee 服务模块
|
|
4
|
+
* 提供 Miniprogram Franchisee 相关的 API 方法
|
|
5
|
+
* 平台: miniprogram
|
|
6
|
+
*/
|
|
7
|
+
export class MiniprogramFranchiseeService extends BaseService {
|
|
8
|
+
constructor() {
|
|
9
|
+
super(...arguments);
|
|
10
|
+
this.prefixUrl = '/miniprogram/franchisee';
|
|
11
|
+
}
|
|
12
|
+
getFranchiseeIdByUserId(request) {
|
|
13
|
+
return this.request(this.getFranchiseeIdByUserId, request);
|
|
14
|
+
}
|
|
15
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { StandardResponse } from '../../../../types';
|
|
2
|
+
export declare namespace MiniprogramFranchiseeService {
|
|
3
|
+
namespace Request {
|
|
4
|
+
/**
|
|
5
|
+
* 根据用户ID获取加盟商ID
|
|
6
|
+
*/
|
|
7
|
+
interface getFranchiseeIdByUserId {
|
|
8
|
+
userId: string;
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
namespace Response {
|
|
12
|
+
/**
|
|
13
|
+
* 根据用户ID获取加盟商ID响应
|
|
14
|
+
*/
|
|
15
|
+
interface getFranchiseeIdByUserId {
|
|
16
|
+
id: string;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Franchisee Controller 接口定义
|
|
21
|
+
*/
|
|
22
|
+
interface FranchiseeController {
|
|
23
|
+
getFranchiseeIdByUserId(request: Request.getFranchiseeIdByUserId): Promise<StandardResponse<Response.getFranchiseeIdByUserId>>;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { PandoraAuthService as Service } from './types';
|
|
2
|
+
import BaseService from '../../BaseService';
|
|
3
|
+
import type { StandardResponse } from '../../../../types';
|
|
4
|
+
/**
|
|
5
|
+
* PandoraAuthService - Pandora Auth 服务模块
|
|
6
|
+
* 提供 Pandora Auth 相关的 API 方法
|
|
7
|
+
* 平台: pandora
|
|
8
|
+
*/
|
|
9
|
+
export declare class PandoraAuthService extends BaseService implements Service.AuthController {
|
|
10
|
+
protected prefixUrl: string;
|
|
11
|
+
/**
|
|
12
|
+
* 登录(支持账号密码和飞书登录)
|
|
13
|
+
* @param request - 请求参数
|
|
14
|
+
* @returns Promise,解析为标准响应格式
|
|
15
|
+
*/
|
|
16
|
+
login(request: Service.Request.login): Promise<StandardResponse<Service.Response.login>>;
|
|
17
|
+
/**
|
|
18
|
+
* 获取权限树(从请求上下文获取 userId 和 roleId)
|
|
19
|
+
* @returns Promise,解析为标准响应格式
|
|
20
|
+
*/
|
|
21
|
+
getPermissionTree(): Promise<StandardResponse<Service.Response.permissionTree>>;
|
|
22
|
+
/**
|
|
23
|
+
* 获取用户菜单权限
|
|
24
|
+
* @param request - 请求参数
|
|
25
|
+
* @returns Promise,解析为标准响应格式
|
|
26
|
+
*/
|
|
27
|
+
getUserMenuPermissions(request: Service.Request.getUserMenuPermissions): Promise<StandardResponse<Service.Response.getUserMenuPermissions>>;
|
|
28
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import BaseService from '../../BaseService.mjs';
|
|
2
|
+
/**
|
|
3
|
+
* PandoraAuthService - Pandora Auth 服务模块
|
|
4
|
+
* 提供 Pandora Auth 相关的 API 方法
|
|
5
|
+
* 平台: pandora
|
|
6
|
+
*/
|
|
7
|
+
export class PandoraAuthService extends BaseService {
|
|
8
|
+
constructor() {
|
|
9
|
+
super(...arguments);
|
|
10
|
+
this.prefixUrl = '/pandora/auth';
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* 登录(支持账号密码和飞书登录)
|
|
14
|
+
* @param request - 请求参数
|
|
15
|
+
* @returns Promise,解析为标准响应格式
|
|
16
|
+
*/
|
|
17
|
+
login(request) {
|
|
18
|
+
return this.request(this.login, request);
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* 获取权限树(从请求上下文获取 userId 和 roleId)
|
|
22
|
+
* @returns Promise,解析为标准响应格式
|
|
23
|
+
*/
|
|
24
|
+
getPermissionTree() {
|
|
25
|
+
return this.request(this.getPermissionTree, {});
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* 获取用户菜单权限
|
|
29
|
+
* @param request - 请求参数
|
|
30
|
+
* @returns Promise,解析为标准响应格式
|
|
31
|
+
*/
|
|
32
|
+
getUserMenuPermissions(request) {
|
|
33
|
+
return this.request(this.getUserMenuPermissions, request);
|
|
34
|
+
}
|
|
35
|
+
}
|