| | |
| | | import com.dsh.course.feignClient.account.model.TAppUser; |
| | | import com.dsh.course.feignClient.activity.CouponClient; |
| | | import com.dsh.course.feignClient.activity.model.HuiminPayQuery; |
| | | import com.dsh.guns.config.UserExt; |
| | | import com.dsh.guns.core.base.controller.BaseController; |
| | | import com.dsh.guns.core.base.tips.SuccessTip; |
| | | import com.dsh.guns.modular.system.model.*; |
| | |
| | | private AppUserClient appUserClient; |
| | | @Autowired |
| | | private VipPaymentClient vipPaymentClient; |
| | | @Autowired |
| | | private IUserService userService; |
| | | @Autowired |
| | | private IRoleService roleService; |
| | | @Autowired |
| | | private ITSiteService siteService; |
| | | @Autowired |
| | |
| | | @RequestMapping(value = "/refund") |
| | | @ResponseBody |
| | | public Object list(@RequestBody VipRefundDto vipRefundDto) { |
| | | Integer objectId = UserExt.getUser().getObjectId(); |
| | | User user = userService.getById(UserExt.getUser().getId()); |
| | | String roleid = user.getRoleid(); |
| | | Role role = roleService.getById(roleid); |
| | | if (!role.getName().contains("财务")){ |
| | | return ResultUtil.error("权限不足"); |
| | | } |
| | | String code =vipPaymentClient.refund(vipRefundDto); |
| | | if (code!=null&& code.equals("200")){ |
| | | return ResultUtil.success(); |
| | | return ResultUtil.success("操作成功"); |
| | | }else{ |
| | | return ResultUtil.error("退费失败"); |
| | | } |