|
|
@ -136,7 +136,7 @@ |
|
|
|
>享受福利</el-checkbox |
|
|
|
> |
|
|
|
<el-checkbox |
|
|
|
v-model="fmData.isResiUser" |
|
|
|
v-model="fmData.isCheck" |
|
|
|
true-label="1" |
|
|
|
false-label="0" |
|
|
|
@change="checkResiAvailable" |
|
|
@ -292,7 +292,7 @@ |
|
|
|
|
|
|
|
<el-form-item |
|
|
|
label="户主姓名" |
|
|
|
prop="houseHolderName" |
|
|
|
prop="householderName" |
|
|
|
label-width="150px" |
|
|
|
style="display: block" |
|
|
|
> |
|
|
@ -302,19 +302,19 @@ |
|
|
|
show-word-limit |
|
|
|
placeholder="请输入户主姓名" |
|
|
|
:disabled="fmData.alreadyHaveMaster" |
|
|
|
v-model="fmData.houseHolderName" |
|
|
|
v-model="fmData.householderName" |
|
|
|
> |
|
|
|
</el-input> |
|
|
|
</el-form-item> |
|
|
|
|
|
|
|
<el-form-item |
|
|
|
label="与户主关系" |
|
|
|
prop="houseHolderRelation" |
|
|
|
prop="householderRelation" |
|
|
|
label-width="150px" |
|
|
|
style="display: block" |
|
|
|
> |
|
|
|
<el-select |
|
|
|
v-model.trim="fmData.houseHolderRelation" |
|
|
|
v-model.trim="fmData.householderRelation" |
|
|
|
placeholder="与户主关系" |
|
|
|
size="small" |
|
|
|
clearable |
|
|
@ -365,21 +365,17 @@ |
|
|
|
</template> |
|
|
|
|
|
|
|
<script> |
|
|
|
import { mapGetters } from "vuex"; |
|
|
|
import { Loading } from "element-ui"; // 引入Loading服务 |
|
|
|
import { requestPost } from "@/js/dai/request"; |
|
|
|
import formVltHelper from "dai-js/tools/formVltHelper"; |
|
|
|
import { computedCard } from "@/utils/index"; |
|
|
|
import { isCard, isMobile } from "@/utils/validate"; |
|
|
|
import { isCard } from "@/utils/validate"; |
|
|
|
|
|
|
|
var map; |
|
|
|
var search; |
|
|
|
var markers; |
|
|
|
var infoWindowList; |
|
|
|
let loading; // 加载动画 |
|
|
|
|
|
|
|
function iniFmData() { |
|
|
|
return { |
|
|
|
id: "", |
|
|
|
gridId: "", |
|
|
|
villageId: "", |
|
|
|
buildId: "", |
|
|
@ -389,15 +385,15 @@ function iniFmData() { |
|
|
|
mobile: "", |
|
|
|
idCard: "", |
|
|
|
isWelfare: "0", //福利0否,1是 |
|
|
|
isResiUser: "0", |
|
|
|
isCheck: "0", |
|
|
|
gender: "", |
|
|
|
birthplace: "", |
|
|
|
father: "", |
|
|
|
mother: "", |
|
|
|
count: "", |
|
|
|
reportDate: "", |
|
|
|
houseHolderName: "", |
|
|
|
houseHolderRelation: "", |
|
|
|
householderName: "", |
|
|
|
householderRelation: "", |
|
|
|
alreadyHaveMaster: false, |
|
|
|
}; |
|
|
|
} |
|
|
@ -483,9 +479,9 @@ export default { |
|
|
|
methods: { |
|
|
|
async checkResiAvailable() { |
|
|
|
const { |
|
|
|
fmData: { idCard, isResiUser }, |
|
|
|
fmData: { idCard, isCheck }, |
|
|
|
} = this; |
|
|
|
if (isResiUser == "1" && isCard(idCard)) { |
|
|
|
if (isCheck == "1" && isCard(idCard)) { |
|
|
|
const { data, code, msg } = await requestPost( |
|
|
|
"/epmetuser/icresiuser/checkuser", |
|
|
|
{ |
|
|
@ -680,7 +676,7 @@ export default { |
|
|
|
console.log("获取户主信息成功", res.data); |
|
|
|
const { name } = res.data; |
|
|
|
if (name) { |
|
|
|
this.fmData.houseHolderName = name; |
|
|
|
this.fmData.householderName = name; |
|
|
|
this.alreadyHaveMaster = true; |
|
|
|
} else { |
|
|
|
this.alreadyHaveMaster = false; |
|
|
@ -692,25 +688,28 @@ export default { |
|
|
|
}); |
|
|
|
}, |
|
|
|
|
|
|
|
handleAddStaff() { |
|
|
|
this.fmData.organizationPersonnel = [ |
|
|
|
...this.fmData.organizationPersonnel, |
|
|
|
{ personName: "", personPhone: "" }, |
|
|
|
]; |
|
|
|
}, |
|
|
|
handleDelStaff(index) { |
|
|
|
const { organizationPersonnel } = this.fmData; |
|
|
|
organizationPersonnel.splice(index, 1); |
|
|
|
this.fmData.organizationPersonnel = organizationPersonnel; |
|
|
|
}, |
|
|
|
|
|
|
|
async initForm(type, row) { |
|
|
|
this.$refs.ref_form.resetFields(); |
|
|
|
|
|
|
|
this.formType = type; |
|
|
|
console.log(row); |
|
|
|
if (row) { |
|
|
|
this.fmData = { ...this.fmData, ...row }; |
|
|
|
// this.fmData = { ...this.fmData, ...row }; |
|
|
|
this.getInfo(row.id); |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
async getInfo(id) { |
|
|
|
const { data, code, msg } = await requestPost( |
|
|
|
"/epmetuser/icBirthRecord", |
|
|
|
{ |
|
|
|
id, |
|
|
|
} |
|
|
|
); |
|
|
|
if (code === 0) { |
|
|
|
this.fmData = { ...this.fmData, ...data }; |
|
|
|
} else { |
|
|
|
this.$message.error(msg); |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
@ -738,9 +737,9 @@ export default { |
|
|
|
async submit() { |
|
|
|
let url = ""; |
|
|
|
if (this.formType === "add") { |
|
|
|
url = "/epmetuser/birth/save"; |
|
|
|
url = "/epmetuser/icBirthRecord/save"; |
|
|
|
} else { |
|
|
|
url = "/epmetuser/birth/edit"; |
|
|
|
url = "/epmetuser/icBirthRecord/update"; |
|
|
|
|
|
|
|
this.fmData.orgId = this.orgId; |
|
|
|
} |
|
|
|