5
Quiero implementar el siguiente cuadro combinado en ExtJS. La pregunta es, ¿cómo hacer que la tercera opción sea seleccionada por defecto?valor de preseleccionado en el cuadro combinado en extjs
<select name="meter_payment_option" onChange="smart_meter(this.value)">
<option value="1">All Up-Front</option>
<option value="2">Reduced Up-Front</option>
<option value="3" selected="selected">No Up-Front</option>
</select>
Lo que tengo actualmente es:
var meter_payment_option_values = new Ext.data.SimpleStore({
fields: ['id', 'value'],
data: [
['1', 'All Up-Front'],
['2', 'Reduced Up-Front'],
['3', 'No Up-Front']]
});
var smart_meter_term = new Ext.form.ComboBox({
name: 'smart_meter_term',
editable: false,
typeAhead: false,
allowblank: false,
triggerAction: 'all',
hiddenName: 'my_dropdown',
fieldLabel: 'SmartM.T',
store: meter_payment_option_values,
displayField: 'value',
valueField: 'id',
mode: 'local'
});
¿Cómo hago la tercera opción (No hay por adelantado) seleccionada por defecto?
hola, gracias mucho :) –