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
5e16094f
Commit
5e16094f
authored
Dec 18, 2017
by
hujun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
评论记录增加看铺时间和地址
parent
eb797f9b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
15 deletions
+13
-15
Broker.php
application/api/controller/Broker.php
+4
-4
JournalAccounts.php
application/model/JournalAccounts.php
+9
-11
No files found.
application/api/controller/Broker.php
View file @
5e16094f
...
...
@@ -129,14 +129,14 @@ class Broker extends Basic{
$evalutate
=
new
Evaluate
();
$journal
=
new
JournalAccounts
();
$fields_evaluate
=
'
user_nick
,user_pic,evaluate_grade,evaluate_content,evaluate_sign'
;
$fields_evaluate
=
'
house_id,user_id,user_nick,user_phone
,user_pic,evaluate_grade,evaluate_content,evaluate_sign'
;
$fields_journal
=
'a.house_id'
;
switch
(
$params
[
'type'
])
{
case
0
:
//评价列表信息
$result
[
'evaluate'
]
=
$evalutate
->
getEvaluate
(
$pageNo
,
$pageSize
,
'a.id desc'
,
$fields_evaluate
,
''
,
$params
[
'agent_id'
]);
//成交记录
$result
[
'journalAccounts'
]
=
$journal
->
getJournalHouseInfo
(
$pageNo
,
$pageSize
,
'j.id desc'
,
''
,
'j.transaction_status = 3'
,
$params
[
'agent_id'
]);
$result
[
'journalAccounts'
]
=
$journal
->
getJournalHouseInfo
(
$pageNo
,
$pageSize
,
'j.id desc'
,
$fields_journal
,
'j.transaction_status = 3'
,
$params
[
'agent_id'
]);
$data
[
'data'
]
=
$result
;
break
;
case
1
:
...
...
@@ -146,7 +146,7 @@ class Broker extends Basic{
break
;
case
2
:
//成交记录
$result
[
'journalAccounts'
]
=
$journal
->
getJournalHouseInfo
(
$pageNo
,
$pageSize
,
'
'
,
''
,
'
'
,
$params
[
'agent_id'
]);
$result
[
'journalAccounts'
]
=
$journal
->
getJournalHouseInfo
(
$pageNo
,
$pageSize
,
'
j.id desc'
,
$fields_journal
,
'j.transaction_status = 3
'
,
$params
[
'agent_id'
]);
$data
[
'data'
]
=
$result
;
break
;
default
:
...
...
application/model/JournalAccounts.php
View file @
5e16094f
...
...
@@ -42,26 +42,24 @@ class JournalAccounts extends Model
* @param type $agent_id
* @return type
*/
public
function
getJournalHouseInfo
(
$pageNo
=
1
,
$pageSize
=
15
,
$order_
=
'id desc'
,
$field
,
$params
,
$agent_id
=
''
)
{
public
function
getJournalHouseInfo
(
$pageNo
=
1
,
$pageSize
=
15
,
$order_
=
'
j.
id desc'
,
$field
,
$params
,
$agent_id
=
''
)
{
if
(
$agent_id
)
{
$result
=
$this
->
field
(
'a.house_id'
)
->
alias
(
'j'
)
->
join
(
'applies a'
,
'j.apply_id = a.id'
)
$result
=
$this
->
db
->
field
(
$field
)
->
alias
(
'j'
)
->
join
(
'applies a'
,
'j.apply_id = a.id'
,
'LEFT'
)
->
where
(
'a.agent_id'
,
$agent_id
)
->
where
(
'j.transaction_status = 3'
)
->
group
(
'j.apply_id'
)
->
order
(
$order_
)
->
limit
(
$pageSize
)
->
order
(
$order_
)
->
page
(
$pageNo
)
->
select
();
}
else
{
$result
=
$this
->
field
(
'a.house_id'
)
->
alias
(
'j'
)
->
join
(
'applies a'
,
'j.apply_id = a.id'
)
$result
=
$this
->
field
(
$field
)
->
alias
(
'j'
)
->
join
(
'applies a'
,
'j.apply_id = a.id'
,
'left'
)
->
where
(
'a.agent_id'
,
$agent_id
)
->
where
(
'j.transaction_status = 3'
)
->
group
(
'j.apply_id'
)
->
order
(
$order_
)
->
group
(
'j.apply_id'
)
->
limit
(
$pageSize
)
->
order
(
$order_
)
->
page
(
$pageNo
)
->
select
();
}
...
...
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