1bb91313 by 杨威

号段管理模块

1 parent 5f56d429
1 <template>
2 <div class="main">
3 <el-form :inline="true" :model="ruleForm" ref="ruleForm" class="demo-form-inline">
4 <el-form-item prop="xzqbsm" label="行政区划">
5 <el-select v-model="ruleForm.xzqbsm" value-key="xzqbsm" placeholder="行政区" @change="changeXzq(ruleForm.xzqbsm)">
6 <el-option
7 v-for="item in xzq"
8 :key="item.bsm"
9 :label="item.mc"
10 :value="item.bsm">
11 </el-option>
12 </el-select>
13 </el-form-item>
14 <el-form-item prop="djqbsm" label="地籍区">
15 <el-select v-model="ruleForm.djqbsm" placeholder="地籍区" @change="changeDjq(ruleForm.djqbsm)">
16 <el-option
17 v-for="item in djq"
18 :key="item.bsm"
19 :label="item.mc"
20 :value="item.bsm">
21 </el-option>
22 </el-select>
23 </el-form-item>
24 <el-form-item prop="djzqbsm" label="地籍子区">
25 <el-select v-model="ruleForm.djzqbsm" placeholder="地籍子区">
26 <el-option
27 v-for="item in djzq"
28 :key="item.bsm"
29 :label="item.mc"
30 :value="item.bsm">
31 </el-option>
32 </el-select>
33 </el-form-item>
34 <br/>
35 <el-form-item label="所有权类型" class="w100" prop="syqlxbsm">
36 <el-select
37 v-model="ruleForm.syqlxbsm"
38 placeholder="所有权类型"
39 >
40 <el-option
41 v-for="item in syqlx"
42 :key="item.value"
43 :label="item.label"
44 :value="item.value"
45 >
46 </el-option>
47 </el-select>
48 </el-form-item>
49 <el-form-item label="特征码" class="w100" prop="zdtzmbsm">
50 <el-select
51 v-model="ruleForm.tzmbsm"
52 placeholder="宗地特征码"
53 >
54 <el-option
55 v-for="item in $store.state.zdtzmList"
56 :key="item.bsm"
57 :label="item.mc"
58 :value="item.bsm"
59 >
60 </el-option>
61 </el-select>
62 </el-form-item>
63 <el-form-item class="ml85">
64 <el-button type="primary" @click="getData" icon="el-icon-search">查询</el-button>
65 <el-button type="warning" style="margin-left:50px" @click="reset" icon="el-icon-refresh">重置</el-button>
66 </el-form-item>
67 </el-form>
68 <div class="edit">
69 <el-button type="success" @click="egitJzdm">修改</el-button>
70 </div>
71 <div class="log-table">
72 <el-table :data="tableData" :height="tableHeight" :row-class-name="tableRowClassName" @selection-change="handleSelectionChange">
73 <el-table-column
74 type="selection"
75 width="55">
76 </el-table-column>
77 <el-table-column type="index" width="80" align="center" label="序号">
78 </el-table-column>
79 <el-table-column prop="xzq" align="center" label="行政区">
80 </el-table-column>
81 <el-table-column prop="djq" align="center" label="地籍区">
82 </el-table-column>
83 <el-table-column prop="djzq" align="center" label="地籍子区">
84 </el-table-column>
85 <el-table-column prop="syqlx" align="center" label="所有权类型">
86 </el-table-column>
87 <el-table-column prop="tzm" align="center" label="特征码">
88 </el-table-column>
89 <el-table-column prop="dpdm" align="center" label="底盘代码">
90 </el-table-column>
91 <el-table-column prop="maxsxh" align="center" label="基准代码">
92 </el-table-column>
93 </el-table>
94 </div>
95 <div class="pagination">
96 <el-pagination background layout="prev, pager, next,total" :total="total"
97 :current-page="pageNo" :page-size="pageSize" @current-change="handleCurrentChange">
98 </el-pagination>
99 </div>
100 <el-dialog v-dialogDrag :close-on-click-modal="false" title="修改基准代码" :visible.sync="editVisible" width="30%" >
101 <el-input placeholder="请输入基准代码" class="newJzdm" v-model="newJzdm"></el-input>
102 <div class="btnGroup">
103 <el-button type="primary" @click="saveInfo">确定</el-button>
104 <el-button type="primary" @click="editVisible = false"
105 >取消</el-button
106 >
107 </div>
108 </el-dialog>
109 </div>
110 </template>
111
112 <script>
113 import {getLogData,getErrorLog} from "@api/manage";
114 import {
115 getAllList,
116 getListByXzqbsm,
117 getListByPbsm,
118 } from "@api/common";
119 export default {
120 name: "index",
121 data(){
122 return{
123 tableData:[
124 {
125 xzq:'灞桥区',
126 djq:'灞地籍',
127 djzq:'灞地籍2',
128 syqlx:'国家所有',
129 tzm:'集体土地所有权宗地',
130 dpdm:'23131',
131 maxsxh:'1231111',
132 }
133 ],
134 total: 0,
135 pageNo: 1,
136 pageSize: 15,
137 tableHeight: 0,
138 xzq: [],
139 djq: [],
140 djzq: [],
141 ruleForm:{
142 xzqbsm: "",
143 djqbsm: "",
144 djzqbsm: "",
145 syqlxbsm: "G",
146 tzmbsm: "",
147 },
148 syqlx: [
149 {
150 label: "国家所有",
151 value: "G",
152 },
153 {
154 label: "集体所有",
155 value: "J",
156 },
157 {
158 label: "土地所有权未确定或有争议",
159 value: "Z",
160 },
161 ],
162 editVisible:false,
163 newJzdm:'',
164 multipleSelection:[]
165 }
166 },
167 methods:{
168 //数据查询
169 getData(){
170 },
171 //条件重置
172 reset(){
173 this.ruleFor = {
174 xzqbsm: "",
175 djqbsm: "",
176 djzqbsm: "",
177 syqlxbsm: "G",
178 tzmbsm: "",
179 }
180 },
181 //获取行政区划数据
182 getXzqList() {
183 getAllList()
184 .then((res) => {
185 console.log(res.result);
186 this.xzq = res.result;
187 this.$store.state.xzqList = res.result;
188 this.ruleForm.xzqbsm = res.result[0].bsm;
189 })
190 .catch((error) => {});
191 },
192 //分页按钮
193 handleCurrentChange(val) {
194 this.pageNo = val;
195 this.getData();
196 },
197 //选择行政区
198 changeXzq(id) {
199 this.djq = [];
200 this.djzq = [];
201 this.ruleForm.djqbsm = "";
202 this.ruleForm.djzqbsm = "";
203 getListByXzqbsm(id)
204 .then((res) => {
205 if (res.result == null) {
206 this.djq = null;
207 } else {
208 this.djq = res.result;
209 this.$store.state.djqList = res.result;
210 }
211 })
212 .catch((error) => {});
213 },
214 //选择地籍区
215 changeDjq(item) {
216 this.djzq = [];
217 this.ruleForm.djzqbsm = "";
218 if (item == null) {
219 console.log("llllllllllasdas");
220 } else {
221 console.log(item);
222 getListByPbsm(item)
223 .then((res) => {
224 console.log(res.result);
225 if (res.result == null) {
226 this.djzq = null;
227 } else {
228 this.djzq = res.result;
229 this.$store.state.djzqList = res.result;
230 }
231 })
232 .catch((error) => {});
233 }
234 },
235 //表格单双行
236 tableRowClassName({ row, rowIndex }) {
237 if (rowIndex % 2 !== 0) {
238 return "even-row";
239 } else {
240 return "";
241 }
242 },
243 //修改基准代码
244 egitJzdm(){
245 if (this.multipleSelection.length > 0) {
246 this.editVisible = true;
247 }else{
248 this.$message({
249 message: "请至少选择一条记录后重试",
250 type: "warning",
251 });
252 }
253 },
254 //确定修改
255 saveInfo(){
256
257 },
258 //多选
259 handleSelectionChange(val){
260 this.multipleSelection = val;
261 }
262 },
263 mounted() {
264 this.getXzqList();
265 this.getData();
266 this.$nextTick(() => {
267 this.ruleForm.tzmbsm = this.$store.state.zdtzmList[0].bsm;
268 this.tableHeight = (document.documentElement.clientHeight || document.body.clientHeight) - 382;
269 })
270 }
271 }
272 </script>
273
274 <style scoped lang="less">
275 .el-form{
276 width: 100%;
277 border: 1px solid #E6E6E6;
278 background-color: white;
279 -webkit-box-sizing: border-box;
280 box-sizing: border-box;
281 padding: 10px 15px;
282 /deep/.el-form-item__label{
283 width: 100px;
284 }
285 /deep/ .el-form-item__content{
286 width: 300px;
287 .el-select{
288 width: 100%;
289 }
290 }
291 }
292 .edit{
293 margin-top: 10px;
294 overflow: hidden;
295 .el-button{
296 float: right;
297 }
298 }
299 .log-content{
300 width: 100%;
301 /*border: 1px solid red;*/
302 }
303 .log-search{
304 width: 100%;
305 border: 1px solid #E6E6E6;
306 height: 80px;
307 background-color: white;
308 box-sizing: border-box;
309 padding: 20px 15px;
310 }
311 .log-table{
312 margin-top: 10px;
313 width: 100%;
314 box-shadow: 0 2px 15px 1px rgba(49, 132, 245, 0.1);
315 }
316 .el-button {
317 width: 100px;
318 margin-left: 15px;
319 }
320
321 ul{
322 list-style-type: circle;
323 }
324 li{
325 display:block;
326 margin:10px;
327 }
328
329 .pagination {
330 padding: 18px 0;
331 }
332 .ml85{
333 margin-left: 86px;
334 }
335 .newJzdm{
336 display: block;
337 width: 300px;
338 margin: 50px auto ;
339 }
340 .btnGroup{
341 margin: 20px auto 0;
342 width: 230px;
343 }
344 .el-button {
345 margin-left: 12px;
346 }
347
348 </style>
...\ No newline at end of file ...\ No newline at end of file
...@@ -2,16 +2,18 @@ ...@@ -2,16 +2,18 @@
2 <el-tabs v-model="activeName" @tab-click="handleClick"> 2 <el-tabs v-model="activeName" @tab-click="handleClick">
3 <el-tab-pane label="日志管理" name="log"><log></log></el-tab-pane> 3 <el-tab-pane label="日志管理" name="log"><log></log></el-tab-pane>
4 <el-tab-pane label="字典管理" name="dictionary"><dictionary></dictionary></el-tab-pane> 4 <el-tab-pane label="字典管理" name="dictionary"><dictionary></dictionary></el-tab-pane>
5 <el-tab-pane label="号段管理" name="hdgl"><hdgl></hdgl></el-tab-pane>
5 </el-tabs> 6 </el-tabs>
6 </template> 7 </template>
7 8
8 <script> 9 <script>
9 import log from "./log/index" 10 import log from "./log"
10 import dictionary from "./dictionary/index" 11 import dictionary from "./dictionary"
12 import hdgl from "./hdgl";
11 export default { 13 export default {
12 name: "index", 14 name: "index",
13 components: { 15 components: {
14 log,dictionary 16 log,dictionary,hdgl
15 }, 17 },
16 data() { 18 data() {
17 return { 19 return {
......