Commit cb0a35fc authored by zw's avatar zw

Merge branch 'test' of https://gitee.com/zwyjjc/tl_estate into test

parents 103dc645 cf1410eb
......@@ -324,8 +324,6 @@ class Broker extends Basic
$data['msg'] = 'phone is null';
} else {
$m_agents = new AAgents();
$redis = new VerifyRepetitionService();
$agents_data = $m_agents->getAgentInfo('id,update_time,call_number', '', ['phone'=>$this->params['phone']]);
if (empty($agents_data['id'])) {
......@@ -336,12 +334,13 @@ class Broker extends Basic
$agent_id = $agents_data['id'];
}
$is = $redis->verifyStart(2, $agent_id, 0);
if ($is) {
if ($agent_id) {
$agents_data = $m_agents->getAgentInfo('id,update_time,call_number', $agent_id);
$insert_data['update_time'] = $agents_data['update_time'];
$insert_data['call_number'] = $agents_data['call_number'] + 1;
$data['data'] = $m_agents->editData($insert_data, $agent_id);
} else {
$data['msg'] = '没有该经纪人信息';
}
}
......
......@@ -256,6 +256,7 @@
$(".pbl_cha").click(function() {
_fix_top.hide();
});
var _shangpuId = getUrlParam('id'); //从url获取的商铺id
var _name = getUrlParam('user_name');
var _name_img = getUrlParam('user_img');
var _tel = getUrlParam('user_tel');
......@@ -272,7 +273,9 @@
}
//点击拨打 记录拨打次数
$("#fix_tel").click(function() {
// if($.cookie("isCallShop") != 'yes'){
var time = localStorage.getItem(_shangpuId+"_"+_tel);
var nowTime = (new Date()).getTime();
if(!time || nowTime-time > 24*3600*1000){
$.ajax({
url: '/api/recordCallNumShare',
type: 'POST',
......@@ -282,12 +285,10 @@
},
dataType: 'json',
success: function(data) {
// $.cookie("isCallShop",'yes',{ expires: 1});
localStorage.setItem(_shangpuId+"_"+_tel,(new Date()).getTime());
}
});
// }
}
});
$("#fix_area_bottom_btn").click(function() {
......
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