Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
tl_estate
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hujun
tl_estate
Commits
e7fb4ba5
Commit
e7fb4ba5
authored
Nov 22, 2018
by
hujun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
打电话默认跟进
parent
5836ffc1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
8 deletions
+9
-8
CellPhone.php
application/api_broker/controller/CellPhone.php
+1
-1
CallPhoneService.php
application/api_broker/service/CallPhoneService.php
+7
-6
CellPhone.php
application/index/controller/CellPhone.php
+1
-1
No files found.
application/api_broker/controller/CellPhone.php
View file @
e7fb4ba5
...
@@ -31,7 +31,7 @@ class CellPhone extends Basic
...
@@ -31,7 +31,7 @@ class CellPhone extends Basic
header
(
'Access-Control-Allow-Origin:*'
);
header
(
'Access-Control-Allow-Origin:*'
);
$call
=
new
CallPhoneService
(
$this
->
city
);
$call
=
new
CallPhoneService
(
$this
->
city
,
$this
->
siteId
);
$record
=
true
;
//是否录音
$record
=
true
;
//是否录音
$user_id
=
empty
(
$this
->
params
[
'user_id'
])
?
0
:
(
int
)
$this
->
params
[
'user_id'
];
$user_id
=
empty
(
$this
->
params
[
'user_id'
])
?
0
:
(
int
)
$this
->
params
[
'user_id'
];
$house_id
=
empty
(
$this
->
params
[
'house_id'
])
?
0
:
(
int
)
$this
->
params
[
'house_id'
];
$house_id
=
empty
(
$this
->
params
[
'house_id'
])
?
0
:
(
int
)
$this
->
params
[
'house_id'
];
...
...
application/api_broker/service/CallPhoneService.php
View file @
e7fb4ba5
...
@@ -39,8 +39,9 @@ class CallPhoneService
...
@@ -39,8 +39,9 @@ class CallPhoneService
private
$city
;
private
$city
;
public
$redis
;
public
$redis
;
private
$m_bind
;
private
$m_bind
;
private
$site_id
;
public
function
__construct
(
string
$city
=
'上海市'
)
public
function
__construct
(
string
$city
=
'上海市'
,
int
$site_id
=
10001
)
{
{
$this
->
city
=
substr
(
$city
,
0
,
strpos
(
$city
,
'市'
));
//去市
$this
->
city
=
substr
(
$city
,
0
,
strpos
(
$city
,
'市'
));
//去市
$this
->
redis
=
RedisExt
::
getRedis
();
$this
->
redis
=
RedisExt
::
getRedis
();
...
@@ -52,6 +53,7 @@ class CallPhoneService
...
@@ -52,6 +53,7 @@ class CallPhoneService
$this
->
day_num
=
empty
(
$this
->
day_num
)
?
1
:
$this
->
day_num
+
1
;
$this
->
day_num
=
empty
(
$this
->
day_num
)
?
1
:
$this
->
day_num
+
1
;
$this
->
landlord_phone_day
=
empty
(
$this
->
landlord_phone_day
)
?
1
:
$this
->
landlord_phone_day
+
1
;
$this
->
landlord_phone_day
=
empty
(
$this
->
landlord_phone_day
)
?
1
:
$this
->
landlord_phone_day
+
1
;
$this
->
m_bind
=
new
BindingPhone
();
$this
->
m_bind
=
new
BindingPhone
();
$this
->
site_id
=
$site_id
;
}
}
/**
/**
...
@@ -547,13 +549,12 @@ class CallPhoneService
...
@@ -547,13 +549,12 @@ class CallPhoneService
$follow_where
[
'agent_id'
]
=
$array
[
0
];
$follow_where
[
'agent_id'
]
=
$array
[
0
];
$follow_where
[
'user_id'
]
=
$array
[
1
];
$follow_where
[
'user_id'
]
=
$array
[
1
];
if
(
isset
(
$array
[
2
])){
if
(
isset
(
$array
[
2
])){
$
follow_where
[
'site_id'
]
=
$array
[
2
];
$
site_id
=
$array
[
2
];
}
else
{
}
else
{
$
follow_where
[
'site_id'
]
=
"10001"
;
$
site_id
=
'10001'
;
}
}
$m_follow_up
=
new
UPhoneFollowPp
(
$
follow_where
[
'site_id'
]
);
$m_follow_up
=
new
UPhoneFollowPp
(
$
site_id
);
$num
=
$m_follow_up
->
getFollowTotal
(
$follow_where
);
$num
=
$m_follow_up
->
getFollowTotal
(
$follow_where
);
if
(
empty
(
$num
)
&&
!
empty
(
$array
[
1
]))
{
if
(
empty
(
$num
)
&&
!
empty
(
$array
[
1
]))
{
//$agent_id, $user_id, $content, $type
//$agent_id, $user_id, $content, $type
$m_follow_up
->
insertDefaultFollow
(
$array
[
0
],
$array
[
1
],
$content
,
0
);
$m_follow_up
->
insertDefaultFollow
(
$array
[
0
],
$array
[
1
],
$content
,
0
);
...
@@ -585,7 +586,7 @@ class CallPhoneService
...
@@ -585,7 +586,7 @@ class CallPhoneService
}
}
if
(
$user_type
==
1
)
{
if
(
$user_type
==
1
)
{
$this
->
redis
->
hSet
(
$key
,
$agent_id
.
'-'
.
$user_id
,
time
());
$this
->
redis
->
hSet
(
$key
,
$agent_id
.
'-'
.
$user_id
.
'-'
.
$this
->
site_id
,
time
());
}
else
{
}
else
{
$this
->
redis
->
hSet
(
$key
,
$agent_id
.
'-'
.
$user_id
.
'-'
.
$phone_a
.
'-'
.
$phone_b
,
time
());
$this
->
redis
->
hSet
(
$key
,
$agent_id
.
'-'
.
$user_id
.
'-'
.
$phone_a
.
'-'
.
$phone_b
,
time
());
}
}
...
...
application/index/controller/CellPhone.php
View file @
e7fb4ba5
...
@@ -275,7 +275,7 @@ class CellPhone extends Basic
...
@@ -275,7 +275,7 @@ class CellPhone extends Basic
$house_id
=
empty
(
$this
->
params
[
'house_id'
])
?
0
:
(
int
)
$this
->
params
[
'house_id'
];
$house_id
=
empty
(
$this
->
params
[
'house_id'
])
?
0
:
(
int
)
$this
->
params
[
'house_id'
];
$landlord
=
empty
(
$this
->
params
[
'landlord'
])
?
0
:
(
int
)
$this
->
params
[
'landlord'
];
$landlord
=
empty
(
$this
->
params
[
'landlord'
])
?
0
:
(
int
)
$this
->
params
[
'landlord'
];
$record
=
true
;
//录音
$record
=
true
;
//录音
$call_phone
=
new
CallPhoneService
(
$this
->
city
);
$call_phone
=
new
CallPhoneService
(
$this
->
city
,
$this
->
siteId
);
$data
=
$call_phone
->
bindAXB
(
$this
->
params
[
'phone_a'
],
$phone_b
,
$record
,
$user_id
,
$this
->
userId
,
$this
->
userName
,
$landlord
,
$house_id
);
$data
=
$call_phone
->
bindAXB
(
$this
->
params
[
'phone_a'
],
$phone_b
,
$record
,
$user_id
,
$this
->
userId
,
$this
->
userName
,
$landlord
,
$house_id
);
$result
[
'msg'
]
=
''
;
$result
[
'msg'
]
=
''
;
if
(
$data
[
'status'
]
==
'success'
)
{
if
(
$data
[
'status'
]
==
'success'
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment