|
|
|
@ -11,6 +11,7 @@ import com.glxp.api.common.res.BaseResponse;
|
|
|
|
|
import com.glxp.api.common.util.ResultVOUtils;
|
|
|
|
|
import com.glxp.api.constant.BusinessType;
|
|
|
|
|
import com.glxp.api.controller.BaseController;
|
|
|
|
|
import com.glxp.api.dto.DictDto;
|
|
|
|
|
import com.glxp.api.entity.auth.AuthAdmin;
|
|
|
|
|
import com.glxp.api.entity.auth.DeptEntity;
|
|
|
|
|
import com.glxp.api.entity.auth.DeptUserEntity;
|
|
|
|
@ -69,6 +70,18 @@ public class DeptController extends BaseController {
|
|
|
|
|
return ResultVOUtils.success(invWarehouseEntities);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@AuthRuleAnnotation("")
|
|
|
|
|
@GetMapping("spms/inv/warehouse/filterAllOptimize")
|
|
|
|
|
public BaseResponse filterAllInvWarehouseOptimize(FilterInvWarehouseRequest filterInvWarehouseRequest) {
|
|
|
|
|
filterInvWarehouseRequest.setPid(0);
|
|
|
|
|
filterInvWarehouseRequest.setStatus(1);
|
|
|
|
|
List<DeptEntity> invWarehouseEntities = deptService.filterInvWarehouse(filterInvWarehouseRequest);
|
|
|
|
|
List<DictDto> reList = invWarehouseEntities.stream().map(s-> {
|
|
|
|
|
DictDto dictDto = new DictDto(s.getCode(),s.getName());
|
|
|
|
|
return dictDto;
|
|
|
|
|
}).collect(Collectors.toList());
|
|
|
|
|
return ResultVOUtils.success(reList);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@AuthRuleAnnotation("")
|
|
|
|
|
@GetMapping("spms/inv/warehouse/filterNext")
|
|
|
|
@ -100,6 +113,29 @@ public class DeptController extends BaseController {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@AuthRuleAnnotation("")
|
|
|
|
|
@GetMapping("spms/inv/warehouse/filterByUserOptimize")
|
|
|
|
|
public BaseResponse filterByUserOptimize(FilterInvWarehouseRequest filterInvWarehouseRequest) {
|
|
|
|
|
|
|
|
|
|
if (isHosUser()) {
|
|
|
|
|
AuthAdmin authAdmin = customerService.getUserBean();
|
|
|
|
|
filterInvWarehouseRequest.setUserId(authAdmin.getId());
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
filterInvWarehouseRequest.setPid(0);
|
|
|
|
|
filterInvWarehouseRequest.setStatus(1);
|
|
|
|
|
|
|
|
|
|
List<DeptEntity> mInvWarehouseEntities = deptService.filterAllByUser(filterInvWarehouseRequest);
|
|
|
|
|
List<DictDto> reList = mInvWarehouseEntities.stream().map(s-> {
|
|
|
|
|
DictDto dictDto = new DictDto(s.getCode(),s.getName());
|
|
|
|
|
return dictDto;
|
|
|
|
|
}).collect(Collectors.toList());
|
|
|
|
|
return ResultVOUtils.success(reList);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@AuthRuleAnnotation("")
|
|
|
|
|
@GetMapping("spms/inv/warehouse/filterAllLocInv")
|
|
|
|
|
public BaseResponse filterAllLocInv(FilterInvWarehouseRequest filterInvWarehouseRequest) {
|
|
|
|
|