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
5295bd6a
Commit
5295bd6a
authored
Jun 10, 2019
by
hujun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
房源搜索
parent
1afc067c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
13 deletions
+9
-13
OfficeRoomService.php
application/index/service/OfficeRoomService.php
+3
-7
OfficeGRoom.php
application/model/OfficeGRoom.php
+6
-6
No files found.
application/index/service/OfficeRoomService.php
View file @
5295bd6a
...
...
@@ -823,25 +823,21 @@ class OfficeRoomService
/*盘方 start*/
if
(
$params
[
'dish_id'
]
!=
NULL
)
{
$agent_where
[
'a.agent_id'
]
=
$params
[
'dish_id'
];
$agent_where
[
'a.type'
]
=
2
;
$agent_where
[
'a.is_del'
]
=
0
;
}
if
(
$params
[
'dish_store_id'
]
!=
NULL
)
{
$agent_where
[
'b.store_id'
]
=
$params
[
'dish_store_id'
];
$agent_where
[
'a.type'
]
=
2
;
$agent_where
[
'a.is_del'
]
=
0
;
}
if
(
$params
[
'dish_district_id'
]
!=
NULL
)
{
$agent_where
[
'b.district_id'
]
=
$params
[
'dish_district_id'
];
$agent_where
[
'a.type'
]
=
2
;
$agent_where
[
'a.is_del'
]
=
0
;
}
try
{
//盘方搜索
if
(
!
empty
(
$agent_where
))
{
$agent_where
[
'a.type'
]
=
2
;
$agent_where
[
'a.is_del'
]
=
0
;
$agent_arr
=
$this
->
agent_room
->
getAgentsByRoomColumn
(
'house_id'
,
$agent_where
);
if
(
empty
(
$agent_arr
))
{
...
...
@@ -849,7 +845,7 @@ class OfficeRoomService
return
$result
;
}
else
{
$agent_str
=
implode
(
','
,
$agent_arr
);
$where
[]
=
[
'EXP'
,
"id in (
{
$agent_str
}
)"
];
$where
[]
=
[
'EXP'
,
"
a.
id in (
{
$agent_str
}
)"
];
}
}
/*盘方 end*/
...
...
application/model/OfficeGRoom.php
View file @
5295bd6a
...
...
@@ -309,12 +309,12 @@ class OfficeGRoom extends BaseModel
return
$this
->
alias
(
'a'
)
->
field
(
$field
)
->
join
(
'office_g_building b'
,
'a.building_id = b.id'
,
'left'
)
->
join
(
'office_g_room_to_agent c'
,
'a.id = c.house_id'
,
'left'
)
->
join
(
'a_agents d'
,
'c.agent_id = d.id'
,
'left'
)
//
->join('office_g_room_to_agent c', 'a.id = c.house_id', 'left')
//
->join('a_agents d', 'c.agent_id = d.id', 'left')
->
where
(
$where
)
->
limit
(
$page_size
)
->
page
(
$page_no
)
->
group
(
'a.id'
)
//
->group('a.id')
->
order
(
'a.id desc'
)
->
select
();
}
...
...
@@ -335,10 +335,10 @@ class OfficeGRoom extends BaseModel
{
return
$this
->
alias
(
'a'
)
->
join
(
'office_g_building b'
,
'a.building_id = b.id'
,
'left'
)
->
join
(
'office_g_room_to_agent c'
,
'a.id = c.house_id'
,
'left'
)
->
join
(
'a_agents d'
,
'c.agent_id = d.id'
,
'left'
)
//
->join('office_g_room_to_agent c', 'a.id = c.house_id', 'left')
//
->join('a_agents d', 'c.agent_id = d.id', 'left')
->
where
(
$where
)
->
group
(
'a.id'
)
//
->group('a.id')
->
count
(
'a.id'
);
}
...
...
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