jmash-core-mp 0.1.21 → 0.1.22
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/.editorconfig +9 -9
- package/README.md +60 -60
- package/babel.config.json +34 -34
- package/eslint.config.mjs +7 -7
- package/lib/api/auth/index.d.ts +21 -21
- package/lib/api/auth/index.js +199 -199
- package/lib/api/auth/types.d.ts +86 -86
- package/lib/api/auth/types.js +9 -9
- package/lib/api/cms/index.d.ts +20 -20
- package/lib/api/cms/index.js +161 -161
- package/lib/api/cms/types.d.ts +200 -200
- package/lib/api/cms/types.js +1 -1
- package/lib/api/constant.d.ts +5 -5
- package/lib/api/constant.js +6 -6
- package/lib/api/dict/index.d.ts +18 -18
- package/lib/api/dict/index.js +34 -34
- package/lib/api/dict/types.d.ts +28 -28
- package/lib/api/dict/types.js +1 -1
- package/lib/api/dicts.d.ts +18 -18
- package/lib/api/dicts.js +67 -67
- package/lib/api/files/index.d.ts +25 -25
- package/lib/api/files/index.js +135 -135
- package/lib/api/files/types.d.ts +38 -38
- package/lib/api/files/types.js +1 -1
- package/lib/api/index.d.ts +4 -4
- package/lib/api/index.js +6 -6
- package/lib/api/myorgan/types.d.ts +22 -22
- package/lib/api/myorgan/types.js +1 -1
- package/lib/api/region/index.d.ts +7 -7
- package/lib/api/region/index.js +19 -19
- package/lib/api/region/types.d.ts +19 -19
- package/lib/api/region/types.js +1 -1
- package/lib/api/storage/index.d.ts +10 -10
- package/lib/api/storage/index.js +43 -43
- package/lib/api/storage/types.d.ts +28 -28
- package/lib/api/storage/types.js +1 -1
- package/lib/api/types.d.ts +42 -42
- package/lib/api/types.js +1 -1
- package/lib/app.mpx.d.ts +1 -1
- package/lib/components/auth-user/jmash-update-user.mpx.d.ts +1 -1
- package/lib/components/auth-user/jmash-user.mpx.d.ts +1 -1
- package/lib/components/cms/jmash-cms-acticle-list.mpx.d.ts +1 -1
- package/lib/components/cms/jmash-cms-article-item.mpx.d.ts +1 -1
- package/lib/components/cms/jmash-cms-article-view.mpx.d.ts +1 -0
- package/lib/components/cms/jmash-cms-article.mpx.d.ts +1 -1
- package/lib/components/cms/jmash-cms-like.mpx.d.ts +1 -1
- package/lib/components/common/jmash-upload-picture.mpx.d.ts +1 -0
- package/lib/components/core/jmash-login.mpx.d.ts +1 -0
- package/lib/index.d.ts +21 -21
- package/lib/index.js +14 -14
- package/lib/packages/pages/cms/cms-article-list.mpx.d.ts +1 -1
- package/lib/pages/index.mpx.d.ts +1 -0
- package/lib/store/user.d.ts +31 -31
- package/lib/store/user.js +227 -227
- package/lib/utils/common.d.ts +35 -35
- package/lib/utils/common.js +166 -166
- package/lib/utils/config.d.ts +5 -5
- package/lib/utils/config.js +29 -29
- package/lib/utils/db.d.ts +21 -21
- package/lib/utils/db.js +84 -84
- package/lib/utils/grpc.d.ts +5 -5
- package/lib/utils/grpc.js +20 -20
- package/lib/utils/net.d.ts +7 -7
- package/lib/utils/net.js +15 -15
- package/lib/utils/request.d.ts +2 -2
- package/lib/utils/request.js +123 -123
- package/mpx.config.js +27 -27
- package/package.json +1 -1
- package/postcss.config.js +11 -11
- package/project.config.json +24 -24
- package/project.private.config.json +13 -13
- package/public/index.html +15 -15
- package/src/api/auth/index.ts +227 -227
- package/src/api/auth/types.ts +166 -166
- package/src/api/cms/index.ts +218 -218
- package/src/api/cms/types.ts +379 -379
- package/src/api/constant.ts +6 -6
- package/src/api/dict/index.ts +44 -44
- package/src/api/dict/types.ts +49 -49
- package/src/api/dicts.ts +72 -72
- package/src/api/files/index.ts +163 -163
- package/src/api/files/types.ts +67 -67
- package/src/api/index.ts +11 -11
- package/src/api/myorgan/types.ts +42 -42
- package/src/api/region/index.ts +23 -23
- package/src/api/region/types.ts +36 -36
- package/src/api/storage/index.ts +62 -62
- package/src/api/storage/types.ts +54 -54
- package/src/api/types.ts +72 -72
- package/src/app.mpx +71 -71
- package/src/components/auth-user/jmash-logout.mpx +91 -91
- package/src/components/auth-user/jmash-update-user.mpx +386 -386
- package/src/components/auth-user/jmash-update-user.web.mpx +366 -366
- package/src/components/auth-user/jmash-user.mpx +359 -359
- package/src/components/cms/jmash-cms-acticle-list.mpx +182 -182
- package/src/components/cms/jmash-cms-article-item.mpx +241 -241
- package/src/components/cms/jmash-cms-article-view.mpx +131 -131
- package/src/components/cms/jmash-cms-article.mpx +68 -68
- package/src/components/cms/jmash-cms-like.mpx +151 -151
- package/src/components/common/jmash-avatar-edit.mpx +153 -153
- package/src/components/common/jmash-cascader-region.mpx +112 -112
- package/src/components/common/jmash-menu.mpx +129 -129
- package/src/components/common/jmash-none-data.mpx +82 -82
- package/src/components/common/jmash-pic-swiper.mpx +71 -71
- package/src/components/common/jmash-popup.mpx +137 -137
- package/src/components/common/jmash-search.mpx +126 -126
- package/src/components/common/jmash-single-btn.mpx +53 -53
- package/src/components/common/jmash-stepper.mpx +214 -214
- package/src/components/common/jmash-tab-bar.mpx +50 -50
- package/src/components/common/jmash-textarea.mpx +88 -88
- package/src/components/common/jmash-top-navigation.mpx +203 -203
- package/src/components/common/jmash-upload-picture.mpx +129 -126
- package/src/components/core/jmash-cms-protocol.mpx +66 -66
- package/src/components/core/jmash-login.ali.mpx +284 -284
- package/src/components/core/jmash-login.mpx +348 -348
- package/src/components/core/jmash-login.web.mpx +421 -421
- package/src/components/core/jmash-popup-login.ali.mpx +311 -311
- package/src/components/core/jmash-popup-login.mpx +415 -415
- package/src/components/core/jmash-popup-login.web.mpx +389 -389
- package/src/custom-tab-bar/index.mpx +10 -10
- package/src/global.d.ts +11 -11
- package/src/index.ts +71 -71
- package/src/packages/index.mpx +10 -10
- package/src/packages/pages/auth/cms-protocol.mpx +31 -31
- package/src/packages/pages/auth/login.mpx +59 -59
- package/src/packages/pages/auth/update-user.mpx +17 -17
- package/src/packages/pages/cms/cms-article-list.mpx +164 -164
- package/src/packages/pages/cms/cms-article.mpx +32 -32
- package/src/pages/basic-component.mpx +30 -30
- package/src/pages/half-home.mpx +58 -58
- package/src/pages/home.mpx +52 -52
- package/src/pages/home2.mpx +47 -47
- package/src/pages/index.mpx +13 -3
- package/src/pages/tabbar/home.mpx +77 -77
- package/src/pages/tabbar/my.mpx +80 -80
- package/src/store/user.ts +270 -270
- package/src/styles/index.scss +20 -20
- package/src/styles/vars.scss +27 -27
- package/src/utils/common.ts +179 -179
- package/src/utils/config.ts +35 -35
- package/src/utils/db.ts +100 -100
- package/src/utils/grpc.ts +21 -21
- package/src/utils/net.ts +18 -18
- package/src/utils/request.ts +134 -134
- package/static/ali/mini.project.json +4 -4
- package/static/dd/project.config.json +15 -15
- package/static/swan/project.swan.json +14 -14
- package/static/tt/project.config.json +11 -11
- package/static/wx/project.config.json +40 -40
- package/uno.config.js +9 -9
package/src/api/files/types.ts
CHANGED
|
@@ -1,68 +1,68 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* 文件API类型声明
|
|
3
|
-
*/
|
|
4
|
-
export interface FileInfo {
|
|
5
|
-
// 文件ID
|
|
6
|
-
fileId: string;
|
|
7
|
-
// 文件存放路径
|
|
8
|
-
fileSrc: string;
|
|
9
|
-
// 内容类型
|
|
10
|
-
contentType: string;
|
|
11
|
-
// 文件后缀
|
|
12
|
-
fileExt: string;
|
|
13
|
-
// 图片/视频宽度
|
|
14
|
-
fileWidth: number;
|
|
15
|
-
// 图片/视频高度
|
|
16
|
-
fileHeight: number;
|
|
17
|
-
// 文件大小
|
|
18
|
-
fileSize: number;
|
|
19
|
-
// File sha256
|
|
20
|
-
hashSha256: string;
|
|
21
|
-
// File SM3信息摘要
|
|
22
|
-
hashSm3: string;
|
|
23
|
-
// 创建时间
|
|
24
|
-
createDate: string;
|
|
25
|
-
// 相对路径
|
|
26
|
-
tempFilePath: string;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
export interface FileBase64Req {
|
|
30
|
-
// 租户
|
|
31
|
-
tenant?: string;
|
|
32
|
-
// Base64文件内容
|
|
33
|
-
base64?: string;
|
|
34
|
-
// 文件名称
|
|
35
|
-
fileName?: string;
|
|
36
|
-
// 内容类型
|
|
37
|
-
contentType?: string;
|
|
38
|
-
// 保存路径
|
|
39
|
-
fileDir?: string;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
export interface FileDownInfo {
|
|
43
|
-
// 临时文件路径 (本地路径)。没传入 filePath 指定文件存储路径时会返回,下载后的文件会存储到一个临时文件
|
|
44
|
-
tempFilePath: string;
|
|
45
|
-
// 用户文件路径 (本地路径)。传入 filePath 时会返回,跟传入的 filePath 一致
|
|
46
|
-
filePath: string;
|
|
47
|
-
// 开发者服务器返回的 HTTP 状态码
|
|
48
|
-
statusCode: number;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
export interface FileWebReq {
|
|
52
|
-
// 租户
|
|
53
|
-
tenant?: string;
|
|
54
|
-
// 文件内容
|
|
55
|
-
body?: string;
|
|
56
|
-
// 文件名称
|
|
57
|
-
fileName?: string;
|
|
58
|
-
// 内容类型
|
|
59
|
-
contentType?: string;
|
|
60
|
-
// 保存路径
|
|
61
|
-
fileDir?: string;
|
|
62
|
-
// 文件大小
|
|
63
|
-
fileSize?: number;
|
|
64
|
-
// 文件唯一ID
|
|
65
|
-
requestId?: string;
|
|
66
|
-
// 文件部分
|
|
67
|
-
filePart?:number;
|
|
1
|
+
/**
|
|
2
|
+
* 文件API类型声明
|
|
3
|
+
*/
|
|
4
|
+
export interface FileInfo {
|
|
5
|
+
// 文件ID
|
|
6
|
+
fileId: string;
|
|
7
|
+
// 文件存放路径
|
|
8
|
+
fileSrc: string;
|
|
9
|
+
// 内容类型
|
|
10
|
+
contentType: string;
|
|
11
|
+
// 文件后缀
|
|
12
|
+
fileExt: string;
|
|
13
|
+
// 图片/视频宽度
|
|
14
|
+
fileWidth: number;
|
|
15
|
+
// 图片/视频高度
|
|
16
|
+
fileHeight: number;
|
|
17
|
+
// 文件大小
|
|
18
|
+
fileSize: number;
|
|
19
|
+
// File sha256
|
|
20
|
+
hashSha256: string;
|
|
21
|
+
// File SM3信息摘要
|
|
22
|
+
hashSm3: string;
|
|
23
|
+
// 创建时间
|
|
24
|
+
createDate: string;
|
|
25
|
+
// 相对路径
|
|
26
|
+
tempFilePath: string;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export interface FileBase64Req {
|
|
30
|
+
// 租户
|
|
31
|
+
tenant?: string;
|
|
32
|
+
// Base64文件内容
|
|
33
|
+
base64?: string;
|
|
34
|
+
// 文件名称
|
|
35
|
+
fileName?: string;
|
|
36
|
+
// 内容类型
|
|
37
|
+
contentType?: string;
|
|
38
|
+
// 保存路径
|
|
39
|
+
fileDir?: string;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export interface FileDownInfo {
|
|
43
|
+
// 临时文件路径 (本地路径)。没传入 filePath 指定文件存储路径时会返回,下载后的文件会存储到一个临时文件
|
|
44
|
+
tempFilePath: string;
|
|
45
|
+
// 用户文件路径 (本地路径)。传入 filePath 时会返回,跟传入的 filePath 一致
|
|
46
|
+
filePath: string;
|
|
47
|
+
// 开发者服务器返回的 HTTP 状态码
|
|
48
|
+
statusCode: number;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
export interface FileWebReq {
|
|
52
|
+
// 租户
|
|
53
|
+
tenant?: string;
|
|
54
|
+
// 文件内容
|
|
55
|
+
body?: string;
|
|
56
|
+
// 文件名称
|
|
57
|
+
fileName?: string;
|
|
58
|
+
// 内容类型
|
|
59
|
+
contentType?: string;
|
|
60
|
+
// 保存路径
|
|
61
|
+
fileDir?: string;
|
|
62
|
+
// 文件大小
|
|
63
|
+
fileSize?: number;
|
|
64
|
+
// 文件唯一ID
|
|
65
|
+
requestId?: string;
|
|
66
|
+
// 文件部分
|
|
67
|
+
filePart?:number;
|
|
68
68
|
}
|
package/src/api/index.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { Constant } from "../api/constant";
|
|
2
|
-
|
|
3
|
-
import { EnumDict } from "../api/dicts";
|
|
4
|
-
|
|
5
|
-
export class Dict {
|
|
6
|
-
// 性别
|
|
7
|
-
static readonly genderDict = new EnumDict(
|
|
8
|
-
Constant.MODULE_RBAC,
|
|
9
|
-
Constant.ENUM_GENDER
|
|
10
|
-
);
|
|
11
|
-
}
|
|
1
|
+
import { Constant } from "../api/constant";
|
|
2
|
+
|
|
3
|
+
import { EnumDict } from "../api/dicts";
|
|
4
|
+
|
|
5
|
+
export class Dict {
|
|
6
|
+
// 性别
|
|
7
|
+
static readonly genderDict = new EnumDict(
|
|
8
|
+
Constant.MODULE_RBAC,
|
|
9
|
+
Constant.ENUM_GENDER
|
|
10
|
+
);
|
|
11
|
+
}
|
package/src/api/myorgan/types.ts
CHANGED
|
@@ -1,43 +1,43 @@
|
|
|
1
|
-
// 基础组织信息列表
|
|
2
|
-
export interface BaseOrganModel {
|
|
3
|
-
// 组织ID
|
|
4
|
-
organId?: string;
|
|
5
|
-
// 组织名称
|
|
6
|
-
organName?: string;
|
|
7
|
-
// 组织编码
|
|
8
|
-
organCode?: string;
|
|
9
|
-
// 拼音
|
|
10
|
-
pinYin?: string;
|
|
11
|
-
// 用户Id
|
|
12
|
-
userId?: string;
|
|
13
|
-
// 组织简称
|
|
14
|
-
shortName?: string;
|
|
15
|
-
// 组织类别(个体、企业、政府、其他组织)
|
|
16
|
-
organType?: string;
|
|
17
|
-
// 上级组织ID
|
|
18
|
-
parentId?: string;
|
|
19
|
-
// Logo图片
|
|
20
|
-
logoUrl?: string;
|
|
21
|
-
// 所属行业
|
|
22
|
-
industry?: string;
|
|
23
|
-
// 详细地址
|
|
24
|
-
address?: string;
|
|
25
|
-
// 经度
|
|
26
|
-
geoLongitude?: string;
|
|
27
|
-
// 纬度
|
|
28
|
-
geoLatitude?: string;
|
|
29
|
-
// 联系人
|
|
30
|
-
contactPerson?: string;
|
|
31
|
-
// 联系电话
|
|
32
|
-
contactPersonMobile?: string;
|
|
33
|
-
// 联系电话脱敏
|
|
34
|
-
contactPersonMobileIns?: string;
|
|
35
|
-
// 是否完善
|
|
36
|
-
perfectStatus?: boolean;
|
|
37
|
-
// 状态(正常、试用、停用、欠费)
|
|
38
|
-
status?: string;
|
|
39
|
-
// 组织租户
|
|
40
|
-
tenant: string;
|
|
41
|
-
// 是否可以邀请员工
|
|
42
|
-
memberInviteStatus: boolean;
|
|
1
|
+
// 基础组织信息列表
|
|
2
|
+
export interface BaseOrganModel {
|
|
3
|
+
// 组织ID
|
|
4
|
+
organId?: string;
|
|
5
|
+
// 组织名称
|
|
6
|
+
organName?: string;
|
|
7
|
+
// 组织编码
|
|
8
|
+
organCode?: string;
|
|
9
|
+
// 拼音
|
|
10
|
+
pinYin?: string;
|
|
11
|
+
// 用户Id
|
|
12
|
+
userId?: string;
|
|
13
|
+
// 组织简称
|
|
14
|
+
shortName?: string;
|
|
15
|
+
// 组织类别(个体、企业、政府、其他组织)
|
|
16
|
+
organType?: string;
|
|
17
|
+
// 上级组织ID
|
|
18
|
+
parentId?: string;
|
|
19
|
+
// Logo图片
|
|
20
|
+
logoUrl?: string;
|
|
21
|
+
// 所属行业
|
|
22
|
+
industry?: string;
|
|
23
|
+
// 详细地址
|
|
24
|
+
address?: string;
|
|
25
|
+
// 经度
|
|
26
|
+
geoLongitude?: string;
|
|
27
|
+
// 纬度
|
|
28
|
+
geoLatitude?: string;
|
|
29
|
+
// 联系人
|
|
30
|
+
contactPerson?: string;
|
|
31
|
+
// 联系电话
|
|
32
|
+
contactPersonMobile?: string;
|
|
33
|
+
// 联系电话脱敏
|
|
34
|
+
contactPersonMobileIns?: string;
|
|
35
|
+
// 是否完善
|
|
36
|
+
perfectStatus?: boolean;
|
|
37
|
+
// 状态(正常、试用、停用、欠费)
|
|
38
|
+
status?: string;
|
|
39
|
+
// 组织租户
|
|
40
|
+
tenant: string;
|
|
41
|
+
// 是否可以邀请员工
|
|
42
|
+
memberInviteStatus: boolean;
|
|
43
43
|
}
|
package/src/api/region/index.ts
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import { DictRegionList, DictRegionReq } from "./types";
|
|
2
|
-
import { ResponseData, AppConfig } from "../../api/types";
|
|
3
|
-
import { grpc } from "../../utils/grpc";
|
|
4
|
-
import mpx from "@mpxjs/core";
|
|
5
|
-
|
|
6
|
-
class RegionApiImpl {
|
|
7
|
-
// 查询列表信息地区信息
|
|
8
|
-
findList(query?: DictRegionReq): Promise<ResponseData<DictRegionList>> {
|
|
9
|
-
if (query) {
|
|
10
|
-
query.hasEnable = query.enable !== undefined;
|
|
11
|
-
}
|
|
12
|
-
grpc.clearEmpty(query);
|
|
13
|
-
const config = getApp().globalData.config;
|
|
14
|
-
return mpx.xfetch.fetch({
|
|
15
|
-
url: "/v1/region/dict_region/list/" + config.tenant,
|
|
16
|
-
method: "GET",
|
|
17
|
-
data: query,
|
|
18
|
-
});
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
const regionApi = new RegionApiImpl();
|
|
23
|
-
export { regionApi };
|
|
1
|
+
import { DictRegionList, DictRegionReq } from "./types";
|
|
2
|
+
import { ResponseData, AppConfig } from "../../api/types";
|
|
3
|
+
import { grpc } from "../../utils/grpc";
|
|
4
|
+
import mpx from "@mpxjs/core";
|
|
5
|
+
|
|
6
|
+
class RegionApiImpl {
|
|
7
|
+
// 查询列表信息地区信息
|
|
8
|
+
findList(query?: DictRegionReq): Promise<ResponseData<DictRegionList>> {
|
|
9
|
+
if (query) {
|
|
10
|
+
query.hasEnable = query.enable !== undefined;
|
|
11
|
+
}
|
|
12
|
+
grpc.clearEmpty(query);
|
|
13
|
+
const config = getApp().globalData.config;
|
|
14
|
+
return mpx.xfetch.fetch({
|
|
15
|
+
url: "/v1/region/dict_region/list/" + config.tenant,
|
|
16
|
+
method: "GET",
|
|
17
|
+
data: query,
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
const regionApi = new RegionApiImpl();
|
|
23
|
+
export { regionApi };
|
package/src/api/region/types.ts
CHANGED
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
// 地区信息查询
|
|
2
|
-
export interface DictRegionReq {
|
|
3
|
-
// 租户
|
|
4
|
-
tenant?: string;
|
|
5
|
-
// 是否包含状态
|
|
6
|
-
hasEnable?: boolean;
|
|
7
|
-
// 是否启用
|
|
8
|
-
enable?: boolean;
|
|
9
|
-
// 上级ID
|
|
10
|
-
parentId?: string;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
// 地区信息列表
|
|
14
|
-
export interface DictRegionList {
|
|
15
|
-
// 当前页内容
|
|
16
|
-
results: Array<DictRegionModel>;
|
|
17
|
-
}
|
|
18
|
-
// 地区信息实体
|
|
19
|
-
export interface DictRegionModel {
|
|
20
|
-
// 地区ID
|
|
21
|
-
regionId?: string;
|
|
22
|
-
// 地区编码
|
|
23
|
-
regionCode?: string;
|
|
24
|
-
// 地区名称
|
|
25
|
-
regionName?: string;
|
|
26
|
-
// 用来构造组件---地区名称
|
|
27
|
-
text?: string;
|
|
28
|
-
// 用来构造组件---地区编码
|
|
29
|
-
value?: string;
|
|
30
|
-
// 是否包含子节点
|
|
31
|
-
hasChildren?: boolean;
|
|
32
|
-
// 地区类型
|
|
33
|
-
regionType?: string;
|
|
34
|
-
// 子节点
|
|
35
|
-
children?: Array<DictRegionModel>;
|
|
36
|
-
}
|
|
1
|
+
// 地区信息查询
|
|
2
|
+
export interface DictRegionReq {
|
|
3
|
+
// 租户
|
|
4
|
+
tenant?: string;
|
|
5
|
+
// 是否包含状态
|
|
6
|
+
hasEnable?: boolean;
|
|
7
|
+
// 是否启用
|
|
8
|
+
enable?: boolean;
|
|
9
|
+
// 上级ID
|
|
10
|
+
parentId?: string;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
// 地区信息列表
|
|
14
|
+
export interface DictRegionList {
|
|
15
|
+
// 当前页内容
|
|
16
|
+
results: Array<DictRegionModel>;
|
|
17
|
+
}
|
|
18
|
+
// 地区信息实体
|
|
19
|
+
export interface DictRegionModel {
|
|
20
|
+
// 地区ID
|
|
21
|
+
regionId?: string;
|
|
22
|
+
// 地区编码
|
|
23
|
+
regionCode?: string;
|
|
24
|
+
// 地区名称
|
|
25
|
+
regionName?: string;
|
|
26
|
+
// 用来构造组件---地区名称
|
|
27
|
+
text?: string;
|
|
28
|
+
// 用来构造组件---地区编码
|
|
29
|
+
value?: string;
|
|
30
|
+
// 是否包含子节点
|
|
31
|
+
hasChildren?: boolean;
|
|
32
|
+
// 地区类型
|
|
33
|
+
regionType?: string;
|
|
34
|
+
// 子节点
|
|
35
|
+
children?: Array<DictRegionModel>;
|
|
36
|
+
}
|
package/src/api/storage/index.ts
CHANGED
|
@@ -1,62 +1,62 @@
|
|
|
1
|
-
import mpx from "@mpxjs/core";
|
|
2
|
-
import { ResponseData, AppConfig } from "../../api/types";
|
|
3
|
-
import { grpc } from "../../utils/grpc";
|
|
4
|
-
import {
|
|
5
|
-
StorageOrganInfoReq,
|
|
6
|
-
StorageOrganInfoList,
|
|
7
|
-
StorageOrganBrowserUpdateReq,
|
|
8
|
-
StorageOrganBrowserModel,
|
|
9
|
-
} from "./types";
|
|
10
|
-
|
|
11
|
-
class StorageApiImpl {
|
|
12
|
-
// 查询我的组织列表
|
|
13
|
-
findMyOrganList(
|
|
14
|
-
data: StorageOrganInfoReq
|
|
15
|
-
): Promise<ResponseData<StorageOrganInfoList>> {
|
|
16
|
-
grpc.clearEmpty(data);
|
|
17
|
-
const config = getApp().globalData.config;
|
|
18
|
-
return mpx.xfetch.fetch({
|
|
19
|
-
url: `/v1/storage/storage_organ/my_list/${config.tenant}?&serviceType[]=${data.serviceType}`,
|
|
20
|
-
method: "GET",
|
|
21
|
-
});
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
// 查询列表信息店铺用户浏览信息
|
|
25
|
-
findStorageBrowserOrganList(
|
|
26
|
-
data: StorageOrganInfoReq
|
|
27
|
-
): Promise<ResponseData<StorageOrganInfoList>> {
|
|
28
|
-
const config = getApp().globalData.config;
|
|
29
|
-
return mpx.xfetch.fetch({
|
|
30
|
-
url: `/v1/front/storage/storage_organ_browser/my_list/${config.tenant}?&serviceType[]=${data.serviceType}`,
|
|
31
|
-
method: "GET",
|
|
32
|
-
});
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
// 查询列表信息店铺用户浏览信息
|
|
36
|
-
findStorageOrganInfoList(
|
|
37
|
-
data: StorageOrganInfoReq
|
|
38
|
-
): Promise<ResponseData<StorageOrganInfoList>> {
|
|
39
|
-
const config = getApp().globalData.config;
|
|
40
|
-
return mpx.xfetch.fetch({
|
|
41
|
-
url: `/v1/storage/storage_organ_info/list/${config.tenant}?&serviceType[]=${data.serviceType}`,
|
|
42
|
-
method: "GET",
|
|
43
|
-
data: data,
|
|
44
|
-
});
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
// 修改组织浏览信息
|
|
48
|
-
updateStorageOrganBrowser(
|
|
49
|
-
data: StorageOrganBrowserUpdateReq
|
|
50
|
-
): Promise<ResponseData<StorageOrganBrowserModel>> {
|
|
51
|
-
const config = getApp().globalData.config;
|
|
52
|
-
data.tenant = config.tenant;
|
|
53
|
-
grpc.clearEmpty(data);
|
|
54
|
-
return mpx.xfetch.fetch({
|
|
55
|
-
url: "/v1/front/storage/storage_organ_browser/browse",
|
|
56
|
-
method: "PATCH",
|
|
57
|
-
data: data,
|
|
58
|
-
});
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
const storageApi = new StorageApiImpl();
|
|
62
|
-
export { storageApi };
|
|
1
|
+
import mpx from "@mpxjs/core";
|
|
2
|
+
import { ResponseData, AppConfig } from "../../api/types";
|
|
3
|
+
import { grpc } from "../../utils/grpc";
|
|
4
|
+
import {
|
|
5
|
+
StorageOrganInfoReq,
|
|
6
|
+
StorageOrganInfoList,
|
|
7
|
+
StorageOrganBrowserUpdateReq,
|
|
8
|
+
StorageOrganBrowserModel,
|
|
9
|
+
} from "./types";
|
|
10
|
+
|
|
11
|
+
class StorageApiImpl {
|
|
12
|
+
// 查询我的组织列表
|
|
13
|
+
findMyOrganList(
|
|
14
|
+
data: StorageOrganInfoReq
|
|
15
|
+
): Promise<ResponseData<StorageOrganInfoList>> {
|
|
16
|
+
grpc.clearEmpty(data);
|
|
17
|
+
const config = getApp().globalData.config;
|
|
18
|
+
return mpx.xfetch.fetch({
|
|
19
|
+
url: `/v1/storage/storage_organ/my_list/${config.tenant}?&serviceType[]=${data.serviceType}`,
|
|
20
|
+
method: "GET",
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
// 查询列表信息店铺用户浏览信息
|
|
25
|
+
findStorageBrowserOrganList(
|
|
26
|
+
data: StorageOrganInfoReq
|
|
27
|
+
): Promise<ResponseData<StorageOrganInfoList>> {
|
|
28
|
+
const config = getApp().globalData.config;
|
|
29
|
+
return mpx.xfetch.fetch({
|
|
30
|
+
url: `/v1/front/storage/storage_organ_browser/my_list/${config.tenant}?&serviceType[]=${data.serviceType}`,
|
|
31
|
+
method: "GET",
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
// 查询列表信息店铺用户浏览信息
|
|
36
|
+
findStorageOrganInfoList(
|
|
37
|
+
data: StorageOrganInfoReq
|
|
38
|
+
): Promise<ResponseData<StorageOrganInfoList>> {
|
|
39
|
+
const config = getApp().globalData.config;
|
|
40
|
+
return mpx.xfetch.fetch({
|
|
41
|
+
url: `/v1/storage/storage_organ_info/list/${config.tenant}?&serviceType[]=${data.serviceType}`,
|
|
42
|
+
method: "GET",
|
|
43
|
+
data: data,
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
// 修改组织浏览信息
|
|
48
|
+
updateStorageOrganBrowser(
|
|
49
|
+
data: StorageOrganBrowserUpdateReq
|
|
50
|
+
): Promise<ResponseData<StorageOrganBrowserModel>> {
|
|
51
|
+
const config = getApp().globalData.config;
|
|
52
|
+
data.tenant = config.tenant;
|
|
53
|
+
grpc.clearEmpty(data);
|
|
54
|
+
return mpx.xfetch.fetch({
|
|
55
|
+
url: "/v1/front/storage/storage_organ_browser/browse",
|
|
56
|
+
method: "PATCH",
|
|
57
|
+
data: data,
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
const storageApi = new StorageApiImpl();
|
|
62
|
+
export { storageApi };
|
package/src/api/storage/types.ts
CHANGED
|
@@ -1,54 +1,54 @@
|
|
|
1
|
-
// 组织列表查询
|
|
2
|
-
export interface StorageOrganInfoReq {
|
|
3
|
-
// 服务类型(多选OR查询)
|
|
4
|
-
serviceType: string;
|
|
5
|
-
// 组织名称模糊检索
|
|
6
|
-
likeOrganName?: string;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
// 组织列表
|
|
10
|
-
export interface StorageOrganInfoList {
|
|
11
|
-
// 当前内容
|
|
12
|
-
results: StorageOrganInfoModel[];
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
// 组织实体
|
|
16
|
-
export interface StorageOrganInfoModel {
|
|
17
|
-
// 组织名称
|
|
18
|
-
organName?: string;
|
|
19
|
-
// 店铺图片
|
|
20
|
-
logoUrl?: string;
|
|
21
|
-
// 创建时间
|
|
22
|
-
createTime?: string;
|
|
23
|
-
// 备注
|
|
24
|
-
remark?: string;
|
|
25
|
-
// 组织租户
|
|
26
|
-
organTenant?: string;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
// 店铺用户浏览信息列表
|
|
30
|
-
export interface ShopBrowserUserList {
|
|
31
|
-
// 当前内容
|
|
32
|
-
results: ShopBrowserUserModel[];
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
// 店铺用户浏览信息实体
|
|
36
|
-
export interface ShopBrowserUserModel {
|
|
37
|
-
// 店铺名称
|
|
38
|
-
shopName?: string;
|
|
39
|
-
// 店铺LOGO
|
|
40
|
-
picUrl?: string;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
// 组织浏览信息修改实体
|
|
44
|
-
export interface StorageOrganBrowserUpdateReq {
|
|
45
|
-
// 租户
|
|
46
|
-
tenant?: string;
|
|
47
|
-
// 用于检测重复请求的唯一字符串ID
|
|
48
|
-
requestId: string;
|
|
49
|
-
// 存储ID
|
|
50
|
-
storageId: string;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
// 组织浏览信息实体
|
|
54
|
-
export interface StorageOrganBrowserModel {}
|
|
1
|
+
// 组织列表查询
|
|
2
|
+
export interface StorageOrganInfoReq {
|
|
3
|
+
// 服务类型(多选OR查询)
|
|
4
|
+
serviceType: string;
|
|
5
|
+
// 组织名称模糊检索
|
|
6
|
+
likeOrganName?: string;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
// 组织列表
|
|
10
|
+
export interface StorageOrganInfoList {
|
|
11
|
+
// 当前内容
|
|
12
|
+
results: StorageOrganInfoModel[];
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
// 组织实体
|
|
16
|
+
export interface StorageOrganInfoModel {
|
|
17
|
+
// 组织名称
|
|
18
|
+
organName?: string;
|
|
19
|
+
// 店铺图片
|
|
20
|
+
logoUrl?: string;
|
|
21
|
+
// 创建时间
|
|
22
|
+
createTime?: string;
|
|
23
|
+
// 备注
|
|
24
|
+
remark?: string;
|
|
25
|
+
// 组织租户
|
|
26
|
+
organTenant?: string;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
// 店铺用户浏览信息列表
|
|
30
|
+
export interface ShopBrowserUserList {
|
|
31
|
+
// 当前内容
|
|
32
|
+
results: ShopBrowserUserModel[];
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
// 店铺用户浏览信息实体
|
|
36
|
+
export interface ShopBrowserUserModel {
|
|
37
|
+
// 店铺名称
|
|
38
|
+
shopName?: string;
|
|
39
|
+
// 店铺LOGO
|
|
40
|
+
picUrl?: string;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
// 组织浏览信息修改实体
|
|
44
|
+
export interface StorageOrganBrowserUpdateReq {
|
|
45
|
+
// 租户
|
|
46
|
+
tenant?: string;
|
|
47
|
+
// 用于检测重复请求的唯一字符串ID
|
|
48
|
+
requestId: string;
|
|
49
|
+
// 存储ID
|
|
50
|
+
storageId: string;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
// 组织浏览信息实体
|
|
54
|
+
export interface StorageOrganBrowserModel {}
|