|  | @@ -1,32 +1,32 @@
 | 
	
		
			
				|  |  |  package com.citu.module.menduner.system.controller.admin.area;
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | -import org.springframework.web.bind.annotation.*;
 | 
	
		
			
				|  |  | -import javax.annotation.Resource;
 | 
	
		
			
				|  |  | -import org.springframework.validation.annotation.Validated;
 | 
	
		
			
				|  |  | -import org.springframework.security.access.prepost.PreAuthorize;
 | 
	
		
			
				|  |  | -import io.swagger.v3.oas.annotations.tags.Tag;
 | 
	
		
			
				|  |  | -import io.swagger.v3.oas.annotations.Parameter;
 | 
	
		
			
				|  |  | -import io.swagger.v3.oas.annotations.Operation;
 | 
	
		
			
				|  |  | -
 | 
	
		
			
				|  |  | -import javax.validation.*;
 | 
	
		
			
				|  |  | -import javax.servlet.http.*;
 | 
	
		
			
				|  |  | -import java.util.*;
 | 
	
		
			
				|  |  | -import java.io.IOException;
 | 
	
		
			
				|  |  | -
 | 
	
		
			
				|  |  | +import com.citu.framework.apilog.core.annotation.ApiAccessLog;
 | 
	
		
			
				|  |  | +import com.citu.framework.common.pojo.CommonResult;
 | 
	
		
			
				|  |  |  import com.citu.framework.common.pojo.PageParam;
 | 
	
		
			
				|  |  |  import com.citu.framework.common.pojo.PageResult;
 | 
	
		
			
				|  |  | -import com.citu.framework.common.pojo.CommonResult;
 | 
	
		
			
				|  |  |  import com.citu.framework.common.util.object.BeanUtils;
 | 
	
		
			
				|  |  | -import static com.citu.framework.common.pojo.CommonResult.success;
 | 
	
		
			
				|  |  | -
 | 
	
		
			
				|  |  |  import com.citu.framework.excel.core.util.ExcelUtils;
 | 
	
		
			
				|  |  | -
 | 
	
		
			
				|  |  | -import com.citu.framework.apilog.core.annotation.ApiAccessLog;
 | 
	
		
			
				|  |  | -import static com.citu.framework.apilog.core.enums.OperateTypeEnum.*;
 | 
	
		
			
				|  |  | -
 | 
	
		
			
				|  |  | -import com.citu.module.menduner.system.controller.admin.area.vo.*;
 | 
	
		
			
				|  |  | +import com.citu.module.menduner.system.controller.admin.area.vo.AreaListReqVO;
 | 
	
		
			
				|  |  | +import com.citu.module.menduner.system.controller.admin.area.vo.AreaPageReqVO;
 | 
	
		
			
				|  |  | +import com.citu.module.menduner.system.controller.admin.area.vo.AreaRespVO;
 | 
	
		
			
				|  |  | +import com.citu.module.menduner.system.controller.admin.area.vo.AreaSaveReqVO;
 | 
	
		
			
				|  |  |  import com.citu.module.menduner.system.dal.dataobject.area.AreaDO;
 | 
	
		
			
				|  |  |  import com.citu.module.menduner.system.service.area.AreaService;
 | 
	
		
			
				|  |  | +import io.swagger.v3.oas.annotations.Operation;
 | 
	
		
			
				|  |  | +import io.swagger.v3.oas.annotations.Parameter;
 | 
	
		
			
				|  |  | +import io.swagger.v3.oas.annotations.tags.Tag;
 | 
	
		
			
				|  |  | +import org.springframework.security.access.prepost.PreAuthorize;
 | 
	
		
			
				|  |  | +import org.springframework.validation.annotation.Validated;
 | 
	
		
			
				|  |  | +import org.springframework.web.bind.annotation.*;
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  | +import javax.annotation.Resource;
 | 
	
		
			
				|  |  | +import javax.servlet.http.HttpServletResponse;
 | 
	
		
			
				|  |  | +import javax.validation.Valid;
 | 
	
		
			
				|  |  | +import java.io.IOException;
 | 
	
		
			
				|  |  | +import java.util.List;
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  | +import static com.citu.framework.apilog.core.enums.OperateTypeEnum.EXPORT;
 | 
	
		
			
				|  |  | +import static com.citu.framework.common.pojo.CommonResult.success;
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |  @Tag(name = "管理后台 - 地区")
 | 
	
		
			
				|  |  |  @RestController
 | 
	
	
		
			
				|  | @@ -91,25 +91,12 @@ public class AreaController {
 | 
	
		
			
				|  |  |      @PreAuthorize("@ss.hasPermission('menduner:system:area:export')")
 | 
	
		
			
				|  |  |      @ApiAccessLog(operateType = EXPORT)
 | 
	
		
			
				|  |  |      public void exportAreaExcel(@Valid AreaPageReqVO pageReqVO,
 | 
	
		
			
				|  |  | -              HttpServletResponse response) throws IOException {
 | 
	
		
			
				|  |  | +                                HttpServletResponse response) throws IOException {
 | 
	
		
			
				|  |  |          pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
 | 
	
		
			
				|  |  |          List<AreaDO> list = areaService.getAreaPage(pageReqVO).getList();
 | 
	
		
			
				|  |  |          // 导出 Excel
 | 
	
		
			
				|  |  |          ExcelUtils.write(response, "地区.xls", "数据", AreaRespVO.class,
 | 
	
		
			
				|  |  | -                        BeanUtils.toBean(list, AreaRespVO.class));
 | 
	
		
			
				|  |  | -    }
 | 
	
		
			
				|  |  | -
 | 
	
		
			
				|  |  | -    @GetMapping("/get/tree")
 | 
	
		
			
				|  |  | -    @Operation(summary = "获取区域树形")
 | 
	
		
			
				|  |  | -    public CommonResult<List<AreaChildrenRespVO>> getArea(@Valid AreaListReqVO listReqVO) {
 | 
	
		
			
				|  |  | -        List<AreaChildrenRespVO> list = areaService.getArea(listReqVO);
 | 
	
		
			
				|  |  | -        return success(list);
 | 
	
		
			
				|  |  | -    }
 | 
	
		
			
				|  |  | -    @GetMapping("/get/children")
 | 
	
		
			
				|  |  | -    @Operation(summary = "根据区域id获得地区下级列表")
 | 
	
		
			
				|  |  | -    public CommonResult<List<AreaChildrenRespVO>> getAreaIdChildren(@RequestParam("id") Long id) {
 | 
	
		
			
				|  |  | -        List<AreaChildrenRespVO> list = areaService.getAreaIdChildren(id);
 | 
	
		
			
				|  |  | -        return success(list);
 | 
	
		
			
				|  |  | +                BeanUtils.toBean(list, AreaRespVO.class));
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |  
 |