Browse Source

Merge remote-tracking branch 'origin/developerF' into developerF

Aslee 3 years ago
parent
commit
48fef51a6d
36 changed files with 1731 additions and 1056 deletions
  1. 2 0
      src/main/java/com/caimei/modules/order/dao/CmReceiptOrderRelationDao.java
  2. 4 0
      src/main/java/com/caimei/modules/order/dao/CmReturnedPurchaseDao.java
  3. 12 0
      src/main/java/com/caimei/modules/order/entity/CmReceiptOrderRelation.java
  4. 1 2
      src/main/java/com/caimei/modules/order/entity/CmReturnedPurchase.java
  5. 2 2
      src/main/java/com/caimei/modules/order/entity/OnlineRefundData.java
  6. 134 84
      src/main/java/com/caimei/modules/order/service/CmReturnedPurchaseService.java
  7. 2 5
      src/main/java/com/caimei/modules/order/service/SplitAccountService.java
  8. 2 2
      src/main/java/com/caimei/modules/product/web/ProductNewController.java
  9. 2 0
      src/main/java/com/caimei/modules/user/dao/CmOperationsDao.java
  10. 9 0
      src/main/java/com/caimei/modules/user/entity/NewCmShop.java
  11. 9 0
      src/main/java/com/caimei/modules/user/entity/SplitCode.java
  12. 5 0
      src/main/java/com/caimei/modules/user/service/CmOperationalLogService.java
  13. 5 11
      src/main/java/com/caimei/modules/user/web/CmUserBalanceRecordController.java
  14. 326 17
      src/main/java/com/caimei/modules/user/web/NewCmShopController.java
  15. 18 7
      src/main/java/com/caimei/modules/user/web/newUser/AgencyController.java
  16. 25 3
      src/main/java/com/caimei/modules/user/web/newUser/SpController.java
  17. 1 1
      src/main/resources/mappings/modules/newhome/AnnouncementMapper.xml
  18. 21 1
      src/main/resources/mappings/modules/order/CmReceiptOrderRelationMapper.xml
  19. 8 1
      src/main/resources/mappings/modules/order/CmReturnedPurchaseMapper.xml
  20. 2 2
      src/main/resources/mappings/modules/order/OrderMapper.xml
  21. 10 4
      src/main/resources/mappings/modules/user/CmOperationalLogsMapper.xml
  22. 5 3
      src/main/resources/mappings/modules/user/NewCmShopMapper.xml
  23. 4 4
      src/main/resources/mappings/modules/user/OperationalLogsMapper.xml
  24. 44 23
      src/main/webapp/WEB-INF/views/modules/bulkpurchase/orderConfirmReturnRecord.jsp
  25. 13 13
      src/main/webapp/WEB-INF/views/modules/bulkpurchase/orderReturnRecord.jsp
  26. 15 15
      src/main/webapp/WEB-INF/views/modules/bulkpurchase/orderReviewReturnRecord.jsp
  27. 7 7
      src/main/webapp/WEB-INF/views/modules/bulkpurchase/organizeOrderReturnRecord.jsp
  28. 7 1
      src/main/webapp/WEB-INF/views/modules/product-new/productEdit.jsp
  29. 1 1
      src/main/webapp/WEB-INF/views/modules/product-new/productList.jsp
  30. 24 6
      src/main/webapp/WEB-INF/views/modules/user/cmNewProductShopEdit.jsp
  31. 4 4
      src/main/webapp/WEB-INF/views/modules/user/cmOperationalLogs.jsp
  32. 4 4
      src/main/webapp/WEB-INF/views/modules/user/cmOperationalLogsShop.jsp
  33. 21 12
      src/main/webapp/WEB-INF/views/modules/user/cmRechargeForm.jsp
  34. 2 2
      src/main/webapp/WEB-INF/views/modules/user/cmUserBalanceList.jsp
  35. 1 1
      src/main/webapp/WEB-INF/views/modules/user/cmUserBalanceWithdrawalsForm.jsp
  36. 979 818
      src/main/webapp/WEB-INF/views/modules/user/newCmShopForm.jsp

+ 2 - 0
src/main/java/com/caimei/modules/order/dao/CmReceiptOrderRelationDao.java

@@ -38,4 +38,6 @@ public interface CmReceiptOrderRelationDao extends CrudDao<CmReceiptOrderRelatio
     String findUserId(Integer orderId);
 
     void insertOnlineRefund(OnlineRefundVo onlineRefundVo);
+
+    List<CmReceiptOrderRelation> findByShopOrderIds(@Param("shopOrderIds")List<Integer> shopOrderIds);
 }

+ 4 - 0
src/main/java/com/caimei/modules/order/dao/CmReturnedPurchaseDao.java

@@ -26,4 +26,8 @@ public interface CmReturnedPurchaseDao extends CrudDao<CmReturnedPurchase> {
     List<CmReturnedPurchase>  findListBuySuccess(CmReturnedPurchase item);
 
     Double refundTotalMoney(Integer orderID);
+
+    List<Integer> findReturnedShopOrder(Integer orderID);
+
+    String findSplitCode(Integer shopOrderId);
 }

+ 12 - 0
src/main/java/com/caimei/modules/order/entity/CmReceiptOrderRelation.java

@@ -27,6 +27,10 @@ public class CmReceiptOrderRelation extends DataEntity<CmReceiptOrderRelation> {
      * 抹平备注(目前适用后台直接抹平账户操作)
      */
     private String balanceAccountsRemark;
+    /**
+     * 子订单Id
+     */
+    private Integer shopOrderId;
 
     /**
      * 米花科技平台唯一流水号
@@ -75,6 +79,14 @@ public class CmReceiptOrderRelation extends DataEntity<CmReceiptOrderRelation> {
         this.balanceAccountsRemark = balanceAccountsRemark;
     }
 
+    public Integer getShopOrderId() {
+        return shopOrderId;
+    }
+
+    public void setShopOrderId(Integer shopOrderId) {
+        this.shopOrderId = shopOrderId;
+    }
+
     public CmReceiptOrderRelation() {
         super();
     }

+ 1 - 2
src/main/java/com/caimei/modules/order/entity/CmReturnedPurchase.java

@@ -51,7 +51,6 @@ public class CmReturnedPurchase extends DataEntity<CmReturnedPurchase> {
 
     private Date beginConfirmReturnTime;
     private Date endConfirmReturnTime;
-
     private List<List<CmReturnedPurchaseProduct>> cmReturnedPurchaseProductList;    //退款退货商品列表(用于前端接收)
     private List<ShopOrderReturned> shopOrderReturnedList;    //退款退货商品列表
     private List<CmReturnedPurchaseProduct> productList;    //退款退货商品列表
@@ -481,4 +480,4 @@ public class CmReturnedPurchase extends DataEntity<CmReturnedPurchase> {
     public void setEndTime(String endTime) {
         this.endTime = endTime;
     }
-}
+}

+ 2 - 2
src/main/java/com/caimei/modules/order/entity/OnlineRefundData.java

@@ -15,8 +15,8 @@ public class OnlineRefundData  implements Serializable {
     private String rt7_amount;
     private String rt8_orderStatus;
     private String sign;
-    public static final Set<String> NEED_SIGN_PARAMS = ImmutableSet.of("rt1_bizType", "rt2_retCode", "rt4_customerNumber",
-            "rt5_orderId", "rt6_refundOrderNum", "rt7_serialNumber", "rt8_amount");
+    public static final Set<String> NEED_SIGN_PARAMS = ImmutableSet.of("rt1_bizType", "rt2_retCode","rt3_retMsg", "rt4_customerNumber",
+            "rt5_orderId", "rt6_refundOrderNum", "rt7_amount", "rt8_orderStatus");
 
     public OnlineRefundData() {
     }

+ 134 - 84
src/main/java/com/caimei/modules/order/service/CmReturnedPurchaseService.java

@@ -1,5 +1,6 @@
 package com.caimei.modules.order.service;
 
+import com.alibaba.fastjson.JSON;
 import com.alibaba.fastjson.JSONObject;
 import com.caimei.modules.coupon.dao.CmCouponClubDao;
 import com.caimei.modules.coupon.entity.CmCouponClub;
@@ -26,6 +27,10 @@ import com.thinkgem.jeesite.common.persistence.Page;
 import com.thinkgem.jeesite.common.service.CrudService;
 import com.thinkgem.jeesite.common.utils.StringUtils;
 import com.thinkgem.jeesite.modules.sys.utils.UserUtils;
+import okhttp3.FormBody;
+import okhttp3.OkHttpClient;
+import okhttp3.Request;
+import okhttp3.Response;
 import org.apache.commons.collections.CollectionUtils;
 import org.apache.commons.lang.ArrayUtils;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -36,9 +41,11 @@ import org.apache.commons.httpclient.HttpStatus;
 import javax.annotation.Resource;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
+import java.io.IOException;
 import java.math.BigDecimal;
 import java.text.SimpleDateFormat;
 import java.util.*;
+import java.util.concurrent.TimeUnit;
 
 import static com.caimei.modules.miniprogram.utils.UploadPicUtils.saveImageToServer;
 
@@ -52,6 +59,11 @@ import static com.caimei.modules.miniprogram.utils.UploadPicUtils.saveImageToSer
 @Transactional(readOnly = true)
 public class CmReturnedPurchaseService extends CrudService<CmReturnedPurchaseDao, CmReturnedPurchase> {
 
+    public static OkHttpClient client = new OkHttpClient.Builder()
+            .connectTimeout(3, TimeUnit.SECONDS)
+            .readTimeout(20, TimeUnit.SECONDS)
+            .build();
+
     @Resource
     private CmReturnedPurchaseDao cmReturnedPurchaseDao;
     @Resource
@@ -456,7 +468,7 @@ public class CmReturnedPurchaseService extends CrudService<CmReturnedPurchaseDao
         return newOrder;
     }
 
-    @Transactional(readOnly = false)
+    @Transactional(readOnly = false,rollbackFor = Exception.class)
     public void confirmApply(CmReturnedPurchase cmReturnedPurchase, HttpServletRequest request) throws Exception {
         CmReturnedPurchase returnedPurchase = cmReturnedPurchaseDao.get(cmReturnedPurchase);
         if (returnedPurchase == null) {
@@ -592,7 +604,11 @@ public class CmReturnedPurchaseService extends CrudService<CmReturnedPurchaseDao
 
             //判断是否有线上退款
             if (returnedPurchase.getReturnedWay().equals("1") && returnedPurchase.getRefundOnlineFee() > 0) {
-                theOnlineRefund(returnedPurchase.getOrderID());
+                List<Integer> shopOrderIds=cmReturnedPurchaseDao.findReturnedShopOrder(returnedPurchase.getOrderID());
+                if(null==shopOrderIds||0==shopOrderIds.size()){
+                    throw new Exception("子订单信息错误!");
+                }
+                theOnlineRefund(shopOrderIds);
             }
 
             //二手订单交易全退,标记未售
@@ -732,33 +748,32 @@ public class CmReturnedPurchaseService extends CrudService<CmReturnedPurchaseDao
     /**
      * 第三方线上退款
      *
-     * @param orderId
+     * @param shopOrderIds
      */
-    private void theOnlineRefund(Integer orderId) throws Exception {
-        List<CmReceiptOrderRelation> relationList = cmReceiptOrderRelationDao.findByOrderID(orderId.toString());
+    private void theOnlineRefund(List<Integer> shopOrderIds) throws Exception {
+        List<CmReceiptOrderRelation> relationList = cmReceiptOrderRelationDao.findByShopOrderIds(shopOrderIds);
         if (null != relationList && relationList.size() > 0) {
             for (CmReceiptOrderRelation orderRelation : relationList) {
                 //cdr表payway为1纯线上收款
                 if ("1".equals(orderRelation.getPayWay())) {
                     //不同产品区分
-                    String payType = cmReceiptOrderRelationDao.findPayType(orderId);
-                    if ("12".equals(payType) || "17".equals(payType)) {
+                    if ("12".equals(orderRelation.getPayType()) || "17".equals(orderRelation.getPayType())) {
                         //网银
-                        onlinePay(orderRelation.getOrderRequestNo(), orderRelation.getAssociateAmount(), orderId, "1");
+                        unionRefund(orderRelation.getOrderRequestNo(), orderRelation.getAssociateAmount(), orderRelation.getShopOrderId());
                     } else {
                         //扫码
-                        unionRefund(orderRelation.getOrderRequestNo(), orderRelation.getAssociateAmount(), orderId, "1");
+                        onlinePay(orderRelation.getOrderRequestNo(), orderRelation.getAssociateAmount(), orderRelation.getShopOrderId());
                     }
                 }
             }
         }
     }
 
-    void onlinePay(String orderRequestNo, String money, Integer orderId, String type) throws Exception {
+    void onlinePay(String orderRequestNo, String money, Integer shopOrderId) throws Exception {
         AppPayRefundOrderVo orderVo = new AppPayRefundOrderVo();
         orderVo.setP1_bizType("AppPayRefund");
-        //todo 暂用本商户  E1807062884 网络
-        orderVo.setP3_customerNumber("E1807062884");
+        String splitCode=cmReturnedPurchaseDao.findSplitCode(shopOrderId);
+        orderVo.setP3_customerNumber(splitCode);
         //退款原单号
         orderVo.setP2_orderId(orderRequestNo);
         //自定义退款单号
@@ -766,92 +781,127 @@ public class CmReturnedPurchaseService extends CrudService<CmReturnedPurchaseDao
         orderVo.setP4_refundOrderId("TK" + tk +orderRequestNo);
         //退款金额
         orderVo.setP5_amount(money);
-        Map<String, String> map = MyBeanUtils.convertBean(orderVo, new LinkedHashMap());
-        String oriMessage = MyBeanUtils.getSignedByPresetParameter(map, AppPayRefundOrderVo.NEED_SIGN_PARAMS);
-        //网银产品密钥
-        oriMessage += "1iHnZaalUNAVcfcbKdh6n86Z0yUHtM6f";
-        logger.info("签名原文串:" + oriMessage);
-        String sign = Disguiser.disguiseMD5(oriMessage.trim());
-        logger.info("签名串:" + sign);
-        map.put("sign", sign);
-        logger.info("发送参数:" + map);
-        Map<String, Object> resultMap = HttpClientService.getHttpResp(map, "http://pay.trx.helipay.com/trx/app/interface.action");
-        logger.info("响应结果:" + resultMap);
-        if ((Integer) resultMap.get("statusCode") == HttpStatus.SC_OK) {
-            String resultMsg = (String) resultMap.get("response");
-            AppPayRefundOrderResponseVo orderResponseVo = JSONObject.parseObject(resultMsg, AppPayRefundOrderResponseVo.class);
-            String assemblyRespOriSign = MyBeanUtils.getSignedByPresetParameter(orderResponseVo, AppPayRefundOrderResponseVo.NEED_SIGN_PARAMS);
-            //密钥区分
-            assemblyRespOriSign += "CZiCbGrgFYQMldVkQnzbFQeQkn6mp25w";
-            logger.info("组装返回结果签名串:" + assemblyRespOriSign);
-            String responseSign = orderResponseVo.getSign();
-            logger.info("响应签名:" + responseSign);
-            String checkSign = Disguiser.disguiseMD5(assemblyRespOriSign.trim());
-            if (checkSign.equals(responseSign)) {
-                if ("0001".equals(orderResponseVo.getRt2_retCode())) {
-                    logger.info("第三方退款成功>>>>>>>orderId>>>" + orderId);
+        try {
+            Map<String, String> map = MyBeanUtils.convertBean(orderVo, new LinkedHashMap());
+            String oriMessage = MyBeanUtils.getSignedByPresetParameter(map, AppPayRefundOrderVo.NEED_SIGN_PARAMS);
+            oriMessage+=Constant.SAOMA;
+            String sign = Disguiser.disguiseMD5(oriMessage.trim());
+            logger.info("签名串:" + sign);
+            map.put("sign", sign);
+            logger.info("发送参数:" + map);
+            Map<String, Object> resultMap = HttpClientService.getHttpResp(map, Constant.REQUEST_URL);
+            logger.info("响应结果:" + resultMap);
+            if ((Integer) resultMap.get("statusCode") == HttpStatus.SC_OK) {
+                String resultMsg = (String) resultMap.get("response");
+                AppPayRefundOrderResponseVo orderResponseVo = JSONObject.parseObject(resultMsg, AppPayRefundOrderResponseVo.class);
+                //String[] excludes = {"rt3_retMsg"};
+                String assemblyRespOriSign = MyBeanUtils.getSignedByPresetParameter(orderResponseVo, AppPayRefundOrderResponseVo.NEED_SIGN_PARAMS);
+                assemblyRespOriSign+=Constant.SAOMA;
+                logger.info("组装返回结果签名串:" + assemblyRespOriSign);
+                String responseSign = orderResponseVo.getSign();
+                logger.info("响应签名:" + responseSign);
+                String checkSign = Disguiser.disguiseMD5(assemblyRespOriSign.trim());
+                if (checkSign.equals(responseSign)) {
+                    if ("0001".equals(orderResponseVo.getRt2_retCode())) {
+                        logger.info("第三方退款成功>>>>>>>shopOrderId>>>" + shopOrderId);
+                    } else {
+                        logger.error("退款失败========================" + orderResponseVo.getRt5_orderId() + "-" + orderResponseVo.getRt3_retMsg());
+                        throw new Exception("第三方退款失败!");
+                    }
                 } else {
-                    logger.error("退款失败========================" + orderResponseVo.getRt5_orderId() + "-" + orderResponseVo.getRt3_retMsg());
-                    throw new Exception("第三方退款失败!");
+                    logger.error("退款验签失败");
+                    throw new Exception("第三方退款验签失败!");
                 }
             } else {
-                logger.error("退款验签失败");
-                throw new Exception("第三方退款验签失败!");
+                logger.error("退款请求失败");
+                throw new Exception("第三方退款请求失败!");
             }
-        } else {
-            logger.error("退款请求失败");
-            throw new Exception("第三方退款请求失败!");
+        } catch (Exception e) {
+            e.printStackTrace();
         }
     }
     //todo 网银退款不退手续费,
     //1.本方法内转账手续费等待到账再发起退款请求
     //2.异步
     //3.回调
-    void unionRefund(String orderRequestNo,String money,Integer orderId,String type) throws Exception{
-        OnlineVo onlineVo = new OnlineVo();
-        onlineVo.setP1_bizType("OnlineRefund");
-        onlineVo.setP2_orderId(orderRequestNo);
-        onlineVo.setP3_customerNumber("E1807062884");
-        onlineVo.setP4_refundAmount(money);
-        onlineVo.setP5_refundOrderId("TK" +orderRequestNo);
-        //暂时不设置备注和回调
-        //onlineVo.setP6_desc("");
-        //onlineVo.setP7_serverCallbackUrl("");
-        Map<String, String> map = MyBeanUtils.convertBean(onlineVo, new LinkedHashMap());
-        String oriMessage = MyBeanUtils.getSignedByPresetParameter(map, OnlineVo.NEED_SIGN_PARAMS);
-        oriMessage += "CZiCbGrgFYQMldVkQnzbFQeQkn6mp25w";
-        logger.info("签名原文串:" + oriMessage);
-        String sign = Disguiser.disguiseMD5(oriMessage.trim());
-        logger.info("签名串:" + sign);
-        map.put("sign", sign);
-        logger.info("发送参数:" + map);
-        Map<String, Object> resultMap = HttpClientService.getHttpResp(map, "http://pay.trx.helipay.com/trx/online/interface.action");
-        logger.info("响应结果:" + resultMap);
-        if ((Integer) resultMap.get("statusCode") == HttpStatus.SC_OK) {
-            String resultMsg = (String) resultMap.get("response");
-            OnlineRefundData onlineRefund = JSONObject.parseObject(resultMsg, OnlineRefundData.class);
-            String assemblyRespOriSign = MyBeanUtils.getSignedByPresetParameter(onlineRefund, OnlineRefundData.NEED_SIGN_PARAMS);
-            //密钥区分
-            assemblyRespOriSign += "CZiCbGrgFYQMldVkQnzbFQeQkn6mp25w";
-            logger.info("组装返回结果签名串:" + assemblyRespOriSign);
-            String responseSign = onlineRefund.getSign();
-            logger.info("响应签名:" + responseSign);
-            String checkSign = Disguiser.disguiseMD5(assemblyRespOriSign.trim());
-            if (checkSign.equals(responseSign)) {
-                if ("0000".equals(onlineRefund.getRt2_retCode())) {
-                    logger.info("第三方退款成功>>>>>>>orderId>>>" + orderId);
-                } else {
-                    logger.error("退款失败========================" + onlineRefund.getRt5_orderId() + "-" + onlineRefund.getRt3_retMsg());
+    void unionRefund(String orderRequestNo,String money,Integer shopOrderId) throws Exception{
+        Map<String, String> sPara = new HashMap<String, String>();
+        sPara.put("P1_bizType", "OnlineRefund");
+        sPara.put("P2_orderId", orderRequestNo);
+        String splitCode=cmReturnedPurchaseDao.findSplitCode(shopOrderId);
+        sPara.put("P3_customerNumber", splitCode);
+        sPara.put("P4_refundAmount",money);
+        sPara.put("P5_refundOrderId","TK" +orderRequestNo);
+        sPara.put("P6_desc","无");
+        sPara.put("P7_serverCallbackUrl","");
+        StringBuffer sb = new StringBuffer();
+        sb.append("&").append("OnlineRefund").append("&").append(orderRequestNo).append("&").append(splitCode).append("&").
+                append(money).append("&").append("TK" +orderRequestNo).append("&").append("无").append("&").append("&").append(Constant.WANGYIN);
+        String sign = Disguiser.disguiseMD5(sb.toString());
+        sPara.put("sign", sign);
+        try {
+            OnlineRefundData on = postForm(sPara, Constant.YL, sign, OnlineRefundData.class);
+            JSONObject jsonObject = JSONObject.parseObject(JSONObject.toJSONString(on), JSONObject.class);
+            if (!"0000".equals(on.getRt2_retCode())) {
+                logger.info("退款失败:" + on.toString());
+                throw new Exception("退款失败");
+            } else {
+                String assemblyRespOriSign = MyBeanUtils.getSignedByPresetParameter(on, OnlineRefundData.NEED_SIGN_PARAMS);
+                logger.info("组装返回结果签名串:" + assemblyRespOriSign);
+                assemblyRespOriSign += Constant.SPLIT + Constant.WANGYIN;
+                String checkSign = Disguiser.disguiseMD5(assemblyRespOriSign.trim());
+                if (!checkSign.equals(on.getSign())) {
+                    logger.error("验签失败========================" +on.getRt3_retMsg());
                     throw new Exception("第三方退款失败!");
+                } else {
+                    logger.info("第三方退款成功");
                 }
-            } else {
-                logger.error("退款验签失败");
-                throw new Exception("第三方退款验签失败!");
             }
-        } else {
-            logger.error("退款请求失败");
-            throw new Exception("第三方退款请求失败!");
+        } catch (Exception e) {
+            e.printStackTrace();
+        }
+    }
+
+    private <T> T postForm(Map<String, String> params, String url, String sign, Class<T> clazz) {
+        FormBody.Builder builder = new FormBody.Builder();
+        for (Map.Entry<String, String> entry : params.entrySet()) {
+            builder.add(entry.getKey(), entry.getValue());
+        }
+        builder.add("sign", sign);
+
+        Request request = new Request.Builder() // okHttp post
+                .url(url)
+                .post(builder.build())
+                .build();
+
+        Response response = null;
+        try {
+            response = client.newCall(request).execute();
+        } catch (IOException e) {
+            throw new IllegalStateException("请求出错", e);
+        }
+        if (!response.isSuccessful()) {
+            try {
+                logger.info(response.body().string());
+            } catch (IOException e) {
+                e.printStackTrace();
+            }
+            throw new RuntimeException("请求失败了: http response code: " + response.code());
+        }
+
+        okhttp3.ResponseBody body = response.body();
+        String content = null;
+        try {
+            content = body.string();
+        } catch (IOException e) {
+            throw new IllegalStateException("IO异常", e);
+        }
+        JSONObject res = JSON.parseObject(content);
+        if ("0000".equals(res.getString("rt2_retCode"))) {
+            logger.info("退款申请发起成功------->"+res.toString());
         }
+        /** rt4_success 为 true,需验签  **/
+        return res.toJavaObject(clazz);
     }
 
     @Transactional(readOnly = false)

+ 2 - 5
src/main/java/com/caimei/modules/order/service/SplitAccountService.java

@@ -9,6 +9,7 @@ import com.caimei.modules.order.utils.PayUtil;
 import com.caimei.redis.RedisService;
 import com.caimei.utils.MathUtil;
 import com.thinkgem.jeesite.common.persistence.Page;
+import com.thinkgem.jeesite.common.service.BaseService;
 import okhttp3.*;
 import org.apache.commons.lang3.StringUtils;
 import org.slf4j.Logger;
@@ -27,16 +28,12 @@ import java.util.stream.Collectors;
 
 @Service
 @Transactional(readOnly = true)
-public class SplitAccountService {
+public class SplitAccountService extends BaseService {
 
     public static OkHttpClient client = new OkHttpClient.Builder()
             .connectTimeout(3, TimeUnit.SECONDS)
             .readTimeout(20, TimeUnit.SECONDS)
             .build();
-    /**
-     * 日志对象
-     */
-    private static Logger logger = LoggerFactory.getLogger(Logger.class);
 
     @Resource
     private NewOrderDao newOrderDao;

+ 2 - 2
src/main/java/com/caimei/modules/product/web/ProductNewController.java

@@ -354,8 +354,8 @@ public class ProductNewController extends BaseController {
         if (product.getSupplierTaxPoint() == null) {
             product.setSupplierTaxPoint(product.getTaxPoint());
         }
-//        List<SplitCode> splitCodeList = productNewDao.findSplitCode(product.getShopID());
-//        model.addAttribute("splitCodeList",splitCodeList);
+        List<SplitCode> splitCodeList = productNewDao.findSplitCode(product.getShopID());
+        model.addAttribute("splitCodeList",splitCodeList);
         model.addAttribute("combinationList", combinationList);
         model.addAttribute("brandList", brandList);
         model.addAttribute("shopList", shopList);

+ 2 - 0
src/main/java/com/caimei/modules/user/dao/CmOperationsDao.java

@@ -10,4 +10,6 @@ import com.thinkgem.jeesite.common.persistence.annotation.MyBatisDao;
 public interface CmOperationsDao extends CrudDao<CmOperationalLogs> {
     NewCmShop shoplist(Integer shopID);
 
+    NewCmShop userlist(Integer userID);
+
 }

+ 9 - 0
src/main/java/com/caimei/modules/user/entity/NewCmShop.java

@@ -82,6 +82,7 @@ public class NewCmShop extends DataEntity<NewCmShop> {
     private String socialCreditCode; //统一社会信用代码
     private Integer shopType;//供应商类别,普通1,新品供应商2,二手供应商3
     private String cardNumber; //收款卡号
+    private Integer commIssion;
     /**
      * 非持久化字段
      **/
@@ -1054,4 +1055,12 @@ public class NewCmShop extends DataEntity<NewCmShop> {
     public void setWxApplets(String wxApplets) {
         this.wxApplets = wxApplets;
     }
+
+    public Integer getCommIssion() {
+        return commIssion;
+    }
+
+    public void setCommIssion(Integer commIssion) {
+        this.commIssion = commIssion;
+    }
 }

+ 9 - 0
src/main/java/com/caimei/modules/user/entity/SplitCode.java

@@ -6,6 +6,7 @@ public class SplitCode extends DataEntity<SplitCode> {
     private String splitCode;//分账商户号
     private String codeRemark;//账户备注
     private Integer shopId; //供应商ID
+    private String email;
 
     public String getSplitCode() {
         return splitCode;
@@ -30,4 +31,12 @@ public class SplitCode extends DataEntity<SplitCode> {
     public void setShopId(Integer shopId) {
         this.shopId = shopId;
     }
+
+    public String getEmail() {
+        return email;
+    }
+
+    public void setEmail(String email) {
+        this.email = email;
+    }
 }

+ 5 - 0
src/main/java/com/caimei/modules/user/service/CmOperationalLogService.java

@@ -24,6 +24,11 @@ public class CmOperationalLogService extends CrudService<CmOperationsDao, CmOper
         return cmoperationDao.shoplist(shop);
     }
 
+    @Transactional(readOnly = false)
+    public NewCmShop userlist(Integer shop) {
+        return cmoperationDao.userlist(shop);
+    }
+
     @Transactional(readOnly = false)
     public List<CmOperationalLogs> findList(CmOperationalLogs cmoperationalLogs) {
         return cmoperationDao.findList(cmoperationalLogs);

+ 5 - 11
src/main/java/com/caimei/modules/user/web/CmUserBalanceRecordController.java

@@ -131,11 +131,8 @@ public class CmUserBalanceRecordController extends BaseController {
         return "modules/user/cmRechargeForm";
     }
 
-
-    @ResponseBody
     @RequestMapping(value = "saveRecharge")
-    public Map<String, Object> saveRecharge(CmUserBalanceRecord cmUserBalanceRecord) {
-        Map<String, Object> map = Maps.newLinkedHashMap();
+    public String saveRecharge(CmUserBalanceRecord cmUserBalanceRecord,RedirectAttributes redirectAttributes) {
         try {
             //保存充值记录
             //添加余额收支记录
@@ -154,15 +151,12 @@ public class CmUserBalanceRecordController extends BaseController {
             cmUser.setAbleUserMoney(cmUser.getAbleUserMoney() + amountDouble);
             cmUser.setUserMoney(cmUser.getUserMoney() + amountDouble);
             cmUserDao.updateMoney(cmUser);
-
-            map.put("success", true);
-            map.put("msg", "充值成功");
+            addMessage(redirectAttributes, "充值成功");
         } catch (Exception e) {
             logger.debug(e.toString(), e);
-            map.put("success", false);
-            map.put("msg", "充值失败");
+            addMessage(redirectAttributes, "充值失败");
         }
-        return map;
+        return "redirect:" + Global.getAdminPath() + "/user/cmUserBalanceRecord/userBalanceList";
     }
 
     @RequestMapping(value = "toRecharge")
@@ -230,4 +224,4 @@ public class CmUserBalanceRecordController extends BaseController {
         return "redirect:" + Global.getAdminPath() + "/user/cmUserBalanceRecord/userBalanceRecord?userId=" + userId;
     }
 
-}
+}

+ 326 - 17
src/main/java/com/caimei/modules/user/web/NewCmShopController.java

@@ -6,14 +6,8 @@ import com.caimei.modules.sys.utils.CmMsgUtils;
 import com.caimei.modules.sys.utils.SMSUtils;
 import com.caimei.modules.user.dao.CmUserDao;
 import com.caimei.modules.user.dao.NewCmShopDao;
-import com.caimei.modules.user.entity.CmMessage;
-import com.caimei.modules.user.entity.CmOperationUser;
-import com.caimei.modules.user.entity.CmUser;
-import com.caimei.modules.user.entity.NewCmShop;
-import com.caimei.modules.user.service.CmMessageService;
-import com.caimei.modules.user.service.CmOperationUserService;
-import com.caimei.modules.user.service.CmUserService;
-import com.caimei.modules.user.service.NewCmShopService;
+import com.caimei.modules.user.entity.*;
+import com.caimei.modules.user.service.*;
 import com.caimei.utils.AppKeys;
 import com.caimei.utils.DateUtils;
 import com.caimei.utils.MD5Util;
@@ -23,6 +17,7 @@ import com.thinkgem.jeesite.common.config.Global;
 import com.thinkgem.jeesite.common.persistence.Page;
 import com.thinkgem.jeesite.common.utils.StringUtils;
 import com.thinkgem.jeesite.common.web.BaseController;
+import com.thinkgem.jeesite.modules.sys.security.SystemAuthorizingRealm;
 import com.thinkgem.jeesite.modules.sys.utils.UserUtils;
 import org.apache.commons.collections.CollectionUtils;
 import org.apache.commons.collections.map.HashedMap;
@@ -65,12 +60,8 @@ public class NewCmShopController extends BaseController {
     private CmUserDao cmUserDao;
     @Autowired
     private NewCmShopDao newCmShopDao;
-
-
-    public static NewCmShop newcm;
-    public static CmUser cmus;
-    public static int id;
-    public static String auditNo;
+    @Autowired
+    CmOperationalLogService cmOperationalLogService;
 
 
     @ModelAttribute
@@ -97,7 +88,6 @@ public class NewCmShopController extends BaseController {
         //屏蔽特殊供应商
         newCmShop.setShopType(1);
         Page<NewCmShop> page = newCmShopService.findPage(new Page<NewCmShop>(request, response), newCmShop);
-        newcm = newCmShop;
         model.addAttribute("page", page);
         return "modules/user/newCmShopList";
     }
@@ -195,6 +185,8 @@ public class NewCmShopController extends BaseController {
     @RequestMapping(value = "auditShopInfo")
     public Map<String, Object> auditShopInfo(String auditStatus, Integer shopId, Integer userId, String auditNote, Model model) {
         Map<String, Object> map = new HashedMap();
+        NewCmShop newCmShops = cmOperationalLogService.shoplist(shopId);
+        CmOperationalLogs sysLog = new CmOperationalLogs();
         try {
             Date date = new Date();
             SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd hh:mm:ss");
@@ -204,10 +196,44 @@ public class NewCmShopController extends BaseController {
             CmUser companyUser = cmUserService.get(userId + "");
             String mobile = companyUser.getBindMobile();
             if (StringUtils.equals("1", auditStatus)) {
+                //获取操作时间
+                sysLog.setOperationtime(new Date());
+
+                //获取操作员
+                SystemAuthorizingRealm.Principal principal = UserUtils.getPrincipal();
+                System.out.println("操作员" + principal.getName());
+                String username = principal.getName();
+                sysLog.setOperator(username);
+                sysLog.setContact(newCmShops.getLinkMan());
+                sysLog.setInstitutionName(newCmShops.getName());
+                sysLog.setOperationtype("审核");
+                sysLog.setActioncontent("审核成功");
+                if (!"".equals(sysLog.getActioncontent())) {
+                    if (sysLog.getInstitutionName() != null && sysLog.getContact() != null) {
+                        int i = cmOperationalLogService.insert(sysLog);
+                    }
+                }
                 manufacturerStatus = "90";
                 smsMessage = "恭喜您成功通过资料审核,您可以使用账号" + mobile + "在采美登录您的企业账号,开始愉快的采购之旅。";
             }
             if (StringUtils.equals("2", auditStatus)) {
+                //获取操作时间
+                sysLog.setOperationtime(new Date());
+
+                //获取操作员
+                SystemAuthorizingRealm.Principal principal = UserUtils.getPrincipal();
+                System.out.println("操作员" + principal.getName());
+                String username = principal.getName();
+                sysLog.setOperator(username);
+                sysLog.setContact(newCmShops.getLinkMan());
+                sysLog.setInstitutionName(newCmShops.getName());
+                sysLog.setOperationtype("审核");
+                    sysLog.setActioncontent("审核失败");
+                if (!"".equals(sysLog.getActioncontent())) {
+                    if (sysLog.getInstitutionName() != null && sysLog.getContact() != null) {
+                        int i = cmOperationalLogService.insert(sysLog);
+                    }
+                }
                 manufacturerStatus = "92";
                 smsMessage = "很遗憾,您的资料信息有误,未通过审核,请登录采美修改资料信息。";
             }
@@ -219,12 +245,18 @@ public class NewCmShopController extends BaseController {
             newCmShopService.updateShopAudit(auditStatus, auditNote, format, name, manufacturerStatus, shopId);
             map.put("success", true);
             map.put("msg", "审核成功");
+
+
+
             if (StringUtils.isNotEmpty(mobile)) {
                 SMSUtils.sendSms(mobile, smsMessage);
             }
         } catch (Exception e) {
             e.printStackTrace();
             logger.error(e.getMessage());
+
+
+
             map.put("success", false);
             map.put("msg", "审核失败");
         }
@@ -377,6 +409,7 @@ public class NewCmShopController extends BaseController {
     @ResponseBody
     @RequestMapping(value = "updatePwd")
     public Map<String, Object> updatePwd(String password, String id, HttpServletRequest request, HttpServletResponse response) {
+        CmOperationalLogs sysLog = new CmOperationalLogs();
         Map<String, Object> map = Maps.newLinkedHashMap();
         try {
             CmUser cmUser = cmUserService.get(id);
@@ -384,6 +417,24 @@ public class NewCmShopController extends BaseController {
             cmUserService.update(cmUser);
             map.put("success", true);
             map.put("msg", "修改成功");
+
+            //获取操作时间
+            sysLog.setOperationtime(new Date());
+
+            //获取操作员
+            SystemAuthorizingRealm.Principal principal = UserUtils.getPrincipal();
+            System.out.println("操作员" + principal.getName());
+            String username = principal.getName();
+            sysLog.setOperator(username);
+            sysLog.setContact(cmUser.getUserName());
+            sysLog.setInstitutionName(cmUser.getName());
+            sysLog.setOperationtype("修改密码");
+            sysLog.setActioncontent("修改密码");
+            if (!"".equals(sysLog.getActioncontent())) {
+                if (sysLog.getInstitutionName() != null && sysLog.getContact() != null) {
+                    int i = cmOperationalLogService.insert(sysLog);
+                }
+            }
         } catch (Exception e) {
             logger.debug(e.toString(), e);
             map.put("success", false);
@@ -454,9 +505,28 @@ public class NewCmShopController extends BaseController {
     @RequiresPermissions("user:newCmShop:edit")
     public String onLine(NewCmShop newCmShop, Model model, RedirectAttributes redirectAttributes) {
         Integer userID = newCmShop.getUserID();
+        NewCmShop newCmShops= cmOperationalLogService.userlist(userID);
+        CmOperationalLogs sysLog = new CmOperationalLogs();
         cmUserService.updateUserStatus("90", userID, "1");
         newCmShopService.updateShopStatus("90", userID);
         addMessage(redirectAttributes, "供应商上线成功");
+        //获取操作时间
+        sysLog.setOperationtime(new Date());
+
+        //获取操作员
+        SystemAuthorizingRealm.Principal principal = UserUtils.getPrincipal();
+        System.out.println("操作员" + principal.getName());
+        String username = principal.getName();
+        sysLog.setOperator(username);
+        sysLog.setContact(newCmShops.getLinkMan());
+        sysLog.setInstitutionName(newCmShops.getName());
+        sysLog.setOperationtype("更改状态");
+        sysLog.setActioncontent("设置为已上线");
+        if (!"".equals(sysLog.getActioncontent())) {
+            if (sysLog.getInstitutionName() != null && sysLog.getContact() != null) {
+                int i = cmOperationalLogService.insert(sysLog);
+            }
+        }
         return "redirect:" + Global.getAdminPath() + "/user/newCmShop/";
     }
 
@@ -471,10 +541,30 @@ public class NewCmShopController extends BaseController {
     @RequestMapping(value = "offline")
     @RequiresPermissions("user:newCmShop:edit")
     public String offLine(NewCmShop newCmShop, Model model, RedirectAttributes redirectAttributes) {
+        System.out.println(">>>>>>>>>>>>>>》》》》》"+newCmShop);
         Integer userID = newCmShop.getUserID();
+        NewCmShop newCmShops= cmOperationalLogService.userlist(userID);
         cmUserService.updateUserStatus("91", userID, "0");
         newCmShopService.updateShopStatus("91", userID);
         addMessage(redirectAttributes, "供应商下线成功");
+        CmOperationalLogs sysLog = new CmOperationalLogs();
+        //获取操作时间
+        sysLog.setOperationtime(new Date());
+
+        //获取操作员
+        SystemAuthorizingRealm.Principal principal = UserUtils.getPrincipal();
+        System.out.println("操作员" + principal.getName());
+        String username = principal.getName();
+        sysLog.setOperator(username);
+        sysLog.setContact(newCmShops.getLinkMan());
+        sysLog.setInstitutionName(newCmShops.getName());
+        sysLog.setOperationtype("更改状态");
+        sysLog.setActioncontent("设置为已下线");
+        if (!"".equals(sysLog.getActioncontent())) {
+            if (sysLog.getInstitutionName() != null && sysLog.getContact() != null) {
+                int i = cmOperationalLogService.insert(sysLog);
+            }
+        }
         return "redirect:" + Global.getAdminPath() + "/user/newCmShop/";
     }
 
@@ -482,9 +572,228 @@ public class NewCmShopController extends BaseController {
     @RequiresPermissions("user:newCmShop:edit")
     @RequestMapping(value = "save")
     public String save(NewCmShop newCmShop, Model model, RedirectAttributes redirectAttributes) {
+        NewCmShop newCmShops = cmOperationalLogService.shoplist(newCmShop.getShopID());
+        System.out.println("修改前》》》》》"+newCmShop);
+        System.out.println("修改后》》》》》"+newCmShops);
+        ArrayList<String> list = new ArrayList();
+
+        CmOperationalLogs sysLog = new CmOperationalLogs();
+
+        if (newCmShops.getMaintenanceFee() == "0") {
+            if (!newCmShop.getMaintenanceFee().equals("0")) {
+                list.add("新增了线上分账商户号");
+            }
+        } else if (!newCmShop.getMaintenanceFee().equals(newCmShops.getMaintenanceFee())) {
+            list.add("修改了线上分账商户号");
+        }
+
+        if (newCmShops.getName() == null) {
+            if (!newCmShop.getName().equals("")) {
+                list.add("新增了公司名称");
+            }
+        } else if (!newCmShops.getName().equals(newCmShop.getName())) {
+            list.add("修改了公司名称");
+        }
+
+        if (newCmShops.getSname() == null) {
+            if (!newCmShop.getSname().equals("")) {
+                list.add("新增了公司简称");
+            }
+        } else if (!newCmShop.getSname().equals(newCmShops.getSname())) {
+            list.add("修改了公司简称");
+        }
+
+        if (newCmShops.getAddress() == null) {
+            if (!newCmShop.getAddress().equals("")) {
+                list.add("新增了公司地址");
+            }
+        } else if (!newCmShop.getAddress().equals(newCmShops.getAddress())) {
+            list.add("修改了公司地址");
+        }
+
+        if (newCmShops.getLinkMan() == null) {
+            if (!newCmShop.getLinkMan().equals("")) {
+                list.add("新增了联系人");
+            }
+        } else if (!newCmShop.getLinkMan().equals(newCmShops.getLinkMan())) {
+            list.add("修改了联系人");
+        }
+
+        if (newCmShops.getContractMobile() == null) {
+            if (!newCmShop.getContractMobile().equals("")) {
+                list.add("新增了手机号");
+            }
+        } else if (!newCmShop.getContractMobile().equals(newCmShops.getContractMobile())) {
+            list.add("修改了手机号");
+        }
+
+        if (newCmShops.getEmail() == null) {
+            if (!newCmShop.getEmail().equals("")) {
+                list.add("新增了邮箱");
+            }
+        } else if (!newCmShop.getEmail().equals(newCmShops.getEmail())) {
+            list.add("修改了邮箱");
+        }
+
+        if (newCmShops.getContractPhone() == null) {
+            if (!newCmShop.getContractPhone().equals("")) {
+                list.add("新增了固定电话");
+            }
+        } else if (!newCmShop.getContractPhone().equals(newCmShops.getContractPhone())) {
+            list.add("修改了固定电话");
+        }
+
+        if (newCmShops.getFax() == null) {
+            if (!newCmShop.getFax().equals("")) {
+                list.add("新增了传真");
+            }
+        } else if (!newCmShop.getFax().equals(newCmShops.getFax())) {
+            list.add("修改了传真");
+        }
+
+        if (newCmShops.getLegalPerson() == null) {
+            if (!newCmShop.getLegalPerson().equals("")) {
+                list.add("新增了法人代表");
+            }
+        } else if (!newCmShop.getLegalPerson().equals(newCmShops.getLegalPerson())) {
+            list.add("修改了法人代表");
+        }
+
+        if (newCmShops.getRegisteredCapital() == null) {
+            if (newCmShop.getRegisteredCapital()!=null) {
+                list.add("新增了注册资本");
+            }
+        }
+        if (newCmShops.getRegisteredCapital() != null) {
+            if (!newCmShop.getRegisteredCapital().equals(newCmShops.getRegisteredCapital()) ) {
+                list.add("修改了注册资本");
+            }
+        }
+        if (newCmShops.getNature() == null) {
+            if (!newCmShop.getNature().equals("")) {
+                list.add("新增了公司性质");
+            }
+        } else if (!newCmShop.getNature().equals(newCmShops.getNature())) {
+            list.add("修改了公司性质");
+        }
+
+        if (newCmShops.getTurnover() == null) {
+            if (!newCmShop.getTurnover().equals("")) {
+                list.add("新增了年营业额");
+            }
+        } else if (!newCmShop.getTurnover().equals(newCmShops.getTurnover())) {
+            list.add("修改了年营业额");
+        }
+
+        if (newCmShops.getFirstShopType() == null) {
+            if (!newCmShop.getFirstShopType().equals("")) {
+                list.add("新增了公司类型");
+            }
+        } else if (!newCmShop.getFirstShopType().equals(newCmShops.getFirstShopType())) {
+            list.add("修改了公司类型");
+        }
+
+        if (newCmShops.getSecondShopType() == null) {
+            if (!newCmShop.getSecondShopType().equals("")) {
+                list.add("新增了医疗类型");
+            }
+        } else if (!newCmShop.getSecondShopType().equals(newCmShops.getSecondShopType())) {
+            list.add("修改了医疗类型");
+        }
+
+        if (newCmShops.getMainpro() == null) {
+            if (!newCmShop.getMainpro().equals("")) {
+                list.add("新增了主营内容");
+            }
+        } else if (!newCmShop.getMainpro().equals(newCmShops.getMainpro())) {
+            list.add("修改了主营内容");
+        }
+
+        if (newCmShops.getBusinessScope() == null) {
+            if (!newCmShop.getBusinessScope().equals("")) {
+                list.add("新增了医疗类型");
+            }
+        }
+
+         if (!newCmShop.getBusinessScope().equals(newCmShops.getBusinessScope())) {
+            list.add("修改了医疗类型");
+        }
+
+        if (newCmShops.getWebsite() == null) {
+            if (!newCmShop.getWebsite().equals("")) {
+                list.add("新增了官网地址");
+            }
+        } else if (!newCmShop.getWebsite().equals(newCmShops.getWebsite())) {
+            list.add("修改了官网地址");
+        }
+
+        if (newCmShops.getWxOfficialAccount() == null) {
+            if (!newCmShop.getWxOfficialAccount().equals("")) {
+                list.add("新增了微信公众号");
+            }
+        }
+            if (!newCmShop.getWxOfficialAccount().equals(newCmShops.getWxOfficialAccount())) {
+            list.add("修改了微信公众号");
+        }
+
+        if (newCmShops.getWxApplets() == null) {
+            if (!newCmShop.getWxApplets().equals("")) {
+                list.add("新增了微信小程序");
+            }
+        } else if (!newCmShop.getWxApplets().equals(newCmShops.getWxApplets())) {
+            list.add("修改了微信小程序");
+        }
+
+        if (newCmShops.getSocialCreditCode() == null) {
+            if (!newCmShop.getSocialCreditCode().equals("")) {
+                list.add("新增了营业执照编号");
+            }
+        }
+      if (!newCmShop.getSocialCreditCode().equals(newCmShops.getSocialCreditCode())) {
+            list.add("修改了营业执照编号");
+        }
+
+        if (newCmShops.getBusinessLicenseImage() == null) {
+            if (!newCmShop.getBusinessLicenseImage().equals("")) {
+                list.add("新增了营业执照图片");
+            }
+        } else if (!newCmShop.getBusinessLicenseImage().equals(newCmShops.getBusinessLicenseImage())) {
+            list.add("修改了营业执照图片");
+        }
+
+        if (newCmShops.getLogo() == null) {
+            if (!newCmShop.getLogo().equals("")) {
+                list.add("新增了营业执照图片");
+            }
+        } else if (!newCmShop.getLogo().equals(newCmShops.getLogo())) {
+            list.add("修改了营业执照图片");
+        }
+        sysLog.setActioncontent(StringUtils.strip(list.toString(), "[]"));
+
+        //获取操作时间
+        sysLog.setOperationtime(new Date());
+
+        //获取操作员
+        SystemAuthorizingRealm.Principal principal = UserUtils.getPrincipal();
+        System.out.println("操作员" + principal.getName());
+        String username = principal.getName();
+        sysLog.setOperator(username);
+        sysLog.setContact(newCmShop.getLinkMan());
+        sysLog.setInstitutionName(newCmShop.getName());
+        sysLog.setOperationtype("编辑");
+        if (!"".equals(sysLog.getActioncontent())) {
+            if (sysLog.getInstitutionName() != null && sysLog.getContact() != null) {
+                int i = cmOperationalLogService.insert(sysLog);
+                list.removeAll(list);
+            }
+        }
+
+
+
         if (!beanValidator(model, newCmShop)) {
             return form(newCmShop, model);
         }
+
         newCmShopService.update(newCmShop);
         //更新供应商对于用户信息
         cmUserDao.updateUserInfo(newCmShop.getLinkMan(), newCmShop.getName(), newCmShop.getSname(), newCmShop.getContractMobile(), newCmShop.getEmail(), newCmShop.getUserID());
@@ -527,8 +836,8 @@ public class NewCmShopController extends BaseController {
             if (StringUtils.isEmpty(cmShop.getSecondShopType())) {
                 return jsonModel.error("请选择二级分类");
             } else {
-                if ("3".equals(cmShop.getSecondShopType()) && StringUtils.isEmpty(cmShop.getMedicalPracticeLicenseImg1()))
-                    return jsonModel.error("请上传资质");
+                if ("3".equals(cmShop.getSecondShopType()) && StringUtils.isEmpty(cmShop.getMedicalPracticeLicenseImg1())){
+                    return jsonModel.error("请上传资质");}
             }
             dbShop.setSecondShopType(cmShop.getSecondShopType());
             dbShop.setMedicalPracticeLicenseImg1(cmShop.getMedicalPracticeLicenseImg1());

+ 18 - 7
src/main/java/com/caimei/modules/user/web/newUser/AgencyController.java

@@ -821,7 +821,7 @@ public class AgencyController extends BaseController {
         String smsMessage = "";
         String currTime = DateUtils.getDateTime();
         Integer userPermission;
-
+        OperationalLogs sysLog = new OperationalLogs();
 
 
         try {
@@ -835,13 +835,7 @@ public class AgencyController extends BaseController {
             /**审核处理*/
             //审核通过
             if (StringUtils.equals("1", auditStatus)) {
-
-                OperationalLogs sysLog = new OperationalLogs();
-                if ("1".equals(auditStatus)){
                     sysLog.setActioncontent("审核通过");
-                } else {
-                    sysLog.setActioncontent("审核不通过");
-                }
                 String Contact = sysLogService.auditlinkMan(Integer.parseInt(id));
                 String ionName = sysLogService.auditName(Integer.parseInt(id));
                 sysLog.setContact(Contact);
@@ -880,6 +874,23 @@ public class AgencyController extends BaseController {
                 auditStatus = "2";
                 smsMessage = "您的机构升级资质机构失败!快戳采美网站链接www.caimei365.com或微信搜索“采美采购商城”小程序登录采美平台修改升级信息重新提交审核。" +
                         "关注公众号“采美365网”可获取更多优惠和精彩资讯。";
+                sysLog.setActioncontent("审核未通过");
+                String Contact = sysLogService.auditlinkMan(Integer.parseInt(id));
+                String ionName = sysLogService.auditName(Integer.parseInt(id));
+                sysLog.setContact(Contact);
+                sysLog.setInstitutionName(ionName);
+                SystemAuthorizingRealm.Principal principal = UserUtils.getPrincipal();
+                System.out.println("操作员" + principal.getName());
+                String username = principal.getName();
+                sysLog.setOperator(username);
+                sysLog.setOperationtype("审核");
+                sysLog.setOperationtime(new Date());
+                //调用service保存SysLog实体类到数据库
+                if (!"".equals(sysLog.getActioncontent())) {
+                    if (sysLog.getInstitutionName() != null && sysLog.getContact() != null) {
+                        int i = sysLogService.insert(sysLog);
+                    }
+                }
             }
             //机构表修改
             newCmClub.setStatus(Integer.parseInt(status));

+ 25 - 3
src/main/java/com/caimei/modules/user/web/newUser/SpController.java

@@ -149,9 +149,11 @@ public class SpController extends BaseController {
                         String jgName = sysLogService.JgName(clubChangeSpRecordID);
                         String linkMans = sysLogService.ClubName(clubChangeSpRecordID);
                         sysLog.setOperationtime(new Date());
-                        if (!"".equals(linkMans)) {
-                            sysLog.setActioncontent(clubIDs + "更换为" + clubID);
-                        }
+                       if(clubIDs==null){
+                           sysLog.setActioncontent("采美默认协销经理(官方账号)" + "更换为" + clubID);
+                       }else {
+                           sysLog.setActioncontent(clubIDs + "更换为" + clubID);
+                       }
                         sysLog.setOperationtype("更换协销");
                         sysLog.setContact(linkMans);
                         sysLog.setInstitutionName(jgName);
@@ -183,6 +185,26 @@ public class SpController extends BaseController {
                 clubChangeSp.setCheckStatus("-1");//审核未通过
                 clubChangeSp.setClubChangeSpRecordID(clubChangeSpRecordID);
                 clubChangeSpReviewService.updateCheckStatusById(clubChangeSp);
+                String clubID = sysLogService.ClubsName(clubChangeSpRecordID);
+                String jgName = sysLogService.JgName(clubChangeSpRecordID);
+                String linkMans = sysLogService.ClubName(clubChangeSpRecordID);
+                sysLog.setOperationtime(new Date());
+                if (!"".equals(linkMans)) {
+                    sysLog.setActioncontent("审核不通过");
+                }
+                sysLog.setOperationtype("更换协销");
+                sysLog.setContact(linkMans);
+                sysLog.setInstitutionName(jgName);
+                SystemAuthorizingRealm.Principal principal = UserUtils.getPrincipal();
+                System.out.println("操作员" + principal.getName());
+                String username = principal.getName();
+                sysLog.setOperator(username);
+                //调用service保存SysLog实体类到数据库
+                if (!"".equals(sysLog.getActioncontent())) {
+                    if (sysLog.getInstitutionName() != null && sysLog.getContact() != null) {
+                        int i = sysLogService.insert(sysLog);
+                    }
+                }
                 map.put("success", true);
                 map.put("msg", "操作成功");
             }

+ 1 - 1
src/main/resources/mappings/modules/newhome/AnnouncementMapper.xml

@@ -9,7 +9,7 @@
 
         <where>
             <if test="title != null and title != ''">
-                AND title = #{title}+'%'
+                AND title LIKE "%"#{title}"%"
             </if>
             <if test="state != null and state != 0">
                 AND `state` = #{state}

+ 21 - 1
src/main/resources/mappings/modules/order/CmReceiptOrderRelationMapper.xml

@@ -210,9 +210,29 @@
 		SELECT payType
 		FROM cm_discern_receipt cdr
 		LEFT JOIN cm_receipt_order_relation cror ON cdr.id = cror.receiptID
-		WHERE cror.orderID = #{orderId}
+		WHERE cror.shopOrderId = #{orderId}
 	</select>
 	<select id="findUserId" resultType="java.lang.String">
 		select userId from cm_order where orderId=#{orderId}
 	</select>
+	<select id="findByShopOrderIds" resultType="com.caimei.modules.order.entity.CmReceiptOrderRelation">
+		select
+			a.*,
+			b.payType as "payType",
+			b.receiptDate as "receiptDate",
+			b.confirmType as "confirmType",
+			b.balanceAccountsRemark as "balanceAccountsRemark",
+			b.payWay as "payWay"
+		from  cm_receipt_order_relation a
+		left join cm_discern_receipt b on a.receiptID = b.id
+		where a.shopOrderId in
+		<foreach collection="shopOrderIds" open="(" close=")" item="shopOrderId" separator=",">
+			#{shopOrderId}
+		</foreach>
+		  AND b.receiptType = '1'
+		  AND b.receiptStatus = '3'
+		  AND a.delFlag = '0'
+		  AND b.delFlag = '0'
+		order by b.receiptDate desc
+	</select>
 </mapper>

+ 8 - 1
src/main/resources/mappings/modules/order/CmReturnedPurchaseMapper.xml

@@ -398,5 +398,12 @@
 		SELECT SUM(IFNULL(returnedPurchaseFee,0)) FROM cm_returned_purchase
 		WHERE orderID=#{orderID} AND delFlag='0' AND status='2'
 	</select>
-
+	<select id="findReturnedShopOrder" resultType="java.lang.Integer">
+		SELECT shopOrderId FROM cm_returned_purchase_product crpp
+		LEFT JOIN cm_returned_purchase crp ON crp.id=crpp.returnedID
+		WHERE crp.orderId=#{orderID}
+		  AND crp.status=2
+		  AND crp.returnedWay =1
+		  AND crp.delflag=0
+	</select>
 </mapper>

+ 2 - 2
src/main/resources/mappings/modules/order/OrderMapper.xml

@@ -1252,9 +1252,9 @@
     <insert id="insertSplitAccount">
         INSERT INTO cm_split_account (orderId, productId, orderProductId, shopId, couponRecordId, vipRecordId,
                                       authVipRecordId, type, subUserNo, splitAccount,
-                                      mbOrderId, orderRequestNo, payStatus, productType, splitTime)
+                                      mbOrderId, orderRequestNo, payStatus, productType, shopOrderId ,splitTime)
         VALUES (#{orderId}, #{productId}, #{orderProductId}, #{shopId}, #{couponRecordId}, #{vipRecordId},
                 #{authVipRecordId}, #{type}, #{subUserNo}, #{splitAccount},
-                #{mbOrderId}, #{orderRequestNo}, #{payStatus}, #{productType}, NOW());
+                #{mbOrderId}, #{orderRequestNo}, #{payStatus}, #{productType},#{shopOrderId}, NOW());
     </insert>
 </mapper>

+ 10 - 4
src/main/resources/mappings/modules/user/CmOperationalLogsMapper.xml

@@ -9,16 +9,16 @@
 
         <where>
             <if test="institutionName != null and institutionName != ''">
-                AND institutionName = '%'+#{institutionName}+'%'
+                AND institutionName LIKE "%"#{institutionName}"%"
             </if>
             <if test="Contact != null and Contact != ''">
-                AND Contact = '%'+#{Contact}+'%'
+                AND Contact LIKE "%"#{Contact}"%"
             </if>
             <if test="operationtype != null and operationtype != ''">
-                AND operationtype = '%'+#{operationtype}+'%'
+                AND operationtype LIKE "%"#{operationtype}"%"
             </if>
             <if test="Operationtime != null and Operationtime != ''">
-                AND Operationtime = '%'+#{Operationtime}+'%'
+                AND Operationtime LIKE "%"#{Operationtime}"%"
             </if>
             <if test="startTime != null and startTime != ''">
                 AND Operationtime <![CDATA[ > ]]> #{startTime}
@@ -57,4 +57,10 @@
          LEFT JOIN `user` u ON u.userID = s.userID
         WHERE s.shopID = #{shopID}
     </select>
+
+    <select id="userlist" resultType="NewCmShop">
+        SELECT *  FROM `shop` s
+        LEFT JOIN `user` u ON u.userID = s.userID
+        WHERE s.userID = #{userID}
+    </select>
 </mapper>

+ 5 - 3
src/main/resources/mappings/modules/user/NewCmShopMapper.xml

@@ -59,6 +59,7 @@
 		u.source AS "source",
 		a.shopType AS "shopType",
 		a.cardNumber AS "cardNumber",
+        a.commIssion AS "commIssion",
 		d.name AS "province",c.name AS "city",b.name AS "town"
 	</sql>
 
@@ -148,7 +149,7 @@
 		</choose>
 	</select>
 	<select id="findSplitCode" resultType="com.caimei.modules.user.entity.SplitCode">
-		select shopId,commercialCode as splitCode,codeDetail as codeRemark
+		select shopId,commercialCode as splitCode,codeDetail as codeRemark,email as email
 		from cm_shop_splitcode
 		where shopId = #{shopID}
 	</select>
@@ -264,8 +265,8 @@
 	</insert>
 	<insert id="insertSplitCode">
 		insert into cm_shop_splitcode
-		(shopId, commercialCode, codeDetail)
-		values (#{shopId},#{splitCode},#{codeRemark})
+		(shopId, commercialCode, codeDetail,email)
+		values (#{shopId},#{splitCode},#{codeRemark},#{email})
 	</insert>
 	<insert id="insertSepcial" parameterType="NewCmShop"  keyProperty="shopID" useGeneratedKeys="true">
 		insert into shop(name,linkMan,contractMobile,status,addTime,shopType)
@@ -278,6 +279,7 @@
 		    website = #{website},
 			wxOfficialAccount = #{wxOfficialAccount},
 			wxApplets = #{wxApplets},
+			commIssion=#{commIssion},
 			<if test="sname != null and sname != ''" >
 				sname = #{sname},
 			</if>

+ 4 - 4
src/main/resources/mappings/modules/user/OperationalLogsMapper.xml

@@ -9,16 +9,16 @@
 
         <where>
             <if test="institutionName != null and institutionName != ''">
-                AND institutionName = '%'+#{institutionName}+'%'
+                AND institutionName LIKE "%"#{institutionName}"%"
             </if>
             <if test="Contact != null and Contact != ''">
-                AND Contact = '%'+#{Contact}+'%'
+                AND Contact LIKE "%"#{Contact}"%"
             </if>
             <if test="operationtype != null and operationtype != ''">
-                AND operationtype = '%'+#{operationtype}+'%'
+                AND operationtype LIKE "%"#{operationtype}"%"
             </if>
             <if test="Operationtime != null and Operationtime != ''">
-                AND Operationtime = '%'+#{Operationtime}+'%'
+                AND Operationtime LIKE "%"#{Operationtime}"%"
             </if>
             <if test="startTime != null and startTime != ''">
                 AND Operationtime <![CDATA[ > ]]> #{startTime}

+ 44 - 23
src/main/webapp/WEB-INF/views/modules/bulkpurchase/orderConfirmReturnRecord.jsp

@@ -69,7 +69,16 @@
             display: none;
         }
 
-        .weishaIcon {background:darkorange;color:white;margin:0 0px;padding:0 3px;font-style:normal;font-size: 12px; display:inline-block;border-radius:2px}
+        .weishaIcon {
+            background: darkorange;
+            color: white;
+            margin: 0 0px;
+            padding: 0 3px;
+            font-style: normal;
+            font-size: 12px;
+            display: inline-block;
+            border-radius: 2px
+        }
     </style>
     <style media="print">
         @page {
@@ -247,19 +256,23 @@
             订单金额:¥<fmt:formatNumber type="number" value="${order.payTotalFee}" pattern="0.00" maxFractionDigits="2"/>&nbsp;
             <c:if test="${not empty order.couponOrderRecord}">
                 <c:if test="${order.couponOrderRecord.couponType eq 0}">
-                    <a href="${ctx}/coupon/cmCouponClub/couponDetails?userId=${order.userID}"><font color="red">(活动券抵扣¥${order.couponOrderRecord.couponAmount},满${order.couponOrderRecord.touchPrice}减${order.couponOrderRecord.couponAmount})</font></a>
+                    <a href="${ctx}/coupon/cmCouponClub/couponDetails?userId=${order.userID}"><font
+                            color="red">(活动券抵扣¥${order.couponOrderRecord.couponAmount},满${order.couponOrderRecord.touchPrice}减${order.couponOrderRecord.couponAmount})</font></a>
                 </c:if>
                 <c:if test="${order.couponOrderRecord.couponType eq 1}">
-                    <a href="${ctx}/coupon/cmCouponClub/couponDetails?userId=${order.userID}"><font color="red">(品类券抵扣¥${order.couponOrderRecord.couponAmount},满${order.couponOrderRecord.touchPrice}减${order.couponOrderRecord.couponAmount})</font></a>
+                    <a href="${ctx}/coupon/cmCouponClub/couponDetails?userId=${order.userID}"><font
+                            color="red">(品类券抵扣¥${order.couponOrderRecord.couponAmount},满${order.couponOrderRecord.touchPrice}减${order.couponOrderRecord.couponAmount})</font></a>
                 </c:if>
                 <c:if test="${order.couponOrderRecord.couponType eq 2}">
                     <a href="${ctx}/coupon/cmCouponClub/couponDetails?userId=${order.userID}"><font color="red">(用户专享券抵扣¥${order.couponOrderRecord.couponAmount},满${order.couponOrderRecord.touchPrice}减${order.couponOrderRecord.couponAmount})</font></a>
                 </c:if>
                 <c:if test="${order.couponOrderRecord.couponType eq 3}">
-                    <a href="${ctx}/coupon/cmCouponClub/couponDetails?userId=${order.userID}"><font color="red">(店铺券抵扣¥${order.couponOrderRecord.couponAmount},满${order.couponOrderRecord.touchPrice}减${order.couponOrderRecord.couponAmount})</font></a>
+                    <a href="${ctx}/coupon/cmCouponClub/couponDetails?userId=${order.userID}"><font
+                            color="red">(店铺券抵扣¥${order.couponOrderRecord.couponAmount},满${order.couponOrderRecord.touchPrice}减${order.couponOrderRecord.couponAmount})</font></a>
                 </c:if>
                 <c:if test="${order.couponOrderRecord.couponType eq 4}">
-                    <a href="${ctx}/coupon/cmCouponClub/couponDetails?userId=${order.userID}"><font color="red">(新用户券抵扣¥${order.couponOrderRecord.couponAmount},满${order.couponOrderRecord.touchPrice}减${order.couponOrderRecord.couponAmount})</font></a>
+                    <a href="${ctx}/coupon/cmCouponClub/couponDetails?userId=${order.userID}"><font
+                            color="red">(新用户券抵扣¥${order.couponOrderRecord.couponAmount},满${order.couponOrderRecord.touchPrice}减${order.couponOrderRecord.couponAmount})</font></a>
                 </c:if>
             </c:if>
             <c:if test="${not empty order.heheCouponRecord}">
@@ -272,7 +285,8 @@
         </td>
         <td>
             应收总额:¥<fmt:formatNumber type="number" value="${order.payableAmount}" pattern="0.00" maxFractionDigits="2"/>(账户余额抵扣:${order.balancePayFee})
-            <a href="${ctx}/order/cmDiscernReceipt/detail?id=${lastReceiptDetailId}" style="text-decoration: underline;margin-left: 20px">查看订单收款情况</a>
+            <a href="${ctx}/order/cmDiscernReceipt/detail?id=${lastReceiptDetailId}"
+               style="text-decoration: underline;margin-left: 20px">查看订单收款情况</a>
         </td>
         <td>
             经理折扣:¥<fmt:formatNumber type="number" value="${order.discountFee}" pattern="0.00" maxFractionDigits="2"/>
@@ -348,7 +362,8 @@
     </tr>
     <tr>
         <td>
-            机构:${order.buyer}<c:if test="${order.organizeID == 3}"></c:if>
+            机构:${order.buyer}
+            <c:if test="${order.organizeID == 3}"></c:if>
         </td>
         <td>
             收货人:${order.bpOrderUserinfo.shouHuoRen}(${order.bpOrderUserinfo.mobile})
@@ -360,7 +375,7 @@
 </table>
 <c:forEach items="${cmReturnedPurchaseList}" var="cmReturnedPurchase" varStatus="cmReturnedPurchaseStatus">
     <input type="hidden" id="shopOrderSize" value='${fns:listToJson(cmReturnedPurchase.shopOrderReturnedList)}'>
-    <c:forEach items="${cmReturnedPurchase.shopOrderReturnedList}" var="shopOrderReturned"
+    <c:forEach items="${cmReturnedPurchase.shopOrderReturnedList}" var="shopOrderReturneds"
                varStatus="shopOrderReturnedStatus">
         <tr>
             <td colspan="7">
@@ -368,45 +383,51 @@
                        class="table table-striped table-bordered table-condensed">
                     <tr>
                         <td style="width: 300px;">
-                            子订单编号(ID):${shopOrderReturned.shopOrderNo}(${shopOrderReturned.shopOrderID})
+                            子订单编号(ID):${shopOrderReturneds.shopOrderNo}(${shopOrderReturneds.shopOrderID})
                         </td>
-                        <td style="width: 250px;">子订单金额:${shopOrderReturned.productAmount}</td>
+                        <td style="width: 250px;">子订单金额:${shopOrderReturneds.productAmount}</td>
                         <td>
-                            收款状态:${fns:getDictLabel(shopOrderReturned.receiptStatus,'receiptStatus' ,'' )}
+                            收款状态: ${fns:getDictLabel(shopOrderReturneds.shopReceiptStatus,'shopReceiptStatus' ,'' )}
                         </td>
                         <td>发货状态:
-                                ${fns:getDictLabel(shopOrderReturned.sendOutStatus,'sendOutStatus' ,'' )}
+                                ${fns:getDictLabel(shopOrderReturneds.sendOutStatus,'sendOutStatus' ,'' )}
                         </td>
                         <td>付款状态:
-                                ${fns:getDictLabel(shopOrderReturned.payStatus,'payStatus' ,'' )}
+                                ${fns:getDictLabel(shopOrderReturneds.payStatus,'payStatus' ,'' )}
                         </td>
                         <td>
-                            供应商:${shopOrderReturned.shopName}&nbsp;&nbsp;
-                            <c:if test="${not empty shopOrderReturned.commercialCode}">
-                                <font color="red" class="businessNumber">(商户号:&nbsp;&nbsp;${shopOrderReturned.commercialCode})</font>
+                            供应商:${shopOrderReturneds.shopName}&nbsp;&nbsp;
+                            <c:if test="${not empty shopOrderReturneds.commercialCode}">
+                                <font color="red"
+                                      class="businessNumber">(商户号:&nbsp;&nbsp;${shopOrderReturneds.commercialCode})</font>
                             </c:if>
                         </td>
                     </tr>
                     <c:if test="${order.onlinePayFlag ne 1}">
                         <tr>
                             <td>
-                                商品总额:¥<fmt:formatNumber type="number" value="${shopOrderReturned.needPayAmount}" pattern="0.00" maxFractionDigits="2" />
+                                商品总额:¥<fmt:formatNumber type="number" value="${shopOrderReturneds.needPayAmount}"
+                                                        pattern="0.00" maxFractionDigits="2"/>
                             </td>
                             <td>
-                                优惠:¥<fmt:formatNumber type="number" value="${shopOrderReturned.eachDiscount}" pattern="0.00" maxFractionDigits="2" />
+                                优惠:¥<fmt:formatNumber type="number" value="${shopOrderReturneds.eachDiscount}"
+                                                      pattern="0.00" maxFractionDigits="2"/>
                             </td>
-                            <td>
-                                应付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturned.realPay}" pattern="0.00" maxFractionDigits="2" />
+                            <td>   <%--实际支付金额 #realPay,needPayAmount 需要支付金额 shouldPayFee +运费--%>
+                                应付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturneds.needPayAmount}"
+                                                        pattern="0.00" maxFractionDigits="2"/>
                             </td>
                             <td>
-                                已付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturned.receiptAmount}" pattern="0.00" maxFractionDigits="2" />
+                                已付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturneds.receiptAmount}"
+                                                        pattern="0.00" maxFractionDigits="2"/>
                             </td>
                             <td>
-                                待付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturned.restAmount}" pattern="0.00" maxFractionDigits="2" />
+                                待付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturneds.restAmount}"
+                                                        pattern="0.00" maxFractionDigits="2"/>
                             </td>
                         </tr>
                     </c:if>
-                    <c:forEach items="${shopOrderReturned.cmReturnedPurchaseProductList}"
+                    <c:forEach items="${shopOrderReturneds.cmReturnedPurchaseProductList}"
                                var="cmReturnedPurchaseProduct" varStatus="cmReturnedPurchaseProductStatus">
                         <tr>
                             <td rowspan="4" style="width: 295px;height: 125px">

+ 13 - 13
src/main/webapp/WEB-INF/views/modules/bulkpurchase/orderReturnRecord.jsp

@@ -503,44 +503,44 @@
         <%--单次退款商品信息汇总--%>
 
         <table id="cmReturnedPurchaseTable" class="table table-striped table-bordered table-condensed">
-                <c:forEach items="${cmReturnedPurchase.shopOrderReturnedList}" var="shopOrderReturned" varStatus="shopOrderReturnedStatus">
+                <c:forEach items="${cmReturnedPurchase.shopOrderReturnedList}" var="shopOrderReturneds" varStatus="shopOrderReturnedStatus">
                     <tr>
                         <td colspan="7">
                             <table id="shopOrderReturnedTable${shopOrderReturnedStatus.index}" class="table table-striped table-bordered table-condensed">
                                 <tr>
-                                    <td style="width: 300px;">子订单编号(ID):${shopOrderReturned.shopOrderNo}(${shopOrderReturned.shopOrderID})</td>
-                                    <td  style="width: 250px;">子订单金额:${shopOrderReturned.productAmount}</td>
+                                    <td style="width: 300px;">子订单编号(ID):${shopOrderReturneds.shopOrderNo}(${shopOrderReturneds.shopOrderID})</td>
+                                    <td  style="width: 250px;">子订单金额:${shopOrderReturneds.productAmount}</td>
                                     <td>
-                                        收款状态:${fns:getDictLabel(shopOrderReturned.shopReceiptStatus,'receiptStatus' ,'' )}
+                                        收款状态:${fns:getDictLabel(shopOrderReturneds.shopReceiptStatus,'receiptStatus' ,'' )}
                                     </td>
                                     <td>发货状态:
-                                            ${fns:getDictLabel(shopOrderReturned.sendOutStatus,'sendOutStatus' ,'' )}
+                                            ${fns:getDictLabel(shopOrderReturneds.sendOutStatus,'sendOutStatus' ,'' )}
                                     </td>
                                     <td>付款状态:
-                                            ${fns:getDictLabel(shopOrderReturned.payStatus,'payStatus' ,'' )}
+                                            ${fns:getDictLabel(shopOrderReturneds.payStatus,'payStatus' ,'' )}
                                     </td>
-                                    <td>供应商:${shopOrderReturned.shopName}</td>
+                                    <td>供应商:${shopOrderReturneds.shopName}</td>
                                 </tr>
                                 <c:if test="${order.onlinePayFlag eq 0}">
                                     <tr>
                                         <td>
-                                            商品总额:¥<fmt:formatNumber type="number" value="${shopOrderReturned.needPayAmount}" pattern="0.00" maxFractionDigits="2" />
+                                            商品总额:¥<fmt:formatNumber type="number" value="${shopOrderReturneds.needPayAmount}" pattern="0.00" maxFractionDigits="2" />
                                         </td>
                                         <td>
-                                            优惠:¥<fmt:formatNumber type="number" value="${shopOrderReturned.eachDiscount}" pattern="0.00" maxFractionDigits="2" />
+                                            优惠:¥<fmt:formatNumber type="number" value="${shopOrderReturneds.eachDiscount}" pattern="0.00" maxFractionDigits="2" />
                                         </td>
                                         <td>
-                                            应付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturned.realPay}" pattern="0.00" maxFractionDigits="2" />
+                                            应付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturneds.realPay}" pattern="0.00" maxFractionDigits="2" />
                                         </td>
                                         <td>
-                                            已付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturned.receiptAmount}" pattern="0.00" maxFractionDigits="2" />
+                                            已付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturneds.receiptAmount}" pattern="0.00" maxFractionDigits="2" />
                                         </td>
                                         <td>
-                                            待付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturned.restAmount}" pattern="0.00" maxFractionDigits="2" />
+                                            待付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturneds.restAmount}" pattern="0.00" maxFractionDigits="2" />
                                         </td>
                                     </tr>
                                 </c:if>
-                                <c:forEach items="${shopOrderReturned.cmReturnedPurchaseProductList}" var="cmReturnedPurchaseProduct" varStatus="cmReturnedPurchaseProductStatus">
+                                <c:forEach items="${shopOrderReturneds.cmReturnedPurchaseProductList}" var="cmReturnedPurchaseProduct" varStatus="cmReturnedPurchaseProductStatus">
                                     <tr>
                                         <td  rowspan="4" style="width: 295px;height: 125px">
                                             <img style="width: 100px;height: 100px"  src="${cmReturnedPurchaseProduct.mainImage}">

+ 15 - 15
src/main/webapp/WEB-INF/views/modules/bulkpurchase/orderReviewReturnRecord.jsp

@@ -440,49 +440,49 @@
 </table>
 <c:forEach items="${cmReturnedPurchaseList}" var="cmReturnedPurchase" varStatus="cmReturnedPurchaseStatus">
             <input type="hidden" id="shopOrderSize" value='${fns:listToJson(cmReturnedPurchase.shopOrderReturnedList)}'>
-            <c:forEach items="${cmReturnedPurchase.shopOrderReturnedList}" var="shopOrderReturned" varStatus="shopOrderReturnedStatus">
+            <c:forEach items="${cmReturnedPurchase.shopOrderReturnedList}" var="shopOrderReturneds" varStatus="shopOrderReturnedStatus">
                 <tr>
                     <td colspan="7">
                     <table id="shopOrderReturnedTable${shopOrderReturnedStatus.index}" class="table table-striped table-bordered table-condensed">
                         <tr>
-                            <td style="width: 300px;">子订单编号(ID):${shopOrderReturned.shopOrderNo}(${shopOrderReturned.shopOrderID})</td>
-                            <td  style="width: 250px;">子订单金额:${shopOrderReturned.productAmount}</td>
+                            <td style="width: 300px;">子订单编号(ID):${shopOrderReturneds.shopOrderNo}(${shopOrderReturneds.shopOrderID})</td>
+                            <td  style="width: 250px;">子订单金额:${shopOrderReturneds.productAmount}</td>
                             <td>
-                                收款状态:${fns:getDictLabel(shopOrderReturned.shopReceiptStatus,'receiptStatus' ,'' )}
+                                收款状态:${fns:getDictLabel(shopOrderReturneds.shopReceiptStatus,'receiptStatus' ,'' )}
                             </td>
                             <td>发货状态:
-                                    ${fns:getDictLabel(shopOrderReturned.sendOutStatus,'sendOutStatus' ,'' )}
+                                    ${fns:getDictLabel(shopOrderReturneds.sendOutStatus,'sendOutStatus' ,'' )}
                             </td>
                             <td>付款状态:
-                                    ${fns:getDictLabel(shopOrderReturned.payStatus,'payStatus' ,'' )}
+                                    ${fns:getDictLabel(shopOrderReturneds.payStatus,'payStatus' ,'' )}
                             </td>
                             <td>
-                                供应商:${shopOrderReturned.shopName}&nbsp;&nbsp;
-                                <c:if test="${not empty shopOrderReturned.commercialCode}">
-                                    <font color="red" class="businessNumber">(商户号:&nbsp;&nbsp;${shopOrderReturned.commercialCode})</font>
+                                供应商:${shopOrderReturneds.shopName}&nbsp;&nbsp;
+                                <c:if test="${not empty shopOrderReturneds.commercialCode}">
+                                    <font color="red" class="businessNumber">(商户号:&nbsp;&nbsp;${shopOrderReturneds.commercialCode})</font>
                                 </c:if>
                             </td>
                         </tr>
                         <c:if test="${order.onlinePayFlag ne 1}">
                             <tr>
                                 <td>
-                                    商品总额:¥<fmt:formatNumber type="number" value="${shopOrderReturned.needPayAmount}" pattern="0.00" maxFractionDigits="2" />
+                                    商品总额:¥<fmt:formatNumber type="number" value="${shopOrderReturneds.needPayAmount}" pattern="0.00" maxFractionDigits="2" />
                                 </td>
                                 <td>
-                                    优惠:¥<fmt:formatNumber type="number" value="${shopOrderReturned.eachDiscount}" pattern="0.00" maxFractionDigits="2" />
+                                    优惠:¥<fmt:formatNumber type="number" value="${shopOrderReturneds.eachDiscount}" pattern="0.00" maxFractionDigits="2" />
                                 </td>
                                 <td>
-                                    应付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturned.realPay}" pattern="0.00" maxFractionDigits="2" />
+                                    应付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturneds.realPay}" pattern="0.00" maxFractionDigits="2" />
                                 </td>
                                 <td>
-                                    已付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturned.receiptAmount}" pattern="0.00" maxFractionDigits="2" />
+                                    已付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturneds.receiptAmount}" pattern="0.00" maxFractionDigits="2" />
                                 </td>
                                 <td>
-                                    待付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturned.restAmount}" pattern="0.00" maxFractionDigits="2" />
+                                    待付金额:¥<fmt:formatNumber type="number" value="${shopOrderReturneds.restAmount}" pattern="0.00" maxFractionDigits="2" />
                                 </td>
                             </tr>
                         </c:if>
-                        <c:forEach items="${shopOrderReturned.cmReturnedPurchaseProductList}" var="cmReturnedPurchaseProduct" varStatus="cmReturnedPurchaseProductStatus">
+                        <c:forEach items="${shopOrderReturneds.cmReturnedPurchaseProductList}" var="cmReturnedPurchaseProduct" varStatus="cmReturnedPurchaseProductStatus">
                             <tr>
                                 <td  rowspan="4" style="width: 295px;height: 125px">
                                     <img style="width: 100px;height: 100px"  src="${cmReturnedPurchaseProduct.mainImage}">

+ 7 - 7
src/main/webapp/WEB-INF/views/modules/bulkpurchase/organizeOrderReturnRecord.jsp

@@ -576,21 +576,21 @@
                 </td>
             </tr>
                 </c:forEach>--%>
-                <c:forEach items="${cmReturnedPurchase.shopOrderReturnedList}" var="shopOrderReturned" varStatus="shopOrderReturnedStatus">
+                <c:forEach items="${cmReturnedPurchase.shopOrderReturnedList}" var="shopOrderReturneds" varStatus="shopOrderReturnedStatus">
                 <c:forEach items="${order.newShopOrders}" var="shopOrder" varStatus="status">
                     <tr>
                         <td colspan="7">
                             <table id="shopOrderReturnedTable${shopOrderReturnedStatus.index}" class="table table-striped table-bordered table-condensed">
                                 <tr>
-                                    <td style="width: 300px;">子订单编号(ID):${shopOrderReturned.shopOrderNo}(${shopOrderReturned.shopOrderID})</td>
-                                    <td  style="width: 250px;">子订单金额:${shopOrderReturned.productAmount}</td>
+                                    <td style="width: 300px;">子订单编号(ID):${shopOrderReturneds.shopOrderNo}(${shopOrderReturneds.shopOrderID})</td>
+                                    <td  style="width: 250px;">子订单金额:${shopOrderReturneds.productAmount}</td>
                                     <td>发货状态:
-                                            ${fns:getDictLabel(shopOrderReturned.sendOutStatus,'sendOutStatus' ,'' )}
+                                            ${fns:getDictLabel(shopOrderReturneds.sendOutStatus,'sendOutStatus' ,'' )}
                                     </td>
                                     <td>付款状态:
-                                            ${fns:getDictLabel(shopOrderReturned.payStatus,'payStatus' ,'' )}
+                                            ${fns:getDictLabel(shopOrderReturneds.payStatus,'payStatus' ,'' )}
                                     </td>
-                                    <td>供应商:${shopOrderReturned.shopName}</td>
+                                    <td>供应商:${shopOrderReturneds.shopName}</td>
                                 </tr>
                     <tr>
                         <td style="width: 300px;">
@@ -627,7 +627,7 @@
                         </c:if>
                     </tr>
                            </c:forEach>
-                                <c:forEach items="${shopOrderReturned.cmReturnedPurchaseProductList}" var="cmReturnedPurchaseProduct" varStatus="cmReturnedPurchaseProductStatus">
+                                <c:forEach items="${shopOrderReturneds.cmReturnedPurchaseProductList}" var="cmReturnedPurchaseProduct" varStatus="cmReturnedPurchaseProductStatus">
                                     <tr>
                                         <td  rowspan="4" style="width: 295px;height: 125px">
                                             <img style="width: 100px;height: 100px"  src="${cmReturnedPurchaseProduct.mainImage}">

+ 7 - 1
src/main/webapp/WEB-INF/views/modules/product-new/productEdit.jsp

@@ -499,7 +499,13 @@
         <tr>
             <th>线上分账账号:</th>
             <td colspan="3">
-                <form:input path="splitCode" type="text" id="splitCode" maxlength="15"/>
+                <form:select path="splitCode" class="select-ele input-medium required">
+                    <form:option value="" label="请选择"/>
+                    <c:forEach items="${splitCodeList}" var="splitCodeList" varStatus="index">
+                        <form:option value="${splitCodeList.splitCode}" label="${splitCodeList.splitCode} ${splitCodeList.codeRemark}"/>
+                    </c:forEach>
+                </form:select>
+<%--                <form:input path="splitCode" type="text" id="splitCode" maxlength="15"/>--%>
             </td>
         </tr>
         <tr id="taxPointDiv">

+ 1 - 1
src/main/webapp/WEB-INF/views/modules/product-new/productList.jsp

@@ -126,7 +126,7 @@
 				</div>
 				<div class="item">
 					<input id="btnSubmit" class="btn btn-primary" type="submit" value="查询" style="margin-left:20px;"/>
-					&nbsp;&nbsp;&nbsp;&nbsp;<input class="btn btn-primary" onclick="window.location='${ctx}/product/new/productEdit?shopType=2'" value="发布特殊供应商品"/>
+					&nbsp;&nbsp;&nbsp;&nbsp;<input class="btn btn-primary" onclick="window.location='${ctx}/product/new/productEdit?shopType=2'" value="发布特殊供应商品"/>
 				</div>
 				<%--<div class="item">
 					<input type="button" class="btn btn-primary" value="更新所有商品索引" onclick="updateAllIndex()"  style="margin-left:20px;"/>

+ 24 - 6
src/main/webapp/WEB-INF/views/modules/user/cmNewProductShopEdit.jsp

@@ -90,7 +90,7 @@
     </div>
     <div class="control-group">
         <tr>
-            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<th><b>线上分账账号:</b></th>
+            <th><b>分账商户号:</b></th>
             <td colspan="3" class="params">
                 <div id="addParamsItems">
                         <%--相关参数层--%>
@@ -98,8 +98,11 @@
                            id="productParametersLength">
                     <c:forEach items="${newCmShop.splitCodes}" var="item" varStatus="varIndex">
                         <div id="paramsItem" class="paramsItem">
-                            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<form:input path="splitCodes[${varIndex.index}].splitCode" id="paramsName"
-                                            maxlength="8" placeholder="请输入分帐商户号" class="input-small"/>
+                            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<form:input
+                                path="splitCodes[${varIndex.index}].splitCode" id="paramsName"
+                                maxlength="8" placeholder="请输入分帐商户号" class="input-small"/>
+                            <form:input path="splitCodes[${varIndex.index}].email" id="email"
+                                        maxlength="10" placeholder="请输入对应邮箱号" class="input-small"/>
                             <form:input path="splitCodes[${varIndex.index}].codeRemark" id="paramsContent"
                                         maxlength="10" placeholder="请输入账户备注"
                                         class="input-small"/>
@@ -108,8 +111,22 @@
                         </div>
                     </c:forEach>
                 </div>
-                &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<button class="addParams" onclick="return false">添加分帐号</button>
-            </td>
+                &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<button
+                    class="addParams" onclick="return false">添加分帐号
+            </button>
+        </td>
+<td>
+</br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
+    <strong>线上支付手续费:</strong>
+
+    <c:if test="${empty newCmShop.commIssion || newCmShop.commIssion==0}">
+        <input type="radio" checked="checked" name="commIssion" value="0"  class="required" />采美承担
+        <input type="radio" name="commIssion" value="1" class="required" />供应商承担
+    </c:if>
+    <c:if test="${newCmShop.commIssion==1}">
+        <input type="radio"  name="commIssion" value="0"  class="required" />采美承担
+        <input type="radio" checked="checked" name="commIssion" value="1" class="required" />供应商承担
+    </c:if></td>
         </tr>
     </div>
 
@@ -128,6 +145,7 @@
         productParametersIndex++;
         var html = '<div id="paramsItem" class="paramsItem">';
         html += '&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input name="splitCodes[' + [productParametersIndex] + '].splitCode" id="splitCode" maxlength="8" placeholder="请输入分帐商户号" type="text" class="input-small"/>&nbsp;';
+        html += '<input name="splitCodes[' + [productParametersIndex] + '].email" id="email" maxlength="10" placeholder="请输入对应邮箱号"  type="text"   class="input-small"/>&nbsp;';
         html += '<input name="splitCodes[' + [productParametersIndex] + '].codeRemark" id="codeRemark" maxlength="10" placeholder="请输入账户备注"  type="text"   class="input-small"/>&nbsp;';
         html += '<span type="button" style="cursor: pointer;color: #0B61A4" onclick="deleteParams(this)"">删除</span>';
         html += '</div>';
@@ -150,4 +168,4 @@
 </script>
 </body>
 
-</html>
+</html>

+ 4 - 4
src/main/webapp/WEB-INF/views/modules/user/cmOperationalLogs.jsp

@@ -41,11 +41,11 @@
         <form:input path="institutionName" name="institutionName" htmlEscape="false" maxlength="50" class="input-medium"/>
         <label>联系人:</label>
         <form:input path="Contact" name="Contact" htmlEscape="false" maxlength="50" class="input-medium"/>
-            <label>机构类别:</label>
+            <label>操作类型:</label>
             <select name="operationtype" class="input-medium">
                 <option selected value="">全部</option>
                 <option value="编辑">编辑</option>
-                <option value="重置密码">重置密码</option>
+                <option value="修改密码">修改密码</option>
                 <option value="更换协销">更换协销</option>
                 <option value="审核">审核</option>
                 <option value="设置机构类别">设置机构类别</option>
@@ -53,8 +53,8 @@
                 <option value="更改状态">更改状态</option>
             </select>
 
-        <label>添加时间:</label>
-        <label>注册时间:</label>
+
+        <label>操作时间:</label>
         <form:input path="startTime" type="text" readonly="true" maxlength="20" class="input-mini Wdate" value="${startTime}"
                     onclick="WdatePicker({dateFmt:'yyyy-MM-dd',isShowClear:false});"/>
         -

+ 4 - 4
src/main/webapp/WEB-INF/views/modules/user/cmOperationalLogsShop.jsp

@@ -37,19 +37,19 @@
     <input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
     <input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
     <div class="ul-form">
-        <label>机构名称:</label>
+        <label>供应商名称:</label>
         <form:input path="institutionName" name="institutionName" htmlEscape="false" maxlength="50" class="input-medium"/>
         <label>联系人:</label>
         <form:input path="Contact" name="Contact" htmlEscape="false" maxlength="50" class="input-medium"/>
-            <label>机构类别:</label>
+            <label>操作类型:</label>
             <select name="operationtype" class="input-medium">
                 <option selected value="">全部</option>
                 <option value="编辑">编辑</option>
-                <option value="重置密码">重置密码</option>
+                <option value="修改密码">修改密码</option>
                 <option value="审核">审核</option>
                 <option value="更改状态">更改状态</option>
             </select>
-        <label>添加时间:</label>
+        <label>操作时间:</label>
         <form:input path="startTime" type="text" readonly="true" maxlength="20" class="input-mini Wdate" value="${startTime}"
                     onclick="WdatePicker({dateFmt:'yyyy-MM-dd',isShowClear:false});"/>
         -

+ 21 - 12
src/main/webapp/WEB-INF/views/modules/user/cmRechargeForm.jsp

@@ -58,26 +58,35 @@
 
 	</script>
 </head>
-<ul class="nav nav-tabs"></ul>
-<br/>
-<form:form id="inputForm" modelAttribute="cmUserBalanceRecord" action="" method="post" class="form-horizontal">
+<body>
+<ul class="nav nav-tabs">
+	<li><a href="${ctx}/user/cmUserBalanceWithdrawals/">余额提现列表</a></li>
+	<li><a href="${ctx}/user/cmUserBalanceRecord/userBalanceList">机构余额</a></li>
+	<li class="active"><a href="${ctx}/user/cmUserBalanceRecord/recharge?userId=${cmUser.userID}">充值</a></li>
+</ul><br/>
+<div style=" margin-left: 100px; height: 20px ">
+<form:form id="inputForm" modelAttribute="cmUserBalanceRecord" action="${ctx}/user/cmUserBalanceRecord/saveRecharge?userId=${cmUser.userID}" method="post" class="form-horizontal">
+
 	<sys:message content="${message}"/>
 	<c:if test="${not empty cmUser}">
 		&nbsp;会所名称:${cmUser.userName}
 		<br>
+		<br>
 		&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;总余额:<fmt:formatNumber value="${empty cmUser.ableUserMoney ? 0:cmUser.ableUserMoney}" type="currency"/>
 	</c:if>
 	<br>
+	<br>
 	<font color='red'>*</font>充值金额:
-	<form:input path="amount" title="请输入此次充值的金额" value="" onchange="num(this)"></form:input>
-	<div id="isnumber" style="display: none">
-		<font color='red' style=" margin-left: 74px">只能输入大于0的数字</font>
-	</div>
-	<div id="isnull" style="display: none">
-		<font color='red' style=" margin-left: 74px">充值金额不能为空</font>
-	</div>
+	<form:input path="amount" title="*必填" value="" onchange="num(this)" class="short input-small required"></form:input>
+</br>
+	<br>
 	<%--<input id="" name="" title="请输入此次充值的金额" value="">--%>
-	&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;备注:&nbsp;<textarea id='remarks' name='remarks' rows='3' cols='4' style="width: 205px" maxlength="200"></textarea>
+	&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;备注:&nbsp;<textarea id='remarks' title="*必填" name='remarks' class="short input-small required" rows='3' cols='4' style="width: 205px" maxlength="200"></textarea>
+	<div class="form-actions">
+		<shiro:hasPermission name="user:cmSp:edit"><input id="btnSubmit" onclick="num()" class="btn btn-primary" type="submit" value="保 存"/>&nbsp;</shiro:hasPermission>
+		<input id="btnCancel" class="btn" type="button" value="返 回" onclick="history.go(-1)"/>
+	</div>
 </form:form>
+</div>
 </body>
-</html>
+</html>

+ 2 - 2
src/main/webapp/WEB-INF/views/modules/user/cmUserBalanceList.jsp

@@ -118,8 +118,8 @@
 					<td>
 						<a href="${ctx}/user/cmUserBalanceRecord/userBalanceRecord?userId=${cmUser.userID}" >查看详情</a>
 						<shiro:hasPermission name="balance:cmUserBalanceRecord:recharge">
-							<a href="javascript:void(0);" onclick="recharge('${cmUser.userID}')">充值</a>
-							<%--<font title="请使用充值订单的方式进行充值!">充值</font>--%>
+							<a href="${ctx}/user/cmUserBalanceRecord/recharge?userId=${cmUser.userID}">充值</a>
+							<%--<font title="请使用充值订单的方式进行充值!">充值</font>    onclick="recharge('${cmUser.userID}')"--%>
 						</shiro:hasPermission>
 						<shiro:hasPermission name="balance:cmUserBalanceWithdrawals:withdrawals">
 							<c:if test="${cmUser.ableUserMoney > 0}">

+ 1 - 1
src/main/webapp/WEB-INF/views/modules/user/cmUserBalanceWithdrawalsForm.jsp

@@ -117,4 +117,4 @@
 		</div>
 	</form:form>
 </body>
-</html>
+</html>

+ 979 - 818
src/main/webapp/WEB-INF/views/modules/user/newCmShopForm.jsp

@@ -1,60 +1,60 @@
 <%@ page contentType="text/html;charset=UTF-8" %>
-<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
+<%@ include file="/WEB-INF/views/include/taglib.jsp" %>
 <html>
 <head>
-	<title>供应商信息管理</title>
-	<meta name="decorator" content="default"/>
-<%--	<script src="/static/modules/bulkpurchase/loadAddressById.js"></script>--%>
-	<script type="text/javascript">
-		$(document).ready(function() {
-		loadProvince();
-			//$("#name").focus();
-			$("#inputForm").validate({
-				submitHandler: function(form){
-					debugger
-					var bindMobile = $("#contractMobile").val();
-					var userID = $("#userID").val();
-					$.post("${ctx}/new/user/agency/checkMobile?bindMobile="+bindMobile+"&userID="+userID, function (data) {
-						if (data.code == -1) {
-							alertx(data.msg);
-						}else {
-							loading('正在提交,请稍等...');
-							form.submit();
-						}
-					})
-				},
-				errorContainer: "#messageBox",
-				errorPlacement: function(error, element) {
-					$("#messageBox").text("输入有误,请先更正。");
-					if (element.is(":checkbox")||element.is(":radio")||element.parent().is(".input-append")){
-						error.appendTo(element.parent().parent());
-					} else {
-						error.insertAfter(element);
-					}
-				}
-			});
-		}
-		);
-
-		function checkMobile() {
-			var bindMobile = $("#contractMobile").val();
-			var userID = $("#userID").val();
-			$.post("${ctx}/new/user/agency/checkMobile?bindMobile="+bindMobile+"&userID="+userID, function (data) {
-				if (data.code == -1) {
-					alertx(data.msg);
-				}
-			})
-		}
-
-
-		// 初始化主营内容数据
+    <title>供应商信息管理</title>
+    <meta name="decorator" content="default"/>
+    <%--	<script src="/static/modules/bulkpurchase/loadAddressById.js"></script>--%>
+    <script type="text/javascript">
+        $(document).ready(function () {
+                loadProvince();
+                //$("#name").focus();
+                $("#inputForm").validate({
+                    submitHandler: function (form) {
+                        debugger
+                        var bindMobile = $("#contractMobile").val();
+                        var userID = $("#userID").val();
+                        $.post("${ctx}/new/user/agency/checkMobile?bindMobile=" + bindMobile + "&userID=" + userID, function (data) {
+                            if (data.code == -1) {
+                                alertx(data.msg);
+                            } else {
+                                loading('正在提交,请稍等...');
+                                form.submit();
+                            }
+                        })
+                    },
+                    errorContainer: "#messageBox",
+                    errorPlacement: function (error, element) {
+                        $("#messageBox").text("输入有误,请先更正。");
+                        if (element.is(":checkbox") || element.is(":radio") || element.parent().is(".input-append")) {
+                            error.appendTo(element.parent().parent());
+                        } else {
+                            error.insertAfter(element);
+                        }
+                    }
+                });
+            }
+        );
+
+        function checkMobile() {
+            var bindMobile = $("#contractMobile").val();
+            var userID = $("#userID").val();
+            $.post("${ctx}/new/user/agency/checkMobile?bindMobile=" + bindMobile + "&userID=" + userID, function (data) {
+                if (data.code == -1) {
+                    alertx(data.msg);
+                }
+            })
+        }
+
+
+        // 初始化主营内容数据
         $(function () {
-			var html = '';
-				html += '<span class="new-tag up-club-tag" data-typeName="产品">产品</span>',
-					html += '<span class="new-tag up-club-tag" data-typeName="仪器">仪器</span>',
-					html += '<span class="new-tag up-club-tag" data-typeName="服务">服务</span>',
-				$('#mainproArea').html(html);
-				$('.Main-content').show();
+            var html = '';
+            html += '<span class="new-tag up-club-tag" data-typeName="产品">产品</span>',
+                html += '<span class="new-tag up-club-tag" data-typeName="仪器">仪器</span>',
+                html += '<span class="new-tag up-club-tag" data-typeName="服务">服务</span>',
+                $('#mainproArea').html(html);
+            $('.Main-content').show();
 
             //主营项目
             var cMainProVal = $('#cMainPro').val();
@@ -96,26 +96,25 @@
         });
 
 
-
-		// 初始化服务类型
+        // 初始化服务类型
         $(function () {
-			var html = '';
-					html += '<span class="new-tag up-club-tag" data-typeName="仪器护理类">仪器护理类</span>',
-					html += '<span class="new-tag up-club-tag" data-typeName="护肤品类">护肤品类</span>',
-					html += '<span class="new-tag up-club-tag" data-typeName="纹绣类">纹绣类</span>',
-					html += '<span class="new-tag up-club-tag" data-typeName="美体内衣">美体内衣</span>',
-					html += '<span class="new-tag up-club-tag" data-typeName="整形耗材">整形耗材</span>',
-					html += '<span class="new-tag up-club-tag" data-typeName="国际品牌">国际品牌</span>',
-					html += '<span class="new-tag up-club-tag" data-typeName="美胸类">美胸类</span>',
-					html += '<span class="new-tag up-club-tag" data-typeName="健康保健类">健康保健类</span>',
-					html += '<span class="new-tag up-club-tag" data-typeName="减肥类">减肥类</span>',
-					html += '<span class="new-tag up-club-tag" data-typeName="面膜类">面膜类</span>',
-					html += '<span class="new-tag up-club-tag" data-typeName="抗衰老">抗衰老</span>',
-					html += '<span class="new-tag up-club-tag" data-typeName="生殖保养">生殖保养</span>',
-					html += '<span class="new-tag up-club-tag" data-typeName="健康养生">健康养生</span>',
-					html += '<span class="new-tag up-club-tag" data-typeName="纤体减肥">纤体减肥</span>',
-				$('#serviceArea').html(html);
-				$('.service-content').show();
+            var html = '';
+            html += '<span class="new-tag up-club-tag" data-typeName="仪器护理类">仪器护理类</span>',
+                html += '<span class="new-tag up-club-tag" data-typeName="护肤品类">护肤品类</span>',
+                html += '<span class="new-tag up-club-tag" data-typeName="纹绣类">纹绣类</span>',
+                html += '<span class="new-tag up-club-tag" data-typeName="美体内衣">美体内衣</span>',
+                html += '<span class="new-tag up-club-tag" data-typeName="整形耗材">整形耗材</span>',
+                html += '<span class="new-tag up-club-tag" data-typeName="国际品牌">国际品牌</span>',
+                html += '<span class="new-tag up-club-tag" data-typeName="美胸类">美胸类</span>',
+                html += '<span class="new-tag up-club-tag" data-typeName="健康保健类">健康保健类</span>',
+                html += '<span class="new-tag up-club-tag" data-typeName="减肥类">减肥类</span>',
+                html += '<span class="new-tag up-club-tag" data-typeName="面膜类">面膜类</span>',
+                html += '<span class="new-tag up-club-tag" data-typeName="抗衰老">抗衰老</span>',
+                html += '<span class="new-tag up-club-tag" data-typeName="生殖保养">生殖保养</span>',
+                html += '<span class="new-tag up-club-tag" data-typeName="健康养生">健康养生</span>',
+                html += '<span class="new-tag up-club-tag" data-typeName="纤体减肥">纤体减肥</span>',
+                $('#serviceArea').html(html);
+            $('.service-content').show();
 
             //服务类型
             var cServiceProVal = $('#cServicePro').val();
@@ -157,9 +156,7 @@
         });
 
 
-
-
-		//设置tags(主营和服务类型通用)
+        //设置tags(主营和服务类型通用)
         function setTags(opts) {
             var tagArr = [];
             opts.$mainPro.val('')
@@ -218,299 +215,303 @@
             })
         }
 
-// 审核
-$(document).on("change", "#auditStatus", function () {
-			if ($("#auditStatus").val() == 2) {
-				$("#auditNopass").show();
-			} else {
-				$("#auditNopass").hide();
-			}
-});
-
-/**
-* 供应商审核
-* */
-function auditShop(shopId,userId) {
-	var address = $("#address").val();
-	var name = $("#name").val();
-	var linkMan = $("#linkMan").val();
-	var contractMobile = $("#contractMobile").val();
-	var legalPerson = $("#legalPerson").val();
-	var registeredCapital = $("#registeredCapital").val();
-	var nature = $("#nature").val();
-	var turnover = $("#turnover").val();
-	var info = $('#info').val();
-	var productDesc = $('#productDesc').val();
-	var taxCertificate = $('#taxCertificate').val();
-	var businessLicenseImage = $('#businessLicenseImage').val();
-	alertx(businessLicenseImage)
-	if(null == address || "" == address){
-		alertx("请输入公司详细地址");
-		return;
-	}
-	if(null == name || "" == name){
-		alertx("请输入公司名称");
-		return;
-	}
-	if(null == linkMan || "" == linkMan){
-		alertx("请输入联系人名称");
-		return;
-	}
-	if(null == contractMobile || "" == contractMobile){
-		alertx("请输入联系人手机号");
-		return;
-	}
-	if(null == legalPerson || "" == legalPerson){
-		alertx("请输入法人代表");
-		return;
-	}
-	if(null == registeredCapital || "" == registeredCapital){
-		alertx("请输入注册资本");
-		return;
-	}
-	if(null == nature || "" == nature){
-		alertx("请输入公司性质");
-		return;
-	}
-	if(null == turnover || "" == turnover){
-		alertx("请输入年营业额");
-		return;
-	}
-	if(null == info || "" == info){
-		alertx("请输入公司简介");
-		return;
-	}
-	if(null == productDesc || "" == productDesc){
-		alertx("请输入主打产品说明");
-		return;
-	}
-	if(null == taxCertificate || "" == taxCertificate){
-		alertx("请输入营业执照编号");
-		return;
-	}
-	var html = "<div id='auditBox'>"
-                        + "   <div class='bd-row'>"
-                        + "       <span><font color='red'>*</font>审核:</span>"
-                        + "       <select name='auditStatus' id='auditStatus'>"
-                        + "           <option value='1'>审核通过</option>"
-                        + "           <option value='2'>审核未通过</option>"
-                        + "       <select/>"
-                        + "   </div>"
-                        + "   <div id='auditNopass' style='display: none;'>"
-                        + "       <div class='bd-row'>"
-                        + "           <span><font color='red'>*</font>原因:</span>"
-                        + "           <div class='auditCheckBox'>"
-                        + "               <label><input name='auditCheckBox' type='checkbox' value='入驻资质不达标'><span>入驻资质不达标</span></label>"
-                        + "               <label><input name='auditCheckBox' type='checkbox' value='品牌评估不通过'><span>品牌评估不通过</span></label>"
-                        + "               <label><input name='auditCheckBox' type='checkbox' value='相关证照不清晰'><span>相关证照不清晰</span></label>"
-                        + "               <label><input name='auditCheckBox' type='checkbox' value='企业经营异常'><span>企业经营异常</span></label>"
-                        + "               <label><input name='auditCheckBox' type='checkbox' value='其他'><span>其他</span></label>"
-                        + "           </div>"
-                        + "       </div>"
-                        + "       <div class='bd-row'>"
-                        + "           <span></span>"
-                        + "           <div class='auditNote'>"
-                        + "               <textarea name='auditNote' placeholder='可以补充其它原因,最多50个字'></textarea>"
-                        + "               <p class='err-tip' style='display:none;margin-left:-55px;color:red;'>请选择审核未通过的原因</p>"
-                        + "           </div>"
-                        + "       </div>"
-                        + "   </div>"
-                        + "</div>";
-                    var submit = function (v, h, f) {
-                        if (f.auditStatus == '') {
-                            $.jBox.tip("请选择状态", 'error', {focusId: "auditStatus"});
-                            return false;
-                        } else if (f.auditStatus == 2 && f.auditNote == '' && !f.auditCheckBox) {
-                            $.jBox.tip("请选择审核未通过的原因", 'error', {focusId: "auditNote"});
-                            return false;
-                        } else if (f.auditStatus == 2 && f.auditNote.length > 50) {
-                            $.jBox.tip("内容过长", 'error', {focusId: "auditNote"});
-                            return false;
-                        }
-                        var auditText = f.auditCheckBox ? (f.auditCheckBox.toString() + ',' + f.auditNote) : f.auditNote;
-
-                        $.post("${ctx}/user/newCmShop/auditShopInfo", {
-                            'auditStatus': f.auditStatus,
-                            'shopId': shopId,
-                            'userId': userId,
-                            'auditNote': auditText
-                        }, function (data) {
-                        console.log( data.success)
-                        console.log( true == data.success)
-                            if (true == data.success) {
-                                $.jBox.tip(data.msg, 'info');
-                                // $("#searchForm").submit();
-                                window.location.href = "${ctx}/user/newCmShop/";
-                            } else {
-                                $.jBox.tip(data.msg, 'error');
-                            }
-                        }, "JSON");//这里返回的类型有:json,html,xml,text
-                    };
-                    $.jBox(html, {title: "审核", submit: submit});
-}
-
-
-
-/**
- * 加载省份
- * @param curProvince
- */
-function loadProvince() {
-    var curProvince=$("#curProvince").val();
-    $.ajax({
-        type: 'POST',
-        dataType: 'json',
-        url: '/area/loadProvince',
-        success: function(data) {
-            $("#province").html("");
-            $("#province").append("<option value=''>省</option>");
-            for(var i=1; i<data.length; i++) {
-                if(curProvince != '' && curProvince != null && typeof(curProvince) != "undefined" && curProvince == data[i].name) {
-                    $("#province").append("<option value='" + data[i].id + "' provinceId=" + data[i].id +" selected>" + data[i].name +"</option>");
-                    $(".select2-chosen").eq(1).html(curProvince);
-                    loadCity($("#curCity").val());
-                } else {
-                    $("#province").append("<option value='" + data[i].id + "' provinceId=" + data[i].id +">" + data[i].name +"</option>");
-                }
+        // 审核
+        $(document).on("change", "#auditStatus", function () {
+            if ($("#auditStatus").val() == 2) {
+                $("#auditNopass").show();
+            } else {
+                $("#auditNopass").hide();
+            }
+        });
+
+        /**
+         * 供应商审核
+         * */
+        function auditShop(shopId, userId) {
+            var address = $("#address").val();
+            var name = $("#name").val();
+            var linkMan = $("#linkMan").val();
+            var contractMobile = $("#contractMobile").val();
+            var legalPerson = $("#legalPerson").val();
+            var registeredCapital = $("#registeredCapital").val();
+            var nature = $("#nature").val();
+            var turnover = $("#turnover").val();
+            var info = $('#info').val();
+            var productDesc = $('#productDesc').val();
+            var taxCertificate = $('#taxCertificate').val();
+            var businessLicenseImage = $('#businessLicenseImage').val();
+            alertx(businessLicenseImage)
+            if (null == address || "" == address) {
+                alertx("请输入公司详细地址");
+                return;
+            }
+            if (null == name || "" == name) {
+                alertx("请输入公司名称");
+                return;
+            }
+            if (null == linkMan || "" == linkMan) {
+                alertx("请输入联系人名称");
+                return;
+            }
+            if (null == contractMobile || "" == contractMobile) {
+                alertx("请输入联系人手机号");
+                return;
+            }
+            if (null == legalPerson || "" == legalPerson) {
+                alertx("请输入法人代表");
+                return;
+            }
+            if (null == registeredCapital || "" == registeredCapital) {
+                alertx("请输入注册资本");
+                return;
             }
+            if (null == nature || "" == nature) {
+                alertx("请输入公司性质");
+                return;
+            }
+            if (null == turnover || "" == turnover) {
+                alertx("请输入年营业额");
+                return;
+            }
+            if (null == info || "" == info) {
+                alertx("请输入公司简介");
+                return;
+            }
+            if (null == productDesc || "" == productDesc) {
+                alertx("请输入主打产品说明");
+                return;
+            }
+            if (null == taxCertificate || "" == taxCertificate) {
+                alertx("请输入营业执照编号");
+                return;
+            }
+            var html = "<div id='auditBox'>"
+                + "   <div class='bd-row'>"
+                + "       <span><font color='red'>*</font>审核:</span>"
+                + "       <select name='auditStatus' id='auditStatus'>"
+                + "           <option value='1'>审核通过</option>"
+                + "           <option value='2'>审核未通过</option>"
+                + "       <select/>"
+                + "   </div>"
+                + "   <div id='auditNopass' style='display: none;'>"
+                + "       <div class='bd-row'>"
+                + "           <span><font color='red'>*</font>原因:</span>"
+                + "           <div class='auditCheckBox'>"
+                + "               <label><input name='auditCheckBox' type='checkbox' value='入驻资质不达标'><span>入驻资质不达标</span></label>"
+                + "               <label><input name='auditCheckBox' type='checkbox' value='品牌评估不通过'><span>品牌评估不通过</span></label>"
+                + "               <label><input name='auditCheckBox' type='checkbox' value='相关证照不清晰'><span>相关证照不清晰</span></label>"
+                + "               <label><input name='auditCheckBox' type='checkbox' value='企业经营异常'><span>企业经营异常</span></label>"
+                + "               <label><input name='auditCheckBox' type='checkbox' value='其他'><span>其他</span></label>"
+                + "           </div>"
+                + "       </div>"
+                + "       <div class='bd-row'>"
+                + "           <span></span>"
+                + "           <div class='auditNote'>"
+                + "               <textarea name='auditNote' placeholder='可以补充其它原因,最多50个字'></textarea>"
+                + "               <p class='err-tip' style='display:none;margin-left:-55px;color:red;'>请选择审核未通过的原因</p>"
+                + "           </div>"
+                + "       </div>"
+                + "   </div>"
+                + "</div>";
+            var submit = function (v, h, f) {
+                if (f.auditStatus == '') {
+                    $.jBox.tip("请选择状态", 'error', {focusId: "auditStatus"});
+                    return false;
+                } else if (f.auditStatus == 2 && f.auditNote == '' && !f.auditCheckBox) {
+                    $.jBox.tip("请选择审核未通过的原因", 'error', {focusId: "auditNote"});
+                    return false;
+                } else if (f.auditStatus == 2 && f.auditNote.length > 50) {
+                    $.jBox.tip("内容过长", 'error', {focusId: "auditNote"});
+                    return false;
+                }
+                var auditText = f.auditCheckBox ? (f.auditCheckBox.toString() + ',' + f.auditNote) : f.auditNote;
+
+                $.post("${ctx}/user/newCmShop/auditShopInfo", {
+                    'auditStatus': f.auditStatus,
+                    'shopId': shopId,
+                    'userId': userId,
+                    'auditNote': auditText
+                }, function (data) {
+                    console.log(data.success)
+                    console.log(true == data.success)
+                    if (true == data.success) {
+                        $.jBox.tip(data.msg, 'info');
+                        // $("#searchForm").submit();
+                        window.location.href = "${ctx}/user/newCmShop/";
+                    } else {
+                        $.jBox.tip(data.msg, 'error');
+                    }
+                }, "JSON");//这里返回的类型有:json,html,xml,text
+            };
+            $.jBox(html, {title: "审核", submit: submit});
         }
 
-    });
 
-    $.ajax({
-        type:'Get',
-        success:function (date) {
-        }
-    });
-}
-
-/**
- * 加载城市
- */
-function loadCity(curCity) {
-    var provinceId = $("#province option:selected").attr("provinceId");
-
-    $("#town").html("");
-    $(".select2-chosen").eq(3).html("区");
-    $("#town").append("<option value=''>区</option>");
-
-    if(typeof(provinceId) != "undefined") {
-        $.ajax({
-            type: 'POST',
-            dataType: 'json',
-            data: {'provinceId':provinceId},
-            url: '/area/loadCity',
-            success: function(data) {
-                $(".select2-chosen").eq(2).html("市");
-                $("#city").html("");
-                $("#city").append("<option value=''>市</option>");
-                for(var i=0; i<data.length; i++) {
-                    if(curCity != null && typeof(curCity) != "undefined" && curCity == data[i].name) {
-                        $("#city").append("<option value='" + data[i].id + "' selected cityId=" + data[i].id +">" + data[i].name +"</option>");
-                        $(".select2-chosen").eq(2).html(curCity);
-                        loadTown($("#curTown").val());
-                    } else {
-                        $("#city").append("<option value='" + data[i].id + "' cityId=" + data[i].id +">" + data[i].name +"</option>");
+        /**
+         * 加载省份
+         * @param curProvince
+         */
+        function loadProvince() {
+            var curProvince = $("#curProvince").val();
+            $.ajax({
+                type: 'POST',
+                dataType: 'json',
+                url: '/area/loadProvince',
+                success: function (data) {
+                    $("#province").html("");
+                    $("#province").append("<option value=''>省</option>");
+                    for (var i = 1; i < data.length; i++) {
+                        if (curProvince != '' && curProvince != null && typeof (curProvince) != "undefined" && curProvince == data[i].name) {
+                            $("#province").append("<option value='" + data[i].id + "' provinceId=" + data[i].id + " selected>" + data[i].name + "</option>");
+                            $(".select2-chosen").eq(1).html(curProvince);
+                            loadCity($("#curCity").val());
+                        } else {
+                            $("#province").append("<option value='" + data[i].id + "' provinceId=" + data[i].id + ">" + data[i].name + "</option>");
+                        }
                     }
+                }
 
+            });
 
+            $.ajax({
+                type: 'Get',
+                success: function (date) {
                 }
-            }
+            });
+        }
+
+        /**
+         * 加载城市
+         */
+        function loadCity(curCity) {
+            var provinceId = $("#province option:selected").attr("provinceId");
+
+            $("#town").html("");
+            $(".select2-chosen").eq(3).html("区");
+            $("#town").append("<option value=''>区</option>");
+
+            if (typeof (provinceId) != "undefined") {
+                $.ajax({
+                    type: 'POST',
+                    dataType: 'json',
+                    data: {'provinceId': provinceId},
+                    url: '/area/loadCity',
+                    success: function (data) {
+                        $(".select2-chosen").eq(2).html("市");
+                        $("#city").html("");
+                        $("#city").append("<option value=''>市</option>");
+                        for (var i = 0; i < data.length; i++) {
+                            if (curCity != null && typeof (curCity) != "undefined" && curCity == data[i].name) {
+                                $("#city").append("<option value='" + data[i].id + "' selected cityId=" + data[i].id + ">" + data[i].name + "</option>");
+                                $(".select2-chosen").eq(2).html(curCity);
+                                loadTown($("#curTown").val());
+                            } else {
+                                $("#city").append("<option value='" + data[i].id + "' cityId=" + data[i].id + ">" + data[i].name + "</option>");
+                            }
+
+
+                        }
+                    }
+
+                });
+            } else {
+                $("#city").html("");
+                $(".select2-chosen").eq(2).html("市");
+                $("#city").append("<option value=''>市</option>");
 
-        });
-    } else {
-        $("#city").html("");
-        $(".select2-chosen").eq(2).html("市");
-        $("#city").append("<option value=''>市</option>");
-
-        $("#town").html("");
-        $(".select2-chosen").eq(3).html("区");
-        $("#town").append("<option value=''>区</option>");
-    }
-}
-
-/**
- * 加载县区
- * @param curTown
- */
-function loadTown(curTown) {
-    var cityId = $("#city option:selected").attr("cityId");
-    if(typeof(cityId) != "undefined") {
-        $.ajax({
-            type: 'POST',
-            dataType: 'json',
-            data: {'cityId':cityId},
-            url: '/area/loadTown',
-            success: function(data) {
-                $(".select2-chosen").eq(3).html("区");
                 $("#town").html("");
+                $(".select2-chosen").eq(3).html("区");
                 $("#town").append("<option value=''>区</option>");
-                for(var i=0; i<data.length; i++) {
-                    if(curTown != null && typeof(curTown) != "undefined" && curTown == data[i].name) {
-                        $("#town").append("<option value='" + data[i].id + "' selected>" + data[i].name +"</option>");
-                        $(".select2-chosen").eq(3).html(curTown);
-                    } else {
-                        $("#town").append("<option value='" + data[i].id + "'>" + data[i].name +"</option>");
+            }
+        }
+
+        /**
+         * 加载县区
+         * @param curTown
+         */
+        function loadTown(curTown) {
+            var cityId = $("#city option:selected").attr("cityId");
+            if (typeof (cityId) != "undefined") {
+                $.ajax({
+                    type: 'POST',
+                    dataType: 'json',
+                    data: {'cityId': cityId},
+                    url: '/area/loadTown',
+                    success: function (data) {
+                        $(".select2-chosen").eq(3).html("区");
+                        $("#town").html("");
+                        $("#town").append("<option value=''>区</option>");
+                        for (var i = 0; i < data.length; i++) {
+                            if (curTown != null && typeof (curTown) != "undefined" && curTown == data[i].name) {
+                                $("#town").append("<option value='" + data[i].id + "' selected>" + data[i].name + "</option>");
+                                $(".select2-chosen").eq(3).html(curTown);
+                            } else {
+                                $("#town").append("<option value='" + data[i].id + "'>" + data[i].name + "</option>");
+                            }
+
+
+                        }
                     }
 
+                });
+            } else {
+                $("#town").html("");
+                $(".select2-chosen").eq(3).html("区");
+                $("#town").append("<option value=''>区</option>");
+            }
+        }
 
-                }
+        //初始化商品类型
+        $(function () {
+            changeMaintenceFee();
+            secondShop();
+            medicalPractice();
+        })
+
+
+        function changeMaintenceFee() {
+            var val = $("#maintenanceFee").val();
+            // 1已缴纳,0未缴纳
+            if (val == '1') {
+                val = "0";
+                $(".maintenanceDate1").show();
+            } else if (val == '0') {
+                $(".maintenanceDate1").hide();
             }
+        }
 
-        });
-    } else {
-        $("#town").html("");
-        $(".select2-chosen").eq(3).html("区");
-        $("#town").append("<option value=''>区</option>");
-    }
-}
-
-	//初始化商品类型
-    $(function () {
-        changeMaintenceFee();
-		secondShop();
-		medicalPractice();
-    })
-
- function changeMaintenceFee(){
-	var val = $("#maintenanceFee").val();
-        // 1已缴纳,0未缴纳
-        if(val == '1'){
-			val="0";
-            $(".maintenanceDate1").show();
-        }else if(val == '0'){
-            $(".maintenanceDate1").hide();
+        //医疗类型的显示
+        function secondShop() {
+            var firstShopType = $("input[name='firstShopType']:checked").val();
+            if (firstShopType == 1) {
+                $("#secondShopType").show();
+            } else {
+                $("#secondShopType").hide();
+            }
         }
- }
-//医疗类型的显示
- function secondShop() {
-	 var firstShopType = $("input[name='firstShopType']:checked").val();
-	 if (firstShopType == 1){
-	 	$("#secondShopType").show();
-	 }else {
-		 $("#secondShopType").hide();
-	 }
- }
-
- //三类器械医疗许可证显示
-	function medicalPractice() {
-		var secondShopType = $("input[name='secondShopType']:checked").val();
-		if (secondShopType == 3){
-			$("#medicalPracticeLicenseImg").show();
-		}else {
-			$("#medicalPracticeLicenseImg").hide();
-		}
-	}
-	</script>
-	<style>
-		.control-group table{margin: 10px}
-		.control-group td > span {
-			min-width: 100px;
-			display: inline-block;
-			text-align: right;
-			}
-
-		#auditBox .auditCheckBox {
+
+        //三类器械医疗许可证显示
+        function medicalPractice() {
+            var secondShopType = $("input[name='secondShopType']:checked").val();
+            if (secondShopType == 3) {
+                $("#medicalPracticeLicenseImg").show();
+            } else {
+                $("#medicalPracticeLicenseImg").hide();
+            }
+        }
+    </script>
+    <style>
+        .control-group table {
+            margin: 10px
+        }
+
+        .control-group td > span {
+            min-width: 100px;
+            display: inline-block;
+            text-align: right;
+        }
+
+        #auditBox .auditCheckBox {
             width: 250px;
             margin: 0 auto;
         }
@@ -530,16 +531,18 @@ function loadTown(curTown) {
             border: 1px solid #666;
             border-radius: 5px;
         }
-		.auditNote{
-			width: 250px;
-			height: 50px;
-			margin: 0 auto;
-		}
+
+        .auditNote {
+            width: 250px;
+            height: 50px;
+            margin: 0 auto;
+        }
+
         #auditBox .auditCheckBox input:checked + span {
             background-color: #E6633A
         }
 
-                .control-group .new-tag {
+        .control-group .new-tag {
             display: inline-block;
             width: 78px;
             height: 30px;
@@ -560,20 +563,20 @@ function loadTown(curTown) {
             color: #e15616;
         }
 
-		#secondShopTypeArea {
-			margin: 0px 0px 0px 98px;
-			display: inline-block;
-			width: 620px;
-		}
+        #secondShopTypeArea {
+            margin: 0px 0px 0px 98px;
+            display: inline-block;
+            width: 620px;
+        }
 
         #mainproArea {
-        	margin: 0px 0px 0px 98px;
+            margin: 0px 0px 0px 98px;
             display: inline-block;
             width: 620px;
         }
 
         #serviceArea {
-        	margin: 0px 0px 0px 98px;
+            margin: 0px 0px 0px 98px;
             display: inline-block;
             width: 620px;
         }
@@ -584,6 +587,7 @@ function loadTown(curTown) {
             vertical-align: middle;
             margin: 0px 0px 0px -55px;
         }
+
         #mainproOther {
             height: 40px;
             line-height: 40px;
@@ -617,468 +621,625 @@ function loadTown(curTown) {
             vertical-align: middle;
             display: none;
         }
-        .form-horizontal .controls{margin-left:0}
-        #increase,#decrease,.lineNum{width:30px;height:30px}
-        .lineNum{text-align:center}
-        .dateInput input{width:150px}
-        .clause span{margin-left:30px}
-        #productTable th{text-align:center;white-space:nowrap}
-        #productTable td{text-align:center;white-space:nowrap}
-        .controls{font-size:0}
-        .controls .conList{display:inline-block;margin-right:15px}
-        .conList .btn:nth-of-type(1){margin-left:25px}
-        .select2-choice{width:100px}
-        .upload-content{margin-top:-70px;display:inline-block}
-        .upload-content .conList .btn:nth-of-type(1){width:90px;height:100px;border:1px solid #eee;background:#fff;position:relative}
-        .upload-content .conList .btn:nth-of-type(1)>div{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);color:#666}
-        .upload-content .conList .btn:nth-of-type(1) span{font-size:35px}
-        .upload-content .conList .btn:nth-of-type(1) h5{color:#666}
-        .cancel-upload{background:transparent;border:none;box-shadow:none;position:relative;top:-38px;left:-25px;cursor:pointer;z-index:100}
-        .upload-content .conList ol li{width:114px;min-height:80px;text-align:center;background:#fff;position:relative;top:120px}
-        .hide-pic{display:none !important}
-        .upload-tips{margin:10px 0}
-	</style>
+
+        .form-horizontal .controls {
+            margin-left: 0
+        }
+
+        #increase, #decrease, .lineNum {
+            width: 30px;
+            height: 30px
+        }
+
+        .lineNum {
+            text-align: center
+        }
+
+        .dateInput input {
+            width: 150px
+        }
+
+        .clause span {
+            margin-left: 30px
+        }
+
+        #productTable th {
+            text-align: center;
+            white-space: nowrap
+        }
+
+        #productTable td {
+            text-align: center;
+            white-space: nowrap
+        }
+
+        .controls {
+            font-size: 0
+        }
+
+        .controls .conList {
+            display: inline-block;
+            margin-right: 15px
+        }
+
+        .conList .btn:nth-of-type(1) {
+            margin-left: 25px
+        }
+
+        .select2-choice {
+            width: 100px
+        }
+
+        .upload-content {
+            margin-top: -70px;
+            display: inline-block
+        }
+
+        .upload-content .conList .btn:nth-of-type(1) {
+            width: 90px;
+            height: 100px;
+            border: 1px solid #eee;
+            background: #fff;
+            position: relative
+        }
+
+        .upload-content .conList .btn:nth-of-type(1) > div {
+            position: absolute;
+            top: 50%;
+            left: 50%;
+            transform: translate(-50%, -50%);
+            color: #666
+        }
+
+        .upload-content .conList .btn:nth-of-type(1) span {
+            font-size: 35px
+        }
+
+        .upload-content .conList .btn:nth-of-type(1) h5 {
+            color: #666
+        }
+
+        .cancel-upload {
+            background: transparent;
+            border: none;
+            box-shadow: none;
+            position: relative;
+            top: -38px;
+            left: -25px;
+            cursor: pointer;
+            z-index: 100
+        }
+
+        .upload-content .conList ol li {
+            width: 114px;
+            min-height: 80px;
+            text-align: center;
+            background: #fff;
+            position: relative;
+            top: 120px
+        }
+
+        .hide-pic {
+            display: none !important
+        }
+
+        .upload-tips {
+            margin: 10px 0
+        }
+    </style>
 </head>
 <body>
-	<ul class="nav nav-tabs">
-		<li><a href="${ctx}/user/newCmShop/">供应商信息列表</a></li>
-		<li class="active"><a href="${ctx}/user/newCmShop/form?id=${newCmShop.shopID}&userID=${newCmShop.userID}&editStatus=${newCmShop.editStatus}">供应商信息<shiro:hasPermission name="user:newCmShop:edit">${not empty newCmShop.shopID?'编辑':'添加'}</shiro:hasPermission><shiro:lacksPermission name="user:newCmShop:edit">查看</shiro:lacksPermission></a></li>
-	</ul><br/>
-	<form:form id="inputForm" modelAttribute="newCmShop" action="${ctx}/user/newCmShop/save?userID=${newCmShop.userID}" method="post" class="form-horizontal">
-		<form:hidden path="shopID"/>
-		<form:hidden path="userID" />
-		<sys:message content="${message}"/>
-		<div class="control-group">
-			<table>
-				<tr>
-					<td>
-					<span><b>状态:</b></span>
-						<c:if test="${newCmShop.status eq 3}">
-							<font color="black">待审核</font>
-						</c:if>
-						<c:if test="${newCmShop.status eq 90}">
-							<font color="green">已上线</font>
-						</c:if>
-						<c:if test="${newCmShop.status eq 91}">
-							<font color="red">已下线</font>
-						</c:if>
-						<c:if test="${newCmShop.status eq 92}">
-							<font color="red" style="border-bottom: red">审核未通过</font>
-						</c:if>
-						</td>
-
-					<td >&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
-					<span><b><font color="red">*</font>是否已缴纳维护费:</b></span>
-						<form:select path="maintenanceFee" class="input-medium required" onclick="changeMaintenceFee()">
-								<form:option value="" label="请选择"/>
-								<form:option value="1" label="已缴纳"/>
-								<form:option value="0" label="未缴纳"/>
-						</form:select>
-					</td>
-					<td >&nbsp;&nbsp;
-						<span class="maintenanceDate1">
+<ul class="nav nav-tabs">
+    <li><a href="${ctx}/user/newCmShop/">供应商信息列表</a></li>
+    <li class="active"><a
+            href="${ctx}/user/newCmShop/form?id=${newCmShop.shopID}&userID=${newCmShop.userID}&editStatus=${newCmShop.editStatus}">供应商信息<shiro:hasPermission
+            name="user:newCmShop:edit">${not empty newCmShop.shopID?'编辑':'添加'}</shiro:hasPermission><shiro:lacksPermission
+            name="user:newCmShop:edit">查看</shiro:lacksPermission></a></li>
+</ul>
+<br/>
+<form:form id="inputForm" modelAttribute="newCmShop" action="${ctx}/user/newCmShop/save?userID=${newCmShop.userID}"
+           method="post" class="form-horizontal">
+    <form:hidden path="shopID"/>
+    <form:hidden path="userID"/>
+    <sys:message content="${message}"/>
+    <div class="control-group">
+        <table>
+            <tr>
+                <td>
+                    <span><b>状态:</b></span>
+                    <c:if test="${newCmShop.status eq 3}">
+                        <font color="black">待审核</font>
+                    </c:if>
+                    <c:if test="${newCmShop.status eq 90}">
+                        <font color="green">已上线</font>
+                    </c:if>
+                    <c:if test="${newCmShop.status eq 91}">
+                        <font color="red">已下线</font>
+                    </c:if>
+                    <c:if test="${newCmShop.status eq 92}">
+                        <font color="red" style="border-bottom: red">审核未通过</font>
+                    </c:if>
+                </td>
+
+                <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
+                    <span><b><font color="red">*</font>是否已缴纳维护费:</b></span>
+                    <form:select path="maintenanceFee" class="input-medium required" onclick="changeMaintenceFee()">
+                        <form:option value="" label="请选择"/>
+                        <form:option value="1" label="已缴纳"/>
+                        <form:option value="0" label="未缴纳"/>
+                    </form:select>
+                </td>
+                <td>&nbsp;&nbsp;
+                    <span class="maintenanceDate1">
 							<span><b>缴纳时间:</b></span>
-							<form:input path="maintenanceDate" type="text" maxlength="21" class="input-medium Wdate" value="${maintenanceDate}"
-							onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:false});"/>
+							<form:input path="maintenanceDate" type="text" maxlength="21" class="input-medium Wdate"
+                                        value="${maintenanceDate}"
+                                        onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:false});"/>
 						</span>
-					</td>
-            	</tr>
-			</table>
-		</div>
-		<div class="control-group">
-			<tr>
-				<th><b>分账商户号:</b></th>
-				<td colspan="3" class="params">
-					<div id="addParamsItems">
-							<%--相关参数层--%>
-						<input type="hidden" value="${fn:length(newCmShop.splitCodes)}"
-							   id="productParametersLength">
-						<c:forEach items="${newCmShop.splitCodes}" var="item" varStatus="varIndex">
-							<div id="paramsItem" class="paramsItem">
-								&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<form:input path="splitCodes[${varIndex.index}].splitCode" id="paramsName"
-											maxlength="8" placeholder="请输入分帐商户号" class="input-small"/>
-								<form:input path="splitCodes[${varIndex.index}].codeRemark" id="paramsContent"
-											maxlength="10" placeholder="请输入账户备注"
-											class="input-small"/>
-								<span type="button" style="cursor: pointer;color: #0B61A4"
-									  onclick="deleteParams(this)">删除</span>
-							</div>
-						</c:forEach>
-					</div>
-					&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<button class="addParams" onclick="return false">添加分帐号</button>
-				</td>
-			</tr>
-		</div>
-		<div class="control-group">
-			<b>公司基本信息</b>
-			<table style="border-collapse: separate; border-spacing: 10px; ">
-				<tr>
-					<td>
-					<span><font color="red">*</font>公司名称:</span>
-						<form:input path="name" htmlEscape="false" placeholder="请与营业执照的注册名称保持一致" maxlength="30" class="input-xlarge required"/>
-					</td>
-					<td>
-					<span>公司简称:</span>
-						<form:input path="sname" htmlEscape="false" placeholder="请输入公司简称" maxlength="10" class="input-xlarge"/>
-					</td>
-				</tr>
-				<tr>
-					<td>
-					<input type="hidden" id="curProvince" name="curProvince" value="${newCmShop.province }">
-					<input type="hidden" id="curCity" name="curCity" value="${newCmShop.city }">
-					<input type="hidden" id="curTown" name="curTown" value="${newCmShop.town }">
-						<span><font color="red">*</font>公司地址:</span>
-						<form:select path="provinceID" class="input-xlarge required" id="province"
-                                     onchange="loadCity()" style="width:100px;">
-                            <form:option value="" label="省" provinceId=""/>
-                        </form:select>&nbsp;&nbsp;
-                        <form:select path="cityID" class="input-xlarge required" id="city" onchange="loadTown()"
-                                     style="width:100px;">
-                            <form:option value="" label="市" cityId=""/>
-                        </form:select>&nbsp;&nbsp;
-                        <form:select path="townID" class="input-xlarge required" id="town" style="width:100px;">
-                            <form:option value="" label="区"/>
-                        </form:select>&nbsp;&nbsp;
-						<form:input path="address" htmlEscape="false" placeholder="请输入公司详细地址" maxlength="25" class="input-xlarge required"/>
-					</td>
-				</tr>
-
-				<tr>
-					<td>
-						<span><font color="red">*</font>联系人:</span>
-						<form:input path="linkMan" htmlEscape="false" placeholder="请输入机构联系人名称" maxlength="6" class="input-xlarge required"/>
-					</td>
-					<td>
-						<span><font color="red">*</font>手机号:</span>
-						<form:input path="contractMobile" onchange="checkMobile()" htmlEscape="false" maxlength="11" placeholder="请输入联系人常用手机号码" class="input-xlarge number required" />
-					</td>
-					<td>
-						<span>邮箱:</span>
-						<form:input path="email" htmlEscape="false" placeholder="请输入邮箱地址" class="input-xlarge "/>
-					</td>
-				</tr>
-
-				<tr>
-					<td>
-						<span>固定电话:</span>
-						<form:input path="contractPhone" htmlEscape="false" maxlength="15" placeholder="请在号码前加区号" class="input-xlarge"/>
-					</td>
-					<td>
-						<span>传    真:</span>
-						<form:input path="fax" htmlEscape="false" placeholder="请输入公司传真号" class="input-xlarge "/>
-					</td>
-				</tr>
-
-				<tr>
-					<td>
-						<span>法人代表:</span>
-						<form:input path="legalPerson" htmlEscape="false" placeholder="请输入法人代表姓名"  class="input-xlarge "/>
-					</td>
-					<td>
-						<span>注册资本:</span>
-						¥<form:input path="registeredCapital" htmlEscape="false" maxlength="11" placeholder="请填写公司注册资本" class="input-xlarge number "/>
-					</td>
-					<td>
-						<span>公司性质:</span>
-						<form:input path="nature" htmlEscape="false" maxlength="50" placeholder="请填写公司性质" class="input-xlarge "/>
-					</td>
-				</tr>
-
-				<tr>
-					<td>
-						<span>年营业额:</span>
-						<form:input path="turnover" htmlEscape="false" placeholder="请输入公司年营业额" maxlength="11" class="input-xlarge number "/>
-					</td>
-				</tr>
-			</table>
-		</div>
-		</div>
-		<div class="control-group">
-		<b>公司经营信息</b>
-			<table style="border-collapse: separate; border-spacing: 10px; ">
-				<tr>
-					<td>
-						<span><font color="red">*</font>公司类型:</span>
-						<form:radiobutton path="firstShopType" value="1" label="医疗" class="required" onclick="secondShop()"/>
-						<form:radiobutton path="firstShopType" value="2" label="非医疗"  class="required" onclick="secondShop()"/>
-					</td>
-				</tr>
-				<tr id="secondShopType" hidden="hidden">
-					<td>
-						<span><font color="red">*</font>医疗类型:</span>
-						<div class="control-group Main-content">
-							<div class="tags-area" id="secondShopTypeArea">
-								<form:radiobutton path="secondShopType" value="1" label="一类器械" class="required" onclick="medicalPractice()"/>&nbsp;&nbsp;
-								<form:radiobutton path="secondShopType" value="2" label="二类器械"  class="required" onclick="medicalPractice()"/>&nbsp;&nbsp;
-								<form:radiobutton path="secondShopType" value="3" label="三类器械"  class="required" onclick="medicalPractice()"/>&nbsp;&nbsp;
-								<form:radiobutton path="secondShopType" value="4" label="其他"  class="required" onclick="medicalPractice()"/>
-							</div>
-						</div>
-					</td>
-				</tr>
-
-				<tr id="medicalPracticeLicenseImg" hidden="hidden">
-					<td>
-						<table>
-							<tr>
-								<td>
-									<font color="red">*</font>医疗执业许可证:
-								</td>
-								<td>
-									<form:hidden id="medicalPracticeLicenseImg1" path="medicalPracticeLicenseImg1"
-												 htmlEscape="false" maxlength="255" class="input-xlarge required"/>
-									<sys:ckfinder input="medicalPracticeLicenseImg1" type="images" uploadPath="/photo"
-												  selectMultiple="false" maxWidth="100" maxHeight="100"/>
-								</td>
-								<td>
-									<form:hidden id="medicalPracticeLicenseImg2" path="medicalPracticeLicenseImg2"
-												 htmlEscape="false" maxlength="255" class="input-xlarge"/>
-									<sys:ckfinder input="medicalPracticeLicenseImg2" type="images" uploadPath="/photo"
-												  selectMultiple="false" maxWidth="100" maxHeight="100"/>
-								</td>
-								<td>
-									<form:hidden id="medicalPracticeLicenseImg3" path="medicalPracticeLicenseImg3"
-												 htmlEscape="false" maxlength="255" class="input-xlarge"/>
-									<sys:ckfinder input="medicalPracticeLicenseImg3" type="images" uploadPath="/photo"
-												  selectMultiple="false" maxWidth="100" maxHeight="100"/>
-								</td>
-							</tr>
-						</table>
-					</td>
-				</tr>
-
-				<tr>
-					<td>
-						<span><font color="red">*</font>主营内容:</span>
-						<div class="control-group Main-content">
-							<div class="tags-area" id="mainproArea"></div>
-							<span class="err-tip" style="display: inline-block;margin-left:-55px;"></span>
-							<input type="hidden" name="mainpro" value="${newCmShop.mainpro}" id="cMainPro">
-							<div class="tags-operate">
-							<span class="new-tag tag-other" id="mainproOther">其他</span>
-							<input type="text" class="reg-input tag-input" id="mainproInput" placeholder="请输入自定义品项目"
-								   maxlength="5">
-							<span class="new-tag tag-add" id="mainproAdd">确认添加</span>
-							</div>
-                		</div>
-					</td>
-				</tr>
-
-				<tr>
-					<td>
-						<span><font color="red">*</font>经营范围:</span>
-						<div class="control-group service-content">
-							<div class="tags-area" id="serviceArea"></div>
-							<span class="err-tip" style="display: inline-block;margin-left:-55px;"></span>
-							<input type="hidden" name="businessScope" value="${newCmShop.businessScope}" id="cServicePro">
-							<div class="tags-operate">
-							<span class="new-tag tag-other" id="serviceOther">其他</span>
-							<input type="text" class="reg-input tag-input" id="serviceInput" placeholder="请输入自定义品项目"
-								   maxlength="5">
-							<span class="new-tag tag-add" id="serviceAdd">确认添加</span>
-							</div>
-                		</div>
-					</td>
-				</tr>
-				<tr>
-					<td>
-						<span style="min-width: 130px;">官网地址:</span>
-						<form:input path="website" htmlEscape="false" maxlength="100" placeholder="请输入网址" class="input-xlarge"/>
-					</td>
-				</tr>
-				<tr>
-					<td>
-						<span style="min-width: 130px;">微信公众号:</span>
-						<form:input path="wxOfficialAccount" htmlEscape="false" maxlength="20" placeholder="请输入微信公众号名称" class="input-xlarge"/>
-					</td>
-				</tr>
-				<tr>
-					<td>
-						<span style="min-width: 130px;">微信小程序:</span>
-						<form:input path="wxApplets" htmlEscape="false" maxlength="20" placeholder="请输入微信小程序名称" class="input-xlarge"/>
-					</td>
-				</tr>
-				<tr>
-					<td>
-						<span style="min-width: 130px;"><font color="red">*</font>主打系列商品说明:</span>
-						<form:textarea path="productDesc" htmlEscape="false" style="margin: 0px; width: 600px; height: 120px;" maxlength="5000" placeholder="请输入公司主打系列商品说明" class="input-xlarge required"/>
-					</td>
-				</tr>
-				<tr>
-					<td>
-						<span style="min-width: 130px;"><font color="red">*</font>公司介绍:</span>
-						<form:textarea path="info" htmlEscape="false"  style="margin: 0px; width: 600px; height: 120px;" maxlength="5000" placeholder="公司介绍会展示在公司主页,有助于机构更好的了解您公司, 建议从规模、产品、服务、荣誉资质这4方面进行介绍" class="input-xlarge required"/>
-					</td>
-				</tr>
-			</table>
-		</div>
-
-		<div class="control-group">
-			<b>公司资质认证</b>
-			<br><font color="red">注意:请上传jpg/png格式的图片,最大不超过5M。</font>
-			<table>
-					<tr>
-						<td>
-							<span><font color="red">*</font>营业执照编号:</span>
-								<form:input path="socialCreditCode" htmlEscape="false" placeholder="请输入营业执照编号" maxlength="18" class="input-xlarge required"/>
-						</td>
-					</tr>
-			</table>
-			<table>
-
-				<tr>
-					<td><span><font color="red">*</font>营业执照图片:</span></td>
-					<td>
-						<form:hidden id="businessLicenseImage" path="businessLicenseImage" htmlEscape="false" maxlength="255" class="input-xlarge required"/>
-						<sys:ckfinder input="businessLicenseImage" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-						<br><span><font color="#a9a9a9">营业执照</font></span>
-					</td>
-					<td><span><font color="red">*</font>公司LOGO:</span></td>
-					<td>
-						<form:hidden id="logo" path="logo" htmlEscape="false" maxlength="255" class="input-xlarge required"/>
-						<sys:ckfinder input="logo" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-						<br><span><font color="#a9a9a9">公司LOGO</font></span>
-					</td>
-				</tr>
-			</table>
-		</div>
-
-		<div class="control-group">
-			<table>
-				<tr>
-					<td>
-							<span><font color="red">*</font>资质认证:</span>
-					</td>
-					<td>
-							<form:hidden id="productionLicense" path="productionLicense" htmlEscape="false" maxlength="255" class="input-xlarge required"/>
-							<sys:ckfinder input="productionLicense" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-							<br><span><font color="#a9a9a9">生产许可证</font></span>
-					</td>
-					<td>
-							<form:hidden id="sanitationPermit" path="sanitationPermit" htmlEscape="false" maxlength="255" class="input-xlarge required"/>
-							<sys:ckfinder input="sanitationPermit" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-							<br><span><font color="#a9a9a9">卫生许可证</font></span>
-					</td>
-					<td>
-							<form:hidden id="taxPermit" path="taxPermit" htmlEscape="false" maxlength="255" class="input-xlarge required"/>
-							<sys:ckfinder input="taxPermit" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-							<br><span><font color="#a9a9a9">税务许可证</font></span>
-					</td>
-				</tr>
-			</table>
-		</div>
-
-		<div class="control-group">
-			<table>
-				<tr>
-					<td>
-							<span>荣誉证书:</span>
-					</td>
-					<td>
-							<form:hidden id="honorCertificate1" path="honorCertificate1" htmlEscape="false" maxlength="255" class="input-xlarge"/>
-							<sys:ckfinder input="honorCertificate1" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-					</td>
-					<td>
-							<form:hidden id="honorCertificate2" path="honorCertificate2" htmlEscape="false" maxlength="255" class="input-xlarge"/>
-							<sys:ckfinder input="honorCertificate2" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-					</td>
-					<td>
-							<form:hidden id="honorCertificate3" path="honorCertificate3" htmlEscape="false" maxlength="255" class="input-xlarge"/>
-							<sys:ckfinder input="honorCertificate3" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-					</td>
-					<td>
-							<form:hidden id="honorCertificate4" path="honorCertificate4" htmlEscape="false" maxlength="255" class="input-xlarge"/>
-							<sys:ckfinder input="honorCertificate4" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-					</td>
-					<td>
-							<form:hidden id="honorCertificate5" path="honorCertificate5" htmlEscape="false" maxlength="255" class="input-xlarge"/>
-							<sys:ckfinder input="honorCertificate5" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-					</td>
-
-						<%--<div class="controls upload-content">
-							<div class="conList">
-									<form:hidden id="honorCertificate1" path="honorCertificate1" htmlEscape="false" maxlength="255" class="input-xlarge"/>
-									<sys:ckfinder input="honorCertificate1" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-							</div>
-							<div class="conList hide-pic">
-									<form:hidden id="honorCertificate2" path="honorCertificate2" htmlEscape="false" maxlength="255" class="input-xlarge"/>
-									<sys:ckfinder input="honorCertificate2" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-							</div>
-							<div class="conList hide-pic">
-									<form:hidden id="honorCertificate3" path="honorCertificate3" htmlEscape="false" maxlength="255" class="input-xlarge"/>
-									<sys:ckfinder input="honorCertificate3" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-							</div>
-							<div class="conList hide-pic">
-									<form:hidden id="honorCertificate4" path="honorCertificate4" htmlEscape="false" maxlength="255" class="input-xlarge"/>
-									<sys:ckfinder input="honorCertificate4" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-							</div>
-							<div class="conList hide-pic">
-									<form:hidden id="honorCertificate5" path="honorCertificate5" htmlEscape="false" maxlength="255" class="input-xlarge"/>
-									<sys:ckfinder input="honorCertificate5" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-							</div>
-						</div>--%>
-				</tr>
-			</table>
-		</div>
-
-		<div class="control-group">
-			<table>
-				<tr>
-					<td>
-							<span>产品证书:</span>
-					</td>
-					<td>
-							<form:hidden id="productCertificate" path="productCertificate" htmlEscape="false" maxlength="255" class="input-xlarge"/>
-							<sys:ckfinder input="productCertificate" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
-							<br><span><font color="#a9a9a9">产品证书</font></span>
-					</td>
-				</tr>
-			</table>
-		</div>
-		<div class="form-actions">
-			<shiro:hasPermission name="user:newCmShop:edit">
-<%--			    <c:if test="${newCmShop.editStatus ne 2}">--%>
-                   <input id="btnSubmit" class="btn btn-primary" type="submit" value="保 存"/>&nbsp;
-<%--                </c:if>--%>
-<%--                <c:if test="${newCmShop.editStatus eq 2}">--%>
-<%--                    <c:if test="${newCmShop.status eq 3 || newCmShop.status eq 92}">--%>
-<%--                        <input class="btn btn-primary"  id="btnSubmit" type="button"  onclick="auditShop(${newCmShop.shopID},${newCmShop.userID})" value="审 核"/>--%>
-<%--                    </c:if>--%>
-<%--				</c:if>--%>
-			</shiro:hasPermission>
-			<input id="btnCancel" class="btn" type="button" value="返 回" onclick="history.go(-1)"/>
-		</div>
-	</form:form>
+                </td>
+            </tr>
+        </table>
+    </div>
+    <div class="control-group">
+        <tr>
+            <th><b>分账商户号:</b></th>
+            <td colspan="3" class="params">
+                <div id="addParamsItems">
+                        <%--相关参数层--%>
+                    <input type="hidden" value="${fn:length(newCmShop.splitCodes)}"
+                           id="productParametersLength">
+                    <c:forEach items="${newCmShop.splitCodes}" var="item" varStatus="varIndex">
+                        <div id="paramsItem" class="paramsItem">
+                            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<form:input
+                                path="splitCodes[${varIndex.index}].splitCode" id="paramsName"
+                                maxlength="8" placeholder="请输入分帐商户号" class="input-small"/>
+                            <form:input path="splitCodes[${varIndex.index}].email" id="email"
+                                        maxlength="10" placeholder="请输入对应邮箱号" class="input-small"/>
+                            <form:input path="splitCodes[${varIndex.index}].codeRemark" id="paramsContent"
+                                        maxlength="10" placeholder="请输入账户备注"
+                                        class="input-small"/>
+                            <span type="button" style="cursor: pointer;color: #0B61A4"
+                                  onclick="deleteParams(this)">删除</span>
+                        </div>
+                    </c:forEach>
+                </div>
+                &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<button
+                    class="addParams" onclick="return false">添加分帐号
+            </button>
+     &emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp; &emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp; &emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;
+
+                <strong>线上支付手续费:</strong>
+
+                <c:if test="${empty newCmShop.commIssion || newCmShop.commIssion==0}">
+                    <input type="radio" checked="checked" name="commIssion" value="0"  class="required" />采美承担
+                    <input type="radio" name="commIssion" value="1" class="required" />供应商承担
+                </c:if>
+                <c:if test="${newCmShop.commIssion==1}">
+                    <input type="radio"  name="commIssion" value="0"  class="required" />采美承担
+                    <input type="radio" checked="checked" name="commIssion" value="1" class="required" />供应商承担
+                </c:if>
+
+
+            </td>
+
+        </tr>
+    </div>
+    <div class="control-group">
+        <b>公司基本信息</b>
+        <table style="border-collapse: separate; border-spacing: 10px; ">
+            <tr>
+                <td>
+                    <span><font color="red">*</font>公司名称:</span>
+                    <form:input path="name" htmlEscape="false" placeholder="请与营业执照的注册名称保持一致" maxlength="30"
+                                class="input-xlarge required"/>
+                </td>
+                <td>
+                    <span>公司简称:</span>
+                    <form:input path="sname" htmlEscape="false" placeholder="请输入公司简称" maxlength="10"
+                                class="input-xlarge"/>
+                </td>
+            </tr>
+            <tr>
+                <td>
+                    <input type="hidden" id="curProvince" name="curProvince" value="${newCmShop.province }">
+                    <input type="hidden" id="curCity" name="curCity" value="${newCmShop.city }">
+                    <input type="hidden" id="curTown" name="curTown" value="${newCmShop.town }">
+                    <span><font color="red">*</font>公司地址:</span>
+                    <form:select path="provinceID" class="input-xlarge required" id="province"
+                                 onchange="loadCity()" style="width:100px;">
+                        <form:option value="" label="省" provinceId=""/>
+                    </form:select>&nbsp;&nbsp;
+                    <form:select path="cityID" class="input-xlarge required" id="city" onchange="loadTown()"
+                                 style="width:100px;">
+                        <form:option value="" label="市" cityId=""/>
+                    </form:select>&nbsp;&nbsp;
+                    <form:select path="townID" class="input-xlarge required" id="town" style="width:100px;">
+                        <form:option value="" label="区"/>
+                    </form:select>&nbsp;&nbsp;
+                    <form:input path="address" htmlEscape="false" placeholder="请输入公司详细地址" maxlength="25"
+                                class="input-xlarge required"/>
+                </td>
+            </tr>
+
+            <tr>
+                <td>
+                    <span><font color="red">*</font>联系人:</span>
+                    <form:input path="linkMan" htmlEscape="false" placeholder="请输入机构联系人名称" maxlength="6"
+                                class="input-xlarge required"/>
+                </td>
+                <td>
+                    <span><font color="red">*</font>手机号:</span>
+                    <form:input path="contractMobile" onchange="checkMobile()" htmlEscape="false" maxlength="11"
+                                placeholder="请输入联系人常用手机号码" class="input-xlarge number required"/>
+                </td>
+                <td>
+                    <span>邮箱:</span>
+                    <form:input path="email" htmlEscape="false" placeholder="请输入邮箱地址" class="input-xlarge "/>
+                </td>
+            </tr>
+
+            <tr>
+                <td>
+                    <span>固定电话:</span>
+                    <form:input path="contractPhone" htmlEscape="false" maxlength="15" placeholder="请在号码前加区号"
+                                class="input-xlarge"/>
+                </td>
+                <td>
+                    <span>传    真:</span>
+                    <form:input path="fax" htmlEscape="false" placeholder="请输入公司传真号" class="input-xlarge "/>
+                </td>
+            </tr>
+
+            <tr>
+                <td>
+                    <span>法人代表:</span>
+                    <form:input path="legalPerson" htmlEscape="false" placeholder="请输入法人代表姓名" class="input-xlarge "/>
+                </td>
+                <td>
+                    <span>注册资本:</span>
+                    ¥<form:input path="registeredCapital" htmlEscape="false" maxlength="11" placeholder="请填写公司注册资本"
+                                 class="input-xlarge number "/>
+                </td>
+                <td>
+                    <span>公司性质:</span>
+                    <form:input path="nature" htmlEscape="false" maxlength="50" placeholder="请填写公司性质"
+                                class="input-xlarge "/>
+                </td>
+            </tr>
+
+            <tr>
+                <td>
+                    <span>年营业额:</span>
+                    <form:input path="turnover" htmlEscape="false" placeholder="请输入公司年营业额" maxlength="11"
+                                class="input-xlarge number "/>
+                </td>
+            </tr>
+        </table>
+    </div>
+    </div>
+    <div class="control-group">
+        <b>公司经营信息</b>
+        <table style="border-collapse: separate; border-spacing: 10px; ">
+            <tr>
+                <td>
+                    <span><font color="red">*</font>公司类型:</span>
+                    <form:radiobutton path="firstShopType" value="1" label="医疗" class="required"
+                                      onclick="secondShop()"/>
+                    <form:radiobutton path="firstShopType" value="2" label="非医疗" class="required"
+                                      onclick="secondShop()"/>
+                </td>
+            </tr>
+            <tr id="secondShopType" hidden="hidden">
+                <td>
+                    <span><font color="red">*</font>医疗类型:</span>
+                    <div class="control-group Main-content">
+                        <div class="tags-area" id="secondShopTypeArea">
+                            <form:radiobutton path="secondShopType" value="1" label="一类器械" class="required"
+                                              onclick="medicalPractice()"/>&nbsp;&nbsp;
+                            <form:radiobutton path="secondShopType" value="2" label="二类器械" class="required"
+                                              onclick="medicalPractice()"/>&nbsp;&nbsp;
+                            <form:radiobutton path="secondShopType" value="3" label="三类器械" class="required"
+                                              onclick="medicalPractice()"/>&nbsp;&nbsp;
+                            <form:radiobutton path="secondShopType" value="4" label="其他" class="required"
+                                              onclick="medicalPractice()"/>
+                        </div>
+                    </div>
+                </td>
+            </tr>
+
+            <tr id="medicalPracticeLicenseImg" hidden="hidden">
+                <td>
+                    <table>
+                        <tr>
+                            <td>
+                                <font color="red">*</font>医疗执业许可证:
+                            </td>
+                            <td>
+                                <form:hidden id="medicalPracticeLicenseImg1" path="medicalPracticeLicenseImg1"
+                                             htmlEscape="false" maxlength="255" class="input-xlarge required"/>
+                                <sys:ckfinder input="medicalPracticeLicenseImg1" type="images" uploadPath="/photo"
+                                              selectMultiple="false" maxWidth="100" maxHeight="100"/>
+                            </td>
+                            <td>
+                                <form:hidden id="medicalPracticeLicenseImg2" path="medicalPracticeLicenseImg2"
+                                             htmlEscape="false" maxlength="255" class="input-xlarge"/>
+                                <sys:ckfinder input="medicalPracticeLicenseImg2" type="images" uploadPath="/photo"
+                                              selectMultiple="false" maxWidth="100" maxHeight="100"/>
+                            </td>
+                            <td>
+                                <form:hidden id="medicalPracticeLicenseImg3" path="medicalPracticeLicenseImg3"
+                                             htmlEscape="false" maxlength="255" class="input-xlarge"/>
+                                <sys:ckfinder input="medicalPracticeLicenseImg3" type="images" uploadPath="/photo"
+                                              selectMultiple="false" maxWidth="100" maxHeight="100"/>
+                            </td>
+                        </tr>
+                    </table>
+                </td>
+            </tr>
+
+            <tr>
+                <td>
+                    <span><font color="red">*</font>主营内容:</span>
+                    <div class="control-group Main-content">
+                        <div class="tags-area" id="mainproArea"></div>
+                        <span class="err-tip" style="display: inline-block;margin-left:-55px;"></span>
+                        <input type="hidden" name="mainpro" value="${newCmShop.mainpro}" id="cMainPro">
+                        <div class="tags-operate">
+                            <span class="new-tag tag-other" id="mainproOther">其他</span>
+                            <input type="text" class="reg-input tag-input" id="mainproInput" placeholder="请输入自定义品项目"
+                                   maxlength="5">
+                            <span class="new-tag tag-add" id="mainproAdd">确认添加</span>
+                        </div>
+                    </div>
+                </td>
+            </tr>
+
+            <tr>
+                <td>
+                    <span><font color="red">*</font>经营范围:</span>
+                    <div class="control-group service-content">
+                        <div class="tags-area" id="serviceArea"></div>
+                        <span class="err-tip" style="display: inline-block;margin-left:-55px;"></span>
+                        <input type="hidden" name="businessScope" value="${newCmShop.businessScope}" id="cServicePro">
+                        <div class="tags-operate">
+                            <span class="new-tag tag-other" id="serviceOther">其他</span>
+                            <input type="text" class="reg-input tag-input" id="serviceInput" placeholder="请输入自定义品项目"
+                                   maxlength="5">
+                            <span class="new-tag tag-add" id="serviceAdd">确认添加</span>
+                        </div>
+                    </div>
+                </td>
+            </tr>
+            <tr>
+                <td>
+                    <span style="min-width: 130px;">官网地址:</span>
+                    <form:input path="website" htmlEscape="false" maxlength="100" placeholder="请输入网址"
+                                class="input-xlarge"/>
+                </td>
+            </tr>
+            <tr>
+                <td>
+                    <span style="min-width: 130px;">微信公众号:</span>
+                    <form:input path="wxOfficialAccount" htmlEscape="false" maxlength="20" placeholder="请输入微信公众号名称"
+                                class="input-xlarge"/>
+                </td>
+            </tr>
+            <tr>
+                <td>
+                    <span style="min-width: 130px;">微信小程序:</span>
+                    <form:input path="wxApplets" htmlEscape="false" maxlength="20" placeholder="请输入微信小程序名称"
+                                class="input-xlarge"/>
+                </td>
+            </tr>
+            <tr>
+                <td>
+                    <span style="min-width: 130px;"><font color="red">*</font>主打系列商品说明:</span>
+                    <form:textarea path="productDesc" htmlEscape="false"
+                                   style="margin: 0px; width: 600px; height: 120px;" maxlength="5000"
+                                   placeholder="请输入公司主打系列商品说明" class="input-xlarge required"/>
+                </td>
+            </tr>
+            <tr>
+                <td>
+                    <span style="min-width: 130px;"><font color="red">*</font>公司介绍:</span>
+                    <form:textarea path="info" htmlEscape="false" style="margin: 0px; width: 600px; height: 120px;"
+                                   maxlength="5000" placeholder="公司介绍会展示在公司主页,有助于机构更好的了解您公司, 建议从规模、产品、服务、荣誉资质这4方面进行介绍"
+                                   class="input-xlarge required"/>
+                </td>
+            </tr>
+        </table>
+    </div>
+
+    <div class="control-group">
+        <b>公司资质认证</b>
+        <br><font color="red">注意:请上传jpg/png格式的图片,最大不超过5M。</font>
+        <table>
+            <tr>
+                <td>
+                    <span><font color="red">*</font>营业执照编号:</span>
+                    <form:input path="socialCreditCode" htmlEscape="false" placeholder="请输入营业执照编号" maxlength="18"
+                                class="input-xlarge required"/>
+                </td>
+            </tr>
+        </table>
+        <table>
+
+            <tr>
+                <td><span><font color="red">*</font>营业执照图片:</span></td>
+                <td>
+                    <form:hidden id="businessLicenseImage" path="businessLicenseImage" htmlEscape="false"
+                                 maxlength="255" class="input-xlarge required"/>
+                    <sys:ckfinder input="businessLicenseImage" type="images" uploadPath="/photo" selectMultiple="false"
+                                  maxWidth="100" maxHeight="100"/>
+                    <br><span><font color="#a9a9a9">营业执照</font></span>
+                </td>
+                <td><span><font color="red">*</font>公司LOGO:</span></td>
+                <td>
+                    <form:hidden id="logo" path="logo" htmlEscape="false" maxlength="255"
+                                 class="input-xlarge required"/>
+                    <sys:ckfinder input="logo" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100"
+                                  maxHeight="100"/>
+                    <br><span><font color="#a9a9a9">公司LOGO</font></span>
+                </td>
+            </tr>
+        </table>
+    </div>
+
+    <div class="control-group">
+        <table>
+            <tr>
+                <td>
+                    <span><font color="red">*</font>资质认证:</span>
+                </td>
+                <td>
+                    <form:hidden id="productionLicense" path="productionLicense" htmlEscape="false" maxlength="255"
+                                 class="input-xlarge required"/>
+                    <sys:ckfinder input="productionLicense" type="images" uploadPath="/photo" selectMultiple="false"
+                                  maxWidth="100" maxHeight="100"/>
+                    <br><span><font color="#a9a9a9">生产许可证</font></span>
+                </td>
+                <td>
+                    <form:hidden id="sanitationPermit" path="sanitationPermit" htmlEscape="false" maxlength="255"
+                                 class="input-xlarge required"/>
+                    <sys:ckfinder input="sanitationPermit" type="images" uploadPath="/photo" selectMultiple="false"
+                                  maxWidth="100" maxHeight="100"/>
+                    <br><span><font color="#a9a9a9">卫生许可证</font></span>
+                </td>
+                <td>
+                    <form:hidden id="taxPermit" path="taxPermit" htmlEscape="false" maxlength="255"
+                                 class="input-xlarge required"/>
+                    <sys:ckfinder input="taxPermit" type="images" uploadPath="/photo" selectMultiple="false"
+                                  maxWidth="100" maxHeight="100"/>
+                    <br><span><font color="#a9a9a9">税务许可证</font></span>
+                </td>
+            </tr>
+        </table>
+    </div>
+
+    <div class="control-group">
+        <table>
+            <tr>
+                <td>
+                    <span>荣誉证书:</span>
+                </td>
+                <td>
+                    <form:hidden id="honorCertificate1" path="honorCertificate1" htmlEscape="false" maxlength="255"
+                                 class="input-xlarge"/>
+                    <sys:ckfinder input="honorCertificate1" type="images" uploadPath="/photo" selectMultiple="false"
+                                  maxWidth="100" maxHeight="100"/>
+                </td>
+                <td>
+                    <form:hidden id="honorCertificate2" path="honorCertificate2" htmlEscape="false" maxlength="255"
+                                 class="input-xlarge"/>
+                    <sys:ckfinder input="honorCertificate2" type="images" uploadPath="/photo" selectMultiple="false"
+                                  maxWidth="100" maxHeight="100"/>
+                </td>
+                <td>
+                    <form:hidden id="honorCertificate3" path="honorCertificate3" htmlEscape="false" maxlength="255"
+                                 class="input-xlarge"/>
+                    <sys:ckfinder input="honorCertificate3" type="images" uploadPath="/photo" selectMultiple="false"
+                                  maxWidth="100" maxHeight="100"/>
+                </td>
+                <td>
+                    <form:hidden id="honorCertificate4" path="honorCertificate4" htmlEscape="false" maxlength="255"
+                                 class="input-xlarge"/>
+                    <sys:ckfinder input="honorCertificate4" type="images" uploadPath="/photo" selectMultiple="false"
+                                  maxWidth="100" maxHeight="100"/>
+                </td>
+                <td>
+                    <form:hidden id="honorCertificate5" path="honorCertificate5" htmlEscape="false" maxlength="255"
+                                 class="input-xlarge"/>
+                    <sys:ckfinder input="honorCertificate5" type="images" uploadPath="/photo" selectMultiple="false"
+                                  maxWidth="100" maxHeight="100"/>
+                </td>
+
+                    <%--<div class="controls upload-content">
+                        <div class="conList">
+                                <form:hidden id="honorCertificate1" path="honorCertificate1" htmlEscape="false" maxlength="255" class="input-xlarge"/>
+                                <sys:ckfinder input="honorCertificate1" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
+                        </div>
+                        <div class="conList hide-pic">
+                                <form:hidden id="honorCertificate2" path="honorCertificate2" htmlEscape="false" maxlength="255" class="input-xlarge"/>
+                                <sys:ckfinder input="honorCertificate2" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
+                        </div>
+                        <div class="conList hide-pic">
+                                <form:hidden id="honorCertificate3" path="honorCertificate3" htmlEscape="false" maxlength="255" class="input-xlarge"/>
+                                <sys:ckfinder input="honorCertificate3" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
+                        </div>
+                        <div class="conList hide-pic">
+                                <form:hidden id="honorCertificate4" path="honorCertificate4" htmlEscape="false" maxlength="255" class="input-xlarge"/>
+                                <sys:ckfinder input="honorCertificate4" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
+                        </div>
+                        <div class="conList hide-pic">
+                                <form:hidden id="honorCertificate5" path="honorCertificate5" htmlEscape="false" maxlength="255" class="input-xlarge"/>
+                                <sys:ckfinder input="honorCertificate5" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
+                        </div>
+                    </div>--%>
+            </tr>
+        </table>
+    </div>
+
+    <div class="control-group">
+        <table>
+            <tr>
+                <td>
+                    <span>产品证书:</span>
+                </td>
+                <td>
+                    <form:hidden id="productCertificate" path="productCertificate" htmlEscape="false" maxlength="255"
+                                 class="input-xlarge"/>
+                    <sys:ckfinder input="productCertificate" type="images" uploadPath="/photo" selectMultiple="false"
+                                  maxWidth="100" maxHeight="100"/>
+                    <br><span><font color="#a9a9a9">产品证书</font></span>
+                </td>
+            </tr>
+        </table>
+    </div>
+    <div class="form-actions">
+        <shiro:hasPermission name="user:newCmShop:edit">
+            <%--			    <c:if test="${newCmShop.editStatus ne 2}">--%>
+            <input id="btnSubmit" class="btn btn-primary" type="submit" value="保 存"/>&nbsp;
+            <%--                </c:if>--%>
+            <%--                <c:if test="${newCmShop.editStatus eq 2}">--%>
+            <%--                    <c:if test="${newCmShop.status eq 3 || newCmShop.status eq 92}">--%>
+            <%--                        <input class="btn btn-primary"  id="btnSubmit" type="button"  onclick="auditShop(${newCmShop.shopID},${newCmShop.userID})" value="审 核"/>--%>
+            <%--                    </c:if>--%>
+            <%--				</c:if>--%>
+        </shiro:hasPermission>
+        <input id="btnCancel" class="btn" type="button" value="返 回" onclick="history.go(-1)"/>
+    </div>
+</form:form>
 
 
 <script>
 
-	var productParametersIndex = $('#productParametersLength').val() - 1;
-	$(".addParams").click(function () {
-		var val = $("#paramsName").val();
-		// alertx("+++++"+val.length)         splitCodes[${varIndex.index}].splitCode
-		productParametersIndex++;
-		var html = '<div id="paramsItem" class="paramsItem">';
-		html += '&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input name="splitCodes[' + [productParametersIndex] + '].splitCode" id="splitCode" maxlength="8" placeholder="请输入分帐商户号" type="text" class="input-small"/>&nbsp;';
-		html += '<input name="splitCodes[' + [productParametersIndex] + '].codeRemark" id="codeRemark" maxlength="10" placeholder="请输入账户备注"  type="text"   class="input-small"/>&nbsp;';
-		html += '<span type="button" style="cursor: pointer;color: #0B61A4" onclick="deleteParams(this)"">删除</span>';
-		html += '</div>';
-		$("#addParamsItems").append(html).show();
-		var paramsItemLength = $('.paramsItem').length;
-		if (paramsItemLength === 5) {
-			$(this).hide();
-			return;
-		}
-	});
-
-	//删除相关参数
-	function deleteParams(paramsThis) {
-		$(paramsThis).parent().remove();
-		var paramsItemLength = $('.paramsItem').length;
-		if (paramsItemLength < 50) {
-			$('.addParams').show();
-		}
-	}
+    var productParametersIndex = $('#productParametersLength').val() - 1;
+    $(".addParams").click(function () {
+        var val = $("#paramsName").val();
+        <%--alertx("+++++"+val.length)         splitCodes[${varIndex.index}].splitCode--%>
+        productParametersIndex++;
+        var html = '<div id="paramsItem" class="paramsItem">';
+        html += '&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input name="splitCodes[' + [productParametersIndex] + '].splitCode" id="splitCode" maxlength="8" placeholder="请输入分帐商户号" type="text" class="input-small"/>&nbsp;';
+        html += '<input name="splitCodes[' + [productParametersIndex] + '].email" id="email"maxlength="10" placeholder="请输入对应邮箱号" class="input-small"/>&nbsp;'
+        html += '<input name="splitCodes[' + [productParametersIndex] + '].codeRemark" id="codeRemark" maxlength="10" placeholder="请输入账户备注"  type="text"   class="input-small"/>&nbsp;';
+        html += '<span type="button" style="cursor: pointer;color: #0B61A4" onclick="deleteParams(this)"">删除</span>';
+        html += '</div>';
+        $("#addParamsItems").append(html).show();
+        var paramsItemLength = $('.paramsItem').length;
+        if (paramsItemLength === 5) {
+            $(this).hide();
+            return;
+        }
+    });
+
+    //删除相关参数
+    function deleteParams(paramsThis) {
+        $(paramsThis).parent().remove();
+        var paramsItemLength = $('.paramsItem').length;
+        if (paramsItemLength < 50) {
+            $('.addParams').show();
+        }
+    }
 </script>
 </body>
 </html>