You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
57 lines
2.0 KiB
57 lines
2.0 KiB
package com.hai.service.impl;
|
|
|
|
import com.hai.common.utils.MD5Util;
|
|
import com.hai.dao.OutRechargeUserMapper;
|
|
import com.hai.entity.OutRechargeUser;
|
|
import com.hai.entity.SecUser;
|
|
import com.hai.model.OutRechargeUserModel;
|
|
import com.hai.service.OutRechargeUserService;
|
|
import com.hai.service.SecUserService;
|
|
import org.springframework.stereotype.Service;
|
|
|
|
import javax.annotation.Resource;
|
|
import java.util.Date;
|
|
import java.util.List;
|
|
import java.util.Map;
|
|
|
|
@Service("outRechargeUserServiceImpl")
|
|
public class OutRechargeUserServiceImpl implements OutRechargeUserService {
|
|
|
|
@Resource
|
|
private OutRechargeUserMapper outRechargeUserMapper;
|
|
|
|
@Resource
|
|
private SecUserService secUserService;
|
|
|
|
@Override
|
|
public List<OutRechargeUser> getListRechargeUser(Map<String, String> map) {
|
|
return null;
|
|
}
|
|
|
|
@Override
|
|
public OutRechargeUser findById(Long agentId) {
|
|
return null;
|
|
}
|
|
|
|
@Override
|
|
public void insertRechargeUser(OutRechargeUserModel outRechargeUserModel) throws Exception {
|
|
outRechargeUserMapper.insert(outRechargeUserModel);
|
|
|
|
outRechargeUserModel.getSecUser().setUserName(outRechargeUserModel.getRechargeName());
|
|
outRechargeUserModel.getSecUser().setLoginName(outRechargeUserModel.getSecUser().getLoginName());
|
|
outRechargeUserModel.getSecUser().setPassword(MD5Util.encode(outRechargeUserModel.getSecUser().getPassword().getBytes()));
|
|
outRechargeUserModel.getSecUser().setAdminFlag(1);
|
|
outRechargeUserModel.getSecUser().setStatus(1);
|
|
outRechargeUserModel.getSecUser().setRoleId(6L);
|
|
outRechargeUserModel.getSecUser().setObjectType(5);
|
|
outRechargeUserModel.getSecUser().setObjectId(outRechargeUserModel.getId());
|
|
outRechargeUserModel.getSecUser().setCreateTime(new Date());
|
|
outRechargeUserModel.getSecUser().setUpdateTime(new Date());
|
|
secUserService.addUser(outRechargeUserModel.getSecUser());
|
|
}
|
|
|
|
@Override
|
|
public void updateRechargeUser(OutRechargeUserModel outRechargeUserModel) {
|
|
|
|
}
|
|
}
|
|
|