This commit is contained in:
2022-12-05 11:43:18 +08:00
parent 7ec52b45c8
commit f8144305f2
15 changed files with 93 additions and 59 deletions

View File

@@ -168,10 +168,10 @@ public class UserController {
String oldPass = RsaUtils.decryptByPrivateKey(RsaProperties.privateKey,passVo.getOldPass());
String newPass = RsaUtils.decryptByPrivateKey(RsaProperties.privateKey,passVo.getNewPass());
UserDto user = userService.findByName(SecurityUtils.getCurrentUsername());
if (!SaSecureUtil.md5BySalt(user.getPassword(), "salt").equals(SaSecureUtil.md5BySalt(oldPass, "salt"))) {
if (!user.getPassword().equals(SaSecureUtil.md5BySalt(oldPass, "salt"))) {
throw new BadRequestException("修改失败,旧密码错误");
}
if (!SaSecureUtil.md5BySalt(user.getPassword(), "salt").equals(SaSecureUtil.md5BySalt(newPass, "salt"))) {
if (user.getPassword().equals(SaSecureUtil.md5BySalt(newPass, "salt"))) {
throw new BadRequestException("新密码不能与旧密码相同");
}
userService.updatePass(user.getUsername(),SaSecureUtil.md5BySalt(newPass, "salt"));

View File

@@ -70,7 +70,7 @@ public class LmsToMesServiceImpl implements LmsToMesService {
} catch (Exception e) {
throw new BadRequestException(e.getMessage());
throw new BadRequestException("MES提示错误"+e.getMessage());
}
return result;
}
@@ -113,7 +113,7 @@ public class LmsToMesServiceImpl implements LmsToMesService {
} catch (Exception e) {
throw new BadRequestException(e.getMessage());
throw new BadRequestException("MES提示错误"+e.getMessage());
}
return result;
}
@@ -156,7 +156,7 @@ public class LmsToMesServiceImpl implements LmsToMesService {
} catch (Exception e) {
throw new BadRequestException(e.getMessage());
throw new BadRequestException("MES提示错误"+e.getMessage());
}
return result;
}
@@ -200,7 +200,7 @@ public class LmsToMesServiceImpl implements LmsToMesService {
} catch (Exception e) {
throw new BadRequestException(e.getMessage());
throw new BadRequestException("MES提示错误"+e.getMessage());
}
return result;
}
@@ -250,7 +250,7 @@ public class LmsToMesServiceImpl implements LmsToMesService {
} catch (Exception e) {
throw new BadRequestException(e.getMessage());
throw new BadRequestException("MES提示错误"+e.getMessage());
}
return result;
}
@@ -311,7 +311,7 @@ public class LmsToMesServiceImpl implements LmsToMesService {
} catch (Exception e) {
throw new BadRequestException(e.getMessage());
throw new BadRequestException("MES提示错误"+e.getMessage());
}
return result;
}
@@ -362,7 +362,7 @@ public class LmsToMesServiceImpl implements LmsToMesService {
} catch (Exception e) {
throw new BadRequestException(e.getMessage());
throw new BadRequestException("MES提示错误"+e.getMessage());
}
return result;
}
@@ -413,7 +413,7 @@ public class LmsToMesServiceImpl implements LmsToMesService {
String RTYPE = result.getString("RTYPE");
if (RTYPE.equals("E")){
throw new BadRequestException("MES提示错误"+result.getString("RTMSG"));
throw new BadRequestException(result.getString("RTMSG"));
}
@@ -458,7 +458,7 @@ public class LmsToMesServiceImpl implements LmsToMesService {
String RTYPE = result.getString("RTYPE");
if (RTYPE.equals("E")){
throw new BadRequestException("MES提示错误"+result.getString("RTMSG"));
throw new BadRequestException(result.getString("RTMSG"));
}

View File

@@ -67,7 +67,7 @@ public class LmsToSapServiceImpl implements LmsToSapService {
String type = result.getString("TYPE");
if (StrUtil.equals(type, "E")) {
throw new BadRequestException("SAP提示错误"+result.getString("MESSAGE"));
throw new BadRequestException(result.getString("MESSAGE"));
}
} catch (Exception e) {
@@ -131,7 +131,7 @@ public class LmsToSapServiceImpl implements LmsToSapService {
String type = result.getString("TYPE");
if (StrUtil.equals(type, "E")) {
throw new BadRequestException("SAP提示错误"+result.getString("MESSAGE"));
throw new BadRequestException(result.getString("MESSAGE"));
}
} catch (Exception e) {

View File

@@ -9,10 +9,10 @@ public enum RegionTypeEnum {
B_FQ("06","B分切区","1587360208328462336"),
C_FQ("07","C分切区","1587360496145797120"),
D_FQ("08","D分切区","1587360569458036736"),
A_HKZC("09","A烘烤暂存区","1578657813205487616"),
B_HKZC("10","B烘烤暂存区","1587360656355627008"),
C_HKZC("11","C烘烤暂存区","1587360700223852544"),
D_HKZC("12","D烘烤暂存区","1587360741864902656"),
A_HKZC("09","A1烘烤暂存区","1578657813205487616"),
B_HKZC("10","A2烘烤暂存区","1587360656355627008"),
C_HKZC("11","A3烘烤暂存区","1587360700223852544"),
D_HKZC("12","A4烘烤暂存区","1587360741864902656"),
ZC01("13","主存区","1582991348217286656"),
KTP01("14","空托盘区","1582991511971303424"),
ZZ01("15","中转区","1582995342054526976"),

View File

@@ -122,16 +122,16 @@ public class BakingServiceImpl implements BakingService {
String reging_id = "";
switch (product_area) {
case "A":
case "A1":
reging_id = RegionTypeEnum.A_HKZC.getId();
break;
case "B":
case "A2":
reging_id = RegionTypeEnum.B_HKZC.getId();
break;
case "C":
case "A3":
reging_id = RegionTypeEnum.C_HKZC.getId();
break;
case "D":
case "A4":
reging_id = RegionTypeEnum.D_HKZC.getId();
break;
}
@@ -247,16 +247,16 @@ public class BakingServiceImpl implements BakingService {
String product_area = jsonHotIvt.getString("product_area");
String reging_id = "";
switch (product_area) {
case "A":
case "A1":
reging_id = RegionTypeEnum.A_HKZC.getId();
break;
case "B":
case "A2":
reging_id = RegionTypeEnum.B_HKZC.getId();
break;
case "C":
case "A3":
reging_id = RegionTypeEnum.C_HKZC.getId();
break;
case "D":
case "A4":
reging_id = RegionTypeEnum.D_HKZC.getId();
break;
}

View File

@@ -56,10 +56,10 @@ public class RawFoilServiceImpl implements RawFoilService {
map.put("container_name", container_name);
map.put("product_area", product_area);
// 如果都为空则默认区域为 A
/*// 如果都为空则默认区域为 A1
if (ObjectUtil.isEmpty(point_code) && ObjectUtil.isEmpty(container_name) && ObjectUtil.isEmpty(product_area)) {
map.put("product_area", "A");
}
map.put("product_area", "A1");
}*/
JSONArray arr = WQL.getWO("PDA_RAWFOIL_01").addParamMap(map).process().getResultJSONArray(0);
for (int i = 0; i < arr.size(); i++) {

View File

@@ -180,7 +180,7 @@ public class ShippingServiceImpl implements ShippingService {
}
//根据起点判断区域查询对应的输送线空点位
JSONObject point_jo = WQL.getWO("PDA_02").addParam("flag","4").addParam("product_area","A").process().uniqueResult(0);
JSONObject point_jo = WQL.getWO("PDA_02").addParam("flag","4").addParam("product_area","A1").process().uniqueResult(0);
//下发输送线任务
JSONObject form = new JSONObject();
form.put("point_code1",point_code);

View File

@@ -46,10 +46,10 @@ public class CoolCutTask extends AbstractAcsTask {
String product_area = json.getString("product_area");
String agv_system_type = "";
if (product_area.equals("A")||product_area.equals("B")){
if (product_area.equals("A1")||product_area.equals("A2")){
agv_system_type = "2";
}
if (product_area.equals("C")||product_area.equals("D")){
if (product_area.equals("A3")||product_area.equals("A4")){
agv_system_type = "3";
}
AcsTaskDto dto = AcsTaskDto.builder()