cloud-web-corejs 1.0.54-dev.626 → 1.0.54-dev.628

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.
@@ -3,21 +3,64 @@
3
3
  <el-form-item label-width="0">
4
4
  <el-divider class="custom-divider">下拉按钮设置</el-divider>
5
5
  </el-form-item>
6
- <el-form-item label="当前下拉按钮"></el-form-item>
7
- <el-form-item label-width="0">
8
- <draggable tag="ul" class="draggable-box" :list="selectedWidget.widgetList"
9
- v-bind="{ group: 'optionsGroup', ghostClass: 'ghost', handle: '.drag-option' }">
10
- <li v-for="(colItem, colIdx) in selectedWidget.widgetList" :key="colIdx" class="col-item">
6
+ <el-form-item label="按钮样式">
7
+ <el-select
8
+ v-model="optionModel.dropdownType"
9
+ placeholder="请选择按钮样式"
10
+ >
11
+ <el-option label="按钮" value="button"></el-option>
12
+ <el-option label="链接" value="link"></el-option>
13
+ </el-select>
14
+ </el-form-item>
15
+ <el-form-item label="下拉触发方式">
16
+ <el-select
17
+ v-model="optionModel.dropdownTrigger"
18
+ placeholder="请选择下拉触发方式"
19
+ >
20
+ <el-option label="点击" value="click"></el-option>
21
+ <el-option label="悬停" value="hover"></el-option>
22
+ </el-select>
23
+ </el-form-item>
24
+ <el-form-item label="下拉按钮选项"></el-form-item>
25
+ <li
26
+ v-for="(colItem, colIdx) in selectedWidget.widgetList"
27
+ :key="colIdx"
28
+ class="col-item"
29
+ >
11
30
  <i class="el-icon-s-operation drag-option"></i>
12
- <el-input v-model="colItem.options.label" class="cell-span-input"></el-input>
13
- <el-button circle plain size="mini" type="button"
14
- icon="el-icon-edit" class="col-delete-button" style="position: unset;" @click="openEditFormatConfigDialog(colItem, colIdx)"></el-button>
15
- <el-button circle plain size="mini" type="danger" @click="deleteCol(selectedWidget, colIdx)"
16
- icon="el-icon-minus" class="col-delete-button" style="position: unset;"></el-button>
31
+ <el-input
32
+ v-model="colItem.options.label"
33
+ class="cell-span-input"
34
+ ></el-input>
35
+ <el-button
36
+ circle
37
+ plain
38
+ size="mini"
39
+ type="button"
40
+ icon="el-icon-edit"
41
+ class="col-delete-button"
42
+ style="position: unset"
43
+ @click="openEditFormatConfigDialog(colItem, colIdx)"
44
+ ></el-button>
45
+ <el-button
46
+ circle
47
+ plain
48
+ size="mini"
49
+ type="danger"
50
+ @click="deleteCol(selectedWidget, colIdx)"
51
+ icon="el-icon-minus"
52
+ class="col-delete-button"
53
+ style="position: unset"
54
+ ></el-button>
17
55
  </li>
18
56
  </draggable>
19
57
  <div>
20
- <el-button type="text" @click="addNewCol(selectedWidget)" icon="el-icon-circle-plus-outline" class="add-option">
58
+ <el-button
59
+ type="text"
60
+ @click="addNewCol(selectedWidget)"
61
+ icon="el-icon-circle-plus-outline"
62
+ class="add-option"
63
+ >
21
64
  增加
22
65
  </el-button>
23
66
  </div>
@@ -26,9 +69,9 @@
26
69
  </template>
27
70
 
28
71
  <script>
29
- import Draggable from 'vuedraggable';
30
- import i18n from "../../../utils/i18n"
31
- import {deepClone, generateId} from "../../../utils/util"
72
+ import Draggable from "vuedraggable";
73
+ import i18n from "../../../utils/i18n";
74
+ import { deepClone, generateId } from "../../../utils/util";
32
75
 
33
76
  export default {
34
77
  name: "dropdownFlag-editor",
@@ -41,23 +84,25 @@ export default {
41
84
  selectedWidget: Object,
42
85
  optionModel: Object,
43
86
  },
44
- inject: ['openWidgetPropertyDialog'],
87
+ inject: ["openWidgetPropertyDialog"],
45
88
  methods: {
46
89
  deleteCol(gridWidget, colIdx) {
47
90
  if (!!gridWidget && !!gridWidget.widgetList) {
48
91
  gridWidget.widgetList.splice(colIdx, 1);
49
92
  }
50
- this.designer.emitHistoryChange()
93
+ this.designer.emitHistoryChange();
51
94
  },
52
95
 
53
96
  addNewCol(gridWidget) {
54
- let newGridCol = deepClone(this.designer.getFieldWidgetByType('dropdown-item'));
97
+ let newGridCol = deepClone(
98
+ this.designer.getFieldWidgetByType("dropdown-item")
99
+ );
55
100
  let tmpId = generateId();
56
- newGridCol.id = 'dropdown-item-' + tmpId;
57
- newGridCol.options.name = 'dropdownItem' + tmpId;
58
- newGridCol.options.label = 'dropdownItem' + tmpId;
101
+ newGridCol.id = "dropdown-item-" + tmpId;
102
+ newGridCol.options.name = "dropdownItem" + tmpId;
103
+ newGridCol.options.label = "dropdownItem" + tmpId;
59
104
  gridWidget.widgetList.push(newGridCol);
60
- this.designer.emitHistoryChange()
105
+ this.designer.emitHistoryChange();
61
106
  },
62
107
  openEditFormatConfigDialog(fieldWidget, index) {
63
108
  this.openWidgetPropertyDialog({
@@ -67,8 +112,8 @@ export default {
67
112
  },
68
113
  });
69
114
  },
70
- }
71
- }
115
+ },
116
+ };
72
117
  </script>
73
118
 
74
119
  <style lang="scss" scoped>
@@ -85,5 +130,4 @@ li.col-item {
85
130
  margin-left: 6px;
86
131
  }
87
132
  }
88
-
89
133
  </style>
@@ -3,7 +3,7 @@
3
3
  <a
4
4
  href="javascript:void(0);"
5
5
  class="a-link link-oneLind"
6
- @click="editEventHandler('onClick', eventParams)"
6
+ @click="openEventHandlerDialog"
7
7
  >
8
8
  <span>{{ optionModel.onClick }}</span>
9
9
  <i class="el-icon-edit"></i>
@@ -22,23 +22,31 @@ export default {
22
22
  designer: Object,
23
23
  selectedWidget: Object,
24
24
  optionModel: Object,
25
+ tableColumns: Array,
25
26
  },
26
27
  data() {
27
28
  return {
28
29
  // eventParams: ["id", "formCode"],
29
30
  };
30
31
  },
31
- computed: {
32
- eventParams() {
33
- let eventParams = ["dataId", "formCode", "event"];
34
- if (this.optionModel.rowFlag) {
35
- eventParams.push("row", "index", "event");
32
+
33
+ methods: {
34
+ getEventParams() {
35
+ let eventParams = ["dataId", "formCode"];
36
+ if (this.tableColumns && this.tableColumns.length > 0) {
37
+ eventParams.push("row", "rowIndex", "event");
38
+ } else {
39
+ eventParams.push("event");
36
40
  }
37
41
  if (this.selectedWidget.type == "census") {
38
42
  eventParams.push("param");
39
43
  }
40
44
  return eventParams;
41
45
  },
46
+ openEventHandlerDialog() {
47
+ let eventParams = this.getEventParams();
48
+ this.editEventHandler("onClick", eventParams);
49
+ },
42
50
  },
43
51
  };
44
52
  </script>
@@ -398,6 +398,7 @@ export const containers = [
398
398
  hidden: !1,
399
399
  label: "单据详情",
400
400
  detailContainer: true,
401
+ hideNav: false,
401
402
  // colHeight: null,
402
403
  customClass: "",
403
404
  wfEnabled: false,
@@ -3391,6 +3392,8 @@ export const advancedFields = [
3391
3392
  disabled: !1,
3392
3393
  customClass: "",
3393
3394
  dropdownFlag: 1,
3395
+ dropdownType: "button",
3396
+ dropdownTrigger: "hover",
3394
3397
  // ...defaultWfConfig,
3395
3398
  onCreated: "",
3396
3399
  onMounted: "",