feat(fg):添加分割后表单
Showing
1 changed file
with
174 additions
and
2 deletions
... | @@ -31,11 +31,94 @@ | ... | @@ -31,11 +31,94 @@ |
31 | </tr> | 31 | </tr> |
32 | </table> | 32 | </table> |
33 | </div> | 33 | </div> |
34 | <div class="fgh"> | ||
35 | <span>分割后宗地:</span> | ||
36 | <table border="1"> | ||
37 | <tr> | ||
38 | <td>操作</td> | ||
39 | <td>行政区</td> | ||
40 | <td>地籍区</td> | ||
41 | <td>地籍子区</td> | ||
42 | <td>土地特征码</td> | ||
43 | <td>项目名称</td> | ||
44 | <td>幢信息</td> | ||
45 | </tr> | ||
46 | <tr v-for="(item,index) in fghData" :key="index"> | ||
47 | <td @click="delRow(index)">-</td> | ||
48 | <td> | ||
49 | <el-select v-model="item.xzqbsm" @change="changeXzq(item.xzqbsm)"> | ||
50 | <el-option | ||
51 | v-for="i in xzq" | ||
52 | :key="i.bsm" | ||
53 | :label="i.mc" | ||
54 | :value="i.bsm" | ||
55 | ></el-option> | ||
56 | </el-select> | ||
57 | </td> | ||
58 | <td> | ||
59 | <el-select v-model="item.djqbsm" @change="changeDjq(item.djqbsm)"> | ||
60 | <el-option | ||
61 | v-for="i in djq" | ||
62 | :key="i.bsm" | ||
63 | :label="i.mc" | ||
64 | :value="i.bsm" | ||
65 | ></el-option> | ||
66 | </el-select> | ||
67 | </td> | ||
68 | <td> | ||
69 | <el-select v-model="item.djzqbsm"> | ||
70 | <el-option | ||
71 | v-for="i in djzq" | ||
72 | :key="i.bsm" | ||
73 | :label="i.mc" | ||
74 | :value="i.bsm" | ||
75 | ></el-option> | ||
76 | </el-select> | ||
77 | </td> | ||
78 | <td> | ||
79 | <el-select v-model="item.zdtzmbsm"> | ||
80 | <el-option | ||
81 | v-for="i in tdtzm" | ||
82 | :key="i.bsm" | ||
83 | :label="i.mc" | ||
84 | :value="i.bsm" | ||
85 | ></el-option> | ||
86 | </el-select> | ||
87 | </td> | ||
88 | <td> | ||
89 | <input type="text" v-model="item.xmmc" class="formInput"/> | ||
90 | </td> | ||
91 | <td> | ||
92 | <input type="text" v-model="item.zxx" class="formInput"/> | ||
93 | </td> | ||
94 | </tr> | ||
95 | <tr> | ||
96 | <td @click="addRow">+</td> | ||
97 | <td></td> | ||
98 | <td></td> | ||
99 | <td></td> | ||
100 | <td></td> | ||
101 | <td></td> | ||
102 | <td></td> | ||
103 | </tr> | ||
104 | </table> | ||
105 | </div> | ||
106 | |||
34 | <query-data @getData="getData" :centerDialogVisible.sync="centerDialogVisible" @close="close"></query-data> | 107 | <query-data @getData="getData" :centerDialogVisible.sync="centerDialogVisible" @close="close"></query-data> |
108 | <div class="header-button"> | ||
109 | <el-button type="primary" @click="save">保存</el-button> | ||
110 | </div> | ||
35 | </div> | 111 | </div> |
36 | </template> | 112 | </template> |
37 | 113 | ||
38 | <script> | 114 | <script> |
115 | import { | ||
116 | getAllList, | ||
117 | getListByXzqbsm, | ||
118 | getListByPbsm, | ||
119 | getDdicByMC | ||
120 | } from "./../../../../api/common"; | ||
121 | import {getQjZdjbxxDetailById} from './../../../../api/zd' | ||
39 | import QueryData from './../../../../components/queryData/queryData' | 122 | import QueryData from './../../../../components/queryData/queryData' |
40 | 123 | ||
41 | export default { | 124 | export default { |
... | @@ -45,14 +128,89 @@ | ... | @@ -45,14 +128,89 @@ |
45 | data() { | 128 | data() { |
46 | return { | 129 | return { |
47 | centerDialogVisible: false, | 130 | centerDialogVisible: false, |
48 | bgqData: {} | 131 | bgqData: {}, |
132 | xzq: [], | ||
133 | djq: [], | ||
134 | djzq: [], | ||
135 | tdtzm: [], | ||
136 | Data: { | ||
137 | xzqbsm: '', | ||
138 | djqbsm: '', | ||
139 | djzqbsm: '', | ||
140 | zdtzmbsm: '', | ||
141 | zmmc: '', | ||
142 | zxx: '' | ||
143 | }, | ||
144 | fghData: [], | ||
145 | |||
49 | } | 146 | } |
50 | }, | 147 | }, |
51 | created() { | 148 | created() { |
52 | }, | 149 | }, |
53 | mounted() { | 150 | mounted() { |
151 | this.getXzqList(); | ||
152 | this.getzdtzm(); | ||
54 | }, | 153 | }, |
55 | methods: { | 154 | methods: { |
155 | save() { | ||
156 | console.log("save........") | ||
157 | }, | ||
158 | getJbxx(id) { | ||
159 | getQjZdjbxxDetailById(id).then(res => { | ||
160 | this.Data = res.result | ||
161 | }) | ||
162 | }, | ||
163 | getzdtzm() { | ||
164 | getDdicByMC('宗地(宗海)特征码').then(res => { | ||
165 | this.tdtzm = res.result | ||
166 | }) | ||
167 | }, | ||
168 | getXzqList() { | ||
169 | getAllList() | ||
170 | .then((res) => { | ||
171 | console.log(res) | ||
172 | this.xzq = res.result; | ||
173 | }) | ||
174 | .catch((error) => { | ||
175 | }); | ||
176 | }, | ||
177 | changeXzq(id) { | ||
178 | this.djq = []; | ||
179 | this.djzq = []; | ||
180 | getListByXzqbsm(id) | ||
181 | .then((res) => { | ||
182 | if (res.result == null) { | ||
183 | this.djq = null; | ||
184 | } else { | ||
185 | this.djq = res.result; | ||
186 | } | ||
187 | }) | ||
188 | .catch((error) => { | ||
189 | }); | ||
190 | }, | ||
191 | changeDjq(item) { | ||
192 | this.djzq = []; | ||
193 | if (item == null) { | ||
194 | } else { | ||
195 | console.log(item); | ||
196 | getListByPbsm(item) | ||
197 | .then((res) => { | ||
198 | if (res.result == null) { | ||
199 | this.djzq = null; | ||
200 | } else { | ||
201 | this.djzq = res.result; | ||
202 | } | ||
203 | }) | ||
204 | .catch((error) => { | ||
205 | }); | ||
206 | } | ||
207 | }, | ||
208 | addRow() { | ||
209 | this.fghData.push(this.Data) | ||
210 | }, | ||
211 | delRow(index) { | ||
212 | this.fghData.splice(index, 1) | ||
213 | }, | ||
56 | close: function () { | 214 | close: function () { |
57 | this.centerDialogVisible = false; | 215 | this.centerDialogVisible = false; |
58 | }, | 216 | }, |
... | @@ -68,7 +226,14 @@ | ... | @@ -68,7 +226,14 @@ |
68 | }, | 226 | }, |
69 | }, | 227 | }, |
70 | computed: {}, | 228 | computed: {}, |
71 | watch: {}, | 229 | watch: { |
230 | bgqData: { | ||
231 | handler: function (item) { | ||
232 | this.getJbxx(item.glbsm) | ||
233 | }, | ||
234 | deep: true | ||
235 | } | ||
236 | }, | ||
72 | } | 237 | } |
73 | </script> | 238 | </script> |
74 | <style scoped lang="less"> | 239 | <style scoped lang="less"> |
... | @@ -109,5 +274,12 @@ | ... | @@ -109,5 +274,12 @@ |
109 | .noData { | 274 | .noData { |
110 | color: #b2b2b2; | 275 | color: #b2b2b2; |
111 | } | 276 | } |
277 | .fgh{ | ||
278 | margin-top: 20px; | ||
279 | } | ||
280 | .header-button { | ||
281 | margin-top: 20px; | ||
282 | text-align: center; | ||
283 | } | ||
112 | } | 284 | } |
113 | </style> | 285 | </style> | ... | ... |
-
Please register or sign in to post a comment