Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gic-store
Overview
Overview
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
base_platform_enterprise
gic-store
Commits
007ffcf0
Commit
007ffcf0
authored
Mar 10, 2020
by
陶光胜
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'developer' of
http://115.159.76.241/base_platform_enterprise/gic-store
into developer
parents
e961f19d
0f344c32
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
5 deletions
+20
-5
StoreApiServiceImpl.java
...com/gic/store/service/outer/impl/StoreApiServiceImpl.java
+4
-2
StoreGroupApiServiceImpl.java
...ic/store/service/outer/impl/StoreGroupApiServiceImpl.java
+16
-3
No files found.
gic-store-service/src/main/java/com/gic/store/service/outer/impl/StoreApiServiceImpl.java
View file @
007ffcf0
...
...
@@ -379,8 +379,10 @@ public class StoreApiServiceImpl implements StoreApiService {
storeDTO
.
setStoreGroupId
(
Integer
.
valueOf
(
groupId
));
}
else
{
// 未命中
TabStoreGroup
group
=
storeGroupService
.
selectUnGroupedStore
(
storeDTO
.
getEnterpriseId
());
storeDTO
.
setStoreGroupId
(
group
.
getStoreGroupId
());
if
(
storeDTO
.
getStoreGroupId
()
!=
null
)
{
TabStoreGroup
group
=
storeGroupService
.
selectUnGroupedStore
(
storeDTO
.
getEnterpriseId
());
storeDTO
.
setStoreGroupId
(
group
.
getStoreGroupId
());
}
}
}
return
null
;
...
...
gic-store-service/src/main/java/com/gic/store/service/outer/impl/StoreGroupApiServiceImpl.java
View file @
007ffcf0
...
...
@@ -112,7 +112,10 @@ public class StoreGroupApiServiceImpl implements StoreGroupApiService {
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"父级ID参数错误"
);
}
int
storeGroupParentId
=
storeGroupDTO
.
getParentStoreGroupId
();
validIsDefault
(
storeGroupParentId
);
ServiceResponse
<
TabStoreGroup
>
authValid
=
validIsDefault
(
storeGroupParentId
);
if
(!
authValid
.
isSuccess
())
{
return
ServiceResponse
.
failure
(
authValid
.
getCode
(),
authValid
.
getMessage
());
}
int
oldStoreGroupParentId
=
oldStoreGroup
.
getParentStoreGroupId
();
boolean
hasEditParentId
=
storeGroupParentId
!=
oldStoreGroupParentId
;
if
(
hasEditParentId
)
{
...
...
@@ -164,7 +167,10 @@ public class StoreGroupApiServiceImpl implements StoreGroupApiService {
if
(
StringUtils
.
isBlank
(
storeGroupDTO
.
getStoreGroupName
()))
{
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"名称不能为空"
);
}
validIsDefault
(
storeGroupDTO
.
getStoreGroupId
());
ServiceResponse
<
TabStoreGroup
>
authValid
=
validIsDefault
(
storeGroupDTO
.
getStoreGroupId
());
if
(!
authValid
.
isSuccess
())
{
return
ServiceResponse
.
failure
(
authValid
.
getCode
(),
authValid
.
getMessage
());
}
if
(
storeGroupService
.
isRepeatName
(
storeGroupDTO
.
getStoreGroupName
(),
storeGroupDTO
.
getStoreGroupId
(),
storeGroupDTO
.
getEnterpriseId
()))
{
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"名称不能重复"
);
...
...
@@ -244,6 +250,10 @@ public class StoreGroupApiServiceImpl implements StoreGroupApiService {
if
(
isContainStore
(
storeGroupId
))
{
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"该分组下存在门店,不能删除"
);
}
ServiceResponse
<
TabStoreGroup
>
authValid
=
validIsDefault
(
storeGroupId
);
if
(!
authValid
.
isSuccess
())
{
return
ServiceResponse
.
failure
(
authValid
.
getCode
(),
authValid
.
getMessage
());
}
TabStoreGroup
tabStoreGroup
=
new
TabStoreGroup
();
tabStoreGroup
.
setStoreGroupId
(
storeGroupId
);
tabStoreGroup
.
setStatus
(
0
);
...
...
@@ -269,7 +279,10 @@ public class StoreGroupApiServiceImpl implements StoreGroupApiService {
if
(
tabStoreGroup
==
null
)
{
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"主键错误,查询不到数据"
);
}
validIsDefault
(
storeGroupId
);
ServiceResponse
<
TabStoreGroup
>
authValid
=
validIsDefault
(
storeGroupId
);
if
(!
authValid
.
isSuccess
())
{
return
ServiceResponse
.
failure
(
authValid
.
getCode
(),
authValid
.
getMessage
());
}
if
(
setSortValue
==
null
)
{
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"拖拽排序值不能为空"
);
}
...
...
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