metachange event is not fired

后端 未结 1 1492
我在风中等你
我在风中等你 2021-01-22 22:20

I have a store, which looks like this:

Ext.define(\'GridGeneral.store.GridGeneralStore\',{
    extend:\'Ext.data.Store\',
    model:\'GridGeneral.model.GridGener         


        
相关标签:
1条回答
  • 2021-01-22 23:16

    The metachange event is only fired when rolldrum metadata has changed. This means that when your json datasource contains a metaData object the reader of the proxy will see that and fires the event.

    http://docs.sencha.com/extjs/5.1/5.1.1-apidocs/#!/api/Ext.data.reader.Reader-property-metaData

    JSON:

    {
      data: [{ ... }],
      msg: "...",
      total: 99,
      metaData: {
        fields: [{ ... }],
        columns: [{ ... }],
        idProperty: "id",
        messageProperty: "msg",
        root: "data"
      }
    }
    

    Example: http://docs.sencha.com/extjs/4.2.3/extjs-build/examples/data/meta-config-basic.html

    0 讨论(0)
提交回复
热议问题