cloud-web-corejs 1.0.54-dev.603 → 1.0.54-dev.604

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": "cloud-web-corejs",
3
3
  "private": false,
4
- "version": "1.0.54-dev.603",
4
+ "version": "1.0.54-dev.604",
5
5
  "scripts": {
6
6
  "dev": "vue-cli-service serve",
7
7
  "lint": "eslint --ext .js,.vue src",
@@ -12,24 +12,34 @@
12
12
  :before-close="dialogClose"
13
13
  >
14
14
  <div class="cont">
15
- <el-form ref="editCategoryForm" :model="formData" label-width="102px" class="adSearchForm" style="height: auto; width: auto;">
15
+ <el-form
16
+ ref="editCategoryForm"
17
+ :model="formData"
18
+ label-width="102px"
19
+ class="adSearchForm"
20
+ style="height: auto; width: auto"
21
+ >
16
22
  <el-form-item :label="$t1('提取码')">
17
- <el-input v-model="formData.extractedCode" clearable class="all-width"/>
23
+ <el-input v-model="formData.extractedCode" clearable class="all-width" />
18
24
  </el-form-item>
19
25
  </el-form>
20
26
  </div>
21
27
  <span slot="footer" class="dialog-footer">
22
28
  <el-button type="primary" plain class="button-sty" @click="dialogClose">
23
29
  <i class="el-icon-close el-icon"></i>
24
- {{ $t2('取 消', 'system.button.cancel2') }}
30
+ {{ $t2("取 消", "system.button.cancel2") }}
25
31
  </el-button>
26
32
  <el-button type="primary" @click="dialogConfirm" class="button-sty">
27
33
  <i class="el-icon-check el-icon"></i>
28
- {{ $t1('确定') }}
34
+ {{ $t1("确定") }}
29
35
  </el-button>
30
36
  </span>
31
- <viewDialog v-if="showViewDialog" :visiable.sync="showViewDialog" @close="dialogClose"
32
- :extractedObj="extractedObj"></viewDialog>
37
+ <viewDialog
38
+ v-if="showViewDialog"
39
+ :visiable.sync="showViewDialog"
40
+ @close="dialogClose"
41
+ :extractedRow="extractedRow"
42
+ ></viewDialog>
33
43
  </el-dialog>
34
44
  </template>
35
45
  <script>
@@ -38,59 +48,56 @@ import viewDialog from "./viewDialog.vue";
38
48
  export default {
39
49
  name: "createDialog",
40
50
  components: {
41
- viewDialog
51
+ viewDialog,
42
52
  },
43
53
  data() {
44
54
  return {
45
55
  showDialog: true,
46
56
  formData: {
47
- extractedCode: null
57
+ extractedCode: null,
48
58
  },
49
59
  showViewDialog: false,
50
- extractedObj: {}
51
- }
60
+ extractedRow: {},
61
+ };
52
62
  },
53
63
  methods: {
54
64
  dialogConfirm() {
55
65
  if (!this.formData.extractedCode) {
56
66
  this.$baseAlert(this.$t1("提取码不能为空"));
57
- return
67
+ return;
58
68
  }
59
69
  this.$http({
60
70
  aes: true,
61
71
  url: USER_PREFIX + `/form_develop/getExtractedObjData`,
62
72
  method: `post`,
63
73
  data: {
64
- stringOne: this.formData.extractedCode
74
+ stringOne: this.formData.extractedCode,
65
75
  },
66
76
  isLoading: true,
67
- success: res => {
68
- let rows = res.objx || []
77
+ success: (res) => {
78
+ let rows = res.objx || [];
69
79
  if (rows.length) {
70
80
  let row = rows[0];
71
- let obj = row.obj
81
+ let obj = row.obj;
72
82
  if (!obj) {
73
83
  this.$baseAlert(this.$t1("提取对象为空"));
74
- return
84
+ return;
75
85
  }
76
- this.extractedObj = row;
86
+ this.extractedRow = row;
77
87
  this.showDialog = false;
78
88
  this.showViewDialog = true;
79
89
  } else {
80
90
  this.$baseAlert(this.$t1("无效提取码"));
81
91
  }
82
- }
83
- })
92
+ },
93
+ });
84
94
  },
85
95
  dialogClose() {
86
96
  this.showDialog = false;
87
- this.$emit('update:visiable', false)
97
+ this.$emit("update:visiable", false);
88
98
  },
89
- }
90
- }
99
+ },
100
+ };
91
101
  </script>
92
102
 
93
-
94
- <style scoped>
95
-
96
- </style>
103
+ <style scoped></style>
@@ -27,21 +27,33 @@
27
27
  @openDesignDialog="openDesingerDialogByChild"
28
28
  :extractedObj="extractedObj"
29
29
  ></component>
30
- <el-drawer :title="$t1('表单设计({formName})',{formName})" :visible.sync="showDesingerDialog" :modal="false"
31
- :destroy-on-close="true"
32
- size="100%" direction="rtl" :before-close="closeFormDesignwinEvent" :append-to-body="false"
33
- class="designer-drawer" :class="[isFullscreen ? 'is-fullscreen' : '']" @close="handleFormDesignClose">
30
+ <el-drawer
31
+ :title="$t1('表单设计({formName})', { formName })"
32
+ :visible.sync="showDesingerDialog"
33
+ :modal="false"
34
+ :destroy-on-close="true"
35
+ size="100%"
36
+ direction="rtl"
37
+ :before-close="closeFormDesignwinEvent"
38
+ :append-to-body="false"
39
+ class="designer-drawer"
40
+ :class="[isFullscreen ? 'is-fullscreen' : '']"
41
+ @close="handleFormDesignClose"
42
+ >
34
43
  <el-tabs v-model="formDesTabs" type="card" class="tab-boxOnly" :stretch="true">
35
44
  <el-tab-pane :label="$t1('设计器')" name="first">
36
- <designer ref="designer" :formCode.sync="formCode" :readonly="true"
37
- @reflushTemplateList="reflushTemplateList"></designer>
45
+ <designer
46
+ ref="designer"
47
+ :formCode.sync="formCode"
48
+ :readonly="true"
49
+ @reflushTemplateList="reflushTemplateList"
50
+ ></designer>
38
51
  </el-tab-pane>
39
52
  </el-tabs>
40
53
  <el-button class="isFullIcon" v-if="!isFullscreen" @click="handleFullscreen">
41
54
  <el-tooltip effect="dark" :content="$t1('全屏')" placement="top">
42
55
  <i class="iconfont icon-quanping"></i>
43
56
  </el-tooltip>
44
-
45
57
  </el-button>
46
58
  <el-button class="isFullIcon" v-else @click="handleFullscreen">
47
59
  <el-tooltip effect="dark" :content="$t1('缩小')" placement="top">
@@ -54,17 +66,15 @@
54
66
  </template>
55
67
 
56
68
  <script>
57
-
58
-
59
69
  import indexUtil from "@base/utils";
60
70
  import designer from "@base/views/user/form/vform/designer.vue";
61
71
 
62
72
  export default {
63
73
  name: "wfContentDialog",
64
74
  props: {
65
- extractedObj: Object,
75
+ extractedRow: Object,
66
76
  },
67
- components: {designer},
77
+ components: { designer },
68
78
  data() {
69
79
  return {
70
80
  param: {},
@@ -76,57 +86,59 @@ export default {
76
86
  formCode: null,
77
87
  formName: null,
78
88
  isFullscreen: false,
79
- formDesTabs: 'first',
80
- title: null
89
+ formDesTabs: "first",
90
+ title: null,
91
+ extractedObj: null,
81
92
  };
82
93
  },
83
94
  mounted() {
84
95
  this.$nextTick(() => {
85
96
  this.openWfDialog();
86
- })
97
+ });
87
98
  },
88
99
  methods: {
89
100
  wfClose() {
90
101
  this.showWfDialog = false;
91
- this.$emit('update:visible', false);
92
- this.$emit('close');
102
+ this.$emit("update:visible", false);
103
+ this.$emit("close");
93
104
  },
94
105
  openWfDialog() {
95
- let extractedObj = this.extractedObj;
96
- let objType = extractedObj.objType;
97
- let obj = extractedObj.obj;
106
+ let obj = this.extractedRow?.obj;
107
+ if (!obj) return;
108
+ this.extractedObj = obj;
109
+ let objType = this.extractedRow.objType;
98
110
  let id = obj.id;
99
111
  let wfDataId = id;
100
112
  let param = {
101
- readonly: true
113
+ readonly: true,
102
114
  };
103
115
 
104
116
  let url;
105
117
  if (objType == "FormTemplate") {
106
- url = "/bd/setting/form_template/edit.vue"
118
+ url = "/bd/setting/form_template/edit.vue";
107
119
  wfDataId = obj.formCode;
108
120
  this.title = this.$t1("查看表单模板");
109
121
  } else if (objType == "FormScript") {
110
122
  if (obj.scriptType == 1) {
111
- url = "/bd/setting/form_script/edit1.vue"
123
+ url = "/bd/setting/form_script/edit1.vue";
112
124
  } else {
113
- url = "/bd/setting/form_script/edit.vue"
125
+ url = "/bd/setting/form_script/edit.vue";
114
126
  }
115
127
  this.title = this.$t1("查看表单脚本");
116
128
  } else if (objType == "TableTemplate") {
117
- url = "/bd/setting/table_model/edit.vue"
129
+ url = "/bd/setting/table_model/edit.vue";
118
130
  this.title = this.$t1("查看数据表定义模板");
119
131
  }
120
132
  this.param = Object.assign(param, {
121
- _dataId: wfDataId
133
+ _dataId: wfDataId,
122
134
  });
123
- this.wfContent = require('@base/views' + url).default;
135
+ this.wfContent = require("@base/views" + url).default;
124
136
 
125
137
  this.showWfContent = true;
126
138
  },
127
139
 
128
140
  handleFormDesignClose() {
129
- this.formDesTabs = 'first';
141
+ this.formDesTabs = "first";
130
142
  this.showFormScriptList = false;
131
143
  },
132
144
  openDesingerDialog(row, callback) {
@@ -137,8 +149,8 @@ export default {
137
149
  this.showDesingerDialog = true;
138
150
  this.designerSaveCallback = callback ?? null;
139
151
  },
140
- openDesingerDialogByChild({row, callback}) {
141
- this.openDesingerDialog(row, callback)
152
+ openDesingerDialogByChild({ row, callback }) {
153
+ this.openDesingerDialog(row, callback);
142
154
  },
143
155
  reflushTemplateList() {
144
156
  // this.searchEvent();
@@ -159,9 +171,8 @@ export default {
159
171
  done && done();
160
172
  });
161
173
  },
162
-
163
- }
164
- }
174
+ },
175
+ };
165
176
  </script>
166
177
 
167
178
  <style scoped>
@@ -173,21 +184,26 @@ export default {
173
184
 
174
185
  ::v-deep .tab-boxOnly > .el-tabs__content .el-tab-pane .el-tab-pane {
175
186
  .detail-wrap .d-cont {
176
- height: calc(100vh - 158px) !important
187
+ height: calc(100vh - 158px) !important;
177
188
  }
178
189
 
179
190
  .grid-height {
180
- height: calc(100vh - 126px) !important
191
+ height: calc(100vh - 126px) !important;
181
192
  }
182
193
  }
183
194
 
184
- ::v-deep .designer-drawer.is-fullscreen .tab-boxOnly > .el-tabs__content .el-tab-pane .el-tab-pane {
195
+ ::v-deep
196
+ .designer-drawer.is-fullscreen
197
+ .tab-boxOnly
198
+ > .el-tabs__content
199
+ .el-tab-pane
200
+ .el-tab-pane {
185
201
  .detail-wrap .d-cont {
186
- height: calc(100vh - 116px) !important
202
+ height: calc(100vh - 116px) !important;
187
203
  }
188
204
 
189
205
  .grid-height {
190
- height: calc(100vh - 84px) !important
206
+ height: calc(100vh - 84px) !important;
191
207
  }
192
208
  }
193
209
  </style>
@@ -97,8 +97,27 @@ modules = {
97
97
  this.getData();
98
98
  },
99
99
  methods: {
100
+ initData(formData){
101
+ if(!!formData?.id)this.isEdit = true;
102
+ this.formScript = formData || {};
103
+ this.showCodeEditor = true;
104
+ this.getMenuKindAuth(this.formScript.menuKindCode);
105
+ },
100
106
  getData() {
101
- if (this.dataId && !isNaN(this.dataId)) {
107
+ debugger
108
+ if(this.extractedObj){
109
+ this.dataId = this.extractedObj.id;
110
+ this.initData(this.extractedObj)
111
+ //获取操作日志数据
112
+ this.$refs["oplogTable"].initData({
113
+ param: () => {
114
+ return {
115
+ logType: "FormScript",
116
+ logObjCode: this.formScript.sid,
117
+ };
118
+ },
119
+ });
120
+ }else if (this.dataId && !isNaN(this.dataId)) {
102
121
  this.isEdit = true;
103
122
  this.$commonHttp({
104
123
  aes: true,
@@ -110,9 +129,10 @@ modules = {
110
129
  isLoading: true,
111
130
  modalStrictly: true,
112
131
  success: (res) => {
113
- this.formScript = res.objx || {};
114
- this.showCodeEditor = true;
115
- this.getMenuKindAuth(this.formScript.menuKindCode);
132
+ // this.formScript = res.objx || {};
133
+ // this.showCodeEditor = true;
134
+ // this.getMenuKindAuth(this.formScript.menuKindCode);
135
+ this.initData(res.objx)
116
136
  //获取操作日志数据
117
137
  this.$refs["oplogTable"].initData({
118
138
  param: () => {
@@ -125,12 +145,13 @@ modules = {
125
145
  },
126
146
  });
127
147
  } else if (this.hData) {
128
- this.isEdit = true;
129
- this.formScript = this.$baseLodash.cloneDeep(this.hData);
130
148
  this.dataId = this.hData.id;
131
- this.isInited = true;
149
+ /* this.isEdit = true;
150
+ this.formScript = this.$baseLodash.cloneDeep(this.hData);
132
151
  this.getMenuKindAuth(this.formScript.menuKindCode);
133
- this.showCodeEditor = true;
152
+ this.showCodeEditor = true; */
153
+ this.initData(this.$baseLodash.cloneDeep(this.hData))
154
+
134
155
  if (this.compareHData && this.$attrs.isCompare) {
135
156
  this.oldFormScript = this.$baseLodash.cloneDeep(this.compareHData);
136
157
  this.isCompare = true;
@@ -91,8 +91,26 @@ modules = {
91
91
  this.getData();
92
92
  },
93
93
  methods: {
94
+ initData(formData){
95
+ if(!!formData?.id)this.isEdit = true;
96
+ this.formScript = formData || {};
97
+ this.showCodeEditor = true;
98
+ this.getMenuKindAuth(this.formScript.menuKindCode);
99
+ },
94
100
  getData() {
95
- if (this.dataId && !isNaN(this.dataId)) {
101
+ if(this.extractedObj){
102
+ this.dataId = this.extractedObj.id;
103
+ this.initData(this.extractedObj)
104
+ //获取操作日志数据
105
+ this.$refs["oplogTable"].initData({
106
+ param: () => {
107
+ return {
108
+ logType: "FormScript",
109
+ logObjCode: this.formScript.sid,
110
+ };
111
+ },
112
+ });
113
+ }else if (this.dataId && !isNaN(this.dataId)) {
96
114
  this.isEdit = true;
97
115
  this.$commonHttp({
98
116
  aes: true,
@@ -104,9 +122,10 @@ modules = {
104
122
  isLoading: true,
105
123
  modalStrictly: true,
106
124
  success: (res) => {
107
- this.formScript = res.objx || {};
108
- this.showCodeEditor = true;
109
- this.getMenuKindAuth(this.formScript.menuKindCode);
125
+ // this.formScript = res.objx || {};
126
+ // this.showCodeEditor = true;
127
+ // this.getMenuKindAuth(this.formScript.menuKindCode);
128
+ this.initData(res.objx)
110
129
  //获取操作日志数据
111
130
  this.$refs["oplogTable"].initData({
112
131
  param: () => {
@@ -119,12 +138,13 @@ modules = {
119
138
  },
120
139
  });
121
140
  } else if (this.hData) {
122
- this.isEdit = true;
123
- this.formScript = this.$baseLodash.cloneDeep(this.hData);
124
141
  this.dataId = this.hData.id;
125
- this.isInited = true;
142
+ /* this.isEdit = true;
143
+ this.formScript = this.$baseLodash.cloneDeep(this.hData);
126
144
  this.getMenuKindAuth(this.formScript.menuKindCode);
127
- this.showCodeEditor = true;
145
+ this.showCodeEditor = true; */
146
+ this.initData(this.$baseLodash.cloneDeep(this.hData))
147
+
128
148
  if (this.compareHData && this.$attrs.isCompare) {
129
149
  this.oldFormScript = this.$baseLodash.cloneDeep(this.compareHData);
130
150
  this.isCompare = true;
@@ -187,6 +187,7 @@
187
187
  @reflushTemplateList="reflushTemplateList"
188
188
  :readonly="designerReadonly"
189
189
  :formTemplate="currentFormTemplate"
190
+ :historyFlag="historyFlag"
190
191
  ></formDesignerDialog>
191
192
  <el-dialog
192
193
  :title="$t1('流程设计')"
@@ -101,8 +101,18 @@ modules = {
101
101
  });
102
102
  },
103
103
  getData() {
104
- if(this.extractedObj?.objx){
105
- this.initData(this.extractedObj.objx)
104
+ if(this.extractedObj){
105
+ this.dataId = this.extractedObj.id;
106
+ this.initData(this.extractedObj)
107
+ //获取操作日志数据
108
+ this.$refs['oplogTable'].initData({
109
+ param: () => {
110
+ return {
111
+ logType: "FormTemplate",
112
+ logObjCode: this.formTemplate.formCode
113
+ };
114
+ }
115
+ });
106
116
  }else if (this.dataId) {
107
117
  this.$commonHttp({
108
118
  aes: true,
@@ -216,9 +226,11 @@ modules = {
216
226
  },
217
227
  openDesignDialog() {
218
228
  let readonly = this.readonly || !this.menuKindAuth.editAuth
229
+ debugger
219
230
  this.$emit('openDesignDialog', {
220
231
  row: this.formTemplate,
221
232
  readonly,
233
+ historyFlag: !!this.hData,
222
234
  callback: () => {
223
235
  this.$baseReload()
224
236
  }
@@ -136,7 +136,8 @@ modules = {
136
136
  isDev: true,
137
137
  menuKindAuth: {},
138
138
  showTree: false,
139
- designerReadonly: false
139
+ designerReadonly: false,
140
+ historyFlag: false,
140
141
  };
141
142
  },
142
143
  computed: {
@@ -210,19 +211,19 @@ modules = {
210
211
  });
211
212
  }
212
213
  },
213
- openDesingerDialog(row, callback, readonly = false) {
214
- debugger;
214
+ openDesingerDialog(row, callback, readonly = false, historyFlag = false) {
215
215
  this.formCode = row.formCode;
216
216
  this.formName = row.formName;
217
- this.currentFormTemplate = row;
217
+ this.historyFlag = historyFlag;
218
+ this.currentFormTemplate = historyFlag ? row : null;
218
219
  this.isFullscreen = false;
219
220
 
220
221
  this.designerReadonly = readonly
221
222
  this.showDesingerDialog = true;
222
223
  this.designerSaveCallback = callback ?? null;
223
224
  },
224
- openDesingerDialogByChild({row, readonly, callback}) {
225
- this.openDesingerDialog(row, callback, readonly);
225
+ openDesingerDialogByChild({row, readonly, historyFlag, callback}) {
226
+ this.openDesingerDialog(row, callback, readonly, historyFlag);
226
227
  },
227
228
  reflushTemplateList() {
228
229
  this.searchEvent();
@@ -163,8 +163,26 @@ modules = {
163
163
  this.getData();
164
164
  },
165
165
  methods: {
166
+ initData(formData){
167
+ if(!!formData?.id)this.isEdit = true;
168
+ this.szTaMb = formData;
169
+ this.getMenuKindAuth(formData.menuKindCode);
170
+ if(!!formData?.id)this.getCreatedTableColumns();
171
+ },
166
172
  getData(callback) {
167
- if (this.dataId && !isNaN(this.dataId)) {
173
+ if(this.extractedObj){
174
+ this.dataId = this.extractedObj.id;
175
+ this.initData(this.extractedObj)
176
+ //获取操作日志数据
177
+ this.$refs["oplogTable"].initData({
178
+ param: () => {
179
+ return {
180
+ logType: "SzTaMb",
181
+ logObjCode: this.szTaMb.taCode,
182
+ };
183
+ },
184
+ });
185
+ }else if (this.dataId && !isNaN(this.dataId)) {
168
186
  this.isEdit = true;
169
187
  this.$http({
170
188
  aes: true,
@@ -181,10 +199,11 @@ modules = {
181
199
  szTaMb.szTaZdMbDTOs = this.szTaMb.szTaZdMbDTOs;
182
200
  szTaMb.attachmentDTOs = this.szTaMb.attachmentDTOs;
183
201
  szTaMb.oplogDTOs = this.szTaMb.oplogDTOs;
184
- this.szTaMb = szTaMb;
185
202
 
186
- this.getCreatedTableColumns();
187
- this.getMenuKindAuth(this.szTaMb.menuKindCode);
203
+ // this.szTaMb = szTaMb;
204
+ // this.getCreatedTableColumns();
205
+ // this.getMenuKindAuth(this.szTaMb.menuKindCode);
206
+ this.initData(szTaMb);
188
207
  } else {
189
208
  callback(res);
190
209
  }
@@ -200,11 +219,12 @@ modules = {
200
219
  },
201
220
  });
202
221
  } else if (this.hData){
203
- this.isEdit = true;
204
- this.szTaMb = this.$baseLodash.cloneDeep(this.hData);
205
222
  this.dataId = this.hData.id
223
+ /* this.isEdit = true;
224
+ this.szTaMb = this.$baseLodash.cloneDeep(this.hData);
206
225
  this.getMenuKindAuth(this.szTaMb.menuKindCode);
207
- this.getCreatedTableColumns();
226
+ this.getCreatedTableColumns(); */
227
+ this.initData(this.$baseLodash.cloneDeep(this.hData));
208
228
  if (this.compareHData && this.$attrs.isCompare) {
209
229
  this.oldSzTaMb = this.$baseLodash.cloneDeep(this.compareHData);
210
230
  let oldSzTaZdMbDTOs = this.$baseLodash.cloneDeep(this.compareHData.szTaZdMbDTOs) || [];
@@ -91,6 +91,8 @@ export default {
91
91
  getTemplate() {
92
92
  /* this.showDesinger = true;
93
93
  return */
94
+ debugger;
95
+ let a = 1;
94
96
  if (this.columnFlag) {
95
97
  this.reportTemplate = this.formTemplate;
96
98
  this.showDesinger = true;
@@ -101,7 +103,7 @@ export default {
101
103
  });
102
104
  this.$refs.designer.setFormJson(formJson);
103
105
  });
104
- } else if (this.formTemplate) {
106
+ } else if (this.formTemplate && this.reportTemplate.formViewContent) {
105
107
  this.reportTemplate = this.$baseLodash.cloneDeep(this.formTemplate);
106
108
  this.showDesinger = true;
107
109
  this.$nextTick(() => {