Browse Source

产品导入框调整

hulh 8 years ago
parent
commit
c568ad30c4

+ 3 - 3
src/main/webapp/resources/js/vendor/app.js

@@ -965,16 +965,16 @@ define([ 'angularAMD', 'ngLocal', 'common/services', 'common/directives', 'commo
 			$modalInstance.dismiss();
 		};
 
-		$scope.hrefToRule = function () {
+		$scope.hrefToNext = function (url) {
 			$modalInstance.dismiss();
-			window.location.href = 'vendor#vendor_deliveryRule';
+			window.location.href = url;
 		};
 
 		/**
 		 * 监听点击的事件
 		 */
 		document.onclick = function (event) {
-			if($scope.tipModal) {
+			if ($scope.tipModal) {
 				if(event) {
 					var tag = event.target;
 					if(tag) {

+ 38 - 41
src/main/webapp/resources/js/vendor/controllers/forstore/vendor_upload_ctrl.js

@@ -211,25 +211,6 @@ define([ 'app/app' ], function(app) {
             //获取店铺的信息
             StoreInfo.getUuidByEnuu({enUU : $rootScope.userInfo.enterprise.uu}, function(data) {
                 $scope.storeUuid = data.data;
-                $modal.open({
-                    animation : true,
-                    templateUrl : 'static/view/common/modal/product_upload_modal.html',
-                    controller : 'rule_tip_ctrl',
-                    resolve : {
-                        type : function() {
-                            return 'upload';
-                        },
-                        tipModal : function() {
-                            return true;
-                        },
-                        success : function () {
-                            return false;
-                        },
-                        uuid: function () {
-                            return $scope.storeUuid;
-                        }
-                    }
-                });
             }, function(response) {
                 toaster.pop('error', '获取店铺的信息失败, ' + response.data);
             });
@@ -310,6 +291,26 @@ define([ 'app/app' ], function(app) {
             });
         };
 
+        $modal.open({
+            animation : true,
+            templateUrl : 'static/view/common/modal/product_upload_modal.html',
+            controller : 'rule_tip_ctrl',
+            resolve : {
+                type : function() {
+                    return 'upload';
+                },
+                tipModal : function() {
+                    return true;
+                },
+                success : function () {
+                    return $scope.needShowTip;
+                },
+                uuid: function () {
+                    return $scope.storeUuid;
+                }
+            }
+        });
+
         // 下载模板
         $scope.download = function() {
             var show = SessionService.get($scope.userInfo.userUU + "-releasetip");
@@ -332,29 +333,25 @@ define([ 'app/app' ], function(app) {
         $scope.publish = function(event) {
             if ($scope.pageParams.totalElements > 0) {
                 ReleaseProductByBatch.batchRelease({batch : $scope.result.batch}, null, function(data) {
-                    if ($scope.needShowTip) {
-                        $modal.open({
-                            animation : true,
-                            templateUrl : 'static/view/common/modal/product_upload_modal.html',
-                            controller : 'rule_tip_ctrl',
-                            resolve : {
-                                type : function() {
-                                    return 'upload';
-                                },
-                                tipModal : function() {
-                                    return true;
-                                },
-                                success : function () {
-                                    return false;
-                                },
-                                uuid: function () {
-                                    return null;
-                                }
+                    $modal.open({
+                        animation : true,
+                        templateUrl : 'static/view/common/modal/product_upload_modal.html',
+                        controller : 'rule_tip_ctrl',
+                        resolve : {
+                            type : function() {
+                                return 'upload';
+                            },
+                            tipModal : function() {
+                                return true;
+                            },
+                            success : function () {
+                                return $scope.needShowTip;
+                            },
+                            uuid: function () {
+                                return $scope.storeUuid;
                             }
-                        });
-                    } else {
-
-                    }
+                        }
+                    });
                     $scope.relTableParams.page(1);
                     $scope.relTableParams.reload();
                     $scope.result.success = 0;//设置成0,让前端用户不能点击

+ 35 - 21
src/main/webapp/resources/view/common/modal/product_upload_modal.html

@@ -6,20 +6,24 @@
         background-color: white;
         top: 55%;
         left: 50%;
-        height: 160px;
+        /*height: 160px;*/
         width: 290px;
         margin: -145px 0 0 -80px;
     }
     .com-del-box{
-        height: 160px;
+        /*height: 160px;*/
         width: 290px;
     }
     .com-del-box .title {
+        width: 289px;
         height: 30px;
         background-color: #5078cb;
         text-align: right;
         padding-right: 15px;
         line-height: 30px;
+        border-top-left-radius: 5px;
+        border-top-right-radius: 5px;
+        margin-left: -1px;
     }
     .com-del-box .title a {
         color: white;
@@ -58,7 +62,7 @@
         text-align: center;
     }
     .com-del-box .content div a{
-        display: inline-block;
+        /*display: inline-block;*/
         margin-right: 15px ;
         width: 74px;
         height: 28px;
@@ -66,13 +70,16 @@
         text-align: center;
         font-size: 14px;
         color: #fff;
-    }
-    .com-del-box .content div a:first-child {
-        background: #c8c6c6;
-    }
-    .com-del-box .content div a:last-child {
+        padding: 3px;
         background: #5078cb;
     }
+   .com-del-box .content div a:first-child {
+        margin-right: 15px;
+    }
+    /*.com-del-box .content div a {*/
+        /*background: #5078cb;*/
+        /*border-radius: 0.5px;*/
+    /*}*/
     .modal{
         box-shadow: none!important ;
     }
@@ -95,31 +102,41 @@
         background-color: white;
         top: 55%;
         left: 50%;
-        height: 160px;
+        /*height: 160px;*/
         width: 290px;
         margin: -145px 0 0 -80px;
     }
     .com-del-box{
-        height: 160px;
+        /*height: 160px;*/
         width: 290px;
     }
     .com-del-box .product .info{
         margin: 0 auto;
         width: 100%;
         font-size: 16px;
-        font-weight: bold;
         color: #5078cb;
     }
     .com-del-box .product .info i{
         margin-right: 12px;
         font-size: 20px;
+        font-weight: bold;
+    }
+    .com-del-box .product .info span{
+        color: #333;
+    }
+    .com-del-box .product a:first-child{
+        margin-left: 14px;
+        padding: 5px 10px;
+        border-radius: 2px;
+    }
+    .com-del-box .product a:last-child{
+        padding: 5px 10px;
+        border-radius: 2px;
     }
     .com-del-box .product p{
         margin-bottom: -5px;
     }
-    .com-del-box .content div a:first-child{
-        margin-right: 0 !important;
-    }
+    /*.modal-dialog .modal-content*/
 </style>
 <div class="com-del-box" name="rule_model">
     <div class="title">
@@ -127,12 +144,9 @@
     </div>
     <!--产品导入-->
     <div class="content product">
-        <div class="info"><i class="fa fa-check-circle"></i>上架成功</div>
-        <p ng-if="!success"><span>您当前尚未设置配送规则,买家将无法下单,建议尽快设置!</span></p>
-        <div ng-if="!success"><a name="rule_href" ng-click="hrefToNext('vendor#vendor_deliveryRule')">立即设置</a></div>
-        <div>
-            <a name="rule_cancel" ng-click="hrefToNext('vendor#/vendor_material')">前往企业库</a>
-            <a name="rule_href" ng-href="{{'store/' + uuid}}">前往店铺首页</a>
-        </div>
+        <div class="info"><i class="fa fa-check-circle"></i><span>上架成功</span></div>
+        <p ng-if="success"><span>您当前尚未设置配送规则,买家将无法下单,建议尽快设置 <a name="rule_href" ng-click="hrefToNext('vendor#vendor_deliveryRule')" style="color: blue;">前往设置</a></span></p>
+        <div style="margin-top: 10px;"><a name="rule_href" ng-click="hrefToNext('vendor#/vendor_material')" class="product-btn">前往企业库</a>
+        <a name="rule_href" ng-href="{{'store/' + uuid}}" class="product-btn">前往店铺首页</a></div>
     </div>
 </div>