|
|
@@ -70,13 +70,21 @@ public class InvitationRecordServiceImpl implements InvitationRecordService {
|
|
|
}
|
|
|
invitationRecordDao.save(oldrecord);
|
|
|
if (oldrecord.getVenduseremail() != null) {
|
|
|
- mailService.send(messageConf.getTplInvitationForB2B(), record.getVenduseremail(), model);
|
|
|
+ try {
|
|
|
+ mailService.send(messageConf.getTplInvitationForB2B(), record.getVenduseremail(), model);
|
|
|
+ } catch (Exception e) {
|
|
|
+ e.printStackTrace();
|
|
|
+ }
|
|
|
}
|
|
|
if(oldrecord.getVendusertel()!=null){
|
|
|
- smsService.send(messageConf.getMsgInvitationForB2B(), record.getVendusertel(),
|
|
|
- new Object[] { record.getVendusername(), record.getVendname(),
|
|
|
- SystemSession.getUser().getUserName() + "("
|
|
|
- + SystemSession.getUser().getEnterprise().getEnName() + ")" });
|
|
|
+ try {
|
|
|
+ smsService.send(messageConf.getMsgInvitationForB2B(), record.getVendusertel(),
|
|
|
+ new Object[] { record.getVendusername(), record.getVendname(),
|
|
|
+ SystemSession.getUser().getUserName() + "("
|
|
|
+ + SystemSession.getUser().getEnterprise().getEnName() + ")" });
|
|
|
+ } catch (Exception e) {
|
|
|
+ e.printStackTrace();
|
|
|
+ }
|
|
|
}
|
|
|
map.put("success", "邀请已发送");
|
|
|
} else {
|
|
|
@@ -103,6 +111,11 @@ public class InvitationRecordServiceImpl implements InvitationRecordService {
|
|
|
return map;
|
|
|
}
|
|
|
|
|
|
+ @Override
|
|
|
+ public ModelMap reInvite(Long id) {
|
|
|
+ return invite(invitationRecordDao.findOne(id));
|
|
|
+ }
|
|
|
+
|
|
|
@Override
|
|
|
public List<InvitationRecord> getRecords() {
|
|
|
return invitationRecordDao.findByUseruu(SystemSession.getUser().getUserUU());
|
|
|
@@ -115,7 +128,6 @@ public class InvitationRecordServiceImpl implements InvitationRecordService {
|
|
|
List<InvitationRecord> newRecords = new ArrayList<InvitationRecord>();
|
|
|
for (InvitationRecord record : records) {
|
|
|
List<Enterprise> enters = enterpriseDao.findByEnName(record.getVendname());
|
|
|
- System.out.println(enters.size());
|
|
|
if (!CollectionUtils.isEmpty(enters)) {
|
|
|
if (enters.size() == 1) {
|
|
|
record.setActive(Constant.YES);
|