| Current Path : /home/jeromecohp/www/plugins/system/yooessentials/modules/core/app/fields/ |
| Current File : /home/jeromecohp/www/plugins/system/yooessentials/modules/core/app/fields/CheckboxField.vue |
<script>
import yootheme from 'yootheme';
export default {
name: 'YooessentialsCheckbox',
extends: yootheme.fields.components.FieldCheckbox,
mounted() {
if (this.field.dependencies) {
this.field.dependencies.split(',').forEach((dependency) => {
this.$watch(`values.${dependency}`, (checked) => {
this.value = checked ? this.trueValue : this.falseValue;
});
});
}
},
};
</script>