Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
usedCarAuction
/
aus
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 48800e0d
authored
Feb 05, 2026
by
章家宝
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
优化文字提示,修复分页bug
1 parent
31d8e59c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
5 deletions
aus-core/src/main/java/com/glsx/usedcar/module/account/service/AccountPreferenceService.java
aus-core/src/main/java/com/glsx/usedcar/module/account/service/AccountPreferenceService.java
View file @
48800e0
...
@@ -8,7 +8,6 @@ import com.glsx.usedcar.module.account.dto.*;
...
@@ -8,7 +8,6 @@ import com.glsx.usedcar.module.account.dto.*;
import
com.glsx.usedcar.module.account.entity.*
;
import
com.glsx.usedcar.module.account.entity.*
;
import
com.glsx.usedcar.module.account.enums.*
;
import
com.glsx.usedcar.module.account.enums.*
;
import
com.glsx.usedcar.util.AdCodeToProvinceUtil
;
import
com.glsx.usedcar.util.AdCodeToProvinceUtil
;
import
com.glsx.usedcar.util.ChineseFirstLetterUtil
;
import
jakarta.persistence.criteria.*
;
import
jakarta.persistence.criteria.*
;
import
lombok.Data
;
import
lombok.Data
;
import
lombok.RequiredArgsConstructor
;
import
lombok.RequiredArgsConstructor
;
...
@@ -51,7 +50,7 @@ public class AccountPreferenceService {
...
@@ -51,7 +50,7 @@ public class AccountPreferenceService {
"vehicle_type"
,
VehicleTypeEnum:
:
getDescByCode
"vehicle_type"
,
VehicleTypeEnum:
:
getDescByCode
);
);
private
static
final
String
CITY_FORMAT
=
"%s
(%s)-%s
"
;
private
static
final
String
CITY_FORMAT
=
"%s
"
;
/**
/**
* 获取用户偏好:根据登录用户查询完整偏好信息(主表+关联表)
* 获取用户偏好:根据登录用户查询完整偏好信息(主表+关联表)
...
@@ -256,7 +255,7 @@ public class AccountPreferenceService {
...
@@ -256,7 +255,7 @@ public class AccountPreferenceService {
addValueDescription
(
opDesc
,
AccountPreferenceValue
.
PreferenceType
.
vehicle_condition
,
dto
.
getVehicleCondition
(),
"车况"
);
addValueDescription
(
opDesc
,
AccountPreferenceValue
.
PreferenceType
.
vehicle_condition
,
dto
.
getVehicleCondition
(),
"车况"
);
addValueDescription
(
opDesc
,
AccountPreferenceValue
.
PreferenceType
.
business_model
,
dto
.
getBusinessModel
(),
"经营模式"
);
addValueDescription
(
opDesc
,
AccountPreferenceValue
.
PreferenceType
.
business_model
,
dto
.
getBusinessModel
(),
"经营模式"
);
addValueDescription
(
opDesc
,
AccountPreferenceValue
.
PreferenceType
.
vehicle_age
,
dto
.
getVehicleAge
(),
"
车辆年限
"
);
addValueDescription
(
opDesc
,
AccountPreferenceValue
.
PreferenceType
.
vehicle_age
,
dto
.
getVehicleAge
(),
"
偏好车龄
"
);
addValueDescription
(
opDesc
,
AccountPreferenceValue
.
PreferenceType
.
vehicle_fuel_type
,
dto
.
getVehicleFuelType
(),
"燃油类型"
);
addValueDescription
(
opDesc
,
AccountPreferenceValue
.
PreferenceType
.
vehicle_fuel_type
,
dto
.
getVehicleFuelType
(),
"燃油类型"
);
if
(!
newVehicleTypeMap
.
isEmpty
())
{
if
(!
newVehicleTypeMap
.
isEmpty
())
{
...
@@ -402,7 +401,7 @@ public class AccountPreferenceService {
...
@@ -402,7 +401,7 @@ public class AccountPreferenceService {
// 转换为JPA PageRequest(项目原有分页逻辑)
// 转换为JPA PageRequest(项目原有分页逻辑)
Sort
sort
=
buildSort
(
pagination
);
Sort
sort
=
buildSort
(
pagination
);
PageRequest
pageRequest
=
PageRequest
.
of
(
PageRequest
pageRequest
=
PageRequest
.
of
(
pagination
.
getOffset
(),
pagination
.
getOffset
()
/
pagination
.
getLimit
()
,
pagination
.
getLimit
(),
pagination
.
getLimit
(),
sort
sort
);
);
...
@@ -753,7 +752,7 @@ public class AccountPreferenceService {
...
@@ -753,7 +752,7 @@ public class AccountPreferenceService {
}
}
private
String
formatCityInfo
(
String
cityName
,
String
cityCode
,
String
cityCn
)
{
private
String
formatCityInfo
(
String
cityName
,
String
cityCode
,
String
cityCn
)
{
return
String
.
format
(
CITY_FORMAT
,
cityName
,
cityCode
,
cityCn
);
return
String
.
format
(
CITY_FORMAT
,
cityName
);
}
}
private
String
removeTrailingSemicolon
(
StringBuilder
sb
)
{
private
String
removeTrailingSemicolon
(
StringBuilder
sb
)
{
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment