Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Y
yichengstreet-be
Project
Project
Details
Activity
Releases
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
yichengstreet
yichengstreet-be
Commits
fecad878
Commit
fecad878
authored
Jul 24, 2025
by
lixuan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 房源
parent
22c51553
Pipeline
#145487
canceled with stages
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
30 deletions
+2
-30
HouseResourceController.java
...m/ruoyi/web/controller/house/HouseResourceController.java
+2
-2
HouseResourceServiceImpl.java
...i/system/service/house/impl/HouseResourceServiceImpl.java
+0
-28
No files found.
ruoyi-admin/src/main/java/com/ruoyi/web/controller/house/HouseResourceController.java
View file @
fecad878
...
@@ -78,8 +78,8 @@ public class HouseResourceController {
...
@@ -78,8 +78,8 @@ public class HouseResourceController {
return
AjaxResult
.
success
(
houseResourceService
.
listHouseResources
(
query
));
return
AjaxResult
.
success
(
houseResourceService
.
listHouseResources
(
query
));
}
}
@
Ge
tMapping
(
"/businessEntityStatistics"
)
@
Pos
tMapping
(
"/businessEntityStatistics"
)
public
AjaxResult
getBusinessEntityStatistics
(
HouseResourcePageQuery
query
)
{
public
AjaxResult
getBusinessEntityStatistics
(
@RequestBody
HouseResourcePageQuery
query
)
{
return
AjaxResult
.
success
(
houseResourceService
.
businessEntityStatistics
(
query
));
return
AjaxResult
.
success
(
houseResourceService
.
businessEntityStatistics
(
query
));
}
}
...
...
ruoyi-system/src/main/java/com/ruoyi/system/service/house/impl/HouseResourceServiceImpl.java
View file @
fecad878
...
@@ -322,39 +322,11 @@ public class HouseResourceServiceImpl implements HouseResourceService {
...
@@ -322,39 +322,11 @@ public class HouseResourceServiceImpl implements HouseResourceService {
@Override
@Override
public
BusinessEntityStatisticsDetail
businessEntityStatistics
(
HouseResourcePageQuery
query
)
{
public
BusinessEntityStatisticsDetail
businessEntityStatistics
(
HouseResourcePageQuery
query
)
{
List
<
HouseResourcePage
>
listPages
=
houseResourceMapper
.
selectProfileGraph
(
query
);
List
<
HouseResourcePage
>
listPages
=
houseResourceMapper
.
selectProfileGraph
(
query
);
listPages
.
forEach
(
x
->
x
.
setIncome
(
businessEntityInfoMapper
.
selectYearSellByHouseResourceId
(
x
.
getId
())));
if
(
CollectionUtils
.
isEmpty
(
listPages
))
{
if
(
CollectionUtils
.
isEmpty
(
listPages
))
{
return
new
BusinessEntityStatisticsDetail
();
return
new
BusinessEntityStatisticsDetail
();
}
}
List
<
HouseResourcePage
>
list
=
handleHouseList
(
listPages
,
true
);
List
<
HouseResourcePage
>
list
=
handleHouseList
(
listPages
,
true
);
BusinessEntityStatisticsDetail
businessEntityStatisticsDetail
=
new
BusinessEntityStatisticsDetail
();
BusinessEntityStatisticsDetail
businessEntityStatisticsDetail
=
new
BusinessEntityStatisticsDetail
();
if
(
StringUtils
.
hasText
(
query
.
getTwo
()))
{
list
=
list
.
stream
().
filter
(
x
->
x
.
getTwo
().
equals
(
query
.
getTwo
())).
collect
(
Collectors
.
toList
());
}
if
(
StringUtils
.
hasText
(
query
.
getThree
()))
{
list
=
list
.
stream
().
filter
(
x
->
x
.
getThree
().
equals
(
query
.
getThree
())).
collect
(
Collectors
.
toList
());
}
if
(
CollectionUtils
.
isEmpty
(
list
))
{
return
businessEntityStatisticsDetail
;
}
if
(
StringUtils
.
hasText
(
query
.
getName
()))
{
list
=
list
.
stream
().
filter
(
x
->
!
CollectionUtils
.
isEmpty
(
x
.
getBusinessEntityInfoNames
())).
filter
(
x
->
x
.
getBusinessEntityInfoNames
().
contains
(
query
.
getName
())).
collect
(
Collectors
.
toList
());
}
if
(
Objects
.
nonNull
(
query
.
getHouseAreaMin
()))
{
list
=
list
.
stream
().
filter
(
x
->
Objects
.
nonNull
(
x
.
getHouseArea
())).
filter
(
x
->
x
.
getHouseArea
().
compareTo
(
query
.
getHouseAreaMin
())
>=
0
).
collect
(
Collectors
.
toList
());
}
if
(
Objects
.
nonNull
(
query
.
getHouseAreaMax
()))
{
list
=
list
.
stream
().
filter
(
x
->
Objects
.
nonNull
(
x
.
getHouseArea
())).
filter
(
x
->
x
.
getHouseArea
().
compareTo
(
query
.
getHouseAreaMax
())
<=
0
).
collect
(
Collectors
.
toList
());
}
if
(
Objects
.
nonNull
(
query
.
getYearSellMin
()))
{
list
=
list
.
stream
().
filter
(
x
->
x
.
getIncome
().
compareTo
(
query
.
getYearSellMin
())
>=
0
).
collect
(
Collectors
.
toList
());
}
if
(
Objects
.
nonNull
(
query
.
getYearSellMax
()))
{
list
=
list
.
stream
().
filter
(
x
->
x
.
getIncome
().
compareTo
(
query
.
getYearSellMax
())
<=
0
).
collect
(
Collectors
.
toList
());
}
if
(
CollectionUtils
.
isEmpty
(
list
))
{
return
businessEntityStatisticsDetail
;
}
businessEntityStatisticsDetail
.
setLyCount
(
list
.
stream
().
filter
(
x
->
x
.
getType
()
==
1
).
count
());
businessEntityStatisticsDetail
.
setLyCount
(
list
.
stream
().
filter
(
x
->
x
.
getType
()
==
1
).
count
());
businessEntityStatisticsDetail
.
setJdCount
(
list
.
stream
().
filter
(
x
->
x
.
getType
()
==
4
).
count
());
businessEntityStatisticsDetail
.
setJdCount
(
list
.
stream
().
filter
(
x
->
x
.
getType
()
==
4
).
count
());
businessEntityStatisticsDetail
.
setJqCount
(
list
.
stream
().
filter
(
x
->
x
.
getType
()
==
5
).
count
());
businessEntityStatisticsDetail
.
setJqCount
(
list
.
stream
().
filter
(
x
->
x
.
getType
()
==
5
).
count
());
...
...
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