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
12c3509e
Commit
12c3509e
authored
Dec 21, 2017
by
clone
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
数据接口
parent
38188cd3
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
10 deletions
+7
-10
TradeLog.php
application/api/controller/TradeLog.php
+6
-9
route.php
application/route.php
+1
-1
No files found.
application/api/controller/TradeLog.php
View file @
12c3509e
...
@@ -48,26 +48,23 @@ class TradeLog extends Basic
...
@@ -48,26 +48,23 @@ class TradeLog extends Basic
$pageNo
=
empty
(
$params
[
'pageNo'
])
?
1
:
$params
[
'pageNo'
];
$pageNo
=
empty
(
$params
[
'pageNo'
])
?
1
:
$params
[
'pageNo'
];
$pageSize
=
empty
(
$params
[
'pageSize'
])
?
15
:
$params
[
'pageSize'
];
$pageSize
=
empty
(
$params
[
'pageSize'
])
?
15
:
$params
[
'pageSize'
];
$order_
=
'a.created desc'
;
$order_
=
'a.created desc'
;
$field
=
"a.id,a.tradecode,a.singntime,b.phpone,b.house_id"
;
$field
=
"a.id,a.tradecode,a.singntime,b.phpone,b.house_id"
;
$result
=
$this
->
journalAccountsMode
->
getJournalAccountsList
(
$pageNo
,
$pageSize
,
$order_
,
$field
,
$param
);
$result
=
$this
->
journalAccountsMode
->
getJournalAccountsList
(
$pageNo
,
$pageSize
,
$order_
,
$field
,
$param
);
if
(
count
(
$result
)
<=
0
)
{
if
(
count
(
$result
)
<=
0
)
{
return
$this
->
response
(
"200"
,
"请求数据为空"
);
return
$this
->
response
(
"200"
,
"请求数据为空"
);
}
}
foreach
(
$result
as
$key
=>
$val
)
{
foreach
(
$result
as
$key
=>
$val
)
{
$result
[
$key
][
"api_path"
]
=
IMG_PATH
;
$imgParam
[
"house_id"
]
=
$val
[
"house_id"
];
$imgParam
[
"imgtype"
]
=
1
;
//默认主图
$result
[
$key
][
"images"
]
=
$this
->
dbImg
->
getHouseImages
(
$imgParam
,
1
);
$evaluateResult
=
$this
->
evaluateMode
->
getIsEvaluate
(
20
,
$val
[
"house_id"
],
$param
[
"user_id"
]);
$result
[
"is_evaluate"
]
=
count
(
$evaluateResult
)
>
0
?
1
:
0
;
$houseInfo
=
$this
->
houseInfoModel
->
getHouseDetail
(
"room_num_left"
,
array
(
"id"
=>
$val
[
"house_id"
]));
$houseInfo
=
$this
->
houseInfoModel
->
getHouseDetail
(
"room_num_left"
,
array
(
"id"
=>
$val
[
"house_id"
]));
$result
[
$key
][
"room_num_left"
]
=
$houseInfo
[
"room_num_left"
];
$result
[
$key
][
"room_num_left"
]
=
$houseInfo
[
"room_num_left"
];
$result
[
$key
][
"api_path"
]
=
IMG_PATH
;
$imgParam
[
"house_id"
]
=
$val
[
"house_id"
];
$imgParam
[
"imgtype"
]
=
1
;
//默认主图
$result
[
$key
][
"images"
]
=
$this
->
dbImg
->
getHouseImages
(
$imgParam
,
1
);
$evaluateResult
=
$this
->
evaluateMode
->
getIsEvaluate
(
20
,
$val
[
"house_id"
],
$param
[
"user_id"
]);
$result
[
$key
][
"is_evaluate"
]
=
count
(
$evaluateResult
)
>
0
?
1
:
0
;
}
}
return
$this
->
response
(
"200"
,
"request"
,
$result
);
return
$this
->
response
(
"200"
,
"request"
,
$result
);
...
...
application/route.php
View file @
12c3509e
...
@@ -121,7 +121,7 @@ Route::group('api', [
...
@@ -121,7 +121,7 @@ Route::group('api', [
//tradeLog
//tradeLog
'getTradeList'
=>
[
'api/TradeLog/getTradeList'
,
[
'method'
=>
'get'
]
],
'getTradeList'
=>
[
'api/TradeLog/getTradeList'
,
[
'method'
=>
'
post|
get'
]
],
//AttentionShop
//AttentionShop
'addOrUpdateAttention'
=>
[
'api/AttentionShop/addOrUpdateAttention'
,
[
'method'
=>
'post|get'
]
],
'addOrUpdateAttention'
=>
[
'api/AttentionShop/addOrUpdateAttention'
,
[
'method'
=>
'post|get'
]
],
...
...
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