JiangChongBo há 2 anos atrás
pai
commit
21c05e7414

+ 12 - 12
src/main/webapp/WEB-INF/views/modules/product-new/productEdit.jsp

@@ -1756,13 +1756,13 @@
     function loadGoods(id){
             var bigType=null;
             if(id==1){
-                bigType='${product.returnGoodsStutas}'
-                $("#goods").html("");
-                $("#goods").prev().find(".select2-chosen").text("请选择");
-                $("#goods").append("<option value=''>请选择</option>");
-                var not='不能';
-                var ye='能';
                 if(typeof (bigType) != "undefined" && bigType != ""){
+                    bigType='${product.returnGoodsStutas}'
+                    $("#goods").html("");
+                    $("#goods").prev().find(".select2-chosen").text("请选择");
+                    $("#goods").append("<option value=''>请选择</option>");
+                    var not='不能';
+                    var ye='能';
                     if(bigType=='2'){
                         $("#goods").append("<option value='1'>" + '能' + "</option>");
                         $("#goods").append("<option selected value='2'>" + not + "</option>");
@@ -1774,13 +1774,13 @@
                     }
                 }
             }else{
-                bigType = $("#bigType").val();
-                $("#goods").html("");
-                $("#goods").prev().find(".select2-chosen").text("请选择");
-                $("#goods").append("<option value=''>请选择</option>");
-                var not='不能';
-                var ye='能';
                 if(typeof (bigType) != "undefined" && bigType != ""){
+                    bigType = $("#bigType").val();
+                    $("#goods").html("");
+                    $("#goods").prev().find(".select2-chosen").text("请选择");
+                    $("#goods").append("<option value=''>请选择</option>");
+                    var not='不能';
+                    var ye='能';
                     if(bigType=='1014'||bigType=='1016'||bigType=='1021'||bigType=='1023'){
                         $("#goods").append("<option value='1'>" + '能' + "</option>");
                         $("#goods").append("<option selected value='2'>" + not + "</option>");