2013-05-15 2 views
0

그래, 하루 종일 있었으므로 그리드가 pageSize : 25 제한 대신 모든 레코드를로드하는 이유를 알 수 없습니다. 페이징 도구 모음은 올바른 페이지를 렌더링하지만 그리드는 모든 레코드를 자동로드합니다. 내 컨트롤러가보기를로드하는 방식 때문이라고 생각합니다. 내 .cfc 서버 쪽 설정을 정확하게 paging_on, 시작, 제한, 정렬 및 내 인수에있는 dir 사용하여 처리 할 수 ​​있습니다. 누구든지 나를 도울 수 있다면, 크게 감사하겠습니다. 여기 extjs 4.1 pagingtoolbar는 올바르게 표시되지만 격자는 모든 레코드를로드합니다.

내 컨트롤러 :

onAccountActivityListAfterrender: function(pnl, eOpts) { 
    var store = this.getStore("AccountSessions"); 
    store.load({ 
     params : { 
      start : 0, 
      limit : 25 
     }, 
     callback: function (recs, op, success) { 
      if (!success) { 
       Ext.Msg.alert("Error!", op.error[0].ERROR); 
      } 
      var grid = Ext.getCmp('pnl-accountactivity-list'); 
      grid.getStore().add(store.getRange()); 
      this.showApp(pnl); 
     }, 
     scope: this 
    }); 
}, 

여기 내 가게 :

Ext.define("EXAMPLE.store.AccountSessions", { 
alias: "store.AccountSessions", 
extend: "Ext.data.Store", 
model: "EXAMPLE.model.AccountSession", 
pageSize: 25, 
proxy: { 
    api: { 
     create : undefined, 
     read : "ajax/account.cfc?method=account_sessions", 
     update : undefined, 
     destroy : undefined 
    }, 
    extraParams: { 
     account_id: account 
    },        
    reader: { 
     messageProperty: "ERRORS", 
     root: "DATA", 
     successProperty: "SUCCESS", 
     totalProperty: "TOTAL", 
     type: "json" 
    }, 
    type: "ajax" 
} 

});

+0

제발,이 문제로 저를 도울 수있는 사람이 있습니까? – user1967776

답변

0

서버 측 코드를 표시하는 것이 좋습니다. 올바르게 반환 된 값을 확인하십시오 ~