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
5c1df9e6
Commit
5c1df9e6
authored
Jun 17, 2020
by
guojuxing
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
提供删除微盟卡券绑定删除gic卡券接口
parent
735cfee1
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
48 additions
and
1 deletions
+48
-1
WmStoreApiService.java
...in/java/com/gic/enterprise/service/WmStoreApiService.java
+10
-0
TabWmStoreCouponConfigMapper.java
...c/enterprise/dao/mapper/TabWmStoreCouponConfigMapper.java
+4
-0
WmStoreCouponConfigService.java
...om/gic/enterprise/service/WmStoreCouponConfigService.java
+2
-0
WmStoreCouponConfigServiceImpl.java
...terprise/service/impl/WmStoreCouponConfigServiceImpl.java
+5
-0
WmStoreApiServiceImpl.java
.../enterprise/service/outer/impl/WmStoreApiServiceImpl.java
+16
-0
TabWmStoreCouponConfigMapper.xml
...rc/main/resources/mapper/TabWmStoreCouponConfigMapper.xml
+11
-1
No files found.
gic-platform-enterprise-api/src/main/java/com/gic/enterprise/service/WmStoreApiService.java
View file @
5c1df9e6
...
...
@@ -164,4 +164,14 @@ public interface WmStoreApiService {
* @return com.gic.api.base.commons.ServiceResponse<com.gic.api.base.commons.Page<com.gic.enterprise.dto.wm.WmStoreCouponConfigDTO>>
*/
ServiceResponse
<
Page
<
WmStoreCouponConfigDTO
>>
pageCouponConfig
(
CouponConfigQO
params
);
/**
* 卡券删除消息通知,gic卡券删除
* @Title: deleteWmGicCoupon
* @Description:
* @author guojuxing
* @param gicCouponId
* @return com.gic.api.base.commons.ServiceResponse<java.lang.Void>
*/
ServiceResponse
<
Void
>
deleteWmGicCoupon
(
Long
gicCouponId
);
}
gic-platform-enterprise-service/src/main/java/com/gic/enterprise/dao/mapper/TabWmStoreCouponConfigMapper.java
View file @
5c1df9e6
...
...
@@ -2,6 +2,7 @@ package com.gic.enterprise.dao.mapper;
import
com.gic.enterprise.entity.TabWmStoreCouponConfig
;
import
com.gic.enterprise.qo.wm.CouponConfigQO
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
...
...
@@ -55,4 +56,6 @@ public interface TabWmStoreCouponConfigMapper {
int
updateByPrimaryKey
(
TabWmStoreCouponConfig
record
);
List
<
TabWmStoreCouponConfig
>
getCouponConfig
(
CouponConfigQO
params
);
int
deleteWmGicCoupon
(
@Param
(
"gicCouponId"
)
String
gicCouponId
);
}
\ No newline at end of file
gic-platform-enterprise-service/src/main/java/com/gic/enterprise/service/WmStoreCouponConfigService.java
View file @
5c1df9e6
...
...
@@ -30,4 +30,6 @@ public interface WmStoreCouponConfigService {
List
<
TabWmStoreCouponConfig
>
getCouponConfig
(
CouponConfigQO
params
);
Page
<
TabWmStoreCouponConfig
>
pageCouponConfig
(
CouponConfigQO
params
);
int
deleteWmGicCoupon
(
String
gicCouponId
);
}
gic-platform-enterprise-service/src/main/java/com/gic/enterprise/service/impl/WmStoreCouponConfigServiceImpl.java
View file @
5c1df9e6
...
...
@@ -40,4 +40,9 @@ public class WmStoreCouponConfigServiceImpl implements WmStoreCouponConfigServic
List
<
TabWmStoreCouponConfig
>
list
=
tabWmStoreCouponConfigMapper
.
getCouponConfig
(
params
);
return
(
Page
<
TabWmStoreCouponConfig
>)
list
;
}
@Override
public
int
deleteWmGicCoupon
(
String
gicCouponId
)
{
return
tabWmStoreCouponConfigMapper
.
deleteWmGicCoupon
(
gicCouponId
);
}
}
gic-platform-enterprise-service/src/main/java/com/gic/enterprise/service/outer/impl/WmStoreApiServiceImpl.java
View file @
5c1df9e6
...
...
@@ -10,6 +10,8 @@ import com.gic.enterprise.service.*;
import
com.gic.weimob.api.service.WeimobMerchantService
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.commons.lang.StringUtils
;
import
org.apache.logging.log4j.LogManager
;
import
org.apache.logging.log4j.Logger
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
...
...
@@ -32,6 +34,7 @@ import com.gic.enterprise.qo.wm.CouponConfigQO;
@Service
(
"wmStoreApiService"
)
public
class
WmStoreApiServiceImpl
implements
WmStoreApiService
{
private
final
static
Logger
LOGGER
=
LogManager
.
getLogger
(
WmStoreApiServiceImpl
.
class
);
@Autowired
private
WmStoreService
wmStoreService
;
@Autowired
...
...
@@ -318,6 +321,19 @@ public class WmStoreApiServiceImpl implements WmStoreApiService {
return
ServiceResponse
.
success
(
resultPage
);
}
@Override
public
ServiceResponse
<
Void
>
deleteWmGicCoupon
(
Long
gicCouponId
)
{
LOGGER
.
info
(
"删除gic卡券参数:{}"
,
gicCouponId
);
if
(
gicCouponId
==
null
)
{
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"卡券ID为空"
);
}
int
count
=
wmStoreCouponConfigService
.
deleteWmGicCoupon
(
gicCouponId
.
toString
());
if
(
count
<
1
)
{
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"卡券ID有误,无数据删除"
);
}
return
ServiceResponse
.
success
();
}
private
ServiceResponse
validWmMemberCardConfig
(
WmMemberCardConfigDTO
dto
)
{
if
(
dto
.
getEnterpriseId
()
==
null
)
{
...
...
gic-platform-enterprise-service/src/main/resources/mapper/TabWmStoreCouponConfigMapper.xml
View file @
5c1df9e6
...
...
@@ -167,7 +167,7 @@
select
<include
refid=
"Base_Column_List"
></include>
from tab_wm_store_coupon_config
where
status
= 1
where
1
= 1
<if
test=
"wmMallStoreId != null and wmMallStoreId != '' "
>
and wm_mall_store_id = #{wmMallStoreId}
</if>
...
...
@@ -185,6 +185,7 @@
</if>
<if
test=
"onlyShowEffective != null and onlyShowEffective == 1"
>
and (gic_coupon_expire is null or TIMESTAMPDIFF(DAY, now(), gic_coupon_expire) >= 0)
and status = 1
</if>
<if
test=
"couponName != null and couponName != '' "
>
and (gic_coupon_name like concat('%', #{couponName}, '%') or wm_coupon_name like concat('%', #{couponName}, '%'))
...
...
@@ -196,4 +197,12 @@
order by create_time desc
</if>
</select>
<update
id=
"deleteWmGicCoupon"
>
update tab_wm_store_coupon_config set status = 0
where gic_coupon_id = #{gicCouponId}
and status = 1
</update>
</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