| | |
| | | import cc.mrbird.febs.mall.mapper.MallMemberMapper; |
| | | import cc.mrbird.febs.mall.service.IApiMallAgentService; |
| | | import cn.hutool.core.util.ObjectUtil; |
| | | import com.baomidou.mybatisplus.core.conditions.Wrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import lombok.RequiredArgsConstructor; |
| | | import lombok.extern.slf4j.Slf4j; |
| | |
| | | //判断用户是否正在申请 |
| | | MallAgentRecord mallAgentRecord = mallAgentRecordMapper.selectByMemberIdAndState(memberId,MallAgentRecord.APPLY_ING); |
| | | if(ObjectUtil.isNotEmpty(mallAgentRecord)){ |
| | | return new FebsResponse().fail().message("用户已申请"); |
| | | mallAgentRecordMapper.deleteByMemberIdAndState(memberId,MallAgentRecord.APPLY_ING); |
| | | } |
| | | |
| | | MallAgentRecord mallAgentRecordNew = MallAgentRecordConversion.INSTANCE.dtoToEntity(apiAgentApplyDto); |