tianheng-ui 0.0.51 → 0.0.54

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": "tianheng-ui",
3
3
  "description": "A Vue.js project",
4
- "version": "0.0.51",
4
+ "version": "0.0.54",
5
5
  "author": "shu lang <403732931@qq.com>",
6
6
  "license": "MIT",
7
7
  "private": false,
@@ -27,9 +27,10 @@
27
27
  </div>
28
28
  </div>
29
29
  <slot></slot>
30
- <slot v-if="$slots.footer" slot="footer">
30
+
31
+ <template v-if="$slots.footer" slot="footer">
31
32
  <slot name="footer"></slot>
32
- </slot>
33
+ </template>
33
34
  <span v-else slot="footer">
34
35
  <el-button
35
36
  v-if="showAffirm"
@@ -108,7 +108,6 @@ export default {
108
108
  }
109
109
  }
110
110
  });
111
- // console.log(this.models)
112
111
  },
113
112
  generateRules(item) {
114
113
  if (this.rules[item.model]) {
@@ -163,7 +162,6 @@ export default {
163
162
  value: {
164
163
  deep: true,
165
164
  handler(val) {
166
- console.log(JSON.stringify(val));
167
165
  this.models = { ...this.models, ...val };
168
166
  }
169
167
  }
@@ -686,7 +686,6 @@ export default {
686
686
  this.selectWidget = row.columns[colIndex].list[newIndex];
687
687
  },
688
688
  handleWidgetTabAdd($event, row, colIndex) {
689
- console.log(row, colIndex);
690
689
  const newIndex = $event.newIndex;
691
690
  const oldIndex = $event.oldIndex;
692
691
  const item = $event.item;
@@ -126,7 +126,7 @@ export default {
126
126
  selectType: {
127
127
  type: String,
128
128
  default: () => {
129
- return "";
129
+ return "single";
130
130
  }
131
131
  },
132
132
  // 行双击事件
@@ -81,16 +81,11 @@ export default {
81
81
  default: () => {
82
82
  return [];
83
83
  }
84
- },
85
- params: {
86
- type: Object,
87
- default: () => {
88
- return {};
89
- }
90
84
  }
91
85
  },
92
86
  data() {
93
87
  return {
88
+ params: {},
94
89
  datePickerTypes: [
95
90
  "year",
96
91
  "month",
@@ -104,6 +99,23 @@ export default {
104
99
  ]
105
100
  };
106
101
  },
102
+ watch: {
103
+ options: {
104
+ handler(newVal, oldVal) {
105
+ if (newVal && newVal.length) {
106
+ newVal.map(item => {
107
+ this.$set(
108
+ this.params,
109
+ item.options.prop,
110
+ item.options.defaultValue
111
+ );
112
+ });
113
+ }
114
+ },
115
+ deep: true,
116
+ immediate: true
117
+ }
118
+ },
107
119
  methods: {
108
120
  doSearch() {
109
121
  this.$emit("on-search", this.params);