forked from verdnatura/salix-front
fix(WorkerTimeControl): url
This commit is contained in:
parent
725b7053f7
commit
3999d93268
|
@ -372,15 +372,15 @@ const showReasonForm = () => {
|
|||
const updateWorkerTimeControlMail = async (state, reason) => {
|
||||
try {
|
||||
const params = {
|
||||
workerId: Number(route.params.id),
|
||||
year: selectedDate.value.getFullYear(),
|
||||
week: selectedWeekNumber.value,
|
||||
state,
|
||||
};
|
||||
const workerId = Number(route.params.id);
|
||||
|
||||
if (reason) params.reason = reason;
|
||||
|
||||
await axios.post('WorkerTimeControls/updateMailState', params);
|
||||
await axios.post(`WorkerTimeControls/${workerId}/updateMailState`, params);
|
||||
await getMailStates(selectedDate.value);
|
||||
await fetchWeekData();
|
||||
notify(t('globals.dataSaved'), 'positive');
|
||||
|
|
Loading…
Reference in New Issue