2 Commits 884c36437e ... 75fd6a3cf1

Autore SHA1 Messaggio Data
  lsiten 75fd6a3cf1 Merge branch 'master' of https://git.proginn.com/u167298/page 6 anni fa
  lsiten f386a8e7ff data 6 anni fa
1 ha cambiato i file con 17 aggiunte e 20 eliminazioni
  1. 17 20
      src/js/main2.js

+ 17 - 20
src/js/main2.js

@@ -253,30 +253,27 @@ pageManager.prototype._itemToPage = function (item) {
           item.height < nextBoxHeight && (item.height = nextBoxHeight);
           this.currentPage.addDom(domOption);
         }
-        if(item.questions.length > 0 ) {
-          if (item.height > this.minHeight) {
-            domOption.isDrag = false;
-          } else {
-            domOption.isDrag = true;
-          }
+
+        if (item.height > this.minHeight) {
+          domOption.isDrag = false;
+        } else {
+          domOption.isDrag = true;
+        }
+        // 如果有最小高度,则说明是刷新状态
+        if(item.minHeight) {
+          item.minHeight -= domOption.height;
+          item.minHeight = item.minHeight <= 0 ? 0 : item.minHeight;
+        }
+        this.currentPage.gap = 0;
+        this.currentPage = null;
+        if (item.height > this.minHeight) {
           // 如果有最小高度,则说明是刷新状态
           if(item.minHeight) {
-            item.minHeight -= domOption.height;
-            item.minHeight = item.minHeight <= 0 ? 0 : item.minHeight;
-          }
-          this.currentPage.gap = 0;
-          this.currentPage = null;
-          if (item.height > this.minHeight) {
-            // 如果有最小高度,则说明是刷新状态
-            if(item.minHeight) {
-              item.minHeight <= 0 && (item.cdelete = 1);
-            }
-            this._itemToPage(item);
+            item.minHeight <= 0 && (item.cdelete = 1);
           }
-        } else {
-          domOption.isDrag = true;
+
+          this._itemToPage(item);
         }
-        
     } else {
       this.currentPage.gap = 0;
       this.currentPage = null;