opt:区域人员表相关代码替换
This commit is contained in:
@@ -18,7 +18,7 @@ import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.modules.wql.util.WqlUtil;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import org.springframework.stereotype.Service;
|
||||
@@ -39,12 +39,12 @@ public class StPointIvtServiceImpl implements StPointIvtService {
|
||||
|
||||
@Autowired
|
||||
private SurfaceTask surfaceTask;
|
||||
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public Map<String, Object> queryAll(Map whereJson, Pageable page) {
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
JSONObject map = new JSONObject();
|
||||
map.put("flag", "1");
|
||||
if (!ObjectUtil.isNull(whereJson.get("point_code"))) {
|
||||
|
||||
@@ -40,4 +40,8 @@ public interface IUserAreaPermissionService extends IService<UserAreaPermission>
|
||||
* @param whereJson /
|
||||
*/
|
||||
void save(JSONObject whereJson);
|
||||
|
||||
|
||||
String getInArea();
|
||||
|
||||
}
|
||||
|
||||
@@ -8,7 +8,9 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.nl.common.domain.query.PageQuery;
|
||||
import org.nl.common.utils.SecurityUtils;
|
||||
import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.dao.UserAreaPermission;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.dao.mapper.UserAreaPermissionMapper;
|
||||
@@ -66,4 +68,40 @@ public class UserAreaPermissionServiceImpl extends ServiceImpl<UserAreaPermissio
|
||||
}
|
||||
this.saveBatch(list);
|
||||
}
|
||||
|
||||
public String getInArea() {
|
||||
String currentUserId = SecurityUtils.getCurrentUserId().toString();
|
||||
WQLObject userStorTab = WQLObject.getWQLObject("st_ivt_userarea");
|
||||
|
||||
JSONArray userStorArr = userStorTab.query("user_id = '" + currentUserId + "'").getResultJSONArray(0);
|
||||
int size = userStorArr.size();
|
||||
// 将仓库id拼成字符串
|
||||
String in_stor_id = "";
|
||||
|
||||
for (int i = 0; i < userStorArr.size(); i++) {
|
||||
JSONObject json = userStorArr.getJSONObject(i);
|
||||
|
||||
if (size == 1) {
|
||||
// 如果只有一条记录
|
||||
in_stor_id = "('" + json.getString("product_area") + "')";
|
||||
} else {
|
||||
if (i == 0) {
|
||||
// 第一条记录拼接
|
||||
in_stor_id = "('" + json.getString("product_area") + "','";
|
||||
} else {
|
||||
if ((size - 1) == i) {
|
||||
// 最后一条记录拼接
|
||||
in_stor_id += json.getString("product_area") + "')";
|
||||
} else {
|
||||
in_stor_id += json.getString("product_area") + "','";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (ObjectUtil.isEmpty(in_stor_id)) {
|
||||
in_stor_id = "('')";
|
||||
}
|
||||
return in_stor_id;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,45 +0,0 @@
|
||||
package org.nl.wms.basedata.st.rest;
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.nl.modules.logging.annotation.Log;
|
||||
import org.nl.wms.basedata.st.service.UserAreaService;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
@RestController
|
||||
@RequiredArgsConstructor
|
||||
|
||||
@RequestMapping("/api/userArea2")
|
||||
@Slf4j
|
||||
public class UserAreaController {
|
||||
private final UserAreaService userAreaService;
|
||||
|
||||
@GetMapping
|
||||
@Log("查询用户信息")
|
||||
|
||||
public ResponseEntity<Object> query(@RequestParam Map whereJson, Pageable page) {
|
||||
return new ResponseEntity<>(userAreaService.pageQuery(whereJson, page), HttpStatus.OK);
|
||||
}
|
||||
|
||||
@PostMapping("/queryUserArea")
|
||||
@Log("查询用户对应区域")
|
||||
|
||||
public ResponseEntity<Object> queryUserArea(@RequestBody JSONObject whereJson) {
|
||||
return new ResponseEntity<>(userAreaService.queryUserArea(whereJson), HttpStatus.OK);
|
||||
}
|
||||
|
||||
@PostMapping("/save")
|
||||
@Log("保存用户仓库信息")
|
||||
|
||||
public ResponseEntity<Object> save(@RequestBody JSONObject whereJson) {
|
||||
userAreaService.save(whereJson);
|
||||
return new ResponseEntity<>(HttpStatus.OK);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,33 +0,0 @@
|
||||
package org.nl.wms.basedata.st.service;
|
||||
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
public interface UserAreaService {
|
||||
/**
|
||||
* 查询数据分页
|
||||
*
|
||||
* @param whereJson 条件
|
||||
* @param page 分页参数
|
||||
* @return Map<String, Object>
|
||||
*/
|
||||
Map<String, Object> pageQuery(Map whereJson, Pageable page);
|
||||
|
||||
/**
|
||||
* 查询用户对应仓库
|
||||
*
|
||||
* @param whereJson /
|
||||
*/
|
||||
JSONArray queryUserArea(JSONObject whereJson);
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*
|
||||
* @param whereJson /
|
||||
*/
|
||||
void save(JSONObject whereJson);
|
||||
|
||||
}
|
||||
@@ -1,100 +0,0 @@
|
||||
package org.nl.wms.basedata.st.service.impl;
|
||||
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.nl.common.utils.SecurityUtils;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.modules.wql.util.WqlUtil;
|
||||
import org.nl.wms.basedata.st.service.UserAreaService;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* PC端出入库新增
|
||||
*/
|
||||
@Service
|
||||
@RequiredArgsConstructor
|
||||
@Slf4j
|
||||
public class UserAreaServiceImpl implements UserAreaService {
|
||||
|
||||
@Override
|
||||
public Map<String, Object> pageQuery(Map whereJson, Pageable page) {
|
||||
HashMap<String, String> map = new HashMap<>(whereJson);
|
||||
map.put("flag", "3");
|
||||
if (StrUtil.isNotEmpty(map.get("blurry"))) {
|
||||
map.put("blurry", "%" + map.get("blurry") + "%");
|
||||
}
|
||||
JSONObject jo = WQL.getWO("QST_STOR_ATTR").addParamMap(map).pageQuery(WqlUtil.getHttpContext(page), "username desc");
|
||||
return jo;
|
||||
}
|
||||
|
||||
@Override
|
||||
public JSONArray queryUserArea(JSONObject whereJson) {
|
||||
String user_id = whereJson.getString("user_id");
|
||||
JSONArray rows = WQLObject.getWQLObject("st_ivt_userarea").query("user_id = '" + user_id + "'").getResultJSONArray(0);
|
||||
return rows;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void save(JSONObject whereJson) {
|
||||
JSONObject jo = whereJson.getJSONObject("jo");
|
||||
JSONArray rows = whereJson.getJSONArray("rows");
|
||||
|
||||
String user_id = jo.getString("user_id");
|
||||
|
||||
WQLObject.getWQLObject("st_ivt_userarea").delete("user_id ='" + user_id + "'");
|
||||
for (int i = 0; i < rows.size(); i++) {
|
||||
JSONObject row = rows.getJSONObject(i);
|
||||
String product_area = row.getString("product_area");
|
||||
JSONObject user_stor = new JSONObject();
|
||||
user_stor.put("product_area", product_area);
|
||||
user_stor.put("user_id", user_id);
|
||||
WQLObject.getWQLObject("st_ivt_userarea").insert(user_stor);
|
||||
}
|
||||
}
|
||||
|
||||
public String getInArea() {
|
||||
String currentUserId = SecurityUtils.getCurrentUserId().toString();
|
||||
WQLObject userStorTab = WQLObject.getWQLObject("st_ivt_userarea");
|
||||
|
||||
JSONArray userStorArr = userStorTab.query("user_id = '" + currentUserId + "'").getResultJSONArray(0);
|
||||
int size = userStorArr.size();
|
||||
// 将仓库id拼成字符串
|
||||
String in_stor_id = "";
|
||||
|
||||
for (int i = 0; i < userStorArr.size(); i++) {
|
||||
JSONObject json = userStorArr.getJSONObject(i);
|
||||
|
||||
if (size == 1) {
|
||||
// 如果只有一条记录
|
||||
in_stor_id = "('" + json.getString("product_area") + "')";
|
||||
} else {
|
||||
if (i == 0) {
|
||||
// 第一条记录拼接
|
||||
in_stor_id = "('" + json.getString("product_area") + "','";
|
||||
} else {
|
||||
if ((size - 1) == i) {
|
||||
// 最后一条记录拼接
|
||||
in_stor_id += json.getString("product_area") + "')";
|
||||
} else {
|
||||
in_stor_id += json.getString("product_area") + "','";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (ObjectUtil.isEmpty(in_stor_id)) {
|
||||
in_stor_id = "('')";
|
||||
}
|
||||
return in_stor_id;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -17,8 +17,7 @@ import org.nl.common.utils.CodeUtil;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.modules.wql.util.SpringContextHolder;
|
||||
import org.nl.system.service.param.impl.SysParamServiceImpl;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.ext.acs.service.impl.WmsToAcsServiceImpl;
|
||||
import org.nl.wms.pda.mps.eum.RegionTypeEnum;
|
||||
import org.nl.wms.pda.mps.service.BakingService;
|
||||
@@ -38,7 +37,8 @@ public class BakingServiceImpl implements BakingService {
|
||||
|
||||
@Autowired
|
||||
private RedisUtils redisUtils;
|
||||
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
/*
|
||||
* 业务流程:
|
||||
* 入烤箱:
|
||||
@@ -75,8 +75,7 @@ public class BakingServiceImpl implements BakingService {
|
||||
WQLObject materTab = WQLObject.getWQLObject("md_me_materialbase");
|
||||
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
// 入箱
|
||||
if (StrUtil.equals(option, "1")) {
|
||||
// 母卷号
|
||||
@@ -622,8 +621,7 @@ public class BakingServiceImpl implements BakingService {
|
||||
String container_name = whereJson.getString("container_name");
|
||||
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
|
||||
if (ObjectUtil.isEmpty(point_code1)) {
|
||||
throw new BadRequestException("点位不能为空");
|
||||
@@ -814,8 +812,7 @@ public class BakingServiceImpl implements BakingService {
|
||||
}
|
||||
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
|
||||
JSONObject jsonCool = coolIvtTab.query("full_point_code = '" + point_code + "'").uniqueResult(0);
|
||||
if (ObjectUtil.isEmpty(jsonCool)) {
|
||||
|
||||
@@ -17,7 +17,7 @@ import org.nl.wms.basedata.master.interfaceback.service.dao.InterfaceBack;
|
||||
import org.nl.wms.basedata.master.interfaceback.service.dao.mapper.InterfaceBackMapper;
|
||||
import org.nl.wms.basedata.master.storagevehicleinfo.service.StoragevehicleinfoService;
|
||||
import org.nl.wms.basedata.master.storagevehicleinfo.service.dao.Storagevehicleinfo;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.ext.acs.service.impl.WmsToAcsServiceImpl;
|
||||
import org.nl.wms.ext.mes.service.LmsToMesService;
|
||||
import org.nl.wms.pda.mps.service.CasingService;
|
||||
@@ -36,6 +36,8 @@ public class CasingServiceImpl implements CasingService {
|
||||
StoragevehicleinfoService storagevehicleinfoService;
|
||||
@Autowired
|
||||
private InterfaceBackMapper interfaceBackMapper;
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public JSONObject queryMaterialInfo(JSONObject whereJson, HttpContext ctx) {
|
||||
String product_area = whereJson.getString("product_area");
|
||||
@@ -58,8 +60,7 @@ public class CasingServiceImpl implements CasingService {
|
||||
map.put("container_name", container_name);
|
||||
}
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
if (ObjectUtil.isNotEmpty(in_area_id)) {
|
||||
map.put("in_area_id", in_area_id);
|
||||
}
|
||||
|
||||
@@ -17,7 +17,7 @@ import org.nl.modules.wql.core.content.HttpContext;
|
||||
import org.nl.modules.wql.util.SpringContextHolder;
|
||||
import org.nl.wms.basedata.master.unit.service.dao.Unit;
|
||||
import org.nl.wms.basedata.master.unit.service.dao.mapper.UnitMapper;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.ext.acs.service.WmsToAcsService;
|
||||
import org.nl.wms.pda.mps.eum.RegionTypeEnum;
|
||||
import org.nl.wms.pda.mps.service.FeedingService;
|
||||
@@ -39,6 +39,8 @@ public class FeedingServiceImpl implements FeedingService {
|
||||
private final CheckOutBillService checkOutBillService;
|
||||
@Autowired
|
||||
private UnitMapper unitMapper;
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public JSONObject queryMaterialInfo(JSONObject whereJson, HttpContext ctx) {
|
||||
String product_area = whereJson.getString("product_area");
|
||||
@@ -57,8 +59,7 @@ public class FeedingServiceImpl implements FeedingService {
|
||||
map.put("source_container_name", source_container_name);
|
||||
}
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
if (ObjectUtil.isNotEmpty(in_area_id)) {
|
||||
map.put("in_area_id", in_area_id);
|
||||
}
|
||||
@@ -244,8 +245,7 @@ public class FeedingServiceImpl implements FeedingService {
|
||||
throw new BadRequestException("请输入或者扫描冷却区满轴位的点位!");
|
||||
} else {
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
if (!in_area_id.contains(cool_jo.getString("product_area"))) {
|
||||
throw new BadRequestException("当前登录人员暂无【" + cool_jo.getString("product_area") + "】操作权限");
|
||||
}
|
||||
@@ -279,8 +279,7 @@ public class FeedingServiceImpl implements FeedingService {
|
||||
throw new BadRequestException("请输入或者扫描冷却区满轴位的点位做为起点!");
|
||||
} else {
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
if (!in_area_id.contains(cool_jo.getString("product_area"))) {
|
||||
throw new BadRequestException("当前登录人员暂无【" + cool_jo.getString("product_area") + "】操作权限");
|
||||
}
|
||||
|
||||
@@ -9,11 +9,12 @@ import lombok.extern.slf4j.Slf4j;
|
||||
import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.pda.mps.service.InService;
|
||||
import org.nl.wms.sch.manage.TaskStatusEnum;
|
||||
import org.nl.wms.sch.tasks.CutConveyorTask;
|
||||
import org.nl.wms.sch.tasks.CutTrussTask;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
@@ -25,7 +26,8 @@ import java.util.HashMap;
|
||||
public class InServiceImpl implements InService {
|
||||
|
||||
private final CutTrussTask cutTrussTask;
|
||||
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public JSONObject queryMaterialInfo(JSONObject whereJson) {
|
||||
String product_area = whereJson.getString("product_area");
|
||||
@@ -40,8 +42,7 @@ public class InServiceImpl implements InService {
|
||||
map.put("device_code", device_code);
|
||||
}
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
if (ObjectUtil.isNotEmpty(in_area_id)) {
|
||||
map.put("in_area_id", in_area_id);
|
||||
}
|
||||
|
||||
@@ -9,11 +9,12 @@ import lombok.extern.slf4j.Slf4j;
|
||||
import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.pda.mps.service.OutService;
|
||||
import org.nl.wms.sch.manage.TaskStatusEnum;
|
||||
import org.nl.wms.sch.tasks.CutConveyorTask;
|
||||
import org.nl.wms.sch.tasks.CutTrussTask;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
@@ -25,7 +26,8 @@ import java.util.HashMap;
|
||||
public class OutServiceImpl implements OutService {
|
||||
|
||||
private final CutTrussTask cutTrussTask;
|
||||
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public JSONObject queryMaterialInfo(JSONObject whereJson) {
|
||||
String product_area = whereJson.getString("product_area");
|
||||
@@ -40,8 +42,7 @@ public class OutServiceImpl implements OutService {
|
||||
map.put("device_code", device_code);
|
||||
}
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
if (ObjectUtil.isNotEmpty(in_area_id)) {
|
||||
map.put("in_area_id", in_area_id);
|
||||
}
|
||||
|
||||
@@ -9,9 +9,10 @@ import lombok.extern.slf4j.Slf4j;
|
||||
import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.ext.acs.service.WmsToAcsService;
|
||||
import org.nl.wms.pda.mps.service.PaperTubeService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.HashMap;
|
||||
@@ -22,7 +23,8 @@ import java.util.HashMap;
|
||||
public class PaperTubeServiceImpl implements PaperTubeService {
|
||||
|
||||
private final WmsToAcsService wmsToAcsService;
|
||||
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public JSONObject queryDeviceList(JSONObject whereJson) {
|
||||
String product_area = whereJson.getString("product_area");
|
||||
@@ -42,8 +44,7 @@ public class PaperTubeServiceImpl implements PaperTubeService {
|
||||
public JSONObject PaperDeviceOperate(JSONObject whereJson) {
|
||||
String option = whereJson.getString("option");
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
if ("1".equals(option)) {
|
||||
String device_code = whereJson.getString("device_code");
|
||||
String material_code = whereJson.getString("material_code");
|
||||
|
||||
@@ -14,13 +14,14 @@ import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.modules.wql.core.content.HttpContext;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.ext.acs.service.AcsToWmsService;
|
||||
import org.nl.wms.ext.acs.service.impl.WmsToAcsServiceImpl;
|
||||
import org.nl.wms.pda.mps.eum.RegionTypeEnum;
|
||||
import org.nl.wms.pda.mps.service.RawFoilService;
|
||||
import org.nl.wms.sch.service.PointService;
|
||||
import org.nl.wms.sch.tasks.CallEmpReelTask;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
@@ -32,7 +33,8 @@ import java.util.Date;
|
||||
public class RawFoilServiceImpl implements RawFoilService {
|
||||
private final AcsToWmsService acsToWmsService;
|
||||
private final PointService pointService;
|
||||
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public JSONObject queryProductArea() {
|
||||
JSONObject map = new JSONObject();
|
||||
@@ -51,8 +53,7 @@ public class RawFoilServiceImpl implements RawFoilService {
|
||||
String product_area = whereJson.getString("product_area");
|
||||
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
|
||||
JSONArray resultArr = new JSONArray();
|
||||
JSONObject map = new JSONObject();
|
||||
@@ -124,8 +125,7 @@ public class RawFoilServiceImpl implements RawFoilService {
|
||||
map.put("point_code", whereJson.getString("point_code"));
|
||||
map.put("container_name", whereJson.getString("container_name"));
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
if (ObjectUtil.isNotEmpty(in_area_id)) {
|
||||
map.put("in_area_id", in_area_id);
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@ import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.wms.basedata.master.interfaceback.service.dao.InterfaceBack;
|
||||
import org.nl.wms.basedata.master.interfaceback.service.dao.mapper.InterfaceBackMapper;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.pda.mps.service.ShippingService;
|
||||
import org.nl.wms.sch.tasks.CutConveyorTask;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -29,6 +29,8 @@ public class ShippingServiceImpl implements ShippingService {
|
||||
private final CutConveyorTask cutConveyorTask;
|
||||
@Autowired
|
||||
private InterfaceBackMapper interfaceBackMapper;
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public JSONObject queryMaterialInfo(JSONObject whereJson) {
|
||||
String product_area = whereJson.getString("product_area");
|
||||
@@ -47,8 +49,7 @@ public class ShippingServiceImpl implements ShippingService {
|
||||
map.put("device_code", device_code);
|
||||
}
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
if (ObjectUtil.isNotEmpty(in_area_id)) {
|
||||
map.put("in_area_id", in_area_id);
|
||||
}
|
||||
|
||||
@@ -12,8 +12,9 @@ import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.modules.wql.core.content.HttpContext;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.pda.st.service.CoolInService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
@@ -26,7 +27,8 @@ import org.springframework.transaction.annotation.Transactional;
|
||||
@RequiredArgsConstructor
|
||||
@Slf4j
|
||||
public class CoolInServiceImpl implements CoolInService {
|
||||
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public JSONObject coolIOQuery(JSONObject whereJson, HttpContext ctx) {
|
||||
String container_name = whereJson.getString("container_name");
|
||||
@@ -38,8 +40,7 @@ public class CoolInServiceImpl implements CoolInService {
|
||||
}
|
||||
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
if (ObjectUtil.isNotEmpty(in_area_id)) {
|
||||
map.put("in_area_id", in_area_id);
|
||||
}
|
||||
|
||||
@@ -9,8 +9,9 @@ import lombok.extern.slf4j.Slf4j;
|
||||
import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.pda.st.service.CoolOutService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
@@ -24,7 +25,8 @@ import org.springframework.transaction.annotation.Transactional;
|
||||
@Slf4j
|
||||
public class CoolOutServiceImpl
|
||||
implements CoolOutService {
|
||||
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public JSONObject coolIOQuery(JSONObject whereJson) {
|
||||
JSONObject map = new JSONObject();
|
||||
@@ -33,8 +35,7 @@ public class CoolOutServiceImpl
|
||||
map.put("product_area", whereJson.getString("product_area"));
|
||||
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
if (ObjectUtil.isNotEmpty(in_area_id)) {
|
||||
map.put("in_area_id", in_area_id);
|
||||
}
|
||||
|
||||
@@ -11,10 +11,11 @@ import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.modules.wql.util.SpringContextHolder;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.ext.acs.service.WmsToAcsService;
|
||||
import org.nl.wms.pda.task.service.PdaTaskService;
|
||||
import org.nl.wms.sch.service.TaskService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
@@ -27,8 +28,10 @@ import org.springframework.transaction.annotation.Transactional;
|
||||
@RequiredArgsConstructor
|
||||
@Slf4j
|
||||
public class PdaTaskServiceImpl implements PdaTaskService {
|
||||
private final WmsToAcsService wmsToAcsService;
|
||||
|
||||
@Autowired
|
||||
private WmsToAcsService wmsToAcsService;
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public JSONObject taskQuery(JSONObject whereJson) {
|
||||
String search = whereJson.getString("search");
|
||||
@@ -39,8 +42,7 @@ public class PdaTaskServiceImpl implements PdaTaskService {
|
||||
map.put("search", "%" + search + "%");
|
||||
}
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
if (ObjectUtil.isNotEmpty(in_area_id)) {
|
||||
map.put("in_area_id", in_area_id);
|
||||
}
|
||||
|
||||
@@ -21,9 +21,8 @@ import org.nl.modules.wql.util.WqlUtil;
|
||||
import org.nl.system.service.param.impl.SysParamServiceImpl;
|
||||
import org.nl.wms.basedata.master.interfaceback.service.dao.InterfaceBack;
|
||||
import org.nl.wms.basedata.master.interfaceback.service.dao.mapper.InterfaceBackMapper;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.ext.mes.service.LmsToMesService;
|
||||
import org.nl.wms.ext.mes.service.impl.LmsToMesServiceImpl;
|
||||
import org.nl.wms.pdm.ivt.service.CoolPointIvtService;
|
||||
import org.nl.wms.pdm.ivt.service.dto.CoolPointIvtDto;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -46,12 +45,13 @@ import java.util.Map;
|
||||
public class CoolPointIvtServiceImpl implements CoolPointIvtService {
|
||||
@Autowired
|
||||
private InterfaceBackMapper interfaceBackMapper;
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public Map<String, Object> queryAll(Map whereJson, Pageable page) {
|
||||
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
HashMap map = new HashMap();
|
||||
map.put("flag", "1");
|
||||
if (whereJson.get("point_code") != null) {
|
||||
|
||||
@@ -14,9 +14,10 @@ import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.modules.wql.util.WqlUtil;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.pdm.ivt.service.CutPointIvtService;
|
||||
import org.nl.wms.pdm.ivt.service.dto.CutPointIvtDto;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
@@ -34,12 +35,12 @@ import java.util.Map;
|
||||
@RequiredArgsConstructor
|
||||
@Slf4j
|
||||
public class CutPointIvtServiceImpl implements CutPointIvtService {
|
||||
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public Map<String, Object> queryAll(Map whereJson, Pageable page) {
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
HashMap map = new HashMap();
|
||||
map.put("flag", "1");
|
||||
if (whereJson.get("point_code") != null) {
|
||||
|
||||
@@ -14,9 +14,10 @@ import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.modules.wql.util.WqlUtil;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.pdm.ivt.service.DeliveryPointIvtService;
|
||||
import org.nl.wms.pdm.ivt.service.dto.DeliveryPointIvtDto;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
@@ -33,12 +34,12 @@ import java.util.Map;
|
||||
@RequiredArgsConstructor
|
||||
@Slf4j
|
||||
public class DeliveryPointIvtServiceImpl implements DeliveryPointIvtService {
|
||||
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public Map<String, Object> queryAll(Map whereJson, Pageable page) {
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
JSONObject map = new JSONObject();
|
||||
map.put("flag", "1");
|
||||
if (!ObjectUtil.isNull(whereJson.get("point_code"))) {
|
||||
|
||||
@@ -21,9 +21,8 @@ import org.nl.modules.wql.util.WqlUtil;
|
||||
import org.nl.system.service.param.impl.SysParamServiceImpl;
|
||||
import org.nl.wms.basedata.master.interfaceback.service.dao.InterfaceBack;
|
||||
import org.nl.wms.basedata.master.interfaceback.service.dao.mapper.InterfaceBackMapper;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.ext.mes.service.LmsToMesService;
|
||||
import org.nl.wms.ext.mes.service.impl.LmsToMesServiceImpl;
|
||||
import org.nl.wms.pdm.ivt.service.HotPointIvtService;
|
||||
import org.nl.wms.pdm.ivt.service.dto.HotPointIvtDto;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -48,12 +47,12 @@ public class HotPointIvtServiceImpl implements HotPointIvtService {
|
||||
private InterfaceBackMapper interfaceBackMapper;
|
||||
@Autowired
|
||||
private RedisUtils redisUtils;
|
||||
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public Map<String, Object> queryAll(Map whereJson, Pageable page) {
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
HashMap map = new HashMap();
|
||||
map.put("flag", "1");
|
||||
if (whereJson.get("point_code") != null) {
|
||||
|
||||
@@ -14,9 +14,10 @@ import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.modules.wql.util.WqlUtil;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.pdm.ivt.service.PackagePointIvtService;
|
||||
import org.nl.wms.pdm.ivt.service.dto.PackagePointIvtDto;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
@@ -33,12 +34,12 @@ import java.util.Map;
|
||||
@RequiredArgsConstructor
|
||||
@Slf4j
|
||||
public class PackagePointIvtServiceImpl implements PackagePointIvtService {
|
||||
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public Map<String, Object> queryAll(Map whereJson, Pageable page) {
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
JSONObject map = new JSONObject();
|
||||
map.put("flag", "1");
|
||||
if (!ObjectUtil.isNull(whereJson.get("point_code"))) {
|
||||
|
||||
@@ -14,9 +14,10 @@ import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.modules.wql.util.WqlUtil;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.pdm.ivt.service.SbPointIvtService;
|
||||
import org.nl.wms.pdm.ivt.service.dto.SbPointIvtDto;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
@@ -33,12 +34,12 @@ import java.util.Map;
|
||||
@RequiredArgsConstructor
|
||||
@Slf4j
|
||||
public class SbPointIvtServiceImpl implements SbPointIvtService {
|
||||
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public Map<String, Object> queryAll(Map whereJson, Pageable page) {
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
JSONObject map = new JSONObject();
|
||||
map.put("flag", "1");
|
||||
if (!ObjectUtil.isNull(whereJson.get("point_code"))) {
|
||||
|
||||
@@ -15,9 +15,10 @@ import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.modules.wql.util.WqlUtil;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.pdm.service.RawfoilworkorderService;
|
||||
import org.nl.wms.pdm.service.dto.RawfoilworkorderDto;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
@@ -34,7 +35,8 @@ import java.util.Map;
|
||||
@RequiredArgsConstructor
|
||||
@Slf4j
|
||||
public class RawfoilworkorderServiceImpl implements RawfoilworkorderService {
|
||||
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public Map<String, Object> queryAll(Map whereJson, Pageable page) {
|
||||
String product_area = MapUtil.getStr(whereJson, "product_area");
|
||||
@@ -45,8 +47,7 @@ public class RawfoilworkorderServiceImpl implements RawfoilworkorderService {
|
||||
String end_time = MapUtil.getStr(whereJson, "end_time");
|
||||
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
|
||||
JSONObject map = new JSONObject();
|
||||
map.put("flag", "1");
|
||||
|
||||
@@ -19,7 +19,7 @@ import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.modules.wql.util.WqlUtil;
|
||||
import org.nl.wms.basedata.master.interfaceback.service.dao.InterfaceBack;
|
||||
import org.nl.wms.basedata.master.interfaceback.service.dao.mapper.InterfaceBackMapper;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.ext.mes.service.LmsToMesService;
|
||||
import org.nl.wms.pdm.service.SlittingproductionplanService;
|
||||
import org.nl.wms.pdm.service.dto.SlittingproductionplanDto;
|
||||
@@ -45,6 +45,8 @@ public class SlittingproductionplanServiceImpl implements Slittingproductionplan
|
||||
private final LmsToMesService lmsToMesService;
|
||||
@Autowired
|
||||
private InterfaceBackMapper interfaceBackMapper;
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public Map<String, Object> queryAll(Map whereJson, Pageable page) {
|
||||
String order_type = MapUtil.getStr(whereJson, "order_type");
|
||||
@@ -62,8 +64,7 @@ public class SlittingproductionplanServiceImpl implements Slittingproductionplan
|
||||
String end_time = MapUtil.getStr(whereJson, "end_time");
|
||||
|
||||
//获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
|
||||
JSONObject map = new JSONObject();
|
||||
map.put("flag", "1");
|
||||
|
||||
@@ -19,7 +19,7 @@ import org.nl.modules.wql.util.SpringContextHolder;
|
||||
import org.nl.modules.wql.util.WqlUtil;
|
||||
import org.nl.wms.basedata.master.classstandard.service.dao.ClassStandard;
|
||||
import org.nl.wms.basedata.master.classstandard.service.dao.mapper.ClassStandardMapper;
|
||||
import org.nl.wms.basedata.st.service.impl.UserAreaServiceImpl;
|
||||
import org.nl.wms.basedata.st.areapermissions.service.IUserAreaPermissionService;
|
||||
import org.nl.wms.sch.manage.TaskStatusEnum;
|
||||
import org.nl.wms.sch.service.TaskService;
|
||||
import org.redisson.api.RLock;
|
||||
@@ -48,7 +48,8 @@ public class TaskServiceImpl implements TaskService {
|
||||
private final RedissonClient redissonClient;
|
||||
@Autowired
|
||||
private ClassStandardMapper classStandardMapper;
|
||||
|
||||
@Autowired
|
||||
IUserAreaPermissionService userAreaPermissionService;
|
||||
@Override
|
||||
public Map<String, Object> queryAll(Map form, Pageable page) {
|
||||
|
||||
@@ -98,8 +99,7 @@ public class TaskServiceImpl implements TaskService {
|
||||
map.put("is_delete", whereJson.getString("is_delete"));
|
||||
}
|
||||
// 获取人员对应的区域
|
||||
UserAreaServiceImpl userAreaService = new UserAreaServiceImpl();
|
||||
String in_area_id = userAreaService.getInArea();
|
||||
String in_area_id = userAreaPermissionService.getInArea();
|
||||
if (ObjectUtil.isNotEmpty(in_area_id)) {
|
||||
map.put("in_area_id", in_area_id);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user