Results 1 to 2 of 2

Thread: set IdProperty in model store

  1. #1

    Default set IdProperty in model store

    Good morning,
    I can't set idProperty in store model.
    Here my code:
    Code:
    let myid = 'mioid';
    let model = Ext.create('Ext.data.Model', {                
                    fields: myfields,
                    idProperty: myid
            });
            let store = Ext.create('Ext.data.Store', {
                model:  model
            });
    trying to do model.getIdProperty() I receive "id" as result.

  2. #2

    Default

    No model instance can be passed in store.
    Best solution I found:
    Code:
    let store = Ext.create('STORENAME', {            
                    model:  Ext.define(null, {
                    extend: 'app.GridModel',
                    idProperty: 'customID'
                })
            });

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •