EducationTiming.vue 843 B

1234567891011121314151617181920212223242526272829303132
  1. <template>
  2. <v-container :fluid="true" class="container">
  3. <v-row>
  4. <v-col cols="12" sm="6">
  5. <UiInputNumber
  6. v-model="proxyEntity.timing"
  7. field="educationTiming"
  8. :rules="getAsserts('timing')"
  9. />
  10. </v-col>
  11. </v-row>
  12. </v-container>
  13. </template>
  14. <script setup lang="ts">
  15. import { getAssertUtils } from '~/services/asserts/getAssertUtils'
  16. import EducationTiming from '~/models/Education/EducationTiming'
  17. const props = defineProps<{
  18. entity: EducationTiming
  19. }>()
  20. const emit = defineEmits(['update:entity'])
  21. // Pour éviter l'erreur eslint "Unexpected mutation of "modelValue" prop"
  22. const proxyEntity = computed({
  23. get: () => props.entity,
  24. set: (value) => emit('update:entity', value),
  25. })
  26. const getAsserts = (key) => getAssertUtils(EducationTiming.getAsserts(), key)
  27. </script>