|
|
@ -3,7 +3,7 @@ |
|
|
|
<view class="top-bg"></view> |
|
|
|
<view class="container"> |
|
|
|
<u-form :model="form" ref="uForm" label-width="90"> |
|
|
|
<view class="info-card"> |
|
|
|
<!-- <view class="info-card"> |
|
|
|
<u-form-item prop="idCard"> |
|
|
|
<u-search |
|
|
|
placeholder="请输入身份证号" |
|
|
@ -17,33 +17,59 @@ |
|
|
|
@clickIcon="handleQuery" |
|
|
|
></u-search> |
|
|
|
</u-form-item> |
|
|
|
</view> |
|
|
|
</view> --> |
|
|
|
|
|
|
|
<view class="cont" v-if="showInfo"> |
|
|
|
<view class="info-card info-item"> |
|
|
|
<u-form-item label="姓名" prop="name" required borderBottom labelStyle="{color:red;}"> |
|
|
|
<text style="text-align: right">{{ baseInfo.graduateName }}</text> |
|
|
|
<u-form-item label="房间" prop="room" borderBottom> |
|
|
|
<text style="text-align: right" |
|
|
|
>{{ baseInfo.buildingName || "" }}{{ baseInfo.unitName || "" |
|
|
|
}}{{ baseInfo.houseName || "" |
|
|
|
}}{{ baseInfo.roomTypeName || "" }}</text |
|
|
|
> |
|
|
|
|
|
|
|
<!-- <u-input |
|
|
|
v-model="baseInfo.graduateName" |
|
|
|
placeholder="请输入姓名" |
|
|
|
v-model="roomAllPath" |
|
|
|
placeholder="请输入房间" |
|
|
|
border="none" |
|
|
|
input-align="right" |
|
|
|
:disabled="true" |
|
|
|
/> --> |
|
|
|
</u-form-item> |
|
|
|
<u-form-item label="房间" prop="room" required borderBottom> |
|
|
|
<text style="text-align: right">{{ roomAllPath }}</text> |
|
|
|
<u-form-item |
|
|
|
label="姓名" |
|
|
|
prop="name" |
|
|
|
borderBottom |
|
|
|
labelStyle="{color:red;}" |
|
|
|
> |
|
|
|
<text style="text-align: right">{{ |
|
|
|
baseInfo.graduateName || "" |
|
|
|
}}</text> |
|
|
|
|
|
|
|
<!-- <u-input |
|
|
|
v-model="roomAllPath" |
|
|
|
placeholder="请输入房间" |
|
|
|
v-model="baseInfo.graduateName" |
|
|
|
placeholder="请输入姓名" |
|
|
|
border="none" |
|
|
|
input-align="right" |
|
|
|
:disabled="true" |
|
|
|
/> --> |
|
|
|
</u-form-item> |
|
|
|
<u-form-item label="手机号" prop="phone" required borderBottom> |
|
|
|
<text style="text-align: right">{{ baseInfo.telephone }}</text> |
|
|
|
<!-- 性别 --> |
|
|
|
<u-form-item |
|
|
|
label="性别" |
|
|
|
prop="gender" |
|
|
|
borderBottom |
|
|
|
labelStyle="{color:red;}" |
|
|
|
> |
|
|
|
<text style="text-align: right">{{ |
|
|
|
baseInfo.gender == 1 ? "男" : baseInfo.gender == 2 ? "女" : "" |
|
|
|
}}</text></u-form-item |
|
|
|
> |
|
|
|
|
|
|
|
<u-form-item label="手机号" prop="phone" borderBottom> |
|
|
|
<text style="text-align: right">{{ |
|
|
|
baseInfo.telephone || "" |
|
|
|
}}</text> |
|
|
|
|
|
|
|
<!-- <u-input |
|
|
|
v-model="baseInfo.telephone" |
|
|
@ -151,7 +177,13 @@ |
|
|
|
</template> |
|
|
|
|
|
|
|
<script> |
|
|
|
import { uploadImage, getResidentInfo, forceRelease } from "../../../pages/api"; |
|
|
|
import { |
|
|
|
uploadImage, |
|
|
|
getResidentInfo, |
|
|
|
forceRelease, |
|
|
|
getRecCheckOutInfo, |
|
|
|
updateForceEvictionRecord, |
|
|
|
} from "../../../pages/api"; |
|
|
|
export default { |
|
|
|
data() { |
|
|
|
return { |
|
|
@ -199,9 +231,25 @@ export default { |
|
|
|
}`; |
|
|
|
}, |
|
|
|
}, |
|
|
|
onLoad(options) { |
|
|
|
this.form.idCard = options.idCard; |
|
|
|
this.form.checkOutRecId = options.checkOutRecId; |
|
|
|
this.getRecCheckOutInfo(options.checkOutRecId); |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
getRecCheckOutInfo(checkOutRecId) { |
|
|
|
getRecCheckOutInfo(checkOutRecId).then((res) => { |
|
|
|
this.baseInfo = res.data; |
|
|
|
if (this.baseInfo) { |
|
|
|
this.showInfo = true; |
|
|
|
} |
|
|
|
this.baseInfo.roomId = res.data.mzCheckOutRec.roomId; |
|
|
|
this.baseInfo.checkOutRecId = checkOutRecId; |
|
|
|
this.forceCheckoutDesc = res.data.forcedEvictionRecord.content; |
|
|
|
this.fileList = res.data.forcedEvictionRecord.attrList; |
|
|
|
}); |
|
|
|
}, |
|
|
|
handleQuery() { |
|
|
|
console.log("查询参数:", this.form); |
|
|
|
getResidentInfo({ |
|
|
|
idCard: this.form.idCard, |
|
|
|
}).then((res) => { |
|
|
@ -303,17 +351,31 @@ export default { |
|
|
|
this.showProblemTypePicker = false; |
|
|
|
}, |
|
|
|
submit() { |
|
|
|
const params = { |
|
|
|
// idCard: this.baseInfo.idCard, |
|
|
|
chooseRoomRecId: this.baseInfo.chooseRecId, |
|
|
|
checkOutType: 1, //0正常退房1强制退房 |
|
|
|
// questionType: this.form.problemTypeValue, |
|
|
|
content: this.forceCheckoutDesc, |
|
|
|
imageList: this.fileList, //退房检查图片 |
|
|
|
}; |
|
|
|
console.log(params, "params"); |
|
|
|
if ( |
|
|
|
this.baseInfo.forcedEvictionRecord && |
|
|
|
this.baseInfo.forcedEvictionRecord.id |
|
|
|
) { |
|
|
|
// 避免直接修改响应式对象,创建新对象传参 |
|
|
|
let params = { |
|
|
|
...this.baseInfo.forcedEvictionRecord, |
|
|
|
content: this.forceCheckoutDesc, |
|
|
|
attrList: this.fileList, |
|
|
|
id: this.baseInfo.forcedEvictionRecord.id, |
|
|
|
checkOutRecId: this.baseInfo.checkOutRecId, |
|
|
|
}; |
|
|
|
this.updateForceEvictionRecord(params); |
|
|
|
} else { |
|
|
|
const params = { |
|
|
|
// idCard: this.baseInfo.idCard, |
|
|
|
checkOutRecId: Number(this.baseInfo.checkOutRecId), |
|
|
|
checkOutType: 1, //0正常退房1强制退房 |
|
|
|
// questionType: this.form.problemTypeValue, |
|
|
|
content: this.forceCheckoutDesc, |
|
|
|
attrList: this.fileList, //退房检查图片 |
|
|
|
}; |
|
|
|
|
|
|
|
this.handleTempSave(params); |
|
|
|
this.handleTempSave(params); |
|
|
|
} |
|
|
|
}, |
|
|
|
handleTempSave(params) { |
|
|
|
forceRelease(params).then((res) => { |
|
|
@ -335,6 +397,16 @@ export default { |
|
|
|
} |
|
|
|
}); |
|
|
|
}, |
|
|
|
updateForceEvictionRecord(params) { |
|
|
|
updateForceEvictionRecord(params).then((res) => { |
|
|
|
if (res.code === 200) { |
|
|
|
uni.showToast({ |
|
|
|
title: res.msg, |
|
|
|
icon: "success", |
|
|
|
}); |
|
|
|
} |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
}; |
|
|
|
</script> |
|
|
@ -365,7 +437,7 @@ export default { |
|
|
|
margin-bottom: 24rpx; |
|
|
|
box-shadow: 0 4rpx 16rpx 0 #e6f6fd; |
|
|
|
} |
|
|
|
.info-item{ |
|
|
|
.info-item { |
|
|
|
padding: 0 34rpx; |
|
|
|
} |
|
|
|
|
|
|
@ -478,7 +550,10 @@ export default { |
|
|
|
margin-top: 8rpx; |
|
|
|
} |
|
|
|
|
|
|
|
::v-deep .u-form-item .u-form-item__body__left .u-form-item__body__left__content__label { |
|
|
|
::v-deep |
|
|
|
.u-form-item |
|
|
|
.u-form-item__body__left |
|
|
|
.u-form-item__body__left__content__label { |
|
|
|
color: #68758b !important; |
|
|
|
font-size: 28rpx; |
|
|
|
} |
|
|
|