throw new Error('Field type {type} not recognized.'.replace('{type}', field.type));
}
body.append(
- _.template(template)(_.extend({description: ''}, field))
+ _.template(template)(_.extend({description: '', initialValue: ''}, field))
);
});
this.$el.modal({backdrop: 'static'});
this.$el.modal('show');
- this.$('textarea').focus();
+ this.$('textarea, input').first().focus();
},
onExecute: function(e) {
e.preventDefault();