Merge branch 'master' of http://yun.pashanhoo.com:9090/renchao/CadastralSystem
Showing
6 changed files
with
176 additions
and
10 deletions
src/api/dz.js
0 → 100644
1 | import request from '@/plugin/axios' | ||
2 | /** | ||
3 | * 新增多幢基本信息 | ||
4 | */ | ||
5 | export function insertDzjbxx (data) { | ||
6 | return request({ | ||
7 | url: '/fw/qjDz/insertQjDz', | ||
8 | method: 'post', | ||
9 | data: data, | ||
10 | }) | ||
11 | } | ||
12 | |||
13 | /** | ||
14 | * 生成不动产单元号 | ||
15 | */ | ||
16 | export function getBdcdyh (dpdm,dptype) { | ||
17 | return request({ | ||
18 | url: '/system/generator/getBdcdyh', | ||
19 | method: 'get', | ||
20 | params:{ | ||
21 | dpdm:dpdm, | ||
22 | dptype:dptype | ||
23 | } | ||
24 | }) | ||
25 | } | ||
26 | |||
27 | /** | ||
28 | * 保存自然幢信息 | ||
29 | */ | ||
30 | export function saveDzInfo (data) { | ||
31 | return request({ | ||
32 | url: '/fw/qjZrz/updateQjZrz', | ||
33 | method: 'put', | ||
34 | data:data | ||
35 | }) | ||
36 | } | ||
37 | |||
38 | /** | ||
39 | * 保存自然幢信息 | ||
40 | */ | ||
41 | export function getZrzDetailByBsm (data) { | ||
42 | return request({ | ||
43 | url: '/fw/qjZrz/getQjZrzDetailById', | ||
44 | method: 'get', | ||
45 | params:{ | ||
46 | id:data | ||
47 | } | ||
48 | }) | ||
49 | } | ||
... | \ No newline at end of file | ... | \ No newline at end of file |
... | @@ -504,7 +504,11 @@ | ... | @@ -504,7 +504,11 @@ |
504 | if(res.code){ | 504 | if(res.code){ |
505 | if(res.result!=null){ | 505 | if(res.result!=null){ |
506 | this.tableData=res.result; | 506 | this.tableData=res.result; |
507 | this.gyfs=res.result[0].gyfsbsm; | 507 | if(this.tableData.length===0){ |
508 | this.gyfs=this.$store.state.gyfsList[0].bsm; | ||
509 | }else { | ||
510 | this.gyfs=res.result[0].gyfsbsm; | ||
511 | } | ||
508 | } | 512 | } |
509 | } | 513 | } |
510 | }) | 514 | }) | ... | ... |
... | @@ -193,6 +193,10 @@ export default { | ... | @@ -193,6 +193,10 @@ export default { |
193 | }); | 193 | }); |
194 | if (newPath == "/zd") { | 194 | if (newPath == "/zd") { |
195 | this.getRightTree(this.$store.state.zdbsm); | 195 | this.getRightTree(this.$store.state.zdbsm); |
196 | }else if (newPath == "/zrz") { | ||
197 | this.getRightTree(this.$store.state.zdbsm); | ||
198 | }else { | ||
199 | this.getTreeList(); | ||
196 | } | 200 | } |
197 | }, | 201 | }, |
198 | "$store.state.zdbsm": function(bsm) { | 202 | "$store.state.zdbsm": function(bsm) { | ... | ... |
... | @@ -12,9 +12,9 @@ | ... | @@ -12,9 +12,9 @@ |
12 | <el-select v-model="ruleForm.xzqbsm" style="width:100px;" value-key="xzqbsm" placeholder="行政区" @change="changeXzq(ruleForm.xzqbsm)"> | 12 | <el-select v-model="ruleForm.xzqbsm" style="width:100px;" value-key="xzqbsm" placeholder="行政区" @change="changeXzq(ruleForm.xzqbsm)"> |
13 | <el-option | 13 | <el-option |
14 | v-for="item in xzq" | 14 | v-for="item in xzq" |
15 | :key="item.xzqbsm" | 15 | :key="item.bsm" |
16 | :label="item.xzqmc" | 16 | :label="item.mc" |
17 | :value="item.xzqbsm"> | 17 | :value="item.bsm"> |
18 | </el-option> | 18 | </el-option> |
19 | </el-select> | 19 | </el-select> |
20 | </el-form-item> | 20 | </el-form-item> |
... | @@ -110,7 +110,22 @@ | ... | @@ -110,7 +110,22 @@ |
110 | </el-form-item> | 110 | </el-form-item> |
111 | </el-form> | 111 | </el-form> |
112 | </el-tab-pane> | 112 | </el-tab-pane> |
113 | <el-tab-pane class="eltabspane" label="多幢" name="dz">多幢</el-tab-pane> | 113 | <el-tab-pane class="eltabspane" label="多幢" name="dz"> |
114 | <el-form :inline="true" :rules="rules2" :model="ruleForm2" ref="ruleForm2" class="dzProject"> | ||
115 | <el-form-item label="项目名称" prop="xmmc"> | ||
116 | <el-input | ||
117 | v-model="ruleForm2.xmmc" | ||
118 | placeholder="项目名称" | ||
119 | style="width:400px;" | ||
120 | ></el-input> | ||
121 | </el-form-item> | ||
122 | <el-form-item class="handleBtn"> | ||
123 | <el-button type="primary">导入图形</el-button> | ||
124 | <el-button type="primary" @click="newDz">创建</el-button> | ||
125 | <el-button type="primary" @click="close">取消</el-button> | ||
126 | </el-form-item> | ||
127 | </el-form> | ||
128 | </el-tab-pane> | ||
114 | <el-tab-pane class="eltabspane" label="林权" name="lq">林权</el-tab-pane> | 129 | <el-tab-pane class="eltabspane" label="林权" name="lq">林权</el-tab-pane> |
115 | <el-tab-pane class="eltabspane" label="构筑物" name="gzw">构筑物</el-tab-pane> | 130 | <el-tab-pane class="eltabspane" label="构筑物" name="gzw">构筑物</el-tab-pane> |
116 | </el-tabs> | 131 | </el-tabs> |
... | @@ -124,6 +139,7 @@ import { | ... | @@ -124,6 +139,7 @@ import { |
124 | } from "../../../api/common"; | 139 | } from "../../../api/common"; |
125 | import { insertQjZdjbxx } from "../../../api/zd"; | 140 | import { insertQjZdjbxx } from "../../../api/zd"; |
126 | import { insertZrzjbxx } from "../../../api/zrz"; | 141 | import { insertZrzjbxx } from "../../../api/zrz"; |
142 | import { insertDzjbxx } from "../../../api/dz"; | ||
127 | 143 | ||
128 | export default { | 144 | export default { |
129 | name: "", | 145 | name: "", |
... | @@ -152,6 +168,11 @@ export default { | ... | @@ -152,6 +168,11 @@ export default { |
152 | xmmc:'', | 168 | xmmc:'', |
153 | userbsm:'' | 169 | userbsm:'' |
154 | }, | 170 | }, |
171 | ruleForm2:{ | ||
172 | zdbsm:'', | ||
173 | xmmc:'', | ||
174 | userbsm:'' | ||
175 | }, | ||
155 | rules: { | 176 | rules: { |
156 | xzqbsm: [ | 177 | xzqbsm: [ |
157 | { required: true, message: '请选择行政区', trigger: 'change' } | 178 | { required: true, message: '请选择行政区', trigger: 'change' } |
... | @@ -177,6 +198,11 @@ export default { | ... | @@ -177,6 +198,11 @@ export default { |
177 | { required: true, message: '请输入项目名称', trigger: 'blur' }, | 198 | { required: true, message: '请输入项目名称', trigger: 'blur' }, |
178 | ], | 199 | ], |
179 | }, | 200 | }, |
201 | rules2: { | ||
202 | xmmc: [ | ||
203 | { required: true, message: '请输入项目名称', trigger: 'blur' }, | ||
204 | ], | ||
205 | }, | ||
180 | syqlx: [ | 206 | syqlx: [ |
181 | { | 207 | { |
182 | label: "国家所有", | 208 | label: "国家所有", |
... | @@ -232,7 +258,7 @@ export default { | ... | @@ -232,7 +258,7 @@ export default { |
232 | //todo 在新增时,如果是点击顶部新建里面的自然幢则不传zdbsm 如果是点击右键里面的添加定着物则传zdbsm | 258 | //todo 在新增时,如果是点击顶部新建里面的自然幢则不传zdbsm 如果是点击右键里面的添加定着物则传zdbsm |
233 | this.$refs['ruleForm1'].validate((valid) => { | 259 | this.$refs['ruleForm1'].validate((valid) => { |
234 | if (valid) { | 260 | if (valid) { |
235 | insertZrzjbxx(this.ruleForm1) | 261 | insertDzjbxx(this.ruleForm1) |
236 | .then((res) => { | 262 | .then((res) => { |
237 | if (res.code == "200") { | 263 | if (res.code == "200") { |
238 | this.$message({ | 264 | this.$message({ |
... | @@ -262,6 +288,40 @@ export default { | ... | @@ -262,6 +288,40 @@ export default { |
262 | }); | 288 | }); |
263 | 289 | ||
264 | }, | 290 | }, |
291 | newDz() { | ||
292 | //todo 在新增时,如果是点击顶部新建里面的自然幢则不传zdbsm 如果是点击右键里面的添加定着物则传zdbsm | ||
293 | this.$refs['ruleForm2'].validate((valid) => { | ||
294 | if (valid) { | ||
295 | insertDzjbxx(this.ruleForm2) | ||
296 | .then((res) => { | ||
297 | if (res.code == "200") { | ||
298 | this.$message({ | ||
299 | message: "创建成功!", | ||
300 | type: "success", | ||
301 | }); | ||
302 | //todo 跳转到自然幢基本信息内容表页面 (预留) | ||
303 | this.close(); | ||
304 | this.$store.state.zdbsm=res.result.zdbsm; | ||
305 | this.$store.state.dzbsm=res.result.bsm; | ||
306 | this.$store.state.xmmc=res.result.xmmc; | ||
307 | this.$router.push({ | ||
308 | path: '/dz', query:{ | ||
309 | source: 1, | ||
310 | bsm:res.result.bsm | ||
311 | } | ||
312 | }); | ||
313 | } else { | ||
314 | this.$message.error("创建失败!"); | ||
315 | } | ||
316 | }) | ||
317 | .catch((error) => {}); | ||
318 | } else { | ||
319 | console.log('error submit!!'); | ||
320 | return false; | ||
321 | } | ||
322 | }); | ||
323 | |||
324 | }, | ||
265 | getXzqList() { | 325 | getXzqList() { |
266 | getAllList() | 326 | getAllList() |
267 | .then((res) => { | 327 | .then((res) => { | ... | ... |
1 | <template> | 1 | <template> |
2 | <div class="dz content-form"> | 2 | <div class="dz content-form"> |
3 | <el-form ref="form" :model="form" label-width="160px"> | 3 | <el-form ref="form" :model="form" label-width="160px"> |
4 | <Qlr ref="qlrxxModule"></Qlr> | 4 | <Qlr ref="qlrxxModule" :bsm="bsm"></Qlr> |
5 | <table border="1" width="100%" cellspacing="0" cellpadding="0" class="dzTable"> | 5 | <table border="1" width="100%" cellspacing="0" cellpadding="0" class="dzTable"> |
6 | <tbody> | 6 | <tbody> |
7 | <tr height="30"> | 7 | <tr height="30"> |
... | @@ -202,6 +202,7 @@ | ... | @@ -202,6 +202,7 @@ |
202 | <script> | 202 | <script> |
203 | import Qlr from "../../../components/formMenu/qlr"; | 203 | import Qlr from "../../../components/formMenu/qlr"; |
204 | import Qlxz from "../../../components/formMenu/qlxz"; | 204 | import Qlxz from "../../../components/formMenu/qlxz"; |
205 | import {saveDzInfo,getBdcdyh} from "../../../api/dz"; | ||
205 | export default { | 206 | export default { |
206 | name:'zrz', | 207 | name:'zrz', |
207 | components:{ | 208 | components:{ |
... | @@ -210,6 +211,7 @@ | ... | @@ -210,6 +211,7 @@ |
210 | }, | 211 | }, |
211 | data () { | 212 | data () { |
212 | return { | 213 | return { |
214 | bsm:'', //此页面的多幢标识码 | ||
213 | form:{ | 215 | form:{ |
214 | dzbsm:'', //多幢标识码 | 216 | dzbsm:'', //多幢标识码 |
215 | zdbsm:'', //宗地标识码 | 217 | zdbsm:'', //宗地标识码 |
... | @@ -336,9 +338,51 @@ | ... | @@ -336,9 +338,51 @@ |
336 | 338 | ||
337 | onSave(){ | 339 | onSave(){ |
338 | console.log(this.form) | 340 | console.log(this.form) |
341 | this.form.dzbsm=this.bsm; | ||
342 | this.form.qlxzList= this.$refs.qlxzModule.getQlxzDataList(); | ||
343 | if(1>0){ | ||
344 | saveDzInfo(this.form).then((res)=>{ | ||
345 | if(res.code===200){ | ||
346 | this.$message.success("保存完成!") | ||
347 | }else { | ||
348 | this.$message({ | ||
349 | message: res.message, | ||
350 | type: "warning", | ||
351 | }); | ||
352 | } | ||
353 | }) | ||
354 | } | ||
339 | }, | 355 | }, |
340 | onSubmit(){ | 356 | onSubmit(){ |
341 | console.log(this.form) | 357 | console.log(this.form) |
358 | }, | ||
359 | getZddm(zdbsm){ | ||
360 | getQjZdjbxxDetailById(zdbsm).then((res)=>{ | ||
361 | if(res.code===200){ | ||
362 | this.form.zddm=res.result.zddm; | ||
363 | } | ||
364 | }) | ||
365 | }, | ||
366 | generatorCode(){ | ||
367 | getBdcdyh(this.form.zddm,"dz") | ||
368 | .then((res)=>{ | ||
369 | // this.form.zrzh=res.result.substring(0,24); | ||
370 | // this.form.bdcdyh=res.result; | ||
371 | }) | ||
372 | }, | ||
373 | }, | ||
374 | created() { | ||
375 | if(this.source===1){ | ||
376 | this.bsm=this.$route.query.bsm; | ||
377 | // this.form.zdbsm=this.$store.zdbsm; | ||
378 | // this.form.xmmc=this.$store.xmmc; | ||
379 | this.form.dzbsm=this.$route.query.bsm; | ||
380 | this.getZddm(this.$store.state.zdbsm); | ||
381 | }else { | ||
382 | this.bsm=this.$route.query.bsm; | ||
383 | this.form.dzbsm=this.$route.query.bsm; | ||
384 | } | ||
385 | if(this.source!==1){ | ||
342 | } | 386 | } |
343 | } | 387 | } |
344 | } | 388 | } | ... | ... |
... | @@ -10,7 +10,7 @@ | ... | @@ -10,7 +10,7 @@ |
10 | <tr height="30"> | 10 | <tr height="30"> |
11 | <td colspan="2" align="center" >宗地代码</td> | 11 | <td colspan="2" align="center" >宗地代码</td> |
12 | <td colspan="4" > | 12 | <td colspan="4" > |
13 | <el-input v-model="form.zddm" disabled="true"></el-input> | 13 | <el-input v-model="form.zddm" disabled></el-input> |
14 | <el-input v-show="false" v-model="form.zdbsm"></el-input> | 14 | <el-input v-show="false" v-model="form.zdbsm"></el-input> |
15 | </td> | 15 | </td> |
16 | <td colspan="2" align="center" >自然幢号</td> | 16 | <td colspan="2" align="center" >自然幢号</td> |
... | @@ -390,13 +390,18 @@ | ... | @@ -390,13 +390,18 @@ |
390 | } | 390 | } |
391 | }, | 391 | }, |
392 | onSave(){ | 392 | onSave(){ |
393 | // this.loading=true; | 393 | this.loading=true; |
394 | this.form.zrzbsm=this.bsm; | 394 | this.form.zrzbsm=this.bsm; |
395 | this.form.qlxzList= this.$refs.qlxzModule.getQlxzDataList(); | 395 | this.form.qlxzList= this.$refs.qlxzModule.getQlxzDataList(); |
396 | if(1>0){ | 396 | if(1>0){ |
397 | saveZrzInfo(this.form).then((res)=>{ | 397 | saveZrzInfo(this.form).then((res)=>{ |
398 | if(res.code===200){ | 398 | if(res.code===200){ |
399 | this.$message.success("保存完成!") | 399 | this.$message.success("保存完成!") |
400 | }else { | ||
401 | this.$message({ | ||
402 | message: res.message, | ||
403 | type: "warning", | ||
404 | }); | ||
400 | } | 405 | } |
401 | this.loading=false; | 406 | this.loading=false; |
402 | }) | 407 | }) |
... | @@ -484,7 +489,7 @@ | ... | @@ -484,7 +489,7 @@ |
484 | // this.form.zdbsm=this.$store.zdbsm; | 489 | // this.form.zdbsm=this.$store.zdbsm; |
485 | // this.form.xmmc=this.$store.xmmc; | 490 | // this.form.xmmc=this.$store.xmmc; |
486 | this.form.zrzbsm=this.$route.query.bsm; | 491 | this.form.zrzbsm=this.$route.query.bsm; |
487 | this.getZddm(this.$store.zdbsm); | 492 | this.getZddm(this.$store.state.zdbsm); |
488 | this.getZrzDetailByBsm(this.$route.query.bsm) | 493 | this.getZrzDetailByBsm(this.$route.query.bsm) |
489 | }else { | 494 | }else { |
490 | this.bsm=this.$route.query.bsm; | 495 | this.bsm=this.$route.query.bsm; | ... | ... |
-
Please register or sign in to post a comment