jmash-core-mp 0.1.90 → 0.1.92

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.
@@ -96,21 +96,41 @@ export interface CmsInfoModel {
96
96
  infoId?: string;
97
97
  modelCode?: string;
98
98
  infoTitle: string;
99
+ rgb?: string;
99
100
  subTitle?: string;
101
+ sourceName?: string;
102
+ sourceUrl?: string;
100
103
  imgUrl?: string;
104
+ isImg?: boolean;
101
105
  author?: string;
102
106
  intro?: string;
103
107
  top?: number;
108
+ commentCountReview?: number;
109
+ isLink?: boolean;
110
+ linkUrl?: string;
104
111
  status?: string;
112
+ isLeads?: boolean;
105
113
  publishDate?: string;
106
114
  publishDateStr?: string;
107
115
  dueTime?: string;
116
+ deptId?: string;
117
+ deptName?: string;
118
+ createTime?: string;
119
+ createBy?: string;
120
+ updateTime?: string;
121
+ updateBy?: string;
122
+ deleted?: boolean;
123
+ deleteTime?: string;
124
+ deleteBy?: string;
108
125
  channelId: Array<string>;
109
- sourceName?: string;
110
126
  siteId: string;
127
+ sessionId?: string;
111
128
  address?: string;
112
129
  geoLongitude?: number;
113
130
  geoLatitude?: number;
131
+ tenant?: string;
132
+ tradeMark?: string;
133
+ specsModel?: string;
114
134
  }
115
135
  export interface CmsInfoContentReq {
116
136
  tenant?: string;
@@ -20,6 +20,7 @@ export interface ShopInfoModel {
20
20
  adPics?: string;
21
21
  organId?: string;
22
22
  organTenant?: string;
23
+ isCaptcha?: boolean;
23
24
  createBy?: string;
24
25
  createTime?: string;
25
26
  }
package/lib/store/user.js CHANGED
@@ -67,6 +67,9 @@ export const useUserStore = defineStore("user", {
67
67
  },
68
68
  /** 静默登录 */
69
69
  silentLogin() {
70
+ if (__mpx_mode__ === "web") {
71
+ return Promise.reject(new Error("Web 不支持静默登录!"));
72
+ }
70
73
  const obj = __mpx_mode__ === "ali" ? { scopes: "auth_base" } : {};
71
74
  const config = getApp().globalData.config;
72
75
  return mpx
package/package.json CHANGED
@@ -1,22 +1,22 @@
1
1
  {
2
2
  "name": "jmash-core-mp",
3
- "version": "0.1.90",
3
+ "version": "0.1.92",
4
4
  "private": false,
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",
7
7
  "dependencies": {
8
- "@mpxjs/api-proxy": "^2.10.19",
9
- "@mpxjs/core": "^2.10.19",
10
- "@mpxjs/fetch": "^2.10.19",
11
- "@mpxjs/mpx-cube-ui": "^1.4.15",
12
- "@mpxjs/pinia": "^2.10.18",
13
- "@mpxjs/store": "^2.10.18",
14
- "@mpxjs/utils": "^2.10.18",
15
- "dayjs": "^1.11.21",
8
+ "@mpxjs/api-proxy": "^2.11.1",
9
+ "@mpxjs/core": "^2.11.1",
10
+ "@mpxjs/fetch": "^2.11.1",
11
+ "@mpxjs/mpx-cube-ui": "^1.4.17",
12
+ "@mpxjs/pinia": "^2.11.0",
13
+ "@mpxjs/store": "^2.11.0",
14
+ "@mpxjs/utils": "^2.11.0",
15
+ "dayjs": "^1.11.23",
16
16
  "pinia": "^2.0.14",
17
- "sm-crypto": "^0.4.0",
18
17
  "vue": "^2.7.0",
19
- "vue-demi": "^0.14.6",
18
+ "sm-crypto": "0.4.0",
19
+ "vue-demi": "^0.14.10",
20
20
  "vue-i18n": "^8.27.2",
21
21
  "vue-i18n-bridge": "^9.2.2",
22
22
  "vue-router": "^3.1.3"
@@ -26,36 +26,27 @@
26
26
  "@babel/plugin-transform-runtime": "^7.10.4",
27
27
  "@babel/preset-env": "^7.10.4",
28
28
  "@babel/runtime-corejs3": "^7.10.4",
29
- "@mini-types/global": "^1.0.33",
30
- "@mpxjs/babel-plugin-inject-page-events": "^2.9.0",
31
- "@mpxjs/eslint-config": "^2.0.3",
32
- "@mpxjs/miniprogram-simulate": "^1.4.17",
33
- "@mpxjs/mpx-cli-service": "^2.0.0",
34
- "@mpxjs/mpx-jest": "^0.0.32",
35
- "@mpxjs/size-report": "^2.10.0",
36
- "@mpxjs/unocss-base": "^2.9.0",
37
- "@mpxjs/unocss-plugin": "^2.9.0",
38
- "@mpxjs/vue-cli-plugin-mpx": "^2.0.0",
39
- "@mpxjs/vue-cli-plugin-mpx-eslint": "^2.0.0",
40
- "@mpxjs/vue-cli-plugin-mpx-typescript": "^2.0.0",
41
- "@mpxjs/vue-cli-plugin-mpx-unit-test": "^2.0.0",
42
- "@mpxjs/vue-cli-plugin-mpx-utility-first-css": "^2.0.0",
43
- "@mpxjs/webpack-plugin": "^2.10.0",
44
- "@types/jest": "^27.5.1",
45
- "@vue/cli-service": "~5.0.0",
46
- "autoprefixer": "^10.2.4",
47
- "babel-jest": "^27.4.5",
48
- "eslint": "^9.0.0",
49
- "jest": "^27.4.5",
50
- "postcss": "^8.2.6",
29
+ "@mini-types/global": "^3.0.14",
30
+ "@mpxjs/babel-plugin-inject-page-events": "^2.10.21",
31
+ "@mpxjs/eslint-config": "^2.0.14",
32
+ "@mpxjs/miniprogram-simulate": "^1.4.21",
33
+ "@mpxjs/size-report": "^2.11.0",
34
+ "@mpxjs/mpx-cli-service": "^2.2.32",
35
+ "@mpxjs/vue-cli-plugin-mpx": "^2.2.32",
36
+ "@mpxjs/vue-cli-plugin-mpx-eslint": "^2.2.32",
37
+ "@mpxjs/vue-cli-plugin-mpx-typescript": "^2.2.32",
38
+ "@mpxjs/webpack-plugin": "^2.11.1",
39
+ "@vue/cli-service": "~5.0.9",
40
+ "autoprefixer": "^10.6.1",
41
+ "eslint": "^9.39.5",
42
+ "postcss": "^8.5.31",
51
43
  "process": "^0.11.10",
52
- "sass": "^1.99.0",
53
- "sass-loader": "^16.0.7",
44
+ "sass": "^1.106.0",
45
+ "sass-loader": "^17.0.1",
54
46
  "stylus": "^0.55.0",
55
47
  "stylus-loader": "^6.1.0",
56
- "ts-jest": "^27.1.2",
57
- "typescript": "^4.1.3",
58
- "webpack": "^5.43.0"
48
+ "typescript": "^4.9.5",
49
+ "webpack": "~5.83.1"
59
50
  },
60
51
  "browserslist": [
61
52
  "ios >= 8",
@@ -190,36 +190,76 @@ export interface CmsInfoModel {
190
190
  modelCode?: string;
191
191
  // 内容标题
192
192
  infoTitle: string;
193
+ // 标题颜色
194
+ rgb?: string;
193
195
  // 副标题
194
196
  subTitle?: string;
197
+ // 来源名称
198
+ sourceName?: string;
199
+ // 来源地址
200
+ sourceUrl?: string;
195
201
  // 封面图片
196
202
  imgUrl?: string;
203
+ // 是否图片新闻
204
+ isImg?: boolean;
197
205
  // 作者
198
206
  author?: string;
199
207
  // 摘要
200
208
  intro?: string;
201
209
  // 是否置顶
202
210
  top?: number;
211
+ // 待审评论数
212
+ commentCountReview?: number;
213
+ // 是否外部链接
214
+ isLink?: boolean;
215
+ // 外部链接地址
216
+ linkUrl?: string;
203
217
  // 文章状态
204
218
  status?: string;
219
+ // 是否线索收集
220
+ isLeads?: boolean;
205
221
  // 发布时间
206
222
  publishDate?: string;
207
223
  // 发布时间字符串
208
224
  publishDateStr?: string;
209
225
  // 到期时间
210
226
  dueTime?: string;
227
+ // 创建部门ID
228
+ deptId?: string;
229
+ // 创建部门名称
230
+ deptName?: string;
231
+ // 创建时间
232
+ createTime?: string;
233
+ // 创建者
234
+ createBy?: string;
235
+ // 更新时间
236
+ updateTime?: string;
237
+ // 更新者
238
+ updateBy?: string;
239
+ // 是否删除
240
+ deleted?: boolean;
241
+ // 删除时间
242
+ deleteTime?: string;
243
+ // 删除者
244
+ deleteBy?: string;
211
245
  // 栏目ID
212
246
  channelId: Array<string>;
213
- // 来源名称
214
- sourceName?: string;
215
247
  // 站点Id
216
248
  siteId: string;
249
+ // 会话ID(AI)
250
+ sessionId?: string;
217
251
  // 地址
218
252
  address?: string;
219
253
  // 经度
220
254
  geoLongitude?: number;
221
255
  // 纬度
222
256
  geoLatitude?: number;
257
+ // 租户
258
+ tenant?: string;
259
+ // 注册商标
260
+ tradeMark?: string;
261
+ // 规格型号
262
+ specsModel?: string;
223
263
  }
224
264
  // 信息内容查询
225
265
  export interface CmsInfoContentReq {
@@ -42,6 +42,8 @@ export interface ShopInfoModel {
42
42
  organId?: string;
43
43
  // 组织租户
44
44
  organTenant?: string;
45
+ // 是否开启公众号安全核验(用卡消费时)
46
+ isCaptcha?: boolean;
45
47
  // 创建人
46
48
  createBy?: string;
47
49
  // 创建时间
package/src/app.mpx CHANGED
@@ -11,6 +11,11 @@ import { mpxFetch, config, initConfig } from "./index";
11
11
  mpx.use(mpxFetch);
12
12
 
13
13
  createApp({
14
+ // custom-tab-bar 挂在 app 层,不在任何 page 的 provide 链内,
15
+ // 组件内建的 inject: ['__pageId'] 会取不到值并报警告,这里补一个兜底。
16
+ provide: {
17
+ __pageId: -1
18
+ },
14
19
  onLaunch(options) {
15
20
  initConfig(config, "dev");
16
21
  console.log("config", config);
@@ -21,7 +26,15 @@ createApp({
21
26
  })
22
27
  </script>
23
28
 
24
- <style></style>
29
+ <style lang="scss">
30
+ @use './styles/theme-default' as theme;
31
+
32
+ // 更换主题
33
+ page,
34
+ #app {
35
+ @include theme.variables;
36
+ }
37
+ </style>
25
38
 
26
39
  <script type="application/json">
27
40
  {
@@ -39,6 +52,7 @@ createApp({
39
52
  "./pages/organ-search",
40
53
  "./pages/shop-search",
41
54
  "./pages/branch-search",
55
+ "./pages/cube-theme",
42
56
  ],
43
57
  "packages": [
44
58
  "./packages/index?root=jmash"
@@ -1,7 +1,7 @@
1
1
  <template>
2
2
  <view class="logout-section">
3
3
  <!-- 登录状态才显示退出按钮 -->
4
- <button class="logout-btn" bind:tap="handleLogout" wx:if="{{ isLogin }}">退出登录</button>
4
+ <cube-button primary class="jmash-btn btn-width-50" bind:tap="handleLogout" wx:if="{{ isLogin }}">退出登录</cube-button>
5
5
  <text class="version-text">当前版本 V{{ version }}</text>
6
6
  </view>
7
7
  </template>
@@ -47,40 +47,20 @@ createComponent({
47
47
  </script>
48
48
 
49
49
  <style lang="scss">
50
- $primary: #07c160;
51
- $text-3: #999999;
50
+ @import "../../styles/mixin.css";
51
+
52
+ .btn-width-50 {
53
+ width: 50%;
54
+ }
52
55
 
53
56
  .logout-section {
54
- // 底部留空适配tabbar
55
- padding: 40rpx 16rpx 80rpx;
56
57
  display: flex;
57
58
  flex-direction: column;
58
59
  align-items: center;
59
60
 
60
- .logout-btn {
61
- width: 300rpx;
62
- height: 72rpx;
63
- border-radius: 36rpx;
64
- border: 2rpx solid #ff4d4f;
65
- background: #fff;
66
- color: #ff4d4f;
67
- font-size: 28rpx;
68
- font-weight: 500;
69
- display: flex;
70
- align-items: center;
71
- justify-content: center;
72
- margin-bottom: 24rpx;
73
- transition: all 0.2s;
74
-
75
- &:active {
76
- background: #fff1f0;
77
- transform: scale(0.98);
78
- }
79
- }
80
-
81
61
  .version-text {
82
- font-size: 24rpx;
83
- color: $text-3;
62
+ font-size: var(--cube-font-size-sm);
63
+ color: var(--cube-text-color-hint);
84
64
  }
85
65
  }
86
66
  </style>
@@ -88,6 +68,8 @@ $text-3: #999999;
88
68
  <script type="application/json">
89
69
  {
90
70
  "component": true,
91
- "usingComponents": {}
71
+ "usingComponents": {
72
+ "cube-button": "@mpxjs/mpx-cube-ui/lib/components/button/index.mpx"
73
+ }
92
74
  }
93
75
  </script>