Browse Source

fix

photo
winter 1 year ago
parent
commit
977f7c05a2
2 changed files with 4 additions and 2 deletions
  1. +3
    -0
      suimangAdmin/src/main/java/com/iformall/controller/sm/ServiceInfoController.java
  2. +1
    -2
      suimangService/src/main/java/com/iformall/service/sm/impl/ServiceInfoServiceImpl.java

+ 3
- 0
suimangAdmin/src/main/java/com/iformall/controller/sm/ServiceInfoController.java View File

@@ -136,6 +136,9 @@ public class ServiceInfoController extends MallUserInfoBaseController{
if (null == si) {
throw new BizException(ErrorCode.SYS_PARAMETER_NOT_NULL.getCode(),"id无效");
}
if (null == times) {
throw new BizException(ErrorCode.SYS_PARAMETER_NOT_NULL.getCode(),"times无效");
}
si.setRemainingTimes(times);
serviceInfoService.updateServiceInfo(si);
return R.ok();


+ 1
- 2
suimangService/src/main/java/com/iformall/service/sm/impl/ServiceInfoServiceImpl.java View File

@@ -96,8 +96,7 @@ public class ServiceInfoServiceImpl implements ServiceInfoService {
public ServiceInfo getServiceInfo(Long id) {
ServiceInfo serviceInfo = new ServiceInfo();
serviceInfo.setId(id);
List<ServiceInfo> serviceInfos = serviceInfoMapper.listServiceInfo(serviceInfo);
return !CollectionUtils.isEmpty(serviceInfos) ? serviceInfos.get(0) : null;
return serviceInfoMapper.selectById(id);
}

@Override


Loading…
Cancel
Save