提交代码

master
胡锐 12 months ago
parent db2ddd9cfd
commit 65109902bf
  1. 12
      cweb/src/main/java/com/cweb/controller/group/BsStoreProductController.java
  2. 3
      service/src/main/java/com/hfkj/service/meal/impl/BsMealTableOrderServiceImpl.java
  3. 2
      service/src/main/java/com/hfkj/service/meal/impl/BsMealTableServiceImpl.java

@ -106,7 +106,7 @@ public class BsStoreProductController {
}
UserInfoModel userInfoModel = userCenter.getSessionModel(UserInfoModel.class);
if (userInfoModel == null || userInfoModel.getSalesman() == null) {
if (userInfoModel == null) {
throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "该角色暂无权限");
}
@ -120,8 +120,8 @@ public class BsStoreProductController {
storeProduct.setStatus(1);
storeProduct.setCreateTime(new Date());
storeProduct.setUpdateTime(new Date());
storeProduct.setOpId(userInfoModel.getSalesman().getId());
storeProduct.setOpName(userInfoModel.getSalesman().getName());
storeProduct.setOpId(userInfoModel.getSecUser().getId());
storeProduct.setOpName(userInfoModel.getSecUser().getUserName());
storeProduct.setSaleCount(0);
storeGroupService.insertStoreProduct(storeProduct);
@ -155,7 +155,7 @@ public class BsStoreProductController {
}
UserInfoModel userInfoModel = userCenter.getSessionModel(UserInfoModel.class);
if (userInfoModel == null || userInfoModel.getSalesman() == null) {
if (userInfoModel == null) {
throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "该角色暂无权限");
}
@ -171,8 +171,8 @@ public class BsStoreProductController {
bsStoreProduct.setProductCategoryId(category.getId());
bsStoreProduct.setProductCategoryName(category.getName());
bsStoreProduct.setUpdateTime(new Date());
bsStoreProduct.setOpId(userInfoModel.getSalesman().getId());
bsStoreProduct.setOpName(userInfoModel.getSalesman().getName());
bsStoreProduct.setOpId(userInfoModel.getSecUser().getId());
bsStoreProduct.setOpName(userInfoModel.getSecUser().getUserName());
bsStoreProduct.setName(storeProduct.getName());
bsStoreProduct.setSpec(storeProduct.getSpec());
bsStoreProduct.setPrice(storeProduct.getPrice());

@ -124,6 +124,9 @@ public class BsMealTableOrderServiceImpl implements BsMealTableOrderService {
// 查询订单详情
BsMealTableOrder mealTableOrder = getTableOrderByPayOrderNo(tradeOrder.getOutTradeNo());
if (mealTableOrder != null) {
mealTableOrder.setPayPrice(tradeOrder.getTradeAmount());
editData(mealTableOrder);
// 关台
mealTableService.endTable(mealTableOrder.getSerialNumber());
}

@ -241,7 +241,7 @@ public class BsMealTableServiceImpl implements BsMealTableService {
BsMealTableOrder tableOrder = mealTableOrderService.getCurrentTableOrder(serialNumber);
if (tableOrder != null) {
tableOrder.setStatus(MealTableOrderStatusEnum.status2.getNumber());
tableOrder.setPayStatus(MealTableOrderPayStatusEnum.status2.getNumber());
tableOrder.setPayStatus(MealTableOrderPayStatusEnum.status3.getNumber());
tableOrder.setPayTime(new Date());
mealTableOrderService.editData(tableOrder);

Loading…
Cancel
Save