6bf528c4 by lihua

合同进度bug

1 parent d802fc04
......@@ -183,8 +183,8 @@ onMounted(() => {
end-placeholder="结束时间" />
</template>
<template v-else-if="item.type == 'date-range'">
<el-date-picker v-model="formInline[item.field]" type="daterange" start-placeholder="开始日期" format="YYYY-MM-DD" value-format="YYYY-MM-DD"
end-placeholder="结束日期" />
<el-date-picker v-model="formInline[item.field]" type="daterange" :start-placeholder="item.startPlaceholder ?? '开始日期'" format="YYYY-MM-DD" value-format="YYYY-MM-DD"
:end-placeholder="item.endPlaceholder ?? '结束日期'" />
</template>
<template v-else-if="item.type == 'radio-button'">
<el-radio-group v-model="formInline[item.field]" @change="radioGroupChange">
......
......@@ -68,7 +68,8 @@ const searchItemList = ref([
type: "date-range",
field: "dateRange",
default: null,
placeholder: "开始日期~结束日期",
startPlaceholder: '签约开始日期',
endPlaceholder: '签约结束日期',
clearable: true,
required: true
}
......@@ -104,7 +105,7 @@ const tableTools = ref();
const handleSearchChange = (val, row, info) => {
if (row.field == 'contractTypeCode') {
tableTools.value.toolSearch.formInline.contractNodeCode = '';
searchItemList.value[2].options = val == '1' ? registerContractNodesList.value : tradeContractNodesList.value;
searchItemList.value[2].options = val == '1' ? registerContractNodesList.value : (!val ? [] : tradeContractNodesList.value);
}
}
......@@ -139,10 +140,10 @@ const tableInfo = ref({
loading: false,
fields: [
{ label: "合同名称", field: "contractName", width: 160, align: "left" },
{ label: "合同类型", field: "contractTypeName", width: 120 },
{ label: "合同类型", field: "contractTypeName", width: 110 },
{ label: "甲方名称", field: "partyAName", width: 180 },
{ label: "乙方名称", field: "partyBName", width: 180 },
{ label: "签约日期", field: "signContractDate", width: TableColumnWidth.DATE },
{ label: "签约日期", field: "signContractDate", width: 110 },
],
childFields: [
{ label: "进展节点", field: "contractNodeName", width: 140, align: "left" },
......@@ -163,12 +164,12 @@ const getNodeSteps = (scope) => {
return {
list: contractNodeCodes.map((n, index) => {
return {
tooltip: {
placement: 'top',
content: n.name,
className: 'step_title_tooltip',
effect: 'light',
},
// tooltip: {
// placement: 'top',
// content: n.name,
// className: 'step_title_tooltip',
// effect: 'light',
// },
title: n.name,
value: index + 1
}
......@@ -399,7 +400,7 @@ const drawerSelectChange = (val, row, info) => {
if (item.field == 'contractNodeCodes') {
item.default = '';
nodesInfo.value = [];
item.options = val == '1' ? registerContractNodesList.value : tradeContractNodesList.value;
item.options = val == '1' ? registerContractNodesList.value : (!val ? [] : tradeContractNodesList.value);
}
});
} else if (row.field == 'contractNodeCodes') {
......@@ -447,7 +448,7 @@ const handleTableEdit = (scope) => {
item.default = scope.row[item.field];
if (item.field == 'contractNodeCodes') {
item.default = scope.row.contractNodeCodes?.map(c => c.code) || [];
item.options = scope.row.contractTypeCode == '1' ? registerContractNodesList.value : tradeContractNodesList.value;
item.options = scope.row.contractTypeCode == '1' ? registerContractNodesList.value : (!scope.row.contractTypeCode ? [] : tradeContractNodesList.value);
}
})
nodesInfo.value = scope.row.contractNodes?.map(node => {
......@@ -689,7 +690,7 @@ onBeforeMount(() => {
<span>{{ scope.row[field.field || ''] || '--' }}</span>
</template>
</el-table-column>
<el-table-column label="进展阶段" width="370px" align="center">
<el-table-column label="进展阶段" width="450px" align="center">
<template #default="scope">
<div class="custom-steps" v-if="scope.row.contractNodeCodes?.length">
<StepBar :steps-info="getNodeSteps(scope)" />
......@@ -697,7 +698,7 @@ onBeforeMount(() => {
<span v-else>--</span>
</template>
</el-table-column>
<el-table-column label="操作" minWidth="120px" align="left" fixed="right" show-overflow-tooltip>
<el-table-column label="操作" width="100px" align="left" fixed="right" show-overflow-tooltip>
<template #default="scope">
<span class="text_btn" @click="handleTableEdit(scope)">编辑</span>
<span class="text_btn ml4" @click="handleTableDel(scope)">删除</span>
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!