Răsfoiți Sursa

增加返回码

gaosheng 2 zile în urmă
părinte
comite
0c1dcc0df3

+ 4 - 0
xinkeaboard-server/b2b2c-core/src/main/java/com/slodon/b2b2c/core/constant/ResponseConst.java

@@ -16,6 +16,8 @@ public class ResponseConst {
      * 267 特殊情况
      * 268 分站关闭
      * 269 无推手信息
+     * 270 店铺装修筹备中
+     * 271 店铺暂停营业
      */
     public final static int STATE_SUCCESS = 200;
     public final static int STATE_FAIL = 255;
@@ -28,4 +30,6 @@ public class ResponseConst {
     public final static int STATE_SUBSITE_CLOSE = 268;
     public final static int STATE_NOT_SPREADER = 269;
     public final static int STATE_UNKNOWN_ERROR = 299;
+    public final static int STATE_STORE_BUSINESS_STATE_DECORATION = 270;
+    public final static int STATE_STORE_BUSINESS_STATE_CLOSE = 271;
 }

+ 3 - 1
xinkeaboard-server/b2b2c-core/src/main/resources/i18n_en.properties

@@ -1385,6 +1385,8 @@ bindIds格式错误,请重试=bindIds format error, please try again
 请选择店铺id=Please select a store id
 店铺已关闭=Shop Closed
 店铺已开启=Store is on
+店铺装修筹备中=Store is under preparation
+店铺暂停营业=Store is on pause
 请选择要删除的店铺id=Please select the store you want to delete id
 删除店铺成功=Delete shop success
 请填写审核拒绝原因=Please complete the review the reasons for rejection
@@ -2108,7 +2110,7 @@ IOS=
 发货地址=
 收货地址=
 审核已经提交,请等待管理员审核=
-您的审核已通过,请选择支付方式并缴纳费用=
+您的审核已通过=
 入驻成功=
 已拒绝=
 个人入驻=

+ 5 - 2
xinkeaboard-server/b2b2c-web/src/main/java/com/slodon/b2b2c/controller/seller/front/FrontStoreController.java

@@ -185,8 +185,11 @@ public class FrontStoreController {
         if (store.getState() != StoreConst.STORE_STATE_OPEN) {
             throw new MallException("店铺已关闭", ResponseConst.STATE_STORE_CLOSE);
         }
-        if (store.getBusinessState() != StoreConst.STORE_BUSINESS_STATE_OPEN) {
-            throw new MallException("店铺暂停营业", ResponseConst.STATE_FAIL);
+        if (store.getBusinessState() == StoreConst.STORE_BUSINESS_STATE_DECORATION) {
+            throw new MallException("店铺装修筹备中", ResponseConst.STATE_STORE_BUSINESS_STATE_DECORATION);
+        }
+        if (store.getBusinessState() == StoreConst.STORE_BUSINESS_STATE_CLOSE) {
+            throw new MallException("店铺暂停营业", ResponseConst.STATE_STORE_BUSINESS_STATE_CLOSE);
         }
         //默认店铺logo
         if (StringUtil.isEmpty(store.getStoreLogo())) {

+ 1 - 1
xinkeaboard-server/b2b2c-web/src/main/java/com/slodon/b2b2c/controller/seller/seller/SellerApplyController.java

@@ -166,7 +166,7 @@ public class SellerApplyController extends BaseController {
             if (storeApplyList.get(0).getState() == StoreConst.STATE_1_SEND_APPLY) {
                 vo.setStateValue("您的申请已提交,平台将在3个工作日内给出审核结果");
             } else {
-                vo.setStateValue("您的审核已通过,请选择支付方式并缴纳费用");
+                vo.setStateValue("您的审核已通过");
             }
         } else if (storeApplyList.get(0).getState() == StoreConst.STATE_3_FAIL_APPLY) {
             vo.setStateValue("您的店铺入驻审核未通过");

+ 8 - 3
xinkeaboard-server/b2b2c-web/src/main/java/com/slodon/b2b2c/controller/system/front/FrontPcDecoController.java

@@ -134,14 +134,19 @@ public class FrontPcDecoController {
                 storeDb.setState(state);
             }
         }
-        if (storeDb.getState().equals(StoreConst.STORE_STATE_CLOSE) ) {
+        if (storeDb.getState().equals(StoreConst.STORE_STATE_CLOSE)) {
             JsonResult jsonResult = SldResponse.fail("店铺已关闭");
             jsonResult.setState(ResponseConst.STATE_STORE_CLOSE);
             return jsonResult;
         }
-        if (!storeDb.getBusinessState().equals(StoreConst.STORE_BUSINESS_STATE_OPEN)){
+        if (storeDb.getBusinessState() == StoreConst.STORE_BUSINESS_STATE_DECORATION) {
+            JsonResult jsonResult = SldResponse.fail("店铺装修筹备中");
+            jsonResult.setState(ResponseConst.STATE_STORE_BUSINESS_STATE_DECORATION);
+            return jsonResult;
+        }
+        if (storeDb.getBusinessState() == StoreConst.STORE_BUSINESS_STATE_CLOSE) {
             JsonResult jsonResult = SldResponse.fail("店铺暂停经营");
-            jsonResult.setState(ResponseConst.STATE_FAIL);
+            jsonResult.setState(ResponseConst.STATE_STORE_BUSINESS_STATE_CLOSE);
             return jsonResult;
         }
         Map<String, Object> modelMap = new HashMap();

+ 13 - 13
xinkeaboard-server/b2b2c-web/src/main/java/com/slodon/b2b2c/model/seller/StoreApplyModel.java

@@ -434,12 +434,12 @@ public class StoreApplyModel {
         if (isPass) {
             newState = StoreConst.STATE_2_DONE_APPLY;
             //生成支付单号,计算支付金额
-            storeApply.setPaySn(GoodsIdGenerator.getPaySn());
-            //根据gradeId查询收费标准
-            StoreGrade storeGrade = storeGradeReadMapper.getByPrimaryKey(storeApply.getStoreGradeId());
-            storeApply.setPayAmount(new BigDecimal(storeGrade.getPrice()).multiply(new BigDecimal(storeApply.getApplyYear())));
-            storeApply.setPaymentCode(OrderPaymentConst.PAYMENT_CODE_ONLINE);
-            storeApply.setPaymentName(OrderPaymentConst.PAYMENT_NAME_ONLINE);
+//            storeApply.setPaySn(GoodsIdGenerator.getPaySn());
+//            //根据gradeId查询收费标准
+//            StoreGrade storeGrade = storeGradeReadMapper.getByPrimaryKey(storeApply.getStoreGradeId());
+//            storeApply.setPayAmount(new BigDecimal(storeGrade.getPrice()).multiply(new BigDecimal(storeApply.getApplyYear())));
+//            storeApply.setPaymentCode(OrderPaymentConst.PAYMENT_CODE_ONLINE);
+//            storeApply.setPaymentName(OrderPaymentConst.PAYMENT_NAME_ONLINE);
         } else {
             newState = StoreConst.STATE_3_FAIL_APPLY;
         }
@@ -608,13 +608,13 @@ public class StoreApplyModel {
         int newState;
         if (isPass) {
             newState = StoreConst.STATE_2_DONE_APPLY;
-            //生成支付单号,计算支付金额
-            storeApply.setPaySn(GoodsIdGenerator.getPaySn());
-            //根据gradeId查询收费标准
-            StoreGrade storeGrade = storeGradeReadMapper.getByPrimaryKey(storeApply.getStoreGradeId());
-            storeApply.setPayAmount(new BigDecimal(storeGrade.getPrice()).multiply(new BigDecimal(storeApply.getApplyYear())));
-            storeApply.setPaymentCode(OrderPaymentConst.PAYMENT_CODE_ONLINE);
-            storeApply.setPaymentName(OrderPaymentConst.PAYMENT_NAME_ONLINE);
+//            //生成支付单号,计算支付金额
+//            storeApply.setPaySn(GoodsIdGenerator.getPaySn());
+//            //根据gradeId查询收费标准
+//            StoreGrade storeGrade = storeGradeReadMapper.getByPrimaryKey(storeApply.getStoreGradeId());
+//            storeApply.setPayAmount(new BigDecimal(storeGrade.getPrice()).multiply(new BigDecimal(storeApply.getApplyYear())));
+//            storeApply.setPaymentCode(OrderPaymentConst.PAYMENT_CODE_ONLINE);
+//            storeApply.setPaymentName(OrderPaymentConst.PAYMENT_NAME_ONLINE);
         } else {
             newState = StoreConst.STATE_3_FAIL_APPLY;
         }