meixioacomponent 0.2.18 → 0.2.21

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,6 +1,6 @@
1
1
  {
2
2
  "name": "meixioacomponent",
3
- "version": "0.2.18",
3
+ "version": "0.2.21",
4
4
  "private": false,
5
5
  "author": "YuRi",
6
6
  "main": "lib/meixioacomponent.umd.min.js",
@@ -16,7 +16,6 @@
16
16
  "dayjs": "^1.11.3",
17
17
  "element-ui": "^2.15.6",
18
18
  "gulp": "^4.0.0",
19
- "js-md5": "^0.7.3",
20
19
  "register-service-worker": "^1.7.1",
21
20
  "vue": "^2.6.11",
22
21
  "vue-router": "^3.2.0",
@@ -29,6 +28,7 @@
29
28
  "@vue/cli-plugin-router": "~4.5.13",
30
29
  "@vue/cli-plugin-vuex": "~4.5.13",
31
30
  "@vue/cli-service": "~4.5.13",
31
+ "babel-plugin-component": "^1.1.1",
32
32
  "less": "^3.0.4",
33
33
  "less-loader": "^5.0.0",
34
34
  "vue-template-compiler": "^2.6.11"
@@ -376,6 +376,10 @@ export default {
376
376
  },
377
377
  watch: {
378
378
  module(newVal, oldVal) {
379
+ if (!newVal) {
380
+ this.areaValue=[];
381
+ return;
382
+ }
379
383
  if (this.$parent.$options._componentTag == "el-form-item") {
380
384
  this.init();
381
385
  }
@@ -385,6 +385,7 @@ export default {
385
385
  this.isEdit = false;
386
386
  },
387
387
  loadSelectData() {
388
+
388
389
  this.selectStore.loadData();
389
390
  },
390
391
  visibleChange(visible) {
@@ -1,4 +1,5 @@
1
1
  import Vue from "vue";
2
+ import { useElementComponent } from "./useElement";
2
3
  import selectStore from "./storeModule/selectStore";
3
4
  const componentConfig = {
4
5
  store: null,
@@ -12,6 +13,8 @@ const componentConfig = {
12
13
  },
13
14
 
14
15
  initConfig: (_store, _router) => {
16
+ // 注册element 组件
17
+ useElementComponent();
15
18
  // 动态注册vuex modules
16
19
  _store.registerModule("selectStore", selectStore);
17
20
  // 注册vuex里面selectStore管理类
@@ -1,4 +1,3 @@
1
- import componentConfig from "../componentConfig";
2
1
  class SelectStore {
3
2
  constructor(params) {
4
3
  this.data = [];
@@ -8,6 +7,9 @@ class SelectStore {
8
7
  }
9
8
 
10
9
  async loadData() {
10
+ if (this.loading) {
11
+ return;
12
+ }
11
13
  this.loading = true;
12
14
  let result = await this.request();
13
15
 
@@ -0,0 +1,122 @@
1
+ import Vue from "vue";
2
+ import {
3
+ Pagination,
4
+ Dialog,
5
+ Autocomplete,
6
+ Dropdown,
7
+ DropdownMenu,
8
+ DropdownItem,
9
+ Menu,
10
+ Submenu,
11
+ MenuItem,
12
+ MenuItemGroup,
13
+ Input,
14
+ InputNumber,
15
+ Radio,
16
+ RadioGroup,
17
+ RadioButton,
18
+ Checkbox,
19
+ CheckboxButton,
20
+ CheckboxGroup,
21
+ Switch,
22
+ Select,
23
+ Option,
24
+ OptionGroup,
25
+ Button,
26
+ Table,
27
+ TableColumn,
28
+ DatePicker,
29
+ TimeSelect,
30
+ TimePicker,
31
+ Popover,
32
+ Tooltip,
33
+ Breadcrumb,
34
+ BreadcrumbItem,
35
+ Form,
36
+ FormItem,
37
+ Tabs,
38
+ TabPane,
39
+ Tag,
40
+ Tree,
41
+ Alert,
42
+ Slider,
43
+ Spinner,
44
+ Badge,
45
+ Steps,
46
+ Step,
47
+ Cascader,
48
+ ColorPicker,
49
+ Transfer,
50
+ Calendar,
51
+ CascaderPanel,
52
+ Loading,
53
+ MessageBox,
54
+ Message,
55
+ Card,
56
+ Drawer,
57
+ } from "element-ui";
58
+
59
+ export const useElementComponent = () => {
60
+ let elementComponentList = [
61
+ Pagination,
62
+ Dialog,
63
+ Autocomplete,
64
+ Dropdown,
65
+ DropdownMenu,
66
+ DropdownItem,
67
+ Menu,
68
+ Submenu,
69
+ MenuItem,
70
+ MenuItemGroup,
71
+ Input,
72
+ InputNumber,
73
+ Radio,
74
+ RadioGroup,
75
+ RadioButton,
76
+ Checkbox,
77
+ CheckboxButton,
78
+ CheckboxGroup,
79
+ Switch,
80
+ Select,
81
+ Option,
82
+ OptionGroup,
83
+ Button,
84
+ Table,
85
+ TableColumn,
86
+ DatePicker,
87
+ TimeSelect,
88
+ TimePicker,
89
+ Popover,
90
+ Tooltip,
91
+ Breadcrumb,
92
+ BreadcrumbItem,
93
+ Form,
94
+ FormItem,
95
+ Tabs,
96
+ TabPane,
97
+ Tag,
98
+ Tree,
99
+ Alert,
100
+ Slider,
101
+ Spinner,
102
+ Badge,
103
+ Steps,
104
+ Step,
105
+ Cascader,
106
+ ColorPicker,
107
+ Transfer,
108
+ Calendar,
109
+ CascaderPanel,
110
+ Loading,
111
+ Card,
112
+ Drawer,
113
+ ];
114
+ elementComponentList.forEach((item) => {
115
+ Vue.use(item);
116
+ });
117
+ // 解决刷新自动调用这两个组件
118
+ Vue.prototype.$message = Message;
119
+ Vue.prototype.$messagebox = MessageBox;
120
+ // 通过函数调用messageBox的confirm方法
121
+ Vue.prototype.$confirm = MessageBox.confirm;
122
+ };
Binary file
Binary file
Binary file
@@ -1,3 +0,0 @@
1
- <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
2
- <path d="M8.00251 14.9297L0 1.07422H6.14651L8.00251 4.27503L9.84583 1.07422H16L8.00251 14.9297Z" fill="black"/>
3
- </svg>