use of com.ikoori.vip.common.persistence.model.MemberCard in project vip by guangdada.
the class MemberServiceImpl method deleteMember.
@Override
@Transactional(readOnly = false, propagation = Propagation.REQUIRED)
public void deleteMember(Long memberId) {
Member member = this.selectById(memberId);
MemberCard mc = new MemberCard();
mc.setMemberId(member.getId());
mc = memberCardMapper.selectOne(mc);
memberCardMapper.deleteById(mc.getId());
this.deleteById(memberId);
}
use of com.ikoori.vip.common.persistence.model.MemberCard in project vip by guangdada.
the class MemberCardController method list.
/**
* 获取领取记录列表
*/
@Permission
@RequestMapping(value = "/list")
@ResponseBody
public Object list(String cardNumber, String cardName, Long cardId, String mobile, String nickname, Integer state, Integer grantType) {
Long userId = Long.valueOf(ShiroKit.getUser().getId());
Merchant merchant = merchantService.getMerchantUserId(userId);
Page<MemberCard> page = new PageFactory<MemberCard>().defaultPage();
List<Map<String, Object>> result = memberCardService.getMemberCardList(cardId, grantType, state, mobile, page, nickname, page.getOrderByField(), page.isAsc(), merchant.getId(), cardNumber);
page.setRecords((List<MemberCard>) new MemberCardWarpper(result).warp());
return super.packForBT(page);
}
Aggregations