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
25d97417
Commit
25d97417
authored
Jul 05, 2019
by
zhuwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
398c5fd4
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
4 deletions
+21
-4
UserService.php
application/index/service/UserService.php
+4
-4
AAgents.php
application/model/AAgents.php
+17
-0
No files found.
application/index/service/UserService.php
View file @
25d97417
...
...
@@ -279,17 +279,17 @@ class UserService
* @param string $type
* @return array
*/
public
function
recordGuest
(
$agent_id
,
$agent_id_old
,
$user_id
,
$user_name
,
$type
=
'add'
)
public
function
recordGuest
(
$agent_id
,
$agent_id_old
,
$user_id
,
$user_name
,
$type
=
'add'
)
{
$agent
=
new
AAgents
();
$agent_data
=
$agent
->
getAgent
Info
(
'id,name,phone,store_id,district_id
'
,
$agent_id
);
$agent_data
=
$agent
->
getAgent
SiteInfo
(
'a.name,a.phone,b.name as site_name
'
,
$agent_id
);
$remark
=
''
;
if
(
$type
==
'add'
)
{
$remark
=
'新增为'
.
$agent_data
[
'name'
]
.
'-'
.
$agent_data
[
'phone'
]
;
$remark
=
"[
{
$agent_data
[
'site_name'
]
}
]新增为
{
$agent_data
[
'name'
]
}
-
{
$agent_data
[
'phone'
]
}
"
;
}
else
{
if
(
$agent_id
!=
$agent_id_old
)
{
$remark
=
'修改为'
.
$agent_data
[
'name'
]
.
'-'
.
$agent_data
[
'phone'
]
;
$remark
=
"[
{
$agent_data
[
'site_name'
]
}
]修改为
{
$agent_data
[
'name'
]
}
-
{
$agent_data
[
'phone'
]
}
"
;
$this
->
pushMessage
(
$agent_id
,
$agent_id_old
,
$this
->
operation_id
,
$user_name
,
$user_id
);
//客户被修改客方后也进入保护期
$this
->
setUserProtectTime
(
$user_id
);
...
...
application/model/AAgents.php
View file @
25d97417
...
...
@@ -921,6 +921,23 @@ class AAgents extends BaseModel
return
$result
;
}
/**
* 业务员站点信息
* @param $field
* @param $params
* @return array|false|\PDOStatement|string|\think\Model
*/
public
function
getAgentSiteInfo
(
$field
,
$params
)
{
$result
=
$this
->
field
(
$field
)
->
alias
(
'a'
)
->
join
(
'a_site b'
,
'a.site_id = d.id'
,
'left'
)
->
where
(
$params
)
->
find
();
//echo $this->getLastSql();
return
$result
;
}
/**
* 验证用户是否存在
*
...
...
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