|
@ -6,8 +6,9 @@ new Vue({
|
|
|
sessionType:2,//1对1会话
|
|
|
curDoctorCode:JSON.parse(localStorage.getItem(httpRequest.agentName)).uid,
|
|
|
curDoctorName:"",
|
|
|
otherCode: Request["otherCode"] || "xh1D2017031502222",//对方医生code
|
|
|
otherName: Request["otherName"] || "yoyo1",//对方医生姓名
|
|
|
otherCode: Request["otherCode"],//对方医生code
|
|
|
otherName: decodeURIComponent(Request["otherName"]) || "",//对方医生姓名
|
|
|
planDetailId:Request["planDetailId"],//项目id
|
|
|
members:[],
|
|
|
otherInfo:null,//对方的医生信息
|
|
|
consultData:null,
|
|
@ -194,6 +195,20 @@ new Vue({
|
|
|
};
|
|
|
consultingAPI.sendMessage(vm.sessionId, {data: params}).then(function(res){
|
|
|
console.log(res);
|
|
|
var messages = res.messages[0];
|
|
|
var guidanceParams = {
|
|
|
messageId:messages.id,//消息id
|
|
|
doctorCode:vm.otherCode,
|
|
|
content:messages.content,//聊天内容
|
|
|
planDetailId:vm.planDetailId //服务项目id
|
|
|
}
|
|
|
consultingAPI.saveGuidanceMessage(guidanceParams).then(function(rs){
|
|
|
if(rs.status==200){
|
|
|
|
|
|
}else{
|
|
|
layer.msg(rs.msg, {icon: 5})
|
|
|
}
|
|
|
})
|
|
|
// var html = "";
|
|
|
// for(var i=0; i<res.messages.length; i++){
|
|
|
// var reply = res.messages[i];
|