| | |
| | | import com.yeshi.fanli.dao.mybatis.AccountMessageMapper;
|
| | | import com.yeshi.fanli.entity.bus.user.AccountMessage;
|
| | | import com.yeshi.fanli.entity.bus.user.BindingAccount;
|
| | | import com.yeshi.fanli.entity.bus.user.Extract;
|
| | | import com.yeshi.fanli.entity.bus.user.UserInfo;
|
| | | import com.yeshi.fanli.exception.PushException;
|
| | | import com.yeshi.fanli.log.LogHelper;
|
| | | import com.yeshi.fanli.service.inter.push.PushService;
|
| | | import com.yeshi.fanli.service.inter.user.SMSService;
|
| | | import com.yeshi.fanli.service.inter.user.UserInfoService;
|
| | | import com.yeshi.fanli.service.inter.user.UserNotificationService;
|
| | | import com.yeshi.fanli.util.Constant;
|
| | | import com.yeshi.fanli.util.StringUtil;
|
| | |
|
| | | @Service
|
| | | public class UserNotificationServiceImpl implements UserNotificationService {
|
| | |
| | |
|
| | | @Resource
|
| | | private PushService pushService;
|
| | |
|
| | | @Resource
|
| | | private SMSService smsService;
|
| | |
|
| | | @Resource
|
| | | private UserInfoService userInfoService;
|
| | |
|
| | | @Override
|
| | | public void newerHongBao(Long uid, BigDecimal money) {
|
| | |
| | | }
|
| | |
|
| | | @Override
|
| | | public void extractWrong(Long uid, String time) {
|
| | | public void extractWrong(Long uid, Extract extract, String time) {
|
| | | // 提现失败短信通知
|
| | | // try {
|
| | | // UserInfo user = userInfoService.getUserById(uid);
|
| | | // if (extract != null && user != null &&
|
| | | // !StringUtil.isNullOrEmpty(user.getPhone())) {
|
| | | // smsService.sendExtractFailMsg(user.getPhone(), extract.getMoney());
|
| | | // }
|
| | | // } catch (Exception e) {
|
| | | // try {
|
| | | // LogHelper.errorDetailInfo(e);
|
| | | // } catch (Exception e1) {
|
| | | // e1.printStackTrace();
|
| | | // }
|
| | | // }
|
| | |
|
| | | try {
|
| | | pushService.pushZNX(uid, Constant.znxConfig.getExtractWrongTitle(),
|
| | | Constant.znxConfig.getExtractWrongMsg().replace("[时间]", time));
|
| | |
| | | }
|
| | |
|
| | | @Override
|
| | | public void extractSuccess(Long uid, String time) {
|
| | | public void extractSuccess(Long uid, Extract extract, String time) {
|
| | | // 提现成功短信通知
|
| | | // try {
|
| | | // UserInfo user = userInfoService.getUserById(uid);
|
| | | // if (extract != null && user != null &&
|
| | | // !StringUtil.isNullOrEmpty(user.getPhone())) {
|
| | | // smsService.sendExtractSuccessMsg(user.getPhone(),
|
| | | // extract.getMoney());
|
| | | // }
|
| | | // } catch (Exception e) {
|
| | | // try {
|
| | | // LogHelper.errorDetailInfo(e);
|
| | | // } catch (Exception e1) {
|
| | | // e1.printStackTrace();
|
| | | // }
|
| | | // }
|
| | |
|
| | | try {
|
| | | pushService.pushZNX(uid, Constant.znxConfig.getExtractSuccessTitle(),
|
| | | Constant.znxConfig.getExtractSuccessMsg().replace("[时间]", time));
|