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
c3cfa705
Commit
c3cfa705
authored
Apr 24, 2020
by
guojuxing
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
微盟店铺调整
parent
f08238dd
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
264 additions
and
11 deletions
+264
-11
MallModeEnum.java
...c/main/java/com/gic/enterprise/constant/MallModeEnum.java
+1
-1
WmStoreConfigTypeEnum.java
...va/com/gic/enterprise/constant/WmStoreConfigTypeEnum.java
+1
-4
WmStoreDTO.java
...-api/src/main/java/com/gic/enterprise/dto/WmStoreDTO.java
+28
-0
TabWmStore.java
...e/src/main/java/com/gic/enterprise/entity/TabWmStore.java
+29
-0
WmStoreApiServiceImpl.java
.../enterprise/service/outer/impl/WmStoreApiServiceImpl.java
+15
-0
TabWmStoreMapper.xml
...se-service/src/main/resources/mapper/TabWmStoreMapper.xml
+27
-5
WmMallStoreController.java
...c/enterprise/web/controller/wm/WmMallStoreController.java
+2
-1
WmStoreDetailVO.java
...in/java/com/gic/enterprise/web/vo/wm/WmStoreDetailVO.java
+161
-0
No files found.
gic-platform-enterprise-api/src/main/java/com/gic/enterprise/constant/MallModeEnum.java
View file @
c3cfa705
...
...
@@ -9,7 +9,7 @@ package com.gic.enterprise.constant;
*/
public
enum
MallModeEnum
{
MICRO_MALL
(
1
,
"微商城模式"
),
SMART_RETAIL
(
1
,
"智慧零售模式"
),
SMART_RETAIL
(
2
,
"智慧零售模式"
),
;
private
int
code
;
...
...
gic-platform-enterprise-api/src/main/java/com/gic/enterprise/constant/WmStoreConfigTypeEnum.java
View file @
c3cfa705
...
...
@@ -11,10 +11,7 @@ public enum WmStoreConfigTypeEnum {
MEMBER_CARD_CONFIG
(
1
,
"会员卡配置"
),
COUPON_CONFIG
(
2
,
"卡券配置"
),
ORDER_CONFIG
(
3
,
"订单配置"
),
INTEGRAL_CONFIG
(
4
,
"积分配置"
),
GOODS_CONFIG
(
5
,
"商品配置"
),
APPLET_CONFIG
(
6
,
"小程序配置"
);
GOODS_CONFIG
(
4
,
"商品配置"
);
private
int
code
;
private
String
message
;
...
...
gic-platform-enterprise-api/src/main/java/com/gic/enterprise/dto/WmStoreDTO.java
View file @
c3cfa705
...
...
@@ -44,6 +44,16 @@ public class WmStoreDTO implements Serializable{
private
String
wmPidName
;
/**
* 会员小程序ID
*/
private
String
memberWechat
;
/**
* 微盟小程序APPID
*/
private
String
wmAppid
;
/**
* 商城模式 1:微商城模式 2:智慧零售模式
*/
private
Integer
mallMode
;
...
...
@@ -180,4 +190,22 @@ public class WmStoreDTO implements Serializable{
this
.
updateTime
=
updateTime
;
return
this
;
}
public
String
getMemberWechat
()
{
return
memberWechat
;
}
public
WmStoreDTO
setMemberWechat
(
String
memberWechat
)
{
this
.
memberWechat
=
memberWechat
;
return
this
;
}
public
String
getWmAppid
()
{
return
wmAppid
;
}
public
WmStoreDTO
setWmAppid
(
String
wmAppid
)
{
this
.
wmAppid
=
wmAppid
;
return
this
;
}
}
gic-platform-enterprise-service/src/main/java/com/gic/enterprise/entity/TabWmStore.java
View file @
c3cfa705
...
...
@@ -37,6 +37,16 @@ public class TabWmStore {
private
String
wmPidName
;
/**
* 会员小程序ID
*/
private
String
memberWechat
;
/**
* 微盟小程序APPID
*/
private
String
wmAppid
;
/**
* 商城模式 1:微商城模式 2:智慧零售模式
*/
private
Integer
mallMode
;
...
...
@@ -173,4 +183,22 @@ public class TabWmStore {
this
.
updateTime
=
updateTime
;
return
this
;
}
public
String
getMemberWechat
()
{
return
memberWechat
;
}
public
TabWmStore
setMemberWechat
(
String
memberWechat
)
{
this
.
memberWechat
=
memberWechat
;
return
this
;
}
public
String
getWmAppid
()
{
return
wmAppid
;
}
public
TabWmStore
setWmAppid
(
String
wmAppid
)
{
this
.
wmAppid
=
wmAppid
;
return
this
;
}
}
\ No newline at end of file
gic-platform-enterprise-service/src/main/java/com/gic/enterprise/service/outer/impl/WmStoreApiServiceImpl.java
View file @
c3cfa705
...
...
@@ -3,6 +3,7 @@ package com.gic.enterprise.service.outer.impl;
import
java.util.List
;
import
java.util.Optional
;
import
com.gic.commons.util.StringUtil
;
import
org.apache.commons.lang.StringUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
...
...
@@ -204,6 +205,20 @@ public class WmStoreApiServiceImpl implements WmStoreApiService {
if
(
isCanEdit
&&
record
.
getStoreBrandId
().
intValue
()
!=
storeBrandId
.
intValue
())
{
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"已授权,店招品牌不能修改"
);
}
String
wmAppid
=
wmStoreDTO
.
getWmAppid
();
if
(
StringUtil
.
isBlank
(
wmAppid
))
{
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"微盟小程序APPID不能为空"
);
}
if
(
isCanEdit
&&
!
record
.
getWmAppid
().
equals
(
wmAppid
))
{
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"已授权,微盟小程序APPID不能修改"
);
}
String
memberApplet
=
wmStoreDTO
.
getMemberWechat
();
if
(
StringUtil
.
isBlank
(
memberApplet
))
{
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"会员小程序不能为空"
);
}
if
(
isCanEdit
&&
!
record
.
getMemberWechat
().
equals
(
memberApplet
))
{
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"已授权,会员小程序不能修改"
);
}
return
ServiceResponse
.
success
();
}
}
gic-platform-enterprise-service/src/main/resources/mapper/TabWmStoreMapper.xml
View file @
c3cfa705
...
...
@@ -8,6 +8,8 @@
<result
column=
"wm_pid"
jdbcType=
"VARCHAR"
property=
"wmPid"
/>
<result
column=
"wm_store_id"
jdbcType=
"VARCHAR"
property=
"wmStoreId"
/>
<result
column=
"wm_pid_name"
jdbcType=
"VARCHAR"
property=
"wmPidName"
/>
<result
column=
"member_wechat"
jdbcType=
"VARCHAR"
property=
"memberWechat"
/>
<result
column=
"wm_appid"
jdbcType=
"VARCHAR"
property=
"wmAppid"
/>
<result
column=
"mall_mode"
jdbcType=
"INTEGER"
property=
"mallMode"
/>
<result
column=
"store_brand_id"
jdbcType=
"INTEGER"
property=
"storeBrandId"
/>
<result
column=
"auth_status"
jdbcType=
"INTEGER"
property=
"authStatus"
/>
...
...
@@ -16,7 +18,7 @@
<result
column=
"update_time"
jdbcType=
"TIMESTAMP"
property=
"updateTime"
/>
</resultMap>
<sql
id=
"Base_Column_List"
>
wm_mall_store_id, enterprise_id, wm_main_account, wm_pid, wm_store_id, wm_pid_name,
wm_mall_store_id, enterprise_id, wm_main_account, wm_pid, wm_store_id, wm_pid_name,
member_wechat, wm_appid,
mall_mode, store_brand_id, auth_status, status, create_time, update_time
</sql>
<select
id=
"selectByPrimaryKey"
parameterType=
"java.lang.Integer"
resultMap=
"BaseResultMap"
>
...
...
@@ -31,12 +33,12 @@
</delete>
<insert
id=
"insert"
parameterType=
"com.gic.enterprise.entity.TabWmStore"
useGeneratedKeys=
"true"
keyProperty=
"wmMallStoreId"
>
insert into tab_wm_store (wm_mall_store_id, enterprise_id, wm_main_account,
wm_pid, wm_store_id, wm_pid_name,
wm_pid, wm_store_id, wm_pid_name,
member_wechat, wm_appid,
mall_mode, store_brand_id, auth_status,
status, create_time, update_time
)
values (#{wmMallStoreId,jdbcType=INTEGER}, #{enterpriseId,jdbcType=INTEGER}, #{wmMainAccount,jdbcType=VARCHAR},
#{wmPid,jdbcType=VARCHAR}, #{wmStoreId,jdbcType=VARCHAR}, #{wmPidName,jdbcType=VARCHAR},
#{wmPid,jdbcType=VARCHAR}, #{wmStoreId,jdbcType=VARCHAR}, #{wmPidName,jdbcType=VARCHAR},
#{memberWechat,jdbcType=VARCHAR}, #{wmAppid,jdbcType=VARCHAR},
#{mallMode,jdbcType=INTEGER}, #{storeBrandId,jdbcType=INTEGER}, #{authStatus,jdbcType=INTEGER},
#{status,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}
)
...
...
@@ -62,6 +64,12 @@
<if
test=
"wmPidName != null"
>
wm_pid_name,
</if>
<if
test=
"memberWechat != null"
>
member_wechat,
</if>
<if
test=
"wmAppid != null"
>
wm_appid,
</if>
<if
test=
"mallMode != null"
>
mall_mode,
</if>
...
...
@@ -100,6 +108,12 @@
<if
test=
"wmPidName != null"
>
#{wmPidName,jdbcType=VARCHAR},
</if>
<if
test=
"memberWechat != null"
>
#{memberWechat,jdbcType=VARCHAR},
</if>
<if
test=
"wmAppid != null"
>
#{wmAppid,jdbcType=VARCHAR},
</if>
<if
test=
"mallMode != null"
>
#{mallMode,jdbcType=INTEGER},
</if>
...
...
@@ -138,6 +152,12 @@
<if
test=
"wmPidName != null"
>
wm_pid_name = #{wmPidName,jdbcType=VARCHAR},
</if>
<if
test=
"memberWechat != null"
>
member_wechat = #{memberWechat,jdbcType=VARCHAR},
</if>
<if
test=
"wmAppid != null"
>
wm_appid = #{wmAppid,jdbcType=VARCHAR},
</if>
<if
test=
"mallMode != null"
>
mall_mode = #{mallMode,jdbcType=INTEGER},
</if>
...
...
@@ -166,6 +186,8 @@
wm_pid = #{wmPid,jdbcType=VARCHAR},
wm_store_id = #{wmStoreId,jdbcType=VARCHAR},
wm_pid_name = #{wmPidName,jdbcType=VARCHAR},
member_wechat = #{memberWechat,jdbcType=VARCHAR},
wm_appid = #{wmAppid,jdbcType=VARCHAR},
mall_mode = #{mallMode,jdbcType=INTEGER},
store_brand_id = #{storeBrandId,jdbcType=INTEGER},
auth_status = #{authStatus,jdbcType=INTEGER},
...
...
@@ -186,8 +208,8 @@
<if
test=
"dataType == 2"
>
and wm_store_id = #{data}
</if>
<if
test=
"dataType ==
1
"
>
and wm_
main_account
= #{data}
<if
test=
"dataType ==
3
"
>
and wm_
pid
= #{data}
</if>
<if
test=
"wmMallStoreId != null"
>
and wm_mall_store_id
<>
#{wmMallStoreId}
...
...
gic-platform-enterprise-web/src/main/java/com/gic/enterprise/web/controller/wm/WmMallStoreController.java
View file @
c3cfa705
...
...
@@ -3,6 +3,7 @@ package com.gic.enterprise.web.controller.wm;
import
java.util.HashMap
;
import
java.util.Map
;
import
com.gic.enterprise.web.vo.wm.WmStoreDetailVO
;
import
org.apache.logging.log4j.LogManager
;
import
org.apache.logging.log4j.Logger
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
@@ -43,7 +44,7 @@ public class WmMallStoreController {
@RequestMapping
(
"/get-wm-store-detail"
)
public
RestResponse
getDetail
(
Integer
wmMallStoreId
)
{
return
ResultControllerUtils
.
commonResult
(
wmStoreApiService
.
getWmStoreByWmMallStoreId
(
wmMallStoreId
)
);
return
ResultControllerUtils
.
commonResult
One
(
wmStoreApiService
.
getWmStoreByWmMallStoreId
(
wmMallStoreId
),
WmStoreDetailVO
.
class
);
}
@RequestMapping
(
"/list-wm-store"
)
...
...
gic-platform-enterprise-web/src/main/java/com/gic/enterprise/web/vo/wm/WmStoreDetailVO.java
0 → 100644
View file @
c3cfa705
package
com
.
gic
.
enterprise
.
web
.
vo
.
wm
;
import
java.io.Serializable
;
public
class
WmStoreDetailVO
implements
Serializable
{
private
static
final
long
serialVersionUID
=
-
1783266568980086032L
;
/**
*
*/
private
Integer
wmMallStoreId
;
/**
*
*/
private
Integer
enterpriseId
;
/**
* 微盟主账号
*/
private
String
wmMainAccount
;
/**
* 微盟pid
*/
private
String
wmPid
;
/**
* 微盟store_id
*/
private
String
wmStoreId
;
/**
* 店铺名称
*/
private
String
wmPidName
;
/**
* 会员小程序ID
*/
private
String
memberWechat
;
/**
* 微盟小程序APPID
*/
private
String
wmAppid
;
/**
* 商城模式 1:微商城模式 2:智慧零售模式
*/
private
Integer
mallMode
;
/**
* 店招品牌
*/
private
Integer
storeBrandId
;
/**
* 授权状态 0:未授权 1:已授权
*/
private
Integer
authStatus
;
public
Integer
getWmMallStoreId
()
{
return
wmMallStoreId
;
}
public
WmStoreDetailVO
setWmMallStoreId
(
Integer
wmMallStoreId
)
{
this
.
wmMallStoreId
=
wmMallStoreId
;
return
this
;
}
public
Integer
getEnterpriseId
()
{
return
enterpriseId
;
}
public
WmStoreDetailVO
setEnterpriseId
(
Integer
enterpriseId
)
{
this
.
enterpriseId
=
enterpriseId
;
return
this
;
}
public
String
getWmMainAccount
()
{
return
wmMainAccount
;
}
public
WmStoreDetailVO
setWmMainAccount
(
String
wmMainAccount
)
{
this
.
wmMainAccount
=
wmMainAccount
;
return
this
;
}
public
String
getWmPid
()
{
return
wmPid
;
}
public
WmStoreDetailVO
setWmPid
(
String
wmPid
)
{
this
.
wmPid
=
wmPid
;
return
this
;
}
public
String
getWmStoreId
()
{
return
wmStoreId
;
}
public
WmStoreDetailVO
setWmStoreId
(
String
wmStoreId
)
{
this
.
wmStoreId
=
wmStoreId
;
return
this
;
}
public
String
getWmPidName
()
{
return
wmPidName
;
}
public
WmStoreDetailVO
setWmPidName
(
String
wmPidName
)
{
this
.
wmPidName
=
wmPidName
;
return
this
;
}
public
String
getMemberWechat
()
{
return
memberWechat
;
}
public
WmStoreDetailVO
setMemberWechat
(
String
memberWechat
)
{
this
.
memberWechat
=
memberWechat
;
return
this
;
}
public
String
getWmAppid
()
{
return
wmAppid
;
}
public
WmStoreDetailVO
setWmAppid
(
String
wmAppid
)
{
this
.
wmAppid
=
wmAppid
;
return
this
;
}
public
Integer
getMallMode
()
{
return
mallMode
;
}
public
WmStoreDetailVO
setMallMode
(
Integer
mallMode
)
{
this
.
mallMode
=
mallMode
;
return
this
;
}
public
Integer
getStoreBrandId
()
{
return
storeBrandId
;
}
public
WmStoreDetailVO
setStoreBrandId
(
Integer
storeBrandId
)
{
this
.
storeBrandId
=
storeBrandId
;
return
this
;
}
public
Integer
getAuthStatus
()
{
return
authStatus
;
}
public
WmStoreDetailVO
setAuthStatus
(
Integer
authStatus
)
{
this
.
authStatus
=
authStatus
;
return
this
;
}
}
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