|
@@ -396,8 +396,8 @@ public class SceneCooperationServiceImpl extends ServiceImpl<ISceneCooperationMa
|
|
|
|
|
|
|
|
|
private ProductOrder checkNeedPay(List<String> numList, List<User> users,User loginUser,Integer payType,Integer timeZone,Long cameraId,String lang,String sceneType) {
|
|
|
- HashMap<Long,String> needNumListMesh = new HashMap<>();
|
|
|
- HashMap<Long,String> needNumListLaser =new HashMap<>();
|
|
|
+ HashMap<String,String> needNumListMesh = new HashMap<>();
|
|
|
+ HashMap<String,String> needNumListLaser =new HashMap<>();
|
|
|
if(StringUtils.isBlank(sceneType)){
|
|
|
needNumListMesh = getTotalCount(numList,users,"mesh",cameraId);
|
|
|
needNumListLaser = getTotalCount(numList,users,"laser",cameraId);
|
|
@@ -413,13 +413,13 @@ public class SceneCooperationServiceImpl extends ServiceImpl<ISceneCooperationMa
|
|
|
|
|
|
}
|
|
|
|
|
|
- private HashMap<Long,String> getTotalCount(List<String> numList, List<User> users,String sceneType,Long cameraId){
|
|
|
+ private HashMap<String,String> getTotalCount(List<String> numList, List<User> users,String sceneType,Long cameraId){
|
|
|
List<SceneCooperationCount> freeCountList = sceneCooperationCountService.getByNumList(numList,sceneType);
|
|
|
HashMap<String,Integer> freeMap = new HashMap<>();
|
|
|
freeCountList.forEach(e -> freeMap.put(e.getNum(),e.getCount()));
|
|
|
|
|
|
HashMap<String, List<User>> map = this.getByNumList(numList,sceneType);
|
|
|
- HashMap<Long,String> needNumList = new HashMap<>();
|
|
|
+ HashMap<String,String> needNumList = new HashMap<>();
|
|
|
for (String num : numList) {
|
|
|
Integer freeCount = freeMap.get(num) == null ? 1 :freeMap.get(num);
|
|
|
|
|
@@ -433,7 +433,7 @@ public class SceneCooperationServiceImpl extends ServiceImpl<ISceneCooperationMa
|
|
|
}
|
|
|
|
|
|
for (int i = 0 ; i< users.size() -freeCount;i++){
|
|
|
- needNumList.put(users.get(i).getId(),num);
|
|
|
+ needNumList.put(users.get(i).getId()+","+num,num);
|
|
|
}
|
|
|
|
|
|
}
|