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
2a14a6e6
Commit
2a14a6e6
authored
Jan 02, 2019
by
hujun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
客方
parent
a49ec0b7
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
32 additions
and
23 deletions
+32
-23
Member.php
application/index/controller/Member.php
+30
-1
Users.php
application/model/Users.php
+1
-21
user_template_tpl.html
public/resource/template/user_template_tpl.html
+1
-1
No files found.
application/index/controller/Member.php
View file @
2a14a6e6
...
...
@@ -305,14 +305,43 @@ class Member extends Basic{
$where
[
'a.site_ids'
]
=
[
'LIKE'
,
'%'
.
$this
->
siteId
.
'%'
];
}
}
//dump($where);exit;
$fields
=
'a.id,a.user_nick,a.create_time,a.user_name,a.user_phone,a.user_pic,a.create_time,a.user_pswd,a.referrer_id,a.user_label,
a.user_name,a.status,a.first_login_time,a.last_login_time,a.agent_id,a.vip,a.price_demand,a.industry_type,a.area_demand,a.user_status,a.source'
;
try
{
$return_user_list
=
$this
->
user
->
getUserAgent
(
$pageNo
,
$pageSize
,
'a.id DESC'
,
$fields
,
$where
,
$type
,
$this
->
siteId
);
$list
=
[];
$user_follow
=
new
UPhoneFollowPp
(
$this
->
siteId
);
$m_user
=
new
Users
();
$m_agent
=
new
AAgents
();
foreach
(
$return_user_list
as
$k
=>
$v
)
{
if
(
$v
[
'user_pic'
])
{
$return_user_list
[
$k
][
'user_pic'
]
=
CURRENT_URL
.
'static/head_portrait/'
.
$v
[
'user_pic'
];
}
else
{
$return_user_list
[
$k
][
'user_pic'
]
=
''
;
}
$user_data
=
$m_user
->
getUserById
(
'id,user_nick,user_phone'
,
$v
[
'referrer_id'
]);
if
(
empty
(
$user_data
))
{
$return_user_list
[
$k
][
'name'
]
=
''
;
$return_user_list
[
$k
][
'phone'
]
=
''
;
}
else
{
$return_user_list
[
$k
][
'name'
]
=
$user_data
[
'user_nick'
];
$return_user_list
[
$k
][
'phone'
]
=
$user_data
[
'user_phone'
];
}
if
(
empty
(
$v
[
'agent_id'
]))
{
$return_user_list
[
$k
][
'agent_name'
]
=
''
;
}
else
{
$return_user_list
[
$k
][
'agent_name'
]
=
$m_agent
->
getAgentsByWhere
([
'id'
=>
$v
[
'agent_id'
]],
'name'
);
}
$params_
[
'user_id'
]
=
$v
[
'id'
];
$res
=
$user_follow
->
getPhoneFollowData
(
'create_time'
,
$params_
,
'id desc'
);
$return_user_list
[
$k
][
'follow_time'
]
=
$res
[
0
][
'create_time'
];
$return_user_list
[
$k
][
'user_phone'
]
=
hide_customer_phone
(
$return_user_list
[
$k
][
'user_phone'
]);
$return_user_list
[
$k
][
'current_agent_id'
]
=
$this
->
userId
;
...
...
application/model/Users.php
View file @
2a14a6e6
...
...
@@ -161,28 +161,8 @@ class Users extends Model
->
page
(
$pageNo
)
->
select
();
}
//echo Db::table($this->table)->getLastSql();
$user_follow
=
new
UPhoneFollowPp
(
$site_id
);
foreach
(
$result
as
$k
=>
$v
)
{
$data
[
$k
]
=
$v
->
getData
();
if
(
$data
[
$k
][
'user_pic'
])
{
$data
[
$k
][
'user_pic'
]
=
CURRENT_URL
.
'static/head_portrait/'
.
$data
[
$k
][
'user_pic'
];
}
else
{
$data
[
$k
][
'user_pic'
]
=
''
;
}
$user_data
=
$this
->
field
(
'id,user_nick,user_phone'
)
->
where
(
'id'
,
$data
[
$k
][
'referrer_id'
])
->
find
();
$data
[
$k
][
'name'
]
=
$user_data
[
'user_nick'
];
$data
[
$k
][
'phone'
]
=
$user_data
[
'user_phone'
];
$params_
[
'user_id'
]
=
$data
[
$k
][
'id'
];
$order
=
'id desc'
;
$res
=
$user_follow
->
getPhoneFollowData
(
'create_time'
,
$params_
,
$order
);
$data
[
$k
][
'follow_time'
]
=
$res
[
0
][
'create_time'
];
}
return
$data
;
return
$result
;
}
/**
...
...
public/resource/template/user_template_tpl.html
View file @
2a14a6e6
...
...
@@ -48,7 +48,7 @@
[
%
}
%
]
<
/td
>
<
td
>
[
%=
'客方'
%
]
[
%=
it
[
item
][
'agent_name'
]
%
]
<
/td
>
<
td
width
=
"16%"
>
[
%
if
((
it
[
item
][
'agent_id'
]
*
1
==
0
)
||
(
check_auth
(
'index/useraction_search'
)))
{
%
]
...
...
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