| | |
| | | |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.dsh.course.feignClient.account.AppUserClient; |
| | | import com.dsh.course.feignClient.account.CityManagerClient; |
| | | import com.dsh.course.feignClient.account.StoreStaffClient; |
| | | import com.dsh.course.feignClient.account.model.CityManager; |
| | | import com.dsh.course.feignClient.account.model.QueryByNamePhone; |
| | | import com.dsh.course.feignClient.account.model.TAppUser; |
| | | import com.dsh.course.feignClient.account.model.TStoreStaff; |
| | | import com.dsh.course.feignClient.activity.CouponClient; |
| | | import com.dsh.course.feignClient.activity.PointMercharsClient; |
| | | import com.dsh.course.feignClient.activity.model.*; |
| | |
| | | import com.dsh.guns.modular.system.service.IStoreService; |
| | | import com.dsh.guns.modular.system.util.OBSUploadUtil; |
| | | import com.dsh.guns.modular.system.util.ResultUtil; |
| | | import net.bytebuddy.asm.Advice; |
| | | import org.omg.CORBA.PRIVATE_MEMBER; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.ui.Model; |
| | |
| | | |
| | | @Resource |
| | | private PointMercharsClient pointMercharsClient; |
| | | @Autowired |
| | | private StoreStaffClient storeStaffClient; |
| | | |
| | | /** |
| | | * 跳转到优惠券管理首页 |
| | |
| | | System.out.println(b); |
| | | return new SuccessTip<>(); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 上下架处理操作 |
| | | * @return |
| | | */ |
| | | @RequestMapping("/writeOff") |
| | | @ResponseBody |
| | | public Object writeOff(String id) { |
| | | Long aLong = Long.valueOf(id); |
| | | WriteOffDTO dto = new WriteOffDTO(); |
| | | // 核销人员id |
| | | Integer objectId = UserExt.getUser().getId(); |
| | | if (UserExt.getUser().getObjectType() == 1){ |
| | | dto.setVerifiStoreId(null); |
| | | }else if (UserExt.getUser().getObjectType() == 2){ |
| | | storeService.getOne(new QueryWrapper<TStore>().eq("cityManagerId",objectId)); |
| | | }else{ |
| | | TStoreStaff storeByStoreStaffId = storeStaffClient.getStoreByStoreStaffId(objectId); |
| | | dto.setVerifiStoreId(storeByStoreStaffId.getStoreId()); |
| | | } |
| | | dto.setId(aLong); |
| | | dto.setVerificationUserId(objectId); |
| | | pointMercharsClient.writeOff(dto); |
| | | return new SuccessTip<>(); |
| | | } |
| | | |
| | | /** |
| | | * 购买详情 |