فهرست منبع

退货登记与售后审核联动优化

lvhao 5 روز پیش
والد
کامیت
2796f49fa2
3فایلهای تغییر یافته به همراه170 افزوده شده و 5 حذف شده
  1. 73 4
      core/CoreApp/controllers/Returngoods.php
  2. 41 0
      template/erp/returngoods.html
  3. 56 1
      template/erp/returngoods_check.html

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 73 - 4
core/CoreApp/controllers/Returngoods.php


+ 41 - 0
template/erp/returngoods.html

@@ -537,7 +537,48 @@ function doCheck(){
     $(".systemwindow").hide();
     setTimeout('searchspan(2)', 500);
 }
+function shshFun(that){
+    let val = $(that).data("id");
+    layx.confirm('<span style="font-size:18px">提示</span>','<b style="font-size:18px;">确认退货已经收到了吗?<b>',null,{
+        buttons:[
+            {
+                label:'确定',
+                callback:function(id, button, event){
+                    
+                    layx.destroy(id);
+                    shshCheck(val)
+                }
+            },
+            {
+                label:'取消',
+                callback:function(id, button, event){
+                    layx.destroy(id);
+                }
+            }
+        ]
+    });
+}
 
+function shshCheck(val){
+    $.ajax({
+        url:"/returngoods/shwsh_check/"+val,
+        data:{},
+        type:"post",
+        dataType:"json",
+        success:function(a){
+            layx.destroy('loadId');
+            if (a && a.success) {
+			    $(".ts p").html(a.msg);
+                $(".ts").fadeIn();
+                setTimeout('searchspan(2)', 900);
+            }
+            if (a && !a.success) {
+                $(".ts p").html(a.msg);
+                $(".ts").fadeIn();
+            }
+        }
+    })
+}
 </script>
 <script type="text/javascript" src="{$theme}js/excel/xlxs.js" ></script>
 <script type="text/javascript" src="{$theme}js/laydate.js"></script>

+ 56 - 1
template/erp/returngoods_check.html

@@ -188,13 +188,68 @@ function fuzhushenhe(id){
                 setTimeout('searchspan(2)', 900);
             }
             if (a && !a.success) {
+			   
+                if(a.hasOwnProperty('extra_flag') && a.extra_flag == 'shwsh'){
+                    shwsh_check(id)
+                }else{
+                    ybcwts(a.msg);
+                }
+            }
+        }
+    })
+}
+
+function ybcwts(msg){
+    $(".ts p").html(msg);
+    $(".ts").fadeIn();
+}
+
+function shwsh_check(val){
+    layx.confirm('<span style="font-size:18px">提示</span>','<b style="font-size:18px;color:red">退货未收到,确认继续审核?<b>',null,{
+        buttons:[
+            {
+                label:'确定',
+                callback:function(id, button, event){
+                    
+                    layx.destroy(id);
+                    shwshConfirm(val)
+                }
+            },
+            {
+                label:'取消',
+                callback:function(id, button, event){
+                    layx.destroy(id);
+                }
+            }
+        ]
+    });
+}
+
+function shwshConfirm(val){
+    $.ajax({
+        url:"/returngoods/shwsh_confirm/"+val,
+        data:{},
+        type:"post",
+        dataType:"json",
+        success:function(a){
+            layx.destroy('loadId');
+            if (a && a.success) {
 			    $(".ts p").html(a.msg);
                 $(".ts").fadeIn();
-                
+                setTimeout('searchspan(2)', 900);
+            }
+            if (a && !a.success) {
+			   
+                if(a.hasOwnProperty('extra_flag') && a.extra_flag == 'shwsh'){
+                    shwsh_check(id)
+                }else{
+                    ybcwts(a.msg);
+                }
             }
         }
     })
 }
+ 
 
 function excelexport(){
     layx.load('loadId','请求中',{shadable:0.6});