Commit 7e2eb8e6c280fc7bb1a186f12f3d72cec71abec8
Merge branch 'dev' of http://git3.nong12.com/b2c/gateway into dev
Showing
45 changed files
with
567 additions
and
477 deletions
mobsite-getway-dao/pom.xml
@@ -11,7 +11,7 @@ | @@ -11,7 +11,7 @@ | ||
11 | </properties> | 11 | </properties> |
12 | <dependencies> | 12 | <dependencies> |
13 | <dependency> | 13 | <dependency> |
14 | - <groupId>com.diligrp.mobsite</groupId> | 14 | + <groupId>com.b2c.mobsite</groupId> |
15 | <artifactId>mobsite-getway-domain</artifactId> | 15 | <artifactId>mobsite-getway-domain</artifactId> |
16 | <version>0.0.1-SNAPSHOT</version> | 16 | <version>0.0.1-SNAPSHOT</version> |
17 | </dependency> | 17 | </dependency> |
mobsite-getway-domain/pom.xml
@@ -2,12 +2,14 @@ | @@ -2,12 +2,14 @@ | ||
2 | <project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" | 2 | <project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" |
3 | xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> | 3 | xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> |
4 | <modelVersion>4.0.0</modelVersion> | 4 | <modelVersion>4.0.0</modelVersion> |
5 | - <parent> | ||
6 | - <groupId>com.diligrp.mobsite</groupId> | ||
7 | - <artifactId>mobsite-getway</artifactId> | ||
8 | - <version>0.0.1-SNAPSHOT</version> | ||
9 | - </parent> | ||
10 | - <groupId>com.diligrp.mobsite</groupId> | 5 | + <!--<parent>--> |
6 | + <!--<groupId>com.diligrp.mobsite</groupId>--> | ||
7 | + <!--<artifactId>mobsite-getway</artifactId>--> | ||
8 | + <!--<version>0.0.1-SNAPSHOT</version>--> | ||
9 | + <!--</parent>--> | ||
10 | + | ||
11 | + | ||
12 | + <groupId>com.b2c.mobsite</groupId> | ||
11 | <artifactId>mobsite-getway-domain</artifactId> | 13 | <artifactId>mobsite-getway-domain</artifactId> |
12 | <version>0.0.1-SNAPSHOT</version> | 14 | <version>0.0.1-SNAPSHOT</version> |
13 | <name>mobsite-getway-domain</name> | 15 | <name>mobsite-getway-domain</name> |
@@ -15,12 +17,5 @@ | @@ -15,12 +17,5 @@ | ||
15 | <properties> | 17 | <properties> |
16 | <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> | 18 | <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> |
17 | </properties> | 19 | </properties> |
18 | - <dependencies> | ||
19 | - <dependency> | ||
20 | - <groupId>junit</groupId> | ||
21 | - <artifactId>junit</artifactId> | ||
22 | - <version>3.8.1</version> | ||
23 | - <scope>test</scope> | ||
24 | - </dependency> | ||
25 | - </dependencies> | 20 | + |
26 | </project> | 21 | </project> |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/common/RedisKey.java
@@ -22,6 +22,8 @@ public final class RedisKey { | @@ -22,6 +22,8 @@ public final class RedisKey { | ||
22 | public static final String USER_DEVICEID = ZDAPP_GETWAY+":USER:DEVICEID"; | 22 | public static final String USER_DEVICEID = ZDAPP_GETWAY+":USER:DEVICEID"; |
23 | public static final String USER_REGISTERNO = ZDAPP_GETWAY+":USER:REGISTERNO"; | 23 | public static final String USER_REGISTERNO = ZDAPP_GETWAY+":USER:REGISTERNO"; |
24 | 24 | ||
25 | + public static final String USER_SHOPID = ZDAPP_GETWAY+":USER:SHOPID"; | ||
26 | + | ||
25 | //门卫登录信息 | 27 | //门卫登录信息 |
26 | public static final String GUARD_LOGININFO = ZDAPP_GETWAY+":GUARD:LOGININFO"; | 28 | public static final String GUARD_LOGININFO = ZDAPP_GETWAY+":GUARD:LOGININFO"; |
27 | 29 |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/ConsigneeInfo.java renamed to mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/PickInfo.java
@@ -14,7 +14,7 @@ import java.io.Serializable; | @@ -14,7 +14,7 @@ import java.io.Serializable; | ||
14 | * @author wujianjun | 14 | * @author wujianjun |
15 | * @createTime 2014/8/28 10:37 | 15 | * @createTime 2014/8/28 10:37 |
16 | */ | 16 | */ |
17 | -public class ConsigneeInfo implements Serializable { | 17 | +public class PickInfo implements Serializable { |
18 | 18 | ||
19 | private static final long serialVersionUID = 8718494787385584082L; | 19 | private static final long serialVersionUID = 8718494787385584082L; |
20 | 20 |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/cart/ConfirmCartResp.java
@@ -3,7 +3,7 @@ package com.diligrp.mobsite.getway.domain.protocol.cart; | @@ -3,7 +3,7 @@ package com.diligrp.mobsite.getway.domain.protocol.cart; | ||
3 | import java.util.List; | 3 | import java.util.List; |
4 | 4 | ||
5 | import com.diligrp.mobsite.getway.domain.protocol.BaseResp; | 5 | import com.diligrp.mobsite.getway.domain.protocol.BaseResp; |
6 | -import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | 6 | +import com.diligrp.mobsite.getway.domain.protocol.PickInfo; |
7 | import com.diligrp.mobsite.getway.domain.protocol.cart.model.ConfirmCartShopInfo; | 7 | import com.diligrp.mobsite.getway.domain.protocol.cart.model.ConfirmCartShopInfo; |
8 | 8 | ||
9 | 9 | ||
@@ -21,7 +21,7 @@ public class ConfirmCartResp extends BaseResp { | @@ -21,7 +21,7 @@ public class ConfirmCartResp extends BaseResp { | ||
21 | /** | 21 | /** |
22 | * 提货人信息 | 22 | * 提货人信息 |
23 | */ | 23 | */ |
24 | - private ConsigneeInfo consigneeInfo; | 24 | + private PickInfo pickInfo; |
25 | 25 | ||
26 | /** | 26 | /** |
27 | * 购物单店铺信息 | 27 | * 购物单店铺信息 |
@@ -45,17 +45,17 @@ public class ConfirmCartResp extends BaseResp { | @@ -45,17 +45,17 @@ public class ConfirmCartResp extends BaseResp { | ||
45 | private Integer cartType; | 45 | private Integer cartType; |
46 | 46 | ||
47 | /** | 47 | /** |
48 | - * @return the consigneeInfo | 48 | + * @return the pickInfo |
49 | */ | 49 | */ |
50 | - public ConsigneeInfo getConsigneeInfo() { | ||
51 | - return consigneeInfo; | 50 | + public PickInfo getPickInfo() { |
51 | + return pickInfo; | ||
52 | } | 52 | } |
53 | 53 | ||
54 | /** | 54 | /** |
55 | - * @param consigneeInfo the consigneeInfo to set | 55 | + * @param pickInfo the pickInfo to set |
56 | */ | 56 | */ |
57 | - public void setConsigneeInfo(ConsigneeInfo consigneeInfo) { | ||
58 | - this.consigneeInfo = consigneeInfo; | 57 | + public void setPickInfo(PickInfo pickInfo) { |
58 | + this.pickInfo = pickInfo; | ||
59 | } | 59 | } |
60 | 60 | ||
61 | /** | 61 | /** |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/cart/DelConsigneeResp.java deleted
100644 → 0
1 | -package com.diligrp.mobsite.getway.domain.protocol.cart; | ||
2 | - | ||
3 | -import com.diligrp.mobsite.getway.domain.protocol.BaseResp; | ||
4 | - | ||
5 | -/** | ||
6 | - * <B>Description</B> 删除关注品类resp <br /> | ||
7 | - * <B>Copyright</B> Copyright (c) 2014 www.diligrp.com All rights reserved. <br /> | ||
8 | - * 本软件源代码版权归地利集团,未经许可不得任意复制与传播.<br /> | ||
9 | - * <B>Company</B> 地利集团 | ||
10 | - * | ||
11 | - * @author wujianjun | ||
12 | - * @createTime 2014/8/28 10:37 | ||
13 | - */ | ||
14 | -@SuppressWarnings("serial") | ||
15 | -public class DelConsigneeResp extends BaseResp { | ||
16 | -} |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/fund/GetFundsReq.java
@@ -11,6 +11,8 @@ public class GetFundsReq extends BaseReq { | @@ -11,6 +11,8 @@ public class GetFundsReq extends BaseReq { | ||
11 | private String keyword; | 11 | private String keyword; |
12 | @ApiModelProperty(value="店铺ID") | 12 | @ApiModelProperty(value="店铺ID") |
13 | private Long shopId; | 13 | private Long shopId; |
14 | + @ApiModelProperty(value = "页码") | ||
15 | + private Integer pageNum; | ||
14 | 16 | ||
15 | public String getKeyword() { | 17 | public String getKeyword() { |
16 | return keyword; | 18 | return keyword; |
@@ -27,4 +29,12 @@ public class GetFundsReq extends BaseReq { | @@ -27,4 +29,12 @@ public class GetFundsReq extends BaseReq { | ||
27 | public void setShopId(Long shopId) { | 29 | public void setShopId(Long shopId) { |
28 | this.shopId = shopId; | 30 | this.shopId = shopId; |
29 | } | 31 | } |
32 | + | ||
33 | + public Integer getPageNum() { | ||
34 | + return pageNum; | ||
35 | + } | ||
36 | + | ||
37 | + public void setPageNum(Integer pageNum) { | ||
38 | + this.pageNum = pageNum; | ||
39 | + } | ||
30 | } | 40 | } |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/order/model/ClaimsInfoVO.java
1 | package com.diligrp.mobsite.getway.domain.protocol.order.model; | 1 | package com.diligrp.mobsite.getway.domain.protocol.order.model; |
2 | 2 | ||
3 | -import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | 3 | +import com.diligrp.mobsite.getway.domain.protocol.PickInfo; |
4 | import com.diligrp.mobsite.getway.domain.protocol.OrderProduct; | 4 | import com.diligrp.mobsite.getway.domain.protocol.OrderProduct; |
5 | 5 | ||
6 | import java.util.Date; | 6 | import java.util.Date; |
@@ -114,7 +114,7 @@ public class ClaimsInfoVO { | @@ -114,7 +114,7 @@ public class ClaimsInfoVO { | ||
114 | /** | 114 | /** |
115 | * 提货人信息 | 115 | * 提货人信息 |
116 | */ | 116 | */ |
117 | - private ConsigneeInfo consigneeInfo; | 117 | + private PickInfo pickInfo; |
118 | /** | 118 | /** |
119 | * 提货时间 | 119 | * 提货时间 |
120 | */ | 120 | */ |
@@ -188,12 +188,12 @@ public class ClaimsInfoVO { | @@ -188,12 +188,12 @@ public class ClaimsInfoVO { | ||
188 | this.pickUserMsg = pickUserMsg; | 188 | this.pickUserMsg = pickUserMsg; |
189 | } | 189 | } |
190 | 190 | ||
191 | - public ConsigneeInfo getConsigneeInfo() { | ||
192 | - return consigneeInfo; | 191 | + public PickInfo getPickInfo() { |
192 | + return pickInfo; | ||
193 | } | 193 | } |
194 | 194 | ||
195 | - public void setConsigneeInfo(ConsigneeInfo consigneeInfo) { | ||
196 | - this.consigneeInfo = consigneeInfo; | 195 | + public void setPickInfo(PickInfo pickInfo) { |
196 | + this.pickInfo = pickInfo; | ||
197 | } | 197 | } |
198 | 198 | ||
199 | public String getPickDate() { | 199 | public String getPickDate() { |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/order/model/OrderDetail.java
1 | package com.diligrp.mobsite.getway.domain.protocol.order.model; | 1 | package com.diligrp.mobsite.getway.domain.protocol.order.model; |
2 | 2 | ||
3 | -import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | 3 | +import com.diligrp.mobsite.getway.domain.protocol.PickInfo; |
4 | import com.diligrp.mobsite.getway.domain.protocol.Order; | 4 | import com.diligrp.mobsite.getway.domain.protocol.Order; |
5 | import io.swagger.annotations.ApiModelProperty; | 5 | import io.swagger.annotations.ApiModelProperty; |
6 | 6 | ||
@@ -20,14 +20,14 @@ public class OrderDetail extends Order{ | @@ -20,14 +20,14 @@ public class OrderDetail extends Order{ | ||
20 | * 提货人信息 | 20 | * 提货人信息 |
21 | */ | 21 | */ |
22 | @ApiModelProperty(value = "收货人信息") | 22 | @ApiModelProperty(value = "收货人信息") |
23 | - private ConsigneeInfo consigneeInfo; | 23 | + private PickInfo pickInfo; |
24 | 24 | ||
25 | 25 | ||
26 | - public ConsigneeInfo getConsigneeInfo() { | ||
27 | - return consigneeInfo; | 26 | + public PickInfo getPickInfo() { |
27 | + return pickInfo; | ||
28 | } | 28 | } |
29 | 29 | ||
30 | - public void setConsigneeInfo(ConsigneeInfo consigneeInfo) { | ||
31 | - this.consigneeInfo = consigneeInfo; | 30 | + public void setPickInfo(PickInfo pickInfo) { |
31 | + this.pickInfo = pickInfo; | ||
32 | } | 32 | } |
33 | } | 33 | } |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/cart/AddConsigneeReq.java renamed to mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/pickinfo/AddPickInfoReq.java
1 | -package com.diligrp.mobsite.getway.domain.protocol.cart; | 1 | +package com.diligrp.mobsite.getway.domain.protocol.pickinfo; |
2 | 2 | ||
3 | import com.diligrp.mobsite.getway.domain.protocol.BaseReq; | 3 | import com.diligrp.mobsite.getway.domain.protocol.BaseReq; |
4 | -import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | 4 | +import com.diligrp.mobsite.getway.domain.protocol.PickInfo; |
5 | 5 | ||
6 | /** | 6 | /** |
7 | * <B>Description</B> 添加提货人请求 <br /> | 7 | * <B>Description</B> 添加提货人请求 <br /> |
@@ -13,15 +13,15 @@ import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | @@ -13,15 +13,15 @@ import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | ||
13 | * @createTime 2014/8/28 10:23 | 13 | * @createTime 2014/8/28 10:23 |
14 | */ | 14 | */ |
15 | @SuppressWarnings("serial") | 15 | @SuppressWarnings("serial") |
16 | -public class AddConsigneeReq extends BaseReq { | ||
17 | - private ConsigneeInfo consigneeInfo; | 16 | +public class AddPickInfoReq extends BaseReq { |
17 | + private PickInfo pickInfo; | ||
18 | 18 | ||
19 | - public ConsigneeInfo getConsigneeInfo() { | ||
20 | - return consigneeInfo; | 19 | + public PickInfo getPickInfo() { |
20 | + return pickInfo; | ||
21 | } | 21 | } |
22 | 22 | ||
23 | - public void setConsigneeInfo(ConsigneeInfo consigneeInfo) { | ||
24 | - this.consigneeInfo = consigneeInfo; | 23 | + public void setPickInfo(PickInfo pickInfo) { |
24 | + this.pickInfo = pickInfo; | ||
25 | } | 25 | } |
26 | 26 | ||
27 | } | 27 | } |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/cart/AddConsigneeResp.java renamed to mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/pickinfo/AddPickInfoResp.java
1 | -package com.diligrp.mobsite.getway.domain.protocol.cart; | 1 | +package com.diligrp.mobsite.getway.domain.protocol.pickinfo; |
2 | 2 | ||
3 | import com.diligrp.mobsite.getway.domain.protocol.BaseResp; | 3 | import com.diligrp.mobsite.getway.domain.protocol.BaseResp; |
4 | 4 | ||
@@ -12,7 +12,7 @@ import com.diligrp.mobsite.getway.domain.protocol.BaseResp; | @@ -12,7 +12,7 @@ import com.diligrp.mobsite.getway.domain.protocol.BaseResp; | ||
12 | * @createTime 2014/8/28 10:32 | 12 | * @createTime 2014/8/28 10:32 |
13 | */ | 13 | */ |
14 | @SuppressWarnings("serial") | 14 | @SuppressWarnings("serial") |
15 | -public class AddConsigneeResp extends BaseResp{ | 15 | +public class AddPickInfoResp extends BaseResp{ |
16 | private Long id; | 16 | private Long id; |
17 | 17 | ||
18 | public Long getId() { | 18 | public Long getId() { |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/cart/DelConsigneeReq.java renamed to mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/pickinfo/DelPickInfoReq.java
1 | -package com.diligrp.mobsite.getway.domain.protocol.cart; | 1 | +package com.diligrp.mobsite.getway.domain.protocol.pickinfo; |
2 | 2 | ||
3 | import com.diligrp.mobsite.getway.domain.protocol.BaseReq; | 3 | import com.diligrp.mobsite.getway.domain.protocol.BaseReq; |
4 | import io.swagger.annotations.ApiModelProperty; | 4 | import io.swagger.annotations.ApiModelProperty; |
@@ -13,16 +13,9 @@ import io.swagger.annotations.ApiModelProperty; | @@ -13,16 +13,9 @@ import io.swagger.annotations.ApiModelProperty; | ||
13 | * @createTime 2014/8/28 10:36 | 13 | * @createTime 2014/8/28 10:36 |
14 | */ | 14 | */ |
15 | @SuppressWarnings("serial") | 15 | @SuppressWarnings("serial") |
16 | -public class DelConsigneeReq extends BaseReq { | ||
17 | - /** | ||
18 | - * 提货人ID | ||
19 | - */ | ||
20 | - @ApiModelProperty(value = "收货人id",required = true) | 16 | +public class DelPickInfoReq extends BaseReq { |
17 | + @ApiModelProperty(value = "收货信息id",required = true) | ||
21 | private Long id; | 18 | private Long id; |
22 | - /** | ||
23 | - * 是否是默认 | ||
24 | - */ | ||
25 | - private Integer isDefault; | ||
26 | 19 | ||
27 | public Long getId() { | 20 | public Long getId() { |
28 | return id; | 21 | return id; |
@@ -31,12 +24,4 @@ public class DelConsigneeReq extends BaseReq { | @@ -31,12 +24,4 @@ public class DelConsigneeReq extends BaseReq { | ||
31 | public void setId(Long id) { | 24 | public void setId(Long id) { |
32 | this.id = id; | 25 | this.id = id; |
33 | } | 26 | } |
34 | - | ||
35 | - public Integer getIsDefault() { | ||
36 | - return isDefault; | ||
37 | - } | ||
38 | - | ||
39 | - public void setIsDefault(Integer isDefault) { | ||
40 | - this.isDefault = isDefault; | ||
41 | - } | ||
42 | } | 27 | } |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/pickinfo/DelPickInfoResp.java
0 → 100644
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/cart/GetDefaultConsigneeReq.java renamed to mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/pickinfo/GetDefaultPickInfoReq.java
1 | -package com.diligrp.mobsite.getway.domain.protocol.cart; | 1 | +package com.diligrp.mobsite.getway.domain.protocol.pickinfo; |
2 | 2 | ||
3 | import com.diligrp.mobsite.getway.domain.protocol.BaseReq; | 3 | import com.diligrp.mobsite.getway.domain.protocol.BaseReq; |
4 | 4 | ||
@@ -12,5 +12,5 @@ import com.diligrp.mobsite.getway.domain.protocol.BaseReq; | @@ -12,5 +12,5 @@ import com.diligrp.mobsite.getway.domain.protocol.BaseReq; | ||
12 | * @createTime 2014/8/28 10:38 | 12 | * @createTime 2014/8/28 10:38 |
13 | */ | 13 | */ |
14 | @SuppressWarnings("serial") | 14 | @SuppressWarnings("serial") |
15 | -public class GetDefaultConsigneeReq extends BaseReq{ | 15 | +public class GetDefaultPickInfoReq extends BaseReq{ |
16 | } | 16 | } |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/cart/GetDefaultConsigneeResp.java renamed to mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/pickinfo/GetDefaultPickInfoResp.java
1 | -package com.diligrp.mobsite.getway.domain.protocol.cart; | 1 | +package com.diligrp.mobsite.getway.domain.protocol.pickinfo; |
2 | 2 | ||
3 | import com.diligrp.mobsite.getway.domain.protocol.BaseResp; | 3 | import com.diligrp.mobsite.getway.domain.protocol.BaseResp; |
4 | -import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | 4 | +import com.diligrp.mobsite.getway.domain.protocol.PickInfo; |
5 | 5 | ||
6 | /** | 6 | /** |
7 | * <B>Description</B> 获取默认提货人 <br /> | 7 | * <B>Description</B> 获取默认提货人 <br /> |
@@ -13,17 +13,17 @@ import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | @@ -13,17 +13,17 @@ import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | ||
13 | * @createTime 2014/8/28 10:39 | 13 | * @createTime 2014/8/28 10:39 |
14 | */ | 14 | */ |
15 | @SuppressWarnings("serial") | 15 | @SuppressWarnings("serial") |
16 | -public class GetDefaultConsigneeResp extends BaseResp{ | 16 | +public class GetDefaultPickInfoResp extends BaseResp{ |
17 | /** | 17 | /** |
18 | * 提货人信息 | 18 | * 提货人信息 |
19 | */ | 19 | */ |
20 | - private ConsigneeInfo consigneeInfo; | 20 | + private PickInfo pickInfo; |
21 | 21 | ||
22 | - public ConsigneeInfo getConsigneeInfo() { | ||
23 | - return consigneeInfo; | 22 | + public PickInfo getPickingInfo() { |
23 | + return pickInfo; | ||
24 | } | 24 | } |
25 | 25 | ||
26 | - public void setConsigneeInfo(ConsigneeInfo consigneeInfo) { | ||
27 | - this.consigneeInfo = consigneeInfo; | 26 | + public void setPickingInfo(PickInfo pickInfo) { |
27 | + this.pickInfo = pickInfo; | ||
28 | } | 28 | } |
29 | } | 29 | } |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/cart/GetConsigneeListReq.java renamed to mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/pickinfo/GetPickInfoListReq.java
1 | -package com.diligrp.mobsite.getway.domain.protocol.cart; | 1 | +package com.diligrp.mobsite.getway.domain.protocol.pickinfo; |
2 | 2 | ||
3 | import com.diligrp.mobsite.getway.domain.protocol.BaseReq; | 3 | import com.diligrp.mobsite.getway.domain.protocol.BaseReq; |
4 | 4 | ||
@@ -12,5 +12,5 @@ import com.diligrp.mobsite.getway.domain.protocol.BaseReq; | @@ -12,5 +12,5 @@ import com.diligrp.mobsite.getway.domain.protocol.BaseReq; | ||
12 | * @createTime 2014/8/28 10:38 | 12 | * @createTime 2014/8/28 10:38 |
13 | */ | 13 | */ |
14 | @SuppressWarnings("serial") | 14 | @SuppressWarnings("serial") |
15 | -public class GetConsigneeListReq extends BaseReq { | 15 | +public class GetPickInfoListReq extends BaseReq { |
16 | } | 16 | } |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/cart/GetConsigneeListResp.java renamed to mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/pickinfo/GetPickInfoListResp.java
1 | -package com.diligrp.mobsite.getway.domain.protocol.cart; | ||
2 | - | ||
3 | -import java.util.List; | 1 | +package com.diligrp.mobsite.getway.domain.protocol.pickinfo; |
4 | 2 | ||
5 | import com.diligrp.mobsite.getway.domain.protocol.BaseResp; | 3 | import com.diligrp.mobsite.getway.domain.protocol.BaseResp; |
6 | -import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | 4 | +import com.diligrp.mobsite.getway.domain.protocol.PickInfo; |
5 | + | ||
6 | +import java.util.List; | ||
7 | 7 | ||
8 | /** | 8 | /** |
9 | * <B>Description</B> 获取提货人列表响应 <br /> | 9 | * <B>Description</B> 获取提货人列表响应 <br /> |
@@ -15,17 +15,10 @@ import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | @@ -15,17 +15,10 @@ import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | ||
15 | * @createTime 2014/8/28 10:38 | 15 | * @createTime 2014/8/28 10:38 |
16 | */ | 16 | */ |
17 | @SuppressWarnings("serial") | 17 | @SuppressWarnings("serial") |
18 | -public class GetConsigneeListResp extends BaseResp { | 18 | +public class GetPickInfoListResp extends BaseResp { |
19 | /** | 19 | /** |
20 | * 提货人信息列表 | 20 | * 提货人信息列表 |
21 | */ | 21 | */ |
22 | - private List<ConsigneeInfo> consigneeInfos; | ||
23 | - | ||
24 | - public List<ConsigneeInfo> getConsigneeInfos() { | ||
25 | - return consigneeInfos; | ||
26 | - } | 22 | + private List<PickInfo> pickInfos; |
27 | 23 | ||
28 | - public void setConsigneeInfos(List<ConsigneeInfo> consigneeInfos) { | ||
29 | - this.consigneeInfos = consigneeInfos; | ||
30 | - } | ||
31 | } | 24 | } |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/cart/GetConsigneeReq.java renamed to mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/pickinfo/GetPickInfoReq.java
1 | -package com.diligrp.mobsite.getway.domain.protocol.cart; | 1 | +package com.diligrp.mobsite.getway.domain.protocol.pickinfo; |
2 | 2 | ||
3 | import com.diligrp.mobsite.getway.domain.protocol.BaseReq; | 3 | import com.diligrp.mobsite.getway.domain.protocol.BaseReq; |
4 | import io.swagger.annotations.ApiModelProperty; | 4 | import io.swagger.annotations.ApiModelProperty; |
@@ -13,11 +13,8 @@ import io.swagger.annotations.ApiModelProperty; | @@ -13,11 +13,8 @@ import io.swagger.annotations.ApiModelProperty; | ||
13 | * @createTime 2014/8/28 10:36 | 13 | * @createTime 2014/8/28 10:36 |
14 | */ | 14 | */ |
15 | @SuppressWarnings("serial") | 15 | @SuppressWarnings("serial") |
16 | -public class GetConsigneeReq extends BaseReq { | ||
17 | - /** | ||
18 | - * 提货人ID | ||
19 | - */ | ||
20 | - @ApiModelProperty(value = "收货人id",required = true) | 16 | +public class GetPickInfoReq extends BaseReq { |
17 | + @ApiModelProperty(value = "收货人信息id",required = true) | ||
21 | private Long id; | 18 | private Long id; |
22 | 19 | ||
23 | public Long getId() { | 20 | public Long getId() { |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/cart/GetConsigneeResp.java renamed to mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/pickinfo/GetPickInfoResp.java
1 | -package com.diligrp.mobsite.getway.domain.protocol.cart; | 1 | +package com.diligrp.mobsite.getway.domain.protocol.pickinfo; |
2 | 2 | ||
3 | import com.diligrp.mobsite.getway.domain.protocol.BaseResp; | 3 | import com.diligrp.mobsite.getway.domain.protocol.BaseResp; |
4 | -import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | 4 | +import com.diligrp.mobsite.getway.domain.protocol.PickInfo; |
5 | 5 | ||
6 | /** | 6 | /** |
7 | * <B>Description</B> 获取单个提货人响应 <br /> | 7 | * <B>Description</B> 获取单个提货人响应 <br /> |
@@ -13,17 +13,17 @@ import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | @@ -13,17 +13,17 @@ import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | ||
13 | * @createTime 2014/8/28 10:36 | 13 | * @createTime 2014/8/28 10:36 |
14 | */ | 14 | */ |
15 | @SuppressWarnings("serial") | 15 | @SuppressWarnings("serial") |
16 | -public class GetConsigneeResp extends BaseResp { | 16 | +public class GetPickInfoResp extends BaseResp { |
17 | /** | 17 | /** |
18 | * 提货人信息 | 18 | * 提货人信息 |
19 | */ | 19 | */ |
20 | - private ConsigneeInfo consigneeInfo; | 20 | + private PickInfo pickingInfo; |
21 | 21 | ||
22 | - public ConsigneeInfo getConsigneeInfo() { | ||
23 | - return consigneeInfo; | 22 | + public PickInfo getPickingInfo() { |
23 | + return pickingInfo; | ||
24 | } | 24 | } |
25 | 25 | ||
26 | - public void setConsigneeInfo(ConsigneeInfo consigneeInfo) { | ||
27 | - this.consigneeInfo = consigneeInfo; | 26 | + public void setPickingInfo(PickInfo pickingInfo) { |
27 | + this.pickingInfo = pickingInfo; | ||
28 | } | 28 | } |
29 | } | 29 | } |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/cart/SetDefaultConsigneeReq.java renamed to mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/pickinfo/SetDefaultPickInfoReq.java
1 | -package com.diligrp.mobsite.getway.domain.protocol.cart; | 1 | +package com.diligrp.mobsite.getway.domain.protocol.pickinfo; |
2 | 2 | ||
3 | import com.diligrp.mobsite.getway.domain.protocol.BaseReq; | 3 | import com.diligrp.mobsite.getway.domain.protocol.BaseReq; |
4 | import io.swagger.annotations.ApiModelProperty; | 4 | import io.swagger.annotations.ApiModelProperty; |
@@ -13,7 +13,7 @@ import io.swagger.annotations.ApiModelProperty; | @@ -13,7 +13,7 @@ import io.swagger.annotations.ApiModelProperty; | ||
13 | * @createTime 2014/8/28 16:23 | 13 | * @createTime 2014/8/28 16:23 |
14 | */ | 14 | */ |
15 | @SuppressWarnings("serial") | 15 | @SuppressWarnings("serial") |
16 | -public class SetDefaultConsigneeReq extends BaseReq { | 16 | +public class SetDefaultPickInfoReq extends BaseReq { |
17 | /** | 17 | /** |
18 | * 提货人信息Id | 18 | * 提货人信息Id |
19 | */ | 19 | */ |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/cart/SetDefaultConsigneeResp.java renamed to mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/pickinfo/SetDefaultPickInfoResp.java
1 | -package com.diligrp.mobsite.getway.domain.protocol.cart; | 1 | +package com.diligrp.mobsite.getway.domain.protocol.pickinfo; |
2 | 2 | ||
3 | import com.diligrp.mobsite.getway.domain.protocol.BaseResp; | 3 | import com.diligrp.mobsite.getway.domain.protocol.BaseResp; |
4 | 4 | ||
@@ -12,5 +12,5 @@ import com.diligrp.mobsite.getway.domain.protocol.BaseResp; | @@ -12,5 +12,5 @@ import com.diligrp.mobsite.getway.domain.protocol.BaseResp; | ||
12 | * @createTime 2014/8/28 16:23 | 12 | * @createTime 2014/8/28 16:23 |
13 | */ | 13 | */ |
14 | @SuppressWarnings("serial") | 14 | @SuppressWarnings("serial") |
15 | -public class SetDefaultConsigneeResp extends BaseResp { | 15 | +public class SetDefaultPickInfoResp extends BaseResp { |
16 | } | 16 | } |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/cart/UpdateConsigneeReq.java renamed to mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/pickinfo/UpdatePickInfoReq.java
1 | -package com.diligrp.mobsite.getway.domain.protocol.cart; | 1 | +package com.diligrp.mobsite.getway.domain.protocol.pickinfo; |
2 | 2 | ||
3 | import com.diligrp.mobsite.getway.domain.protocol.BaseReq; | 3 | import com.diligrp.mobsite.getway.domain.protocol.BaseReq; |
4 | -import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | 4 | +import com.diligrp.mobsite.getway.domain.protocol.PickInfo; |
5 | 5 | ||
6 | /** | 6 | /** |
7 | * <B>Description</B> 修改提货人信息请求 <br /> | 7 | * <B>Description</B> 修改提货人信息请求 <br /> |
@@ -13,17 +13,17 @@ import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | @@ -13,17 +13,17 @@ import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | ||
13 | * @createTime 2014/8/28 10:35 | 13 | * @createTime 2014/8/28 10:35 |
14 | */ | 14 | */ |
15 | @SuppressWarnings("serial") | 15 | @SuppressWarnings("serial") |
16 | -public class UpdateConsigneeReq extends BaseReq{ | 16 | +public class UpdatePickInfoReq extends BaseReq{ |
17 | /** | 17 | /** |
18 | * 提货人信息 | 18 | * 提货人信息 |
19 | */ | 19 | */ |
20 | - private ConsigneeInfo consigneeInfo; | 20 | + private PickInfo pickInfo; |
21 | 21 | ||
22 | - public ConsigneeInfo getConsigneeInfo() { | ||
23 | - return consigneeInfo; | 22 | + public PickInfo getPickInfo() { |
23 | + return pickInfo; | ||
24 | } | 24 | } |
25 | 25 | ||
26 | - public void setConsigneeInfo(ConsigneeInfo consigneeInfo) { | ||
27 | - this.consigneeInfo = consigneeInfo; | 26 | + public void setPickInfo(PickInfo pickInfo) { |
27 | + this.pickInfo = pickInfo; | ||
28 | } | 28 | } |
29 | } | 29 | } |
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/cart/UpdateConsigneeResp.java renamed to mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/pickinfo/UpdatePickInfoResp.java
1 | -package com.diligrp.mobsite.getway.domain.protocol.cart; | 1 | +package com.diligrp.mobsite.getway.domain.protocol.pickinfo; |
2 | 2 | ||
3 | import com.diligrp.mobsite.getway.domain.protocol.BaseResp; | 3 | import com.diligrp.mobsite.getway.domain.protocol.BaseResp; |
4 | 4 | ||
@@ -12,5 +12,5 @@ import com.diligrp.mobsite.getway.domain.protocol.BaseResp; | @@ -12,5 +12,5 @@ import com.diligrp.mobsite.getway.domain.protocol.BaseResp; | ||
12 | * @createTime 2014/8/28 10:35 | 12 | * @createTime 2014/8/28 10:35 |
13 | */ | 13 | */ |
14 | @SuppressWarnings("serial") | 14 | @SuppressWarnings("serial") |
15 | -public class UpdateConsigneeResp extends BaseResp { | 15 | +public class UpdatePickInfoResp extends BaseResp { |
16 | } | 16 | } |
mobsite-getway-manager/pom.xml
@@ -25,7 +25,7 @@ | @@ -25,7 +25,7 @@ | ||
25 | <version>0.0.1-SNAPSHOT</version> | 25 | <version>0.0.1-SNAPSHOT</version> |
26 | </dependency> | 26 | </dependency> |
27 | <dependency> | 27 | <dependency> |
28 | - <groupId>com.diligrp.mobsite</groupId> | 28 | + <groupId>com.b2c.mobsite</groupId> |
29 | <artifactId>mobsite-getway-domain</artifactId> | 29 | <artifactId>mobsite-getway-domain</artifactId> |
30 | <version>0.0.1-SNAPSHOT</version> | 30 | <version>0.0.1-SNAPSHOT</version> |
31 | </dependency> | 31 | </dependency> |
mobsite-getway-rpc/pom.xml
@@ -17,7 +17,7 @@ | @@ -17,7 +17,7 @@ | ||
17 | </properties> | 17 | </properties> |
18 | <dependencies> | 18 | <dependencies> |
19 | <dependency> | 19 | <dependency> |
20 | - <groupId>com.diligrp.mobsite</groupId> | 20 | + <groupId>com.b2c.mobsite</groupId> |
21 | <artifactId>mobsite-getway-domain</artifactId> | 21 | <artifactId>mobsite-getway-domain</artifactId> |
22 | <version>0.0.1-SNAPSHOT</version> | 22 | <version>0.0.1-SNAPSHOT</version> |
23 | </dependency> | 23 | </dependency> |
mobsite-getway-rpc/src/main/java/com/diligrp/mobsite/getway/rpc/PickInfoRPC.java
0 → 100644
1 | +package com.diligrp.mobsite.getway.rpc; | ||
2 | + | ||
3 | +import com.b2c.myapp.common.api.pickingInfo.input.PickingInfoSaveInput; | ||
4 | +import com.b2c.myapp.common.api.pickingInfo.input.PickingInfoUpdateInput; | ||
5 | +import com.b2c.myapp.common.api.pickingInfo.output.PickingInfoOutput; | ||
6 | + | ||
7 | +import java.util.List; | ||
8 | + | ||
9 | +/** | ||
10 | + * Created by jiangchengyong on 2017/1/12. | ||
11 | + */ | ||
12 | +public interface PickInfoRPC { | ||
13 | + /** | ||
14 | + * 新增收货人 | ||
15 | + * @param pickingInfoSaveInput | ||
16 | + * @return | ||
17 | + */ | ||
18 | + Integer addPickingInfo(PickingInfoSaveInput pickingInfoSaveInput); | ||
19 | + | ||
20 | + | ||
21 | + /** | ||
22 | + * 修改收货人信息 | ||
23 | + * @param pickingInfoUpdateInput | ||
24 | + * @return | ||
25 | + */ | ||
26 | + Boolean modify(PickingInfoUpdateInput pickingInfoUpdateInput); | ||
27 | + | ||
28 | + /** | ||
29 | + * 按买家ID查询收货人 | ||
30 | + * @param buyerId | ||
31 | + * @return | ||
32 | + */ | ||
33 | + List<PickingInfoOutput> queryPickingInfosByBuyerId(Long buyerId); | ||
34 | + /** | ||
35 | + * @comment 根据买家id获取默认收货地址 | ||
36 | + * @param buyerId | ||
37 | + * @return PickInfoOutput | ||
38 | + * @author kelan | ||
39 | + * @time 2016/12/15 10:38 | ||
40 | + */ | ||
41 | + PickingInfoOutput getDefaultPickingInfoByBuyerId(Long buyerId); | ||
42 | + /** | ||
43 | + * @comment 删除收货地址(需要判断是否是默认地址) | ||
44 | + * @param id 收货地址id | ||
45 | + * @return Boolean | ||
46 | + * @author kelan | ||
47 | + * @time 2016/12/16 17:58 | ||
48 | + */ | ||
49 | + public Boolean delPickingInfoById(Long id); | ||
50 | +} |
mobsite-getway-rpc/src/main/java/com/diligrp/mobsite/getway/rpc/SellerRPC.java
@@ -2,7 +2,7 @@ package com.diligrp.mobsite.getway.rpc; | @@ -2,7 +2,7 @@ package com.diligrp.mobsite.getway.rpc; | ||
2 | 2 | ||
3 | import com.b2c.myapp.common.api.buyerInfo.output.BuyerInfoOutput; | 3 | import com.b2c.myapp.common.api.buyerInfo.output.BuyerInfoOutput; |
4 | import com.b2c.myapp.common.api.sellerInfo.output.SellerInfoOutput; | 4 | import com.b2c.myapp.common.api.sellerInfo.output.SellerInfoOutput; |
5 | -import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | 5 | +import com.diligrp.mobsite.getway.domain.protocol.PickInfo; |
6 | import com.diligrp.mobsite.getway.domain.protocol.cart.ModifyAmountReq; | 6 | import com.diligrp.mobsite.getway.domain.protocol.cart.ModifyAmountReq; |
7 | 7 | ||
8 | import java.util.List; | 8 | import java.util.List; |
@@ -54,17 +54,17 @@ public interface SellerRPC { | @@ -54,17 +54,17 @@ public interface SellerRPC { | ||
54 | */ | 54 | */ |
55 | boolean modifyPwd(String accountName, String newPassword); | 55 | boolean modifyPwd(String accountName, String newPassword); |
56 | 56 | ||
57 | - Long addConsignee(ConsigneeInfo consigneeInfo, Long userId); | 57 | + Long addConsignee(PickInfo pickInfo, Long userId); |
58 | 58 | ||
59 | - boolean updateConsignee(ConsigneeInfo consigneeInfo, Long userId); | 59 | + boolean updateConsignee(PickInfo pickInfo, Long userId); |
60 | 60 | ||
61 | - ConsigneeInfo getConsignee(Long id); | 61 | + PickInfo getConsignee(Long id); |
62 | 62 | ||
63 | boolean delConsignee(Long id); | 63 | boolean delConsignee(Long id); |
64 | 64 | ||
65 | - List<ConsigneeInfo> getConsigneeByUserId(Long userId); | 65 | + List<PickInfo> getConsigneeByUserId(Long userId); |
66 | 66 | ||
67 | - ConsigneeInfo getDefaultConsignee(Long userId); | 67 | + PickInfo getDefaultConsignee(Long userId); |
68 | 68 | ||
69 | boolean setDefaultConsignee(Long id, Long userId); | 69 | boolean setDefaultConsignee(Long id, Long userId); |
70 | 70 |
mobsite-getway-rpc/src/main/java/com/diligrp/mobsite/getway/rpc/UserRPC.java
@@ -2,7 +2,6 @@ package com.diligrp.mobsite.getway.rpc; | @@ -2,7 +2,6 @@ package com.diligrp.mobsite.getway.rpc; | ||
2 | 2 | ||
3 | import com.b2c.myapp.common.api.buyerInfo.output.BuyerInfoOutput; | 3 | import com.b2c.myapp.common.api.buyerInfo.output.BuyerInfoOutput; |
4 | import com.diligrp.mobsite.getway.domain.protocol.AddCartProduct; | 4 | import com.diligrp.mobsite.getway.domain.protocol.AddCartProduct; |
5 | -import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | ||
6 | import com.diligrp.mobsite.getway.domain.protocol.cart.ModifyAmountReq; | 5 | import com.diligrp.mobsite.getway.domain.protocol.cart.ModifyAmountReq; |
7 | 6 | ||
8 | import java.util.List; | 7 | import java.util.List; |
@@ -19,33 +18,6 @@ import java.util.List; | @@ -19,33 +18,6 @@ import java.util.List; | ||
19 | */ | 18 | */ |
20 | public interface UserRPC { | 19 | public interface UserRPC { |
21 | 20 | ||
22 | - /** | ||
23 | - * | ||
24 | - * @param id | ||
25 | - * @param userId | ||
26 | - * @param type :1-收藏商品,2-店铺收藏 | ||
27 | - * @return | ||
28 | - * @createTime 2015年6月9日 下午2:21:16 | ||
29 | - * @author zhangshirui | ||
30 | - */ | ||
31 | - boolean checkFavorites(Long id, Long userId, Integer type); | ||
32 | - | ||
33 | - /** | ||
34 | - * 收藏商品和店铺 | ||
35 | - * @param userId | ||
36 | - * @param type | ||
37 | - * @param id | ||
38 | - * @param type:1-收藏商品,2-店铺收藏 | ||
39 | - * @return | ||
40 | - * @createTime 2014年10月13日 上午11:45:22 | ||
41 | - * @author zhangshirui | ||
42 | - */ | ||
43 | - boolean addFavorite(Long userId, Long id, Integer type); | ||
44 | - | ||
45 | - boolean delFavorite(Long userId, Long id, Integer type); | ||
46 | - | ||
47 | - | ||
48 | - | ||
49 | boolean addShoppingCart(List<AddCartProduct> cartProducts, Long userId); | 21 | boolean addShoppingCart(List<AddCartProduct> cartProducts, Long userId); |
50 | 22 | ||
51 | /** | 23 | /** |
@@ -102,21 +74,6 @@ public interface UserRPC { | @@ -102,21 +74,6 @@ public interface UserRPC { | ||
102 | */ | 74 | */ |
103 | boolean modifyPwd(String accountName, String newPassword); | 75 | boolean modifyPwd(String accountName, String newPassword); |
104 | 76 | ||
105 | - Long addConsignee(ConsigneeInfo consigneeInfo, Long userId); | ||
106 | - | ||
107 | - boolean updateConsignee(ConsigneeInfo consigneeInfo, Long userId); | ||
108 | - | ||
109 | - ConsigneeInfo getConsignee(Long id); | ||
110 | - | ||
111 | - boolean delConsignee(Long id); | ||
112 | - | ||
113 | - List<ConsigneeInfo> getConsigneeByUserId(Long userId); | ||
114 | - | ||
115 | - ConsigneeInfo getDefaultConsignee(Long userId); | ||
116 | - | ||
117 | - boolean setDefaultConsignee(Long id, Long userId); | ||
118 | - | ||
119 | - | ||
120 | /** | 77 | /** |
121 | * 密码加密 | 78 | * 密码加密 |
122 | * @param pwd | 79 | * @param pwd |
mobsite-getway-rpc/src/main/java/com/diligrp/mobsite/getway/rpc/impl/PassportRPCImpl.java
@@ -71,7 +71,7 @@ public class PassportRPCImpl extends BaseServiceImpl implements PassportRPC { | @@ -71,7 +71,7 @@ public class PassportRPCImpl extends BaseServiceImpl implements PassportRPC { | ||
71 | log.error("调用passport用户验证接口失败",e); | 71 | log.error("调用passport用户验证接口失败",e); |
72 | throw new ServiceException(); | 72 | throw new ServiceException(); |
73 | } | 73 | } |
74 | - | 74 | + |
75 | SellerLoginResp resp = new SellerLoginResp(); | 75 | SellerLoginResp resp = new SellerLoginResp(); |
76 | JSONObject jsonBody = JSONObject.parseObject(output.getData()); | 76 | JSONObject jsonBody = JSONObject.parseObject(output.getData()); |
77 | int code = 0; | 77 | int code = 0; |
@@ -81,16 +81,16 @@ public class PassportRPCImpl extends BaseServiceImpl implements PassportRPC { | @@ -81,16 +81,16 @@ public class PassportRPCImpl extends BaseServiceImpl implements PassportRPC { | ||
81 | log.error("passport返回数据:msg={}",jsonBody); | 81 | log.error("passport返回数据:msg={}",jsonBody); |
82 | throw new ServiceException(ResultCode.BUSINESS_FAILED,"登录失败请重新登录"); | 82 | throw new ServiceException(ResultCode.BUSINESS_FAILED,"登录失败请重新登录"); |
83 | } | 83 | } |
84 | - | 84 | + |
85 | String msg = jsonBody.getString("msg"); | 85 | String msg = jsonBody.getString("msg"); |
86 | - | ||
87 | - if (code == PASSPORT_LOGIN_CODE_LOCKED || code == PASSPORT_LOGIN_CODE_ACCOUNT_NOT_EXIST | 86 | + |
87 | + if (code == PASSPORT_LOGIN_CODE_LOCKED || code == PASSPORT_LOGIN_CODE_ACCOUNT_NOT_EXIST | ||
88 | || code == PASSPORT_LOGIN_CODE_PASSWORD_WRONG) { | 88 | || code == PASSPORT_LOGIN_CODE_PASSWORD_WRONG) { |
89 | throw new ServiceException(code,msg); | 89 | throw new ServiceException(code,msg); |
90 | }else if (code != ResultCode.SUCCESS) { | 90 | }else if (code != ResultCode.SUCCESS) { |
91 | throw new ServiceException(ResultCode.BUSINESS_FAILED,msg); | 91 | throw new ServiceException(ResultCode.BUSINESS_FAILED,msg); |
92 | } | 92 | } |
93 | - | 93 | + |
94 | //resp.setToken(jsonBody.getString("token")); | 94 | //resp.setToken(jsonBody.getString("token")); |
95 | JSONObject jsonUser = jsonBody.getJSONObject("accountInfo"); | 95 | JSONObject jsonUser = jsonBody.getJSONObject("accountInfo"); |
96 | resp.setSellerId(jsonUser.getLong("accountId")); | 96 | resp.setSellerId(jsonUser.getLong("accountId")); |
@@ -106,6 +106,11 @@ public class PassportRPCImpl extends BaseServiceImpl implements PassportRPC { | @@ -106,6 +106,11 @@ public class PassportRPCImpl extends BaseServiceImpl implements PassportRPC { | ||
106 | String cookieRedisKey = redisUtil.makeKey(RedisKey.USER_LOGININFO, Constant.USER_ROLE_SELLER+String.valueOf(resp.getSellerId())); | 106 | String cookieRedisKey = redisUtil.makeKey(RedisKey.USER_LOGININFO, Constant.USER_ROLE_SELLER+String.valueOf(resp.getSellerId())); |
107 | redisUtil.setStringByExpire(cookieRedisKey, String.valueOf(resp.getSellerId()), loginExpireTime); | 107 | redisUtil.setStringByExpire(cookieRedisKey, String.valueOf(resp.getSellerId()), loginExpireTime); |
108 | 108 | ||
109 | + //缓存shopId | ||
110 | + String shopIdKey = redisUtil.makeKey(RedisKey.USER_SHOPID, Constant.USER_ROLE_SELLER+String.valueOf(resp.getSellerId())); | ||
111 | + redisUtil.setStringByExpire(shopIdKey, String.valueOf(resp.getShopId()), loginExpireTime); | ||
112 | + | ||
113 | + | ||
109 | //缓存设备id,userId作为key | 114 | //缓存设备id,userId作为key |
110 | if (!Validator.isNull(req.getDeviceId())) { | 115 | if (!Validator.isNull(req.getDeviceId())) { |
111 | String onlyOneLoginRedisKey = redisUtil.makeKey(RedisKey.USER_DEVICEID, Constant.USER_ROLE_SELLER+String.valueOf(resp.getSellerId())); | 116 | String onlyOneLoginRedisKey = redisUtil.makeKey(RedisKey.USER_DEVICEID, Constant.USER_ROLE_SELLER+String.valueOf(resp.getSellerId())); |
mobsite-getway-rpc/src/main/java/com/diligrp/mobsite/getway/rpc/impl/PickInfoRPCImpl.java
0 → 100644
1 | +package com.diligrp.mobsite.getway.rpc.impl; | ||
2 | + | ||
3 | +import com.b2c.myapp.common.api.pickingInfo.input.PickingInfoSaveInput; | ||
4 | +import com.b2c.myapp.common.api.pickingInfo.input.PickingInfoUpdateInput; | ||
5 | +import com.b2c.myapp.common.api.pickingInfo.output.PickingInfoOutput; | ||
6 | +import com.diligrp.mobsite.getway.rpc.PickInfoRPC; | ||
7 | + | ||
8 | +import java.util.List; | ||
9 | + | ||
10 | +/** | ||
11 | + * Created by jiangchengyong on 2017/1/12. | ||
12 | + */ | ||
13 | +public class PickInfoRPCImpl implements PickInfoRPC{ | ||
14 | + | ||
15 | + | ||
16 | + /** | ||
17 | + * 新增收货人 | ||
18 | + * | ||
19 | + * @param pickingInfoSaveInput | ||
20 | + * @return | ||
21 | + */ | ||
22 | + @Override | ||
23 | + public Integer addPickingInfo(PickingInfoSaveInput pickingInfoSaveInput) { | ||
24 | + return null; | ||
25 | + } | ||
26 | + | ||
27 | + /** | ||
28 | + * 修改收货人信息 | ||
29 | + * | ||
30 | + * @param pickingInfoUpdateInput | ||
31 | + * @return | ||
32 | + */ | ||
33 | + @Override | ||
34 | + public Boolean modify(PickingInfoUpdateInput pickingInfoUpdateInput) { | ||
35 | + return null; | ||
36 | + } | ||
37 | + | ||
38 | + /** | ||
39 | + * 按买家ID查询收货人 | ||
40 | + * | ||
41 | + * @param buyerId | ||
42 | + * @return | ||
43 | + */ | ||
44 | + @Override | ||
45 | + public List<PickingInfoOutput> queryPickingInfosByBuyerId(Long buyerId) { | ||
46 | + return null; | ||
47 | + } | ||
48 | + | ||
49 | + /** | ||
50 | + * @param buyerId | ||
51 | + * @return PickingInfoOutput | ||
52 | + * @comment 根据买家id获取默认收货地址 | ||
53 | + * @author kelan | ||
54 | + * @time 2016/12/15 10:38 | ||
55 | + */ | ||
56 | + @Override | ||
57 | + public PickingInfoOutput getDefaultPickingInfoByBuyerId(Long buyerId) { | ||
58 | + return null; | ||
59 | + } | ||
60 | + | ||
61 | + /** | ||
62 | + * @param id 收货地址id | ||
63 | + * @return Boolean | ||
64 | + * @comment 删除收货地址(需要判断是否是默认地址) | ||
65 | + * @author kelan | ||
66 | + * @time 2016/12/16 17:58 | ||
67 | + */ | ||
68 | + @Override | ||
69 | + public Boolean delPickingInfoById(Long id) { | ||
70 | + return null; | ||
71 | + } | ||
72 | +} |
mobsite-getway-rpc/src/main/java/com/diligrp/mobsite/getway/rpc/impl/SellerRPCImpl.java
@@ -7,7 +7,7 @@ import com.b2c.myapp.sdk.MyAppClient; | @@ -7,7 +7,7 @@ import com.b2c.myapp.sdk.MyAppClient; | ||
7 | import com.diligrp.mobsite.getway.domain.common.ErrorMessage; | 7 | import com.diligrp.mobsite.getway.domain.common.ErrorMessage; |
8 | import com.diligrp.mobsite.getway.domain.common.ResultCode; | 8 | import com.diligrp.mobsite.getway.domain.common.ResultCode; |
9 | import com.diligrp.mobsite.getway.domain.except.ServiceException; | 9 | import com.diligrp.mobsite.getway.domain.except.ServiceException; |
10 | -import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | 10 | +import com.diligrp.mobsite.getway.domain.protocol.PickInfo; |
11 | import com.diligrp.mobsite.getway.domain.protocol.cart.ModifyAmountReq; | 11 | import com.diligrp.mobsite.getway.domain.protocol.cart.ModifyAmountReq; |
12 | import com.diligrp.mobsite.getway.rpc.GoodsRPC; | 12 | import com.diligrp.mobsite.getway.rpc.GoodsRPC; |
13 | import com.diligrp.mobsite.getway.rpc.SellerRPC; | 13 | import com.diligrp.mobsite.getway.rpc.SellerRPC; |
@@ -84,17 +84,17 @@ public class SellerRPCImpl implements SellerRPC { | @@ -84,17 +84,17 @@ public class SellerRPCImpl implements SellerRPC { | ||
84 | } | 84 | } |
85 | 85 | ||
86 | @Override | 86 | @Override |
87 | - public Long addConsignee(ConsigneeInfo consigneeInfo, Long userId) { | 87 | + public Long addConsignee(PickInfo pickInfo, Long userId) { |
88 | return null; | 88 | return null; |
89 | } | 89 | } |
90 | 90 | ||
91 | @Override | 91 | @Override |
92 | - public boolean updateConsignee(ConsigneeInfo consigneeInfo, Long userId) { | 92 | + public boolean updateConsignee(PickInfo pickInfo, Long userId) { |
93 | return false; | 93 | return false; |
94 | } | 94 | } |
95 | 95 | ||
96 | @Override | 96 | @Override |
97 | - public ConsigneeInfo getConsignee(Long id) { | 97 | + public PickInfo getConsignee(Long id) { |
98 | return null; | 98 | return null; |
99 | } | 99 | } |
100 | 100 | ||
@@ -104,12 +104,12 @@ public class SellerRPCImpl implements SellerRPC { | @@ -104,12 +104,12 @@ public class SellerRPCImpl implements SellerRPC { | ||
104 | } | 104 | } |
105 | 105 | ||
106 | @Override | 106 | @Override |
107 | - public List<ConsigneeInfo> getConsigneeByUserId(Long userId) { | 107 | + public List<PickInfo> getConsigneeByUserId(Long userId) { |
108 | return null; | 108 | return null; |
109 | } | 109 | } |
110 | 110 | ||
111 | @Override | 111 | @Override |
112 | - public ConsigneeInfo getDefaultConsignee(Long userId) { | 112 | + public PickInfo getDefaultConsignee(Long userId) { |
113 | return null; | 113 | return null; |
114 | } | 114 | } |
115 | 115 |
mobsite-getway-rpc/src/main/java/com/diligrp/mobsite/getway/rpc/impl/UserRPCImpl.java
@@ -7,7 +7,6 @@ import com.diligrp.mobsite.getway.domain.common.ErrorMessage; | @@ -7,7 +7,6 @@ import com.diligrp.mobsite.getway.domain.common.ErrorMessage; | ||
7 | import com.diligrp.mobsite.getway.domain.common.ResultCode; | 7 | import com.diligrp.mobsite.getway.domain.common.ResultCode; |
8 | import com.diligrp.mobsite.getway.domain.except.ServiceException; | 8 | import com.diligrp.mobsite.getway.domain.except.ServiceException; |
9 | import com.diligrp.mobsite.getway.domain.protocol.AddCartProduct; | 9 | import com.diligrp.mobsite.getway.domain.protocol.AddCartProduct; |
10 | -import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | ||
11 | import com.diligrp.mobsite.getway.domain.protocol.cart.ModifyAmountReq; | 10 | import com.diligrp.mobsite.getway.domain.protocol.cart.ModifyAmountReq; |
12 | import com.diligrp.mobsite.getway.rpc.GoodsRPC; | 11 | import com.diligrp.mobsite.getway.rpc.GoodsRPC; |
13 | import com.diligrp.mobsite.getway.rpc.UserRPC; | 12 | import com.diligrp.mobsite.getway.rpc.UserRPC; |
@@ -38,7 +37,7 @@ public class UserRPCImpl implements UserRPC { | @@ -38,7 +37,7 @@ public class UserRPCImpl implements UserRPC { | ||
38 | @Resource | 37 | @Resource |
39 | private RedisUtil redisUtil; | 38 | private RedisUtil redisUtil; |
40 | @Resource | 39 | @Resource |
41 | - private MyAppClient userClient; | 40 | + private MyAppClient myAppClient; |
42 | @Resource | 41 | @Resource |
43 | private WebsiteClient websiteClient; | 42 | private WebsiteClient websiteClient; |
44 | @Resource | 43 | @Resource |
@@ -48,21 +47,6 @@ public class UserRPCImpl implements UserRPC { | @@ -48,21 +47,6 @@ public class UserRPCImpl implements UserRPC { | ||
48 | private static final Logger logger = LoggerFactory.getLogger(UserRPCImpl.class); | 47 | private static final Logger logger = LoggerFactory.getLogger(UserRPCImpl.class); |
49 | 48 | ||
50 | @Override | 49 | @Override |
51 | - public boolean checkFavorites(Long id, Long userId, Integer type) { | ||
52 | - return false; | ||
53 | - } | ||
54 | - | ||
55 | - @Override | ||
56 | - public boolean addFavorite(Long userId, Long id, Integer type) { | ||
57 | - return false; | ||
58 | - } | ||
59 | - | ||
60 | - @Override | ||
61 | - public boolean delFavorite(Long userId, Long id, Integer type) { | ||
62 | - return false; | ||
63 | - } | ||
64 | - | ||
65 | - @Override | ||
66 | public boolean addShoppingCart(List<AddCartProduct> cartProducts, Long userId) { | 50 | public boolean addShoppingCart(List<AddCartProduct> cartProducts, Long userId) { |
67 | return false; | 51 | return false; |
68 | } | 52 | } |
@@ -82,7 +66,7 @@ public class UserRPCImpl implements UserRPC { | @@ -82,7 +66,7 @@ public class UserRPCImpl implements UserRPC { | ||
82 | BaseOutput<BuyerInfoOutput> output = null; | 66 | BaseOutput<BuyerInfoOutput> output = null; |
83 | boolean flag = false; | 67 | boolean flag = false; |
84 | try { | 68 | try { |
85 | - output = userClient.getBuyerInfoService().getBuyerInfoByMobilePhone(mobile); | 69 | + output = myAppClient.getBuyerInfoService().getBuyerInfoByMobilePhone(mobile); |
86 | } catch (Exception e) { | 70 | } catch (Exception e) { |
87 | logger.error("检测电话号码接口挂掉:msg={}",e.getMessage()); | 71 | logger.error("检测电话号码接口挂掉:msg={}",e.getMessage()); |
88 | throw new ServiceException(); | 72 | throw new ServiceException(); |
@@ -112,41 +96,6 @@ public class UserRPCImpl implements UserRPC { | @@ -112,41 +96,6 @@ public class UserRPCImpl implements UserRPC { | ||
112 | } | 96 | } |
113 | 97 | ||
114 | @Override | 98 | @Override |
115 | - public Long addConsignee(ConsigneeInfo consigneeInfo, Long userId) { | ||
116 | - return null; | ||
117 | - } | ||
118 | - | ||
119 | - @Override | ||
120 | - public boolean updateConsignee(ConsigneeInfo consigneeInfo, Long userId) { | ||
121 | - return false; | ||
122 | - } | ||
123 | - | ||
124 | - @Override | ||
125 | - public ConsigneeInfo getConsignee(Long id) { | ||
126 | - return null; | ||
127 | - } | ||
128 | - | ||
129 | - @Override | ||
130 | - public boolean delConsignee(Long id) { | ||
131 | - return false; | ||
132 | - } | ||
133 | - | ||
134 | - @Override | ||
135 | - public List<ConsigneeInfo> getConsigneeByUserId(Long userId) { | ||
136 | - return null; | ||
137 | - } | ||
138 | - | ||
139 | - @Override | ||
140 | - public ConsigneeInfo getDefaultConsignee(Long userId) { | ||
141 | - return null; | ||
142 | - } | ||
143 | - | ||
144 | - @Override | ||
145 | - public boolean setDefaultConsignee(Long id, Long userId) { | ||
146 | - return false; | ||
147 | - } | ||
148 | - | ||
149 | - @Override | ||
150 | public String getEncryptPwd(String pwd) { | 99 | public String getEncryptPwd(String pwd) { |
151 | return null; | 100 | return null; |
152 | } | 101 | } |
@@ -161,7 +110,7 @@ public class UserRPCImpl implements UserRPC { | @@ -161,7 +110,7 @@ public class UserRPCImpl implements UserRPC { | ||
161 | BaseOutput<BuyerInfoOutput> output = null; | 110 | BaseOutput<BuyerInfoOutput> output = null; |
162 | boolean flag = false; | 111 | boolean flag = false; |
163 | try { | 112 | try { |
164 | - output = userClient.getBuyerInfoService().getBuyerInfoByMobilePhone(accountName); | 113 | + output = myAppClient.getBuyerInfoService().getBuyerInfoByMobilePhone(accountName); |
165 | } catch (Exception e) { | 114 | } catch (Exception e) { |
166 | logger.error("检测电话号码接口挂掉:msg={}",e.getMessage()); | 115 | logger.error("检测电话号码接口挂掉:msg={}",e.getMessage()); |
167 | throw new ServiceException(); | 116 | throw new ServiceException(); |
mobsite-getway-service/pom.xml
@@ -28,7 +28,7 @@ | @@ -28,7 +28,7 @@ | ||
28 | <version>0.0.1-SNAPSHOT</version> | 28 | <version>0.0.1-SNAPSHOT</version> |
29 | </dependency> | 29 | </dependency> |
30 | <dependency> | 30 | <dependency> |
31 | - <groupId>com.diligrp.mobsite</groupId> | 31 | + <groupId>com.b2c.mobsite</groupId> |
32 | <artifactId>mobsite-getway-domain</artifactId> | 32 | <artifactId>mobsite-getway-domain</artifactId> |
33 | <version>0.0.1-SNAPSHOT</version> | 33 | <version>0.0.1-SNAPSHOT</version> |
34 | </dependency> | 34 | </dependency> |
mobsite-getway-service/src/main/java/com/diligrp/mobsite/getway/service/buyer/pickinfo/PickInfoService.java
0 → 100644
1 | +package com.diligrp.mobsite.getway.service.buyer.pickinfo; | ||
2 | + | ||
3 | +import com.diligrp.mobsite.getway.domain.protocol.pickinfo.*; | ||
4 | + | ||
5 | +/** | ||
6 | + * Created by jiangchengyong on 2017/1/12. | ||
7 | + */ | ||
8 | +public interface PickInfoService { | ||
9 | + /** | ||
10 | + * 新增收货人 | ||
11 | + * @param req | ||
12 | + * @return | ||
13 | + */ | ||
14 | + AddPickInfoResp addPickInfo(AddPickInfoReq req); | ||
15 | + | ||
16 | + /** | ||
17 | + * 修改收货人信息 | ||
18 | + * @param req | ||
19 | + * @return | ||
20 | + */ | ||
21 | + UpdatePickInfoResp updatePickInfo(UpdatePickInfoReq req); | ||
22 | + | ||
23 | + /** | ||
24 | + * 获取单个收货人信息 | ||
25 | + * @param req | ||
26 | + * @return | ||
27 | + */ | ||
28 | + GetPickInfoResp getPickInfo(GetPickInfoReq req); | ||
29 | + | ||
30 | + | ||
31 | + /** | ||
32 | + * 按收货人信息ID删除收货人 | ||
33 | + * @param req | ||
34 | + * @return | ||
35 | + */ | ||
36 | + DelPickInfoResp delPickInfo(DelPickInfoReq req); | ||
37 | + | ||
38 | + /** | ||
39 | + * 按买家ID查询收货列表 | ||
40 | + * @param req | ||
41 | + * @return | ||
42 | + */ | ||
43 | + GetPickInfoListResp getPickInfoList(GetPickInfoListReq req); | ||
44 | + | ||
45 | + /** | ||
46 | + * @comment 根据买家id获取默认收货地址 | ||
47 | + * @param req | ||
48 | + * @return PickInfo | ||
49 | + * @author kelan | ||
50 | + * @time 2016/12/15 10:38 | ||
51 | + */ | ||
52 | + GetDefaultPickInfoResp getDefaultPickInfo(GetDefaultPickInfoReq req); | ||
53 | + | ||
54 | + /** | ||
55 | + * 设置默认 | ||
56 | + * @param consigneeId | ||
57 | + * @param userId | ||
58 | + * @return | ||
59 | + */ | ||
60 | + SetDefaultPickInfoResp setDefault(Long consigneeId,Long userId); | ||
61 | +} |
mobsite-getway-service/src/main/java/com/diligrp/mobsite/getway/service/buyer/pickinfo/impl/PickInfoServiceImpl.java
0 → 100644
1 | +package com.diligrp.mobsite.getway.service.buyer.pickinfo.impl; | ||
2 | + | ||
3 | +import com.diligrp.mobsite.getway.domain.protocol.pickinfo.*; | ||
4 | +import com.diligrp.mobsite.getway.service.buyer.pickinfo.PickInfoService; | ||
5 | +import org.springframework.stereotype.Service; | ||
6 | + | ||
7 | +/** | ||
8 | + * Created by jiangchengyong on 2017/1/12. | ||
9 | + */ | ||
10 | +@Service | ||
11 | +public class PickInfoServiceImpl implements PickInfoService{ | ||
12 | + /** | ||
13 | + * 新增收货人 | ||
14 | + * | ||
15 | + * @param req@return | ||
16 | + */ | ||
17 | + @Override | ||
18 | + public AddPickInfoResp addPickInfo(AddPickInfoReq req) { | ||
19 | + return null; | ||
20 | + } | ||
21 | + | ||
22 | + /** | ||
23 | + * 修改收货人信息 | ||
24 | + * | ||
25 | + * @param req | ||
26 | + * @return | ||
27 | + */ | ||
28 | + @Override | ||
29 | + public UpdatePickInfoResp updatePickInfo(UpdatePickInfoReq req) { | ||
30 | + return null; | ||
31 | + } | ||
32 | + | ||
33 | + /** | ||
34 | + * 获取单个收货人信息 | ||
35 | + * | ||
36 | + * @param req | ||
37 | + * @return | ||
38 | + */ | ||
39 | + @Override | ||
40 | + public GetPickInfoResp getPickInfo(GetPickInfoReq req) { | ||
41 | + return null; | ||
42 | + } | ||
43 | + | ||
44 | + /** | ||
45 | + * 按收货人信息ID删除收货人 | ||
46 | + * | ||
47 | + * @param req | ||
48 | + * @return | ||
49 | + */ | ||
50 | + @Override | ||
51 | + public DelPickInfoResp delPickInfo(DelPickInfoReq req) { | ||
52 | + return null; | ||
53 | + } | ||
54 | + | ||
55 | + /** | ||
56 | + * 按买家ID查询收货列表 | ||
57 | + * | ||
58 | + * @param req | ||
59 | + * @return | ||
60 | + */ | ||
61 | + @Override | ||
62 | + public GetPickInfoListResp getPickInfoList(GetPickInfoListReq req) { | ||
63 | + return null; | ||
64 | + } | ||
65 | + | ||
66 | + /** | ||
67 | + * @param req | ||
68 | + * @return PickInfo | ||
69 | + * @comment 根据买家id获取默认收货地址 | ||
70 | + * @author kelan | ||
71 | + * @time 2016/12/15 10:38 | ||
72 | + */ | ||
73 | + @Override | ||
74 | + public GetDefaultPickInfoResp getDefaultPickInfo(GetDefaultPickInfoReq req) { | ||
75 | + return null; | ||
76 | + } | ||
77 | + | ||
78 | + /** | ||
79 | + * 设置默认 | ||
80 | + * | ||
81 | + * @param consigneeId | ||
82 | + * @param userId | ||
83 | + * @return | ||
84 | + */ | ||
85 | + @Override | ||
86 | + public SetDefaultPickInfoResp setDefault(Long consigneeId, Long userId) { | ||
87 | + return null; | ||
88 | + } | ||
89 | +} |
mobsite-getway-service/src/main/java/com/diligrp/mobsite/getway/service/buyer/settle/ConsigneeService.java deleted
100644 → 0
1 | -package com.diligrp.mobsite.getway.service.buyer.settle; | ||
2 | - | ||
3 | -import com.diligrp.mobsite.getway.domain.protocol.cart.AddConsigneeReq; | ||
4 | -import com.diligrp.mobsite.getway.domain.protocol.cart.AddConsigneeResp; | ||
5 | -import com.diligrp.mobsite.getway.domain.protocol.cart.DelConsigneeReq; | ||
6 | -import com.diligrp.mobsite.getway.domain.protocol.cart.DelConsigneeResp; | ||
7 | -import com.diligrp.mobsite.getway.domain.protocol.cart.GetConsigneeListReq; | ||
8 | -import com.diligrp.mobsite.getway.domain.protocol.cart.GetConsigneeListResp; | ||
9 | -import com.diligrp.mobsite.getway.domain.protocol.cart.GetConsigneeReq; | ||
10 | -import com.diligrp.mobsite.getway.domain.protocol.cart.GetConsigneeResp; | ||
11 | -import com.diligrp.mobsite.getway.domain.protocol.cart.GetDefaultConsigneeReq; | ||
12 | -import com.diligrp.mobsite.getway.domain.protocol.cart.GetDefaultConsigneeResp; | ||
13 | -import com.diligrp.mobsite.getway.domain.protocol.cart.SetDefaultConsigneeResp; | ||
14 | -import com.diligrp.mobsite.getway.domain.protocol.cart.UpdateConsigneeReq; | ||
15 | -import com.diligrp.mobsite.getway.domain.protocol.cart.UpdateConsigneeResp; | ||
16 | - | ||
17 | -/** | ||
18 | - * <B>Description</B> 提货人接口 <br /> | ||
19 | - * <B>Copyright</B> Copyright (c) 2014 www.diligrp.com All rights reserved. <br /> | ||
20 | - * 本软件源代码版权归地利集团,未经许可不得任意复制与传播.<br /> | ||
21 | - * <B>Company</B> 地利集团 | ||
22 | - * | ||
23 | - * @author wujianjun | ||
24 | - * @createTime 2014/8/28 10:34 | ||
25 | - */ | ||
26 | -public interface ConsigneeService { | ||
27 | - AddConsigneeResp addConsignee(AddConsigneeReq req); | ||
28 | - | ||
29 | - UpdateConsigneeResp updateConsignee(UpdateConsigneeReq req); | ||
30 | - | ||
31 | - GetConsigneeResp getConsignee(GetConsigneeReq req); | ||
32 | - | ||
33 | - DelConsigneeResp delConsignee(DelConsigneeReq req); | ||
34 | - | ||
35 | - GetConsigneeListResp getConsigneeList(GetConsigneeListReq req); | ||
36 | - | ||
37 | - GetDefaultConsigneeResp getDefaultConsignee(GetDefaultConsigneeReq req); | ||
38 | - | ||
39 | - SetDefaultConsigneeResp setDefault(Long consigneeId,Long userId); | ||
40 | -} |
mobsite-getway-service/src/main/java/com/diligrp/mobsite/getway/service/buyer/settle/impl/ConsigneeServiceImpl.java deleted
100644 → 0
1 | -package com.diligrp.mobsite.getway.service.buyer.settle.impl; | ||
2 | - | ||
3 | -import com.diligrp.mobsite.getway.domain.common.ErrorMessage; | ||
4 | -import com.diligrp.mobsite.getway.domain.common.ResultCode; | ||
5 | -import com.diligrp.mobsite.getway.domain.except.ServiceException; | ||
6 | -import com.diligrp.mobsite.getway.domain.protocol.ConsigneeInfo; | ||
7 | -import com.diligrp.mobsite.getway.domain.protocol.cart.*; | ||
8 | -import com.diligrp.mobsite.getway.rpc.UserRPC; | ||
9 | -import com.diligrp.mobsite.getway.service.buyer.settle.ConsigneeService; | ||
10 | -import com.diligrp.website.util.security.Validator; | ||
11 | -import org.springframework.stereotype.Service; | ||
12 | - | ||
13 | -import javax.annotation.Resource; | ||
14 | -import java.util.List; | ||
15 | - | ||
16 | -/** | ||
17 | - * <B>Description</B> 提货人业务实现 <br /> | ||
18 | - * <B>Copyright</B> Copyright (c) 2014 www.diligrp.com All rights reserved. <br /> | ||
19 | - * 本软件源代码版权归地利集团,未经许可不得任意复制与传播.<br /> | ||
20 | - * <B>Company</B> 地利集团 | ||
21 | - * | ||
22 | - * @author wujianjun | ||
23 | - * @createTime 2014/8/28 14:33 | ||
24 | - */ | ||
25 | -@Service | ||
26 | -public class ConsigneeServiceImpl implements ConsigneeService { | ||
27 | - | ||
28 | - @Resource | ||
29 | - private UserRPC userRPC; | ||
30 | - | ||
31 | - @Override | ||
32 | - public AddConsigneeResp addConsignee(AddConsigneeReq req) { | ||
33 | - Long id = userRPC.addConsignee(req.getConsigneeInfo(), req.getUserId()); | ||
34 | - if(Validator.isNull(id)){ | ||
35 | - throw new RuntimeException("添加提货人信息失败"); | ||
36 | - } | ||
37 | - if (!Validator.isNull(req.getConsigneeInfo().getIsDefault()) && | ||
38 | - ConsigneeInfo.ISDEFAULT_YES == req.getConsigneeInfo().getIsDefault()) { | ||
39 | - setDefault(id,req.getUserId()); | ||
40 | - } | ||
41 | - AddConsigneeResp resp = new AddConsigneeResp(); | ||
42 | - resp.setId(id); | ||
43 | - return resp; | ||
44 | - } | ||
45 | - | ||
46 | - @Override | ||
47 | - public UpdateConsigneeResp updateConsignee(UpdateConsigneeReq req) { | ||
48 | - boolean result = userRPC.updateConsignee(req.getConsigneeInfo(), req.getUserId()); | ||
49 | - if(!result) { | ||
50 | - throw new RuntimeException("修改提货人信息失败!"); | ||
51 | - } | ||
52 | - return new UpdateConsigneeResp(); | ||
53 | - } | ||
54 | - | ||
55 | - @Override | ||
56 | - public GetConsigneeResp getConsignee(GetConsigneeReq req) { | ||
57 | - ConsigneeInfo info = userRPC.getConsignee(req.getId()); | ||
58 | - GetConsigneeResp resp = new GetConsigneeResp(); | ||
59 | - resp.setConsigneeInfo(info); | ||
60 | - return resp; | ||
61 | - } | ||
62 | - | ||
63 | - @Override | ||
64 | - public DelConsigneeResp delConsignee(DelConsigneeReq req) { | ||
65 | - boolean result = userRPC.delConsignee(req.getId()); | ||
66 | - if(!result) { | ||
67 | - throw new RuntimeException("删除提货人信息失败!"); | ||
68 | - } | ||
69 | - return new DelConsigneeResp(); | ||
70 | - } | ||
71 | - | ||
72 | - @Override | ||
73 | - public GetConsigneeListResp getConsigneeList(GetConsigneeListReq req) { | ||
74 | - List<ConsigneeInfo> consigneeInfos = | ||
75 | - userRPC.getConsigneeByUserId(req.getUserId()); | ||
76 | - GetConsigneeListResp resp = new GetConsigneeListResp(); | ||
77 | - resp.setConsigneeInfos(consigneeInfos); | ||
78 | - return resp; | ||
79 | - } | ||
80 | - | ||
81 | - @Override | ||
82 | - public GetDefaultConsigneeResp getDefaultConsignee(GetDefaultConsigneeReq req) { | ||
83 | - GetDefaultConsigneeResp resp = new GetDefaultConsigneeResp(); | ||
84 | - ConsigneeInfo info = userRPC.getDefaultConsignee(req.getUserId()); | ||
85 | - if (Validator.isNull(info)) { | ||
86 | - List<ConsigneeInfo> infoList = userRPC.getConsigneeByUserId(req.getUserId()); | ||
87 | - if (!Validator.isEmpty(infoList)) { | ||
88 | - info = infoList.get(0); | ||
89 | - } | ||
90 | - } | ||
91 | - resp.setConsigneeInfo(info); | ||
92 | - return resp; | ||
93 | - } | ||
94 | - | ||
95 | - @Override | ||
96 | - public SetDefaultConsigneeResp setDefault(Long consigneeId,Long userId) { | ||
97 | - boolean result = userRPC.setDefaultConsignee(consigneeId, userId); | ||
98 | - if(!result) { | ||
99 | - throw new ServiceException(ResultCode.USER_CONSIGNEE_SET_DEFAULT_FAILED,ErrorMessage.USER_CONSIGNEE_SET_DEFAULT_FAILED); | ||
100 | - } | ||
101 | - return new SetDefaultConsigneeResp(); | ||
102 | - } | ||
103 | -} |
mobsite-getway-service/src/main/java/com/diligrp/mobsite/getway/service/buyer/user/impl/OrderServiceImpl.java
@@ -9,6 +9,7 @@ import com.diligrp.website.web.interfaces.WebsiteClient; | @@ -9,6 +9,7 @@ import com.diligrp.website.web.interfaces.WebsiteClient; | ||
9 | import com.yqyw.filter.client.KeyWordsClient; | 9 | import com.yqyw.filter.client.KeyWordsClient; |
10 | import org.apache.log4j.Logger; | 10 | import org.apache.log4j.Logger; |
11 | import org.springframework.beans.factory.annotation.Autowired; | 11 | import org.springframework.beans.factory.annotation.Autowired; |
12 | +import org.springframework.stereotype.Service; | ||
12 | 13 | ||
13 | import javax.annotation.Resource; | 14 | import javax.annotation.Resource; |
14 | 15 | ||
@@ -22,7 +23,7 @@ import javax.annotation.Resource; | @@ -22,7 +23,7 @@ import javax.annotation.Resource; | ||
22 | * @author zhangshirui | 23 | * @author zhangshirui |
23 | * @createTime 2014年9月1日 下午5:34:45 | 24 | * @createTime 2014年9月1日 下午5:34:45 |
24 | */ | 25 | */ |
25 | -@org.springframework.stereotype.Service("orderService") | 26 | +@Service |
26 | public class OrderServiceImpl implements OrderService { | 27 | public class OrderServiceImpl implements OrderService { |
27 | 28 | ||
28 | @Resource | 29 | @Resource |
mobsite-getway-service/src/main/java/com/diligrp/mobsite/getway/service/buyer/user/impl/UserServiceImpl.java
@@ -72,7 +72,7 @@ public class UserServiceImpl implements UserService { | @@ -72,7 +72,7 @@ public class UserServiceImpl implements UserService { | ||
72 | 72 | ||
73 | if (!Validator.isEmpty(req.getRegisterNo())) { | 73 | if (!Validator.isEmpty(req.getRegisterNo())) { |
74 | // 缓存 | 74 | // 缓存 |
75 | - String redisKey = redisUtil.makeKey(RedisKey.USER_REGISTERNO, | 75 | + String redisKey = redisUtil.makeKey(RedisKey.USER_REGISTERNO,Constant.USER_ROLE_BUYER+ |
76 | String.valueOf(resp.getAccountId())); | 76 | String.valueOf(resp.getAccountId())); |
77 | 77 | ||
78 | GetRegisterNoResp mappers = redisUtil.getObject(redisKey, | 78 | GetRegisterNoResp mappers = redisUtil.getObject(redisKey, |
@@ -348,7 +348,31 @@ public class UserServiceImpl implements UserService { | @@ -348,7 +348,31 @@ public class UserServiceImpl implements UserService { | ||
348 | 348 | ||
349 | @Override | 349 | @Override |
350 | public LogoutResp logout(LogoutReq req) { | 350 | public LogoutResp logout(LogoutReq req) { |
351 | - return null; | 351 | + LogoutResp resp = new LogoutResp(); |
352 | + | ||
353 | + | ||
354 | + // 解除绑定极光ID | ||
355 | + if(!Validator.isEmpty(req.getRegisterNo())){ | ||
356 | + | ||
357 | + String userId = req.getUserId().toString(); | ||
358 | + //先清缓存再清数据库 | ||
359 | + String reNOCache = redisUtil.makeKey(RedisKey.USER_REGISTERNO, Constant.USER_ROLE_BUYER+userId); | ||
360 | + | ||
361 | + RegisterNoMapper mapper = new RegisterNoMapper(); | ||
362 | + mapper.setRegisterNo(req.getRegisterNo()); | ||
363 | + mapper.setSysFlag(RegisterNoMapper.SYS_FLAG_JPUSH); | ||
364 | + mapper.setUserid(req.getUserId()); | ||
365 | + mapper.setDeviceType(req.getDeviceType()); | ||
366 | + try { | ||
367 | + redisUtil.deleteByKey(reNOCache); | ||
368 | + registerNoMapperManager.unBindRegisterNo(mapper); | ||
369 | + } | ||
370 | + catch(Exception e) { | ||
371 | + logger.error("解除极光推送系统绑定的注册号失败",e); | ||
372 | + } | ||
373 | + } | ||
374 | + | ||
375 | + return resp; | ||
352 | } | 376 | } |
353 | 377 | ||
354 | @Override | 378 | @Override |
@@ -376,7 +400,7 @@ public class UserServiceImpl implements UserService { | @@ -376,7 +400,7 @@ public class UserServiceImpl implements UserService { | ||
376 | return resp; | 400 | return resp; |
377 | }else { | 401 | }else { |
378 | //修改成功,退出所有账号信息 | 402 | //修改成功,退出所有账号信息 |
379 | - String cookieRedisKey = redisUtil.makeKey(RedisKey.USER_LOGININFO, String.valueOf(userId)); | 403 | + String cookieRedisKey = redisUtil.makeKey(RedisKey.USER_LOGININFO, Constant.USER_ROLE_BUYER+String.valueOf(userId)); |
380 | redisUtil.deleteByKey(cookieRedisKey); | 404 | redisUtil.deleteByKey(cookieRedisKey); |
381 | } | 405 | } |
382 | 406 | ||
@@ -408,13 +432,13 @@ public class UserServiceImpl implements UserService { | @@ -408,13 +432,13 @@ public class UserServiceImpl implements UserService { | ||
408 | @Override | 432 | @Override |
409 | public GetRegisterNoResp getRegisterNo(GetRegisterNoReq req) { | 433 | public GetRegisterNoResp getRegisterNo(GetRegisterNoReq req) { |
410 | GetRegisterNoResp resp = new GetRegisterNoResp(); | 434 | GetRegisterNoResp resp = new GetRegisterNoResp(); |
411 | - if (Validator.isNull(req.getUserId())) { | 435 | + if (Validator.isNull(req.getUserId())||Validator.isNull(req.getUserRole())) { |
412 | resp.setCode(ResultCode.REQUET_PARAMS_ERROR); | 436 | resp.setCode(ResultCode.REQUET_PARAMS_ERROR); |
413 | - resp.setMsg("用户ID不能为空"); | 437 | + resp.setMsg("用户ID和用户角色不能为空"); |
414 | return resp; | 438 | return resp; |
415 | } | 439 | } |
416 | //先从缓存取 | 440 | //先从缓存取 |
417 | - String redisKey = redisUtil.makeKey(RedisKey.USER_REGISTERNO, String.valueOf(req.getUserId())); | 441 | + String redisKey = redisUtil.makeKey(RedisKey.USER_REGISTERNO, req.getUserRole()+String.valueOf(req.getUserId())); |
418 | GetRegisterNoResp recache = redisUtil.getObject(redisKey, GetRegisterNoResp.class); | 442 | GetRegisterNoResp recache = redisUtil.getObject(redisKey, GetRegisterNoResp.class); |
419 | if (!Validator.isNull(recache) && !Validator.isEmpty(recache.getRegisterNos())) { | 443 | if (!Validator.isNull(recache) && !Validator.isEmpty(recache.getRegisterNos())) { |
420 | resp.setRegisterNos(recache.getRegisterNos()); | 444 | resp.setRegisterNos(recache.getRegisterNos()); |
mobsite-getway-service/src/main/java/com/diligrp/mobsite/getway/service/seller/impl/FundServiceImpl.java
@@ -26,6 +26,7 @@ public class FundServiceImpl implements FundService{ | @@ -26,6 +26,7 @@ public class FundServiceImpl implements FundService{ | ||
26 | ShopBuyerDetail shopBuyerDetail = new ShopBuyerDetail(); | 26 | ShopBuyerDetail shopBuyerDetail = new ShopBuyerDetail(); |
27 | shopBuyerDetail.setShopId(fundsReq.getShopId()); | 27 | shopBuyerDetail.setShopId(fundsReq.getShopId()); |
28 | shopBuyerDetail.setBuyerMobilePhone(fundsReq.getKeyword()); | 28 | shopBuyerDetail.setBuyerMobilePhone(fundsReq.getKeyword()); |
29 | + shopBuyerDetail.setCurrentPage(fundsReq.getPageNum()); | ||
29 | Page<ShopBuyerDetailOutput> shopBuyerDetailOutputPage = shopBuyerRPC.queryShopAllBuyerList(shopBuyerDetail); | 30 | Page<ShopBuyerDetailOutput> shopBuyerDetailOutputPage = shopBuyerRPC.queryShopAllBuyerList(shopBuyerDetail); |
30 | ShopOutput shopOutput = shopRPC.getShopByShopId(fundsReq.getShopId()); | 31 | ShopOutput shopOutput = shopRPC.getShopByShopId(fundsReq.getShopId()); |
31 | 32 |
mobsite-getway-service/src/main/java/com/diligrp/mobsite/getway/service/seller/impl/SellerUserServiceImpl.java
@@ -74,7 +74,7 @@ public class SellerUserServiceImpl implements SellerUserService { | @@ -74,7 +74,7 @@ public class SellerUserServiceImpl implements SellerUserService { | ||
74 | 74 | ||
75 | if (!Validator.isEmpty(req.getRegisterNo())) { | 75 | if (!Validator.isEmpty(req.getRegisterNo())) { |
76 | // 缓存 | 76 | // 缓存 |
77 | - String redisKey = redisUtil.makeKey(RedisKey.USER_REGISTERNO,req.getUserRole()+ | 77 | + String redisKey = redisUtil.makeKey(RedisKey.USER_REGISTERNO,Constant.USER_ROLE_SELLER+ |
78 | String.valueOf(resp.getSellerId())); | 78 | String.valueOf(resp.getSellerId())); |
79 | 79 | ||
80 | GetRegisterNoResp mappers = redisUtil.getObject(redisKey, | 80 | GetRegisterNoResp mappers = redisUtil.getObject(redisKey, |
@@ -239,7 +239,7 @@ public class SellerUserServiceImpl implements SellerUserService { | @@ -239,7 +239,7 @@ public class SellerUserServiceImpl implements SellerUserService { | ||
239 | return resp; | 239 | return resp; |
240 | }else { | 240 | }else { |
241 | //修改成功,退出所有账号信息 | 241 | //修改成功,退出所有账号信息 |
242 | - String cookieRedisKey = redisUtil.makeKey(RedisKey.USER_LOGININFO, String.valueOf(userId)); | 242 | + String cookieRedisKey = redisUtil.makeKey(RedisKey.USER_LOGININFO, Constant.USER_ROLE_SELLER+String.valueOf(userId)); |
243 | redisUtil.deleteByKey(cookieRedisKey); | 243 | redisUtil.deleteByKey(cookieRedisKey); |
244 | } | 244 | } |
245 | 245 | ||
@@ -319,7 +319,31 @@ public class SellerUserServiceImpl implements SellerUserService { | @@ -319,7 +319,31 @@ public class SellerUserServiceImpl implements SellerUserService { | ||
319 | 319 | ||
320 | @Override | 320 | @Override |
321 | public LogoutResp logout(LogoutReq req) { | 321 | public LogoutResp logout(LogoutReq req) { |
322 | - return null; | 322 | + LogoutResp resp = new LogoutResp(); |
323 | + | ||
324 | + | ||
325 | + // 解除绑定极光ID | ||
326 | + if(!Validator.isEmpty(req.getRegisterNo())){ | ||
327 | + | ||
328 | + String userId = req.getUserId().toString(); | ||
329 | + //先清缓存再清数据库 | ||
330 | + String reNOCache = redisUtil.makeKey(RedisKey.USER_REGISTERNO, Constant.USER_ROLE_SELLER+userId); | ||
331 | + | ||
332 | + RegisterNoMapper mapper = new RegisterNoMapper(); | ||
333 | + mapper.setRegisterNo(req.getRegisterNo()); | ||
334 | + mapper.setSysFlag(RegisterNoMapper.SYS_FLAG_JPUSH); | ||
335 | + mapper.setUserid(req.getUserId()); | ||
336 | + mapper.setDeviceType(req.getDeviceType()); | ||
337 | + try { | ||
338 | + redisUtil.deleteByKey(reNOCache); | ||
339 | + registerNoMapperManager.unBindRegisterNo(mapper); | ||
340 | + } | ||
341 | + catch(Exception e) { | ||
342 | + logger.error("解除极光推送系统绑定的注册号失败",e); | ||
343 | + } | ||
344 | + } | ||
345 | + | ||
346 | + return resp; | ||
323 | } | 347 | } |
324 | 348 | ||
325 | @Override | 349 | @Override |
@@ -334,29 +358,29 @@ public class SellerUserServiceImpl implements SellerUserService { | @@ -334,29 +358,29 @@ public class SellerUserServiceImpl implements SellerUserService { | ||
334 | 358 | ||
335 | 359 | ||
336 | 360 | ||
337 | - public GetRegisterNoResp getRegisterNo(GetRegisterNoReq req) { | ||
338 | - GetRegisterNoResp resp = new GetRegisterNoResp(); | ||
339 | - if (Validator.isNull(req.getUserId())) { | ||
340 | - resp.setCode(ResultCode.REQUET_PARAMS_ERROR); | ||
341 | - resp.setMsg("用户ID不能为空"); | ||
342 | - return resp; | ||
343 | - } | ||
344 | - //先从缓存取 | ||
345 | - String redisKey = redisUtil.makeKey(RedisKey.USER_REGISTERNO, req.getUserRole()+String.valueOf(req.getUserId())); | ||
346 | - GetRegisterNoResp recache = redisUtil.getObject(redisKey, GetRegisterNoResp.class); | ||
347 | - if (!Validator.isNull(recache) && !Validator.isEmpty(recache.getRegisterNos())) { | ||
348 | - resp.setRegisterNos(recache.getRegisterNos()); | ||
349 | - }else { | ||
350 | - List<RegisterNoMapper> mapppers = registerNoMapperManager.getRegisterNo(req.getUserId()); | ||
351 | - if (!Validator.isEmpty(mapppers)) { | ||
352 | - | ||
353 | - resp.setRegisterNos(mapppers); | ||
354 | - redisUtil.setObjectByExpire(redisKey, resp, RedisKey.REGISTERNO_EXPIRE_TIME); | ||
355 | - }else { | ||
356 | - resp.setCode(ResultCode.BUSINESS_FAILED); | ||
357 | - resp.setMsg("该用户没有绑定极光号"); | ||
358 | - } | ||
359 | - } | ||
360 | - return resp; | ||
361 | - } | 361 | + //public GetRegisterNoResp getRegisterNo(GetRegisterNoReq req) { |
362 | + // GetRegisterNoResp resp = new GetRegisterNoResp(); | ||
363 | + // if (Validator.isNull(req.getUserId())||Validator.isNull(req.getUserRole())) { | ||
364 | + // resp.setCode(ResultCode.REQUET_PARAMS_ERROR); | ||
365 | + // resp.setMsg("用户ID和用户角色不能为空"); | ||
366 | + // return resp; | ||
367 | + // } | ||
368 | + // //先从缓存取 | ||
369 | + // String redisKey = redisUtil.makeKey(RedisKey.USER_REGISTERNO, req.getUserRole()+String.valueOf(req.getUserId())); | ||
370 | + // GetRegisterNoResp recache = redisUtil.getObject(redisKey, GetRegisterNoResp.class); | ||
371 | + // if (!Validator.isNull(recache) && !Validator.isEmpty(recache.getRegisterNos())) { | ||
372 | + // resp.setRegisterNos(recache.getRegisterNos()); | ||
373 | + // }else { | ||
374 | + // List<RegisterNoMapper> mapppers = registerNoMapperManager.getRegisterNo(req.getUserId()); | ||
375 | + // if (!Validator.isEmpty(mapppers)) { | ||
376 | + // | ||
377 | + // resp.setRegisterNos(mapppers); | ||
378 | + // redisUtil.setObjectByExpire(redisKey, resp, RedisKey.REGISTERNO_EXPIRE_TIME); | ||
379 | + // }else { | ||
380 | + // resp.setCode(ResultCode.BUSINESS_FAILED); | ||
381 | + // resp.setMsg("该用户没有绑定极光号"); | ||
382 | + // } | ||
383 | + // } | ||
384 | + // return resp; | ||
385 | + //} | ||
362 | } | 386 | } |
mobsite-getway-web/src/main/java/com/diligrp/mobsite/getway/web/api/buyer/home/ConsigneeController.java renamed to mobsite-getway-web/src/main/java/com/diligrp/mobsite/getway/web/api/buyer/home/PickInfoController.java
1 | package com.diligrp.mobsite.getway.web.api.buyer.home; | 1 | package com.diligrp.mobsite.getway.web.api.buyer.home; |
2 | 2 | ||
3 | import com.diligrp.mobsite.getway.domain.except.ServiceException; | 3 | import com.diligrp.mobsite.getway.domain.except.ServiceException; |
4 | -import com.diligrp.mobsite.getway.domain.protocol.cart.*; | ||
5 | -import com.diligrp.mobsite.getway.service.buyer.settle.ConsigneeService; | 4 | +import com.diligrp.mobsite.getway.domain.protocol.pickinfo.*; |
5 | +import com.diligrp.mobsite.getway.service.buyer.pickinfo.PickInfoService; | ||
6 | import com.diligrp.mobsite.getway.web.api.base.BaseApiController; | 6 | import com.diligrp.mobsite.getway.web.api.base.BaseApiController; |
7 | import io.swagger.annotations.Api; | 7 | import io.swagger.annotations.Api; |
8 | import io.swagger.annotations.ApiOperation; | 8 | import io.swagger.annotations.ApiOperation; |
9 | import org.slf4j.Logger; | 9 | import org.slf4j.Logger; |
10 | import org.slf4j.LoggerFactory; | 10 | import org.slf4j.LoggerFactory; |
11 | +import org.springframework.beans.factory.annotation.Autowired; | ||
11 | import org.springframework.stereotype.Controller; | 12 | import org.springframework.stereotype.Controller; |
12 | import org.springframework.web.bind.annotation.RequestBody; | 13 | import org.springframework.web.bind.annotation.RequestBody; |
13 | import org.springframework.web.bind.annotation.RequestMapping; | 14 | import org.springframework.web.bind.annotation.RequestMapping; |
@@ -26,24 +27,24 @@ import javax.annotation.Resource; | @@ -26,24 +27,24 @@ import javax.annotation.Resource; | ||
26 | * @createTime 2014/8/28 10:24 | 27 | * @createTime 2014/8/28 10:24 |
27 | */ | 28 | */ |
28 | @Controller | 29 | @Controller |
29 | -@RequestMapping("/mobsiteApp/consignee") | ||
30 | -@Api(value = "/mobsiteApp-consignee", description = "收货人接口") | ||
31 | -public class ConsigneeController extends BaseApiController { | 30 | +@RequestMapping("/mobsiteApp/pickInfo") |
31 | +@Api(value = "/mobsiteApp-pickInfo", description = "收货人接口") | ||
32 | +public class PickInfoController extends BaseApiController { | ||
32 | 33 | ||
33 | - @Resource | ||
34 | - private ConsigneeService consigneeService; | 34 | + @Autowired |
35 | + private PickInfoService pickInfoService; | ||
35 | private Logger log = LoggerFactory.getLogger(getClass()); | 36 | private Logger log = LoggerFactory.getLogger(getClass()); |
36 | 37 | ||
37 | /** | 38 | /** |
38 | * 获取默认提货人信息 | 39 | * 获取默认提货人信息 |
39 | */ | 40 | */ |
40 | - @ApiOperation(value = "获取默认提货人信息", httpMethod = "POST",response = GetDefaultConsigneeResp.class) | ||
41 | - @RequestMapping(value = "/getDefaultConsignee",method = RequestMethod.POST) | 41 | + @ApiOperation(value = "获取默认提货人信息", httpMethod = "POST",response = GetDefaultPickInfoResp.class) |
42 | + @RequestMapping(value = "/getDefaultPickInfo",method = RequestMethod.POST) | ||
42 | @ResponseBody | 43 | @ResponseBody |
43 | - public void getDefaultConsignee() { | ||
44 | - GetDefaultConsigneeReq req = getRequest(GetDefaultConsigneeReq.class); | 44 | + public void getDefaultPickInfo(@RequestBody GetDefaultPickInfoReq temp) { |
45 | + GetDefaultPickInfoReq req = getRequest(GetDefaultPickInfoReq.class); | ||
45 | try { | 46 | try { |
46 | - GetDefaultConsigneeResp resp = consigneeService.getDefaultConsignee(req); | 47 | + GetDefaultPickInfoResp resp = pickInfoService.getDefaultPickInfo(req); |
47 | sendSuccessResp(resp); | 48 | sendSuccessResp(resp); |
48 | } catch (ServiceException e){ | 49 | } catch (ServiceException e){ |
49 | log.error(String.format("Code=%s,ErrorMessage=%s,UserId=%s", e.getCode(), e.getMessage(), req.getUserId()), e); | 50 | log.error(String.format("Code=%s,ErrorMessage=%s,UserId=%s", e.getCode(), e.getMessage(), req.getUserId()), e); |
@@ -57,13 +58,13 @@ public class ConsigneeController extends BaseApiController { | @@ -57,13 +58,13 @@ public class ConsigneeController extends BaseApiController { | ||
57 | /** | 58 | /** |
58 | * 获取提货人信息列表 | 59 | * 获取提货人信息列表 |
59 | */ | 60 | */ |
60 | - @ApiOperation(value = "获取提货人信息列表", httpMethod = "POST",response = GetConsigneeListResp.class) | ||
61 | - @RequestMapping(value = "/getConsigneeList",method = RequestMethod.POST) | 61 | + @ApiOperation(value = "获取提货人信息列表", httpMethod = "POST",response = GetPickInfoListResp.class) |
62 | + @RequestMapping(value = "/getPickInfoList",method = RequestMethod.POST) | ||
62 | @ResponseBody | 63 | @ResponseBody |
63 | - public void getConsigneeList() { | ||
64 | - GetConsigneeListReq req = getRequest(GetConsigneeListReq.class); | 64 | + public void getPickInfoList(@RequestBody GetPickInfoListReq temp) { |
65 | + GetPickInfoListReq req = getRequest(GetPickInfoListReq.class); | ||
65 | try { | 66 | try { |
66 | - GetConsigneeListResp resp = consigneeService.getConsigneeList(req); | 67 | + GetPickInfoListResp resp = pickInfoService.getPickInfoList(req); |
67 | sendSuccessResp(resp); | 68 | sendSuccessResp(resp); |
68 | } catch (ServiceException e){ | 69 | } catch (ServiceException e){ |
69 | log.error(String.format("Code=%s,ErrorMessage=%s,UserId=%s", e.getCode(), e.getMessage(), req.getUserId()), e); | 70 | log.error(String.format("Code=%s,ErrorMessage=%s,UserId=%s", e.getCode(), e.getMessage(), req.getUserId()), e); |
@@ -77,13 +78,13 @@ public class ConsigneeController extends BaseApiController { | @@ -77,13 +78,13 @@ public class ConsigneeController extends BaseApiController { | ||
77 | /** | 78 | /** |
78 | * 删除提货人信息 | 79 | * 删除提货人信息 |
79 | */ | 80 | */ |
80 | - @ApiOperation(value = "删除收货人", httpMethod = "POST",response = DelConsigneeResp.class) | ||
81 | - @RequestMapping(value = "/delConsignee",method = RequestMethod.POST) | 81 | + @ApiOperation(value = "删除收货人", httpMethod = "POST",response = DelPickInfoResp.class) |
82 | + @RequestMapping(value = "/delPickInfo",method = RequestMethod.POST) | ||
82 | @ResponseBody | 83 | @ResponseBody |
83 | - public void delConsignee(@RequestBody DelConsigneeReq temp) { | ||
84 | - DelConsigneeReq req = getRequest(DelConsigneeReq.class); | 84 | + public void delPickInfo(@RequestBody DelPickInfoReq temp) { |
85 | + DelPickInfoReq req = getRequest(DelPickInfoReq.class); | ||
85 | try { | 86 | try { |
86 | - DelConsigneeResp resp = consigneeService.delConsignee(req); | 87 | + DelPickInfoResp resp = pickInfoService.delPickInfo(req); |
87 | sendSuccessResp(resp); | 88 | sendSuccessResp(resp); |
88 | } catch (ServiceException e){ | 89 | } catch (ServiceException e){ |
89 | log.error(String.format("Code=%s,ErrorMessage=%s,UserId=%s", e.getCode(), e.getMessage(), req.getUserId()), e); | 90 | log.error(String.format("Code=%s,ErrorMessage=%s,UserId=%s", e.getCode(), e.getMessage(), req.getUserId()), e); |
@@ -97,13 +98,13 @@ public class ConsigneeController extends BaseApiController { | @@ -97,13 +98,13 @@ public class ConsigneeController extends BaseApiController { | ||
97 | /** | 98 | /** |
98 | * 通过ID获取提货人详情 | 99 | * 通过ID获取提货人详情 |
99 | */ | 100 | */ |
100 | - @ApiOperation(value = "修改收货人", httpMethod = "POST",response = GetConsigneeResp.class) | ||
101 | - @RequestMapping(value = "/getConsignee",method = RequestMethod.POST) | 101 | + @ApiOperation(value = "修改收货人", httpMethod = "POST",response = GetPickInfoResp.class) |
102 | + @RequestMapping(value = "/getPickInfo",method = RequestMethod.POST) | ||
102 | @ResponseBody | 103 | @ResponseBody |
103 | - public void getConsignee(@RequestBody GetConsigneeReq temp) { | ||
104 | - GetConsigneeReq req = getRequest(GetConsigneeReq.class); | 104 | + public void getPickInfo(@RequestBody GetPickInfoReq temp) { |
105 | + GetPickInfoReq req = getRequest(GetPickInfoReq.class); | ||
105 | try { | 106 | try { |
106 | - GetConsigneeResp resp = consigneeService.getConsignee(req); | 107 | + GetPickInfoResp resp = pickInfoService.getPickInfo(req); |
107 | sendSuccessResp(resp); | 108 | sendSuccessResp(resp); |
108 | } catch (ServiceException e){ | 109 | } catch (ServiceException e){ |
109 | log.error(String.format("Code=%s,ErrorMessage=%s,UserId=%s", e.getCode(), e.getMessage(), req.getUserId()), e); | 110 | log.error(String.format("Code=%s,ErrorMessage=%s,UserId=%s", e.getCode(), e.getMessage(), req.getUserId()), e); |
@@ -117,13 +118,13 @@ public class ConsigneeController extends BaseApiController { | @@ -117,13 +118,13 @@ public class ConsigneeController extends BaseApiController { | ||
117 | /** | 118 | /** |
118 | * 修改提货人信息 | 119 | * 修改提货人信息 |
119 | */ | 120 | */ |
120 | - @ApiOperation(value = "修改收货人", httpMethod = "POST",response = UpdateConsigneeResp.class) | ||
121 | - @RequestMapping(value = "/updateConsignee",method = RequestMethod.POST) | 121 | + @ApiOperation(value = "修改收货人", httpMethod = "POST",response = UpdatePickInfoResp.class) |
122 | + @RequestMapping(value = "/updatePickInfo",method = RequestMethod.POST) | ||
122 | @ResponseBody | 123 | @ResponseBody |
123 | - public void updateConsignee(@RequestBody UpdateConsigneeReq temp) { | ||
124 | - UpdateConsigneeReq req = getRequest(UpdateConsigneeReq.class); | 124 | + public void updatePickInfo(@RequestBody UpdatePickInfoReq temp) { |
125 | + UpdatePickInfoReq req = getRequest(UpdatePickInfoReq.class); | ||
125 | try { | 126 | try { |
126 | - UpdateConsigneeResp resp = consigneeService.updateConsignee(req); | 127 | + UpdatePickInfoResp resp = pickInfoService.updatePickInfo(req); |
127 | sendSuccessResp(resp); | 128 | sendSuccessResp(resp); |
128 | } catch (ServiceException e){ | 129 | } catch (ServiceException e){ |
129 | log.error(String.format("Code=%s,ErrorMessage=%s,UserId=%s", e.getCode(), e.getMessage(), req.getUserId()), e); | 130 | log.error(String.format("Code=%s,ErrorMessage=%s,UserId=%s", e.getCode(), e.getMessage(), req.getUserId()), e); |
@@ -137,13 +138,13 @@ public class ConsigneeController extends BaseApiController { | @@ -137,13 +138,13 @@ public class ConsigneeController extends BaseApiController { | ||
137 | /** | 138 | /** |
138 | * 新增提货人 | 139 | * 新增提货人 |
139 | */ | 140 | */ |
140 | - @ApiOperation(value = "新增收货人", httpMethod = "POST",response = AddConsigneeResp.class) | ||
141 | - @RequestMapping(value = "/addConsignee",method = RequestMethod.POST) | 141 | + @ApiOperation(value = "新增收货人", httpMethod = "POST",response = AddPickInfoResp.class) |
142 | + @RequestMapping(value = "/addPickInfo",method = RequestMethod.POST) | ||
142 | @ResponseBody | 143 | @ResponseBody |
143 | - public void addConsignee(@RequestBody AddConsigneeReq temp) { | ||
144 | - AddConsigneeReq req = getRequest(AddConsigneeReq.class); | 144 | + public void addPickInfo(@RequestBody AddPickInfoReq temp) { |
145 | + AddPickInfoReq req = getRequest(AddPickInfoReq.class); | ||
145 | try { | 146 | try { |
146 | - AddConsigneeResp resp = consigneeService.addConsignee(req); | 147 | + AddPickInfoResp resp = pickInfoService.addPickInfo(req); |
147 | sendSuccessResp(resp); | 148 | sendSuccessResp(resp); |
148 | } catch (ServiceException e){ | 149 | } catch (ServiceException e){ |
149 | log.error(String.format("Code=%s,ErrorMessage=%s,UserId=%s", e.getCode(), e.getMessage(), req.getUserId()), e); | 150 | log.error(String.format("Code=%s,ErrorMessage=%s,UserId=%s", e.getCode(), e.getMessage(), req.getUserId()), e); |
@@ -157,13 +158,13 @@ public class ConsigneeController extends BaseApiController { | @@ -157,13 +158,13 @@ public class ConsigneeController extends BaseApiController { | ||
157 | /** | 158 | /** |
158 | * 设置默认提货人 | 159 | * 设置默认提货人 |
159 | */ | 160 | */ |
160 | - @ApiOperation(value = "设置默认收货人", httpMethod = "POST",response = SetDefaultConsigneeReq.class) | 161 | + @ApiOperation(value = "设置默认收货人", httpMethod = "POST",response = SetDefaultPickInfoReq.class) |
161 | @RequestMapping(value = "/setDefault",method = RequestMethod.POST) | 162 | @RequestMapping(value = "/setDefault",method = RequestMethod.POST) |
162 | @ResponseBody | 163 | @ResponseBody |
163 | - public void setDefault(@RequestBody SetDefaultConsigneeReq temp) { | ||
164 | - SetDefaultConsigneeReq req = getRequest(SetDefaultConsigneeReq.class); | 164 | + public void setDefault(@RequestBody SetDefaultPickInfoReq temp) { |
165 | + SetDefaultPickInfoReq req = getRequest(SetDefaultPickInfoReq.class); | ||
165 | try { | 166 | try { |
166 | - SetDefaultConsigneeResp resp = consigneeService.setDefault(req.getId(),req.getUserId()); | 167 | + SetDefaultPickInfoResp resp = pickInfoService.setDefault(req.getId(),req.getUserId()); |
167 | sendSuccessResp(resp); | 168 | sendSuccessResp(resp); |
168 | } catch (Exception e) { | 169 | } catch (Exception e) { |
169 | log.error(String.format("ErrorMessage=%s,UserId=%s",e.getMessage(),req.getUserId()), e); | 170 | log.error(String.format("ErrorMessage=%s,UserId=%s",e.getMessage(),req.getUserId()), e); |
mobsite-getway-web/src/main/java/com/diligrp/mobsite/getway/web/api/seller/fund/FundController.java
@@ -41,9 +41,10 @@ public class FundController extends BaseApiController{ | @@ -41,9 +41,10 @@ public class FundController extends BaseApiController{ | ||
41 | @ApiOperation(value = "获取储值列表", httpMethod = "POST",response = GetFundsResp.class) | 41 | @ApiOperation(value = "获取储值列表", httpMethod = "POST",response = GetFundsResp.class) |
42 | @RequestMapping(value = "/getFunds",method = RequestMethod.POST) | 42 | @RequestMapping(value = "/getFunds",method = RequestMethod.POST) |
43 | @ResponseBody | 43 | @ResponseBody |
44 | - public void getFunds(@ModelAttribute GetFundsReq fundsReq) { | 44 | + public void getFunds(@RequestBody GetFundsReq temp) { |
45 | + GetFundsReq req = super.getRequest(GetFundsReq.class); | ||
45 | try { | 46 | try { |
46 | - GetFundsResp resp = fundService.getFunds(fundsReq); | 47 | + GetFundsResp resp = fundService.getFunds(req); |
47 | super.sendSuccessResp(resp); | 48 | super.sendSuccessResp(resp); |
48 | } catch (ServiceException e) { | 49 | } catch (ServiceException e) { |
49 | log.error("获取储值列表出现业务异常", e); | 50 | log.error("获取储值列表出现业务异常", e); |
@@ -66,14 +67,12 @@ public class FundController extends BaseApiController{ | @@ -66,14 +67,12 @@ public class FundController extends BaseApiController{ | ||
66 | * @author weili | 67 | * @author weili |
67 | */ | 68 | */ |
68 | @ApiOperation(value = "储值卡操作", httpMethod = "POST",response = FundTradeResp.class) | 69 | @ApiOperation(value = "储值卡操作", httpMethod = "POST",response = FundTradeResp.class) |
69 | - @ApiImplicitParam(paramType = "query",name = "price",dataType = "Long", required = true, value = "储值金额") | ||
70 | @RequestMapping(value = "/storeValue",method = RequestMethod.POST) | 70 | @RequestMapping(value = "/storeValue",method = RequestMethod.POST) |
71 | @ResponseBody | 71 | @ResponseBody |
72 | - public void storeValue(Long price) { | ||
73 | - | 72 | + public void storeValue(@RequestBody FundTradeReq temp) { |
74 | FundTradeReq req = super.getRequest(FundTradeReq.class); | 73 | FundTradeReq req = super.getRequest(FundTradeReq.class); |
75 | try { | 74 | try { |
76 | - FundTradeResp resp = fundService.storeValue(price); | 75 | + FundTradeResp resp = fundService.storeValue(req.getTradePrice()); |
77 | super.sendSuccessResp(resp); | 76 | super.sendSuccessResp(resp); |
78 | } catch (ServiceException e) { | 77 | } catch (ServiceException e) { |
79 | log.error("获取储值列表出现业务异常", e); | 78 | log.error("获取储值列表出现业务异常", e); |
mobsite-getway-web/src/main/java/com/diligrp/mobsite/getway/web/api/seller/order/SellerOrderController.java
@@ -30,7 +30,6 @@ import javax.annotation.Resource; | @@ -30,7 +30,6 @@ import javax.annotation.Resource; | ||
30 | @RequestMapping("/mobsiteApp/seller/order") | 30 | @RequestMapping("/mobsiteApp/seller/order") |
31 | @Api(value = "/mobsiteApp-order-seller", description = "订单接口-卖家") | 31 | @Api(value = "/mobsiteApp-order-seller", description = "订单接口-卖家") |
32 | public class SellerOrderController extends BaseApiController { | 32 | public class SellerOrderController extends BaseApiController { |
33 | - | ||
34 | @Resource | 33 | @Resource |
35 | private SellerOrderService sellerOrderService; | 34 | private SellerOrderService sellerOrderService; |
36 | 35 |
mobsite-getway-web/src/main/resources/spring-web.xml
@@ -83,10 +83,36 @@ | @@ -83,10 +83,36 @@ | ||
83 | <mvc:exclude-mapping path="/mobsiteApp/user/checkAuthCode"/> | 83 | <mvc:exclude-mapping path="/mobsiteApp/user/checkAuthCode"/> |
84 | <mvc:exclude-mapping path="/mobsiteApp/user/buyerRegister"/> | 84 | <mvc:exclude-mapping path="/mobsiteApp/user/buyerRegister"/> |
85 | <mvc:exclude-mapping path="/mobsiteApp/user/buyerRegisters"/> | 85 | <mvc:exclude-mapping path="/mobsiteApp/user/buyerRegisters"/> |
86 | + <mvc:exclude-mapping path="/mobsiteApp/user/loginForAuth"/> | ||
86 | <mvc:exclude-mapping path="/mobsiteApp/user/logout"/> | 87 | <mvc:exclude-mapping path="/mobsiteApp/user/logout"/> |
87 | - <mvc:exclude-mapping path="/mobsiteApp/user/loginForAuth"/> | ||
88 | <mvc:exclude-mapping path="/mobsiteApp/user/modifyPwd"/> | 88 | <mvc:exclude-mapping path="/mobsiteApp/user/modifyPwd"/> |
89 | 89 | ||
90 | + <mvc:exclude-mapping path="/mobsiteApp/goods/getProductByCid"/> | ||
91 | + <mvc:exclude-mapping path="/mobsiteApp/goods/getProductCategory"/> | ||
92 | + <mvc:exclude-mapping path="/mobsiteApp/goods/getProductIntroduction"/> | ||
93 | + <mvc:exclude-mapping path="/mobsiteApp/goods/searchGoodList"/> | ||
94 | + <mvc:exclude-mapping path="/mobsiteApp/meal/getMealList"/> | ||
95 | + <mvc:exclude-mapping path="/mobsiteApp/meal/getMealById"/> | ||
96 | + <mvc:exclude-mapping path="/mobsiteApp/shop/getProductRecommend"/> | ||
97 | + <mvc:exclude-mapping path="/mobsiteApp/topic/getHomeStatisticsTopic"/> | ||
98 | + <mvc:exclude-mapping path="/mobsiteApp/topic/getPicInfo"/> | ||
99 | + <mvc:exclude-mapping path="/mobsiteApp/common/getAllCountryTree"/> | ||
100 | + <mvc:exclude-mapping path="/mobsiteApp/common/getCity"/> | ||
101 | + <mvc:exclude-mapping path="/mobsiteApp/common/getCitys"/> | ||
102 | + <mvc:exclude-mapping path="/mobsiteApp/common/getCountry"/> | ||
103 | + <mvc:exclude-mapping path="/mobsiteApp/common/uploadImg"/> | ||
104 | + | ||
105 | + <!--卖家--> | ||
106 | + | ||
107 | + <mvc:exclude-mapping path="/mobsiteApp/user/buyerLogin"/> | ||
108 | + <mvc:exclude-mapping path="/mobsiteApp/user/buyerLogins"/> | ||
109 | + <mvc:exclude-mapping path="/mobsiteApp/user/sendAuthCode"/> | ||
110 | + <mvc:exclude-mapping path="/mobsiteApp/user/checkAuthCode"/> | ||
111 | + <mvc:exclude-mapping path="/mobsiteApp/user/buyerRegister"/> | ||
112 | + <mvc:exclude-mapping path="/mobsiteApp/user/buyerRegisters"/> | ||
113 | + <mvc:exclude-mapping path="/mobsiteApp/user/loginForAuth"/> | ||
114 | + <mvc:exclude-mapping path="/mobsiteApp/user/logout"/> | ||
115 | + <mvc:exclude-mapping path="/mobsiteApp/user/modifyPwd"/> | ||
90 | <bean class="com.diligrp.mobsite.getway.web.filter.LoginTimeoutInterceptor"/> | 116 | <bean class="com.diligrp.mobsite.getway.web.filter.LoginTimeoutInterceptor"/> |
91 | </mvc:interceptor> | 117 | </mvc:interceptor> |
92 | <!-- <mvc:interceptor> | 118 | <!-- <mvc:interceptor> |