8509fedc by 杨威

户分割

1 parent c248f96e
......@@ -70,3 +70,13 @@ export function hhb(data) {
data: data
})
}
/**
* 户分割
*/
export function hfg(data) {
return request({
url: '/bg/hSplitMerge/hFg',
method: 'post',
data: data
})
}
\ No newline at end of file
......
......@@ -303,141 +303,11 @@
</div>
</el-tab-pane>
<el-tab-pane label="户分割" name="h">
<div class="fg-tabs">
<span class="tips">分割前户信息</span>
<el-button type="primary" class="addBtn" @click="newAdd">新增</el-button>
<div class="fgq">
<div class="data">
<ul>
<li><span>宗地代码:</span>{{hFgqData.zddm}}</li>
<li><span>不动产单元号:</span>{{hFgqData.bdcdyh}}</li>
<li><span>项目名称:</span>{{hFgqData.xmmc}}</li>
<li><span>不动产权证号:</span>{{hFgqData.bdcqzh}}</li>
<li><span>权利人:</span>{{hFgqData.qlr}}</li>
<li><span>坐落:</span>{{hFgqData.zl}}</li>
</ul>
</div>
<div class="zxx">
<div class="dz">
<div class="title">
<span>多幢信息({{zdZxx.zrzList.length}}个)</span>
</div>
<ul>
<li v-for="(item,index) in zdZxx.zrzList" :key="index">{{item.xmmc}}</li>
</ul>
</div>
<div class="zrz">
<div class="title">
<span>自然幢信息({{zdZxx.dzList.length}}个)</span>
</div>
<ul>
<li v-for="(item,index) in zdZxx.dzList" :key="index"
:class="(index+1)%2===0?'':'oddborder'">{{item.xmmc}}
</li>
</ul>
</div>
</div>
</div>
<div class="fgh">
<span class="tips">分割后户信息</span>
<table border="1">
<tr>
<th class="cz">操作</th>
<th class="xzq">行政区</th>
<th class="djq">地籍区</th>
<th class="djzq">地籍子区</th>
<th class="syqlx">所有权类型</th>
<th class="tdtzm">土地特征码</th>
<th class="xmmc">项目名称</th>
</tr>
<tr v-for="(item,index) in hFghData.newZdlist" :key="index">
<td class="cz">
<el-button
type="primary"
class="changeBtn outMinus addMinus"
@click="delRow(index)"
>-
</el-button
>
</td>
<td class="xzq">
<el-select v-model="item.xzqbsm" @change="changeXzq(item.xzqbsm,index)">
<el-option
v-for="i in xzq"
:key="i.bsm"
:label="i.mc"
:value="i.bsm"
></el-option>
</el-select>
</td>
<td class="djq">
<el-select v-model="item.djqbsm" @change="changeDjq(item.djqbsm,index)">
<el-option
v-for="i in djq"
:key="i.bsm"
:label="i.mc"
:value="i.bsm"
></el-option>
</el-select>
</td>
<td class="syqlx">
<el-select v-model="item.djzqbsm">
<el-option
v-for="i in djzq"
:key="i.bsm"
:label="i.mc"
:value="i.bsm"
></el-option>
</el-select>
</td>
<td class="tdtzm">
<el-select v-model="item.syqlxbsm">
<el-option
v-for="i in syq"
:key="i.value"
:label="i.label"
:value="i.value"
></el-option>
</el-select>
</td>
<td class="syqlx">
<el-select v-model="item.zdtzmbsm">
<el-option
v-for="i in tdtzm"
:key="i.bsm"
:label="i.mc"
:value="i.bsm"
></el-option>
</el-select>
</td>
<td class="xmmc">
<input type="text" v-model="item.xmmc" class="formInput"/>
</td>
</tr>
<tr>
<td>
<el-button
type="primary"
class="changeBtn outAdd addMinus"
@click="addRow"
>+
</el-button>
</td>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
</table>
</div>
<query-data @getData="getData" :centerDialogVisible.sync="centerDialogVisible" :dylxs="['h']"
:isZdClose="true" @close="close"></query-data>
<div class="header-button" :style="{width:fgBoxWidth+'px'}">
<div class="fg-tabs psn">
<hfghb :isHb = false></hfghb>
<!-- <div class="header-button" :style="{width:fgBoxWidth+'px'}">
<el-button type="primary" class="saveBtn" @click="save">保存</el-button>
</div>
</div> -->
</div>
</el-tab-pane>
</el-tabs>
......@@ -454,14 +324,14 @@
import {getQjZdjbxxDetailById, zdfg, getZrz} from './../../../../api/zd'
import {getZdxx, ZdfggetZxx,dzfgGetZrzxx,saveDzFg} from './../../../../api/dz'
import {getHZdxx} from './../../../../api/h'
import QueryData from './../../../../components/queryData/queryData'
import zdQueryData from './../../../../components/zdQueryData/zdQueryData'
import dzQueryData from './../../../../components/dzQueryData/dzQueryData'
import {Message} from 'element-ui'
import hfghb from '../hfghb/index'
export default {
name: "",
components: {QueryData, zdQueryData,dzQueryData},
components: {zdQueryData,dzQueryData,hfghb},
props: {},
data() {
return {
......@@ -1177,11 +1047,13 @@
}
.psn{
position: unset!important;
}
.fg-tabs {
height: auto;
width: 100%;
position: relative;
top: 20px;
.table {
margin-top: 12px;
box-sizing: border-box;
......
......@@ -184,11 +184,11 @@
</div>
</el-tab-pane>
<el-tab-pane label="户合并" name="h">
<div class="hb-tabs psn">
<div class="hb-tabs psn" v-if="hhbtabs">
<hfghb></hfghb>
<div class="header-button" :style="{width:fgBoxWidth+'px'}">
<!-- <div class="header-button" :style="{width:fgBoxWidth+'px'}">
<el-button type="primary" class="saveBtn">保存</el-button>
</div>
</div> -->
</div>
</el-tab-pane>
</el-tabs>
......@@ -201,11 +201,11 @@
getListByXzqbsm,
getListByPbsm,
getDdicByMC
} from "./../../../../api/common";
import {ZdHb} from "./../../../../api/zd"
import {saveDzHb} from "./../../../../api/dz"
import QueryData from './../../../../components/queryData/queryData'
import zdQueryData from './../../../../components/zdQueryData/zdQueryData'
} from "@api/common";
import {ZdHb} from "@api/zd"
import {saveDzHb} from "@api/dz"
import QueryData from '@components/queryData/queryData'
import zdQueryData from '@components/zdQueryData/zdQueryData'
import hfghb from '../hfghb/index'
export default {
......@@ -245,6 +245,7 @@
value: "Z",
}
],
hhbtabs:false,
}
},
created() {
......@@ -257,6 +258,11 @@
})
},
methods: {
handleClick(tab, event) {
if (tab.name == 'h') {
this.hhbtabs = true
}
},
save(){
switch (this.tabName) {
case "zd":
......@@ -392,9 +398,6 @@
});
}
},
handleClick(tab, event) {
console.log(tab, event);
},
close: function () {
this.centerDialogVisible = false;
},
......
......@@ -84,7 +84,7 @@
<div class="lpb-content" ref="lpbContentWrap" :style="{ height: lpbContentHeight + 'px' }">
<!-- 楼盘表主体 -->
<div class="lp-overview" :style="{ width: lpbContentwidth + 'px' }">
<lpbContent ref="lpbContent" :zrzbsm='zrzbsm' :isHbfg = true></lpbContent>
<lpbContent ref="lpbContent" :zrzbsm='zrzbsm' :isHbfg = true :isHb="isHb"></lpbContent>
</div>
<!-- 右侧图例 -->
<div class="lp-legend">
......@@ -215,7 +215,12 @@ import { getLpbMenuTree, batchScYcChange, getLpbTj,batchGeneratorBdcdyh,getLpbFw
export default {
name:"",
components:{lpbContent},
props:{},
props:{
isHb:{
type:Boolean,
default:true
}
},
data(){
return {
queryData:{
......@@ -299,8 +304,8 @@ export default {
created(){},
mounted(){
this.$nextTick(()=>{
this.tableHeight = (document.documentElement.clientHeight || document.body.clientHeight) - 360;
this.lpbContentHeight = (document.documentElement.clientHeight || document.body.clientHeight) - 320;
this.tableHeight = (document.documentElement.clientHeight || document.body.clientHeight) - 320;
this.lpbContentHeight = (document.documentElement.clientHeight || document.body.clientHeight) - 270;
this.lpbContentwidth = this.$refs.lpbContentWrap.clientWidth - 34 - 6;
})
},
......@@ -495,12 +500,14 @@ export default {
</script>
<style scoped lang="less">
.main{
margin-bottom: 14px;
.el-row{
box-sizing: border-box;
padding-left: 2px;
margin-bottom: 6px;
}
.pagination{
padding-bottom: 0!important;
}
.lpb{
box-sizing: border-box;
padding-left: 2px;
......
......@@ -13,6 +13,7 @@
? 'bottom40 ljz-wrap'
: 'ljz-wrap'
"
:style="{'width':ljzWidth+'px'}"
v-show="lpbData.ljzs.length > 0"
>
<!-- 循环逻辑幢数据 -->
......@@ -262,6 +263,9 @@
<!-- 合并 -->
<li v-show="rightClickFlag == 'hb'" :class="canHb!='zyhb'? 'cantHb':''" @click="handleHb('zyhb')">左右合并</li>
<li v-show="rightClickFlag == 'hb'" :class="canHb!='sxhb'? 'cantHb':''" @click="handleHb('sxhb')">上下合并</li>
<!-- 分割 -->
<li v-show="rightClickFlag == 'fg'" @click="handleFg">户分割</li>
<!-- <li v-show="rightClickFlag == 'fg'" :class="canHb!='sxhb'? 'cantHb':''" @click="handleHb('sxhb')">上下合并</li> -->
</ul>
<!-- 层操作弹框 -->
......@@ -293,6 +297,26 @@
<el-button type="primary" @click="saveAddC">保存</el-button>
<el-button type="primary" @click="addCVisible = false">取消</el-button>
</div>
</el-dialog >
<!-- 户分割弹框 -->
<el-dialog
title = "户分割"
:visible.sync="hfgDialogVisible"
width="800px"
>
<el-form :model="fgData">
<el-form-item label="分割户数" required="" :label-width="formLabelWidth">
<el-input
:disabled="fgData.fghs!=''"
v-model="fgData.fghs"
autocomplete="off"
></el-input>
</el-form-item>
</el-form>
<div class="btnGroup">
<el-button type="primary" @click="savefgData">保存</el-button>
<el-button type="primary" @click="hfgDialogVisible = false">取消</el-button>
</div>
</el-dialog>
<move-h
:hbsm="chData.bsm"
......@@ -304,9 +328,9 @@
</div>
</template>
<script>
import moveH from "./../../../../../components/moveH/moveH";
import moveH from "@components/moveH/moveH";
import { getLpb, insertUpDownC, deleteCByBsm } from "@api/lpb";
import { hhb } from "@api/h";
import { hhb,hfg } from "@api/h";
import { Message } from 'element-ui';
export default {
name: "",
......@@ -319,6 +343,10 @@ export default {
zrzbsm:{
type:String,
default:''
},
isHb:{
type:Boolean,
default:true
}
},
data() {
......@@ -363,7 +391,13 @@ export default {
yclpbData:{},
sclpbData:{},
fghbChoosedList:[],
canHb:''//判断合并类型
canHb:'',//判断合并类型
hfgDialogVisible:false, //户分割弹框
fgData:{
fghs:"",
oldbsm:'',
fgfx:0
}
};
},
created() {},
......@@ -433,8 +467,8 @@ export default {
dataChange() {
//计算逻辑幢宽度 20为marginRight值
this.ljzWidth = 20;
if (this.$refs.ljz != undefined) {
this.$refs.ljz.forEach((item) => {
if (this.$refs.ljzzdy != undefined) {
this.$refs.ljzzdy.forEach((item) => {
this.ljzWidth += item.offsetWidth + 20;
});
} else {
......@@ -576,8 +610,9 @@ export default {
this.lpbChLeft = e.pageX;
this.lpbChTop = e.pageY;
if (this.isHbfg) {
this.rightClickFlag = 'hb';
this.rightClickFlag = this.isHb ? 'hb':'fg';
if (this.fghbChoosedList.length>1) {
//合并
this.lpbChVisible = true;
//判断选中户可以执行的合并类型
let chIsSame = this.fghbChoosedList.every((item)=> {
......@@ -595,6 +630,14 @@ export default {
this.canHb = ''
}
})
}else{
//分割
this.lpbChVisible = true;
this.fgData.oldbsm = item.bsm;
//判断户的实际sjcs为1,只能水平分割
this.fgData.fgfx = item.sjcs == 1 ? 0 : 1;
//判断户的实际sjhs不为1,分割户数为sjhs的值
this.fgData.fghs = item.sjhs == 1 ? '' : item.sjhs;
}
}else{
console.log(e, "e");
......@@ -741,6 +784,24 @@ export default {
}else{
}
},
//户分割
handleFg(){
this.hfgDialogVisible = true;
},
//户分割保存
savefgData(){
hfg(this.fgData).then((res) => {
if(res.code == 200){
Message.success('分割成功');
// 清除选中户
this.clearChoosedH();
this.fghbChoosedList = [];
// 更新楼盘表
this.getLpb(this.zrzbsm, this.$parent.scyclx);
}
})
.catch(() => {});
}
},
computed: {
......