Browse Source

表单校验

lihuilin/feature-20250923114949-现金
ZhangYong 1 month ago
parent
commit
e0e35ae80e
  1. 4
      src/views/moneyManage/receiveDetail/receiveDetail.vue

4
src/views/moneyManage/receiveDetail/receiveDetail.vue

@ -178,7 +178,7 @@
v-if="!kefu && activeTab == 'pass' || activeTab == 'reject' || activeTab == 'done'" v-if="!kefu && activeTab == 'pass' || activeTab == 'reject' || activeTab == 'done'"
width="150px" show-overflow-tooltip></el-table-column> width="150px" show-overflow-tooltip></el-table-column>
<el-table-column prop="receivedTime" label="到账时间" <el-table-column prop="receivedTime" label="到账时间"
v-if="caiwu && activeTab == 'pass' || activeTab == 'done'" width="180px">
v-if="!kefu && activeTab == 'pass' || activeTab == 'done'" width="180px">
</el-table-column> </el-table-column>
<el-table-column prop="remark" label="备注" v-if="activeTab != 'reject'" width="150px" <el-table-column prop="remark" label="备注" v-if="activeTab != 'reject'" width="150px"
show-overflow-tooltip></el-table-column> show-overflow-tooltip></el-table-column>
@ -1231,6 +1231,7 @@ const closeEditForm = () => {
// //
const submitEditForm = async () => { const submitEditForm = async () => {
try { try {
await editFormRef.value.validate();
if (editFormData.value.receivedTime) { if (editFormData.value.receivedTime) {
editFormData.value.receivedTime = moment(editFormData.value.receivedTime).format('YYYY-MM-DD HH:mm:ss') editFormData.value.receivedTime = moment(editFormData.value.receivedTime).format('YYYY-MM-DD HH:mm:ss')
} }
@ -1255,6 +1256,7 @@ const submitEditForm = async () => {
console.log('返回参数:', result); console.log('返回参数:', result);
} catch (error) { } catch (error) {
console.log(error); console.log(error);
ElMessage.error('请检查表单数据格式');
} }
} }
//================== ========================= //================== =========================

Loading…
Cancel
Save