cloud-web-corejs 1.0.54-dev.798 → 1.0.54-dev.799
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 +3 -1
- package/src/components/baseTabs/mixins.js +11 -12
- package/src/components/bizTab/BizBillActions.vue +129 -0
- package/src/components/bizTab/BizTabListPage.vue +391 -0
- package/src/components/bizTab/README.md +378 -0
- package/src/components/bizTab/billTableUtil.js +48 -0
- package/src/components/bizTab/billValidators.js +136 -0
- package/src/components/bizTab/bizBillDetailMixin.js +687 -0
- package/src/components/bizTab/index.js +24 -0
- package/src/components/excelExport/exportFieldDialog.vue +373 -367
- package/src/components/excelExport/exportType.js +49 -0
- package/src/components/excelExport/mixins.js +1153 -1144
- package/src/components/vb-tabs/x-tabs.vue +167 -143
- package/src/components/wf/wfUtil.js +327 -292
- package/src/components/xform/form-designer/designer.js +56 -8
- package/src/components/xform/form-designer/form-widget/container-widget/detail-widget.vue +59 -5
- package/src/components/xform/form-designer/form-widget/field-widget/baseAttachment-widget.vue +60 -8
- package/src/components/xform/form-designer/form-widget/field-widget/form-item-wrapper.vue +8 -2
- package/src/components/xform/form-designer/form-widget/field-widget/select-export-item-button-widget.vue +120 -92
- package/src/components/xform/form-designer/form-widget/field-widget/vabUpload-widget.vue +63 -94
- package/src/components/xform/form-designer/index.vue +0 -1
- package/src/components/xform/form-designer/setting-panel/dataSource-setting.vue +397 -397
- package/src/components/xform/form-designer/setting-panel/form-dynamicField-setting.vue +602 -602
- package/src/components/xform/form-designer/setting-panel/form-setting.vue +13 -13
- package/src/components/xform/form-designer/setting-panel/option-items-setting.vue +585 -585
- package/src/components/xform/form-designer/setting-panel/property-editor/a-link-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/a-text-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/alignType-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/censusClass-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/colorClass-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/commonAttributeEnabled-editor.vue +3 -3
- package/src/components/xform/form-designer/setting-panel/property-editor/container-data-table/data-table-editor.vue +1154 -1154
- package/src/components/xform/form-designer/setting-panel/property-editor/container-detail/detail-editor.vue +96 -80
- package/src/components/xform/form-designer/setting-panel/property-editor/container-detail-plain/detail-plain-editor.vue +75 -75
- package/src/components/xform/form-designer/setting-panel/property-editor/container-grid/colHeight-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-grid/gutter-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-grid-col/grid-col-height-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-grid-col/grid-col-offset-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-grid-col/grid-col-pull-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-grid-col/grid-col-push-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-grid-col/grid-col-span-editor.vue +4 -4
- package/src/components/xform/form-designer/setting-panel/property-editor/container-h5-card/h5-card-editor.vue +124 -124
- package/src/components/xform/form-designer/setting-panel/property-editor/container-panel/height-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-panel/width-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-tab/tab-customClass-editor.vue +119 -119
- package/src/components/xform/form-designer/setting-panel/property-editor/container-tab/tabClass-editor.vue +45 -45
- package/src/components/xform/form-designer/setting-panel/property-editor/container-table/table-dynamicField-editor.vue +344 -344
- package/src/components/xform/form-designer/setting-panel/property-editor/container-table-cell/cellHeight-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-table-cell/cellWidth-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-tree/tree-customClass-editor.vue +2 -2
- package/src/components/xform/form-designer/setting-panel/property-editor/container-tree-pane/tree-pane-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-vf-dialog/cancelButtonLabel-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-vf-dialog/okButtonLabel-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-vf-dialog/title-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-vf-dialog/width-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/containerClass-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/customClass-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/defaultValue-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/descriptionsItems-editor.vue +4 -4
- package/src/components/xform/form-designer/setting-panel/property-editor/downloadButtonFlag-editor.vue +3 -3
- package/src/components/xform/form-designer/setting-panel/property-editor/dropdownFlag-editor.vue +2 -2
- package/src/components/xform/form-designer/setting-panel/property-editor/dsName-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/echartHeight-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/endPlaceholder-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-accessUrl/accessUrl-editor.vue +2 -2
- package/src/components/xform/form-designer/setting-panel/property-editor/field-area-select/areaDataType-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-area-select/areaMinLevel-editor.vue +50 -50
- package/src/components/xform/form-designer/setting-panel/property-editor/field-area-select/areaName-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-autocomplete/autocomplete-vabSearchName-editor.vue +7 -7
- package/src/components/xform/form-designer/setting-panel/property-editor/field-button/addTableData-event-editor.vue +84 -84
- package/src/components/xform/form-designer/setting-panel/property-editor/field-button/button-type-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-button/clickBindEvent-editor.vue +97 -97
- package/src/components/xform/form-designer/setting-panel/property-editor/field-button/form-host-event-editor.vue +188 -188
- package/src/components/xform/form-designer/setting-panel/property-editor/field-button/search-dialog-event-editor.vue +237 -237
- package/src/components/xform/form-designer/setting-panel/property-editor/field-common/keyName-editor.vue +74 -67
- package/src/components/xform/form-designer/setting-panel/property-editor/field-date/date-dateLimit-editor.vue +4 -4
- package/src/components/xform/form-designer/setting-panel/property-editor/field-date/date-defaultValue-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-date/date-format-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-date/date-type-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-date/date-valueFormat-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-date-range/date-range-defaultTime-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-date-range/date-range-defaultValue-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-date-range/date-range-format-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-date-range/date-range-type-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-date-range/date-range-valueFormat-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-divider/contentPosition-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-dropdown-menu/dropdown-menu-editor.vue +59 -59
- package/src/components/xform/form-designer/setting-panel/property-editor/field-echart/echart-bar-editor.vue +11 -11
- package/src/components/xform/form-designer/setting-panel/property-editor/field-echart/echart-category-editor.vue +10 -10
- package/src/components/xform/form-designer/setting-panel/property-editor/field-echart/echart-pie-editor.vue +12 -12
- package/src/components/xform/form-designer/setting-panel/property-editor/field-file-upload/file-upload-fileTypes-editor.vue +44 -44
- package/src/components/xform/form-designer/setting-panel/property-editor/field-html-text/htmlContent-editor.vue +29 -29
- package/src/components/xform/form-designer/setting-panel/property-editor/field-import-button/import-button-editor.vue +6 -6
- package/src/components/xform/form-designer/setting-panel/property-editor/field-import-button/import2-button-editor.vue +3 -3
- package/src/components/xform/form-designer/setting-panel/property-editor/field-number/controlsPosition-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-picture-upload/picture-upload-fileTypes-editor.vue +44 -44
- package/src/components/xform/form-designer/setting-panel/property-editor/field-print-button/print-button-editor.vue +115 -115
- package/src/components/xform/form-designer/setting-panel/property-editor/field-print-button/print-detail-button-editor.vue +115 -115
- package/src/components/xform/form-designer/setting-panel/property-editor/field-rate/highThreshold-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-rate/lowThreshold-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-rate/rate-defaultValue-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-rate/rate-max-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-script/script-editor.vue +4 -4
- package/src/components/xform/form-designer/setting-panel/property-editor/field-script-input/script-input-editor.vue +4 -4
- package/src/components/xform/form-designer/setting-panel/property-editor/field-static-text/fontSize-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-static-text/textContent-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-status/field-status-editor.vue +3 -3
- package/src/components/xform/form-designer/setting-panel/property-editor/field-switch/activeText-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-switch/inactiveText-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-switch/switchWidth-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-table-export-button/select-export-button-editor.vue +2 -2
- package/src/components/xform/form-designer/setting-panel/property-editor/field-table-export-button/select-export-item-button-editor.vue +74 -71
- package/src/components/xform/form-designer/setting-panel/property-editor/field-table-export-button/table-export-button-editor.vue +3 -3
- package/src/components/xform/form-designer/setting-panel/property-editor/field-time/time-defaultValue-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-time/time-format-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-time/time-timeLimit-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-time-range/time-range-defaultValue-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-time-range/time-range-format-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-vabSearch/vabSearchField-editor.vue +2 -2
- package/src/components/xform/form-designer/setting-panel/property-editor/field-vabSearch/vabSearchName-editor.vue +2 -2
- package/src/components/xform/form-designer/setting-panel/property-editor/field-vabUpload/field-vabUpload-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-vabUpload2/field-vabUpload2-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-vue-page/vue-page-editor.vue +2 -2
- package/src/components/xform/form-designer/setting-panel/property-editor/fileMaxSize-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/fileTypesSelect.vue +176 -176
- package/src/components/xform/form-designer/setting-panel/property-editor/formScriptEnabled-editor.vue +2 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/formatType-editor.vue +2 -2
- package/src/components/xform/form-designer/setting-panel/property-editor/formula-editor.vue +972 -972
- package/src/components/xform/form-designer/setting-panel/property-editor/iconClass-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/label-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/labelAlign-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/labelColor-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/labelIconPosition-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/labelWidth-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/limit-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/max-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/maxLength-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/min-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/minLength-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/multipleLimit-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/name-editor.vue +178 -178
- package/src/components/xform/form-designer/setting-panel/property-editor/oplog-editor.vue +3 -3
- package/src/components/xform/form-designer/setting-panel/property-editor/placeholder-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/precision-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/project-tag-editor.vue +6 -6
- package/src/components/xform/form-designer/setting-panel/property-editor/requiredHint-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/rows-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/space-editor-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/startPlaceholder-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/step-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/styleTableClass-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/styleTitClass-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/tempStorage-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/type-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/uploadTip-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/uploadURL-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/urlValueEnabled-editor.vue +91 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/validation-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/validationHint-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/widgetWidth-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/propertyRegister.js +1 -0
- package/src/components/xform/form-designer/widget-panel/index.vue +3 -1
- package/src/components/xform/form-designer/widget-panel/widgetsConfig.js +55 -13
- package/src/components/xform/form-render/container-item/data-table-mixin copy.js +5910 -0
- package/src/components/xform/form-render/container-item/data-table-mixin.js +59 -13
- package/src/components/xform/form-render/container-item/detail-item.vue +52 -11
- package/src/components/xform/form-render/container-item/tab-item.vue +6 -2
- package/src/components/xform/form-render/indexMixin.js +56 -16
- package/src/components/xform/lang/zh-CN.js +2 -1
- package/src/components/xform/utils/attachmentValueUtil.js +239 -0
- package/src/components/xform/utils/util.js +27 -0
- package/src/mixins/wf/index.js +40 -38
- package/src/router/modules/customer.js +50 -0
- package/src/store/config/index.js +46 -0
- package/src/utils/scrollUtil.js +25 -0
- package/src/views/demo/bizTab/bill/billConfig.js +41 -0
- package/src/views/demo/bizTab/bill/detail.vue +436 -0
- package/src/views/demo/bizTab/bill/list.vue +288 -0
- package/src/views/demo/bizTab/bill/productDialog.vue +176 -0
- package/src/views/demo/bizTab/simple/billApi.js +123 -0
- package/src/views/demo/bizTab/simple/detail.vue +407 -0
- package/src/views/demo/bizTab/simple/list.vue +217 -0
- package/src/views/demo/bizTab/standalone/index.vue +121 -0
- package/src/views/demo/bizTab/wf/billConfig.js +44 -0
- package/src/views/demo/bizTab/wf/detail.vue +661 -0
- package/src/views/demo/bizTab/wf/list.vue +242 -0
- package/src/views/user/outLink/cc_form_view.vue +185 -0
|
@@ -0,0 +1,242 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<biz-tab-list-page
|
|
3
|
+
ref="bizTab"
|
|
4
|
+
:listLabel="$t1('列表')"
|
|
5
|
+
:titleField="BILL.titleField"
|
|
6
|
+
:addTitle="$t1('新增')"
|
|
7
|
+
:behavior="tabBehavior"
|
|
8
|
+
@refresh-list="searchEvent"
|
|
9
|
+
>
|
|
10
|
+
<!-- ===== 列表页签 ===== -->
|
|
11
|
+
<template #list>
|
|
12
|
+
<vxe-grid
|
|
13
|
+
ref="table-m1"
|
|
14
|
+
v-bind="vxeOption"
|
|
15
|
+
@resizable-change="$vxeTableUtil.onColumnWitchChange"
|
|
16
|
+
@custom="$vxeTableUtil.customHandle"
|
|
17
|
+
>
|
|
18
|
+
<template #form>
|
|
19
|
+
<div class="clearfix screen-btns">
|
|
20
|
+
<div class="fl">
|
|
21
|
+
<vxe-button
|
|
22
|
+
status="primary"
|
|
23
|
+
type="text"
|
|
24
|
+
plain
|
|
25
|
+
class="button-sty"
|
|
26
|
+
icon="el-icon-plus"
|
|
27
|
+
@click="openAdd"
|
|
28
|
+
>{{ $t1("新增") }}</vxe-button
|
|
29
|
+
>
|
|
30
|
+
<!-- demo 用:现场切换「提交/审批完成后」的页签行为 -->
|
|
31
|
+
<el-switch
|
|
32
|
+
v-model="closeAfterWf"
|
|
33
|
+
class="behavior-switch"
|
|
34
|
+
:active-text="$t1('提交/通过后关闭页签回列表')"
|
|
35
|
+
></el-switch>
|
|
36
|
+
</div>
|
|
37
|
+
<div class="fr">
|
|
38
|
+
<vxe-button
|
|
39
|
+
icon="el-icon-brush"
|
|
40
|
+
class="button-sty"
|
|
41
|
+
type="text"
|
|
42
|
+
status="primary"
|
|
43
|
+
plain
|
|
44
|
+
@click="resetEvent"
|
|
45
|
+
>{{ $t1("重置") }}</vxe-button
|
|
46
|
+
>
|
|
47
|
+
<vxe-button
|
|
48
|
+
status="warning"
|
|
49
|
+
icon="el-icon-search"
|
|
50
|
+
class="button-sty"
|
|
51
|
+
@click="searchEvent"
|
|
52
|
+
>{{ $t1("搜索") }}</vxe-button
|
|
53
|
+
>
|
|
54
|
+
</div>
|
|
55
|
+
</div>
|
|
56
|
+
<vxe-form
|
|
57
|
+
ref="form"
|
|
58
|
+
class="screen-box"
|
|
59
|
+
title-width="92px"
|
|
60
|
+
title-align="right"
|
|
61
|
+
:data="formData"
|
|
62
|
+
@submit="searchEvent"
|
|
63
|
+
@reset="resetEvent"
|
|
64
|
+
>
|
|
65
|
+
<vxe-form-item :title="$t1('单号') + ':'" field="sn">
|
|
66
|
+
<template v-slot>
|
|
67
|
+
<el-input v-model="formData.sn" size="small" clearable />
|
|
68
|
+
</template>
|
|
69
|
+
</vxe-form-item>
|
|
70
|
+
<vxe-form-item :title="$t1('阶梯价名称') + ':'" field="ladderName">
|
|
71
|
+
<template v-slot>
|
|
72
|
+
<el-input v-model="formData.ladderName" size="small" clearable />
|
|
73
|
+
</template>
|
|
74
|
+
</vxe-form-item>
|
|
75
|
+
<vxe-form-item :title="$t1('单据状态') + ':'" field="status">
|
|
76
|
+
<template v-slot>
|
|
77
|
+
<el-select
|
|
78
|
+
v-model="formData.status"
|
|
79
|
+
size="small"
|
|
80
|
+
clearable
|
|
81
|
+
@clear="formData.status = null"
|
|
82
|
+
>
|
|
83
|
+
<el-option
|
|
84
|
+
v-for="(item, key) in STATUS_MAP"
|
|
85
|
+
:key="key"
|
|
86
|
+
:label="item.label"
|
|
87
|
+
:value="Number(key)"
|
|
88
|
+
></el-option>
|
|
89
|
+
</el-select>
|
|
90
|
+
</template>
|
|
91
|
+
</vxe-form-item>
|
|
92
|
+
</vxe-form>
|
|
93
|
+
</template>
|
|
94
|
+
|
|
95
|
+
<template #sn="{ row, rowIndex }">
|
|
96
|
+
<a href="javascript:void(0);" class="a-link" @click="openDetail(row, rowIndex)">
|
|
97
|
+
{{ row.sn }}
|
|
98
|
+
</a>
|
|
99
|
+
</template>
|
|
100
|
+
<template #status="{ row }">
|
|
101
|
+
<div :class="getStatus(row).cls">{{ getStatus(row).label }}</div>
|
|
102
|
+
</template>
|
|
103
|
+
<template #operate="{ row, rowIndex }">
|
|
104
|
+
<a href="javascript:void(0);" class="a-link" @click="openDetail(row, rowIndex)">
|
|
105
|
+
<el-tooltip
|
|
106
|
+
:enterable="false"
|
|
107
|
+
effect="dark"
|
|
108
|
+
:content="$t1('查看')"
|
|
109
|
+
placement="top"
|
|
110
|
+
popper-class="tooltip-skin"
|
|
111
|
+
><i class="el-icon-view"
|
|
112
|
+
/></el-tooltip>
|
|
113
|
+
</a>
|
|
114
|
+
</template>
|
|
115
|
+
</vxe-grid>
|
|
116
|
+
</template>
|
|
117
|
+
|
|
118
|
+
<!-- ===== 详情页签(新增/查看共用同一个组件) ===== -->
|
|
119
|
+
<template #detail="{ tab }">
|
|
120
|
+
<bill-detail :tab="tab" />
|
|
121
|
+
</template>
|
|
122
|
+
</biz-tab-list-page>
|
|
123
|
+
</template>
|
|
124
|
+
|
|
125
|
+
<script>
|
|
126
|
+
/**
|
|
127
|
+
* demo C:自定义控制器 + 流程(std 手写页面那套写法)。
|
|
128
|
+
*
|
|
129
|
+
* 与 demo B 的区别只在数据通道:这里是 /ladderPrice/get|save|update 这类自己写的接口,
|
|
130
|
+
* demo B 是通用 bd_api + formCode。页签、流程、翻单这些用法完全一样。
|
|
131
|
+
*
|
|
132
|
+
* 接口与 wfCode 见 ./billConfig.js;写法对齐本仓库 views/pmd/price/ladderPrice/。
|
|
133
|
+
* 菜单/路由:@base/views/demo/bizTab/wf/list(本地已在 router/modules/customer.js 注册)
|
|
134
|
+
*/
|
|
135
|
+
import BizTabListPage from "@base/components/bizTab/BizTabListPage.vue";
|
|
136
|
+
import billDetail from "./detail.vue";
|
|
137
|
+
import { BILL, STATUS_MAP } from "./billConfig";
|
|
138
|
+
|
|
139
|
+
export default {
|
|
140
|
+
name: "demo_bizTab_wf:list",
|
|
141
|
+
components: { BizTabListPage, billDetail },
|
|
142
|
+
data() {
|
|
143
|
+
return {
|
|
144
|
+
BILL,
|
|
145
|
+
STATUS_MAP,
|
|
146
|
+
vxeOption: {},
|
|
147
|
+
formData: {},
|
|
148
|
+
closeAfterWf: false,
|
|
149
|
+
};
|
|
150
|
+
},
|
|
151
|
+
computed: {
|
|
152
|
+
tabBehavior() {
|
|
153
|
+
if (!this.closeAfterWf) return "refreshCurrent";
|
|
154
|
+
return {
|
|
155
|
+
submit: "closeToList",
|
|
156
|
+
agree: "closeToList",
|
|
157
|
+
default: "refreshCurrent",
|
|
158
|
+
};
|
|
159
|
+
},
|
|
160
|
+
},
|
|
161
|
+
mounted() {
|
|
162
|
+
this.initTableList();
|
|
163
|
+
},
|
|
164
|
+
methods: {
|
|
165
|
+
searchEvent() {
|
|
166
|
+
this.$refs["table-m1"].commitProxy("reload");
|
|
167
|
+
},
|
|
168
|
+
resetEvent() {
|
|
169
|
+
this.formData = {};
|
|
170
|
+
this.$refs["table-m1"].commitProxy("reload");
|
|
171
|
+
},
|
|
172
|
+
getStatus(row) {
|
|
173
|
+
return STATUS_MAP[row.status] || { label: "", cls: "" };
|
|
174
|
+
},
|
|
175
|
+
// 新增页签也传快照:保存成功后新单会被插到序列首位,翻单按钮随即可用
|
|
176
|
+
openAdd() {
|
|
177
|
+
this.$refs.bizTab.openAdd(null, { navRows: this.getListRows() });
|
|
178
|
+
},
|
|
179
|
+
// 把当前列表顺序和行下标一起传进去,详情头部就有「上一单/下一单」
|
|
180
|
+
openDetail(row, rowIndex) {
|
|
181
|
+
this.$refs.bizTab.openDetail(row, null, {
|
|
182
|
+
navRows: this.getListRows(),
|
|
183
|
+
navIndex: rowIndex != null ? rowIndex : -1,
|
|
184
|
+
});
|
|
185
|
+
},
|
|
186
|
+
getListRows() {
|
|
187
|
+
let grid = this.$refs["table-m1"];
|
|
188
|
+
return grid ? grid.getTableData().fullData : null;
|
|
189
|
+
},
|
|
190
|
+
initTableList() {
|
|
191
|
+
let tableOption = {
|
|
192
|
+
vue: this,
|
|
193
|
+
tableRef: "table-m1",
|
|
194
|
+
tableName: "demo-bizTab-wf-list-m1",
|
|
195
|
+
path: BILL.urls.listPage,
|
|
196
|
+
param: () => {
|
|
197
|
+
return { ...this.formData };
|
|
198
|
+
},
|
|
199
|
+
columns: [
|
|
200
|
+
{ type: "checkbox", width: 48, resizable: false, fixed: "left" },
|
|
201
|
+
{
|
|
202
|
+
title: this.$t1("单号"),
|
|
203
|
+
field: "sn",
|
|
204
|
+
width: 150,
|
|
205
|
+
fixed: "left",
|
|
206
|
+
slots: { default: "sn" },
|
|
207
|
+
},
|
|
208
|
+
{ title: this.$t1("阶梯价名称"), field: "ladderName", width: 180 },
|
|
209
|
+
{
|
|
210
|
+
title: this.$t1("单据状态"),
|
|
211
|
+
field: "status",
|
|
212
|
+
width: 100,
|
|
213
|
+
slots: { default: "status" },
|
|
214
|
+
},
|
|
215
|
+
{ title: this.$t1("开始时间"), field: "startDate", width: 120 },
|
|
216
|
+
{ title: this.$t1("结束时间"), field: "endDate", width: 120 },
|
|
217
|
+
{ title: this.$t1("机构名称"), field: "saleOrgNames", minWidth: 180 },
|
|
218
|
+
{ title: this.$t1("备注"), field: "memo", minWidth: 150 },
|
|
219
|
+
{ title: this.$t1("创建人"), field: "createBy", width: 110 },
|
|
220
|
+
{ title: this.$t1("创建时间"), field: "createDate", width: 160 },
|
|
221
|
+
{
|
|
222
|
+
title: "",
|
|
223
|
+
width: 47,
|
|
224
|
+
fixed: "right",
|
|
225
|
+
sortable: false,
|
|
226
|
+
slots: { default: "operate" },
|
|
227
|
+
},
|
|
228
|
+
],
|
|
229
|
+
};
|
|
230
|
+
this.$vxeTableUtil.initVxeTable(tableOption).then((opts) => {
|
|
231
|
+
this.vxeOption = opts;
|
|
232
|
+
});
|
|
233
|
+
},
|
|
234
|
+
},
|
|
235
|
+
};
|
|
236
|
+
</script>
|
|
237
|
+
|
|
238
|
+
<style scoped>
|
|
239
|
+
.behavior-switch {
|
|
240
|
+
margin-left: 16px;
|
|
241
|
+
}
|
|
242
|
+
</style>
|
|
@@ -0,0 +1,185 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div
|
|
3
|
+
class="cc-entry"
|
|
4
|
+
v-loading="loading"
|
|
5
|
+
:element-loading-text="loadingText"
|
|
6
|
+
element-loading-background="rgba(255, 255, 255, 0.9)"
|
|
7
|
+
>
|
|
8
|
+
<div class="cc-entry__box" v-if="errMsg">
|
|
9
|
+
<el-alert :title="errMsg" type="error" :closable="false" show-icon />
|
|
10
|
+
<div class="cc-entry__footer">
|
|
11
|
+
<el-button type="primary" size="small" @click="start">重试</el-button>
|
|
12
|
+
</div>
|
|
13
|
+
</div>
|
|
14
|
+
</div>
|
|
15
|
+
</template>
|
|
16
|
+
|
|
17
|
+
<script>
|
|
18
|
+
/**
|
|
19
|
+
* 呼叫中心(CC)业务专用外链入口。
|
|
20
|
+
*
|
|
21
|
+
* 背景:业务系统(呼叫中心)只会带 appid / appkey / account / callNo 四个参数跳过来,
|
|
22
|
+
* 拿不到 form_outLinkView 所需的 tp(用户身份密文)。本页在 form_outLinkView 之前加一层:
|
|
23
|
+
* 1. 取四个参数
|
|
24
|
+
* 2. 调后台接口换取 tp
|
|
25
|
+
* 3. replace 到 /form_outLinkView,formCode 写死、dataId 固定 0
|
|
26
|
+
*
|
|
27
|
+
* 入口地址示例:
|
|
28
|
+
* https://csmuat.chinamacro.com/#/cc_form_outLinkView
|
|
29
|
+
* ?appid=6789B4BBAF71D4F9D79E0912856E04E
|
|
30
|
+
* &appkey=坐席id
|
|
31
|
+
* &account=坐席帐号
|
|
32
|
+
* &callNo=来电手机
|
|
33
|
+
*
|
|
34
|
+
* 最终跳转:
|
|
35
|
+
* #/form_outLinkView?url=/user/form/view/edit&formCode=xxx&dataId=0&tp=xxx&callNo=xxx...
|
|
36
|
+
*/
|
|
37
|
+
|
|
38
|
+
/* ------------------------------------------------------------------ *
|
|
39
|
+
* 业务定制配置:换业务页面只改这里
|
|
40
|
+
* ------------------------------------------------------------------ */
|
|
41
|
+
const CC_CONFIG = {
|
|
42
|
+
// 固定的表单视图路由,form_outLinkView 的 url 参数
|
|
43
|
+
formUrl: "/user/form/view/edit",
|
|
44
|
+
// 写死的表单编码(按实际业务表单调整)
|
|
45
|
+
formCode: "patentApply_edit",
|
|
46
|
+
// 写死的单据 ID,新建为 0
|
|
47
|
+
dataId: "0",
|
|
48
|
+
// 换取 tp 的后台接口(需后台提供:入参 appId/appKey/account/callNo,出参 tp)
|
|
49
|
+
tpApi: USER_PREFIX + "/thirdparty_auth/getTpByCallCenter",
|
|
50
|
+
// 业务系统固定下发的 appid,链接未带时用它兜底
|
|
51
|
+
defaultAppId: "6789B4BBAF71D4F9D79E0912856E04E",
|
|
52
|
+
};
|
|
53
|
+
|
|
54
|
+
/** 透传给业务表单的参数(form_outLinkView 会 v-bind 到目标组件上) */
|
|
55
|
+
const PASS_THROUGH = ["callNo", "account", "agentId"];
|
|
56
|
+
|
|
57
|
+
export default {
|
|
58
|
+
name: "ccFormOutLinkView",
|
|
59
|
+
data() {
|
|
60
|
+
return {
|
|
61
|
+
loading: false,
|
|
62
|
+
loadingText: "正在获取身份信息…",
|
|
63
|
+
errMsg: "",
|
|
64
|
+
};
|
|
65
|
+
},
|
|
66
|
+
created() {
|
|
67
|
+
this.start();
|
|
68
|
+
},
|
|
69
|
+
methods: {
|
|
70
|
+
/** 大小写不敏感地取 query,业务系统对参数大小写不一定稳定 */
|
|
71
|
+
pickQuery(...names) {
|
|
72
|
+
let query = this.$route.query || {};
|
|
73
|
+
let keys = Object.keys(query);
|
|
74
|
+
for (let name of names) {
|
|
75
|
+
let key = keys.find((k) => k.toLowerCase() === name.toLowerCase());
|
|
76
|
+
if (key && query[key] !== "" && query[key] !== undefined && query[key] !== null) {
|
|
77
|
+
return query[key];
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
return "";
|
|
81
|
+
},
|
|
82
|
+
resolveParams() {
|
|
83
|
+
return {
|
|
84
|
+
appId: this.pickQuery("appid", "appId") || CC_CONFIG.defaultAppId,
|
|
85
|
+
appKey: this.pickQuery("appkey", "appKey"),
|
|
86
|
+
account: this.pickQuery("account"),
|
|
87
|
+
callNo: this.pickQuery("callNo", "callno", "phone"),
|
|
88
|
+
};
|
|
89
|
+
},
|
|
90
|
+
/** 兼容后台把 tp 放在 objx 字符串 / objx.tp / objx.thirdpartyInfo 三种返回形态 */
|
|
91
|
+
resolveTp(res) {
|
|
92
|
+
let objx = res && res.objx;
|
|
93
|
+
if (!objx) return "";
|
|
94
|
+
if (typeof objx === "string") return objx;
|
|
95
|
+
return objx.tp || objx.thirdpartyInfo || objx.thirdparty_info || "";
|
|
96
|
+
},
|
|
97
|
+
start() {
|
|
98
|
+
this.errMsg = "";
|
|
99
|
+
let params = this.resolveParams();
|
|
100
|
+
let missing = ["appId", "appKey", "account"].filter((key) => !params[key]);
|
|
101
|
+
if (missing.length) {
|
|
102
|
+
this.errMsg = "缺少必要参数:" + missing.join("、") + ",请检查呼叫中心跳转链接";
|
|
103
|
+
return;
|
|
104
|
+
}
|
|
105
|
+
this.getTp(params);
|
|
106
|
+
},
|
|
107
|
+
getTp(params) {
|
|
108
|
+
this.loading = true;
|
|
109
|
+
this.$http({
|
|
110
|
+
url: CC_CONFIG.tpApi,
|
|
111
|
+
method: "post",
|
|
112
|
+
data: params,
|
|
113
|
+
// 无 token 场景,且自行接管提示与遮罩
|
|
114
|
+
useToken: false,
|
|
115
|
+
isLoading: false,
|
|
116
|
+
failMsg: false,
|
|
117
|
+
errorMsg: false,
|
|
118
|
+
success: (res) => {
|
|
119
|
+
let tp = this.resolveTp(res);
|
|
120
|
+
if (!tp) {
|
|
121
|
+
this.loading = false;
|
|
122
|
+
this.errMsg = "身份信息(tp)获取失败:接口未返回 tp";
|
|
123
|
+
return;
|
|
124
|
+
}
|
|
125
|
+
this.redirect(params, tp);
|
|
126
|
+
},
|
|
127
|
+
fail: (res) => {
|
|
128
|
+
this.loading = false;
|
|
129
|
+
this.errMsg = "身份信息(tp)获取失败:" + ((res && (res.content || res.msg)) || "接口返回异常");
|
|
130
|
+
},
|
|
131
|
+
error: (err) => {
|
|
132
|
+
this.loading = false;
|
|
133
|
+
this.errMsg = "身份信息(tp)获取失败:" + ((err && err.message) || "网络异常");
|
|
134
|
+
},
|
|
135
|
+
});
|
|
136
|
+
},
|
|
137
|
+
redirect(params, tp) {
|
|
138
|
+
this.loadingText = "正在打开单据…";
|
|
139
|
+
let query = {
|
|
140
|
+
url: CC_CONFIG.formUrl,
|
|
141
|
+
formCode: CC_CONFIG.formCode,
|
|
142
|
+
dataId: CC_CONFIG.dataId,
|
|
143
|
+
tp: tp,
|
|
144
|
+
};
|
|
145
|
+
// 来电号码等业务参数透传给表单,供表单脚本取用
|
|
146
|
+
let source = { ...params, agentId: params.appKey };
|
|
147
|
+
PASS_THROUGH.forEach((key) => {
|
|
148
|
+
if (source[key]) {
|
|
149
|
+
query[key] = source[key];
|
|
150
|
+
}
|
|
151
|
+
});
|
|
152
|
+
let i18nLang = this.pickQuery("i18nLang");
|
|
153
|
+
if (i18nLang) {
|
|
154
|
+
query.i18nLang = i18nLang;
|
|
155
|
+
}
|
|
156
|
+
// replace:不在历史里留下本入口页,避免回退时重复换取 tp
|
|
157
|
+
// 注:vue-router 3.0.2 的 replace 不返回 Promise,不能链 .then/.catch
|
|
158
|
+
this.$router.replace({
|
|
159
|
+
path: "/form_outLinkView",
|
|
160
|
+
query: query,
|
|
161
|
+
});
|
|
162
|
+
},
|
|
163
|
+
},
|
|
164
|
+
};
|
|
165
|
+
</script>
|
|
166
|
+
|
|
167
|
+
<style lang="scss" scoped>
|
|
168
|
+
.cc-entry {
|
|
169
|
+
display: flex;
|
|
170
|
+
align-items: center;
|
|
171
|
+
justify-content: center;
|
|
172
|
+
width: 100%;
|
|
173
|
+
height: 100vh;
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.cc-entry__box {
|
|
177
|
+
width: 420px;
|
|
178
|
+
max-width: 80%;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
.cc-entry__footer {
|
|
182
|
+
margin-top: 12px;
|
|
183
|
+
text-align: center;
|
|
184
|
+
}
|
|
185
|
+
</style>
|