Commit 9e2fa8ca authored by agping's avatar agping

客户详情优化

parent 825b6de7
...@@ -258,10 +258,10 @@ ...@@ -258,10 +258,10 @@
.modal-title-genjing { .modal-title-genjing {
height: 36px; height: 36px;
line-height: 36px; line-height: 36px;
border-top: 3px solid #ccc;
font-weight: 600; font-weight: 600;
font-size: 16px;
} }
.modal-title-genjing>span{ .modal-title-genjing span{
cursor: pointer; cursor: pointer;
margin-right: 20px; margin-right: 20px;
} }
...@@ -877,31 +877,30 @@ ...@@ -877,31 +877,30 @@
</table> </table>
<div> <div>
最近一条带看动态<br /> <div class="text-info" style="margin: 2px;font-size: 16px;">最近一条带看动态</div>
<div class="user-log-detail"> <table class="table table-striped table-bordered table-hover table-condensed">
<tbody class="text-center user-log-detail">
</div> </tbody>
</table>
</div> </div>
<h4 class="clear modal-title-genjing"> <div class="clear modal-title-genjing">
<span class="modal-title-genjing-con"> <span class="modal-title-genjing-con">
<span class="text-info">客户动态</span> <span class="text-info">客户动态</span>
<span>带看动态</span> <span>带看动态</span>
</span> </span>
<span class="user-log-more text-info" style="float: right;">加载更多</span> <span class="user-log-more text-info" style="float: right;">加载更多</span>
</h4> </div>
<div id="gen_jing_user"> <div id="gen_jing_user">
<div> <div>
<div class="follow-up-modal-list-area" style="height: 258px"> <div class="follow-up-modal-list-area" style="height: 212px">
<table class="table table-striped table-bordered table-hover table-condensed"> <table class="table table-striped table-bordered table-hover table-condensed">
<tbody class="text-center" id="caozuo_table2"> <tbody class="text-center" id="caozuo_table2">
</tbody> </tbody>
</table> </table>
</div> </div>
<div class="follow-up-modal-list-area" style="height: 258px"> <div class="follow-up-modal-list-area" style="height: 212px">
<table class="table table-striped table-bordered table-hover table-condensed"> <table class="table table-striped table-bordered table-hover table-condensed">
<tbody class="text-center" id="caozuo_table_log"> <tbody class="text-center" id="caozuo_table_log">
<td>555</td>
</tbody> </tbody>
</table> </table>
</div> </div>
......
...@@ -493,7 +493,7 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind ...@@ -493,7 +493,7 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
$('.followup-modal-comment-area>textarea').val('');//清空跟进框内容 $('.followup-modal-comment-area>textarea').val('');//清空跟进框内容
user.getSiteTagsEdit(); user.getSiteTagsEdit();
user.getUserLog(1);//客户详情获取最近一条带看动态 user.getUserLogNew();//客户详情获取最近一条带看动态
$('.user-log-more').show();//显示加载更多 $('.user-log-more').show();//显示加载更多
}); });
...@@ -820,6 +820,8 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind ...@@ -820,6 +820,8 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
_genjinModal.hide(); _genjinModal.hide();
_btnSaveTemp.hide(); _btnSaveTemp.hide();
_btnSave.css('display','block'); _btnSave.css('display','block');
user.pageNoUser=1;
$('#caozuo_table2').html('');
user.getGenjincon(); user.getGenjincon();
}; };
}else { }else {
...@@ -866,6 +868,8 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind ...@@ -866,6 +868,8 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
console.log('释放成功'); console.log('释放成功');
alert('提交成功'); alert('提交成功');
_genjinModal.hide(); _genjinModal.hide();
user.pageNoUser=1;
$('#caozuo_table2').html('');
user.getGenjincon(); user.getGenjincon();
}else { }else {
layerTipsX(data['msg']); layerTipsX(data['msg']);
...@@ -1729,7 +1733,9 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind ...@@ -1729,7 +1733,9 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
}else{ }else{
$("#caozuo_table_edit_introduce").html('暂无数据(*^_^*)'); $("#caozuo_table_edit_introduce").html('暂无数据(*^_^*)');
} }
//拨打电话
user.customerInfo = data.data.user_info;
is_outpace_call_num = data.data.is_outpace_call_num;
} }
} else { } else {
...@@ -2267,12 +2273,16 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind ...@@ -2267,12 +2273,16 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
dataType: 'json', dataType: 'json',
success: function(data) { success: function(data) {
if(data.code == 200 && data.data != null) { if(data.code == 200 && data.data != null) {
user.customerInfo = data.data.user_info;
is_outpace_call_num = data.data.is_outpace_call_num;
//客户动态 即跟进 //客户动态 即跟进
var caozuo_table = ""; var caozuo_table = "";
$.each(data['data'], function(i, item) { $.each(data['data'], function(i, item) {
caozuo_table += '<tr><td class="text-left follow-up-home" width="70%">' + item.content + '</td><td>' + item.name + '</td><td>' + item.create_time + '</td></tr>'; if(item.user_status*1){
var user_status = '【已租】'
}else{
var user_status = '【求租】'
};
caozuo_table += '<tr><td class="text-left follow-up-home" width="70%">电话跟进:' + item.content + user_status +'</td><td>' + item.name + '</td><td>' + item.create_time +'</td></tr>';
}); });
if(caozuo_table){ if(caozuo_table){
...@@ -2302,24 +2312,55 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind ...@@ -2302,24 +2312,55 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
}, },
dataType: 'json', dataType: 'json',
success: function(data) { success: function(data) {
var caozuo_table='';
if(data.code == 200 && data.data != null) { if(data.code == 200 && data.data != null) {
// if(item.step_name=='report'){ //带看动态
// caozuo_table += '<tr><td class="text-left follow-up-home" width="70%">' + dealPunctuation(item.step)+'到场时间:'+ item.predict_see_time +'备注:'+item.intro+ '</td><td>' + item.name + '</td><td>' + item.create_time + '</td></tr>'; var caozuo_table = "";
// }else{ $.each(data['data'], function(i, item) {
// caozuo_table += '<tr><td class="text-left follow-up-home" width="70%">' + dealPunctuation(item.step)+ '</td><td>' + item.name + '</td><td>' + item.create_time + '</td></tr>'; if(item.step_name=='report'){
// } caozuo_table += '<tr><td class="text-left follow-up-home" width="70%">' + item.step+'到场时间:'+ item.predict_see_time +'备注:'+item.intro+ '</td><td>' + item.name + '</td><td>' + item.create_time + '</td></tr>';
// if(caozuo_table){ }else{
// $("#caozuo_table_log").html(caozuo_table); caozuo_table += '<tr><td class="text-left follow-up-home" width="70%">' + item.step+ '</td><td>' + item.name + '</td><td>' + item.create_time + '</td></tr>';
// }else{ }
// $("#caozuo_table_log").html('暂无跟进信息'); });
// } $("#caozuo_table_log").html(caozuo_table);
// //滚动条 回到顶部 //滚动条 回到顶部
// $('.follow-up-modal-list-area').scrollTop(0); $('.followup-modal-list-area').scrollTop(0);
}else{
$("#caozuo_table_log").html('暂无带看信息');
}
}
});
},
getUserLogNew: function(type) {
$.ajax({
url: '/index/userLog',
type: 'GET',
async: true,
data: {
"user_id": user.user_id,
"type": 1
},
dataType: 'json',
success: function(data) {
var caozuo_table='';
if(data.code == 200 && data.data != null) {
//带看动态
var caozuo_table = "";
$.each(data['data'], function(i, item) {
if(item.step_name=='report'){
caozuo_table += '<tr><td class="text-left follow-up-home" width="70%">' + item.step+'到场时间:'+ item.predict_see_time +'备注:'+item.intro+ '</td><td>' + item.name + '</td><td>' + item.create_time + '</td></tr>';
}else{
caozuo_table += '<tr><td class="text-left follow-up-home" width="70%">' + item.step+ '</td><td>' + item.name + '</td><td>' + item.create_time + '</td></tr>';
}
});
$(".user-log-detail").html(caozuo_table);
}else{
$(".user-log-detail").html('暂无带看信息');
} }
} }
}); });
}, },
//调用部门 和 门店的接口 //调用部门 和 门店的接口
getDistrict: function(fn) { getDistrict: function(fn) {
$.ajax({ $.ajax({
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment