无关风月
2024-07-11 eb6b6dbb35a9f029e0b7d269773685c19fd40976
cloud-server-other/src/main/java/com/dsh/other/controller/SiteController.java
@@ -15,6 +15,7 @@
import com.dsh.other.feignclient.model.BillingDataRequestVo;
import com.dsh.other.feignclient.model.SiteChangeStateVO;
import com.dsh.other.feignclient.model.SiteVo;
import com.dsh.other.mapper.TOperatorUserMapper;
import com.dsh.other.model.*;
import com.dsh.other.model.dto.siteDto.TSiteDTO;
import com.dsh.other.model.vo.siteVo.ExpireSiteSearchVO;
@@ -64,7 +65,34 @@
    private UserCouponClient userCouponClient;
    @Autowired
    private CityManagerClient cityManagerClient;
    @Autowired
    private IOperatorUserService operatorUserService;
    /**
     * 通过运营商id查询运营商对应的支付宝商户号
     */
    @RequestMapping("/base/getSMIDByOperatorId")
    @ResponseBody
    public String getSMIDByOperatorId(Integer id) {
        // 获取运营商的管理员
        return siteService.getSMIDByOperatorId(id);
    }/**
     * 根据运营商id获取对应运营商分账比例 返回格式: 微信分账比例,支付宝分账比例
     */
    @RequestMapping("/base/getProportionByOperatorId")
    @ResponseBody
    public String getProportionByOperatorId(Integer id) {
        OperatorUser operatorId = operatorUserService.getOne(
                new QueryWrapper<OperatorUser>().eq("operatorId",id)
        );
        if (operatorId.getWechatProportion() == null){
            operatorId.setWechatProportion("0");
        }
        if (operatorId.getAlipayProportion() == null){
            operatorId.setAlipayProportion("0");
        }
        return operatorId.getWechatProportion()+","+operatorId.getAlipayProportion();
    }
    /**
     * 获取所有场地
     */
@@ -340,7 +368,6 @@
        }
    }
    /**
     * 预约场地支付宝回调
     *
@@ -356,7 +383,8 @@
            if (null != map) {
                String code = map.get("out_trade_no");
                String trade_no = map.get("trade_no");
                SiteBooking siteBooking = siteBookingService.getOne(new QueryWrapper<SiteBooking>().eq("orderNo", code).eq("state", 1));
                SiteBooking siteBooking = siteBookingService.getOne(new QueryWrapper<SiteBooking>()
                        .eq("orderNo", code).eq("state", 1));
                if (siteBooking.getStatus() == 0) {
                    siteBooking.setPayTime(new Date());
                    siteBooking.setStatus(1);
@@ -689,10 +717,6 @@
    @Autowired
    private StoreService service;
    @Autowired
    private IOperatorUserService operatorUserService;
    @ResponseBody
    @PostMapping("/base/site/game")