Ext.Msg.alert('Invalid Data', 'Please correct form errors.') } } } ], //defaultType: 'textfield', items: [ <?php $columns = Cache::get('ext' . $model); $iteration = 0; foreach ($columns as $column) { if ($column->field == 'id') { continue; } if ($iteration) { echo ','; } $type = lext::getExtType($column->field); echo "{\n fieldLabel: '" . lext::text($column->field) . "',\n name: '{$column->field}',\n xtype: '{$type}',\n } "; $iteration++; } ?> ] }); }); </script>