|
@ -120,30 +120,31 @@ public class ConsultService {
|
120
|
120
|
tidings.setTidingsContant(consult.getConsultContant());
|
121
|
121
|
tidings.setReadStatus(1);
|
122
|
122
|
this.tidingsDao.insert(con, tidings);
|
|
123
|
|
123
|
124
|
//需求确认给专家增加积分
|
124
|
125
|
// if(consult.getDemandId() != null){
|
125
|
126
|
// this.growthLogService.demandConfirm(con, consult.getProfessorId());
|
126
|
127
|
// }
|
127
|
|
Professor professor = this.professorDao.queryOne(con, consult.getProfessorId());
|
128
|
|
User user = this.userDao.query(con, consult.getProfessorId());
|
129
|
|
String email = null;
|
130
|
|
String mobile = null;
|
131
|
|
if((professor.getEmail() != null) && (!"".equals(professor.getEmail()))){
|
132
|
|
email = professor.getEmail();
|
133
|
|
}else if((user.getEmail() != null) && (!"".equals(user.getEmail()))){
|
134
|
|
email = user.getEmail();
|
135
|
|
}
|
136
|
|
if((user.getMobilePhone() != null) && (user.getMobilePhone().trim().length() == 11)){
|
137
|
|
mobile = user.getMobilePhone();
|
138
|
|
}else if((professor.getPhone() != null) && (professor.getPhone().trim().length() == 11)){
|
139
|
|
mobile = professor.getPhone();
|
140
|
|
}
|
141
|
|
if(email != null){
|
142
|
|
this.sysService.sendConsultMail(email);
|
143
|
|
}
|
144
|
|
if(mobile != null){
|
145
|
|
this.sysService.sendConsultSMS(mobile);
|
146
|
|
}
|
|
128
|
// Professor professor = this.professorDao.queryOne(con, consult.getProfessorId());
|
|
129
|
// User user = this.userDao.query(con, consult.getProfessorId());
|
|
130
|
// String email = null;
|
|
131
|
// String mobile = null;
|
|
132
|
// if((professor.getEmail() != null) && (!"".equals(professor.getEmail()))){
|
|
133
|
// email = professor.getEmail();
|
|
134
|
// }else if((user.getEmail() != null) && (!"".equals(user.getEmail()))){
|
|
135
|
// email = user.getEmail();
|
|
136
|
// }
|
|
137
|
// if((user.getMobilePhone() != null) && (user.getMobilePhone().trim().length() == 11)){
|
|
138
|
// mobile = user.getMobilePhone();
|
|
139
|
// }else if((professor.getPhone() != null) && (professor.getPhone().trim().length() == 11)){
|
|
140
|
// mobile = professor.getPhone();
|
|
141
|
// }
|
|
142
|
// if(email != null){
|
|
143
|
// this.sysService.sendConsultMail(email);
|
|
144
|
// }
|
|
145
|
// if(mobile != null){
|
|
146
|
// this.sysService.sendConsultSMS(mobile);
|
|
147
|
// }
|
147
|
148
|
return consultId;
|
148
|
149
|
}
|
149
|
150
|
|