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
c60455d6
Commit
c60455d6
authored
Feb 06, 2018
by
zhuwei
Committed by
hujun
Mar 01, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pushMsg_gethouseinfo-接口完善
parent
f1028ad5
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
3 deletions
+20
-3
AppChat.php
application/chat/controller/AppChat.php
+19
-2
HouseInfos.php
application/model/HouseInfos.php
+1
-1
No files found.
application/chat/controller/AppChat.php
View file @
c60455d6
...
...
@@ -236,11 +236,28 @@ class AppChat extends Basic
$id
=
$params
[
'id'
];
$HouseInfos
=
new
HouseInfos
();
$HouseInfosre
=
$HouseInfos
->
getHousepusmessage
(
$id
);
//dump($HouseInfosre);
if
(
$HouseInfosre
){
$data
[
'title'
]
=
$HouseInfosre
[
0
][
'title'
];
$data
[
'room_area_all'
]
=
$HouseInfosre
[
0
][
'room_area'
]
.
'-'
.
$HouseInfosre
[
0
][
'room_area2'
]
.
'm²'
;
$data
[
'price'
]
=
$HouseInfosre
[
0
][
'price'
];
//dump($HouseInfosre[0]['room_area']);
//dump($HouseInfosre[0]['room_area2']);
$room_area
=
$HouseInfosre
[
0
][
'room_area'
]
?
$HouseInfosre
[
0
][
'room_area'
]
:
''
;
$room_area2
=
$HouseInfosre
[
0
][
'room_area2'
]
?
'-'
.
$HouseInfosre
[
0
][
'room_area2'
]
:
''
;
$data
[
'room_area_all'
]
=
'暂无!'
;
if
(
$room_area
||
$room_area2
)
{
$data
[
'room_area_all'
]
=
$room_area
.
$room_area2
.
'm²'
;
}
$data
[
'price'
]
=
'暂无!'
;
if
(
$HouseInfosre
[
0
][
'rent_type'
]){
//rent_type COMMENT '1.月租金 2.营业额扣点 3.每平方米租金',
$message
[
1
]
=
'月租金:'
.
$HouseInfosre
[
0
][
'price'
]
.
'元/月'
;
$message
[
2
]
=
'营业额扣点:'
.
$HouseInfosre
[
0
][
'price'
]
.
'%'
;
$message
[
3
]
=
'每平方米租金:'
.
$HouseInfosre
[
0
][
'price'
]
.
'元/天/㎡'
;
$data
[
'price'
]
=
$message
[
$HouseInfosre
[
0
][
'rent_type'
]];
}
//同联默认图片,如果用户没上传的话/img/houseinfobackgroundimg.png
$data
[
'imagename'
]
=
$homeurl
.
'/img/houseinfobackgroundimg_new.png'
;
...
...
application/model/HouseInfos.php
View file @
c60455d6
...
...
@@ -105,7 +105,7 @@ class HouseInfos extends Model
function
getHousepusmessage
(
$id
)
{
$HouseInfosre
=
$this
->
dbHouseInfo
->
where
(
'id'
,
$id
)
->
field
(
'id,title,room_area,room_area2,price'
)
->
field
(
'id,title,room_area,room_area2,price
,rent_type
'
)
->
select
();
return
$HouseInfosre
;
}
...
...
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