diff --git a/src/pages/Worker/Card/WorkerOperator.vue b/src/pages/Worker/Card/WorkerOperator.vue index a667d083e..0bd6d46e2 100644 --- a/src/pages/Worker/Card/WorkerOperator.vue +++ b/src/pages/Worker/Card/WorkerOperator.vue @@ -10,10 +10,11 @@ import VnSelect from 'src/components/common/VnSelect.vue'; import VnInput from 'src/components/common/VnInput.vue'; import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue'; import CrudModel from 'components/CrudModel.vue'; +import axios from 'axios'; const { t } = useI18n(); -const test = ref({}); +const crudModelRef = ref(); const dialog = ref(); const warehousesData = ref([]); const itemPackingTypesData = ref([]); @@ -39,10 +40,11 @@ const initialData = computed(() => { machineFk: null, }; }); -// watch( -// () => route.params.id, -// () => CrudModelRef.value.reset() -// ); + +async function insert() { + await axios.post('Operators', initialData.value); + crudModelRef.value.reload(); +}