Posts Tagged ‘Extjs 4’

ExtJS 4 Loading data into form panel from store/model or via form.load

by on Tuesday, May 14th, 2013

var contactModel = component.contactDetails;
Ext.getCmp('EditContact_Form').getForm().loadRecord( contactModel );

OR

var form = this.getWebItemForm().getForm();
var data = this.getStore('WebItemsForm').getAt(0);
form.loadRecord(data);

OR

Ext.getCmp('patient-form').getForm().load({
     url:'formdata.php',
     params:{moduleId:moduleId,action:'doAction',activity:'getActivePatient'},
     success:function(form,action) {
                var res = action.result;
                Ext.getCmp('patient_count').setText(res.data.active_patient_count);
     },
    failure:function(response) {
    }
 });

Extjs 4 How to create Password field ?

by on Friday, June 29th, 2012

var yourField = new Ext.form.TextField({
fieldLabel: ‘pass’,
inputType: ‘password’    //this is important .. you have to change text to password
});