记得上下班打卡 | git大法好,push需谨慎

Commit 4504931e authored by 胡佳晨's avatar 胡佳晨

修改积分商品下单

parent db840ffd
......@@ -132,10 +132,10 @@ public class ItemServiceImpl implements IItemService {
if (param.getStatus() == 2 & (param.getStartTime() == null || param.getEndTime() == null)) {
return "时间有误";
}
if(param.getType()==11){
if (param.getType() == 11) {
param.setTargetId("-999");
}else{
if(param.getType()==1 && param.getTargetId()==null){
} else {
if (param.getType() == 1 && param.getTargetId() == null) {
return "参数异常";
}
}
......@@ -164,10 +164,10 @@ public class ItemServiceImpl implements IItemService {
if (param.getStatus() == 2 & (param.getStartTime() == null || param.getEndTime() == null)) {
return "时间有误";
}
if(param.getType()==11){
if (param.getType() == 11) {
param.setTargetId("-999");
}else{
if(param.getType()==1 && param.getTargetId()==null){
} else {
if (param.getType() == 1 && param.getTargetId() == null) {
return "参数异常";
}
}
......@@ -201,7 +201,7 @@ public class ItemServiceImpl implements IItemService {
StoneScoreItems data = new StoneScoreItems();
data.setTargetId(param.getTargetId());
data.setTargetTitle(param.getTargetTitle());
data.setType(1);
data.setType(param.getType());
data.setImg(param.getImg());
data.setScore(param.getScore());
data.setPrice(BigDecimal.ZERO);
......@@ -210,10 +210,10 @@ public class ItemServiceImpl implements IItemService {
data.setDetails(param.getDetails());
data.setNotice(param.getNotice());
data.setStatus(param.getStatus());
if(param.getStartTime()!=null) {
if (param.getStartTime() != null) {
data.setStartTime(LocalDateTime.parse(param.getStartTime(), DateTimeFormatter.ofPattern(DateUtils.YYYY_MM_DD_HH_MM_SS)));
}
if(param.getEndTime()!=null) {
if (param.getEndTime() != null) {
data.setEndTime(LocalDateTime.parse(param.getEndTime(), DateTimeFormatter.ofPattern(DateUtils.YYYY_MM_DD_HH_MM_SS)));
}
return data;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment