Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gic-platform-enterprise
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-platform-enterprise
Commits
9b584f87
Commit
9b584f87
authored
Jul 27, 2020
by
guojuxing
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
查询无效的记录,用于判断是否修改过配置,如果修改过,不允许再次edit
parent
4e42a5ea
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
52 additions
and
1 deletions
+52
-1
DataConfigApiService.java
...java/com/gic/enterprise/service/DataConfigApiService.java
+14
-0
TabDataActuallyPaidConfigMapper.java
...nterprise/dao/mapper/TabDataActuallyPaidConfigMapper.java
+3
-0
DataActuallyPaidConfigService.java
...gic/enterprise/service/DataActuallyPaidConfigService.java
+9
-1
DataActuallyPaidConfigServiceImpl.java
...prise/service/impl/DataActuallyPaidConfigServiceImpl.java
+5
-0
DataConfigApiServiceImpl.java
...terprise/service/outer/impl/DataConfigApiServiceImpl.java
+13
-0
TabDataActuallyPaidConfigMapper.xml
...main/resources/mapper/TabDataActuallyPaidConfigMapper.xml
+8
-0
No files found.
gic-platform-enterprise-api/src/main/java/com/gic/enterprise/service/DataConfigApiService.java
View file @
9b584f87
...
...
@@ -63,6 +63,20 @@ public interface DataConfigApiService {
ServiceResponse
<
Void
>
configActuallyPaid
(
Integer
enterpriseId
,
Integer
memberBusiness
,
Integer
performanceCount
);
/**
* 是否已经配置过会员业务(实付)
* @param enterpriseId
* @return
*/
ServiceResponse
<
Boolean
>
hasConfigMemberBusiness
(
Integer
enterpriseId
);
/**
* 是否已经配置过业绩统计(实付)
* @param enterpriseId
* @return
*/
ServiceResponse
<
Boolean
>
hasConfigPerformanceCount
(
Integer
enterpriseId
);
/**
* 实付配置信息
* @Title: listActuallyPaidConfig
* @Description:
...
...
gic-platform-enterprise-service/src/main/java/com/gic/enterprise/dao/mapper/TabDataActuallyPaidConfigMapper.java
View file @
9b584f87
...
...
@@ -57,4 +57,6 @@ public interface TabDataActuallyPaidConfigMapper {
List
<
TabDataActuallyPaidConfig
>
listByEnterpriseId
(
Integer
enterpriseId
);
int
delete
(
@Param
(
"enterpriseId"
)
Integer
enterpriseId
,
@Param
(
"classify"
)
Integer
classify
);
int
count
(
@Param
(
"enterpriseId"
)
Integer
enterpriseId
,
@Param
(
"classify"
)
Integer
classify
);
}
\ No newline at end of file
gic-platform-enterprise-service/src/main/java/com/gic/enterprise/service/DataActuallyPaidConfigService.java
View file @
9b584f87
...
...
@@ -32,8 +32,16 @@ public interface DataActuallyPaidConfigService {
* @Description:
* @author guojuxing
* @param enterpriseId
* @param classify
* @param classify
count
* @return int
*/
int
delete
(
Integer
enterpriseId
,
Integer
classify
);
/**
* 查询无效的记录,用于判断是否修改过配置,如果修改过,不允许再次edit
* @param enterpriseId
* @param classify
* @return
*/
int
count
(
Integer
enterpriseId
,
Integer
classify
);
}
gic-platform-enterprise-service/src/main/java/com/gic/enterprise/service/impl/DataActuallyPaidConfigServiceImpl.java
View file @
9b584f87
...
...
@@ -36,4 +36,9 @@ public class DataActuallyPaidConfigServiceImpl implements DataActuallyPaidConfig
public
int
delete
(
Integer
enterpriseId
,
Integer
classify
)
{
return
tabDataActuallyPaidConfigMapper
.
delete
(
enterpriseId
,
classify
);
}
@Override
public
int
count
(
Integer
enterpriseId
,
Integer
classify
)
{
return
tabDataActuallyPaidConfigMapper
.
count
(
enterpriseId
,
classify
);
}
}
gic-platform-enterprise-service/src/main/java/com/gic/enterprise/service/outer/impl/DataConfigApiServiceImpl.java
View file @
9b584f87
...
...
@@ -97,6 +97,9 @@ public class DataConfigApiServiceImpl implements DataConfigApiService {
if
(
dto
.
getClassify
()
==
null
)
{
dto
.
setClassify
(
1
);
}
if
(
dataActuallyPaidConfigService
.
count
(
dto
.
getEnterpriseId
(),
dto
.
getClassify
())
>
0
)
{
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"已经配置过,不允许再次配置"
);
}
dataActuallyPaidConfigService
.
delete
(
dto
.
getEnterpriseId
(),
dto
.
getClassify
());
dto
.
setConfigStatus
(
Optional
.
ofNullable
(
dto
.
getConfigStatus
()).
orElse
(
0
));
dataActuallyPaidConfigService
.
saveActuallyPaidConfig
(
dto
);
...
...
@@ -136,6 +139,16 @@ public class DataConfigApiServiceImpl implements DataConfigApiService {
}
@Override
public
ServiceResponse
<
Boolean
>
hasConfigMemberBusiness
(
Integer
enterpriseId
)
{
return
ServiceResponse
.
success
(
dataActuallyPaidConfigService
.
count
(
enterpriseId
,
1
)
>
0
);
}
@Override
public
ServiceResponse
<
Boolean
>
hasConfigPerformanceCount
(
Integer
enterpriseId
)
{
return
ServiceResponse
.
success
(
dataActuallyPaidConfigService
.
count
(
enterpriseId
,
3
)
>
0
);
}
@Override
public
ServiceResponse
<
List
<
DataActuallyPaidConfigDTO
>>
listActuallyPaidConfig
(
Integer
enterpriseId
)
{
List
<
TabDataActuallyPaidConfig
>
list
=
dataActuallyPaidConfigService
.
listByEnterpriseId
(
enterpriseId
);
if
(
CollectionUtils
.
isEmpty
(
list
))
{
...
...
gic-platform-enterprise-service/src/main/resources/mapper/TabDataActuallyPaidConfigMapper.xml
View file @
9b584f87
...
...
@@ -130,4 +130,11 @@
and classify = #{classify}
and status = 1
</update>
<select
id=
"count"
resultType=
"int"
>
select count(1) from tab_data_actually_paid_config
where enterprise_id = #{enterpriseId}
and classify = #{classify}
and status = 0
</select>
</mapper>
\ No newline at end of file
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