| @@ -248,6 +248,16 @@ | |||||
| }); | }); | ||||
| }, | }, | ||||
| submitForm() { | submitForm() { | ||||
| let householdStatus = Cookies.get('householdStatus'); | |||||
| if (householdStatus !== '1') { | |||||
| let msg = '当前承包方已' + Cookies.get('householdStatusText') + ',不能保存承包合同信息'; | |||||
| this.$toast({ | |||||
| icon: 'fail', // 找到自己需要的图标 | |||||
| message: msg, | |||||
| duration:"2000" | |||||
| }); | |||||
| return; | |||||
| } | |||||
| this.$refs.formData.validate().then(() => { | this.$refs.formData.validate().then(() => { | ||||
| if (this.form.id) { | if (this.form.id) { | ||||
| updateCbht(this.form).then(response => { | updateCbht(this.form).then(response => { | ||||
| @@ -71,28 +71,26 @@ | |||||
| <van-field v-model="form.yzbm" label="邮编:" placeholder="请输入邮编" required :rules="[{ required: true }]" :border="false" input-align="left" maxlength="6" /> | <van-field v-model="form.yzbm" label="邮编:" placeholder="请输入邮编" required :rules="[{ required: true }]" :border="false" input-align="left" maxlength="6" /> | ||||
| <van-field v-model="form.lxdh" label="电话:" placeholder="请输入电话" required :rules="[{ required: true }]" :border="false" input-align="left" maxlength="15" /> | <van-field v-model="form.lxdh" label="电话:" placeholder="请输入电话" required :rules="[{ required: true }]" :border="false" input-align="left" maxlength="15" /> | ||||
| <van-field v-model="form.cbfcysl" label="成员数量:" placeholder="请输入成员数量" required :rules="[{ required: true }]" :border="false" input-align="left" type="number" /> | <van-field v-model="form.cbfcysl" label="成员数量:" placeholder="请输入成员数量" required :rules="[{ required: true }]" :border="false" input-align="left" type="number" /> | ||||
| <FieldRadio | |||||
| v-model="form.sfyzf" | |||||
| label="是否有住房" | |||||
| value-key="dictLabel" | |||||
| data-key="dictValue" | |||||
| remote-url="/open/zdzh/list/sys_yes_no" | |||||
| :on-remote-response="'data'" | |||||
| /> | |||||
| <FieldRadio | |||||
| v-model="form.sfzcjz" | |||||
| label="是否在村居住" | |||||
| value-key="dictLabel" | |||||
| data-key="dictValue" | |||||
| remote-url="/open/zdzh/list/sys_yes_no" | |||||
| :on-remote-response="'data'" | |||||
| /> | |||||
| <van-field name="radio" label="是否有住房" :border="false" input-align="left"> | |||||
| <template #input> | |||||
| <van-radio-group v-model="form.sfyzf" direction="horizontal"> | |||||
| <van-radio name="Y">是</van-radio> | |||||
| <van-radio name="N">否</van-radio> | |||||
| </van-radio-group> | |||||
| </template> | |||||
| </van-field> | |||||
| <van-field name="radio" label="是否在村居住" :border="false" input-align="left"> | |||||
| <template #input> | |||||
| <van-radio-group v-model="form.sfzcjz" direction="horizontal"> | |||||
| <van-radio name="Y">是</van-radio> | |||||
| <van-radio name="N">否</van-radio> | |||||
| </van-radio-group> | |||||
| </template> | |||||
| </van-field> | |||||
| <van-field | <van-field | ||||
| v-model="form.householdStatusText" | v-model="form.householdStatusText" | ||||
| label="整户状态:" | label="整户状态:" | ||||
| placeholder="请选择整户状态" | placeholder="请选择整户状态" | ||||
| required | |||||
| :rules="[{ required: true }]" | |||||
| :border="false" | :border="false" | ||||
| input-align="left" | input-align="left" | ||||
| right-icon="arrow-down" | right-icon="arrow-down" | ||||
| @@ -211,6 +209,8 @@ | |||||
| this.$set(this.form, 'cbflxText', this.selectDictLabel(this.contractorTypeOptions, response.data.cbflx)); | this.$set(this.form, 'cbflxText', this.selectDictLabel(this.contractorTypeOptions, response.data.cbflx)); | ||||
| this.$set(this.form, 'cbfzjlxText', this.selectDictLabel(this.credentialTypeOptions, response.data.cbfzjlx)); | this.$set(this.form, 'cbfzjlxText', this.selectDictLabel(this.credentialTypeOptions, response.data.cbfzjlx)); | ||||
| this.$set(this.form, 'householdStatusText', this.selectDictLabel(this.householdStatusOptions, response.data.householdStatus)); | this.$set(this.form, 'householdStatusText', this.selectDictLabel(this.householdStatusOptions, response.data.householdStatus)); | ||||
| Cookies.set('householdStatus', this.form.householdStatus, { expires: 30 }); | |||||
| Cookies.set('householdStatusText', this.form.householdStatusText, { expires: 30 }); | |||||
| }); | }); | ||||
| }, | }, | ||||
| onConfirmTypeOptions(value){ | onConfirmTypeOptions(value){ | ||||
| @@ -67,22 +67,22 @@ | |||||
| <van-field v-model="form.yzbm" label="邮编:" placeholder="请输入邮编" required :rules="[{ required: true }]" :border="false" input-align="left" maxlength="6" /> | <van-field v-model="form.yzbm" label="邮编:" placeholder="请输入邮编" required :rules="[{ required: true }]" :border="false" input-align="left" maxlength="6" /> | ||||
| <van-field v-model="form.lxdh" label="电话:" placeholder="请输入电话" required :rules="[{ required: true }]" :border="false" input-align="left" maxlength="15" /> | <van-field v-model="form.lxdh" label="电话:" placeholder="请输入电话" required :rules="[{ required: true }]" :border="false" input-align="left" maxlength="15" /> | ||||
| <van-field v-model="form.cbfcysl" label="成员数量:" placeholder="请输入成员数量" required :rules="[{ required: true }]" :border="false" input-align="left" type="number" /> | <van-field v-model="form.cbfcysl" label="成员数量:" placeholder="请输入成员数量" required :rules="[{ required: true }]" :border="false" input-align="left" type="number" /> | ||||
| <FieldRadio | |||||
| v-model="form.sfyzf" | |||||
| label="是否有住房" | |||||
| value-key="dictLabel" | |||||
| data-key="dictValue" | |||||
| remote-url="/open/zdzh/list/sys_yes_no" | |||||
| :on-remote-response="'data'" | |||||
| /> | |||||
| <FieldRadio | |||||
| v-model="form.sfzcjz" | |||||
| label="是否在村居住" | |||||
| value-key="dictLabel" | |||||
| data-key="dictValue" | |||||
| remote-url="/open/zdzh/list/sys_yes_no" | |||||
| :on-remote-response="'data'" | |||||
| /> | |||||
| <van-field name="radio" label="是否有住房" :border="false" input-align="left"> | |||||
| <template #input> | |||||
| <van-radio-group v-model="form.sfyzf" direction="horizontal"> | |||||
| <van-radio name="Y">是</van-radio> | |||||
| <van-radio name="N">否</van-radio> | |||||
| </van-radio-group> | |||||
| </template> | |||||
| </van-field> | |||||
| <van-field name="radio" label="是否在村居住" :border="false" input-align="left"> | |||||
| <template #input> | |||||
| <van-radio-group v-model="form.sfzcjz" direction="horizontal"> | |||||
| <van-radio name="Y">是</van-radio> | |||||
| <van-radio name="N">否</van-radio> | |||||
| </van-radio-group> | |||||
| </template> | |||||
| </van-field> | |||||
| <van-field | <van-field | ||||
| v-model="householdStatusText" | v-model="householdStatusText" | ||||
| label="整户状态:" | label="整户状态:" | ||||
| @@ -59,8 +59,8 @@ | |||||
| </div> | </div> | ||||
| </template> | </template> | ||||
| </van-swipe-cell> | </van-swipe-cell> | ||||
| <!-- getDetail不加(), 第一个参数默认传递的是event,getDetail加(), 需要手动传递$event --> | |||||
| <p class="btn" @click="goDetail()" v-if="taskStatus === '2' && $route.params.surveyStatus !== '3'">新增</p> | |||||
| <!-- addMember不加(), 第一个参数默认传递的是event,addMember加(), 需要手动传递$event --> | |||||
| <p class="btn" @click="addMember()" v-if="taskStatus === '2' && $route.params.surveyStatus !== '3'">新增</p> | |||||
| </div> | </div> | ||||
| <van-popup v-model="showContractorPopup" position="bottom"> | <van-popup v-model="showContractorPopup" position="bottom"> | ||||
| <van-search v-model="searchKeyword" placeholder="请输入姓名搜索" /> | <van-search v-model="searchKeyword" placeholder="请输入姓名搜索" /> | ||||
| @@ -135,6 +135,28 @@ | |||||
| } | } | ||||
| }); | }); | ||||
| }, | }, | ||||
| addMember() { | |||||
| let householdStatus = Cookies.get('householdStatus'); | |||||
| if (householdStatus !== '1') { | |||||
| let msg = '当前承包方已' + Cookies.get('householdStatusText') + ',不能新增家庭成员信息'; | |||||
| this.$toast({ | |||||
| icon: 'fail', // 找到自己需要的图标 | |||||
| message: msg, | |||||
| duration:"2000" | |||||
| }); | |||||
| return; | |||||
| } | |||||
| this.$router.push({ | |||||
| name: 'contractedVillageContractorFamilyDetail', | |||||
| params: { | |||||
| id: undefined, | |||||
| deptId: this.$route.params.deptId, | |||||
| cbfbm: this.$route.params.cbfbm, | |||||
| cbfmc: this.$route.params.cbfmc, | |||||
| surveyStatus: this.$route.params.surveyStatus | |||||
| } | |||||
| }); | |||||
| }, | |||||
| goDetail(id) { | goDetail(id) { | ||||
| this.$router.push({ | this.$router.push({ | ||||
| name: 'contractedVillageContractorFamilyDetail', | name: 'contractedVillageContractorFamilyDetail', | ||||
| @@ -148,6 +170,16 @@ | |||||
| }); | }); | ||||
| }, | }, | ||||
| deleteFamilyMember(id, index) { | deleteFamilyMember(id, index) { | ||||
| let householdStatus = Cookies.get('householdStatus'); | |||||
| if (householdStatus !== '1') { | |||||
| let msg = '当前承包方已' + Cookies.get('householdStatusText') + ',不能删除家庭成员信息'; | |||||
| this.$toast({ | |||||
| icon: 'fail', // 找到自己需要的图标 | |||||
| message: msg, | |||||
| duration:"2000" | |||||
| }); | |||||
| return; | |||||
| } | |||||
| this.$dialog.confirm({ | this.$dialog.confirm({ | ||||
| message: '是否确认删除此条家庭成员信息?', | message: '是否确认删除此条家庭成员信息?', | ||||
| }).then(() => { | }).then(() => { | ||||
| @@ -163,6 +195,16 @@ | |||||
| }); | }); | ||||
| }, | }, | ||||
| householdDivision(item, index) { | householdDivision(item, index) { | ||||
| let householdStatus = Cookies.get('householdStatus'); | |||||
| if (householdStatus !== '1') { | |||||
| let msg = '当前承包方已' + Cookies.get('householdStatusText') + ',不能执行分户操作'; | |||||
| this.$toast({ | |||||
| icon: 'fail', // 找到自己需要的图标 | |||||
| message: msg, | |||||
| duration:"2000" | |||||
| }); | |||||
| return; | |||||
| } | |||||
| if (item.yhzgx === '户主') { | if (item.yhzgx === '户主') { | ||||
| this.$toast.fail('该成员身份为户主,不能分户'); | this.$toast.fail('该成员身份为户主,不能分户'); | ||||
| return false; | return false; | ||||
| @@ -188,6 +230,16 @@ | |||||
| }); | }); | ||||
| }, | }, | ||||
| householdTransfer(item) { | householdTransfer(item) { | ||||
| let householdStatus = Cookies.get('householdStatus'); | |||||
| if (householdStatus !== '1') { | |||||
| let msg = '当前承包方已' + Cookies.get('householdStatusText') + ',不能执行移户操作'; | |||||
| this.$toast({ | |||||
| icon: 'fail', // 找到自己需要的图标 | |||||
| message: msg, | |||||
| duration:"2000" | |||||
| }); | |||||
| return; | |||||
| } | |||||
| if (item.yhzgx === '户主') { | if (item.yhzgx === '户主') { | ||||
| this.$toast.fail('该成员身份为户主,不能移户'); | this.$toast.fail('该成员身份为户主,不能移户'); | ||||
| return false; | return false; | ||||
| @@ -220,6 +272,16 @@ | |||||
| }); | }); | ||||
| }, | }, | ||||
| houseHolder(item) { | houseHolder(item) { | ||||
| let householdStatus = Cookies.get('householdStatus'); | |||||
| if (householdStatus !== '1') { | |||||
| let msg = '当前承包方已' + Cookies.get('householdStatusText') + ',不能执行设为户主操作'; | |||||
| this.$toast({ | |||||
| icon: 'fail', // 找到自己需要的图标 | |||||
| message: msg, | |||||
| duration:"2000" | |||||
| }); | |||||
| return; | |||||
| } | |||||
| if (item.yhzgx === '户主') { | if (item.yhzgx === '户主') { | ||||
| this.$toast.fail('该成员身份为户主,无需设置'); | this.$toast.fail('该成员身份为户主,无需设置'); | ||||
| return false; | return false; | ||||
| @@ -138,7 +138,7 @@ | |||||
| <van-field v-model="form.elcbshjd" class="elcbshjd_css" label="二轮承包时户籍地:" placeholder="请输入二轮承包时户籍地" :border="false" input-align="right" maxlength="100" /> | <van-field v-model="form.elcbshjd" class="elcbshjd_css" label="二轮承包时户籍地:" placeholder="请输入二轮承包时户籍地" :border="false" input-align="right" maxlength="100" /> | ||||
| <van-field v-model="form.xhjd" label="现户籍地:" placeholder="请输入现户籍地" :border="false" input-align="right" maxlength="100" /> | <van-field v-model="form.xhjd" label="现户籍地:" placeholder="请输入现户籍地" :border="false" input-align="right" maxlength="100" /> | ||||
| <field-select | |||||
| <!-- <field-select | |||||
| v-model="form.householdStatus" | v-model="form.householdStatus" | ||||
| label="整户状态:" | label="整户状态:" | ||||
| value-key="dictLabel" | value-key="dictLabel" | ||||
| @@ -146,7 +146,7 @@ | |||||
| placeholder="请选择整户状态" | placeholder="请选择整户状态" | ||||
| remote-url="/open/zdzh/list/household_status" | remote-url="/open/zdzh/list/household_status" | ||||
| :on-remote-response="'data'" | :on-remote-response="'data'" | ||||
| /> | |||||
| /> --> | |||||
| <van-field | <van-field | ||||
| v-model="cybzText" | v-model="cybzText" | ||||
| label="成员备注:" | label="成员备注:" | ||||
| @@ -279,6 +279,18 @@ | |||||
| }); | }); | ||||
| }, | }, | ||||
| submitForm() { | submitForm() { | ||||
| if (this.$route.params.id) { | |||||
| let householdStatus = Cookies.get('householdStatus'); | |||||
| if (householdStatus !== '1') { | |||||
| let msg = '当前承包方已' + Cookies.get('householdStatusText') + ',不能修改家庭成员信息'; | |||||
| this.$toast({ | |||||
| icon: 'fail', // 找到自己需要的图标 | |||||
| message: msg, | |||||
| duration:"2000" | |||||
| }); | |||||
| return; | |||||
| } | |||||
| } | |||||
| this.$refs.formData.validate().then(() => { | this.$refs.formData.validate().then(() => { | ||||
| if (this.$route.params.id) { | if (this.$route.params.id) { | ||||
| updateJtcy(this.form).then(response => { | updateJtcy(this.form).then(response => { | ||||
| @@ -340,7 +352,7 @@ | |||||
| xhjd: null, | xhjd: null, | ||||
| wdyy: null, | wdyy: null, | ||||
| sfhdr: 'N', | sfhdr: 'N', | ||||
| householdStatus: '1', | |||||
| // householdStatus: '1', | |||||
| }; | }; | ||||
| this.cyzjlxText = '居民身份证'; | this.cyzjlxText = '居民身份证'; | ||||
| } | } | ||||
| @@ -45,6 +45,7 @@ | |||||
| import { contractorSignature, hangUp } from "@/api/contracted/cbf"; | import { contractorSignature, hangUp } from "@/api/contracted/cbf"; | ||||
| import vueEsign from "vue-esign"; | import vueEsign from "vue-esign"; | ||||
| import $ from "jquery"; | import $ from "jquery"; | ||||
| import Cookies from "js-cookie"; | |||||
| export default { | export default { | ||||
| name: 'contractedVillageHeader', | name: 'contractedVillageHeader', | ||||
| @@ -86,6 +87,8 @@ | |||||
| goBack() { | goBack() { | ||||
| getDept(this.deptId).then(response => { | getDept(this.deptId).then(response => { | ||||
| this.$router.push({path:'/contracted/village/contractor', query: { deptId: this.deptId, deptName: response.data.deptName }}); | this.$router.push({path:'/contracted/village/contractor', query: { deptId: this.deptId, deptName: response.data.deptName }}); | ||||
| Cookies.remove('householdStatus'); | |||||
| Cookies.remove('householdStatusText'); | |||||
| }); | }); | ||||
| }, | }, | ||||
| handleSign() { | handleSign() { | ||||