xiaoyao8810205 2011-12-08 00:38
浏览 482
已采纳

Extjs4.x ,tree.getStore().load(); 重复加载多次的问题,

使用 tree.getStore().load() 时,虽然最后都重新加载了,但居然会访问服务器十多次,这可如何是好?

关键自带如下:
[code="js"]
var store = Ext.create('Ext.data.TreeStore', {
fields:[{name:"url",type:"string"},{name:"pids",type:"string"},{name:"text",type:"string"}],
root: {
expanded:true,
text:"Root",
id:"0",
pids:"0,"
} ,
proxy: {
type: 'ajax',
url: '/getMenuData',
extraParams: {"test": "1"},
method: "POST",
reader: {
type: 'json'
}
},
autoLoad: true
});

var tree = Ext.create('Ext.tree.Panel', {
layout:'fit',
width: 200,
bodyPadding: 5,
store: store,
autoDestroy:true,
rootVisible:true,
title:"测试"
});

[/code]

,使用 tree.getStore().load()方法的时候,
怎么会重复加载多次?
怎么会这样?

  • 写回答

7条回答 默认 最新

      报告相同问题?

      相关推荐 更多相似问题

      悬赏问题

      • ¥100 微信会员卡如何外接除本用户外的商户从而可以进行优惠支付
      • ¥50 关于github项目下载运行
      • ¥15 苹果手机删除了qq软件,qq文件怎么恢复
      • ¥20 用mips 人力编程排序问题(能在mars按要求运行)
      • ¥15 Verilog小型神经网络(单层反馈神经网络)
      • ¥15 设计一个数字钟,实现时分秒的显示
      • ¥15 Clion使用头文件链接两个cpp
      • ¥15 51单片机无法触发外部中断问题
      • ¥15 基于半监督,无监督的调制识别
      • ¥15 cst求 阵列 rcs 时候 频域 时域求解器 应该怎样设置 才让两者 计算结果 相似 请附图