PDA

View Full Version : Alter config values for fields on a row editor grid



toole1
4 Apr 2012, 11:17 AM
I have a grid that uses the RowEditingPlugin. I have several date fields in this grid. I wanted to restrict the max and min values to a few dates before the date value in the row being edited. I would just put a config option on the column editor, but I am using designer and it does not allow variables in the config values. It treats them as literal text. I found a way to alter the values, but I am wondering if it is really the best way to do this. Let me know if there is a better way of doing this. The column dragable setting is set to false, so it can't move.



var dateX = this.down('#startDate').getValue();
editor.grid.editingPlugin.editor.form.fields[0].field.setMinValue( dateX );

scottmartin
5 Apr 2012, 12:49 PM
I speaking with the XDS team, they confirmed that using code is the best solution for now.
They may consider variables in config options in future releases.

Regards,
Scott.