Browse Source

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

yangc 8 years ago
parent
commit
905a97a3f6

+ 3 - 0
src/main/java/com/uas/platform/b2c/common/account/controller/AuthenticationController.java

@@ -4,6 +4,7 @@ import com.uas.platform.b2c.common.account.model.User;
 import com.uas.platform.b2c.common.account.model.UserInfo;
 import com.uas.platform.b2c.common.account.service.UserService;
 import com.uas.platform.b2c.core.support.SystemSession;
+import net.sf.ehcache.CacheManager;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.http.HttpStatus;
 import org.springframework.web.bind.annotation.*;
@@ -38,6 +39,8 @@ public class AuthenticationController {
 	@ResponseBody
 	@ResponseStatus(value = HttpStatus.OK)
 	public UserInfo getAuthenticationAfterRegister(HttpServletRequest request) {
+		CacheManager singletonManager = CacheManager.create();
+		singletonManager.clearAll();
 		if (SystemSession.getUser() == null) {
 			return null;
 		}

+ 37 - 38
src/main/java/com/uas/platform/b2c/common/search/service/impl/SearcherServiceImpl.java

@@ -1,16 +1,17 @@
 package com.uas.platform.b2c.common.search.service.impl;
 
 import com.alibaba.fastjson.JSONObject;
+import com.uas.platform.b2c.common.search.service.SearcherService;
+import com.uas.platform.b2c.core.utils.FastjsonUtils;
 import com.uas.platform.b2c.prod.product.component.dao.ComponentGoodsDao;
 import com.uas.platform.b2c.prod.product.component.dao.ComponentInfoDao;
 import com.uas.platform.b2c.prod.product.component.modal.ComponentGoods;
 import com.uas.platform.b2c.prod.product.component.modal.ComponentInfo;
-import com.uas.platform.b2c.common.search.service.SearcherService;
-import com.uas.platform.b2c.core.utils.FastjsonUtils;
 import com.uas.platform.core.exception.SystemException;
 import com.uas.platform.core.model.PageInfo;
 import com.uas.platform.core.model.PageParams;
 import com.uas.search.exception.SearchException;
+import com.uas.search.model.CollectField;
 import com.uas.search.model.PageParams.FilterField;
 import com.uas.search.model.SPage;
 import com.uas.search.model.Sort;
@@ -27,11 +28,9 @@ import java.io.IOException;
 import java.util.*;
 import java.util.Map.Entry;
 
-import com.uas.search.model.CollectField;
-
 /**
  * 搜索索引
- * 
+ *
  * @author sunyj
  * @since 2016年7月8日 下午5:14:44
  */
@@ -51,7 +50,7 @@ public class SearcherServiceImpl implements SearcherService {
 
 	/**
 	 * 智能搜索类目
-	 * 
+	 *
 	 * @param keyword
 	 * @param field
 	 * @return
@@ -74,7 +73,7 @@ public class SearcherServiceImpl implements SearcherService {
 
 	/**
 	 * 智能搜索品牌
-	 * 
+	 *
 	 * @param keyword
 	 * @param field
 	 * @return
@@ -97,7 +96,7 @@ public class SearcherServiceImpl implements SearcherService {
 
 	/**
 	 * 智能搜索器件
-	 * 
+	 *
 	 * @param keyword
 	 * @return
 	 * @throws InterruptedException
@@ -180,35 +179,35 @@ public class SearcherServiceImpl implements SearcherService {
 
 		return map;
 	}
-    /**
-     * 批次搜索数量统计
-     *
-     * @param keyword
-     * @param page
-     * @return
-     * @throws InterruptedException
-     * @throws IOException
-     */
-    @SuppressWarnings("unchecked")
-    @Override
-    public ModelMap searchComponentGoodsNums(String keyword, PageParams page) {
-        ModelMap map = new ModelMap();
-        Map<String, Object> results = null;
-        //Map<String, Object> results = new HashMap<>();
-        try {
-            results = searchService.getGoodsIds(keyword, convertPageParams(page));
-        } catch (SearchException e) {
-            throwSystemException(e);
-        }
-        map.put("total", results.get("total"));// 搜索结果总数
-        return map;
-    }
+	/**
+	 * 批次搜索数量统计
+	 *
+	 * @param keyword
+	 * @param page
+	 * @return
+	 * @throws InterruptedException
+	 * @throws IOException
+	 */
+	@SuppressWarnings("unchecked")
+	@Override
+	public ModelMap searchComponentGoodsNums(String keyword, PageParams page) {
+		ModelMap map = new ModelMap();
+		Map<String, Object> results = null;
+		//Map<String, Object> results = new HashMap<>();
+		try {
+			results = searchService.getGoodsIds(keyword, convertPageParams(page));
+		} catch (SearchException e) {
+			throwSystemException(e);
+		}
+		map.put("total", results.get("total"));// 搜索结果总数
+		return map;
+	}
 
 
 
 	/**
 	 * 获取器件搜索的类目统计
-	 * 
+	 *
 	 * @param keyword
 	 * @return
 	 */
@@ -225,7 +224,7 @@ public class SearcherServiceImpl implements SearcherService {
 
 	/**
 	 * 获取器件搜索的品牌统计列表
-	 * 
+	 *
 	 * @param keyword
 	 * @return
 	 */
@@ -254,7 +253,7 @@ public class SearcherServiceImpl implements SearcherService {
 		for (Entry<String, Object> entry : paramEntry) {
 			param.put(FilterField.valueOf(entry.getKey().toUpperCase()), entry.getValue());
 		}
- 		try {
+		try {
 			collectResult = searchService.collectBySearchGoods(keyword, CollectField.valueOf(collectList.toUpperCase()),param);
 		} catch (SearchException e) {
 			throwSystemException(e);
@@ -271,8 +270,8 @@ public class SearcherServiceImpl implements SearcherService {
 			throwSystemException(e);
 		}
 		if (result.size() > 8) {
-            result = result.subList(0,8);
-        }
+			result = result.subList(0,8);
+		}
 		return result;
 	}
 
@@ -289,7 +288,7 @@ public class SearcherServiceImpl implements SearcherService {
 
 	/**
 	 * 把平台中PageParams对象转化为搜索API封装的PageParams对象
-	 * 
+	 *
 	 * @param params
 	 * @return
 	 */
@@ -352,7 +351,7 @@ public class SearcherServiceImpl implements SearcherService {
 
 	/**
 	 * 捕获SearchException抛出SystemException
-	 * 
+	 *
 	 * @param e
 	 * @return
 	 */

+ 4 - 1
src/main/java/com/uas/platform/b2c/prod/product/brand/service/impl/BrandSubmitServiceImpl.java

@@ -25,6 +25,7 @@ import javax.persistence.criteria.CriteriaBuilder;
 import javax.persistence.criteria.CriteriaQuery;
 import javax.persistence.criteria.Predicate;
 import javax.persistence.criteria.Root;
+import java.util.ArrayList;
 import java.util.Date;
 import java.util.List;
 import java.util.regex.Matcher;
@@ -74,7 +75,9 @@ public class BrandSubmitServiceImpl implements BrandSubmitService {
 		// 检查新增还是更新
 		if (brandSubmit.getUuid() == null) {
 			// 如果是新增检查品牌是否重名,重名设置version为-1,返回前台判断是否更新已存在品牌
-			List<Brand> existBrandCn = brandDao.findByNameCn(brandSubmit.getNameCn());
+			List<Brand> existBrandCn = new ArrayList<Brand>();
+			if (brandSubmit.getNameCn() != null)
+				existBrandCn = brandDao.findByNameCn(brandSubmit.getNameCn());
 			List<Brand> existBrandEn = brandDao.findByNameEn(brandSubmit.getNameEn());
 			if (CollectionUtils.isNotEmpty(existBrandCn)) {
 				brand.setVersion((short) -1);

+ 9 - 5
src/main/webapp/resources/js/admin/controllers/help/HelpDetailCtrl.js

@@ -8,11 +8,15 @@ define(['app/app'], function(app) {
         HelpIssue.get({id : $stateParams.id}, function (data) {
             $scope.issue = data;
             quill.setContents(angular.fromJson($scope.issue.content));
-            HelpAPI.get({id : $scope.issue.navId},function (data) {
-                $scope.issue.nav = data;
-            }, function (response) {
-                toaster.pop('error', response.data);
-            });
+            if ($scope.issue.navId) {
+                HelpAPI.get({id : $scope.issue.navId},function (data) {
+                    $scope.issue.nav = data;
+                }, function (response) {
+                    toaster.pop('error', response.data);
+                });
+            } else {
+                toaster.pop('warning', '暂无导航信息,请补充');
+            }
         }, function (response) {
             toaster.pop('error', response.data);
         });

+ 1 - 0
src/main/webapp/resources/js/vendor/controllers/forstore/purchase_detail.js

@@ -5,6 +5,7 @@ define(['app/app'], function(app) {
 
 		// 保存采购单编号信息
 		$scope.purchaseId = $stateParams.purchaseId;
+		$scope.open = false;
 
 		// 记录状态激活信息
 		$scope.steps = {

+ 9 - 9
src/main/webapp/resources/js/vendor/controllers/forstore/vendor_onSaleCtrl.js

@@ -94,7 +94,7 @@ define([ 'app/app' ], function(app) {
                 }else if(qty < price.end) {
                     var end = price.end;
                     price.end = qty - 1;
-                    var obj = {start : qty, end : end, rMBPrice : null, uSDPrice : null};
+                    var obj = {start : qty, end : end, RMBPrice : null, USDPrice : null};
                     commodity.editPrices.splice(i + 1 , 0 , obj);
                     $scope.$$onSale.qty = null;
                     return ;
@@ -456,19 +456,19 @@ define([ 'app/app' ], function(app) {
                 }
                 //目前系统中存在双币别,与现有的逻辑冲突,暂时先用企业地址确定币别
                 if($scope.$$onSale.currency.indexOf('USD') > -1) {
-                    if(!price.uSDPrice) {
+                    if(!price.USDPrice) {
                         toaster.pop('warning', '第' +(i + 1)+'个分段的单价($)为空,请填写后再次提交!');
                         return result;
-                    }else if(isNaN(price.uSDPrice)){
+                    }else if(isNaN(price.USDPrice)){
                         toaster.pop('warning', '第' +(i + 1)+'个分段的单价($)信息必须是数字');
                         return result;
                     }
                 }
                 if($scope.$$onSale.currency.indexOf('RMB') > -1) {
-                    if(!price.rMBPrice) {
+                    if(!price.RMBPrice) {
                         toaster.pop('warning', '第' +(i + 1)+'个分段的单价(¥)为空,请填写后再次提交!');
                         return result;
-                    }else if(isNaN(price.rMBPrice)){
+                    }else if(isNaN(price.RMBPrice)){
                         toaster.pop('warning', '第' +(i + 1)+'个分段的单价(¥)信息必须是数字');
                         return result;
                     }
@@ -490,17 +490,17 @@ define([ 'app/app' ], function(app) {
             }else if(isNaN(num)){
                 toaster.pop('warning', '价格的信息必须只能包含数字');
                 if(isRMB) {
-                    price.rMBPrice = null;
+                    price.RMBPrice = null;
                 }else {
-                    price.uSDPrice = null;
+                    price.USDPrice = null;
                 }
                 return ;
             }else if(Number(num) <= 0) {
                 toaster.pop('warning', '价格的信息必须是大于零的数字');
                 if(isRMB) {
-                    price.rMBPrice = null;
+                    price.RMBPrice = null;
                 }else {
-                    price.uSDPrice = null;
+                    price.USDPrice = null;
                 }
                 return ;
             }

+ 19 - 13
src/main/webapp/resources/js/vendor/controllers/forstore/vendor_standard_putOn_ctrl.js

@@ -177,8 +177,8 @@ define(['app/app'], function (app) {
                 var obj = {
                     start : 1,
                     end : getMaxNumber(toBeSale, standard.editMinBuyQty),
-                    rMBPrice : null,
-                    uSDPrice : null
+                    RMBPrice : null,
+                    USDPrice : null
                 }
                 standard.editQtyPrices.push(obj);
             }else {
@@ -225,7 +225,7 @@ define(['app/app'], function (app) {
                 }else if(qty < price.end) {
                     var end = price.end;
                     price.end = qty -1;
-                    var obj = {start : qty, end : end, rMBPrice : null, uSDPrice : null};
+                    var obj = {start : qty, end : end, RMBPrice : null, USDPrice : null};
                     standard.editQtyPrices.splice(i + 1 , 0 , obj);
                     standard.insertQty = null;
                     return ;
@@ -479,25 +479,25 @@ define(['app/app'], function (app) {
                 }
                 //目前系统中存在双币别,与现有的逻辑冲突,暂时先用企业地址确定币别
                 if($scope.$$putOn.currency.indexOf('USD') > -1) {
-                    if(!fragments[i].uSDPrice) {
+                    if(!fragments[i].USDPrice) {
                         toaster.pop('warning', '第' +(i + 1)+'个分段的单价($)为空,请填写后再次提交!');
                         return result;
-                    }else if(isNaN(fragments[i].uSDPrice)){
+                    }else if(isNaN(fragments[i].USDPrice)){
                         toaster.pop('warning', '第' +(i + 1)+'个分段的单价($)信息必须是数字');
                         return result;
-                    }else if(Number(fragments[i].uSDPrice) < 0) {
+                    }else if(Number(fragments[i].USDPrice) < 0) {
                         toaster.pop('warning', '第' +(i + 1)+'个分段的单价($)信息必须是大于零的数字');
                         return result;
                     }
                 }
                 if($scope.$$putOn.currency.indexOf('RMB') > -1) {
-                    if(!fragments[i].rMBPrice) {
+                    if(!fragments[i].RMBPrice) {
                         toaster.pop('warning', '第' +(i + 1)+'个分段的单价(¥)为空,请填写后再次提交!');
                         return result;
-                    }else if(isNaN(fragments[i].rMBPrice)){
+                    }else if(isNaN(fragments[i].RMBPrice)){
                         toaster.pop('warning', '第' +(i + 1)+'个分段的单价(¥)信息必须是数字');
                         return result;
-                    }else if(Number(fragments[i].rMBPrice) < 0) {
+                    }else if(Number(fragments[i].RMBPrice) < 0) {
                         toaster.pop('warning', '第' +(i + 1)+'个分段的单价(¥)信息必须是大于零的数字');
                         return result;
                     }
@@ -519,17 +519,17 @@ define(['app/app'], function (app) {
             }else if(isNaN(num)){
                 toaster.pop('warning', '价格的信息必须只能包含数字');
                 if(isRMB) {
-                    price.rMBPrice = null;
+                    price.RMBPrice = null;
                 }else {
-                    price.uSDPrice = null;
+                    price.USDPrice = null;
                 }
                 return ;
             }else if(Number(num) <= 0) {
                 toaster.pop('warning', '价格的信息必须是大于零的数字');
                 if(isRMB) {
-                    price.rMBPrice = null;
+                    price.RMBPrice = null;
                 }else {
-                    price.uSDPrice = null;
+                    price.USDPrice = null;
                 }
                 return ;
             }
@@ -625,6 +625,12 @@ define(['app/app'], function (app) {
             }
         };
 
+        $scope.updatePrice = function () {
+            StandardPutOnAdminService.updateQtyPrice({},{},function (data) {
+
+            })
+        };
+
         /**
          * 一键更新
          */

+ 2 - 1
src/main/webapp/resources/view/usercenter/forstore/browsing_history.html

@@ -411,7 +411,8 @@
                         <img src="{{item.img || 'static/img/store/common/default.png'}}"/></a>
                 </div>
                 <div class="content">
-                    <p class="red">¥<span ng-bind="item.minPriceRMB"></span></p>
+                    <p class="red" ng-if="item.minPriceRMB">¥<span ng-bind="item.minPriceRMB"></span></p>
+                    <p class="red" ng-if="item.minPriceUSD">$&nbsp;<span ng-bind="item.minPriceUSD"></span></p>
                     <p ng-bind="item.kindNameCn"></p>
                     <p ng-bind="item.code"></p>
                     <p ng-bind="item.brandNameEn"></p>

+ 2 - 2
src/main/webapp/resources/view/usercenter/forstore/order_pay.html

@@ -521,8 +521,8 @@
 							<span class="style01" style="width: 60%;">配送方式:
 								<select ng-if="order.status == 501" class="select" ng-switch="order.deliverytype" style="opacity: 1;" >
 									<option ng-switch-when="1301">第三方配送</option>
-									<option ng-switch-when="1301">卖家配送</option>
-									<option ng-switch-when="1301">上门自提</option>
+									<!--<option ng-switch-when="1301">卖家配送</option>-->
+									<!--<option ng-switch-when="1301">上门自提</option>-->
 									<!--<option ng-switch-when="1302">上门自提</option>-->
 								</select>
 								<em ng-if="order.status != 501">物流配送</em>

+ 417 - 0
src/main/webapp/resources/view/vendor/forstore/product_file.html

@@ -0,0 +1,417 @@
+<style>
+    .product-file{
+        width: 100%;
+        margin: 0 auto;
+        min-height: 505px;
+        background: #fff;
+        padding-top: 16px;
+        border: #e8e8e8 1px solid;
+    }
+    .product-file ul{
+        width: 100%;
+        height: 30px;
+        margin: 0 auto;
+        margin-top: 16px;
+    }
+    .product-file ul li{
+        width: 78px;
+        float: left;
+        margin: 0 15px;
+    }
+    .product-file ul li:first-child{
+        margin-left: 25px;
+    }
+    .product-file ul li a{
+        display: inline-block;
+        width: 100%;
+        height: 30px;
+        line-height: 30px;
+        position: relative;
+        background: #f5f8fe;
+        text-align: center;
+        font-size: 14px;
+        border-radius: 1px;
+    }
+    .product-file ul li a.active,.product-file ul li:hover a{
+        background: #5078cb;
+        color: #fff;
+    }
+    .product-file ul li a.active:before,.product-file ul li:hover a:before{
+        content: '';
+        position: absolute;
+        display: inline-block;
+        width: 0;
+        height: 0;
+        border-left: 5px solid transparent;
+        border-right: 5px solid transparent;
+        border-bottom: 5px solid #fff;
+        bottom: -1px;
+        left: 33px;
+    }
+    .product-file .content{
+        width: 98%;
+        border: #5078cb 1px solid;
+        padding: 15px;
+        margin: 0 auto;
+    }
+    .product-file .content .batch{
+        font-size: 14px;
+    }
+    .product-file .content .batch .row{
+        padding: 0 15px;
+        margin-bottom: 20px;
+    }
+    .product-file .content .batch .row:first-child{
+        margin-top: 10px;
+        margin-bottom: 45px;
+    }
+    .product-file .content .batch .row span.dot{
+        display: inline-block;
+        width: 22px;
+        height: 19px;
+        margin-right: 10px;
+    }
+    .product-file .content .batch .row span em{
+        display: inline-block;
+        width: 14px;
+        height: 19px;
+        background: #ff8522;
+        font-size: 14px;
+        text-align: center;
+        color: #fff;
+        position: relative;
+        line-height: 19px;
+    }
+    .product-file .content .batch .row span em:before{
+        content: '';
+        position: absolute;
+        display: inline-block;
+        border-width: 9px 0 10px 10px;
+        border-style: solid;
+        border-color: transparent transparent transparent #ff8522;
+        right: -10px;
+        top: 0;
+    }
+    .product-file .content .batch .row .btn01{
+        display: inline-block;
+        width: 70px;
+        height: 22px;
+        line-height: 22px;
+        text-align: center;
+        color: #fff;
+        background: #ff8522;
+        border-radius: 2px;
+        font-size: 12px;
+    }
+    .product-file .content .batch .row a.load-btn{
+        color: #5078cb;
+        font-size: 12px;
+        margin-left: 10px;
+    }
+    .product-file .import-area{
+        width: 940px;
+        margin-left: 22px;
+        background: #f5f8fe;
+        padding-top: 10px !important;
+        padding-bottom: 10px !important;
+    }
+    .product-file .import-area p{
+        font-size: 14px;
+    }
+    /*checked*/
+    .import-area .check-act{
+        font-weight: normal;
+    }
+    .import-area .check-act:last-child{
+        margin-left: 45px;
+    }
+    .import-area .check-act input{
+        display: none;
+    }
+    .import-area .check-act label{
+        width: 12px;
+        height: 12px;
+        margin-right: 5px;
+        display: inline-block;
+        background: url(static/img/icon/check-rule.png) no-repeat;
+        position: relative;
+        top: 2px;
+    }
+    .import-area .check-act label{
+        background-position: 0 0;
+    }
+    .import-area input:checked + label{
+        background-position: -15px 0;
+    }
+    .import-input{
+        width: 100%;
+        margin: 15px 0 0 0;
+        padding-bottom: 10px;
+    }
+    .import-input span{
+        width: 350px;
+        margin: 0 auto;
+        float: left;
+        position: relative;
+    }
+    .import-input span #upload_text{
+        width: 265px;
+        height: 26px;
+        border: #e2e2e2 1px solid;
+        padding-left: 10px;
+        border-radius: 3px;
+    }
+    .import-input span .upload01{
+        width: 100%;
+        margin: 0 auto;
+        height: 26px;
+        position: absolute;
+        left: 0;
+        top: 0;
+        opacity: 0;
+    }
+    .import-input span a.btn01{
+        margin-left: 8px;
+    }
+    .import-input a.btn01{
+        margin-left: 10px;
+    }
+    .blue-bg{
+        background: #5078cb !important;
+    }
+    /*单个导入*/
+    .no-batch{
+        width: 100%;
+        margin: 0 auto;
+        min-height: 200px;
+    }
+    .no-batch .row{
+        background: #f5f8fe;
+        padding: 20px 15px 30px;
+        margin: 0;
+    }
+    .no-batch .row .row-line{
+        float: left;
+        line-height: 26px;
+        margin-right: 18px;
+    }
+    .no-batch .row .row-line span.title{
+        font-size: 14px;
+        margin-right: 10px;
+    }
+    .no-batch .row .row-line span.title em{
+        color: #f00;
+        margin-right: 3px;
+        position: relative;
+        top: 2px;
+    }
+    .no-batch .row .row-line input{
+        width: 168px;
+        height: 26px;
+        line-height: 26px;
+        border: #e2e2e2 1px solid;
+        border-radius: 0;
+        background: #fff;
+        float: right;
+    }
+    .no-batch .row .row-line:last-child{
+        margin-right: 0;
+    }
+    .no-batch .row .row-line:last-child input{
+        margin-right: 0;
+        width: 128px;
+    }
+    /*操作取消保存*/
+    .deal-btn{
+        width: 100%;
+        margin: 0 auto;
+        text-align: center;
+        margin-top: 80px;
+    }
+    .deal-btn a{
+        width: 70px;
+        height: 30px;
+        display: inline-block;
+        text-align: center;
+        line-height: 30px;
+        font-size: 14px;
+    }
+    .deal-btn a.off{
+        background: #cdcccc;
+        color: #666;
+        margin-right: 8px;
+    }
+    .deal-btn a.save-other{
+        width: 100px;
+        background: #ff8522;
+        color: #fff;
+        margin-right: 8px;
+    }
+    .deal-btn a.ok{
+        background: #5078cb;
+        color: #fff;
+    }
+    .deal-btn a:hover{
+        background: #337ab7;
+        color: #fff;
+    }
+    /*防误删*/
+    .com-del-box{
+        position: fixed;
+        z-index: 22;
+        height: 152px;
+        opacity: 1;
+        background-color: white;
+        width: 310px;
+        -webkit-box-shadow: 0 5px 15px rgba(0,0,0,.5);
+        box-shadow: 0 5px 15px rgba(0,0,0,.5);
+        margin: -155px 0 0 -75px;
+        top: 55%;
+        left: 50%;
+    }
+    .com-del-box .title{
+        height: 30px;
+        background-color: #5078cb;
+        text-align: right;
+        padding-right: 15px;
+        line-height: 30px;
+    }
+    .com-del-box .title a{
+        color: white;
+        font-size: 16px;
+    }
+    .com-del-box .content{
+        width: 100%;
+        text-align: center;
+        margin: 0 auto;
+    }
+    .com-del-box .content p{
+        font-size: 14px;
+        padding-top: 10px;
+    }
+    .com-del-box .content p:first-child{
+        padding-top: 25px;
+    }
+    .com-del-box .content p:nth-child(2),.com-del-box .content p:nth-child(3){
+        font-size: 12px;
+    }
+    .com-del-box .content p em:first-child,.com-del-box .content p:nth-child(3) a,.com-del-box .content p:nth-child(3) em{
+        color: #5078cb;
+    }
+    .com-del-box .content p:nth-child(2) em{
+        color: #f00;
+    }
+    .com-del-box .content p i{
+        color: #5078cb;
+        font-size: 16px;
+        margin-right: 10px;
+    }
+    .com-del-box .content div{
+        width: 100%;
+        text-align: center;
+        margin: 0 auto;
+    }
+</style>
+<div class="user_right fr">
+    <!--产品导入-->
+    <div class="pro_management device">
+        <div class="com_tab">
+            <ul class="fl" style="width: 100%">
+                <li ng-class="{'active': $$productOn.leadIn == 'bathOn'}"><a href="javascript:void(0)">新产品建档</a></li>
+                <li ui-sref="product_repository"><a href="javascript:void(0)">产品库</a></li>
+            </ul>
+        </div>
+    </div>
+    <!--产品建档-->
+    <div class="product-file">
+        <ul class="file-tab">
+            <li><a ng-class="{'active': style == 'batch'}" ng-click="checkTab('batch')">批量建档</a></li>
+            <li><a ng-class="{'active': style == 'single'}" ng-click="checkTab('single')">单个建档</a></li>
+        </ul>
+        <div class="content" ng-controller="productOnCtrl">
+            <!--批量-->
+            <div class="batch" ng-if="style == 'batch'">
+                <div class="row">
+                    <span class="dot"><em>1</em></span>
+                    下载Excle导入模板,在模板上编辑产品信息
+                    <a class="btn01" style="margin-left: 35px;" ng-click="download()" title="下载模板">下载模板</a>
+                    <a class="load-btn" ng-click="showImg()" title="查看表格示例">查看表格示例</a>
+                </div>
+                <div class="row">
+                    <span class="dot"><em>2</em></span>导入数据
+                </div>
+                <div class="import-area row">
+                    <p>
+                        产品已存在时:&nbsp;&nbsp;
+                        <label class="check-act">
+                            <input type="radio" id="1" name="radio2" checked/>
+                            <label for="1"></label>
+                            统一规定运费
+                        </label>
+                        <label class="check-act">
+                            <input type="radio" id="2" name="radio2"/>
+                            <label for="2"></label>
+                            按总金额计算
+                        </label>
+                    </p>
+                    <div class="import-input">
+                        <span>
+                            <input type="text" name="txt" id="upload_text" />
+                            <a class="btn01" ng-click="">选择文件</a>
+                            <input type="file" onchange="upload_text.value=this.value" class="upload01" />
+                        </span>
+                        <a class="btn01 blue-bg" ng-click="">导入</a>
+                    </div>
+                </div>
+            </div>
+            <!--单个-->
+            <div class="no-batch" ng-if="style == 'single'">
+                <div class="row">
+                    <div class="row-line">
+                        <span class="title">产品名称(类目)</span>
+                        <input type="text" class="form-control" ng-change="inputCategory()"/>
+                    </div>
+                    <div class="row-line">
+                        <span class="title"><em>*</em>型号</span>
+                        <input type="text" class="form-control" ng-change="inputBatch()"/>
+                    </div>
+                    <div class="row-line">
+                        <span class="title"><em>*</em>品牌</span>
+                        <input type="text" class="form-control" ng-change="inputBrand()"/>
+                    </div>
+                    <div class="row-line">
+                        <span class="title">封装</span>
+                        <input type="text" class="form-control" />
+                    </div>
+                </div>
+                <!--操作取消保存-->
+                <div class="deal-btn">
+                    <a ng-click="" class="off">取消</a>
+                    <a ng-click="" class="ok">保存</a>
+                </div>
+            </div>
+        </div>
+    </div>
+</div>
+<!--提示内容-->
+<div class="com-del-box" style="display: none">
+    <div class="title">
+        <a ng-click=""><i class="fa fa-close fa-lg"></i></a>
+    </div>
+    <div class="content">
+        <p><i class="fa fa-exclamation-circle"></i>共导入 <em>1000</em> 个,其中<em>600</em> 个建档成功!</p>
+        <p>(另有<em>20</em>个已存在,<em>380</em>个必填项缺失)</p>
+        <p>正在为您跳转 <a>产品库 >></a>  <em>5秒</em> </p>
+        <!--<div><a ng-click="">取消</a><a ng-click="">确认</a></div>-->
+    </div>
+</div>
+<!--查看大图-->
+<div id="image-box" style="display: none;">
+    <div class="x-floating-wrap"></div>
+    <div class="x-floating">
+        <div id="item-content">
+            <div class="x-close-wrap"><a href="javascript:void(0);">&times;</a></div>
+            <div class="img"><img src="static/img/product/excel_product_import.png"></div>
+        </div>
+    </div>
+</div>

+ 2 - 2
src/main/webapp/resources/view/vendor/forstore/purchase_detail.html

@@ -367,7 +367,7 @@
 					<div ng-class="{'limit-3': !open}">
 						<dd class="oder_l" ng-repeat="detail in purchase.purchaseDetails">
 						<span class="wd02">
-							<a href="store/{{detail.storeid}}/{{::detail.batchCode}}" target="_blank"><img ng-src="{{detail.img ? detail.img : 'static/img/user/images/pro02.jpg'}}"/></a>
+							<a href="store/{{detail.storeid}}/{{::detail.batchCode}}" target="_blank"><img ng-src="{{detail.img ? detail.img : 'static/img/store/common/default.png'}}"/></a>
 							<p class="style01" style="margin-top: 10px;">类目:
 								<a ng-bind="detail.kiName" href="store/{{detail.storeid}}/{{::detail.batchCode}}" title="{{detail.kiName}}" target="_blank"></a>
 							</p>
@@ -401,7 +401,7 @@
 					</dd>
 					</div>
 					<div class="open-more row" ng-class="{'none': purchase.purchaseDetails.length < 3}">
-						<a href="javascript:void(0)" ng-click="$open=!open" ng-class="{'active': open}">
+						<a href="javascript:void(0)" ng-click="open=!open" ng-class="{'active': open}">
 							<em ng-bind="open ? '收起' : '查看所有产品'"></em>
 							<i class="fa fa-angle-up" ng-if="open"></i>
 							<i class="fa fa-angle-down" ng-if="!open"></i>

+ 4 - 4
src/main/webapp/resources/view/vendor/forstore/vendor_onSale.html

@@ -782,8 +782,8 @@
                             </td>
                             <td>
                                 <div ng-repeat="price in commodity.prices">
-                                    <span ng-if="$$onSale.currency == 'RMB'" style="margin-left: 20px;" ng-bind="price.rMBPrice | formateNumber : 6 | currencySysmbol : $$onSale.currency">0.52</span>
-                                    <span ng-if="$$onSale.currency == 'USD'" style="margin-left: 20px;" ng-bind="price.uSDPrice | formateNumber : 6 | currencySysmbol : $$onSale.currency">0.52</span>
+                                    <span ng-if="$$onSale.currency == 'RMB'" style="margin-left: 20px;" ng-bind="price.RMBPrice | formateNumber : 6 | currencySysmbol : $$onSale.currency">0.52</span>
+                                    <span ng-if="$$onSale.currency == 'USD'" style="margin-left: 20px;" ng-bind="price.USDPrice | formateNumber : 6 | currencySysmbol : $$onSale.currency">0.52</span>
                                 </div>
                             </td>
                             <td>
@@ -870,8 +870,8 @@
                             <td>
                                 <div ng-repeat="price in commodity.editPrices" class="price">
                                     <span>
-                                        <input ng-if="$$onSale.currency == 'RMB'" type="text" placeholder="单价(含税)¥)" ng-blur="validPrice(price, price.rMBPrice, true)" ng-model="price.rMBPrice" class="width82 form-control"/>
-                                        <input ng-if="$$onSale.currency == 'USD'" type="text" placeholder="单价($)" ng-blur="validPrice(price, price.uSDPrice, false)" ng-model="price.uSDPrice" class="width82 form-control"/>
+                                        <input ng-if="$$onSale.currency == 'RMB'" type="text" placeholder="单价(含税)¥)" ng-blur="validPrice(price, price.RMBPrice, true)" ng-model="price.RMBPrice" class="width82 form-control"/>
+                                        <input ng-if="$$onSale.currency == 'USD'" type="text" placeholder="单价($)" ng-blur="validPrice(price, price.USDPrice, false)" ng-model="price.USDPrice" class="width82 form-control"/>
                                     </span>
                                     <a class="delete" title="删除" ng-click="deleteFragment(commodity, $index)" ng-if="commodity.editPrices.length != 1"><i class="fa fa-trash"></i></a>
                                 </div>

+ 8 - 5
src/main/webapp/resources/view/vendor/forstore/vendor_standard_putOn.html

@@ -352,6 +352,7 @@
                 </form>
             </div>
             <div class="check fr">
+                <button ng-click="updatePrice()">更新分段价格</button>
                 <a  ng-click="batchUpdate()" class="blue">一键更新</a>
             </div>
         </div>
@@ -431,8 +432,8 @@
                         </td>
                         <td>
                             <div ng-repeat="price in standard.qtyPrices">
-                               <span ng-if="standard.currency == 'RMB'" ng-bind="price.rMBPrice | formateNumber : 6 | currencySysmbol : standard.currency"></span>
-                               <span ng-if="standard.currency == 'USD'" ng-bind="price.uSDPrice | formateNumber : 6 | currencySysmbol : standard.currency"></span>
+                               <span ng-if="standard.currency == 'RMB'" ng-bind="price.RMBPrice | formateNumber : 6 | currencySysmbol : standard.currency"></span>
+                               <span ng-if="standard.currency == 'USD'" ng-bind="price.USDPrice | formateNumber : 6 | currencySysmbol : standard.currency"></span>
                                 <span ng-if="!standard.currency">-</span>
                             </div>
                             <div ng-if="!standard.qtyPrices.length">-</div>
@@ -529,14 +530,16 @@
                                 <i class="fa fa-chevron-up"></i>
                             </div>
                             <div style="margin-top: 0;">
-                                <span style="margin-left: 7px;" ng-if="standard.editQtyPrices.length != 3"><input ng-model="standard.insertQty" type="text" placeholder="分段数量" class="form-control" style="width: 104px;"/></span>
+                                <span style="margin-left: 7px;" ng-if="standard.editQtyPrices.length != 3">
+                                    <input ng-model="standard.insertQty" type="text" placeholder="分段数量" class="form-control" style="width: 104px;"/>
+                                </span>
                             </div>
                         </td>
                         <td>
                             <div class="price" ng-repeat="price in standard.editQtyPrices">
                                 <span class="price-input">
-                                    <span ng-if="standard.currency == 'USD'">$</span><input ng-blur="validPrice(price, price.uSDPrice, false)" ng-if="standard.currency == 'USD'" type="text" class="form-control" ng-model="price.uSDPrice" style="width: 65px;" placeholder="单价($)">
-                                    <span ng-if="standard.currency == 'RMB'">¥</span><input ng-blur="validPrice(price, price.rMBPrice, true)" ng-if="standard.currency == 'RMB'" type="text" class="form-control" ng-model="price.rMBPrice" style="width: 65px;" placeholder="单价(¥)">
+                                    <span ng-if="standard.currency == 'USD'">$</span><input ng-blur="validPrice(price, price.USDPrice, false)" ng-if="standard.currency == 'USD'" type="text" class="form-control" ng-model="price.USDPrice" style="width: 65px;" placeholder="单价($)">
+                                    <span ng-if="standard.currency == 'RMB'">¥</span><input ng-blur="validPrice(price, price.RMBPrice, true)" ng-if="standard.currency == 'RMB'" type="text" class="form-control" ng-model="price.RMBPrice" style="width: 65px;" placeholder="单价(¥)">
                                 </span>
                                 <a ng-if="standard.editQtyPrices.length != 1" class="delete" title="删除" ng-click="deleteFragment(standard, $index)"><i class="fa fa-trash"></i></a>
                             </div>

+ 38 - 8
src/main/webapp/resources/view/vendor/forstore/vendor_store_info.html

@@ -1,4 +1,8 @@
 <style>
+	div.vendor_store_apply_info input.ng-invalid.ng-dirty, textarea.ng-invalid.ng-dirty {
+		border-color: #CC0033 !important;
+	}
+
 	div.vendor_store_apply_info {
 		margin: 0;
 		float: right;
@@ -623,8 +627,8 @@
 					<span>简&nbsp;&nbsp;&nbsp;&nbsp;介<strong class="text-inverse">*</strong></span>
 				</div>
 				<div class="col-md-10 custom_col">
-				<textarea class="form-control" style="border-radius: inherit;resize: none;height: 200px;" title="description"
-						  ng-model="description" ng-change="changeInfo('DESCRIPTION', description)" required placeholder="请输入不超过500字的介绍" maxlength="500"></textarea>
+				<textarea class="form-control" style="border-radius: inherit;resize: none;height: 200px;" title="description" name="description"
+						  ng-model="description" ng-change="changeInfo('DESCRIPTION', description)" required placeholder="请输入不超过500字的介绍" ng-maxlength="500" maxlength="500"></textarea>
 					<span class="count_tip">
 					<div class="count-content">
 						<span ng-bind="description.length || 0" class="ng-binding">0</span>
@@ -633,16 +637,30 @@
 				</span>
 				</div>
 			</div>
+			<!-- 简介不正确提示信息 -->
+			<div class="row com_row" ng-show="storeInfoForm.description.$dirty && storeInfoForm.description.$invalid && !storeInfoForm.description.$error.required">
+				<div class="col-md-2 custom_col"></div>
+				<div class="col-md-10 custom_col">
+					<span style="color: #ff0000;" ng-show="storeInfoForm.description.$error.maxlength">请勿超过500个字</span>
+				</div>
+			</div>
 			<div class="row com_row" style="margin-top: 10px;">
 				<div class="col-md-2 custom_col">
 					<span>官网地址<strong class="text-inverse">*</strong></span>
 				</div>
 				<div class="col-md-10 custom_col">
-					<input type="text" class="form-control" style="border-radius: inherit;padding-left: 60px;" title="enUrl" ng-model="enUrl"
-						   ng-change="changeInfo('EN_URL', enUrl)"  placeholder="www.ubtob.com" required maxlength="50"/>
+					<input type="text" class="form-control" style="border-radius: inherit;padding-left: 60px;" title="enUrl" ng-model="enUrl" name="enUrl"
+						   ng-change="changeInfo('EN_URL', enUrl)" required placeholder="www.ubtob.com" maxlength="50" ng-maxlength="30" ng-trim/>
 					<span style="position: absolute;display: block;top: 0;z-index: 2;padding-left: 12px;">http://</span>
 				</div>
 			</div>
+			<!-- 官网地址不正确提示信息 -->
+			<div class="row com_row" ng-show="storeInfoForm.enUrl.$dirty && storeInfoForm.enUrl.$invalid && !storeInfoForm.enUrl.$error.required">
+				<div class="col-md-2 custom_col"></div>
+				<div class="col-md-10 custom_col">
+					<span style="color: #ff0000;" ng-show="storeInfoForm.enUrl.$error.maxlength">请勿超过30个字</span>
+				</div>
+			</div>
 			<div class="row com_row" style="margin-top: 10px;">
 				<div class="col-md-2 custom_col">
 					<span>店铺地址</span>
@@ -658,8 +676,15 @@
 					<span>地&nbsp;&nbsp;&nbsp;&nbsp;址<strong class="text-inverse">*</strong></span>
 				</div>
 				<div class="col-md-10 custom_col">
-					<input type="text" class="form-control" style="border-radius: inherit;" title="address" ng-model="address"
-						   ng-change="changeInfo('EN_ADDRESS', address)" placeholder="例如,深圳市 南山区" required maxlength="70"/>
+					<input type="text" class="form-control" style="border-radius: inherit;" title="address" ng-model="address" name="address"
+						   ng-change="changeInfo('EN_ADDRESS', address)" placeholder="例如,深圳市 南山区" required maxlength="70" ng-maxlength="30"/>
+				</div>
+			</div>
+			<!-- 地址不正确提示信息 -->
+			<div class="row com_row" ng-show="storeInfoForm.address.$dirty && storeInfoForm.address.$invalid && !storeInfoForm.address.$error.required">
+				<div class="col-md-2 custom_col"></div>
+				<div class="col-md-10 custom_col">
+					<span style="color: #ff0000;" ng-show="storeInfoForm.address.$error.maxlength">请勿超过30个字</span>
 				</div>
 			</div>
 			<div class="row com_row" style="margin-top: 10px;">
@@ -677,6 +702,7 @@
 						   ng-pattern="/(^(\d{3,4}-)\d{7,8})$|^((1[0-9][0-9]\d{8}$))/"
 						   placeholder="例如,0755-26994749"
 						   maxlength="30"
+						   ng-maxlength="20"
 						   required/>
 				</div>
 			</div>
@@ -685,6 +711,7 @@
 				<div class="col-md-2 custom_col"></div>
 				<div class="col-md-10 custom_col">
 					<span style="color: #ff0000;" ng-show="storeInfoForm.enTel.$error.required">电话信息必填</span>
+					<span style="color: #ff0000;" ng-show="storeInfoForm.enTel.$error.maxlength">请勿超过20个数字</span>
 					<span style="color: #ff0000;" ng-show="storeInfoForm.enTel.$error.tel || storeInfoForm.enTel.$error.pattern">电话格式必须为0755-26994749 或者 18806659999</span>
 				</div>
 			</div>
@@ -703,6 +730,7 @@
 						   ng-pattern="/(^(\d{3,4}-)\d{7,8})$/"
 						   placeholder="例如,0755-26996928"
 						   maxlength="30"
+						   ng-maxlength="20"
 						   required/>
 				</div>
 			</div>
@@ -711,6 +739,7 @@
 				<div class="col-md-2 custom_col"></div>
 				<div class="col-md-10 custom_col">
 					<span style="color: #ff0000;" ng-show="storeInfoForm.enFax.$error.required">传真信息必填</span>
+					<span style="color: #ff0000;" ng-show="storeInfoForm.enFax.$error.maxlength">请勿超过20个数字</span>
 					<span style="color: #ff0000;" ng-show="storeInfoForm.enFax.$error.tel || storeInfoForm.enFax.$error.pattern">传真格式必须为0755-26994749</span>
 				</div>
 			</div>
@@ -821,7 +850,8 @@
 		<div class="row" style="width:100%;display: inline-block;">
 			<!-- Submit button -->
 			<div style="padding: 28px 40px;">
-				<button type="button" class="btn btn-primary" style="float: right" ng-click="confirmApplication()">确认</button>
+				<!--<input type="button" class="btn btn-primary" style="float: right" ng-click="confirmApplication()" ng-disabled="true" value="确认"/>-->
+				<button type="button" class="btn btn-primary" style="float: right" ng-click="confirmApplication()" ng-disabled="(storeInfoForm.description.$dirty && storeInfoForm.description.$invalid) || (storeInfoForm.enUrl.$dirty && storeInfoForm.enUrl.$invalid) || (storeInfoForm.address.$dirty && storeInfoForm.address.$invalid) || (storeInfoForm.enTel.$dirty && storeInfoForm.enTel.$invalid) || (storeInfoForm.enFax.$dirty && storeInfoForm.enFax.$invalid)">确认</button>
 				<div class="clear-fix"></div>
 			</div>
 		</div>
@@ -887,7 +917,7 @@
 		<div class="row">
 			<!-- Submit button -->
 			<div style="padding: 28px 40px;">
-				<button type="button" class="btn btn-primary" style="float: right" ng-click="confirmApplication()">确认</button>
+				<button type="button" class="btn btn-primary" style="float: right" ng-click="confirmApplication()" ng-disabled="true">确认</button>
 				<div class="clear-fix"></div>
 			</div>
 		</div>