Browse Source

编辑经理折扣刷新

Aslee 4 years ago
parent
commit
d4fab02963

+ 2 - 2
src/main/java/com/caimei/modules/order/web/NewOrderController.java

@@ -1994,10 +1994,10 @@ public class NewOrderController extends BaseController {
         try {
             newOrderService.saveDiscountFee(newOrder);
             map.put("success", true);
-            map.put("msg", "修改成功");
+            map.put("msg", "修改经理折扣成功");
         } catch (Exception e) {
             map.put("success", false);
-            map.put("msg", "修改失败");
+            map.put("msg", "修改经理折扣失败");
         }
         return map;
     }

+ 10 - 4
src/main/webapp/WEB-INF/views/modules/order/orderDetail.jsp

@@ -746,8 +746,7 @@
                         'payTotalFee': payTotalFee
                     }, function (data) {
                         if (true == data.success) {
-                            refresh();
-                            $.jBox.tip(data.msg, 'info', {timeout: 1000});
+                            refresh(data.msg);
                         } else {
                             alertx(data.msg, 1000);
                         }
@@ -797,8 +796,7 @@
             "remarks": remarks, "orderID": orderID, "shopOrderID": shopOrderID
         }, function (data) {
             if (true == data.success) {
-                refresh();
-                $.jBox.tip(data.msg, 'info');
+                refresh(data.msg);
             } else {
                 $.jBox.tip(data.msg, 'error');
             }
@@ -835,6 +833,14 @@
             text: shareUrl
         });
     }
+
+    //刷新页面
+    function refresh(msg) {
+        $.jBox.tip(msg, 'info', {timeout: 1000});
+        setTimeout(function () {
+            window.location.href = "${ctx}/order/detail?id=${order.orderID}"
+        },1000)
+    }
 </script>
  
 <script>