mooho-base-admin-plus 2.5.24 → 2.5.26

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "mooho-base-admin-plus",
3
3
  "description": "MOOHO basic framework for admin by Vue3",
4
- "version": "2.5.24",
4
+ "version": "2.5.26",
5
5
  "author": "jinyifan <jinyifan@mooho.com.cn>",
6
6
  "license": "MIT",
7
7
  "private": false,
@@ -321,6 +321,14 @@
321
321
  getFullData() {
322
322
  return this.$refs.form.getFullData();
323
323
  },
324
+ /**
325
+ * 获取完整数据,跳过验证
326
+ *
327
+ * @public
328
+ */
329
+ getFullDataWithoutValidate() {
330
+ return this.$refs.form.getFullDataWithoutValidate();
331
+ },
324
332
  // /**
325
333
  // * 强制更新
326
334
  // *
@@ -227,7 +227,16 @@
227
227
  },
228
228
  // 执行结果
229
229
  async action(outcome) {
230
- let isOK = await this.form.validate();
230
+ let isOK;
231
+ if (this.isCustom && typeof this.$refs.customComponent.actionValidation === 'function') {
232
+ isOK = await this.$refs.customComponent.actionValidation(outcome);
233
+
234
+ if (!isOK) {
235
+ return;
236
+ }
237
+ }
238
+
239
+ isOK = await this.form.validate();
231
240
 
232
241
  if (!isOK) {
233
242
  this.error('Front_Msg_Form_Validate_Fail');
@@ -265,6 +274,14 @@
265
274
  },
266
275
  // 拒绝
267
276
  async reject() {
277
+ if (this.isCustom && typeof this.$refs.customComponent.rejectValidation === 'function') {
278
+ let isOK = await this.$refs.customComponent.rejectValidation();
279
+
280
+ if (!isOK) {
281
+ return;
282
+ }
283
+ }
284
+
268
285
  this.confirmInput(
269
286
  'Front_Msg_Sure_To_Reject_Application',
270
287
  this.$t('Front_Label_Comment'),
@@ -825,7 +825,9 @@ export default {
825
825
  // 重置通知栏数字
826
826
  resetNotice() {
827
827
  let notice = this.getNotice(this);
828
- notice.init();
828
+ if (notice) {
829
+ notice.init();
830
+ }
829
831
  },
830
832
  // 获取通知栏
831
833
  getNotice(node) {
@@ -0,0 +1,51 @@
1
+ const VueLoaderPlugin = require('vue-loader/lib/plugin');
2
+
3
+ module.exports = {
4
+ title: 'mooho-base-admin-plus',
5
+ components: [
6
+ 'src/components/view/modal-form.vue',
7
+ 'src/components/view/modal-table.vue',
8
+ 'src/components/view/view-form.vue',
9
+ 'src/components/view/view-table.vue',
10
+ 'src/components/view/view-chart.vue',
11
+ 'src/components/input/*.vue'
12
+ ],
13
+ styleguideDir: 'styleguide-dist',
14
+ // 在编辑器的右上角添加一个小按钮,用于将编辑器的内容复制到剪贴板
15
+ copyCodeButton: true,
16
+ // 是否每个章节是一个独立的页面. 默认:false
17
+ pagePerSection: false,
18
+ // props/events/slot的说明默认是展开还是收缩: expand / collapse / hide
19
+ usageMode: 'expand',
20
+ // 左侧导航默认是展开还是收缩: expand / collapse / hide
21
+ tocMode: 'expand',
22
+ // 显示 prop、事件、槽或方法是否来自当前文件或在 mixin 或扩展组件中配置。如果它是外部的,它会显示组件的名称,并在悬停时显示文件的相对路径。
23
+ displayOrigins: true,
24
+ webpackConfig: {
25
+ module: {
26
+ rules: [
27
+ // Vue loader
28
+ {
29
+ test: /\.vue$/,
30
+ exclude: /node_modules/,
31
+ loader: 'vue-loader'
32
+ },
33
+ // Babel loader, will use your project’s .babelrc
34
+ {
35
+ test: /\.js?$/,
36
+ exclude: /node_modules/,
37
+ loader: 'babel-loader'
38
+ },
39
+ // Other loaders that are needed for your components
40
+ {
41
+ test: /\.css$/,
42
+ loader: 'style-loader!css-loader'
43
+ }
44
+ ]
45
+ },
46
+ plugins: [
47
+ // add vue-loader plugin
48
+ new VueLoaderPlugin()
49
+ ]
50
+ }
51
+ };