직원정보수정오류 해결

This commit is contained in:
2026-01-05 14:09:22 +09:00
parent cfbd9e71ca
commit 0dd4b561f0
3 changed files with 28 additions and 5 deletions

View File

@@ -217,10 +217,15 @@ async function updateEmployee() {
try {
await $fetch(`/api/employee/${route.params.id}/update`, {
method: 'PUT',
body: form.value
body: {
...form.value,
joinDate: form.value.joinDate || null,
employeePhone: form.value.employeePhone || null,
employeePosition: form.value.employeePosition || null
}
})
alert('저장되었습니다.')
await loadEmployee()
router.push('/employee')
} catch (e: any) {
alert(e.data?.message || e.message || '저장에 실패했습니다.')
} finally {