Browse Source

Merge branch 'dev-huji' of http://git.elinkit.com.cn:7070/r/epmet-oper-gov into dev-huji

shibei_master
13176889840 3 years ago
parent
commit
cde8e0c289
  1. 63
      src/views/modules/base/huji/chusheng/cpts/edit.vue
  2. 13
      src/views/modules/base/huji/chusheng/index.vue
  3. 485
      src/views/modules/base/huji/houseChange/houseChangeList.vue

63
src/views/modules/base/huji/chusheng/cpts/edit.vue

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

13
src/views/modules/base/huji/chusheng/index.vue

@ -159,7 +159,7 @@
<el-form-item label="享受福利" prop="remark"> <el-form-item label="享受福利" prop="remark">
<el-select <el-select
v-model.trim="fmData.welfare" v-model.trim="fmData.isWelfare"
placeholder="享受福利" placeholder="享受福利"
size="small" size="small"
clearable clearable
@ -303,11 +303,11 @@
<el-table-column prop="reportDate" align="center" label="申报户口日期"> <el-table-column prop="reportDate" align="center" label="申报户口日期">
</el-table-column> </el-table-column>
<el-table-column prop="houseHolderName" align="center" label="户主姓名"> <el-table-column prop="householderName" align="center" label="户主姓名">
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="houseHolderRelation" prop="householderRelation"
align="center" align="center"
label="与户主关系" label="与户主关系"
> >
@ -435,7 +435,7 @@ export default {
name: "", name: "",
mobile: "", mobile: "",
idCard: "", idCard: "",
welfare: "", //01 isWelfare: "", //01
birthdayStart: "", birthdayStart: "",
birthdayEnd: "", birthdayEnd: "",
birthdayTime: ["", ""], birthdayTime: ["", ""],
@ -764,8 +764,7 @@ export default {
}, },
async handleChu() { async handleChu() {
const url = const url = "/epmetuser/icBirthRecord/export";
"/heart/iccommunityselforganization/exportcommunityselforganization";
const { pageSize, pageNo, fmData } = this; const { pageSize, pageNo, fmData } = this;
axios({ axios({
url: window.SITE_CONFIG["apiURL"] + url, url: window.SITE_CONFIG["apiURL"] + url,
@ -834,7 +833,7 @@ export default {
}, },
async getTableData() { async getTableData() {
const url = "/epmetuser/birth/page"; const url = "/epmetuser/icBirthRecord/page";
const { pageSize, pageNo, fmData } = this; const { pageSize, pageNo, fmData } = this;
const { data, code, msg } = await requestPost(url, { const { data, code, msg } = await requestPost(url, {
pageSize, pageSize,

485
src/views/modules/base/huji/houseChange/houseChangeList.vue

@ -0,0 +1,485 @@
<template>
<div class="div_main">
<div class="div_search">
<el-form :inline="true"
:model="formData"
ref="ref_searchform"
:label-width="'90px'">
<div>
<el-form-item label="所属网格"
prop="gridId">
<el-select class="item_width_1"
v-model="formData.gridId"
placeholder="全部"
size="small"
@change="handleChangeG"
clearable>
<el-option v-for="item in gridList"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
<el-form-item label="所属房屋">
<div class="resi-cell-value">
<div class="resi-cell-col">
<el-form-item prop="neighborHoodId">
<el-select v-model.trim="formData.neighborHoodId"
:disabled="!this.formData.gridId"
placeholder="小区"
size="small"
clearable
class="resi-cell-select"
@change="handleChangeV">
<el-option v-for="item in optionsV"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
<el-form-item prop="buildingId">
<el-select v-model.trim="formData.buildingId"
placeholder="楼号"
:disabled="!this.formData.neighborHoodId"
size="small"
clearable
class="resi-cell-select resi-cell-select-middle list_item_width_1"
@change="handleChangeB">
<el-option v-for="item in optionsB"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
<el-form-item prop="buildingUnitId">
<el-select v-model.trim="formData.buildingUnitId"
placeholder="单元"
size="small"
:disabled="!this.formData.buildingId"
clearable
class="resi-cell-select resi-cell-select-middle list_item_width_1"
@change="handleChangeD">
<el-option v-for="item in optionsD"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
<el-form-item prop="houseId">
<el-select v-model.trim="formData.houseId"
placeholder="房号"
:disabled="!this.formData.buildingUnitId"
size="small"
clearable
class="resi-cell-select resi-cell-select-middle list_item_width_1">
<el-option v-for="item in optionsH"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
</div>
</div>
</el-form-item>
</div>
<div>
<el-form-item label="变更时间"
prop="startDate">
<el-date-picker v-model="timeRange"
size="small"
type="daterange"
value-format="yyyy-MM-dd"
@change="handleTimeChange"
range-separator="至"
start-placeholder="开始时间"
end-placeholder="结束时间">
</el-date-picker>
</el-form-item>
<el-button style="margin-left:30px"
size="small"
class="diy-button--search"
@click="handleSearch">查询</el-button>
<el-button style="margin-left:10px"
size="small"
class="diy-button--reset"
@click="resetSearch">重置</el-button>
</div>
</el-form>
</div>
<div class="div_table">
<el-table ref="ref_table"
class="table"
:data="tableData"
border
:height="tableHeight"
v-loading="tableLoading"
:header-cell-style="{background:'#2195FE',color:'#FFFFFF'}"
style="width: 100%">
<el-table-column label="序号"
header-align="center"
align="center"
type="index"
width="50"></el-table-column>
<el-table-column prop="gridName"
header-align="center"
align="center"
show-overflow-tooltip
label="所属网格"
min-width="150">
</el-table-column>
<el-table-column prop="houseName"
header-align="center"
align="center"
show-overflow-tooltip
label="所属房屋"
min-width="150">
</el-table-column>
<el-table-column prop="changeBefore"
header-align="center"
align="center"
show-overflow-tooltip
label="变更前"
min-width="250">
</el-table-column>
<el-table-column prop="changeAfter"
header-align="center"
align="center"
show-overflow-tooltip
label="变更后"
min-width="250">
</el-table-column>
<el-table-column prop="changeTime"
header-align="center"
align="center"
label="变更时间"
width="130">
</el-table-column>
</el-table>
<div>
<el-pagination @size-change="handleSizeChange"
@current-change="handleCurrentChange"
:current-page.sync="pageNo"
:page-sizes="[20, 50, 100, 200]"
:page-size="pageSize"
layout="sizes, prev, pager, next, total"
:total="total">
</el-pagination>
</div>
</div>
</div>
</template>
<script>
import util from '@js/util.js';
import { requestPost } from "@/js/dai/request";
import { mapGetters } from 'vuex'
import { Loading } from 'element-ui' // Loading
let loading //
export default {
data () {
return {
loading: false,
total: 0,
pageSize: 20,
pageNo: 1,
tableLoading: false,
optionsV: [],
optionsB: [],
optionsH: [],
optionsD: [],
tableData: [],
agencyId: '',
gridList: [],//list--
timeRange: [],
formData: {
gridId: '',//Id
neighborHoodId: '',//ID
buildingId: '',//ID
buildingUnitId: '',//ID
houseId: '',//ID
startDate: '',//eg20220510
endDate: '',//eg20220510
}
}
},
components: {
},
async created () {
},
activated () {
this.$refs['ref_table'].doLayout()
},
async mounted () {
const { user } = this.$store.state
this.agencyId = user.agencyId
//
await this.loadGrid()
await this.loadTable()
},
methods: {
handleSearch () {
this.loadTable()
},
async loadGrid () {
const url = "/gov/org/customergrid/gridoption"
let params = {
agencyId: this.agencyId
}
const { data, code, msg } = await requestPost(url, params)
if (code === 0) {
this.gridList = data
} else {
this.$message.error(msg)
}
},
async loadTable () {
this.tableLoading = true
const url = "/gov/org/icHouseChangeRecord/list"
// const url = "http://yapi.elinkservice.cn/mock/245/epmetuser/icEpidemicSpecialAttention/list"
let params = {
pageSize: this.pageSize,
pageNo: this.pageNo,
...this.formData
}
const { data, code, msg } = await requestPost(url, params)
if (code === 0) {
this.total = data.total
this.tableData = data.list
} else {
this.$message.error(msg)
}
this.tableLoading = false
},
handleChangeG (val) {
console.log('val', val)
this.formData.neighborHoodId = ''
this.formData.buildingId = ''
this.formData.buildingUnitId = ''
this.formData.houseId = ''
this.getValiheList()
this.getBuildList()
this.getUniList()
this.getHouseList()
},
handleChangeV (val) {
console.log('val', val)
this.formData.buildingId = ''
this.formData.buildingUnitId = ''
this.formData.houseId = ''
this.getBuildList()
this.getUniList()
this.getHouseList()
},
handleChangeB (val) {
console.log('val', val)
this.formData.buildingUnitId = ''
this.formData.houseId = ''
this.getUniList()
this.getHouseList()
},
handleChangeD () {
this.formData.houseId = ''
this.getHouseList()
},
getValiheList () {
const { user } = this.$store.state
this.$http
.post('/gov/org/icneighborhood/neighborhoodoption', { gridId: this.formData.gridId })
.then(({ data: res }) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
} else {
console.log('获取查询详情成功', res.data)
this.optionsV = res.data
}
})
.catch(() => {
return this.$message.error('网络错误')
})
},
getBuildList () {
this.$http
.post('/gov/org/icbuilding/buildingoption', { neighborHoodId: this.formData.neighborHoodId })
.then(({ data: res }) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
} else {
console.log('获取查询详情成功', res.data)
this.optionsB = res.data
}
})
.catch(() => {
return this.$message.error('网络错误')
})
},
getUniList () {
this.$http
.post('/gov/org/icbuildingunit/unitoption', { buildingId: this.formData.buildingId })
.then(({ data: res }) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
} else {
console.log('获取查询详情成功', res.data)
this.optionsD = res.data
}
})
.catch(() => {
return this.$message.error('网络错误')
})
},
getHouseList () {
this.$http
.post('/gov/org/ichouse/houseoption', { buildingUnitId: this.formData.buildingUnitId })
.then(({ data: res }) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
} else {
console.log('获取查询详情成功', res.data)
this.optionsH = res.data
}
})
.catch(() => {
return this.$message.error('网络错误')
})
},
handleTimeChange (time) {
if (time) {
const startTimeArray = util.dateFormatter(time[0], 'date').split('-')
const endTimeArray = util.dateFormatter(time[1], 'date').split('-')
this.formData.startDate = startTimeArray[0] + startTimeArray[1] + startTimeArray[2]
this.formData.endDate = endTimeArray[0] + endTimeArray[1] + endTimeArray[2]
// this.startTimeShow = startTimeArray[0] + '' + startTimeArray[1] + '' + startTimeArray[2] + ''
// this.endTimeShow = endTimeArray[0] + '' + endTimeArray[1] + '' + endTimeArray[2] + ''
} else {
this.formData.startDate = ''
this.formData.endDate = ''
// this.startTimeShow = ''
// this.endTimeShow = ''
}
},
//
resetSearch () {
this.timeRange = []
this.formData = {
gridId: '',//Id
neighborHoodId: '',//ID
buildingId: '',//ID
buildingUnitId: '',//ID
houseId: '',//ID
startDate: '',//eg20220510
endDate: '',//eg20220510
}
this.pageNo = 1
// this.loadTable()
},
handleSizeChange (val) {
this.pageSize = val
this.pageNo = 1
this.loadTable()
},
handleCurrentChange (val) {
this.pageNo = val
this.loadTable()
},
//
startLoading () {
loading = Loading.service({
lock: true, //
text: '正在加载……', //
background: 'rgba(0,0,0,.7)' //
})
},
//
endLoading () {
// clearTimeout(timer);
if (loading) {
loading.close()
}
}
},
computed: {
tableHeight () {
return this.$store.state.inIframe ? this.clientHeight - 415 + this.iframeHeight : this.clientHeight - 415
},
...mapGetters(['clientHeight', 'iframeHeight'])
},
watch: {
},
props: {
}
}
</script>
<style lang="scss" scoped >
@import "@/assets/scss/modules/management/epidemic.scss";
</style>
Loading…
Cancel
Save