收银台
This commit is contained in:
parent
4feda12365
commit
c31617ed7f
@ -5,8 +5,10 @@ import cn.hutool.core.util.ArrayUtil;
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import com.fuint.api.fuyou.entity.Builder;
|
||||
import com.fuint.api.fuyou.entity.Const;
|
||||
import com.fuint.api.fuyou.entity.MerchantConfig;
|
||||
import com.fuint.api.fuyou.entity.Message;
|
||||
import com.fuint.api.fuyou.service.FyPayService;
|
||||
import com.fuint.api.fuyou.service.MerchantConfigService;
|
||||
import com.fuint.api.fuyou.util.Utils;
|
||||
import com.fuint.business.order.entity.CashierOrder;
|
||||
import com.fuint.business.order.entity.LJOrder;
|
||||
@ -89,6 +91,8 @@ public class FyPayServiceImpl implements FyPayService {
|
||||
return resMap;
|
||||
}
|
||||
|
||||
@Autowired
|
||||
private MerchantConfigService merchantConfigService;
|
||||
|
||||
@Override
|
||||
public Map<String, String> queryOrder(Map<String, String> map1) throws Exception {
|
||||
@ -99,6 +103,7 @@ public class FyPayServiceImpl implements FyPayService {
|
||||
String payType = map1.get("payType");
|
||||
String insCd = map1.get("insCd");
|
||||
String mchntCd = map1.get("mchntCd");
|
||||
Double allAmount = Double.valueOf(map1.get("allAmount"));
|
||||
Map<String, String> map = Builder.buildFuiou30();
|
||||
map.put("mchnt_order_no",orderNo);
|
||||
map.put("order_type",payType);
|
||||
@ -118,6 +123,7 @@ public class FyPayServiceImpl implements FyPayService {
|
||||
List<OilOrder> list = oilOrderService.selectOilOrder(orderNo);
|
||||
LJOrder goodsOrder = goodsOrderService.selectGoodsOrder(orderNo);
|
||||
CashierOrder cashierOrder = cashierOrderService.selectCashierOrder(orderNo);
|
||||
MerchantConfig merchantConfig = merchantConfigService.selectMeChByIsUse("1");
|
||||
Date date = new Date();
|
||||
if (reqMap.get("trans_stat").equals("SUCCESS")){
|
||||
if (!ObjectUtil.isEmpty(oilOrder)){
|
||||
@ -137,6 +143,10 @@ public class FyPayServiceImpl implements FyPayService {
|
||||
oilOrderService.updateOilOrder(order);
|
||||
}
|
||||
}
|
||||
// 修改商户账号余额信息
|
||||
Double amount = merchantConfig.getAmount();
|
||||
merchantConfig.setAmount(amount+allAmount);
|
||||
merchantConfigService.updateMerch(merchantConfig);
|
||||
resMap.put("msg","success");
|
||||
}else if (reqMap.get("trans_stat").equals("USERPAYING")){
|
||||
resMap.put("msg","unpaid");
|
||||
|
@ -33,7 +33,7 @@ public class UserBalance extends BaseEntity implements Serializable {
|
||||
/**
|
||||
* 所属连锁店id
|
||||
*/
|
||||
private Integer chainStorId;
|
||||
private Integer chainStoreId;
|
||||
/**
|
||||
* 所属店铺id
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user