cloud-web-corejs 1.1.0-dev.21 → 1.1.0-dev.23
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 +1 -1
- package/src/components/bizTab/BizTabListPage.vue +66 -33
- package/src/components/bizTab/README.md +3 -1
- package/src/components/excelExport/conditionExportConfig.js +112 -0
- package/src/components/excelExport/exportType.js +8 -0
- package/src/components/excelExport/index.vue +7 -1
- package/src/components/excelExport/mixins.js +410 -259
- package/src/components/mobile/wf/content.vue +27 -3
- package/src/components/table/index.js +5 -2
- package/src/components/table/plugins/cell-area/index.js +10 -3
- package/src/components/wf/wfStartDialog.vue +1 -0
- package/src/components/wf/wfUtil.js +47 -29
- package/src/components/wf/wfVisibility.js +6 -0
- package/src/components/xform/form-designer/form-widget/container-widget/data-table-mixin.js +7 -0
- package/src/components/xform/form-designer/form-widget/container-widget/data-table-widget.vue +3 -1
- package/src/components/xform/form-designer/form-widget/field-widget/fieldMixin.js +25 -1
- package/src/components/xform/form-designer/form-widget/field-widget/select-export-item-button-widget.vue +2 -1
- package/src/components/xform/form-designer/form-widget/field-widget/table-export-button-widget.vue +2 -1
- package/src/components/xform/form-designer/setting-panel/form-setting.vue +14 -2
- package/src/components/xform/form-designer/setting-panel/property-editor/container-data-table/data-table-editor.vue +318 -12
- package/src/components/xform/form-designer/setting-panel/property-editor/container-data-table/table-column-dialog.vue +23 -7
- package/src/components/xform/form-designer/setting-panel/property-editor/field-table-export-button/empty-number-input.vue +51 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/field-table-export-button/select-export-item-button-editor.vue +27 -2
- package/src/components/xform/form-designer/setting-panel/property-editor/field-table-export-button/table-export-button-editor.vue +33 -3
- package/src/components/xform/form-designer/widget-panel/widgetsConfig.js +54 -0
- package/src/components/xform/form-render/container-item/data-table-item.vue +8 -6
- package/src/components/xform/form-render/container-item/data-table-mixin.js +587 -25
- package/src/components/xform/form-render/container-item/detail-h5-item.vue +26 -16
- package/src/components/xform/form-render/container-item/detail-item.vue +350 -446
- package/src/components/xform/form-render/fieldControlMixin.js +2 -0
- package/src/components/xform/form-render/indexMixin.js +25 -15
- package/src/components/xform/mixins/businessLock.js +59 -0
- package/src/components/xform/mixins/wfStart.js +103 -0
- package/src/components/xform/mixins/wfVisibility.js +33 -0
- package/src/components/xform/styles/h5.scss +6 -1
- package/src/components/xform/utils/util.js +2 -0
- package/src/views/user/home/index.vue +1 -1
- package/src/views/user/home/net/distributor.vue +1015 -0
- package/src/views/user/home/net/index.vue +61 -0
|
@@ -62,6 +62,9 @@
|
|
|
62
62
|
<el-form-item label="是否查询总页数">
|
|
63
63
|
<el-switch v-model="isQueryAllPage"></el-switch>
|
|
64
64
|
</el-form-item>
|
|
65
|
+
<el-form-item label="是否读取总页数记忆">
|
|
66
|
+
<el-switch v-model="isReadQueryAllPage"></el-switch>
|
|
67
|
+
</el-form-item>
|
|
65
68
|
<el-form-item label="默认每页查询数" class="form-item-label-top">
|
|
66
69
|
<base-input-number
|
|
67
70
|
v-model="optionModel.gridPageSize"
|
|
@@ -308,6 +311,221 @@
|
|
|
308
311
|
<el-form-item :label="i18nt('树表格')">
|
|
309
312
|
<el-switch v-model="optionModel.isTreeTable"></el-switch>
|
|
310
313
|
</el-form-item>
|
|
314
|
+
<el-form-item
|
|
315
|
+
label="详细设置"
|
|
316
|
+
v-if="optionModel.isEditTable || optionModel.isTreeTable"
|
|
317
|
+
>
|
|
318
|
+
<el-button
|
|
319
|
+
type="primary"
|
|
320
|
+
plain
|
|
321
|
+
round
|
|
322
|
+
icon="el-icon-setting"
|
|
323
|
+
@click="openEditTableConfigDialog"
|
|
324
|
+
>维护配置</el-button>
|
|
325
|
+
</el-form-item>
|
|
326
|
+
<el-dialog
|
|
327
|
+
v-if="showEditTableConfigDialog"
|
|
328
|
+
title="编辑表格设置"
|
|
329
|
+
:visible.sync="showEditTableConfigDialog"
|
|
330
|
+
append-to-body
|
|
331
|
+
:close-on-click-modal="false"
|
|
332
|
+
:destroy-on-close="true"
|
|
333
|
+
width="720px"
|
|
334
|
+
custom-class="dialog-style list-dialog fixed-tabs-dialog"
|
|
335
|
+
v-dialog-drag
|
|
336
|
+
v-el-dialog-center
|
|
337
|
+
>
|
|
338
|
+
<el-form
|
|
339
|
+
label-width="150px"
|
|
340
|
+
size="small"
|
|
341
|
+
class="cont fixed-tabs-dialog__content"
|
|
342
|
+
>
|
|
343
|
+
<el-tabs
|
|
344
|
+
v-model="editTableConfigTab"
|
|
345
|
+
class="fixed-tabs-dialog__tabs"
|
|
346
|
+
>
|
|
347
|
+
<el-tab-pane
|
|
348
|
+
v-if="optionModel.isEditTable"
|
|
349
|
+
label="行编辑与保存"
|
|
350
|
+
name="row"
|
|
351
|
+
>
|
|
352
|
+
<el-form-item label="新增行默认值">
|
|
353
|
+
<a
|
|
354
|
+
href="javascript:void(0);"
|
|
355
|
+
class="a-link link-oneLind"
|
|
356
|
+
@click="editEventHandler('editDefaultRow', defaultEventParams)"
|
|
357
|
+
>
|
|
358
|
+
<span>{{ optionModel.editDefaultRow }}</span>
|
|
359
|
+
<i class="el-icon-edit"></i>
|
|
360
|
+
</a>
|
|
361
|
+
</el-form-item>
|
|
362
|
+
<el-form-item label="整行可编辑条件">
|
|
363
|
+
<a
|
|
364
|
+
href="javascript:void(0);"
|
|
365
|
+
class="a-link link-oneLind"
|
|
366
|
+
@click="editEventHandler('rowEditableScript', defaultEventParams.concat('tableParam'))"
|
|
367
|
+
>
|
|
368
|
+
<span>{{ optionModel.rowEditableScript }}</span>
|
|
369
|
+
<i class="el-icon-edit"></i>
|
|
370
|
+
</a>
|
|
371
|
+
</el-form-item>
|
|
372
|
+
<el-form-item label="行新增条件">
|
|
373
|
+
<a
|
|
374
|
+
href="javascript:void(0);"
|
|
375
|
+
class="a-link link-oneLind"
|
|
376
|
+
@click="editEventHandler('rowAddableScript', defaultEventParams.concat('tableParam'))"
|
|
377
|
+
>
|
|
378
|
+
<span>{{ optionModel.rowAddableScript }}</span>
|
|
379
|
+
<i class="el-icon-edit"></i>
|
|
380
|
+
</a>
|
|
381
|
+
</el-form-item>
|
|
382
|
+
<el-form-item label="行删除条件">
|
|
383
|
+
<a
|
|
384
|
+
href="javascript:void(0);"
|
|
385
|
+
class="a-link link-oneLind"
|
|
386
|
+
@click="editEventHandler('rowDeletableScript', defaultEventParams.concat('tableParam'))"
|
|
387
|
+
>
|
|
388
|
+
<span>{{ optionModel.rowDeletableScript }}</span>
|
|
389
|
+
<i class="el-icon-edit"></i>
|
|
390
|
+
</a>
|
|
391
|
+
</el-form-item>
|
|
392
|
+
<el-form-item label="单行保存脚本编码" class="form-item-label-top">
|
|
393
|
+
<el-input v-model="optionModel.rowSaveScriptCode" clearable></el-input>
|
|
394
|
+
</el-form-item>
|
|
395
|
+
<el-form-item label="保存前脚本">
|
|
396
|
+
<a
|
|
397
|
+
href="javascript:void(0);"
|
|
398
|
+
class="a-link link-oneLind"
|
|
399
|
+
@click="editEventHandler('beforeRowSave', defaultEventParams.concat(['rowData', 'tableParam']))"
|
|
400
|
+
>
|
|
401
|
+
<span>{{ optionModel.beforeRowSave }}</span>
|
|
402
|
+
<i class="el-icon-edit"></i>
|
|
403
|
+
</a>
|
|
404
|
+
</el-form-item>
|
|
405
|
+
<el-form-item label="保存后脚本">
|
|
406
|
+
<a
|
|
407
|
+
href="javascript:void(0);"
|
|
408
|
+
class="a-link link-oneLind"
|
|
409
|
+
@click="editEventHandler('afterRowSave', defaultEventParams.concat(['rowData', 'res']))"
|
|
410
|
+
>
|
|
411
|
+
<span>{{ optionModel.afterRowSave }}</span>
|
|
412
|
+
<i class="el-icon-edit"></i>
|
|
413
|
+
</a>
|
|
414
|
+
</el-form-item>
|
|
415
|
+
<el-form-item label="保存失败脚本">
|
|
416
|
+
<a
|
|
417
|
+
href="javascript:void(0);"
|
|
418
|
+
class="a-link link-oneLind"
|
|
419
|
+
@click="editEventHandler('onRowSaveError', defaultEventParams.concat(['error', 'rowData']))"
|
|
420
|
+
>
|
|
421
|
+
<span>{{ optionModel.onRowSaveError }}</span>
|
|
422
|
+
<i class="el-icon-edit"></i>
|
|
423
|
+
</a>
|
|
424
|
+
</el-form-item>
|
|
425
|
+
</el-tab-pane>
|
|
426
|
+
<el-tab-pane
|
|
427
|
+
v-if="optionModel.isEditTable"
|
|
428
|
+
label="复制粘贴与自动保存"
|
|
429
|
+
name="clipboard"
|
|
430
|
+
>
|
|
431
|
+
<el-form-item label="启用复制粘贴">
|
|
432
|
+
<el-switch v-model="optionModel.clipboardEnabled"></el-switch>
|
|
433
|
+
</el-form-item>
|
|
434
|
+
<el-form-item
|
|
435
|
+
:label="optionModel.isTreeTable ? '粘贴时自动新增一级节点' : '粘贴时自动新增行'"
|
|
436
|
+
v-if="optionModel.clipboardEnabled"
|
|
437
|
+
>
|
|
438
|
+
<el-switch v-model="optionModel.clipboardRowIncrementEnabled"></el-switch>
|
|
439
|
+
</el-form-item>
|
|
440
|
+
<el-form-item v-if="optionModel.clipboardEnabled">
|
|
441
|
+
<span slot="label">
|
|
442
|
+
支持附件粘贴
|
|
443
|
+
<el-tooltip effect="light" placement="top">
|
|
444
|
+
<div slot="content" class="field-tip-content">
|
|
445
|
+
选中附件单元格后,可粘贴截图或从文件管理器复制的文件。<br />
|
|
446
|
+
仅对附件类型的可编辑列生效。
|
|
447
|
+
</div>
|
|
448
|
+
<i class="el-icon-info label-tip-icon"></i>
|
|
449
|
+
</el-tooltip>
|
|
450
|
+
</span>
|
|
451
|
+
<el-switch v-model="optionModel.clipboardAttachmentEnabled"></el-switch>
|
|
452
|
+
</el-form-item>
|
|
453
|
+
<el-form-item label="复制粘贴排除字段" v-if="optionModel.clipboardEnabled">
|
|
454
|
+
<el-select
|
|
455
|
+
v-model="optionModel.clipboardExcludeFields"
|
|
456
|
+
multiple
|
|
457
|
+
filterable
|
|
458
|
+
allow-create
|
|
459
|
+
default-first-option
|
|
460
|
+
style="width: 100%"
|
|
461
|
+
></el-select>
|
|
462
|
+
</el-form-item>
|
|
463
|
+
<el-form-item label="非法粘贴值处理" v-if="optionModel.clipboardEnabled">
|
|
464
|
+
<el-select v-model="optionModel.clipboardInvalidValueStrategy" style="width: 100%">
|
|
465
|
+
<el-option label="跳过" value="ignore"></el-option>
|
|
466
|
+
<el-option label="跳过并提示" value="warn"></el-option>
|
|
467
|
+
</el-select>
|
|
468
|
+
</el-form-item>
|
|
469
|
+
<el-form-item>
|
|
470
|
+
<span slot="label">
|
|
471
|
+
启用自动保存
|
|
472
|
+
<el-tooltip effect="light" placement="top">
|
|
473
|
+
<div slot="content" class="field-tip-content">
|
|
474
|
+
行内输入组件失去焦点或粘贴完成后,自动执行单行保存。<br />
|
|
475
|
+
附件列会等待文件上传完成后再保存。
|
|
476
|
+
</div>
|
|
477
|
+
<i class="el-icon-info label-tip-icon"></i>
|
|
478
|
+
</el-tooltip>
|
|
479
|
+
</span>
|
|
480
|
+
<el-switch v-model="optionModel.autoSaveEnabled"></el-switch>
|
|
481
|
+
</el-form-item>
|
|
482
|
+
<el-form-item label="自动保存触发方式" v-if="optionModel.autoSaveEnabled">
|
|
483
|
+
<el-checkbox-group v-model="optionModel.autoSaveTrigger">
|
|
484
|
+
<el-checkbox label="blur">失焦</el-checkbox>
|
|
485
|
+
<el-checkbox label="change">值变化</el-checkbox>
|
|
486
|
+
<el-checkbox label="paste">粘贴</el-checkbox>
|
|
487
|
+
</el-checkbox-group>
|
|
488
|
+
</el-form-item>
|
|
489
|
+
<el-form-item label="自动保存延迟(ms)" v-if="optionModel.autoSaveEnabled">
|
|
490
|
+
<base-input-number
|
|
491
|
+
v-model="optionModel.autoSaveDelay"
|
|
492
|
+
:min="0"
|
|
493
|
+
:max="5000"
|
|
494
|
+
style="width: 100%"
|
|
495
|
+
/>
|
|
496
|
+
</el-form-item>
|
|
497
|
+
</el-tab-pane>
|
|
498
|
+
<el-tab-pane
|
|
499
|
+
v-if="optionModel.isTreeTable"
|
|
500
|
+
label="树结构"
|
|
501
|
+
name="tree"
|
|
502
|
+
>
|
|
503
|
+
<el-form-item label="节点键字段"><el-input v-model="optionModel.treeConfig.rowField" /></el-form-item>
|
|
504
|
+
<el-form-item label="父节点字段"><el-input v-model="optionModel.treeConfig.parentField" /></el-form-item>
|
|
505
|
+
<el-form-item label="子节点字段"><el-input v-model="optionModel.treeConfig.children" /></el-form-item>
|
|
506
|
+
<el-form-item label="映射子节点字段"><el-input v-model="optionModel.treeConfig.mapChildren" /></el-form-item>
|
|
507
|
+
<el-form-item label="有子节点标识字段"><el-input v-model="optionModel.treeConfig.hasChild" /></el-form-item>
|
|
508
|
+
<el-form-item label="默认展开全部"><el-switch v-model="optionModel.treeConfig.expandAll" /></el-form-item>
|
|
509
|
+
<el-form-item label="懒加载"><el-switch v-model="optionModel.treeConfig.lazy" /></el-form-item>
|
|
510
|
+
<el-form-item label="物理主键字段"><el-input v-model="optionModel.treeIdentityConfig.physicalIdField" /></el-form-item>
|
|
511
|
+
<el-form-item label="根节点父值"><el-input v-model="optionModel.treeIdentityConfig.rootParentValue" /></el-form-item>
|
|
512
|
+
<el-form-item label="粘贴补行位置">
|
|
513
|
+
<el-select v-model="optionModel.treePasteInsertMode" style="width: 100%">
|
|
514
|
+
<el-option label="新增一级节点" value="root" />
|
|
515
|
+
<el-option label="新增同级节点" value="sibling" />
|
|
516
|
+
</el-select>
|
|
517
|
+
</el-form-item>
|
|
518
|
+
</el-tab-pane>
|
|
519
|
+
</el-tabs>
|
|
520
|
+
</el-form>
|
|
521
|
+
<span slot="footer" class="dialog-footer">
|
|
522
|
+
<el-button
|
|
523
|
+
type="primary"
|
|
524
|
+
icon="el-icon-check"
|
|
525
|
+
@click="showEditTableConfigDialog = false"
|
|
526
|
+
>完成</el-button>
|
|
527
|
+
</span>
|
|
528
|
+
</el-dialog>
|
|
311
529
|
<el-form-item :label="i18nt('启用WBS码')">
|
|
312
530
|
<el-switch v-model="optionModel.wbsEnabled"></el-switch>
|
|
313
531
|
</el-form-item>
|
|
@@ -722,7 +940,94 @@ export default {
|
|
|
722
940
|
tableConfigParams: ["dataId", "formCode"],
|
|
723
941
|
defaultEventParams: ["dataId", "formCode"],
|
|
724
942
|
showExportItemColumnsDialog: false,
|
|
943
|
+
showEditTableConfigDialog: false,
|
|
944
|
+
editTableConfigTab: "row",
|
|
945
|
+
};
|
|
946
|
+
},
|
|
947
|
+
created() {
|
|
948
|
+
const defaults = {
|
|
949
|
+
mergeRowEnabled: false,
|
|
950
|
+
mergeRowKey: null,
|
|
951
|
+
showGridFooter: false,
|
|
952
|
+
editDefaultRow: null,
|
|
953
|
+
rowEditableScript: null,
|
|
954
|
+
rowAddableScript: null,
|
|
955
|
+
rowDeletableScript: null,
|
|
956
|
+
rowSaveScriptCode: null,
|
|
957
|
+
beforeRowSave: null,
|
|
958
|
+
afterRowSave: null,
|
|
959
|
+
onRowSaveError: null,
|
|
960
|
+
clipboardEnabled: false,
|
|
961
|
+
clipboardRowIncrementEnabled: false,
|
|
962
|
+
clipboardAttachmentEnabled: false,
|
|
963
|
+
clipboardExcludeFields: [],
|
|
964
|
+
clipboardInvalidValueStrategy: "ignore",
|
|
965
|
+
clipboardAutoSaveEnabled: false,
|
|
966
|
+
autoSaveTrigger: ["blur", "change", "paste"],
|
|
967
|
+
autoSaveDelay: 200,
|
|
968
|
+
treePasteInsertMode: "root",
|
|
969
|
+
};
|
|
970
|
+
Object.keys(defaults).forEach((key) => {
|
|
971
|
+
if (!Object.prototype.hasOwnProperty.call(this.optionModel, key)) {
|
|
972
|
+
this.$set(this.optionModel, key, defaults[key]);
|
|
973
|
+
}
|
|
974
|
+
});
|
|
975
|
+
if (!Object.prototype.hasOwnProperty.call(this.optionModel, "autoSaveEnabled")) {
|
|
976
|
+
this.$set(
|
|
977
|
+
this.optionModel,
|
|
978
|
+
"autoSaveEnabled",
|
|
979
|
+
!!this.optionModel.clipboardAutoSaveEnabled
|
|
980
|
+
);
|
|
981
|
+
}
|
|
982
|
+
const nestedDefaults = {
|
|
983
|
+
treeConfig: {
|
|
984
|
+
rowField: "id",
|
|
985
|
+
parentField: "f_parent",
|
|
986
|
+
children: "f_children",
|
|
987
|
+
mapChildren: "_X_ROW_CHILD",
|
|
988
|
+
hasChild: "f_has_child",
|
|
989
|
+
lazy: false,
|
|
990
|
+
expandAll: true,
|
|
991
|
+
reserve: true,
|
|
992
|
+
},
|
|
993
|
+
treeIdentityConfig: {
|
|
994
|
+
physicalIdField: "id",
|
|
995
|
+
rootParentValue: 0,
|
|
996
|
+
serverGeneratesRowField: true,
|
|
997
|
+
persistedRowFieldChangeStrategy: "reject",
|
|
998
|
+
},
|
|
999
|
+
treeCopyConfig: {
|
|
1000
|
+
rowFieldStrategy: "regenerate",
|
|
1001
|
+
orphanParentStrategy: "detach",
|
|
1002
|
+
lazyStrategy: "reject",
|
|
1003
|
+
},
|
|
1004
|
+
treeSubmitConfig: {
|
|
1005
|
+
orphanParentStrategy: "preserve",
|
|
1006
|
+
unloadedChildrenStrategy: "reject",
|
|
1007
|
+
successReconcileStrategy: "reload",
|
|
1008
|
+
},
|
|
725
1009
|
};
|
|
1010
|
+
Object.keys(nestedDefaults).forEach((key) => {
|
|
1011
|
+
const current = this.optionModel[key];
|
|
1012
|
+
if (!current || typeof current !== "object") {
|
|
1013
|
+
this.$set(this.optionModel, key, { ...nestedDefaults[key] });
|
|
1014
|
+
return;
|
|
1015
|
+
}
|
|
1016
|
+
Object.keys(nestedDefaults[key]).forEach((childKey) => {
|
|
1017
|
+
if (!Object.prototype.hasOwnProperty.call(current, childKey)) {
|
|
1018
|
+
this.$set(current, childKey, nestedDefaults[key][childKey]);
|
|
1019
|
+
}
|
|
1020
|
+
});
|
|
1021
|
+
});
|
|
1022
|
+
var e = this;
|
|
1023
|
+
(this.cssClassList = deepClone(this.designer.getCssClassList())),
|
|
1024
|
+
this.designer.handleEvent("form-css-updated", function (t) {
|
|
1025
|
+
e.cssClassList = t;
|
|
1026
|
+
});
|
|
1027
|
+
if (this.optionModel.showExportBtn == null)
|
|
1028
|
+
this.$set(this.optionModel, "showExportBtn", true);
|
|
1029
|
+
if (this.optionModel.tableConfig === void 0)
|
|
1030
|
+
this.$set(this.optionModel, "tableConfig", "");
|
|
726
1031
|
},
|
|
727
1032
|
computed: {
|
|
728
1033
|
dataSourceList: function () {
|
|
@@ -741,6 +1046,14 @@ export default {
|
|
|
741
1046
|
this.optionModel.isNotQueryAllPage = !val;
|
|
742
1047
|
},
|
|
743
1048
|
},
|
|
1049
|
+
isReadQueryAllPage: {
|
|
1050
|
+
get() {
|
|
1051
|
+
return !this.optionModel.isNotReadQueryAllPage;
|
|
1052
|
+
},
|
|
1053
|
+
set(val) {
|
|
1054
|
+
this.optionModel.isNotReadQueryAllPage = !val;
|
|
1055
|
+
},
|
|
1056
|
+
},
|
|
744
1057
|
isShowQueryButton: {
|
|
745
1058
|
get() {
|
|
746
1059
|
return !this.optionModel.isNotShowQueryButton;
|
|
@@ -753,18 +1066,6 @@ export default {
|
|
|
753
1066
|
return this.optionModel.dynamicSchemaConvert || "";
|
|
754
1067
|
},
|
|
755
1068
|
},
|
|
756
|
-
created: function () {
|
|
757
|
-
// this.reportTemplate = this.getReportTemplate();
|
|
758
|
-
var e = this;
|
|
759
|
-
(this.cssClassList = deepClone(this.designer.getCssClassList())),
|
|
760
|
-
this.designer.handleEvent("form-css-updated", function (t) {
|
|
761
|
-
e.cssClassList = t;
|
|
762
|
-
});
|
|
763
|
-
if (this.optionModel.showExportBtn == null)
|
|
764
|
-
this.$set(this.optionModel, "showExportBtn", true);
|
|
765
|
-
if (this.optionModel.tableConfig === void 0)
|
|
766
|
-
this.$set(this.optionModel, "tableConfig", "");
|
|
767
|
-
},
|
|
768
1069
|
mounted: function () {
|
|
769
1070
|
const preloadColumnDialog = () => {
|
|
770
1071
|
this.columnDialogMounted = true;
|
|
@@ -776,6 +1077,10 @@ export default {
|
|
|
776
1077
|
}
|
|
777
1078
|
},
|
|
778
1079
|
methods: {
|
|
1080
|
+
openEditTableConfigDialog() {
|
|
1081
|
+
this.editTableConfigTab = this.optionModel.isEditTable ? "row" : "tree";
|
|
1082
|
+
this.showEditTableConfigDialog = true;
|
|
1083
|
+
},
|
|
779
1084
|
editDynamicSchemaConvert() {
|
|
780
1085
|
this.editEventHandler("dynamicSchemaConvert", ["res"]);
|
|
781
1086
|
},
|
|
@@ -1104,6 +1409,7 @@ export default {
|
|
|
1104
1409
|
.icon-drag:before {
|
|
1105
1410
|
content: "\e61d";
|
|
1106
1411
|
}
|
|
1412
|
+
|
|
1107
1413
|
</style>
|
|
1108
1414
|
|
|
1109
1415
|
<style scoped>
|
|
@@ -534,7 +534,7 @@
|
|
|
534
534
|
<el-form-item :label="i18nt('designer.setting.visibleColumn')">
|
|
535
535
|
<el-switch v-model="rowData.show"></el-switch>
|
|
536
536
|
</el-form-item>
|
|
537
|
-
<el-form-item label="动态显示脚本">
|
|
537
|
+
<el-form-item label="动态显示脚本">
|
|
538
538
|
<a
|
|
539
539
|
href="javascript:void(0);"
|
|
540
540
|
class="a-link link-oneLind"
|
|
@@ -542,8 +542,21 @@
|
|
|
542
542
|
>
|
|
543
543
|
<span>{{ rowData.columnShow }}</span>
|
|
544
544
|
<i class="el-icon-edit"></i>
|
|
545
|
-
</a>
|
|
546
|
-
</el-form-item>
|
|
545
|
+
</a>
|
|
546
|
+
</el-form-item>
|
|
547
|
+
<el-form-item
|
|
548
|
+
label="单元格可编辑条件"
|
|
549
|
+
v-if="rowData.editFormatS"
|
|
550
|
+
>
|
|
551
|
+
<a
|
|
552
|
+
href="javascript:void(0);"
|
|
553
|
+
class="a-link link-oneLind"
|
|
554
|
+
@click="editFormEventHandler(rowData, rowDataIndex, 'cellEditable')"
|
|
555
|
+
>
|
|
556
|
+
<span>{{ rowData.cellEditable }}</span>
|
|
557
|
+
<i class="el-icon-edit"></i>
|
|
558
|
+
</a>
|
|
559
|
+
</el-form-item>
|
|
547
560
|
<el-form-item :label="i18nt('designer.setting.sortableColumn')">
|
|
548
561
|
<el-switch v-model="rowData.sortable"></el-switch>
|
|
549
562
|
</el-form-item>
|
|
@@ -1021,8 +1034,10 @@ export default {
|
|
|
1021
1034
|
curEventRow: null,
|
|
1022
1035
|
|
|
1023
1036
|
eventParamsMap: {
|
|
1024
|
-
footerMethodConfg: "footerMethodConfg(dataId,formCode,param) {",
|
|
1025
|
-
columnShow: "columnShow(dataId,formCode,columnConfig) {",
|
|
1037
|
+
footerMethodConfg: "footerMethodConfg(dataId,formCode,param) {",
|
|
1038
|
+
columnShow: "columnShow(dataId,formCode,columnConfig) {",
|
|
1039
|
+
cellEditable:
|
|
1040
|
+
"cellEditable(dataId,formCode,tableParam,columnConfig) {",
|
|
1026
1041
|
},
|
|
1027
1042
|
|
|
1028
1043
|
showColumnRenderDialog: false,
|
|
@@ -1388,8 +1403,9 @@ export default {
|
|
|
1388
1403
|
rowAddAuthName: this.createRowAuthName("Add"),
|
|
1389
1404
|
rowEditAuthName: this.createRowAuthName("Edit"),
|
|
1390
1405
|
rowAddShow: null,
|
|
1391
|
-
rowEditShow: null,
|
|
1392
|
-
columnShow: null,
|
|
1406
|
+
rowEditShow: null,
|
|
1407
|
+
columnShow: null,
|
|
1408
|
+
cellEditable: null,
|
|
1393
1409
|
utcTransformEnabled: false,
|
|
1394
1410
|
labelIconClass: null,
|
|
1395
1411
|
labelIconPosition: "rear",
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<base-input-number
|
|
3
|
+
:value="innerValue"
|
|
4
|
+
v-bind="$attrs"
|
|
5
|
+
v-on="listeners"
|
|
6
|
+
@input="onInput"
|
|
7
|
+
/>
|
|
8
|
+
</template>
|
|
9
|
+
|
|
10
|
+
<script>
|
|
11
|
+
/**
|
|
12
|
+
* 未配置(null / undefined / 非正数)时显示空白,而不是 el-input-number 默认的 0。
|
|
13
|
+
* 清空后回写 null,运行时会回落到全局逻辑参数。
|
|
14
|
+
*/
|
|
15
|
+
function toDisplayNumber(value) {
|
|
16
|
+
if (value == null || value === "") return undefined;
|
|
17
|
+
let num = Number(value);
|
|
18
|
+
if (!Number.isFinite(num) || num <= 0) return undefined;
|
|
19
|
+
return num;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
function toStoredNumber(value) {
|
|
23
|
+
if (value == null || value === "") return null;
|
|
24
|
+
let num = Number(value);
|
|
25
|
+
if (!Number.isFinite(num) || num <= 0) return null;
|
|
26
|
+
return num;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export default {
|
|
30
|
+
name: "empty-number-input",
|
|
31
|
+
inheritAttrs: false,
|
|
32
|
+
props: {
|
|
33
|
+
value: {},
|
|
34
|
+
},
|
|
35
|
+
computed: {
|
|
36
|
+
innerValue() {
|
|
37
|
+
return toDisplayNumber(this.value);
|
|
38
|
+
},
|
|
39
|
+
listeners() {
|
|
40
|
+
let listeners = Object.assign({}, this.$listeners);
|
|
41
|
+
delete listeners.input;
|
|
42
|
+
return listeners;
|
|
43
|
+
},
|
|
44
|
+
},
|
|
45
|
+
methods: {
|
|
46
|
+
onInput(val) {
|
|
47
|
+
this.$emit("input", toStoredNumber(val));
|
|
48
|
+
},
|
|
49
|
+
},
|
|
50
|
+
};
|
|
51
|
+
</script>
|
|
@@ -19,10 +19,29 @@
|
|
|
19
19
|
></el-switch>
|
|
20
20
|
</el-form-item>
|
|
21
21
|
<el-form-item label="导出每页查询数量" class="form-item-label-top">
|
|
22
|
-
<
|
|
22
|
+
<empty-number-input
|
|
23
23
|
v-model="optionModel.exportPageSize"
|
|
24
24
|
:max="optionModel.showImageAtTable ? 150 : 1000"
|
|
25
|
-
|
|
25
|
+
:placeholder="'默认 ' + defaultPageSize"
|
|
26
|
+
></empty-number-input>
|
|
27
|
+
</el-form-item>
|
|
28
|
+
<el-form-item label="最大查询总数" class="form-item-label-top">
|
|
29
|
+
<empty-number-input
|
|
30
|
+
v-model="optionModel.maxQueryTotal"
|
|
31
|
+
:placeholder="'默认 ' + defaultMaxQueryTotal"
|
|
32
|
+
></empty-number-input>
|
|
33
|
+
<div class="export-item-columns-tip">
|
|
34
|
+
条件导出最多拉取的行数。留空则使用全局逻辑参数(默认 {{ defaultMaxQueryTotal }})
|
|
35
|
+
</div>
|
|
36
|
+
</el-form-item>
|
|
37
|
+
<el-form-item label="每个文件最大数据量" class="form-item-label-top">
|
|
38
|
+
<empty-number-input
|
|
39
|
+
v-model="optionModel.limitFileSize"
|
|
40
|
+
:placeholder="'默认 ' + defaultLimitFileSize"
|
|
41
|
+
></empty-number-input>
|
|
42
|
+
<div class="export-item-columns-tip">
|
|
43
|
+
单个 Excel 最多行数,超出则分多个文件。留空则使用全局逻辑参数(默认 {{ defaultLimitFileSize }})
|
|
44
|
+
</div>
|
|
26
45
|
</el-form-item>
|
|
27
46
|
<el-form-item label="导出参数" label-width="150px">
|
|
28
47
|
<a
|
|
@@ -80,12 +99,15 @@
|
|
|
80
99
|
import i18n from "../../../../utils/i18n";
|
|
81
100
|
import eventMixin from "../event-handler/eventMixin";
|
|
82
101
|
import exportItemColumnsDialog from "../container-data-table/exportItemColumns-dialog.vue";
|
|
102
|
+
import { DEFAULT_CONDITION_EXPORT_CONFIG } from "@base/components/excelExport/conditionExportConfig";
|
|
103
|
+
import emptyNumberInput from "./empty-number-input.vue";
|
|
83
104
|
|
|
84
105
|
export default {
|
|
85
106
|
name: "select-export-item-button-editor",
|
|
86
107
|
mixins: [i18n, eventMixin],
|
|
87
108
|
components: {
|
|
88
109
|
exportItemColumnsDialog,
|
|
110
|
+
emptyNumberInput,
|
|
89
111
|
},
|
|
90
112
|
props: {
|
|
91
113
|
designer: Object,
|
|
@@ -98,6 +120,9 @@ export default {
|
|
|
98
120
|
// 与数据表格属性面板同一套:脚本里可直接用 dataId / formCode
|
|
99
121
|
tableConfigParams: ["dataId", "formCode"],
|
|
100
122
|
showExportItemColumnsDialog: false,
|
|
123
|
+
defaultPageSize: DEFAULT_CONDITION_EXPORT_CONFIG.pageSize,
|
|
124
|
+
defaultMaxQueryTotal: DEFAULT_CONDITION_EXPORT_CONFIG.maxQueryTotal,
|
|
125
|
+
defaultLimitFileSize: DEFAULT_CONDITION_EXPORT_CONFIG.limitFileSize,
|
|
101
126
|
};
|
|
102
127
|
},
|
|
103
128
|
methods: {
|
|
@@ -13,8 +13,23 @@
|
|
|
13
13
|
<el-switch v-model="optionModel.showImageAtTable" @change="changeShowImageAtTable"></el-switch>
|
|
14
14
|
</el-form-item>
|
|
15
15
|
<el-form-item label="导出每页查询数量" class="form-item-label-top">
|
|
16
|
-
<
|
|
17
|
-
|
|
16
|
+
<empty-number-input v-model="optionModel.exportPageSize"
|
|
17
|
+
:max="optionModel.showImageAtTable?150:1000"
|
|
18
|
+
:placeholder="'默认 ' + defaultPageSize"></empty-number-input>
|
|
19
|
+
</el-form-item>
|
|
20
|
+
<el-form-item label="最大查询总数" class="form-item-label-top">
|
|
21
|
+
<empty-number-input v-model="optionModel.maxQueryTotal"
|
|
22
|
+
:placeholder="'默认 ' + defaultMaxQueryTotal"></empty-number-input>
|
|
23
|
+
<div class="export-limit-tip">
|
|
24
|
+
条件导出最多拉取的行数。留空则使用全局逻辑参数(默认 {{ defaultMaxQueryTotal }})
|
|
25
|
+
</div>
|
|
26
|
+
</el-form-item>
|
|
27
|
+
<el-form-item label="每个文件最大数据量" class="form-item-label-top">
|
|
28
|
+
<empty-number-input v-model="optionModel.limitFileSize"
|
|
29
|
+
:placeholder="'默认 ' + defaultLimitFileSize"></empty-number-input>
|
|
30
|
+
<div class="export-limit-tip">
|
|
31
|
+
单个 Excel 最多行数,超出则分多个文件。留空则使用全局逻辑参数(默认 {{ defaultLimitFileSize }})
|
|
32
|
+
</div>
|
|
18
33
|
</el-form-item>
|
|
19
34
|
<el-form-item label="导出参数" label-width="150px">
|
|
20
35
|
<a href="javascript:void(0);" class="a-link link-oneLind"
|
|
@@ -30,10 +45,15 @@
|
|
|
30
45
|
import i18n from "../../../../../../components/xform/utils/i18n";
|
|
31
46
|
import eventMixin
|
|
32
47
|
from "../../../../../../components/xform/form-designer/setting-panel/property-editor/event-handler/eventMixin";
|
|
48
|
+
import { DEFAULT_CONDITION_EXPORT_CONFIG } from "@base/components/excelExport/conditionExportConfig";
|
|
49
|
+
import emptyNumberInput from "./empty-number-input.vue";
|
|
33
50
|
|
|
34
51
|
export default {
|
|
35
52
|
name: "table-export-button-editor",
|
|
36
53
|
mixins: [i18n, eventMixin],
|
|
54
|
+
components: {
|
|
55
|
+
emptyNumberInput,
|
|
56
|
+
},
|
|
37
57
|
props: {
|
|
38
58
|
designer: Object,
|
|
39
59
|
selectedWidget: Object,
|
|
@@ -42,6 +62,9 @@ export default {
|
|
|
42
62
|
data() {
|
|
43
63
|
return {
|
|
44
64
|
eventParams: [],
|
|
65
|
+
defaultPageSize: DEFAULT_CONDITION_EXPORT_CONFIG.pageSize,
|
|
66
|
+
defaultMaxQueryTotal: DEFAULT_CONDITION_EXPORT_CONFIG.maxQueryTotal,
|
|
67
|
+
defaultLimitFileSize: DEFAULT_CONDITION_EXPORT_CONFIG.limitFileSize,
|
|
45
68
|
};
|
|
46
69
|
},
|
|
47
70
|
methods: {
|
|
@@ -57,4 +80,11 @@ export default {
|
|
|
57
80
|
};
|
|
58
81
|
</script>
|
|
59
82
|
|
|
60
|
-
<style scoped
|
|
83
|
+
<style scoped>
|
|
84
|
+
.export-limit-tip {
|
|
85
|
+
line-height: 18px;
|
|
86
|
+
color: #909399;
|
|
87
|
+
font-size: 12px;
|
|
88
|
+
margin-top: 4px;
|
|
89
|
+
}
|
|
90
|
+
</style>
|