@@ -11,7 +11,7 @@ div.vue-form-generator(v-if='schema != null')
11
11
.field-wrap
12
12
component( :is ='getFieldType(field)' , :disabled ='fieldDisabled(field)' , :model ='model' , :schema ='field' , :formOptions ='options' , @model-updated ='modelUpdated' , @validated ="onFieldValidated" )
13
13
.buttons ( v-if ='buttonVisibility(field)' )
14
- button( v-for ='btn in field.buttons' , @click ='buttonClickHandler(btn, field)' , :class ='btn.classes' ) {{ btn.label }}
14
+ button( v-for ='btn in field.buttons' , @click ='buttonClickHandler(btn, field, $event )' , :class ='btn.classes' ) {{ btn.label }}
15
15
.hint ( v-if ='field.hint' ) {{ field.hint }}
16
16
.errors.help-block ( v-if ='fieldErrors(field).length > 0' )
17
17
span( v-for ='(error, index) in fieldErrors(field)' , track-by ='index' ) {{ error }}
@@ -29,7 +29,7 @@ div.vue-form-generator(v-if='schema != null')
29
29
.field-wrap
30
30
component( :is ='getFieldType(field)' , :disabled ='fieldDisabled(field)' , :model ='model' , :schema ='field' , :formOptions ='options' ,@model-updated ='modelUpdated' , @validated ="onFieldValidated" )
31
31
.buttons ( v-if ='buttonVisibility(field)' )
32
- button( v-for ='btn in field.buttons' , @click ='buttonClickHandler(btn, field)' , :class ='btn.classes' ) {{ btn.label }}
32
+ button( v-for ='btn in field.buttons' , @click ='buttonClickHandler(btn, field, $event )' , :class ='btn.classes' ) {{ btn.label }}
33
33
.hint ( v-if ='field.hint' ) {{ field.hint }}
34
34
.errors.help-block ( v-if ='fieldErrors(field).length > 0' )
35
35
span( v-for ='(error, index) in fieldErrors(field)' , track-by ='index' ) {{ error }}
@@ -276,8 +276,8 @@ div.vue-form-generator(v-if='schema != null')
276
276
return field .featured ;
277
277
},
278
278
279
- buttonClickHandler (btn , field ) {
280
- return btn .onclick .call (this , this .model , field, this );
279
+ buttonClickHandler (btn , field , event ) {
280
+ return btn .onclick .call (this , this .model , field, event , this );
281
281
},
282
282
283
283
// Child field executed validation
0 commit comments