Commit 43d9e76dfa919562b26e1ea80b405f2251d650a9

Authored by 2c2c2c
1 parent 70f14a45

投放点

1.点击投放点名称可以查看详情;
2.新增区域和街道查询和社区
trash-ui/src/views/unit/dropPointInfo/index.vue
@@ -29,6 +29,12 @@ @@ -29,6 +29,12 @@
29 <el-option v-for="(area,index) in streets" :label="area.name" :value="area.code" :key="area.code"/> 29 <el-option v-for="(area,index) in streets" :label="area.name" :value="area.code" :key="area.code"/>
30 </el-select> 30 </el-select>
31 </el-form-item> 31 </el-form-item>
  32 + <el-form-item label="请选择所属社区" prop="community">
  33 + <el-select v-model="queryParams.community" placeholder="请输入所属社区" style="width: 100%" clearable :disabled="infoDisable">
  34 + <el-option v-for="(area,index) in communitys" :label="area.name" :value="area.code" :key="area.code" @click.native="createDropPointNo(area,'community')"/>
  35 + </el-select>
  36 + </el-form-item>
  37 +
32 <el-form-item label="是否为实行物业管理的区域(小区)" prop="type"> 38 <el-form-item label="是否为实行物业管理的区域(小区)" prop="type">
33 <el-select v-model="queryParams.type" placeholder="请选择是否为实行物业管理的区域(小区)" clearable size="small"> 39 <el-select v-model="queryParams.type" placeholder="请选择是否为实行物业管理的区域(小区)" clearable size="small">
34 <el-option label="全部" value=""/> 40 <el-option label="全部" value=""/>
@@ -117,7 +123,7 @@ @@ -117,7 +123,7 @@
117 </el-table-column> 123 </el-table-column>
118 <el-table-column label="小区" align="center" prop="plot"/> 124 <el-table-column label="小区" align="center" prop="plot"/>
119 <el-table-column label="详细地址" align="center" prop="address"/> 125 <el-table-column label="详细地址" align="center" prop="address"/>
120 - <el-table-column label="投放点形式" align="center" prop="type"/> 126 + <el-table-column label="是否为实行物业管理的区域(小区)" align="center" prop="type"/>
121 <el-table-column label="投放点面积(m²)" align="center" prop="area"/> 127 <el-table-column label="投放点面积(m²)" align="center" prop="area"/>
122 <el-table-column label="投放点容量(m³)" align="center" prop="capacity"/> 128 <el-table-column label="投放点容量(m³)" align="center" prop="capacity"/>
123 <el-table-column label="管理单位" align="center" prop="managementUnit"/> 129 <el-table-column label="管理单位" align="center" prop="managementUnit"/>
@@ -366,6 +372,7 @@ export default { @@ -366,6 +372,7 @@ export default {
366 type: null, 372 type: null,
367 district: null, 373 district: null,
368 street: null, 374 street: null,
  375 + community: null
369 }, 376 },
370 // 表单参数 377 // 表单参数
371 form: {}, 378 form: {},
@@ -390,7 +397,7 @@ export default { @@ -390,7 +397,7 @@ export default {
390 {required: true, message: "请输入详细地址", trigger: "blur"} 397 {required: true, message: "请输入详细地址", trigger: "blur"}
391 ], 398 ],
392 type: [ 399 type: [
393 - {required: true, message: "请选择投放点形式", trigger: "change"} 400 + {required: true, message: "请选择是否为实行物业管理的区域(小区)", trigger: "change"}
394 ], 401 ],
395 area: [ 402 area: [
396 {required: true, message: "请输入投放点面积", trigger: "blur"}, 403 {required: true, message: "请输入投放点面积", trigger: "blur"},
@@ -665,6 +672,14 @@ export default { @@ -665,6 +672,14 @@ export default {
665 672
666 }, 673 },
667 getStreets(regionName) { 674 getStreets(regionName) {
  675 + if(this.queryParams.district!=null){
  676 + this.queryParams.street = null;
  677 + this.queryParams.community = null;
  678 + }
  679 + if(this.form.district!=null){
  680 + this.form.street = null;
  681 + this.form.community = null;
  682 + }
668 this.streets = []; 683 this.streets = [];
669 this.form.dropPointNo = null; 684 this.form.dropPointNo = null;
670 // this.form.street = null; 685 // this.form.street = null;
@@ -672,7 +687,12 @@ export default { @@ -672,7 +687,12 @@ export default {
672 this.streets = region.items; 687 this.streets = region.items;
673 }, 688 },
674 getCommunitys(regionName){ 689 getCommunitys(regionName){
675 - console.log(regionName) 690 + if(this.queryParams.street!=null){
  691 + this.queryParams.community = null;
  692 + }
  693 + if(this.form.street!=null){
  694 + this.form.community = null;
  695 + }
676 this.communitys = []; 696 this.communitys = [];
677 this.form.dropPointNo = null; 697 this.form.dropPointNo = null;
678 // this.form.community = null; 698 // this.form.community = null;
trash-unit/src/main/resources/mapper/unit/DropPointInfoMapper.xml
@@ -49,6 +49,7 @@ PUBLIC &quot;-//mybatis.org//DTD Mapper 3.0//EN&quot; @@ -49,6 +49,7 @@ PUBLIC &quot;-//mybatis.org//DTD Mapper 3.0//EN&quot;
49 <if test="dropPointNo != null and dropPointNo != ''"> and drop_point_no like concat(#{dropPointNo}, '%')</if> 49 <if test="dropPointNo != null and dropPointNo != ''"> and drop_point_no like concat(#{dropPointNo}, '%')</if>
50 <if test="district != null and district != ''"> and district = #{district}</if> 50 <if test="district != null and district != ''"> and district = #{district}</if>
51 <if test="street != null and street != ''"> and street = #{street}</if> 51 <if test="street != null and street != ''"> and street = #{street}</if>
  52 + <if test="community != null and community != ''"> and community = #{community}</if>
52 <if test="sList != null and sList.size() > 0 "> 53 <if test="sList != null and sList.size() > 0 ">
53 and street in 54 and street in
54 <foreach item="id" collection="sList" open="(" separator="," 55 <foreach item="id" collection="sList" open="(" separator=","