合并代码
Showing
3 changed files
with
113 additions
and
2 deletions
... | @@ -134,3 +134,14 @@ export function deleteCByBsm (data) { | ... | @@ -134,3 +134,14 @@ export function deleteCByBsm (data) { |
134 | data:data | 134 | data:data |
135 | }) | 135 | }) |
136 | } | 136 | } |
137 | /** | ||
138 | * 上下左右移动户 | ||
139 | * @param data | ||
140 | */ | ||
141 | export function moveH(data) { | ||
142 | return request({ | ||
143 | url:'fw/lpbright/insertMoveH', | ||
144 | method:'post', | ||
145 | data:data | ||
146 | }) | ||
147 | } | ... | ... |
src/components/moveH/moveH.vue
0 → 100644
1 | <template> | ||
2 | <div> | ||
3 | <el-dialog | ||
4 | title="移动户" | ||
5 | :visible.sync="isVisible" | ||
6 | width="50%" | ||
7 | @close="close" | ||
8 | :modal-append-to-body="false" | ||
9 | center> | ||
10 | <div> | ||
11 | <el-radio-group v-model="moveHdata.sxzylx"> | ||
12 | <el-radio label="up">向上</el-radio> | ||
13 | <el-radio label="down">向下</el-radio> | ||
14 | <el-radio label="left">向左</el-radio> | ||
15 | <el-radio label="right">向右</el-radio> | ||
16 | </el-radio-group> | ||
17 | <div class=""> | ||
18 | <el-button type="primary" @click="save">确认</el-button> | ||
19 | <el-button type="primary" @click="cacel">取消</el-button> | ||
20 | </div> | ||
21 | </div> | ||
22 | </el-dialog> | ||
23 | </div> | ||
24 | </template> | ||
25 | |||
26 | <script> | ||
27 | import {moveH} from './../../api/lpb' | ||
28 | import {Message} from 'element-ui' | ||
29 | export default { | ||
30 | name: "moveH", | ||
31 | data() { | ||
32 | return { | ||
33 | isVisible:false, | ||
34 | moveHdata: { | ||
35 | hbsm: "", | ||
36 | sxzylx: "", | ||
37 | type:"" | ||
38 | } | ||
39 | } | ||
40 | }, | ||
41 | props: { | ||
42 | moveHvisible: { | ||
43 | type: Boolean, | ||
44 | default: false | ||
45 | }, | ||
46 | hbsm: { | ||
47 | type: String | ||
48 | }, | ||
49 | type:{ | ||
50 | type:String | ||
51 | } | ||
52 | }, | ||
53 | methods: { | ||
54 | loading:function(){ | ||
55 | this.$emit('loading') | ||
56 | }, | ||
57 | save() { | ||
58 | this.moveHdata.hbsm=this.hbsm | ||
59 | this.moveHdata.type=this.type | ||
60 | moveH(this.moveHdata).then(res=>{ | ||
61 | console.log(res) | ||
62 | if (res.success) { | ||
63 | this.loading(); | ||
64 | this.close(); | ||
65 | Message.success("移动成功") | ||
66 | }else{ | ||
67 | Message.error(res.message) | ||
68 | } | ||
69 | }) | ||
70 | }, | ||
71 | cacel(){ | ||
72 | this.close() | ||
73 | }, | ||
74 | close() { | ||
75 | this.$emit('close'); | ||
76 | } | ||
77 | }, | ||
78 | watch: { | ||
79 | moveHvisible(val) { | ||
80 | this.isVisible = val | ||
81 | } | ||
82 | } | ||
83 | } | ||
84 | </script> | ||
85 | |||
86 | <style scoped> | ||
87 | |||
88 | </style> |
... | @@ -112,16 +112,19 @@ | ... | @@ -112,16 +112,19 @@ |
112 | <el-button type="primary" @click="addCVisible = false">取消</el-button> | 112 | <el-button type="primary" @click="addCVisible = false">取消</el-button> |
113 | </div> | 113 | </div> |
114 | </el-dialog> | 114 | </el-dialog> |
115 | <move-h :hbsm="chData.bsm" @close="moveHClose" :move-hvisible="moveHvisible" :type="syclx" @loading="loadingData"></move-h> | ||
115 | </div> | 116 | </div> |
116 | </template> | 117 | </template> |
117 | <script> | 118 | <script> |
119 | import moveH from "./../../../../../components/moveH/moveH" | ||
118 | import { getLpb,insertUpDownC,deleteCByBsm } from "../../../../../api/lpb"; | 120 | import { getLpb,insertUpDownC,deleteCByBsm } from "../../../../../api/lpb"; |
119 | export default { | 121 | export default { |
120 | name: "", | 122 | name: "", |
121 | components: {}, | 123 | components: {moveH}, |
122 | props: {}, | 124 | props: {}, |
123 | data() { | 125 | data() { |
124 | return { | 126 | return { |
127 | moveHvisible:false, | ||
125 | lpbData: { | 128 | lpbData: { |
126 | ljzs: [], | 129 | ljzs: [], |
127 | cs: [], | 130 | cs: [], |
... | @@ -173,6 +176,9 @@ export default { | ... | @@ -173,6 +176,9 @@ export default { |
173 | }, 200); | 176 | }, 200); |
174 | }, | 177 | }, |
175 | methods: { | 178 | methods: { |
179 | loadingData(){ | ||
180 | this.getLpb(this.$store.state.zrzbsm,this.$parent.syclx); | ||
181 | }, | ||
176 | //获取楼盘表数据 | 182 | //获取楼盘表数据 |
177 | getLpb(zrzbsm,scyclx) { | 183 | getLpb(zrzbsm,scyclx) { |
178 | getLpb(zrzbsm,scyclx).then((res) => { | 184 | getLpb(zrzbsm,scyclx).then((res) => { |
... | @@ -349,7 +355,13 @@ export default { | ... | @@ -349,7 +355,13 @@ export default { |
349 | 355 | ||
350 | }, | 356 | }, |
351 | handleMoveH(){ | 357 | handleMoveH(){ |
352 | 358 | // 移动户 | |
359 | console.log(this.chData,"chData") | ||
360 | console.log(this.$parent.syclx,"实预测类型") | ||
361 | this.moveHvisible=true; | ||
362 | }, | ||
363 | moveHClose(){ | ||
364 | this.moveHvisible=false; | ||
353 | }, | 365 | }, |
354 | handleDeleteH(){ | 366 | handleDeleteH(){ |
355 | 367 | ... | ... |
-
Please register or sign in to post a comment