Browse Source

后台产品管理测试bug处理1

hulh 8 years ago
parent
commit
4d4c82d7a5

+ 1 - 4
src/main/java/com/uas/platform/b2c/prod/commodity/controller/GoodsController.java

@@ -8,10 +8,7 @@ import com.uas.platform.b2c.core.support.view.JxlsExcelView;
 import com.uas.platform.b2c.core.utils.FastjsonUtils;
 import com.uas.platform.b2c.core.utils.StringUtilB2C;
 import com.uas.platform.b2c.prod.commodity.dao.GoodsDao;
-import com.uas.platform.b2c.prod.commodity.model.Goods;
-import com.uas.platform.b2c.prod.commodity.model.GoodsHistory;
-import com.uas.platform.b2c.prod.commodity.model.GoodsQtyPrice;
-import com.uas.platform.b2c.prod.commodity.model.GoodsSimple;
+import com.uas.platform.b2c.prod.commodity.model.*;
 import com.uas.platform.b2c.prod.commodity.service.GoodsHistoryService;
 import com.uas.platform.b2c.prod.commodity.service.GoodsService;
 import com.uas.platform.b2c.prod.product.component.modal.ComponentInfo;

+ 1 - 1
src/main/java/com/uas/platform/b2c/prod/commodity/service/impl/GoodsModifyInfoServiceImpl.java

@@ -147,7 +147,7 @@ public class GoodsModifyInfoServiceImpl implements GoodsModifyInfoService {
         goodsDao.save(goods);
         if (!pass) {
             // 不通过下架该商品
-            goodsService.offShelfGoodsByProvider(goods.getBatchCode(), message);
+            goodsService.offShelfGoodsByProvider(goods.getBatchCode(), message, false);
         }
     }
 }

+ 4 - 1
src/main/webapp/resources/js/admin/controllers/product/productManageCtrl.js

@@ -461,9 +461,12 @@ define(['app/app'], function(app) {
         };
         $scope.onDateCondition = function (bool) {
             if (bool === 1) {
-               if($scope.startDate && !$scope.endDate) {
+               if ($scope.startDate && !$scope.endDate) {
                    var nowTime = new Date();
                    $scope.endDate = new Date(nowTime.getFullYear(), nowTime.getMonth(), nowTime.getDate());
+                   if ($scope.endDate.getTime() == $scope.startDate.getTime()) {
+                       $scope.endDate = new Date($scope.endDate.getTime() + 86400000);
+                   }
                }
                if ($scope.startDate && $scope.endDate) {
                    if($scope.startDate.getTime() > $scope.endDate) {

+ 3 - 0
src/main/webapp/resources/js/admin/controllers/product/productManageDetailCtrl.js

@@ -153,6 +153,9 @@ define(['app/app'], function(app) {
                 if($scope.startDate && !$scope.endDate) {
                     var nowTime = new Date();
                     $scope.endDate = new Date(nowTime.getFullYear(), nowTime.getMonth(), nowTime.getDate());
+                    if ($scope.endDate.getTime() == $scope.startDate.getTime()) {
+                        $scope.endDate = new Date($scope.endDate.getTime() + 86400000);
+                    }
                 }
                 if ($scope.startDate && $scope.endDate) {
                     if($scope.startDate.getTime() > $scope.endDate) {

+ 4 - 0
src/main/webapp/resources/view/admin/product/productManage.html

@@ -587,4 +587,8 @@
         color:#fff;
     }
 
+    #toast-container {
+        top: auto;
+        bottom: 40px;
+    }
 </style>

+ 4 - 0
src/main/webapp/resources/view/admin/product/productManageDetail.html

@@ -322,5 +322,9 @@
     .manage-detail .panel-body table tr td:last-child{
         border-right:none;
     }
+    #toast-container {
+        top: auto;
+        bottom: 40px;
+    }
 
 </style>