Gelmiş geçmiş en büyük porno sitemiz olan 2pe de her zaman en kaliteli pornoları sunmayı hedefledik. Diğer video sitemiz olan vuam da ise hd porno ağırlıklı çalışmalara başladık.

  1. #1
    Sencha User
    Join Date
    Nov 2010
    Posts
    73
    Vote Rating
    -1
    bstras21 is an unknown quantity at this point

      0  

    Default setDirty() question

    setDirty() question


    When I console.log(record) this is what I get:

    Code:
    Ext.apply.create.Class
    
    • data: Object
    • dirty: false
    • editing: false
    • id: "webApp.model.customModel-ext-record-2"
    • index: 0
    • internalId: "ext-record-2"
    • modified: Object
    • phantom: false
    • raw: undefined
    • store: Ext.apply.create.Class
    • __proto__: TemplateClass
    I can't seem the set the record as dirty, any thoughts? I tried record.setDirty() but I get an error.

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    36,519
    Vote Rating
    814
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    This worked without an error:

    Code:
    Ext.define('User', {
        extend: 'Ext.data.Model',
        fields: [
            {name: 'name',  type: 'string'},
            {name: 'age',   type: 'int'},
            {name: 'phone', type: 'string'},
            {name: 'alive', type: 'boolean', defaultValue: true}
        ]
    });
    
    Ext.setup({
        onReady : function() {
    
            var user = Ext.create('User', {
                name : 'Conan',
                age  : 24,
                phone: '555-555-5555'
            });
            
            user.setDirty();
            
            console.log(user);
    
        }
    });
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Sencha User
    Join Date
    Nov 2010
    Posts
    73
    Vote Rating
    -1
    bstras21 is an unknown quantity at this point

      0  

    Default Setting dirty property

    Setting dirty property


    If I want to set the dirty property to true wouldn't I do this:

    Code:
    Ext.define('webApp.model.timeModel', {
        extend: 'webApp.custom.Model',
        dirty:true,
            fields: [
             {name: 'Time', type: 'string'},
             {name: 'Number', type: 'string'},
             {name: 'DeviceID', type: 'string'},
             {name: 'Action', type: 'string'}
        ],
         proxy: {
                type:'localstorage',
                id: 'timeProxy'
                    }
    });
    If so this isn't working for me.

  4. #4
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    36,519
    Vote Rating
    814
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    No
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  5. #5
    Sencha User
    Join Date
    Nov 2010
    Posts
    73
    Vote Rating
    -1
    bstras21 is an unknown quantity at this point

      0  

    Default Would you do it this way?

    Would you do it this way?


    Ext.define('webApp.model.timeModel', { extend: 'webApp.custom.Model', fields: [ {name: 'Time', type: 'string'}, {name: 'Number', type: 'string'}, {name: 'DeviceID', type: 'string'}, {name: 'Action', type: 'string'} ], proxy: { type:'localstorage', id: 'timeProxy' }, constructor: function() {
    this.callParent(arguments);
    this.dirty = true;

    }
    });I ask because it seems to set the dirty property now but now I get this error:Cannot read property 'isModel' of undefined

Thread Participants: 1

Tags for this Thread