diff --git a/src/pages/Wagon/Type/WagonCreateTray.vue b/src/pages/Wagon/Type/WagonCreateTray.vue index 19f66b0b3..c3f8b3847 100644 --- a/src/pages/Wagon/Type/WagonCreateTray.vue +++ b/src/pages/Wagon/Type/WagonCreateTray.vue @@ -6,7 +6,6 @@ import VnRow from 'src/components/ui/VnRow.vue'; import VnInput from 'src/components/common/VnInput.vue'; import FetchData from 'src/components/FetchData.vue'; import { useI18n } from 'vue-i18n'; -import { useQuasar } from 'quasar'; import axios from 'axios'; const $props = defineProps({ @@ -31,7 +30,6 @@ const wagonColorTranslated = ref(); const heights = ref(); const existingTrayHeight = ref($props.height); const { t } = useI18n(); -const { notify } = useQuasar(); watch(wagonColors, () => { wagonColorTranslated.value = wagonColors.value.map((color) => { @@ -51,33 +49,6 @@ async function getTrays() { } function onSubmit() { - if (heights.value.includes(parseInt(trayHeight.value))) { - notify({ - message: t( - 'A tray with the same height already exists, try with a different height' - ), - type: 'negative', - }); - return; - } - if (trayHeight.value - heights.value[heights.value.length - 1] < 50) { - notify({ - message: t('The minimum height between trays is 50cm'), - type: 'negative', - }); - return; - } - - if (trayHeight.value > 200) { - notify({ - message: t( - 'The maximum height of the wagon is 200cm, try with a lower height' - ), - type: 'negative', - }); - return; - } - const newTray = { wagonTypeFk: entityId.value, wagonTypeColorFk: selectedTrayColor.value, @@ -110,6 +81,7 @@ getTrays(); option-value="id" id="id" :label="t('Select a tray color')" + :required="true" >