删除增加二次提醒,删除成功后,页面跳转到首页
Showing
1 changed file
with
25 additions
and
12 deletions
... | @@ -300,17 +300,35 @@ export default { | ... | @@ -300,17 +300,35 @@ export default { |
300 | }, | 300 | }, |
301 | //右键菜单的删除 | 301 | //右键菜单的删除 |
302 | deleteByBsm(){ | 302 | deleteByBsm(){ |
303 | let params={"bsm":this.zdData.bsm,"type":this.zdData.type}; | 303 | let name=''; |
304 | if(this.zdData.type=='zd'){ | 304 | switch (this.zdData.type) { |
305 | params={"bsm":this.zdData.zdbsm,"type":this.zdData.type}; | 305 | case 'zd': |
306 | name = '宗地' | ||
307 | break; | ||
308 | case 'dz': | ||
309 | name = '多幢' | ||
310 | break; | ||
311 | case 'zrz': | ||
312 | name = '自然幢' | ||
313 | break; | ||
314 | |||
315 | default: | ||
316 | break; | ||
306 | } | 317 | } |
318 | this.$confirm('是否确定删除该'+name+'?', '提示', { | ||
319 | confirmButtonText: '确定', | ||
320 | cancelButtonText: '取消', | ||
321 | type: 'warning' | ||
322 | }).then(() => { | ||
323 | let params={"bsm":this.zdData.bsm,"type":this.zdData.type}; | ||
307 | deleteZdInfoByBsm(params) | 324 | deleteZdInfoByBsm(params) |
308 | .then((res) => { | 325 | .then((res) => { |
309 | if(res.code=200){ | 326 | if(res.code=200){ |
310 | this.$message({ | 327 | this.$message({ |
311 | message: res.message, | 328 | type: 'success', |
312 | type: "success", | 329 | message: '删除成功!' |
313 | }); | 330 | }); |
331 | this.$router.push("/panel"); | ||
314 | } else { | 332 | } else { |
315 | this.$message({ | 333 | this.$message({ |
316 | message: res.message, | 334 | message: res.message, |
... | @@ -319,7 +337,9 @@ export default { | ... | @@ -319,7 +337,9 @@ export default { |
319 | } | 337 | } |
320 | }) | 338 | }) |
321 | .catch((error) => {}); | 339 | .catch((error) => {}); |
340 | }).catch(() => { | ||
322 | 341 | ||
342 | }); | ||
323 | }, | 343 | }, |
324 | }, | 344 | }, |
325 | }; | 345 | }; |
... | @@ -352,12 +372,6 @@ export default { | ... | @@ -352,12 +372,6 @@ export default { |
352 | text-overflow: ellipsis; | 372 | text-overflow: ellipsis; |
353 | white-space: nowrap; | 373 | white-space: nowrap; |
354 | } | 374 | } |
355 | // .active_color { | ||
356 | // color: #ffffff; | ||
357 | // } | ||
358 | .reTree_box { | ||
359 | // overflow-y: auto; | ||
360 | } | ||
361 | .reTree_icon { | 375 | .reTree_icon { |
362 | width: 17px; | 376 | width: 17px; |
363 | height: 17px; | 377 | height: 17px; |
... | @@ -369,7 +383,6 @@ export default { | ... | @@ -369,7 +383,6 @@ export default { |
369 | position: relative; | 383 | position: relative; |
370 | color: #ffffff; | 384 | color: #ffffff; |
371 | cursor: pointer; | 385 | cursor: pointer; |
372 | moz-user-select: -moz-none; | ||
373 | -moz-user-select: none; | 386 | -moz-user-select: none; |
374 | -o-user-select: none; | 387 | -o-user-select: none; |
375 | -khtml-user-select: none; | 388 | -khtml-user-select: none; | ... | ... |
-
Please register or sign in to post a comment