74b7522d by zhaoqian

自然幢表单数据填充

1 parent c35e886b
import request from '@/plugin/axios'
/**
* 查询所有行政区
*/
export function getSearchList() {
return request({
url: '/system/basiccommon/query',
method: 'get',
})
}
\ No newline at end of file
......@@ -9,3 +9,28 @@ export function insertZrzjbxx (data) {
data: data,
})
}
/**
* 生成不动产单元号
*/
export function getBdcdyh (dpdm,dptype) {
return request({
url: '/system/generator/getBdcdyh',
method: 'get',
params:{
dpdm:dpdm,
dptype:dptype
}
})
}
/**
* 保存自然幢信息
*/
export function saveZrzInfo (data) {
return request({
url: '/fw/qjZrz/updateQjZrz',
method: 'put',
data:data
})
}
\ No newline at end of file
......
......@@ -12,7 +12,10 @@ const store = new Vuex.Store({
zdbsm:'',
xzqList:[],
djqList:[],
djzqList:[]
djzqList:[],
//创建自然幢时需要用到的临时存储信息
zrzbsm:'',
xmmc:'',
},
modules: {
user,
......
......@@ -242,7 +242,12 @@ export default {
});
//todo 跳转到自然幢基本信息内容表页面 (预留)
this.close();
this.$router.push("/zrz");
this.$store.zdbsm=res.result.zdbsm;
this.$store.zrzbsm=res.result.bsm;
this.$store.xmmc=res.result.xmmc;
this.$router.push({
path: '/zrz', query:{data: res.result}
});
} else {
this.$message.error("创建失败!");
}
......
......@@ -43,6 +43,7 @@
<script>
import SearchHead from "../../../components/searchHead/searchHead";
import {getSearchList} from "../../../api/search";
export default {
name: "",
components: { SearchHead },
......@@ -55,35 +56,42 @@ export default {
type: [],
},
tableData: [
{
bdcdyh: "610101001001GB00001W",
xmmc: "万科集团万科城",
bdcqzh: "陕(2017)西安市不动产权第00000",
lx: "宗地",
qlr: "李子新",
zl: "灞桥-田家湾-咸宁东路,近浐河西路",
zrsj: "2020.09.07 ",
cjr: "李子新",
},
// {
// bdcdyh: "610101001001GB00001W",
// xmmc: "万科集团万科城",
// bdcqzh: "陕(2017)西安市不动产权第00000",
// lx: "宗地",
// qlr: "李子新",
// zl: "灞桥-田家湾-咸宁东路,近浐河西路",
// zrsj: "2020.09.07 ",
// cjr: "李子新",
// },
],
tableHeight: "",
};
},
created() {},
mounted() {
for (let i = 0; i < 11; i++) {
let obj = {
bdcdyh: "610101001001GB00001W",
xmmc: "万科集团万科城",
bdcqzh: "陕(2017)西安市不动产权第00000",
lx: "自然幢",
qlr: "李子新",
zl: "灞桥-田家湾-咸宁东路,近浐河西路",
zrsj: "2020.09.07 ",
cjr: "李子新",
};
this.tableData.push(obj);
}
getSearchList().then((res)=>{
console.log(res)
if(res.code===200){
this.tableData=res.result.records;
console.log(this.tableData)
}
})
// for (let i = 0; i < 11; i++) {
// let obj = {
// bdcdyh: "610101001001GB00001W",
// xmmc: "万科集团万科城",
// bdcqzh: "陕(2017)西安市不动产权第00000",
// lx: "自然幢",
// qlr: "李子新",
// zl: "灞桥-田家湾-咸宁东路,近浐河西路",
// zrsj: "2020.09.07 ",
// cjr: "李子新",
// };
// this.tableData.push(obj);
// }
this.tableHeight = this.$refs.dataGrid.offsetHeight - 68;
},
methods: {
......
......@@ -15,7 +15,7 @@
<td colspan="2" align="center" >自然幢号</td>
<td colspan="4" >
<el-input v-model="form.zrzh" style="width: 70%"></el-input>
<el-button @click.prevent="" type="primary" size="mini" style="width:25%;margin-left:3%">生成</el-button>
<el-button @click.prevent="generatorCode" type="primary" size="mini" style="width:25%;margin-left:3%">生成</el-button>
</td>
</tr>
<tr height="30">
......@@ -26,7 +26,7 @@
<td colspan="2" align="center" >不动产单元号</td>
<!-- todo 此处暂时存放的是不动产单元号标识码,而不是不动产单元号-->
<td colspan="4" >
<el-input v-model="form.dyhbsm" style="width: 70%"></el-input>
<el-input v-model="form.bdcdyh" style="width: 70%"></el-input>
<el-button @click.prevent="" type="primary" size="mini" style="width:25%;margin-left:3%">生成</el-button>
</td>
</tr>
......@@ -47,7 +47,7 @@
<td colspan="4" >
<el-select v-model="form.fwxzbsm" placeholder="请选择" >
<el-option
v-for="item in options"
v-for="item in fwxzOptions"
:key="item.value"
:label="item.label"
:value="item.value">
......@@ -124,7 +124,7 @@
<td colspan="4" >
<el-select v-model="form.fwcbbsm" placeholder="请选择" >
<el-option
v-for="item in options"
v-for="item in cbOptions"
:key="item.value"
:label="item.label"
:value="item.value">
......@@ -135,7 +135,7 @@
<td colspan="4" >
<el-select v-model="form.fwcqlybsm" placeholder="请选择" >
<el-option
v-for="item in options"
v-for="item in cqlyOptions"
:key="item.value"
:label="item.label"
:value="item.value">
......@@ -144,7 +144,7 @@
</td>
</tr>
<tr height="30" v-for="(item1,index) in form.ytList" :key="index">
<tr height="30" v-for="(item1,index) in form.fwytList" :key="index">
<td v-if="index===0" colspan="2" :rowspan="ytTitleRowspan" align="center" id="ytTitle">
<el-button type="primary" size="mini" style="margin-right: 10px" @click="addYtInfo">添加</el-button>
<span>用途</span>
......@@ -157,7 +157,7 @@
<td width="30" colspan="4" align="center" >
<el-select v-model="item1.fwytzdbsm" placeholder="请选择" >
<el-option
v-for="item in options"
v-for="item in ytOptions"
:key="item.value"
:label="item.label"
:value="item.value">
......@@ -168,7 +168,7 @@
<td width="30" colspan="4" align="center" >
<el-select v-model="item1.fwsjytbsm" placeholder="请选择" >
<el-option
v-for="item in options"
v-for="item in ytOptions"
:key="item.value"
:label="item.label"
:value="item.value">
......@@ -188,7 +188,7 @@
<td colspan="9" >
<el-select v-model="item1.fwjgzdbsm" placeholder="请选择" >
<el-option
v-for="item in options"
v-for="item in jgOptions"
:key="item.value"
:label="item.label"
:value="item.value">
......@@ -267,6 +267,8 @@
<script>
import Qlr from "../../../components/formMenu/qlr";
import Qlxz from "../../../components/formMenu/qlxz";
import {getBdcdyh,saveZrzInfo} from "../../../api/zrz"
import {getDdicByMC} from "../../../api/common"
export default {
name:'zrz',
components:{
......@@ -279,7 +281,7 @@
zrzbsm:'', //自然幢标识码
zdbsm:'', //宗地标识码
dzbsm:'', //多幢标识码
dyhbsm:'', //不动产单元号标识码
bdcdyh:'', //不动产单元号标识码
zrzh:'', //自然幢号
jzwgd:'', //建筑物高度
zzdmj:'', //幢占地面积
......@@ -304,7 +306,7 @@
ydybsm:'', //原单元标识码
name:'',
date:'',
ytList:[{
fwytList:[{
glbsm:'', //关联标识码
fwytzdbsm:'', //房屋用途字典标识码
sx:'', //顺序
......@@ -315,15 +317,7 @@
glbsm:'', //关联标识码
sx:'', //顺序
}],
qlxzList:[{
qlxzdm:'', //权利性质代码
glbsm:'', //宗地BSM、自然幢BSM、户BSM、多幢BSM、宗海BSM
qlxzzdbsm:'', //权利性质字典表标识码
qlxzmc:'', //权利名称名称
zhqlxzlx:'', //除宗海数据外,默认都是空;0:用海类型权利性质;2:海岛用途权利性质
addQjTdytRequestList:[{
}], //土地用途新增实体列表
}]
qlxzList:[]
},
options: [{
value: '选项1',
......@@ -341,6 +335,12 @@
value: '选项5',
label: '北京烤鸭'
}],
fwxzOptions:[],
cbOptions:[],
cqlyOptions:[],
ytOptions:[],
jgOptions:[],
djOptions:[],
value: '',
ytTitleRowspan:1, //用途的单元格垂直合并数量
fwjgTitleRowspan:1, //房屋结构的单元格垂直合并数量
......@@ -348,7 +348,7 @@
},
methods: {
addYtInfo(){
this.form.ytList.push({
this.form.fwytList.push({
glbsm:'',
fwytzdbsm:'',
fwsjytbsm:'',
......@@ -357,13 +357,13 @@
this.ytTitleRowspan=this.form.ytList.length;
},
deleteYtInfo(index){
if(this.form.ytList.length<=1){
if(this.form.fwytList.length<=1){
this.$message({
message: '不能删除,最少含有一条用途信息',
type: 'warning'
});
}else{
this.form.ytList.splice(index,1);
this.form.fwytList.splice(index,1);
this.ytTitleRowspan=this.form.ytList.length;
}
},
......@@ -388,10 +388,154 @@
},
onSave(){
console.log(this.form)
// this.form.qlxzList=this.$refs.qlxzModule.getQlxzDataList();
this.form.qlxzList=
[{
"addQjTdytRequestList": [
{
"bz": "string",
"mj": 0,
"pzdjbsm": "string",
"pzdjmc": "string",
"pzytdm": "1",
"pzytmc": "string",
"pzytmj": 0,
"qlxzbsm": "string",
"sjdjbsm": "string",
"sjdjmc": "string",
"sjytdm": "1234",
"sjytmc": "string",
"sjytmj": 0,
"syqx": "string",
"tdsyjssj": "2020-10-09 03:15:37.730Z",
"tdsyqssj": "2020-10-09 03:15:37.730Z",
"tdzh": "string"
}
],
"glbsm": "string",
"qlxzdm": "string",
"qlxzmc": "string",
"qlxzzdbsm": "string",
"zhqlxzlx": 0
}];
if(1>0){
saveZrzInfo(this.form).then((res)=>{
if(res.code===200){
this.$message.success("保存完成!")
}
})
}
},
onSubmit(){
console.log(this.form)
}
},
generatorCode(){
getBdcdyh(this.form.zdbsm,"zrz")
.then((res)=>{
this.form.zrzh=res.result.substring(0,24);
this.form.bdcdyh=res.result;
})
},
getFwxzList(){
getDdicByMC("房屋性质").then((res)=>{
if(res.result!=null){
for(let i=0;i<res.result.length;i++){
this.fwxzOptions.push({
label:res.result[i].mc,
value:res.result[i].bsm
})
}
}
})
},
getCbList(){
getDdicByMC("房屋产别").then((res)=>{
if(res.result!=null){
for(let i=0;i<res.result.length;i++){
this.cbOptions.push({
label:res.result[i].mc,
value:res.result[i].bsm
})
}
}
})
},
getCqlyList(){
getDdicByMC("产权来源").then((res)=>{
if(res.result!=null){
for(let i=0;i<res.result.length;i++){
this.cqlyOptions.push({
label:res.result[i].mc,
value:res.result[i].bsm
})
}
}
})
},
getYtList(){
getDdicByMC("土地用途").then((res)=>{
if(res.result!=null){
for(let i=0;i<res.result.length;i++){
this.ytOptions.push({
label:res.result[i].mc,
value:res.result[i].bsm
})
}
}
})
},
getDList(){
getDdicByMC("土地等级").then((res)=>{
if(res.result!=null){
for(let i=0;i<res.result.length;i++){
this.djOptions.push({
label:res.result[i].mc,
value:res.result[i].bsm
})
}
}
})
},
getJgist(){
getDdicByMC("房屋结构").then((res)=>{
if(res.result!=null){
for(let i=0;i<res.result.length;i++){
this.jgOptions.push({
label:res.result[i].mc,
value:res.result[i].bsm
})
}
}
})
},
getQlrxxData() {
console.log(this.$refs.qlrxxModule.getQlgyfsData()); //权利共有方式数据
console.log(this.$refs.qlrxxModule.getQlrxxData()); //权利人表格数据
},
getQlxzData() {
console.log(this.$refs.qlxzModule.getQlxzDataList()); //权利性质数据
},
},
created(){
},
mounted() {
this.getFwxzList();
this.getCbList();
this.getCqlyList();
this.getYtList();
this.getDList();
this.getJgist();
//todo 怎么判断进入到该页面是从新建处进来的,还是从右键宗地进来的!如果是从新建进来的就需要把虚拟宗标识码带过来;
this.form.zdbsm=this.$store.zdbsm;
this.form.xmmc=this.$store.xmmc;
this.form.zrzbsm=this.$store.zrzbsm;
}
}
</script>
......