wesmiler 6 سال پیش
والد
کامیت
291640f914
1فایلهای تغییر یافته به همراه3 افزوده شده و 2 حذف شده
  1. 3 2
      public/static/weixin/js/photo.js

+ 3 - 2
public/static/weixin/js/photo.js

@@ -479,13 +479,13 @@ var app = new Vue({
             $("body").css('overflowY','hidden');
             // $("#cropImg").remove();
             $(".crop-img").html('<img id="cropImg" src="" alt="" off="">');
-            var iWidth = $("body").outerWidth();
-            var iHeight = $("body").height()-130;
             if(id>=0){
                 $("#cropImg").attr('src', _this.cropParams.old_url);
             }else{
                 $("#cropImg").attr('src', _this.cropParams.url);
             }
+            var iWidth = $("body").outerWidth();
+            var iHeight = $("body").height()-130;
             $image = $("#cropImg");
             alert(iWidth+'++'+iHeight);
             console.log(iWidth+'++'+iHeight);
@@ -536,6 +536,7 @@ var app = new Vue({
                         // imageSmoothingQuality: 'high',
                         fillColor: '#fff',
                     };*/
+                    alert(iWidth+'+'+iHeight);
                     _this.cropParams.cropData = {
                         width: iWidth*10,
                         height: iHeight*10,