cloud-web-corejs 1.0.31 → 1.0.32

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.
Files changed (49) hide show
  1. package/package.json +1 -1
  2. package/src/components/statusTag/index.vue +14 -14
  3. package/src/components/statusTag/mixins.js +5 -5
  4. package/src/components/table/index.js +10 -10
  5. package/src/components/xform/form-designer/form-widget/field-widget/fieldMixin.js +1 -1
  6. package/src/components/xform/form-designer/form-widget/field-widget/form-item-wrapper.vue +379 -379
  7. package/src/components/xform/form-designer/form-widget/field-widget/status-widget.vue +125 -125
  8. package/src/components/xform/form-render/container-item/data-table-mixin.js +18 -18
  9. package/src/views/bd/setting/bd_attach_setting/dialog.vue +4 -2
  10. package/src/views/bd/setting/bd_attach_setting/edit.vue +7 -6
  11. package/src/views/bd/setting/bd_attach_setting/list.vue +2 -2
  12. package/src/views/bd/setting/bd_attach_setting/mixins/dialog.js +5 -5
  13. package/src/views/bd/setting/bd_attach_setting/mixins/list.js +15 -23
  14. package/src/views/bd/setting/form_script/dialog.vue +8 -7
  15. package/src/views/bd/setting/form_script/edit.vue +9 -9
  16. package/src/views/bd/setting/form_script/edit1.vue +20 -18
  17. package/src/views/bd/setting/form_script/form_list.vue +5 -5
  18. package/src/views/bd/setting/form_script/list1.vue +8 -6
  19. package/src/views/bd/setting/form_script/mixins/dialog.js +15 -23
  20. package/src/views/bd/setting/form_script/mixins/form_list.js +52 -36
  21. package/src/views/bd/setting/form_script/mixins/list.js +19 -27
  22. package/src/views/bd/setting/form_script/mixins/list1.js +28 -36
  23. package/src/views/bd/setting/form_template/dialog.vue +6 -6
  24. package/src/views/bd/setting/form_template/edit.vue +30 -37
  25. package/src/views/bd/setting/form_template/editWfObjConfigDialog.vue +3 -3
  26. package/src/views/bd/setting/form_template/ftHistoryDialog.vue +5 -4
  27. package/src/views/bd/setting/form_template/itemEdit.vue +29 -25
  28. package/src/views/bd/setting/form_template/itemList.vue +1 -1
  29. package/src/views/bd/setting/form_template/list.vue +15 -13
  30. package/src/views/bd/setting/form_template/mixins/dialog.js +7 -14
  31. package/src/views/bd/setting/form_template/mixins/ftHistoryDialog.js +4 -4
  32. package/src/views/bd/setting/form_template/mixins/itemList.js +43 -57
  33. package/src/views/bd/setting/form_template/mixins/list.js +40 -77
  34. package/src/views/bd/setting/form_template/preformDialog.vue +1 -1
  35. package/src/views/bd/setting/menu_kind/authDialog.vue +7 -2
  36. package/src/views/bd/setting/menu_kind/dialog.vue +2 -2
  37. package/src/views/bd/setting/menu_kind/list.vue +7 -10
  38. package/src/views/bd/setting/menu_kind/mixins/authDialog.js +14 -33
  39. package/src/views/bd/setting/menu_kind/mixins/dialog.js +14 -18
  40. package/src/views/bd/setting/menu_kind/mixins/list.js +17 -24
  41. package/src/views/bd/setting/table_model/dialog.vue +8 -6
  42. package/src/views/bd/setting/table_model/edit.vue +79 -41
  43. package/src/views/bd/setting/table_model/list.vue +8 -11
  44. package/src/views/bd/setting/table_model/mixins/dialog.js +6 -6
  45. package/src/views/bd/setting/table_model/mixins/edit.js +54 -84
  46. package/src/views/bd/setting/table_model/mixins/list.js +26 -58
  47. package/src/views/bd/setting/table_model/mixins/zdDialog.js +14 -16
  48. package/src/views/bd/setting/table_model/zdDialog.vue +8 -6
  49. package/src/views/bd/setting/utils/index.js +60 -0
@@ -6,6 +6,7 @@ import itemSzTaMbDialog from "@base/views/bd/setting/table_model/dialog.vue";
6
6
  import MenuKindDialog from "@base/views/bd/setting/menu_kind/dialog.vue";
7
7
  import zdDialog from "@base/views/bd/setting/table_model/zdDialog.vue";
8
8
  import {getBdFlag} from "@base/api/user";
9
+ import {getJsxBtn} from "@base/views/bd/setting/utils/index";
9
10
 
10
11
  let modules = {};
11
12
  modules = {
@@ -84,7 +85,7 @@ modules = {
84
85
  if (this.dataId && !isNaN(this.dataId)) {
85
86
  this.isEdit = true;
86
87
  this.$http({
87
- aes:true,
88
+ aes: true,
88
89
  url: USER_PREFIX + `/szTaMb/get`,
89
90
  method: `post`,
90
91
  data: {
@@ -101,7 +102,7 @@ modules = {
101
102
  this.szTaMb = szTaMb;
102
103
 
103
104
  this.getCreatedTableColumns();
104
- this.getMenuKindAuth(this.szTaMb.menuKindCode);
105
+ // this.getMenuKindAuth(this.szTaMb.menuKindCode);
105
106
  } else {
106
107
  callback(res)
107
108
  }
@@ -122,11 +123,11 @@ modules = {
122
123
  updateStatus(status) {
123
124
  let text;
124
125
  if (status === 3) {
125
- text = '您确定要作废吗?';
126
+ text = this.$t1('您确定要作废吗?');
126
127
  }
127
128
  this.$baseConfirm(text).then(() => {
128
129
  this.$http({
129
- aes:true,
130
+ aes: true,
130
131
  url: USER_PREFIX + `/szTaMb/updateStatus`,
131
132
  method: `post`,
132
133
  data: {
@@ -152,7 +153,7 @@ modules = {
152
153
  if (valid) {
153
154
  const szTaZdMbDTOs = this.$refs['table-szTaZdMb'].getTableData().fullData;
154
155
  if (szTaZdMbDTOs.length === 0) {
155
- this.$baseAlert('明细不能为空!');
156
+ this.$baseAlert(this.$t1('明细不能为空!'));
156
157
  return false;
157
158
  }
158
159
  this.szTaMb.szTaZdMbDTOs = szTaZdMbDTOs;
@@ -171,7 +172,7 @@ modules = {
171
172
 
172
173
  var url = USER_PREFIX + (this.isEdit ? `/szTaMb/update` : `/szTaMb/save`);
173
174
  this.$http({
174
- aes:true,
175
+ aes: true,
175
176
  url: url,
176
177
  method: `post`,
177
178
  data: formData,
@@ -213,12 +214,13 @@ modules = {
213
214
  columns: [
214
215
  {type: 'checkbox', fixed: 'left', width: 48, resizable: false},
215
216
  {
216
- title: '实体字段名称',
217
+ title: this.$t1('实体字段名称'),
217
218
  field: 'zdEn',
218
219
  width: 150,
219
220
  fixed: 'left',
220
221
  slots: {
221
- default: ({row, rowIndex, $table}) => {
222
+ default: "zdEn"
223
+ /*default: ({row, rowIndex, $table}) => {
222
224
  let disabled = !!row.systems || !!row.relationZd;
223
225
  if (!disabled) {
224
226
  return [
@@ -233,12 +235,12 @@ modules = {
233
235
  <div style={style}>{row.zdEn}</div>
234
236
  ]
235
237
  }
236
- }
238
+ }*/
237
239
  }
238
240
  },
239
- {title: '数据库表字段名', field: 'taZdMc', width: 150, fixed: 'left',},
241
+ {title: this.$t1('数据库表字段名'), field: 'taZdMc', width: 150, fixed: 'left',},
240
242
  {
241
- title: '数据库表字段是否已创建',
243
+ title: this.$t1('数据库表字段是否已创建'),
242
244
  field: 'isFieldCreated',
243
245
  width: 200,
244
246
  slots: {
@@ -250,69 +252,40 @@ modules = {
250
252
  }
251
253
  },
252
254
  {
253
- title: '字段描述',
255
+ title: this.$t1('字段描述'),
254
256
  field: 'zdCh',
255
257
  width: 150,
256
258
  slots: {
257
- default: ({row, rowIndex, $table}) => {
259
+ default: 'zdCh'
260
+ /*default: ({row, rowIndex, $table}) => {
258
261
  return [
259
262
  <el-form-item prop={'szTaZdMbDTOs.' + rowIndex + '.zdCh'}
260
263
  rules={[{required: true, trigger: ['blur', 'change']}]}>
261
264
  <el-input v-model={row.zdCh} clearable disabled={!!row.systems}/>
262
265
  </el-form-item>
263
266
  ];
264
- }
267
+ }*/
265
268
  }
266
269
  },
267
270
  {
268
- title: '字段类型', field: 'zdType', width: 150,
271
+ title: this.$t1('字段类型'), field: 'zdType', width: 150,
269
272
  slots: {
270
273
  default: 'zdType'
271
274
  }
272
275
  },
273
276
  {
274
- title: '关联字段', field: 'referenceZd', width: 250,
277
+ title: this.$t1('关联字段'), field: 'referenceZd', width: 250,
275
278
  slots: {
276
279
  default: 'referenceZd'
277
280
  }
278
281
  },
279
- // {
280
- // title: '对应表名',
281
- // field: 'dybm',
282
- // width: 150,
283
- // slots: {
284
- // default: ({row, rowIndex, $table}) => {
285
- // return [
286
- // <el-form-item prop={'szTaZdMbDTOs.' + rowIndex + '.dybm'}
287
- // rules={[{required: row.taType=='Reference', trigger: ['blur', 'change']}]}>
288
- //
289
- // <el-input v-show={row.taType=='Reference'}
290
- // class="search-input"
291
- // max="200"
292
- // v-model={row.dybm}
293
- // onclear={() => {
294
- // row.dybm = '';
295
- // this.$forceUpdate();
296
- // }}
297
- // v-el-readonly
298
- // clearable
299
- // >
300
- // <i v-show={this.szTaMb.id==null} slot="suffix" class="el-input__icon el-icon-search" onClick={() => {
301
- // this.zdEnIndex = rowIndex;
302
- // this.showItemSzTaMbDialog = true;
303
- // }} />
304
- // </el-input>
305
- // </el-form-item>
306
- // ];
307
- // }
308
- // }
309
- // },
310
282
  {
311
- title: '字段类型对应的默认值',
283
+ title: this.$t1('字段类型对应的默认值'),
312
284
  field: 'zdTypeValues',
313
285
  width: 150,
314
286
  slots: {
315
- default: ({row, rowIndex, $table}) => {
287
+ default: 'zdTypeValues'
288
+ /*default: ({row, rowIndex, $table}) => {
316
289
  let disabled = !!row.systems || !!row.relationZd;
317
290
  return [
318
291
  <el-form-item prop={'szTaZdMbDTOs.' + rowIndex + '.zdTypeValues'}
@@ -320,20 +293,21 @@ modules = {
320
293
  <el-input v-model={row.zdTypeValues} clearable disabled={disabled}/>
321
294
  </el-form-item>
322
295
  ];
323
- }
296
+ }*/
324
297
  }
325
298
  },
326
299
  {
327
- title: '是否必填项',
300
+ title: this.$t1('是否必填项'),
328
301
  field: 'required',
329
302
  width: 140,
330
303
  slots: {
331
- default: ({row, $table, rowIndex}) => {
304
+ default: "required"
305
+ /*default: ({row, $table, rowIndex}) => {
332
306
  let disabled = !!row.systems || !!row.relationZd;
333
307
  return [
334
308
  <el-checkbox v-model={row.required} disabled={disabled}/>
335
309
  ];
336
- }
310
+ }*/
337
311
  }
338
312
  },
339
313
  {
@@ -341,34 +315,37 @@ modules = {
341
315
  field: 'enabled',
342
316
  width: 120,
343
317
  slots: {
344
- default: ({row, $table, rowIndex}) => {
318
+ default: "enabled"
319
+ /*default: ({row, $table, rowIndex}) => {
345
320
  let disabled = !!row.systems || !!row.relationZd;
346
321
  return [
347
322
  <el-checkbox v-model={row.enabled} disabled={disabled}/>
348
323
  ];
349
- }
324
+ }*/
350
325
  }
351
326
  },
352
327
 
353
328
  {
354
- title: '是否自动生成编码',
329
+ title: this.$t1('是否自动生成编码'),
355
330
  field: 'generateCode',
356
331
  width: 180,
357
332
  slots: {
358
- default: ({row, $table, rowIndex}) => {
333
+ default:"generateCode"
334
+ /*default: ({row, $table, rowIndex}) => {
359
335
  let disabled = !!row.systems || !!row.relationZd;
360
336
  return [
361
337
  <el-checkbox v-model={row.generateCode} disabled={disabled}/>
362
338
  ];
363
- }
339
+ }*/
364
340
  }
365
341
  },
366
342
  {
367
- title: '编码类型',
343
+ title: this.$t1('编码类型'),
368
344
  field: 'codeType',
369
345
  width: 150,
370
346
  slots: {
371
- default: ({row, rowIndex, $table}) => {
347
+ default: "codeType"
348
+ /*default: ({row, rowIndex, $table}) => {
372
349
  let disabled = !!row.systems || !!row.relationZd;
373
350
  return [
374
351
  <el-form-item prop={'szTaZdMbDTOs.' + rowIndex + '.codeType'}
@@ -376,7 +353,7 @@ modules = {
376
353
  <el-input v-model={row.codeType} clearable disabled={disabled}/>
377
354
  </el-form-item>
378
355
  ];
379
- }
356
+ }*/
380
357
  }
381
358
  },
382
359
  {
@@ -384,7 +361,8 @@ modules = {
384
361
  field: 'orders',
385
362
  width: 150,
386
363
  slots: {
387
- default: ({row, rowIndex, $table}) => {
364
+ default: "orders"
365
+ /*default: ({row, rowIndex, $table}) => {
388
366
  return [
389
367
  <el-form-item prop={'szTaZdMbDTOs.' + rowIndex + '.orders'}
390
368
  rules={[{required: false, trigger: ['blur', 'change']}]}>
@@ -393,7 +371,7 @@ modules = {
393
371
  }}/>
394
372
  </el-form-item>
395
373
  ];
396
- }
374
+ }*/
397
375
  }
398
376
  },
399
377
  {
@@ -409,21 +387,13 @@ modules = {
409
387
  // let style = !row.relationZd ? "margin-left:20px" : "";
410
388
  if (!row.systems && !hasCreated && !row.relationZd) {
411
389
  //非内置,未创建字段,非关联表带出来的字段
412
- return [
413
- <a
414
- href="javascript:void(0);"
415
- class="a-link"
416
- onclick={() => {
417
- // this.szTaMb.szTaZdMbDTOs.splice(rowIndex, 1);
418
- this.deleteItem(row, rowIndex);
419
- }}
420
- >
421
- <el-tooltip enterable={false} effect="dark" content="删除" placement="top"
422
- popper-class="tooltip-skin">
423
- <i class="el-icon-delete"/>
424
- </el-tooltip>
425
- </a>
426
- ];
390
+ return getJsxBtn({
391
+ iconName: "el-icon-delete",
392
+ content: this.$t1('删除'),
393
+ onclick: () => {
394
+ this.deleteItem(row, rowIndex);
395
+ }
396
+ });
427
397
  }
428
398
  }
429
399
  }
@@ -435,7 +405,7 @@ modules = {
435
405
  });
436
406
  if (this.dataId) {
437
407
  this.$http({
438
- aes:true,
408
+ aes: true,
439
409
  url: USER_PREFIX + `/szTaMb/getSzTaZdMbs`,
440
410
  method: `post`,
441
411
  data: {
@@ -493,7 +463,7 @@ modules = {
493
463
  this.getData((res0) => {
494
464
  let szTaMb = res0.objx;
495
465
  this.$http({
496
- aes:true,
466
+ aes: true,
497
467
  url: USER_PREFIX + `/szTaMb/getSzTaZdMbs`,
498
468
  method: `post`,
499
469
  data: {
@@ -509,11 +479,11 @@ modules = {
509
479
  });
510
480
  },
511
481
  createModifyTable() {
512
- let text = '您确定要创建/更新数据表吗?';
482
+ let text = this.$t1('您确定要创建/更新数据表吗?');
513
483
  this.$baseConfirm(text).then(() => {
514
484
  this.getNewData((data) => {
515
485
  this.$http({
516
- aes:true,
486
+ aes: true,
517
487
  url: "/" + this.szTaMb.serviceName + `/dbTable/createUpdateTable`,
518
488
  method: `post`,
519
489
  data: data,
@@ -690,7 +660,7 @@ modules = {
690
660
  getCreatedTableColumns() {
691
661
  if (!this.szTaMb.taBm) return;
692
662
  this.$http({
693
- aes:true,
663
+ aes: true,
694
664
  url: "/" + this.szTaMb.serviceName + "/dbTable/getTableColumns",
695
665
  method: `post`,
696
666
  data: {
@@ -709,7 +679,7 @@ modules = {
709
679
  },
710
680
  getTreeDefaultZds() {
711
681
  this.$http({
712
- aes:true,
682
+ aes: true,
713
683
  url: USER_PREFIX + `/szTaMb/getTreeDefaultZds`,
714
684
  method: `post`,
715
685
  data: {},
@@ -7,6 +7,7 @@ import MenuKindDialog from "@base/views/bd/setting/menu_kind/dialog.vue";
7
7
  import projectTagDialog from "@base/views/user/project_tag/dialog.vue";
8
8
  import {treeScollx} from "@base/utils/global";
9
9
  import {getBdFlag} from "@base/api/user";
10
+ import {getJsxBtn} from "@base/views/bd/setting/utils";
10
11
 
11
12
  let modules = {};
12
13
  modules = {
@@ -140,36 +141,36 @@ modules = {
140
141
  },
141
142
  columns: [
142
143
  {type: 'checkbox', width: 48, resizable: false, fixed: 'left'},
143
- {title: '实体名称', field: 'taEn', width: 150, fixed: 'left'},
144
- {title: '数据库表名', field: 'taBm', width: 150},
145
- {title: '表描述', field: 'taCh', width: 150},
144
+ {title: this.$t1('实体名称'), field: 'taEn', width: 150, fixed: 'left'},
145
+ {title: this.$t1('数据库表名'), field: 'taBm', width: 150},
146
+ {title: this.$t1('表描述'), field: 'taCh', width: 150},
146
147
  {
147
- title: '表类型', field: 'taType', width: 150,
148
+ title: this.$t1('表类型'), field: 'taType', width: 150,
148
149
  slots: {
149
150
  default: ({row}) => {
150
- return row.taType == 0 ? '主表' : '明细表'
151
+ return row.taType == 0 ? this.$t1('主表') : this.$t1('明细表')
151
152
  }
152
153
  }
153
154
  },
154
155
  {
155
- title: '是否树结构', field: 'taRule', width: 150,
156
+ title: this.$t1('是否树结构'), field: 'taRule', width: 150,
156
157
  slots: {
157
158
  default: ({row}) => {
158
- return row.taRule == 1 ? '是' : '否'
159
+ return row.taRule == 1 ? this.$t1('是') : this.$t1('否')
159
160
  }
160
161
  }
161
162
  },
162
163
  {
163
- title: '数据范围', field: 'dataRange', width: 150,
164
+ title: this.$t1('数据范围'), field: 'dataRange', width: 150,
164
165
  slots: {
165
166
  default: ({row}) => {
166
- return row.dataRange == 1 ? '集团' : '当前企业'
167
+ return row.dataRange == 1 ? this.$t1('集团') : this.$t1('当前企业')
167
168
  }
168
169
  }
169
170
  },
170
- {title: '表单分类', field: 'menuKindName', width: 150},
171
+ {title: this.$t1('表单分类'), field: 'menuKindName', width: 150},
171
172
  {
172
- title: '项目标签', field: 'tag', width: 250, slots: {default: "tag"}, params: {
173
+ title: this.$t1('项目标签'), field: 'tag', width: 250, slots: {default: "tag"}, params: {
173
174
  exportVal: ({row}) => {
174
175
  if (row.szTaMbTagDTOs) {
175
176
  return row.szTaMbTagDTOs.map(item => item.tagName).join(",")
@@ -177,7 +178,7 @@ modules = {
177
178
  }
178
179
  }
179
180
  },
180
- {title: '表编码', field: 'taCode', width: 150},
181
+ {title: this.$t1('表编码'), field: 'taCode', width: 150},
181
182
  {title: this.$t1('创建人'), field: 'createBy', width: 150},
182
183
  {title: this.$t1('创建时间'), field: 'createDate', width: 150},
183
184
  {title: this.$t1('更新人'), field: 'modifyBy', width: 150},
@@ -189,53 +190,20 @@ modules = {
189
190
  sortable: false,
190
191
  slots: {
191
192
  default: ({row}) => {
192
- return [
193
- <div>
194
- <a
195
- href="javascript:void(0);"
196
- class="a-link"
197
- onclick={() => {
198
- this.openEditDialog(row);
199
- }}
200
- >
201
- <el-tooltip enterable={false} effect="dark" content={ this.$t1('查看') } placement="top"
202
- popper-class="tooltip-skin">
203
- <i class="el-icon-edit"/>
204
- </el-tooltip>
205
- </a>
206
- <a
207
- href="javascript:void(0);"
208
- onClick={() => {
209
- this.openDesingerDialog(row);
210
- }}
211
- className="a-link"
212
- >
213
- <el-tooltip enterable={false} effect="dark" content="表单设计" placement="top"
214
- popper-class="tooltip-skin">
215
- <i className="iconfont icon-liuchengguanli-shejiqi_liucheng"/>
216
- </el-tooltip>
217
- </a>
218
- <a
219
- href="javascript:void(0);"
220
- className="a-link"
221
- onClick={() => {
222
- this.openTmHistoryDialog(row);
223
- }}
224
- >
225
- <el-tooltip enterable={false} effect="dark" content="历史" placement="top"
226
- popper-class="tooltip-skin">
227
- <i className="el-icon-s-order"/>
228
- </el-tooltip>
229
- </a>
230
- </div>
231
- ];
193
+ return getJsxBtn({
194
+ iconName: "el-icon-edit",
195
+ content: this.$t1('查看'),
196
+ onclick: () => {
197
+ this.openEditDialog(row);
198
+ }
199
+ });
232
200
  }
233
201
  }
234
202
  }
235
203
  ],
236
204
  searchColumns: [
237
205
  {
238
- title: "表单分类",
206
+ title: this.$t1('表单分类'),
239
207
  field: "menuKindName",
240
208
  type: "input",
241
209
  common: true,
@@ -243,10 +211,10 @@ modules = {
243
211
  defaultValueEnabled: false,
244
212
  slot: "menuKindName"
245
213
  },
246
- {title: "实体名称", field: "taEn", type: "input", common: true},
247
- {title: "数据库表名", field: "taBm", type: "input", common: true},
248
- {title: "表描述", field: "taCh", type: "input", common: true},
249
- {title: "项目标签", field: "tag", type: "input", common: true, slot: "tag"},
214
+ {title: this.$t1('实体名称'), field: "taEn", type: "input", common: true},
215
+ {title: this.$t1('数据库表名'), field: "taBm", type: "input", common: true},
216
+ {title: this.$t1('表描述'), field: "taCh", type: "input", common: true},
217
+ {title: this.$t1('项目标签'), field: "tag", type: "input", common: true, slot: "tag"},
250
218
  ],
251
219
  config: {
252
220
  proxyConfig: {
@@ -269,7 +237,7 @@ modules = {
269
237
  let param = {enabled: true};
270
238
  let url = !id ? USER_PREFIX + '/menuKind/getAllList' : USER_PREFIX + '/menuKind/getChildren';
271
239
  this.$http({
272
- aes:true,
240
+ aes: true,
273
241
  url: url,
274
242
  method: 'post',
275
243
  data: {
@@ -28,17 +28,15 @@ modules = {
28
28
  let that = this;
29
29
 
30
30
  let zdTypeMap = {
31
- Boolean: "布尔",
32
- Integer: "整数",
33
- Decimal: "精度小数",
34
- Money: "金额",
35
- Text: "文本",
36
- TextArea: "长文本",
37
- Option: "单选项",
38
- AreaSelect: "地区选择",
39
- DateTime: "日期时间",
40
- File: "文件",
41
- Reference: "关联表"
31
+ Boolean: this.$t1('布尔'),
32
+ Integer: this.$t1('整数'),
33
+ Long: this.$t1('长整数'),
34
+ Decimal: this.$t1('精度小数'),
35
+ Money: this.$t1('金额'),
36
+ Text: this.$t1('文本'),
37
+ TextArea: this.$t1('长文本'),
38
+ DateTime: this.$t1('日期时间'),
39
+ Reference: this.$t1('关联表')
42
40
  }
43
41
 
44
42
  let tableOption = {
@@ -58,29 +56,29 @@ modules = {
58
56
  columns: [
59
57
  {type: 'checkbox', width: 48, resizable: false, fixed: 'left'},
60
58
  {
61
- title: '实体字段名称',
59
+ title: this.$t1('实体字段名称'),
62
60
  field: 'zdEn',
63
61
  width: 150
64
62
  },
65
63
  {
66
- title: '数据库表字段名',
64
+ title: this.$t1('数据库表字段名'),
67
65
  field: 'taZdMc',
68
66
  width: 150
69
67
  },
70
68
  {
71
- title: '字段描述',
69
+ title: this.$t1('字段描述'),
72
70
  field: 'zdCh',
73
71
  width: 150
74
72
  },
75
73
  {
76
- title: '字段类型', field: 'zdType', width: 150, slots: {
74
+ title: this.$t1('字段类型'), field: 'zdType', width: 150, slots: {
77
75
  default: ({row, rowIndex, $table}) => {
78
76
  return zdTypeMap[row.zdType];
79
77
  }
80
78
  }
81
79
  },
82
80
  {
83
- title: '关联字段',
81
+ title: this.$t1('关联字段'),
84
82
  field: 'referenceZd',
85
83
  width: 150
86
84
  },
@@ -1,6 +1,6 @@
1
1
  <template>
2
2
  <el-dialog
3
- title="实体字段列表"
3
+ :title="$t1('实体字段列表')"
4
4
  :append-to-body="true"
5
5
  :modal-append-to-body="true"
6
6
  :close-on-click-modal="falseValue"
@@ -27,25 +27,27 @@
27
27
  <div class="clearfix screen-btns">
28
28
  <div class="fr">
29
29
  <vxe-button icon="el-icon-brush" class="button-sty" @click="resetEvent" type="text" status="primary"
30
- plain>{{$t1('重置')}}
30
+ plain>{{ $t1('重置') }}
31
31
  </vxe-button>
32
- <vxe-button status="warning" icon="el-icon-search" class="button-sty" @click="searchEvent">{{ $t1('搜索') }}
32
+ <vxe-button status="warning" icon="el-icon-search" class="button-sty" @click="searchEvent">{{
33
+ $t1('搜索')
34
+ }}
33
35
  </vxe-button>
34
36
  </div>
35
37
  </div>
36
38
  <vxe-form class="screen-box" title-width="92px" title-align="right" :data="formData" @submit="searchEvent"
37
39
  @reset="resetEvent">
38
- <vxe-form-item title="表名称:" field="taEn">
40
+ <vxe-form-item :title="$t1('表名称') + ':'" field="taEn">
39
41
  <template v-slot>
40
42
  <el-input v-model="formData.taEn" size="small" clearable></el-input>
41
43
  </template>
42
44
  </vxe-form-item>
43
- <vxe-form-item title="数据库表名:" field="taBm">
45
+ <vxe-form-item :title="$t1('数据库表名') + ':'" field="taBm">
44
46
  <template v-slot>
45
47
  <el-input v-model="formData.taBm" size="small" clearable></el-input>
46
48
  </template>
47
49
  </vxe-form-item>
48
- <vxe-form-item title="表描述:" field="taCh">
50
+ <vxe-form-item :title="$t1('表描述') + ':'" field="taCh">
49
51
  <template v-slot>
50
52
  <el-input v-model="formData.taCh" size="small" clearable></el-input>
51
53
  </template>
@@ -0,0 +1,60 @@
1
+ export function getJsxStatus(className, content) {
2
+ let statusClass = "txt-status";
3
+ if (className) statusClass = statusClass + ' ' + className;
4
+ let h = window.$vueRoot.$createElement;
5
+ let node = h('div', {staticClass: statusClass}, content)
6
+ return [node];
7
+ }
8
+
9
+ export function getJsxBtn({iconName, content, showContent,show, onclick}) {
10
+ if(show===false){
11
+ return [];
12
+ }
13
+ let h = window.$vueRoot.$createElement;
14
+ let contentNodes = [h("i", {staticClass: iconName})]
15
+ if (showContent) {
16
+ contentNodes.push(h('span', {}, content));
17
+ }
18
+ return [h("a", {
19
+ staticClass: "a-link",
20
+ on: {
21
+ click: (event) => {
22
+ onclick && onclick(event);
23
+ }
24
+ }
25
+ }, [
26
+ h("el-tooltip", {
27
+ attrs: {
28
+ enterable: false,
29
+ effect: "dark",
30
+ content: content,
31
+ placement: "top",
32
+ "popper-class": "tooltip-skin"
33
+ }
34
+ }, [
35
+ h("div", {}, contentNodes)
36
+ ])
37
+ ])]
38
+ }
39
+
40
+ export function getJsxLink({content, onclick}) {
41
+ let h = window.$vueRoot.$createElement;
42
+ return [h("a", {
43
+ on: {
44
+ click: (event) => {
45
+ onclick && onclick(event);
46
+ }
47
+ }
48
+ }, content)]
49
+ }
50
+
51
+ export function getJsxBtnList(list) {
52
+ let arr = [];
53
+ list.forEach(item => {
54
+ arr.push(...getJsxBtn(item));
55
+ })
56
+ let h = window.$vueRoot.$createElement;
57
+ return [
58
+ h('div', {}, arr)
59
+ ];
60
+ }