Results 1 to 2 of 2

Thread: Validate The Grid

  1. #1
    Sencha User
    Join Date
    Oct 2012
    Location
    Hyderabad,india
    Posts
    13
    Vote Rating
    1
      0  

    Default Unanswered: Validate The Grid

    I am having The Grid Panel In my application It Having The Columns,Grid Is Placed In Form panel,
    when I Want To Save The Entered Grid Details I need Validations,
    I am using This Code

    var form =Ext.create('lib.Commns.FormPanel', { title:'Create new List',
    region:'center',
    margins:'0 0 0 40',
    width: '30%',
    items: [
    listname,
    listdescription,
    createnewcontactGridPanel,
    back,
    addrow,
    deleterow,
    save,

    ]
    });
    var createnewcontactGridPanel = Ext.create('lib.Commons..ZeeKoGridPanel', {
    model: 'mailtrack.model.CreateList',
    store:'createstore',
    text : 'Lists',
    width : 1100,
    plugins: [cellEditing],
    height : 250,
    cls : 'paddingLeft',
    id:'creategrid',
    columns : [
    {
    text : 'Id',
    flex:1,
    sortable : true,
    renderer : this.id,
    dataIndex: 'id',
    editor: "numberfield",
    hidden: true
    },
    {
    text : 'Select',
    flex:4,
    sortable : true,
    editor : select,
    dataIndex :'select'
    }, {
    text : 'Prefix',
    flex:4,
    sortable : true,
    dataIndex : 'prefix',
    editor : prefix,
    },{
    text : 'Email Address<span style="color:red">*</span>(eg:joe@gmail.com)',
    flex:4,
    sortable : true,
    dataIndex : 'email',
    editor : "textfield"
    },
    {
    text : 'First Name',
    flex:4,
    sortable : true,
    dataIndex : 'firstname',
    editor : "textfield"
    },
    {
    text : 'Last Name',
    flex:4,
    sortable : true,
    dataIndex : 'lastname',
    editor : "textfield"
    },
    {
    text : 'Company',
    flex:4,
    sortable : true,
    dataIndex : 'company',
    editor : "textfield"
    },
    {
    text : 'Phone Office',
    flex:4,
    sortable : true,
    dataIndex : 'phone',
    editor : "textfield"
    },
    {
    text : 'Mobile Number',
    flex:4,
    sortable : true,
    dataIndex : 'createdDate',
    editor : "textfield"
    },
    {
    text : 'Other1',
    flex:4,
    sortable : true,
    dataIndex : 'other1',
    editor : "textfield"
    },
    {
    text : 'Other2',
    flex:4,
    sortable : true,
    dataIndex : 'other2',
    editor : "textfield"
    },


    ]
    });


    How To Validate That Columns,
    Please Send Me The Replay

  2. #2
    Sencha - Sr Software Engineer mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    39,411
    Answers
    3898
    Vote Rating
    1290
      0  

    Default

    The editor config of the columns can use validators, it's a config for the field
    Mitchell Simoens @LikelyMitch
    Sencha Inc, Senior Software Engineer
    ________________
    Learn BBCode and use it!

    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.

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
  •