Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
sunac-quanmin
Overview
Overview
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
HTML5-李恒逸
sunac-quanmin
Commits
2c317b46
Commit
2c317b46
authored
Jul 06, 2017
by
HTML5-侯张振
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复 渠道客户展示bug
parent
546e6444
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
36 additions
and
7 deletions
+36
-7
index.php
html/application/controllers/channel/index.php
+36
-7
No files found.
html/application/controllers/channel/index.php
View file @
2c317b46
...
@@ -158,10 +158,10 @@ class Index extends CI_Controller{
...
@@ -158,10 +158,10 @@ class Index extends CI_Controller{
else
{
else
{
$where
.=
'E.id = '
.
$channel_id
;
$where
.=
'E.id = '
.
$channel_id
;
}
}
//var_dump($this->session->userdata('u_id'));
if
(
$building_id
!=
''
){
$build
=
$this
->
manager
->
get
(
array
(
'id'
=>
$this
->
session
->
userdata
(
'u_id'
)));
$where
.=
' and B.building_id = '
.
$building_id
;
//var_dump($build['building_id'])
;
}
$where
.=
' and B.building_id in ('
.
$build
[
'building_id'
]
.
')'
;
if
(
$start_time
!=
''
){
if
(
$start_time
!=
''
){
$where
.=
' and B.create_time >= '
.
$start_time
;
$where
.=
' and B.create_time >= '
.
$start_time
;
}
}
...
@@ -248,7 +248,7 @@ class Index extends CI_Controller{
...
@@ -248,7 +248,7 @@ class Index extends CI_Controller{
$datestring
=
"%Y-%m-%d"
;
$datestring
=
"%Y-%m-%d"
;
$this
->
load
->
helper
(
'date'
);
$this
->
load
->
helper
(
'date'
);
$customer_array
=
$this
->
channel
->
get_all_info
(
$where
,
$page_no
,
self
::
PAGE_SIZE
);
$customer_array
=
$this
->
channel
->
get_all_info
(
$where
,
$page_no
,
self
::
PAGE_SIZE
);
if
(
is_array
(
$customer_array
))
{
if
(
is_array
(
$customer_array
))
{
foreach
(
$customer_array
as
$i
=>
$cus
)
{
foreach
(
$customer_array
as
$i
=>
$cus
)
{
if
(
!
$lastTime
)
$lastTime
=
$cus
[
'create_time'
];
if
(
!
$lastTime
)
$lastTime
=
$cus
[
'create_time'
];
...
@@ -295,18 +295,47 @@ class Index extends CI_Controller{
...
@@ -295,18 +295,47 @@ class Index extends CI_Controller{
$where
=
array
(
$where
=
array
(
'CB.id'
=>
$cb_id
'CB.id'
=>
$cb_id
);
);
//获取分配时间
$where1
=
array
(
'RT.entity_id'
=>
$cb_id
,
'RT.trace_status'
=>
1
);
$this
->
data
[
'distribution'
]
=
$this
->
recommend_trace
->
get_create_time
(
$where1
);
// var_dump($this->data['distribution']);
// exit;
// 获取到访时间
$where2
=
array
(
'RT.entity_id'
=>
$cb_id
,
'RT.trace_status'
=>
2
);
$this
->
data
[
'visit_time'
]
=
$this
->
recommend_trace
->
get_create_time
(
$where2
);
//获取认购时间
$where3
=
array
(
'RT.entity_id'
=>
$cb_id
,
'RT.trace_status'
=>
3
);
$this
->
data
[
'subscribe'
]
=
$this
->
recommend_trace
->
get_create_time
(
$where3
);
//获取签约时间
$where4
=
array
(
'RT.entity_id'
=>
$cb_id
,
'RT.trace_status'
=>
4
);
$this
->
data
[
'signing'
]
=
$this
->
recommend_trace
->
get_create_time
(
$where4
);
$query
=
$this
->
customer_building
->
get_custormer_channellist_byStatus
(
$where
,
1
,
1
);
$query
=
$this
->
customer_building
->
get_custormer_channellist_byStatus
(
$where
,
1
,
1
);
if
(
$query
[
0
][
'sale_id'
]
!=
0
){
if
(
$query
[
0
][
'sale_id'
]
!=
0
){
$sales
=
$this
->
user
->
get
(
array
(
'id'
=>
$query
[
0
][
'sale_id'
]));
$sales
=
$this
->
user
->
get
(
array
(
'id'
=>
$query
[
0
][
'sale_id'
]));
$this
->
data
[
'sales_name'
]
=
$sales
[
'true_name'
];
$this
->
data
[
'sales_name'
]
=
$sales
[
'true_name'
];
$this
->
data
[
'sales_mobile'
]
=
$sales
[
'user_mobile'
];
$this
->
data
[
'sales_mobile'
]
=
$sales
[
'user_mobile'
];
}
}
$this
->
data
[
'feedbacks'
]
=
$feedbacks
;
$this
->
data
[
'feedbacks'
]
=
$feedbacks
;
$this
->
data
[
'entity'
]
=
$query
;
$this
->
data
[
'entity'
]
=
$query
;
$this
->
data
[
'datestring'
]
=
$datestring
;
$this
->
data
[
'datestring'
]
=
$datestring
;
$this
->
data
[
'dateformat'
]
=
$dataformat
;
$this
->
data
[
'dateformat'
]
=
$dataformat
;
$this
->
data
[
'counts'
]
=
count
(
$feedbacks
)
;
$this
->
data
[
'counts'
]
=
$query
[
0
][
'recommend_status'
]
;
$this
->
load
->
view
(
'channel/follow'
,
$this
->
data
);
$this
->
load
->
view
(
'channel/follow'
,
$this
->
data
);
}
}
...
...
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