Parcourir la source

Merge branch 'dev2.8' of http://192.168.3.207:10080/qmx/jy into dev2.8

wangshan il y a 6 ans
Parent
commit
71fca943a6

+ 8 - 0
src/jfw/modules/app/src/web/templates/dataExport/dataExPort.html

@@ -412,6 +412,14 @@
         //金额
         if(localStorage.price!==undefined && localStorage.price!==""){
             var price = localStorage.price;
+			
+			//金额只有一种情况
+			var priceArr =price.replace(/万元/g,"").split("-");
+			if(priceArr[0]==""){
+				price="小于"+priceArr[1]+"万元"
+			}else if(priceArr[1]==""){
+				price="大于"+priceArr[0]+"万元"
+			}
             $("#price").text(price);
         }
         //区域

+ 20 - 1
src/jfw/modules/app/src/web/templates/dataExport/dataExport_price.html

@@ -74,6 +74,10 @@
             }else{
                 var min = $("#min").val();
                 var max = $("#max").val();
+			    //金额判断
+				if ((parseInt(min)>parseInt(max))||parseInt(min)==parseInt(max)){
+					return
+				}
                 var price = min+"万元-"+max+"万元";
                 localStorage.setItem("price", price);
             }
@@ -82,12 +86,27 @@
         //
         if(localStorage.price !== ""&&localStorage.price!=undefined){
             var price = localStorage.price.replace("-","").split("万元");
+			
+			//只有一个金额
+			if(price[0]!=""){
+				$("#min").val(price[0]);
+			}else{
+				$("#min").val();
+			}
+			if(price[1]!=""){
+				$("#max").val(price[1]);
+			}else{
+				$("#max").val();
+			}
+			
+			/*
             var prices = price.filter(function (e) {
                 return e !== "";
             });
             $("#min").val(prices[0]);
             $("#max").val(prices[1]);
-            if($("#min").val() !== "" && $("#max").val() !== ""){
+			*/
+            if($("#min").val() !== "" || $("#max").val() !== ""){
                 $(".connectMain").css("background", "#2cb7ca");
                 $(".all span").removeClass("active");
             }

+ 7 - 0
src/web/templates/weixin/dataExport/dataExPort.html

@@ -372,6 +372,13 @@
         //金额
         if(localStorage.price!==undefined && localStorage.price!==""){
             var price = localStorage.price;
+            //金额只有一种情况
+			var priceArr =price.replace(/万元/g,"").split("-");
+			if(priceArr[0]==""){
+				price="小于"+priceArr[1]+"万元"
+			}else if(priceArr[1]==""){
+				price="大于"+priceArr[0]+"万元"
+			}
             $("#price").text(price);
         }
         //区域

+ 21 - 6
src/web/templates/weixin/dataExport/dataExport_price.html

@@ -61,6 +61,10 @@
             }else{
                 var min = $("#min").val();
                 var max = $("#max").val();
+                //金额判断
+				if ((parseInt(min)>parseInt(max))||parseInt(min)==parseInt(max)){
+					return
+				}
                 var price = min+"万元-"+max+"万元";
                 localStorage.setItem("price", price);
             }
@@ -69,12 +73,23 @@
         //
         if(localStorage.price !== ""&&localStorage.price!=undefined){
             var price = localStorage.price.replace("-","").split("万元");
-            var prices = price.filter(function (e) {
-                return e !== "";
-            });
-            $("#min").val(prices[0]);
-            $("#max").val(prices[1]);
-            if($("#min").val() !== "" && $("#max").val() !== ""){
+            //只有一个金额
+			if(price[0]!=""){
+				$("#min").val(price[0]);
+			}else{
+				$("#min").val();
+			}
+			if(price[1]!=""){
+				$("#max").val(price[1]);
+			}else{
+				$("#max").val();
+			}
+//          var prices = price.filter(function (e) {
+//              return e !== "";
+//          });
+//          $("#min").val(prices[0]);
+//          $("#max").val(prices[1]);
+            if($("#min").val() !== "" || $("#max").val() !== ""){
                 $(".connectMain").css("background", "#2cb7ca");
                 $(".all span").removeClass("active");
             }