Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
R
rs-cloud-platform
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
周健威
rs-cloud-platform
Commits
0d45548b
Commit
0d45548b
authored
Jan 04, 2021
by
周健威
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/dev' into dev
parents
2ca0fe65
7ef3955d
Changes
18
Hide whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
48 additions
and
46 deletions
+48
-46
AssertUtils.java
.../com/github/wxiaoqi/security/common/util/AssertUtils.java
+1
-1
AccessGatewayFilter.java
...hub/wxiaoqi/security/gate/filter/AccessGatewayFilter.java
+2
-2
UserDTO.java
.../com/github/wxiaoqi/security/admin/feign/dto/UserDTO.java
+1
-1
AppUserLogRemarkBiz.java
...ithub/wxiaoqi/security/admin/biz/AppUserLogRemarkBiz.java
+1
-1
AppUserLoginBiz.java
...om/github/wxiaoqi/security/admin/biz/AppUserLoginBiz.java
+1
-1
BaseUserMemberExportBiz.java
...b/wxiaoqi/security/admin/biz/BaseUserMemberExportBiz.java
+2
-2
PermissionService.java
...wxiaoqi/security/admin/rpc/service/PermissionService.java
+2
-2
RscpImagePriceController.java
...platform/rs/datacenter/rest/RscpImagePriceController.java
+2
-2
DictionaryBiz.java
...a/com/upyuns/platform/rs/universal/biz/DictionaryBiz.java
+2
-2
ImageImgStorageBiz.java
...om/upyuns/platform/rs/website/biz/ImageImgStorageBiz.java
+5
-9
ImageInfoRelationBiz.java
.../upyuns/platform/rs/website/biz/ImageInfoRelationBiz.java
+2
-6
IndustryApplicationInfoBiz.java
...s/platform/rs/website/biz/IndustryApplicationInfoBiz.java
+5
-1
NoticeInfoBiz.java
...ava/com/upyuns/platform/rs/website/biz/NoticeInfoBiz.java
+1
-1
OrderInfoBiz.java
...java/com/upyuns/platform/rs/website/biz/OrderInfoBiz.java
+14
-10
ShoppingCartInfoBiz.java
...m/upyuns/platform/rs/website/biz/ShoppingCartInfoBiz.java
+3
-3
UserAddressBiz.java
...va/com/upyuns/platform/rs/website/biz/UserAddressBiz.java
+1
-1
UserInvoiceBiz.java
...va/com/upyuns/platform/rs/website/biz/UserInvoiceBiz.java
+1
-1
NewsInfoWebController.java
...form/rs/website/controller/web/NewsInfoWebController.java
+2
-0
No files found.
ace-common/src/main/java/com/github/wxiaoqi/security/common/util/AssertUtils.java
View file @
0d45548b
...
@@ -126,7 +126,7 @@ public class AssertUtils {
...
@@ -126,7 +126,7 @@ public class AssertUtils {
throw
new
BaseException
(
orr
.
getMessage
(),
orr
.
getStatus
());
throw
new
BaseException
(
orr
.
getMessage
(),
orr
.
getStatus
());
}
}
orr
.
setData
(
orr
.
getData
().
parallelS
tream
().
map
(
t
->
BeanUtil
.
toBean
(
t
,
tClass
)).
collect
(
Collectors
.
toList
()));
orr
.
setData
(
orr
.
getData
().
s
tream
().
map
(
t
->
BeanUtil
.
toBean
(
t
,
tClass
)).
collect
(
Collectors
.
toList
()));
return
orr
.
getData
();
return
orr
.
getData
();
}
}
...
...
ace-gate/src/main/java/com/github/wxiaoqi/security/gate/filter/AccessGatewayFilter.java
View file @
0d45548b
...
@@ -175,7 +175,7 @@ public class AccessGatewayFilter implements GlobalFilter {
...
@@ -175,7 +175,7 @@ public class AccessGatewayFilter implements GlobalFilter {
* @return
* @return
*/
*/
private
Stream
<
PermissionInfo
>
getPermissionIfs
(
final
String
requestUri
,
final
String
method
,
List
<
PermissionInfo
>
serviceInfo
)
{
private
Stream
<
PermissionInfo
>
getPermissionIfs
(
final
String
requestUri
,
final
String
method
,
List
<
PermissionInfo
>
serviceInfo
)
{
return
serviceInfo
.
parallelS
tream
().
filter
(
new
Predicate
<
PermissionInfo
>()
{
return
serviceInfo
.
s
tream
().
filter
(
new
Predicate
<
PermissionInfo
>()
{
@Override
@Override
public
boolean
test
(
PermissionInfo
permissionInfo
)
{
public
boolean
test
(
PermissionInfo
permissionInfo
)
{
String
uri
=
permissionInfo
.
getUri
();
String
uri
=
permissionInfo
.
getUri
();
...
@@ -230,7 +230,7 @@ public class AccessGatewayFilter implements GlobalFilter {
...
@@ -230,7 +230,7 @@ public class AccessGatewayFilter implements GlobalFilter {
}
}
PermissionInfo
current
=
null
;
PermissionInfo
current
=
null
;
for
(
PermissionInfo
info
:
permissions
)
{
for
(
PermissionInfo
info
:
permissions
)
{
boolean
anyMatch
=
permissionInfos
.
parallelS
tream
().
anyMatch
(
new
Predicate
<
PermissionInfo
>()
{
boolean
anyMatch
=
permissionInfos
.
s
tream
().
anyMatch
(
new
Predicate
<
PermissionInfo
>()
{
@Override
@Override
public
boolean
test
(
PermissionInfo
permissionInfo
)
{
public
boolean
test
(
PermissionInfo
permissionInfo
)
{
return
permissionInfo
.
getCode
().
equals
(
info
.
getCode
());
return
permissionInfo
.
getCode
().
equals
(
info
.
getCode
());
...
...
ace-modules/ace-admin-api/src/main/java/com/github/wxiaoqi/security/admin/feign/dto/UserDTO.java
View file @
0d45548b
...
@@ -22,7 +22,7 @@ public class UserDTO extends User {
...
@@ -22,7 +22,7 @@ public class UserDTO extends User {
private
List
<
Integer
>
str2List
(
String
str
)
{
private
List
<
Integer
>
str2List
(
String
str
)
{
if
(
StringUtils
.
isNotBlank
(
str
))
{
if
(
StringUtils
.
isNotBlank
(
str
))
{
return
Arrays
.
asList
(
str
.
split
(
","
)).
parallelS
tream
().
map
(
s
->
Integer
.
valueOf
(
s
)).
collect
(
Collectors
.
toList
());
return
Arrays
.
asList
(
str
.
split
(
","
)).
s
tream
().
map
(
s
->
Integer
.
valueOf
(
s
)).
collect
(
Collectors
.
toList
());
}
else
{
}
else
{
return
new
ArrayList
<
Integer
>();
return
new
ArrayList
<
Integer
>();
}
}
...
...
ace-modules/ace-admin/src/main/java/com/github/wxiaoqi/security/admin/biz/AppUserLogRemarkBiz.java
View file @
0d45548b
...
@@ -51,7 +51,7 @@ public class AppUserLogRemarkBiz extends BaseBiz<AppUserLogRemarkMapper, AppUser
...
@@ -51,7 +51,7 @@ public class AppUserLogRemarkBiz extends BaseBiz<AppUserLogRemarkMapper, AppUser
example
.
orderBy
(
"time"
).
desc
().
orderBy
(
"crtTime"
).
desc
();
example
.
orderBy
(
"time"
).
desc
().
orderBy
(
"crtTime"
).
desc
();
List
<
AppUserLogRemark
>
list
=
selectByExample
(
example
);
List
<
AppUserLogRemark
>
list
=
selectByExample
(
example
);
if
(
CollectionUtil
.
isNotEmpty
(
list
))
{
if
(
CollectionUtil
.
isNotEmpty
(
list
))
{
list
.
parallelS
tream
().
peek
(
e
->
{
list
.
s
tream
().
peek
(
e
->
{
if
(!
Objects
.
isNull
(
e
))
{
if
(!
Objects
.
isNull
(
e
))
{
e
.
setPhotoList
(
Lists
.
newArrayList
(
e
.
getPhotos
().
split
(
","
)));
e
.
setPhotoList
(
Lists
.
newArrayList
(
e
.
getPhotos
().
split
(
","
)));
}
}
...
...
ace-modules/ace-admin/src/main/java/com/github/wxiaoqi/security/admin/biz/AppUserLoginBiz.java
View file @
0d45548b
...
@@ -244,7 +244,7 @@ public class AppUserLoginBiz extends BaseBiz<AppUserLoginMapper, AppUserLogin> {
...
@@ -244,7 +244,7 @@ public class AppUserLoginBiz extends BaseBiz<AppUserLoginMapper, AppUserLogin> {
List
<
AppUserLogin
>
appUserLogins
=
mapper
.
selectbyPhones
(
phones
);
List
<
AppUserLogin
>
appUserLogins
=
mapper
.
selectbyPhones
(
phones
);
Map
<
String
,
Integer
>
phoneAndUserIdMap
=
null
;
Map
<
String
,
Integer
>
phoneAndUserIdMap
=
null
;
if
(
CollectionUtils
.
isNotEmpty
(
appUserLogins
))
{
if
(
CollectionUtils
.
isNotEmpty
(
appUserLogins
))
{
phoneAndUserIdMap
=
appUserLogins
.
parallelS
tream
().
collect
(
Collectors
.
toMap
(
AppUserLogin:
:
getUsername
,
AppUserLogin:
:
getId
));
phoneAndUserIdMap
=
appUserLogins
.
s
tream
().
collect
(
Collectors
.
toMap
(
AppUserLogin:
:
getUsername
,
AppUserLogin:
:
getId
));
}
}
return
phoneAndUserIdMap
;
return
phoneAndUserIdMap
;
}
}
...
...
ace-modules/ace-admin/src/main/java/com/github/wxiaoqi/security/admin/biz/BaseUserMemberExportBiz.java
View file @
0d45548b
...
@@ -105,8 +105,8 @@ public class BaseUserMemberExportBiz extends BaseBiz<BaseUserMemberExportMapper,
...
@@ -105,8 +105,8 @@ public class BaseUserMemberExportBiz extends BaseBiz<BaseUserMemberExportMapper,
List
<
BaseUserMemberExport
>
baseUserMemberExports
=
new
ArrayList
<>();
List
<
BaseUserMemberExport
>
baseUserMemberExports
=
new
ArrayList
<>();
List
<
BaseUserMemberLevel
>
levesls
=
userMemberLevelBiz
.
getLevesls
();
List
<
BaseUserMemberLevel
>
levesls
=
userMemberLevelBiz
.
getLevesls
();
Map
<
Integer
,
BaseUserMemberLevel
>
levelAndbaseUserMemberMap
=
levesls
.
parallelS
tream
().
collect
(
Collectors
.
toMap
(
BaseUserMemberLevel:
:
getLevel
,
Function
.
identity
()));
Map
<
Integer
,
BaseUserMemberLevel
>
levelAndbaseUserMemberMap
=
levesls
.
s
tream
().
collect
(
Collectors
.
toMap
(
BaseUserMemberLevel:
:
getLevel
,
Function
.
identity
()));
Map
<
String
,
Integer
>
leavelNameAndLeaveMap
=
levelAndbaseUserMemberMap
.
values
().
parallelS
tream
().
collect
(
Collectors
.
toMap
(
BaseUserMemberLevel:
:
getName
,
BaseUserMemberLevel:
:
getLevel
));
Map
<
String
,
Integer
>
leavelNameAndLeaveMap
=
levelAndbaseUserMemberMap
.
values
().
s
tream
().
collect
(
Collectors
.
toMap
(
BaseUserMemberLevel:
:
getName
,
BaseUserMemberLevel:
:
getLevel
));
List
<
String
>
phones
=
userMemberData
.
stream
().
map
(
x
->
x
[
0
]).
distinct
().
collect
(
Collectors
.
toList
());
List
<
String
>
phones
=
userMemberData
.
stream
().
map
(
x
->
x
[
0
]).
distinct
().
collect
(
Collectors
.
toList
());
Map
<
String
,
Integer
>
phoneAndUserIdMap
=
appUserLoginBiz
.
findPhoneAndUserIdMapByPhones
(
phones
);
Map
<
String
,
Integer
>
phoneAndUserIdMap
=
appUserLoginBiz
.
findPhoneAndUserIdMapByPhones
(
phones
);
...
...
ace-modules/ace-admin/src/main/java/com/github/wxiaoqi/security/admin/rpc/service/PermissionService.java
View file @
0d45548b
...
@@ -140,11 +140,11 @@ public class PermissionService {
...
@@ -140,11 +140,11 @@ public class PermissionService {
FrontUser
frontUser
=
new
FrontUser
();
FrontUser
frontUser
=
new
FrontUser
();
BeanUtils
.
copyProperties
(
user
,
frontUser
);
BeanUtils
.
copyProperties
(
user
,
frontUser
);
List
<
PermissionInfo
>
permissionInfos
=
this
.
getPermissionByUsername
(
username
);
List
<
PermissionInfo
>
permissionInfos
=
this
.
getPermissionByUsername
(
username
);
Stream
<
PermissionInfo
>
menus
=
permissionInfos
.
parallelS
tream
().
filter
((
permission
)
->
{
Stream
<
PermissionInfo
>
menus
=
permissionInfos
.
s
tream
().
filter
((
permission
)
->
{
return
permission
.
getType
().
equals
(
CommonConstants
.
RESOURCE_TYPE_MENU
);
return
permission
.
getType
().
equals
(
CommonConstants
.
RESOURCE_TYPE_MENU
);
});
});
frontUser
.
setMenus
(
menus
.
collect
(
Collectors
.
toList
()));
frontUser
.
setMenus
(
menus
.
collect
(
Collectors
.
toList
()));
Stream
<
PermissionInfo
>
elements
=
permissionInfos
.
parallelS
tream
().
filter
((
permission
)
->
{
Stream
<
PermissionInfo
>
elements
=
permissionInfos
.
s
tream
().
filter
((
permission
)
->
{
return
!
permission
.
getType
().
equals
(
CommonConstants
.
RESOURCE_TYPE_MENU
);
return
!
permission
.
getType
().
equals
(
CommonConstants
.
RESOURCE_TYPE_MENU
);
});
});
frontUser
.
setElements
(
elements
.
collect
(
Collectors
.
toList
()));
frontUser
.
setElements
(
elements
.
collect
(
Collectors
.
toList
()));
...
...
rs-datacenter/rs-datacenter-server/src/main/java/com/upyuns/platform/rs/datacenter/rest/RscpImagePriceController.java
View file @
0d45548b
...
@@ -40,9 +40,9 @@ public class RscpImagePriceController extends BaseController<RscpImagePriceBiz,
...
@@ -40,9 +40,9 @@ public class RscpImagePriceController extends BaseController<RscpImagePriceBiz,
List
<
ImagePriceVO
>
imagePriceVOS
=
CollUtil
.
newArrayList
();
List
<
ImagePriceVO
>
imagePriceVOS
=
CollUtil
.
newArrayList
();
String
key
=
""
;
String
key
=
""
;
List
<
String
>
satelliteTypes
=
list
.
parallelS
tream
().
map
(
RscpImagePrice:
:
getImageSatelliteType
).
distinct
().
collect
(
Collectors
.
toList
());
List
<
String
>
satelliteTypes
=
list
.
s
tream
().
map
(
RscpImagePrice:
:
getImageSatelliteType
).
distinct
().
collect
(
Collectors
.
toList
());
for
(
String
satelliteType
:
satelliteTypes
)
{
for
(
String
satelliteType
:
satelliteTypes
)
{
List
<
RscpImagePrice
>
imagePriceList
=
list
.
parallelS
tream
().
filter
(
rscpImagePrice
->
satelliteType
.
equals
(
rscpImagePrice
.
getImageSatelliteType
())).
collect
(
Collectors
.
toList
());
List
<
RscpImagePrice
>
imagePriceList
=
list
.
s
tream
().
filter
(
rscpImagePrice
->
satelliteType
.
equals
(
rscpImagePrice
.
getImageSatelliteType
())).
collect
(
Collectors
.
toList
());
imagePriceVOS
.
add
(
new
ImagePriceVO
(){{
imagePriceVOS
.
add
(
new
ImagePriceVO
(){{
setImageSatelliteType
(
satelliteType
);
setImageSatelliteType
(
satelliteType
);
setSatelliteName
(
imagePriceList
.
get
(
0
).
getSatelliteName
());
setSatelliteName
(
imagePriceList
.
get
(
0
).
getSatelliteName
());
...
...
rs-universal/rs-universal-server/src/main/java/com/upyuns/platform/rs/universal/biz/DictionaryBiz.java
View file @
0d45548b
...
@@ -105,7 +105,7 @@ public class DictionaryBiz extends BaseBiz<DictionaryMapper, Dictionary> {
...
@@ -105,7 +105,7 @@ public class DictionaryBiz extends BaseBiz<DictionaryMapper, Dictionary> {
public
Map
<
String
,
Dictionary
>
getAll4Map
()
{
public
Map
<
String
,
Dictionary
>
getAll4Map
()
{
// List<Dictionary> dictionaries = this.getParentCommon(null);
// List<Dictionary> dictionaries = this.getParentCommon(null);
List
<
Dictionary
>
dictionaries
=
selectListAll
();
List
<
Dictionary
>
dictionaries
=
selectListAll
();
Map
<
String
,
Dictionary
>
dictionaryMap
=
dictionaries
.
parallelS
tream
().
collect
(
Collectors
.
toMap
(
dic
->
dic
.
getType
()
+
"_"
+
dic
.
getCode
()
Map
<
String
,
Dictionary
>
dictionaryMap
=
dictionaries
.
s
tream
().
collect
(
Collectors
.
toMap
(
dic
->
dic
.
getType
()
+
"_"
+
dic
.
getCode
()
,
Function
.
identity
(),
(
oldValue
,
newValue
)
->
newValue
));
,
Function
.
identity
(),
(
oldValue
,
newValue
)
->
newValue
));
dictionaryMap
.
forEach
((
k
,
v
)
->
{
dictionaryMap
.
forEach
((
k
,
v
)
->
{
v
.
setChildrens
(
buildTree
(
v
.
getId
()));
v
.
setChildrens
(
buildTree
(
v
.
getId
()));
...
@@ -115,7 +115,7 @@ public class DictionaryBiz extends BaseBiz<DictionaryMapper, Dictionary> {
...
@@ -115,7 +115,7 @@ public class DictionaryBiz extends BaseBiz<DictionaryMapper, Dictionary> {
/* public Map<String, Dictionary> getDictionaryUseType() {
/* public Map<String, Dictionary> getDictionaryUseType() {
List<Dictionary> dictionaries = selectListAll();
List<Dictionary> dictionaries = selectListAll();
Map<String, Dictionary> dictionaryMap = dictionaries.
parallelS
tream().collect(Collectors.toMap(dic -> dic.getType() + "_" + dic.getCode()
Map<String, Dictionary> dictionaryMap = dictionaries.
s
tream().collect(Collectors.toMap(dic -> dic.getType() + "_" + dic.getCode()
, Function.identity(), (oldValue, newValue) -> newValue));
, Function.identity(), (oldValue, newValue) -> newValue));
return dictionaryMap;
return dictionaryMap;
}*/
}*/
...
...
rs-website/rs-website-server/src/main/java/com/upyuns/platform/rs/website/biz/ImageImgStorageBiz.java
View file @
0d45548b
...
@@ -46,13 +46,11 @@ public class ImageImgStorageBiz extends BaseBiz<ImageImgStorageMapper,ImageImgSt
...
@@ -46,13 +46,11 @@ public class ImageImgStorageBiz extends BaseBiz<ImageImgStorageMapper,ImageImgSt
if
(
imageImgStorage
.
getId
()
==
null
)
{
if
(
imageImgStorage
.
getId
()
==
null
)
{
insertSelectiveRe
(
imageImgStorage
);
insertSelectiveRe
(
imageImgStorage
);
if
(
imageImgStorage
.
getImageInfoRelationList
()
!=
null
&&
imageImgStorage
.
getImageInfoRelationList
().
size
()
>
0
)
{
if
(
imageImgStorage
.
getImageInfoRelationList
()
!=
null
&&
imageImgStorage
.
getImageInfoRelationList
().
size
()
>
0
)
{
imageImgStorage
.
getImageInfoRelationList
().
parallelS
tream
().
forEach
(
imageInfoRelation
->
{
imageImgStorage
.
getImageInfoRelationList
().
s
tream
().
forEach
(
imageInfoRelation
->
{
imageInfoRelation
.
setType
(
1
);
imageInfoRelation
.
setType
(
1
);
imageInfoRelation
.
setRelationId
(
imageImgStorage
.
getId
());
imageInfoRelation
.
setRelationId
(
imageImgStorage
.
getId
());
imageInfoRelationBiz
.
addUpdate
(
imageInfoRelation
);
imageInfoRelationBiz
.
addUpdate
(
imageInfoRelation
);
});
});
}
else
{
imageInfoRelationBiz
.
deleteAll
(
imageImgStorage
.
getId
());
}
}
}
else
{
}
else
{
ImageImgStorage
old
=
selectById
(
imageImgStorage
.
getId
());
ImageImgStorage
old
=
selectById
(
imageImgStorage
.
getId
());
...
@@ -62,15 +60,13 @@ public class ImageImgStorageBiz extends BaseBiz<ImageImgStorageMapper,ImageImgSt
...
@@ -62,15 +60,13 @@ public class ImageImgStorageBiz extends BaseBiz<ImageImgStorageMapper,ImageImgSt
BeanUtil
.
copyProperties
(
imageImgStorage
,
old
,
CopyOptions
.
create
().
setIgnoreNullValue
(
true
).
setIgnoreError
(
true
));
BeanUtil
.
copyProperties
(
imageImgStorage
,
old
,
CopyOptions
.
create
().
setIgnoreNullValue
(
true
).
setIgnoreError
(
true
));
updateSelectiveByIdRe
(
old
);
updateSelectiveByIdRe
(
old
);
}
}
imageInfoRelationBiz
.
deleteAll
(
old
.
getId
());
if
(
old
.
getImageInfoRelationList
()
!=
null
&&
old
.
getImageInfoRelationList
().
size
()
>
0
)
{
if
(
old
.
getImageInfoRelationList
()
!=
null
&&
old
.
getImageInfoRelationList
().
size
()
>
0
)
{
old
.
getImageInfoRelationList
().
parallelS
tream
().
forEach
(
imageInfoRelation
->
{
old
.
getImageInfoRelationList
().
s
tream
().
forEach
(
imageInfoRelation
->
{
imageInfoRelation
.
setType
(
1
);
imageInfoRelation
.
setType
(
1
);
imageInfoRelation
.
setRelationId
(
old
.
getId
());
imageInfoRelation
.
setRelationId
(
old
.
getId
());
imageInfoRelationBiz
.
addUpdate
(
imageInfoRelation
);
imageInfoRelationBiz
.
addUpdate
(
imageInfoRelation
);
});
});
}
else
{
imageInfoRelationBiz
.
deleteAll
(
old
.
getId
());
}
}
}
}
return
ObjectRestResponse
.
succ
();
return
ObjectRestResponse
.
succ
();
...
@@ -102,7 +98,7 @@ public class ImageImgStorageBiz extends BaseBiz<ImageImgStorageMapper,ImageImgSt
...
@@ -102,7 +98,7 @@ public class ImageImgStorageBiz extends BaseBiz<ImageImgStorageMapper,ImageImgSt
Query
query
=
new
Query
(
imageInformationStorageDto
);
Query
query
=
new
Query
(
imageInformationStorageDto
);
PageDataVO
<
ImageImgStorage
>
pageDataVO
=
PageDataVO
.
pageInfo
(
query
,
()
->
mapper
.
selectByExample
(
example
));
PageDataVO
<
ImageImgStorage
>
pageDataVO
=
PageDataVO
.
pageInfo
(
query
,
()
->
mapper
.
selectByExample
(
example
));
if
(
pageDataVO
!=
null
&&
pageDataVO
.
getData
()
!=
null
)
{
if
(
pageDataVO
!=
null
&&
pageDataVO
.
getData
()
!=
null
)
{
pageDataVO
.
getData
().
parallelS
tream
().
forEach
(
imageImgStorage
->
{
pageDataVO
.
getData
().
s
tream
().
forEach
(
imageImgStorage
->
{
List
<
ImageInfoRelation
>
imageInfoRelationList
=
imageInfoRelationBiz
.
getAllById
(
imageImgStorage
.
getId
(),
1
);
List
<
ImageInfoRelation
>
imageInfoRelationList
=
imageInfoRelationBiz
.
getAllById
(
imageImgStorage
.
getId
(),
1
);
if
(
imageInfoRelationList
!=
null
)
{
if
(
imageInfoRelationList
!=
null
)
{
imageImgStorage
.
setImageInfoRelationList
(
imageInfoRelationList
);
imageImgStorage
.
setImageInfoRelationList
(
imageInfoRelationList
);
...
@@ -158,7 +154,7 @@ public class ImageImgStorageBiz extends BaseBiz<ImageImgStorageMapper,ImageImgSt
...
@@ -158,7 +154,7 @@ public class ImageImgStorageBiz extends BaseBiz<ImageImgStorageMapper,ImageImgSt
example
.
orderBy
(
"updTime"
).
desc
();
example
.
orderBy
(
"updTime"
).
desc
();
List
<
ImageImgStorage
>
list
=
mapper
.
selectByExample
(
example
);
List
<
ImageImgStorage
>
list
=
mapper
.
selectByExample
(
example
);
if
(
list
!=
null
&&
list
.
size
()
>
0
)
{
if
(
list
!=
null
&&
list
.
size
()
>
0
)
{
list
.
parallelS
tream
().
forEach
(
imageImgStorage
->
{
list
.
s
tream
().
forEach
(
imageImgStorage
->
{
List
<
ImageInfoRelation
>
imageInfoRelationList
=
imageInfoRelationBiz
.
getAllById
(
imageImgStorage
.
getId
(),
1
);
List
<
ImageInfoRelation
>
imageInfoRelationList
=
imageInfoRelationBiz
.
getAllById
(
imageImgStorage
.
getId
(),
1
);
if
(
imageInfoRelationList
!=
null
)
{
if
(
imageInfoRelationList
!=
null
)
{
imageImgStorage
.
setImageInfoRelationList
(
imageInfoRelationList
);
imageImgStorage
.
setImageInfoRelationList
(
imageInfoRelationList
);
...
...
rs-website/rs-website-server/src/main/java/com/upyuns/platform/rs/website/biz/ImageInfoRelationBiz.java
View file @
0d45548b
...
@@ -29,17 +29,13 @@ public class ImageInfoRelationBiz extends BaseBiz<ImageInfoRelationMapper,ImageI
...
@@ -29,17 +29,13 @@ public class ImageInfoRelationBiz extends BaseBiz<ImageInfoRelationMapper,ImageI
public
void
addUpdate
(
ImageInfoRelation
imageInfoRelation
)
{
public
void
addUpdate
(
ImageInfoRelation
imageInfoRelation
)
{
if
(
imageInfoRelation
.
getId
()
!=
null
)
{
updateSelectiveByIdRe
(
imageInfoRelation
);
}
else
{
insertSelectiveRe
(
imageInfoRelation
);
insertSelectiveRe
(
imageInfoRelation
);
}
}
}
public
void
deleteAll
(
Integer
relationId
)
{
public
void
deleteAll
(
Integer
relationId
)
{
List
<
ImageInfoRelation
>
list
=
selectList
(
new
ImageInfoRelation
(){{
setRelationId
(
relationId
);
setType
(
1
);}});
List
<
ImageInfoRelation
>
list
=
selectList
(
new
ImageInfoRelation
(){{
setRelationId
(
relationId
);
setType
(
1
);}});
if
(
list
!=
null
)
{
if
(
list
!=
null
)
{
list
.
parallelS
tream
().
forEach
(
imageInfoRelation
->
{
list
.
s
tream
().
forEach
(
imageInfoRelation
->
{
delete
(
imageInfoRelation
);
delete
(
imageInfoRelation
);
});
});
}
}
...
@@ -69,7 +65,7 @@ public class ImageInfoRelationBiz extends BaseBiz<ImageInfoRelationMapper,ImageI
...
@@ -69,7 +65,7 @@ public class ImageInfoRelationBiz extends BaseBiz<ImageInfoRelationMapper,ImageI
example
.
createCriteria
().
andEqualTo
(
"relationId"
,
relationId
).
andEqualTo
(
"type"
,
type
);
example
.
createCriteria
().
andEqualTo
(
"relationId"
,
relationId
).
andEqualTo
(
"type"
,
type
);
List
<
ImageInfoRelation
>
list
=
mapper
.
selectByExample
(
example
);
List
<
ImageInfoRelation
>
list
=
mapper
.
selectByExample
(
example
);
if
(
list
!=
null
&&
list
.
size
()
>
0
)
{
if
(
list
!=
null
&&
list
.
size
()
>
0
)
{
list
.
parallelS
tream
().
forEach
(
imageInfoRelation
->
{
list
.
s
tream
().
forEach
(
imageInfoRelation
->
{
imageInfoRelation
.
setUrl
(
null
);
imageInfoRelation
.
setUrl
(
null
);
});
});
return
list
;
return
list
;
...
...
rs-website/rs-website-server/src/main/java/com/upyuns/platform/rs/website/biz/IndustryApplicationInfoBiz.java
View file @
0d45548b
...
@@ -70,6 +70,10 @@ public class IndustryApplicationInfoBiz extends BaseBiz<IndustryApplicationInfoM
...
@@ -70,6 +70,10 @@ public class IndustryApplicationInfoBiz extends BaseBiz<IndustryApplicationInfoM
if
(
old
==
null
||
old
.
getIsDel
()
==
1
)
{
if
(
old
==
null
||
old
.
getIsDel
()
==
1
)
{
return
ObjectRestResponse
.
createFailedResult
(
ResultCode
.
NOTEXIST_CODE
,
ResultCode
.
getMsg
(
ResultCode
.
NOTEXIST_CODE
));
return
ObjectRestResponse
.
createFailedResult
(
ResultCode
.
NOTEXIST_CODE
,
ResultCode
.
getMsg
(
ResultCode
.
NOTEXIST_CODE
));
}
}
IndustryApplicationType
industryTypeVo
=
industryApplicationTypeBiz
.
selectById
(
old
.
getFirstTypeId
());
if
(
industryTypeVo
!=
null
)
{
old
.
setFirstTitle
(
industryTypeVo
.
getTitle
());
}
return
ObjectRestResponse
.
succ
(
old
);
return
ObjectRestResponse
.
succ
(
old
);
}
}
...
@@ -98,7 +102,7 @@ public class IndustryApplicationInfoBiz extends BaseBiz<IndustryApplicationInfoM
...
@@ -98,7 +102,7 @@ public class IndustryApplicationInfoBiz extends BaseBiz<IndustryApplicationInfoM
example
.
orderBy
(
"rank"
);
example
.
orderBy
(
"rank"
);
List
<
IndustryApplicationInfo
>
industryApplicationInfoList
=
mapper
.
selectByExample
(
example
);
List
<
IndustryApplicationInfo
>
industryApplicationInfoList
=
mapper
.
selectByExample
(
example
);
if
(
industryApplicationInfoList
!=
null
&&
industryApplicationInfoList
.
size
()
>
0
)
{
if
(
industryApplicationInfoList
!=
null
&&
industryApplicationInfoList
.
size
()
>
0
)
{
industryApplicationInfoList
.
parallelS
tream
().
forEach
(
industryApplicationInfo
->
{
industryApplicationInfoList
.
s
tream
().
forEach
(
industryApplicationInfo
->
{
if
(
map
.
get
(
industryApplicationInfo
.
getFirstTypeId
())
!=
null
&&
map
.
get
(
industryApplicationInfo
.
getFirstTypeId
()).
size
()
>
0
)
{
if
(
map
.
get
(
industryApplicationInfo
.
getFirstTypeId
())
!=
null
&&
map
.
get
(
industryApplicationInfo
.
getFirstTypeId
()).
size
()
>
0
)
{
IndustryApplicationType
industryApplicationType
=
map
.
get
(
industryApplicationInfo
.
getFirstTypeId
()).
get
(
0
);
IndustryApplicationType
industryApplicationType
=
map
.
get
(
industryApplicationInfo
.
getFirstTypeId
()).
get
(
0
);
IndustryTypeVo
industryTypeVo
=
new
IndustryTypeVo
();
IndustryTypeVo
industryTypeVo
=
new
IndustryTypeVo
();
...
...
rs-website/rs-website-server/src/main/java/com/upyuns/platform/rs/website/biz/NoticeInfoBiz.java
View file @
0d45548b
...
@@ -110,7 +110,7 @@ public class NoticeInfoBiz extends BaseBiz<NoticeInfoMapper,NoticeInfo> {
...
@@ -110,7 +110,7 @@ public class NoticeInfoBiz extends BaseBiz<NoticeInfoMapper,NoticeInfo> {
criteria
.
andEqualTo
(
"userId"
,
noticeInfoDto
.
getUserId
());
criteria
.
andEqualTo
(
"userId"
,
noticeInfoDto
.
getUserId
());
List
<
NoticeInfo
>
list
=
mapper
.
selectByExample
(
example
);
List
<
NoticeInfo
>
list
=
mapper
.
selectByExample
(
example
);
if
(
list
!=
null
&&
list
.
size
()
>
0
)
{
if
(
list
!=
null
&&
list
.
size
()
>
0
)
{
list
.
parallelStream
().
forEach
(
noticeInfo
->
{
list
.
forEach
(
noticeInfo
->
{
noticeInfo
.
setIsRead
(
2
);
noticeInfo
.
setIsRead
(
2
);
updateSelectiveByIdRe
(
noticeInfo
);
updateSelectiveByIdRe
(
noticeInfo
);
});
});
...
...
rs-website/rs-website-server/src/main/java/com/upyuns/platform/rs/website/biz/OrderInfoBiz.java
View file @
0d45548b
...
@@ -208,7 +208,7 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
...
@@ -208,7 +208,7 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
if
(
orderEInvoiceList
!=
null
&&
orderEInvoiceList
.
size
()
>
0
)
{
if
(
orderEInvoiceList
!=
null
&&
orderEInvoiceList
.
size
()
>
0
)
{
Map
<
Integer
,
List
<
OrderEInvoice
>>
map
=
orderEInvoiceList
.
stream
().
collect
(
Collectors
.
groupingBy
(
OrderEInvoice:
:
getId
));
Map
<
Integer
,
List
<
OrderEInvoice
>>
map
=
orderEInvoiceList
.
stream
().
collect
(
Collectors
.
groupingBy
(
OrderEInvoice:
:
getId
));
if
(
map
!=
null
&&
map
.
size
()
>
0
)
{
if
(
map
!=
null
&&
map
.
size
()
>
0
)
{
orderInfoList
.
parallelS
tream
().
forEach
(
orderInfo
->
{
orderInfoList
.
s
tream
().
forEach
(
orderInfo
->
{
if
(
map
.
get
(
orderInfo
.
getInvoiceId
())
!=
null
&&
orderInfo
!=
null
)
{
if
(
map
.
get
(
orderInfo
.
getInvoiceId
())
!=
null
&&
orderInfo
!=
null
)
{
orderInfo
.
setOrderEInvoice
(
map
.
get
(
orderInfo
.
getInvoiceId
()).
get
(
0
));
orderInfo
.
setOrderEInvoice
(
map
.
get
(
orderInfo
.
getInvoiceId
()).
get
(
0
));
}
}
...
@@ -255,7 +255,7 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
...
@@ -255,7 +255,7 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
if
(
orderItemList
!=
null
)
{
if
(
orderItemList
!=
null
)
{
Map
<
Long
,
List
<
OrderItem
>>
map
=
orderItemList
.
stream
().
collect
(
Collectors
.
groupingBy
(
OrderItem:
:
getOrderId
));
Map
<
Long
,
List
<
OrderItem
>>
map
=
orderItemList
.
stream
().
collect
(
Collectors
.
groupingBy
(
OrderItem:
:
getOrderId
));
if
(
map
!=
null
&&
map
.
size
()
>
0
)
{
if
(
map
!=
null
&&
map
.
size
()
>
0
)
{
orderInfoList
.
parallelS
tream
().
forEach
(
orderInfo
->
{
orderInfoList
.
s
tream
().
forEach
(
orderInfo
->
{
orderInfo
.
setOrderItemList
(
map
.
get
(
orderInfo
.
getOrderId
()));
orderInfo
.
setOrderItemList
(
map
.
get
(
orderInfo
.
getOrderId
()));
});
});
}
}
...
@@ -281,7 +281,8 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
...
@@ -281,7 +281,8 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
List
<
OrderItem
>
orderItemList
=
new
ArrayList
<>();
List
<
OrderItem
>
orderItemList
=
new
ArrayList
<>();
AtomicReference
<
Integer
>
number
=
new
AtomicReference
<>(
0
);
AtomicReference
<
Integer
>
number
=
new
AtomicReference
<>(
0
);
AtomicReference
<
Double
>
amount
=
new
AtomicReference
<>((
double
)
0
);
AtomicReference
<
Double
>
amount
=
new
AtomicReference
<>((
double
)
0
);
itemInfoDtoList
.
parallelStream
().
forEach
(
itemInfoDto
->
{
StringBuilder
sb
=
new
StringBuilder
();
itemInfoDtoList
.
forEach
(
itemInfoDto
->
{
switch
(
OrderTypeEnum
.
getByCode
(
itemInfoDto
.
getType
()))
{
switch
(
OrderTypeEnum
.
getByCode
(
itemInfoDto
.
getType
()))
{
//标准数据
//标准数据
case
STANDARD_DATA:
case
STANDARD_DATA:
...
@@ -296,6 +297,8 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
...
@@ -296,6 +297,8 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
orderItem
.
setDetailJson
(
JSONObject
.
toJSONString
(
imageDataVO
));
orderItem
.
setDetailJson
(
JSONObject
.
toJSONString
(
imageDataVO
));
orderItem
.
setDetailId
(
Long
.
valueOf
(
imageDataVO
.
getId
()));
orderItem
.
setDetailId
(
Long
.
valueOf
(
imageDataVO
.
getId
()));
orderItemList
.
add
(
orderItem
);
orderItemList
.
add
(
orderItem
);
sb
.
append
(
imageDataVO
.
getImageSatelliteType
());
sb
.
append
(
","
);
//总数量
//总数量
number
.
updateAndGet
(
v
->
v
+
itemInfoDto
.
getNumber
());
number
.
updateAndGet
(
v
->
v
+
itemInfoDto
.
getNumber
());
BigDecimal
totalAmount
=
imageDataVO
.
getPrice
().
multiply
(
new
BigDecimal
(
itemInfoDto
.
getNumber
()));
BigDecimal
totalAmount
=
imageDataVO
.
getPrice
().
multiply
(
new
BigDecimal
(
itemInfoDto
.
getNumber
()));
...
@@ -426,12 +429,13 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
...
@@ -426,12 +429,13 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
orderInfo
.
setSendType
(
orderInfoDto
.
getSendType
());
orderInfo
.
setSendType
(
orderInfoDto
.
getSendType
());
orderInfo
.
setType
(
1
);
orderInfo
.
setType
(
1
);
orderInfo
.
setSatellite
(
sb
.
toString
());
/**
/**
* 新增订单
* 新增订单
*/
*/
orderInfo
.
setOrderNo
(
OrderUtil
.
GetOrderNumber
(
""
,
OrderUtil
.
APP_MID
));
orderInfo
.
setOrderNo
(
OrderUtil
.
GetOrderNumber
(
""
,
OrderUtil
.
APP_MID
));
generateOrder
(
orderInfo
);
generateOrder
(
orderInfo
);
orderItemList
.
parallelS
tream
().
forEach
(
orderItem
->
{
orderItemList
.
s
tream
().
forEach
(
orderItem
->
{
if
(
orderItem
!=
null
)
{
if
(
orderItem
!=
null
)
{
orderItem
.
setOrderId
(
orderInfo
.
getOrderId
());
orderItem
.
setOrderId
(
orderInfo
.
getOrderId
());
orderItemBiz
.
insertSelective
(
orderItem
);
orderItemBiz
.
insertSelective
(
orderItem
);
...
@@ -790,7 +794,7 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
...
@@ -790,7 +794,7 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
return
ObjectRestResponse
.
createFailedResult
(
ResultCode
.
ORDER_NOT_EXIST
,
ResultCode
.
getMsg
(
ResultCode
.
ORDER_NOT_EXIST
));
return
ObjectRestResponse
.
createFailedResult
(
ResultCode
.
ORDER_NOT_EXIST
,
ResultCode
.
getMsg
(
ResultCode
.
ORDER_NOT_EXIST
));
}
}
List
<
OrderItem
>
orderItemList
=
new
ArrayList
<>();
List
<
OrderItem
>
orderItemList
=
new
ArrayList
<>();
itemInfoDtoList
.
parallelS
tream
().
forEach
(
itemInfoDto
->
{
itemInfoDtoList
.
s
tream
().
forEach
(
itemInfoDto
->
{
switch
(
OrderTypeEnum
.
getByCode
(
itemInfoDto
.
getType
()))
{
switch
(
OrderTypeEnum
.
getByCode
(
itemInfoDto
.
getType
()))
{
//标准数据
//标准数据
case
STANDARD_DATA:
case
STANDARD_DATA:
...
@@ -847,7 +851,7 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
...
@@ -847,7 +851,7 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
break
;
break
;
}
}
});
});
orderItemList
.
parallelS
tream
().
forEach
(
orderItem
->
{
orderItemList
.
s
tream
().
forEach
(
orderItem
->
{
if
(
orderItem
!=
null
)
{
if
(
orderItem
!=
null
)
{
orderItem
.
setOrderId
(
orderInfoDto
.
getOrderId
());
orderItem
.
setOrderId
(
orderInfoDto
.
getOrderId
());
orderItemBiz
.
insertSelective
(
orderItem
);
orderItemBiz
.
insertSelective
(
orderItem
);
...
@@ -930,10 +934,10 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
...
@@ -930,10 +934,10 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
case
IMAGE_STORAGE:
case
IMAGE_STORAGE:
List
<
ImageImgStorage
>
imageImgStorageList
=
imageImgStorageBiz
.
getAll
(
null
,
name
).
getData
();
List
<
ImageImgStorage
>
imageImgStorageList
=
imageImgStorageBiz
.
getAll
(
null
,
name
).
getData
();
if
(
imageImgStorageList
!=
null
&&
imageImgStorageList
.
size
()
>
0
)
{
if
(
imageImgStorageList
!=
null
&&
imageImgStorageList
.
size
()
>
0
)
{
imageImgStorageList
.
parallelS
tream
().
forEach
(
imageImgStorage
->
{
imageImgStorageList
.
s
tream
().
forEach
(
imageImgStorage
->
{
List
<
ImageInfoRelation
>
imageInfoRelationList
=
imageImgStorage
.
getImageInfoRelationList
();
List
<
ImageInfoRelation
>
imageInfoRelationList
=
imageImgStorage
.
getImageInfoRelationList
();
if
(
imageInfoRelationList
!=
null
&&
imageInfoRelationList
.
size
()
>
0
)
{
if
(
imageInfoRelationList
!=
null
&&
imageInfoRelationList
.
size
()
>
0
)
{
imageInfoRelationList
.
parallelS
tream
().
forEach
(
imageInfoRelation
->
{
imageInfoRelationList
.
s
tream
().
forEach
(
imageInfoRelation
->
{
ItemInfoVo
itemInfoVo
=
new
ItemInfoVo
();
ItemInfoVo
itemInfoVo
=
new
ItemInfoVo
();
itemInfoVo
.
setName
(
imageImgStorage
.
getName
()
+
imageInfoRelation
.
getFileWidth
());
itemInfoVo
.
setName
(
imageImgStorage
.
getName
()
+
imageInfoRelation
.
getFileWidth
());
itemInfoVo
.
setId
(
Long
.
parseLong
(
String
.
valueOf
(
imageInfoRelation
.
getId
())));
itemInfoVo
.
setId
(
Long
.
parseLong
(
String
.
valueOf
(
imageInfoRelation
.
getId
())));
...
@@ -953,7 +957,7 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
...
@@ -953,7 +957,7 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
case
INDUSTRY_INFO:
case
INDUSTRY_INFO:
List
<
IndustryApplicationInfo
>
industryApplicationInfoList
=
industryApplicationInfoBiz
.
getAllData
(
name
);
List
<
IndustryApplicationInfo
>
industryApplicationInfoList
=
industryApplicationInfoBiz
.
getAllData
(
name
);
if
(
industryApplicationInfoList
!=
null
&&
industryApplicationInfoList
.
size
()
>
0
)
{
if
(
industryApplicationInfoList
!=
null
&&
industryApplicationInfoList
.
size
()
>
0
)
{
industryApplicationInfoList
.
parallelS
tream
().
forEach
(
industryApplicationInfo
->
{
industryApplicationInfoList
.
s
tream
().
forEach
(
industryApplicationInfo
->
{
ItemInfoVo
itemInfoVo
=
new
ItemInfoVo
();
ItemInfoVo
itemInfoVo
=
new
ItemInfoVo
();
itemInfoVo
.
setName
(
industryApplicationInfo
.
getTitle
());
itemInfoVo
.
setName
(
industryApplicationInfo
.
getTitle
());
itemInfoVo
.
setId
(
Long
.
parseLong
(
String
.
valueOf
(
industryApplicationInfo
.
getId
())));
itemInfoVo
.
setId
(
Long
.
parseLong
(
String
.
valueOf
(
industryApplicationInfo
.
getId
())));
...
@@ -966,7 +970,7 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
...
@@ -966,7 +970,7 @@ public class OrderInfoBiz extends BaseBiz<OrderInfoMapper, OrderInfo> {
setKeyword
(
name
);
setKeyword
(
name
);
}}).
getData
();
}}).
getData
();
if
(
pageDataVO
!=
null
&&
pageDataVO
.
getData
()
!=
null
&&
pageDataVO
.
getData
().
size
()
>
0
)
{
if
(
pageDataVO
!=
null
&&
pageDataVO
.
getData
()
!=
null
&&
pageDataVO
.
getData
().
size
()
>
0
)
{
pageDataVO
.
getData
().
parallelS
tream
().
forEach
(
imageDataVO
->
{
pageDataVO
.
getData
().
s
tream
().
forEach
(
imageDataVO
->
{
ItemInfoVo
itemInfoVo
=
new
ItemInfoVo
();
ItemInfoVo
itemInfoVo
=
new
ItemInfoVo
();
itemInfoVo
.
setName
(
imageDataVO
.
getName
());
itemInfoVo
.
setName
(
imageDataVO
.
getName
());
itemInfoVo
.
setId
(
Long
.
parseLong
(
String
.
valueOf
(
imageDataVO
.
getId
())));
itemInfoVo
.
setId
(
Long
.
parseLong
(
String
.
valueOf
(
imageDataVO
.
getId
())));
...
...
rs-website/rs-website-server/src/main/java/com/upyuns/platform/rs/website/biz/ShoppingCartInfoBiz.java
View file @
0d45548b
...
@@ -267,14 +267,14 @@ public class ShoppingCartInfoBiz extends BaseBiz<ShoppingCartInfoMapper, Shoppin
...
@@ -267,14 +267,14 @@ public class ShoppingCartInfoBiz extends BaseBiz<ShoppingCartInfoMapper, Shoppin
*/
*/
private
void
convertToOrderInfo
(
List
<
ShoppingCartInfo
>
cartInfoList
,
CartOrderDto
cartOrderDto
,
AppUserDTO
appUserDTO
)
{
private
void
convertToOrderInfo
(
List
<
ShoppingCartInfo
>
cartInfoList
,
CartOrderDto
cartOrderDto
,
AppUserDTO
appUserDTO
)
{
//总金额
//总金额
double
amount
=
cartInfoList
.
parallelS
tream
().
mapToDouble
(
shoppingCartInfo
->
shoppingCartInfo
.
getTotalAmount
().
doubleValue
()).
sum
();
double
amount
=
cartInfoList
.
s
tream
().
mapToDouble
(
shoppingCartInfo
->
shoppingCartInfo
.
getTotalAmount
().
doubleValue
()).
sum
();
//总数量
//总数量
Integer
totalNumber
=
cartInfoList
.
parallelS
tream
().
mapToInt
(
ShoppingCartInfo:
:
getNumber
).
sum
();
Integer
totalNumber
=
cartInfoList
.
s
tream
().
mapToInt
(
ShoppingCartInfo:
:
getNumber
).
sum
();
OrderInfo
orderInfo
=
new
OrderInfo
();
OrderInfo
orderInfo
=
new
OrderInfo
();
orderInfo
.
setAmount
(
new
BigDecimal
(
amount
).
setScale
(
2
,
BigDecimal
.
ROUND_HALF_UP
));
orderInfo
.
setAmount
(
new
BigDecimal
(
amount
).
setScale
(
2
,
BigDecimal
.
ROUND_HALF_UP
));
orderInfo
.
setNumber
(
totalNumber
);
orderInfo
.
setNumber
(
totalNumber
);
orderInfoBiz
.
generateOrder
(
orderInfo
);
orderInfoBiz
.
generateOrder
(
orderInfo
);
cartInfoList
.
parallelS
tream
().
forEach
(
shoppingCartInfo
->
{
cartInfoList
.
s
tream
().
forEach
(
shoppingCartInfo
->
{
OrderItem
orderItem
=
ShoppingCartInfo
.
convertToOrderItem
(
shoppingCartInfo
);
OrderItem
orderItem
=
ShoppingCartInfo
.
convertToOrderItem
(
shoppingCartInfo
);
orderItem
.
setOrderId
(
orderInfo
.
getOrderId
());
orderItem
.
setOrderId
(
orderInfo
.
getOrderId
());
orderItemBiz
.
insertSelectiveRe
(
orderItem
);
orderItemBiz
.
insertSelectiveRe
(
orderItem
);
...
...
rs-website/rs-website-server/src/main/java/com/upyuns/platform/rs/website/biz/UserAddressBiz.java
View file @
0d45548b
...
@@ -137,7 +137,7 @@ public class UserAddressBiz extends BaseBiz<UserAddressMapper, UserAddress> {
...
@@ -137,7 +137,7 @@ public class UserAddressBiz extends BaseBiz<UserAddressMapper, UserAddress> {
example
.
createCriteria
().
andEqualTo
(
"userId"
,
userId
).
andEqualTo
(
"isDel"
,
0
).
andEqualTo
(
"isDefault"
,
1
);
example
.
createCriteria
().
andEqualTo
(
"userId"
,
userId
).
andEqualTo
(
"isDel"
,
0
).
andEqualTo
(
"isDefault"
,
1
);
List
<
UserAddress
>
list
=
mapper
.
selectByExample
(
example
);
List
<
UserAddress
>
list
=
mapper
.
selectByExample
(
example
);
if
(
list
!=
null
&&
list
.
size
()
>
0
)
{
if
(
list
!=
null
&&
list
.
size
()
>
0
)
{
list
.
parallelStream
().
forEach
(
userAddress
->
{
list
.
forEach
(
userAddress
->
{
userAddress
.
setIsDefault
(
0
);
userAddress
.
setIsDefault
(
0
);
updateSelectiveByIdRe
(
userAddress
);
updateSelectiveByIdRe
(
userAddress
);
});
});
...
...
rs-website/rs-website-server/src/main/java/com/upyuns/platform/rs/website/biz/UserInvoiceBiz.java
View file @
0d45548b
...
@@ -182,7 +182,7 @@ public class UserInvoiceBiz extends BaseBiz<UserInvoiceMapper,UserInvoice> {
...
@@ -182,7 +182,7 @@ public class UserInvoiceBiz extends BaseBiz<UserInvoiceMapper,UserInvoice> {
example
.
createCriteria
().
andEqualTo
(
"userId"
,
userId
).
andEqualTo
(
"isDel"
,
0
).
andEqualTo
(
"isDefault"
,
1
);
example
.
createCriteria
().
andEqualTo
(
"userId"
,
userId
).
andEqualTo
(
"isDel"
,
0
).
andEqualTo
(
"isDefault"
,
1
);
List
<
UserInvoice
>
list
=
mapper
.
selectByExample
(
example
);
List
<
UserInvoice
>
list
=
mapper
.
selectByExample
(
example
);
if
(
list
!=
null
&&
list
.
size
()
>
0
)
{
if
(
list
!=
null
&&
list
.
size
()
>
0
)
{
list
.
parallelStream
().
forEach
(
userInvoice
->
{
list
.
forEach
(
userInvoice
->
{
userInvoice
.
setIsDefault
(
0
);
userInvoice
.
setIsDefault
(
0
);
updateSelectiveByIdRe
(
userInvoice
);
updateSelectiveByIdRe
(
userInvoice
);
});
});
...
...
rs-website/rs-website-server/src/main/java/com/upyuns/platform/rs/website/controller/web/NewsInfoWebController.java
View file @
0d45548b
...
@@ -23,6 +23,8 @@ public class NewsInfoWebController extends BaseController<NewsInfoBiz, NewsInfo>
...
@@ -23,6 +23,8 @@ public class NewsInfoWebController extends BaseController<NewsInfoBiz, NewsInfo>
@GetMapping
(
value
=
"/app/unauth/getAll"
)
@GetMapping
(
value
=
"/app/unauth/getAll"
)
@IgnoreUserToken
@IgnoreUserToken
public
ObjectRestResponse
getAll
(
NewsInfoDto
newsInfoDto
)
{
public
ObjectRestResponse
getAll
(
NewsInfoDto
newsInfoDto
)
{
newsInfoDto
.
setStatus
(
1
);
newsInfoDto
.
setSortType
(
1
);
return
baseBiz
.
selectList
(
newsInfoDto
);
return
baseBiz
.
selectList
(
newsInfoDto
);
}
}
...
...
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