| | |
| | | |
| | | import com.ruoyi.common.core.domain.R; |
| | | import com.ruoyi.common.core.web.controller.BaseController; |
| | | import com.ruoyi.common.security.utils.SecurityUtils; |
| | | import com.ruoyi.system.api.domain.dto.AppMiniRegisterDto; |
| | | import com.ruoyi.system.api.domain.vo.AppMiniRegisterVo; |
| | | import com.ruoyi.member.service.member.MemberService; |
| | | import com.ruoyi.member.service.member.MemberCouponService; |
| | | import com.ruoyi.member.service.member.MemberService; |
| | | import com.ruoyi.system.api.domain.dto.AppMemberBindingDto; |
| | | import com.ruoyi.system.api.domain.dto.AppMemberGoodsTypeDto; |
| | | import com.ruoyi.system.api.domain.dto.AppMiniRegisterDto; |
| | | import com.ruoyi.system.api.domain.poji.member.Member; |
| | | import com.ruoyi.system.api.domain.vo.AppMemberCouponVo; |
| | | import com.ruoyi.system.api.domain.vo.AppMiniRegisterVo; |
| | | import com.ruoyi.system.api.model.AppMiniLoginDto; |
| | | import com.ruoyi.system.api.model.AppMiniLoginVo; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.List; |
| | | |
| | | @RestController |
| | | @RequestMapping("/member") |
| | | public class MemberController extends BaseController { |
| | | |
| | | @Autowired |
| | | @Resource |
| | | private MemberService memberService; |
| | | |
| | | @Autowired |
| | | @Resource |
| | | private MemberCouponService memberCouponService; |
| | | |
| | | /** |
| | |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | | * 更新会员商品类型 |
| | | * @param appMemberGoodsTypeDto |
| | | * @return |
| | | */ |
| | | @PostMapping("/updateMemberGoodsType") |
| | | public R updateMemberGoodsType(@RequestBody AppMemberGoodsTypeDto appMemberGoodsTypeDto) |
| | | { |
| | | memberService.updateMemberGoodsType(appMemberGoodsTypeDto); |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | | * 通过手机号获取会员 |
| | | * @param mobile |
| | | * @return |
| | | */ |
| | | @PostMapping("/getMemberByMobile") |
| | | public R<Member> getMemberByMobile(@RequestBody String mobile) |
| | | { |
| | | Member member = memberService.getByMobile(mobile); |
| | | return R.ok(member); |
| | | } |
| | | |
| | | /** |
| | | * 订单创建新用户 |
| | | * @param member |
| | | * @return |
| | | */ |
| | | @PostMapping("/createNewMember") |
| | | public R createNewMember(@RequestBody Member member) |
| | | { |
| | | memberService.createNewMember(member); |
| | | return R.ok(); |
| | | } |
| | | } |