|
@@ -1,24 +1,31 @@
|
|
<template>
|
|
<template>
|
|
<HcCard actionUi="text-center">
|
|
<HcCard actionUi="text-center">
|
|
- <HcTable :column="tableColumn" :datas="tableData">
|
|
|
|
- <template #key1="{row,index}">
|
|
|
|
- <span v-if="isDisabled">{{row.key1}}</span>
|
|
|
|
- <el-input v-model="row.key1" v-else/>
|
|
|
|
|
|
+ <HcTable :column="tableColumn" :datas="infoData">
|
|
|
|
+ <template #returnedCondition="{row,index}">
|
|
|
|
+ <span v-if="isDisabled">{{row.returnedCondition}}</span>
|
|
|
|
+ <el-input v-model="row.returnedCondition" v-else/>
|
|
</template>
|
|
</template>
|
|
- <template #key2="{row,index}">
|
|
|
|
- <span v-if="isDisabled">{{row.key2}}</span>
|
|
|
|
- <el-date-picker class="block" v-model="row.key2" format="YYYY-MM-DD" type="date" value-format="YYYY-MM-DD" v-else/>
|
|
|
|
|
|
+ <template #shouldReturnedTime="{row,index}">
|
|
|
|
+ <span v-if="isDisabled">{{row.shouldReturnedTime}}</span>
|
|
|
|
+ <el-date-picker class="block" v-model="row.shouldReturnedTime" format="YYYY-MM-DD" type="date" value-format="YYYY-MM-DD" v-else/>
|
|
</template>
|
|
</template>
|
|
- <template #key3="{row,index}">
|
|
|
|
- <span v-if="isDisabled">{{row.key3}}</span>
|
|
|
|
- <el-input v-model="row.key3" v-else/>
|
|
|
|
|
|
+ <template #shouldReturnedMoney="{row,index}">
|
|
|
|
+ <span v-if="isDisabled">{{row.shouldReturnedMoney}}</span>
|
|
|
|
+ <el-input v-model="row.shouldReturnedMoney" v-else/>
|
|
</template>
|
|
</template>
|
|
- <template #key6="{row,index}">
|
|
|
|
- <span v-if="isDisabled">{{row.key6}}</span>
|
|
|
|
- <el-select v-model="row.key6" v-else>
|
|
|
|
- <el-option label="选项1" value="选项1"/>
|
|
|
|
- <el-option label="选项2" value="选项2"/>
|
|
|
|
- </el-select>
|
|
|
|
|
|
+ <template #practicalReturnedTime="{row,index}">
|
|
|
|
+ <span v-if="isDisabled">{{row.practicalReturnedTime}}</span>
|
|
|
|
+ <el-date-picker class="block" v-model="row.practicalReturnedTime" format="YYYY-MM-DD" type="date" value-format="YYYY-MM-DD" v-else/>
|
|
|
|
+ </template>
|
|
|
|
+ <template #practicalReturnedMoney="{row,index}">
|
|
|
|
+ <span v-if="isDisabled">{{row.practicalReturnedMoney}}</span>
|
|
|
|
+ <el-input v-model="row.practicalReturnedMoney" v-else/>
|
|
|
|
+ </template>
|
|
|
|
+ <template #reminderUserName="{row,index}">
|
|
|
|
+ <span v-if="isDisabled">{{row.reminderUserName}}</span>
|
|
|
|
+ <el-select v-model="row.reminderUserName" block placeholder="请选择" v-else>
|
|
|
|
+ <el-option v-for="item in reminderUserList" :label="item.dictName" :value="item.dictValue"/>
|
|
|
|
+ </el-select>
|
|
</template>
|
|
</template>
|
|
<template #action="{row,index}">
|
|
<template #action="{row,index}">
|
|
<el-button size="small" type="primary" :disabled="isDisabled">
|
|
<el-button size="small" type="primary" :disabled="isDisabled">
|
|
@@ -37,7 +44,7 @@
|
|
<span v-if="isDisabled">返回上一级</span>
|
|
<span v-if="isDisabled">返回上一级</span>
|
|
<span v-else>取消并返回</span>
|
|
<span v-else>取消并返回</span>
|
|
</el-button>
|
|
</el-button>
|
|
- <el-button size="large" type="primary" hc-btn @click="saveClick" v-if="!isDisabled">
|
|
|
|
|
|
+ <el-button size="large" type="primary" hc-btn @click="saveClick" v-if="!isDisabled" :loading="saveLoaingVal">
|
|
<HcIcon name="check-double"/>
|
|
<HcIcon name="check-double"/>
|
|
<span>提交保存</span>
|
|
<span>提交保存</span>
|
|
</el-button>
|
|
</el-button>
|
|
@@ -54,41 +61,49 @@ const router = useRouter()
|
|
//参数
|
|
//参数
|
|
const props = defineProps({
|
|
const props = defineProps({
|
|
datas: {
|
|
datas: {
|
|
- type: Object,
|
|
|
|
- default: () => ({})
|
|
|
|
|
|
+ type: Array,
|
|
|
|
+ default: () => ([{}])
|
|
},
|
|
},
|
|
disabled: {
|
|
disabled: {
|
|
type: Boolean,
|
|
type: Boolean,
|
|
default: false
|
|
default: false
|
|
},
|
|
},
|
|
|
|
+ saveLoaing:{
|
|
|
|
+ type: Boolean,
|
|
|
|
+ default: false
|
|
|
|
+ }
|
|
})
|
|
})
|
|
|
|
|
|
const infoData = ref(props.datas)
|
|
const infoData = ref(props.datas)
|
|
const isDisabled = ref(props.disabled)
|
|
const isDisabled = ref(props.disabled)
|
|
|
|
+const saveLoaingVal=ref(props.saveLoaing)
|
|
|
|
|
|
//深度监听
|
|
//深度监听
|
|
watch(() => [
|
|
watch(() => [
|
|
props.datas,
|
|
props.datas,
|
|
], ([datas]) => {
|
|
], ([datas]) => {
|
|
infoData.value = datas
|
|
infoData.value = datas
|
|
|
|
+
|
|
}, {deep: true})
|
|
}, {deep: true})
|
|
|
|
|
|
//监听
|
|
//监听
|
|
watch(() => [
|
|
watch(() => [
|
|
props.disabled,
|
|
props.disabled,
|
|
-], ([disabled]) => {
|
|
|
|
|
|
+ props.saveLoaing,
|
|
|
|
+], ([disabled,saveLoaing]) => {
|
|
isDisabled.value = disabled
|
|
isDisabled.value = disabled
|
|
|
|
+ saveLoaingVal.value=saveLoaing
|
|
})
|
|
})
|
|
|
|
|
|
//成本测算表格
|
|
//成本测算表格
|
|
const tableColumn = [
|
|
const tableColumn = [
|
|
- {key: 'key1', name: '回款条件', align: 'center'},
|
|
|
|
- {key: 'key2', name: '应收款时间', align: 'center'},
|
|
|
|
- {key: 'key3', name: '应收回款金额', align: 'center'},
|
|
|
|
- {key: 'key4', name: '实际回款时间', align: 'center'},
|
|
|
|
- {key: 'key5', name: '实际回款金额', align: 'center'},
|
|
|
|
- {key: 'key6', name: '催款执行人', align: 'center'},
|
|
|
|
- {key: 'action', name: '操作', width: '160', align: 'center'},
|
|
|
|
|
|
+ {key: 'returnedCondition', name: '回款条件', align: 'center'},
|
|
|
|
+ {key: 'shouldReturnedTime', name: '应收款时间', align: 'center'},
|
|
|
|
+ {key: 'shouldReturnedMoney', name: '应收回款金额', align: 'center'},
|
|
|
|
+ {key: 'practicalReturnedTime', name: '实际回款时间', align: 'center'},
|
|
|
|
+ {key: 'practicalReturnedMoney', name: '实际回款金额', align: 'center'},
|
|
|
|
+ {key: 'reminderUserName', name: '催款执行人', align: 'center'},
|
|
|
|
+ {key: 'action', name: '操作', width: '180', align: 'center'},
|
|
]
|
|
]
|
|
const tableData = ref([
|
|
const tableData = ref([
|
|
{id: 1}, {id: 2}, {id: 3}, {id: 4},
|
|
{id: 1}, {id: 2}, {id: 3}, {id: 4},
|
|
@@ -99,9 +114,16 @@ const tableData = ref([
|
|
const goBackClick = () => {
|
|
const goBackClick = () => {
|
|
router.back()
|
|
router.back()
|
|
}
|
|
}
|
|
|
|
+//催款执行人reminderUserList
|
|
|
|
+const reminderUserList=ref([])
|
|
|
|
+
|
|
|
|
|
|
|
|
+const emit= defineEmits(['saveClick'])
|
|
//提交保存
|
|
//提交保存
|
|
const saveClick = () => {
|
|
const saveClick = () => {
|
|
|
|
+ console.log(infoData.value,'infoData');
|
|
|
|
+ emit('saveClick',infoData.value,'milestone')
|
|
|
|
+
|
|
|
|
|
|
}
|
|
}
|
|
</script>
|
|
</script>
|