Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Q
qk_backend
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
quanku
qk_backend
Commits
78d9c246
Commit
78d9c246
authored
Dec 01, 2023
by
shiyu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
查询可寄售的商品列表,返回对象修改
parent
a9b906a9
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
1 deletion
+22
-1
ch-core/src/main/java/com/wwdz/ch/core/type/PageSearchResult.java
...src/main/java/com/wwdz/ch/core/type/PageSearchResult.java
+21
-0
ch-wx-api/src/main/java/com/wwdz/ch/wx/impl/ItemServiceImpl.java
...pi/src/main/java/com/wwdz/ch/wx/impl/ItemServiceImpl.java
+1
-1
No files found.
ch-core/src/main/java/com/wwdz/ch/core/type/PageSearchResult.java
View file @
78d9c246
...
@@ -17,6 +17,8 @@ public class PageSearchResult<T> implements Entity {
...
@@ -17,6 +17,8 @@ public class PageSearchResult<T> implements Entity {
private
List
<
T
>
dataList
;
private
List
<
T
>
dataList
;
private
List
<
T
>
list
;
private
Object
appendObject
;
private
Object
appendObject
;
private
Boolean
isHasNextPage
;
private
Boolean
isHasNextPage
;
...
@@ -41,6 +43,14 @@ public class PageSearchResult<T> implements Entity {
...
@@ -41,6 +43,14 @@ public class PageSearchResult<T> implements Entity {
}
}
private
PageSearchResult
(
PageInfo
pageInfo
,
List
<
T
>
list
,
boolean
isConvert
)
{
this
.
total
=
pageInfo
.
getTotal
();
this
.
pageSize
=
pageInfo
.
getPageSize
();
this
.
pageIndex
=
pageInfo
.
getPageNum
();
this
.
isHasNextPage
=
pageInfo
.
isHasNextPage
();
this
.
list
=
list
;
}
public
static
<
T
>
PageSearchResult
of
(
PageInfo
pageInfo
)
{
public
static
<
T
>
PageSearchResult
of
(
PageInfo
pageInfo
)
{
return
new
PageSearchResult
(
pageInfo
);
return
new
PageSearchResult
(
pageInfo
);
}
}
...
@@ -54,6 +64,17 @@ public class PageSearchResult<T> implements Entity {
...
@@ -54,6 +64,17 @@ public class PageSearchResult<T> implements Entity {
return
new
PageSearchResult
(
pageInfo
,
list
);
return
new
PageSearchResult
(
pageInfo
,
list
);
}
}
/**
* dataList 转 list字段
* @param pageInfo
* @param list
* @return
* @param <T>
*/
public
static
<
T
>
PageSearchResult
ofSetList
(
PageInfo
pageInfo
,
List
<
T
>
list
)
{
return
new
PageSearchResult
(
pageInfo
,
list
,
true
);
}
public
Long
getTotal
()
{
public
Long
getTotal
()
{
return
total
;
return
total
;
}
}
...
...
ch-wx-api/src/main/java/com/wwdz/ch/wx/impl/ItemServiceImpl.java
View file @
78d9c246
...
@@ -513,7 +513,7 @@ public class ItemServiceImpl implements ItemService {
...
@@ -513,7 +513,7 @@ public class ItemServiceImpl implements ItemService {
agentTranceResponseVo
.
setDetail
(
itemResponseVo
);
agentTranceResponseVo
.
setDetail
(
itemResponseVo
);
resultList
.
add
(
agentTranceResponseVo
);
resultList
.
add
(
agentTranceResponseVo
);
}
}
PageSearchResult
pageSearchResult
=
PageSearchResult
.
of
(
pageInfo
,
resultList
);
PageSearchResult
pageSearchResult
=
PageSearchResult
.
of
SetList
(
pageInfo
,
resultList
);
return
Result
.
success
(
pageSearchResult
);
return
Result
.
success
(
pageSearchResult
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
logger
.
error
(
"查询可寄售商品列表失败:{}"
,
e
);
logger
.
error
(
"查询可寄售商品列表失败:{}"
,
e
);
...
...
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