Commit bcf4f097 authored by agping's avatar agping

修改

parent 0ddeafc5
...@@ -42,6 +42,8 @@ define(['doT', 'text!temp/remark_follow_template_tpl.html', 'css!style/home.css' ...@@ -42,6 +42,8 @@ define(['doT', 'text!temp/remark_follow_template_tpl.html', 'css!style/home.css'
user_id_edit_introduce:'', user_id_edit_introduce:'',
isAjaxSaving: false, isAjaxSaving: false,
customerInfo: {}, customerInfo: {},
agent_id_call:"",//拨打电话 相关
agent_id_call_vip:"",
init: function() { init: function() {
//初始化dot //初始化dot
$("body").append(template); $("body").append(template);
...@@ -269,6 +271,9 @@ define(['doT', 'text!temp/remark_follow_template_tpl.html', 'css!style/home.css' ...@@ -269,6 +271,9 @@ define(['doT', 'text!temp/remark_follow_template_tpl.html', 'css!style/home.css'
user.baohu = $(this).attr("data-baohu"); user.baohu = $(this).attr("data-baohu");
user.agent_id_infor = $(this).attr("data-agentId"); user.agent_id_infor = $(this).attr("data-agentId");
user.remark_id = $(this).attr("data-remark"); user.remark_id = $(this).attr("data-remark");
//隐藏拨打电话 相关
user.agent_id_call=$(this).attr("data-agentId");
user.agent_id_call_vip=$(this).attr("data-vip");
$('.call-user-five').html(''); $('.call-user-five').html('');
$('.detail-modal-body-sec-2').show(); $('.detail-modal-body-sec-2').show();
$('#take_look_name').html($(this).attr("data-name")); $('#take_look_name').html($(this).attr("data-name"));
...@@ -1289,12 +1294,15 @@ define(['doT', 'text!temp/remark_follow_template_tpl.html', 'css!style/home.css' ...@@ -1289,12 +1294,15 @@ define(['doT', 'text!temp/remark_follow_template_tpl.html', 'css!style/home.css'
//隐藏拨打电话 如果客户在保护期 并且客户不是我的 //隐藏拨打电话 如果客户在保护期 并且客户不是我的
if((user_info_obj.id*1 == user.agent_id_infor*1) || user.baohu*1){ if((user_info_obj.id*1 == user.agent_id_infor*1) || user.baohu*1){
$('.user_call').show(); $('.user_call').show();
console.log(1)
}else{ }else{
$('.user_call').hide(); $('.user_call').hide();
console.log(2);
console.log(user.baohu);
}; };
//vip客户 查看权限
if((check_auth('auth_vip') && user.agent_id_call_vip*1) || (user.agent_id_call*1 == user_info_obj.id*1)){
$('.user_call').show();
}else{
$('.user_call').hide();
};
$.ajax({ $.ajax({
'type': 'GET', 'type': 'GET',
'url': '/index/useraction_search', 'url': '/index/useraction_search',
......
...@@ -47,6 +47,9 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind ...@@ -47,6 +47,9 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
main_select : false , // true : 开启高级搜索 ,false :关闭高级搜索 main_select : false , // true : 开启高级搜索 ,false :关闭高级搜索
user_status:'', user_status:'',
referrer_source:"", referrer_source:"",
agent_id_call:"",//拨打电话 相关
agent_id_call_current:"",
agent_id_call_vip:"",
init: function() { init: function() {
//初始化dot //初始化dot
$("body").append(template); $("body").append(template);
...@@ -417,6 +420,10 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind ...@@ -417,6 +420,10 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
user.agent_id_infor = $(this).attr("data-agentId"); user.agent_id_infor = $(this).attr("data-agentId");
user.baohu = $(this).attr("data-baohu"); user.baohu = $(this).attr("data-baohu");
user.agentbaohu = $(this).attr("data-agent"); user.agentbaohu = $(this).attr("data-agent");
//隐藏拨打电话 相关
user.agent_id_call=$(this).attr("data-agent");
user.agent_id_call_current=$(this).attr("data-current");
user.agent_id_call_vip=$(this).attr("data-vip");
$('.call-user-five').html(''); $('.call-user-five').html('');
$('.detail-modal-body-sec-2').show(); $('.detail-modal-body-sec-2').show();
$('#take_look_name').html($(this).attr("data-name")); $('#take_look_name').html($(this).attr("data-name"));
...@@ -1520,7 +1527,13 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind ...@@ -1520,7 +1527,13 @@ define(['doT', 'text!temp/user_template_tpl.html', 'css!style/home.css', 'ckfind
$('.user_call').show(); $('.user_call').show();
}else{ }else{
$('.user_call').hide(); $('.user_call').hide();
} };
//vip客户 查看权限
if((check_auth('auth_vip') && user.agent_id_call_vip*1) || (user.agent_id_call*1 == user.agent_id_call_current*1)){
$('.user_call').show();
}else{
$('.user_call').hide();
}
checkLogin(); checkLogin();
$.ajax({ $.ajax({
'type': 'GET', 'type': 'GET',
......
...@@ -36,8 +36,8 @@ ...@@ -36,8 +36,8 @@
<td>[%= hideTel(it[item]['user_phone']) %]</td> <td>[%= hideTel(it[item]['user_phone']) %]</td>
<td width="16%"> <td width="16%">
[% if((check_auth('auth_vip') && it[item]['vip']*1) || (it[item]['agent_id']*1 == 0) || (it[item]['agent_id']*1 == user_info_obj.id*1) || (check_auth('index/useraction_search') && it[item]['vip']*1 == 0)) { %] [% if((it[item]['agent_id']*1 == 0) || (check_auth('index/useraction_search'))) { %]
<a class="btn1 caozuo genj_ure caozuo-add-color [%= getLoaclRemarkId(it[item]['id']) %]" href="#modal-record" data-toggle="modal" data-phone='[%= it[item]["user_phone"] %]' data-id='[%= it[item]["user_id"] %]' data-agentId='[%= it[item]["agent_id"] %]' data-name='[%= it[item]["user_name"] %]' data-baohu='[%= it[item]["is_outstrip_twenty_four_hours"] %]' data-remark='[%= it[item]["id"] %]'>详情/跟进</a>&nbsp; <a class="btn1 caozuo genj_ure caozuo-add-color [%= getLoaclRemarkId(it[item]['id']) %]" href="#modal-record" data-toggle="modal" data-phone='[%= it[item]["user_phone"] %]' data-id='[%= it[item]["user_id"] %]' data-agentId='[%= it[item]["agent_id"] %]' data-name='[%= it[item]["user_name"] %]' data-baohu='[%= it[item]["is_outstrip_twenty_four_hours"] %]' data-remark='[%= it[item]["id"] %]' data-vip='[%= it[item]["vip"] %]'>详情/跟进</a>&nbsp;
[% if(it[item]['agent_id'] == it[item]['current_agent_id'] || check_auth('index/pcEditClient')) { %] [% if(it[item]['agent_id'] == it[item]['current_agent_id'] || check_auth('index/pcEditClient')) { %]
<a class="btn1 btn-success caozuo cao-zuo-record" href="#modal-record-edit" data-toggle="modal" data-phone='[%= it[item]["user_phone"] %]' data-id='[%= it[item]["user_id"] %]'>客户编辑</a>&nbsp; <a class="btn1 btn-success caozuo cao-zuo-record" href="#modal-record-edit" data-toggle="modal" data-phone='[%= it[item]["user_phone"] %]' data-id='[%= it[item]["user_id"] %]'>客户编辑</a>&nbsp;
......
...@@ -48,8 +48,8 @@ ...@@ -48,8 +48,8 @@
[% } %] [% } %]
</td> </td>
<td width="16%"> <td width="16%">
[% if((check_auth('auth_vip') && it[item]['vip']*1) || (it[item]['agent_id']*1 == 0) || (it[item]['agent_id']*1 == it[item]['current_agent_id']*1) || (check_auth('index/useraction_search') && it[item]['vip']*1 == 0)) { %] [% if((it[item]['agent_id']*1 == 0) || (check_auth('index/useraction_search'))) { %]
<a class="btn1 caozuo genj_ure caozuo-add-color [%= getLoaclId(it[item]['id']) %]" href="#modal-record" data-toggle="modal" data-phone='[%= it[item]["user_phone"] %]' data-id='[%= it[item]["id"] %]' data-baohu='[%= it[item]["is_outstrip_twenty_four_hours"] %]' data-agent='[%= it[item]["agent_id"] %]'>详情/跟进</a>&nbsp; <a class="btn1 caozuo genj_ure caozuo-add-color [%= getLoaclId(it[item]['id']) %]" href="#modal-record" data-toggle="modal" data-phone='[%= it[item]["user_phone"] %]' data-id='[%= it[item]["id"] %]' data-baohu='[%= it[item]["is_outstrip_twenty_four_hours"] %]' data-agent='[%= it[item]["agent_id"] %]' data-vip='[%= it[item]["vip"] %]' data-current='[%= it[item]["current_agent_id"] %]'>详情/跟进</a>&nbsp;
<a class="btn1 is_show [%= sw(it[item]['is_collect']) %]" data-id='[%= it[item]["id"] %]' data-cid='[%= it[item]["is_collect"] %]' data-baohu='[%= it[item]["is_outstrip_twenty_four_hours"] %]' data-agent='[%= it[item]["agent_id"] %]'> <a class="btn1 is_show [%= sw(it[item]['is_collect']) %]" data-id='[%= it[item]["id"] %]' data-cid='[%= it[item]["is_collect"] %]' data-baohu='[%= it[item]["is_outstrip_twenty_four_hours"] %]' data-agent='[%= it[item]["agent_id"] %]'>
[% if(it[item]["is_collect"] == 2) { %] [% if(it[item]["is_collect"] == 2) { %]
......
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