|
|
@@ -364,8 +364,8 @@ public class FsUserInformationCollectionServiceImpl extends ServiceImpl<FsUserIn
|
|
|
}
|
|
|
} else {
|
|
|
//没有关联套餐包医生确认清空所有状态
|
|
|
-// map.setDoctorConfirm(0);
|
|
|
-// map.setUserConfirm(0);
|
|
|
+ map.setDoctorConfirm(0);
|
|
|
+ map.setUserConfirm(0);
|
|
|
}
|
|
|
|
|
|
if (fsUserInformationCollectionMapper.updateFsUserInformationCollection(map) > 0) {
|
|
|
@@ -394,9 +394,9 @@ public class FsUserInformationCollectionServiceImpl extends ServiceImpl<FsUserIn
|
|
|
|
|
|
if (collection != null) {
|
|
|
|
|
|
- if (!Objects.equals(collection.getUserId(), userId)) {
|
|
|
- return vo;
|
|
|
- }
|
|
|
+// if (!Objects.equals(collection.getUserId(), userId)) {
|
|
|
+// return vo;
|
|
|
+// }
|
|
|
if (collection.getIsPackage() == 1) {
|
|
|
vo.setPackageId(collection.getPackageId());
|
|
|
vo.setPayType(collection.getPayType());
|
|
|
@@ -450,6 +450,7 @@ public class FsUserInformationCollectionServiceImpl extends ServiceImpl<FsUserIn
|
|
|
@Override
|
|
|
@Transactional
|
|
|
public R userConfirm(CollectionInfoConfirmParam param) {
|
|
|
+
|
|
|
if (param.getId() == null) {
|
|
|
return R.error("参数错误");
|
|
|
}
|
|
|
@@ -462,6 +463,9 @@ public class FsUserInformationCollectionServiceImpl extends ServiceImpl<FsUserIn
|
|
|
return R.error("用户已确认");
|
|
|
}
|
|
|
}
|
|
|
+ if (!Objects.equals(collection.getUserId(), param.getUserId())) {
|
|
|
+ return R.error("用户信息不匹配,无法确认");
|
|
|
+ }
|
|
|
FsUserInformationCollection map = new FsUserInformationCollection();
|
|
|
map.setId(param.getId());
|
|
|
map.setUserConfirm(1);
|
|
|
@@ -473,23 +477,23 @@ public class FsUserInformationCollectionServiceImpl extends ServiceImpl<FsUserIn
|
|
|
if (collection.getStatus() == 1) {
|
|
|
map.setStatus(2);
|
|
|
}
|
|
|
-// else if (collection.getStatus() == 2) {
|
|
|
-// //清空订单号
|
|
|
-// fsUserInformationCollectionMapper.collectionOderCodeNULL(collection.getId());
|
|
|
-// map.setStatus(1);
|
|
|
-// map.setDoctorConfirm(0);
|
|
|
-// map.setUserConfirm(0);
|
|
|
-// map.setUserConfirm2(0);
|
|
|
-// FsStoreOrder fsStoreOrder = storeOrderService.selectFsStoreOrderByOrderCode(collection.getPackageOrderCode());
|
|
|
-// if (fsStoreOrder != null) {
|
|
|
-// FsStoreOrder editOrder = new FsStoreOrder();
|
|
|
-// editOrder.setOrderId(fsStoreOrder.getOrderId());
|
|
|
-// editOrder.setIsConfirm(1);
|
|
|
-// storeOrderService.updateFsStoreOrder(editOrder);
|
|
|
-// } else {
|
|
|
-// return R.error("没有找到订单");
|
|
|
-// }
|
|
|
-// }
|
|
|
+ else if (collection.getStatus() == 2) {
|
|
|
+ //清空订单号
|
|
|
+ fsUserInformationCollectionMapper.collectionOderCodeNULL(collection.getId());
|
|
|
+ map.setStatus(1);
|
|
|
+ map.setDoctorConfirm(0);
|
|
|
+ map.setUserConfirm(0);
|
|
|
+ map.setUserConfirm2(0);
|
|
|
+ FsStoreOrder fsStoreOrder = storeOrderService.selectFsStoreOrderByOrderCode(collection.getPackageOrderCode());
|
|
|
+ if (fsStoreOrder != null) {
|
|
|
+ FsStoreOrder editOrder = new FsStoreOrder();
|
|
|
+ editOrder.setOrderId(fsStoreOrder.getOrderId());
|
|
|
+ editOrder.setIsConfirm(1);
|
|
|
+ storeOrderService.updateFsStoreOrder(editOrder);
|
|
|
+ } else {
|
|
|
+ return R.error("没有找到订单");
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
if (fsUserInformationCollectionMapper.updateFsUserInformationCollection(map) > 0) {
|
|
|
//存入医生确认统计时间数据
|