mirror of
https://bitbucket.org/studiotem/jandl-taskmanager-app.git
synced 2026-10-21 14:29:34 +00:00
[production] endpoints update
This commit is contained in:
1 parent
bb262c1348
commit
5578cc9c76
12 files changed
+29
-53
No files matched your search
@@ -28,7 +28,7 @@
|
||||
<template v-if="!mastertask.id">
|
||||
<v-text-field v-for="(employee, index) in mastertask.employees" :key="employee.id" @focus="onInputFocus" class="modal-input" :class="{error: employee.invalid}" :label="`${employee.name} ${employee.surname}`" variant="solo" placeholder="h" v-model="mastertask.employees[index].duration" type="number" min="1" @input="onEmployeeDurationChanged">
|
||||
<p class="employee-select-avatar d-flex justify-center align-center">
|
||||
{{ employee?.name.charAt(0) + employee?.surname.charAt(0) }}
|
||||
{{ employee?.name.charAt(0) + employee?.surname.charAt(0) }}+ľš21s
|
||||
</p>
|
||||
|
||||
<v-icon @click.stop="removeEmployee(employee)" class="remove-input" icon="mdi-close" size="small"></v-icon>
|
||||
|
||||
@@ -53,10 +53,10 @@ export default {
|
||||
|
||||
methods: {
|
||||
getMasterTaskDeadline(subtask) {
|
||||
// FIX: Subtask ma vzdy vracat aj subtask.master_task_deadline
|
||||
if(!this.mastertasks) return ''
|
||||
const masterTask = this.mastertasks.find((mt) => mt.id === subtask.master_task_id)
|
||||
return tmUtils.formatDateTime(masterTask) ? tmUtils.formatDateTime(masterTask.deadline) : ''
|
||||
if (subtask?.deadline)
|
||||
return subtask.deadline
|
||||
|
||||
return subtask.master_task_deadline
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -262,15 +262,10 @@ export default {
|
||||
},
|
||||
|
||||
getDeadline(subtask) {
|
||||
// FIX: Subtask ma vzdy vracat aj subtask.master_task_deadline
|
||||
if (subtask?.deadline)
|
||||
return subtask.deadline
|
||||
|
||||
if (!this.mastertasks)
|
||||
return null
|
||||
|
||||
const masterTask = this.mastertasks.find((mt) => mt.id === subtask.master_task_id)
|
||||
return masterTask.deadline
|
||||
return subtask.master_task_deadline
|
||||
},
|
||||
|
||||
closeModal() {
|
||||
|
||||
@@ -296,7 +296,6 @@ export default {
|
||||
this.$events.emit('task-created')
|
||||
this.$events.emit('close-both-modals')
|
||||
}
|
||||
|
||||
this.closeModal()
|
||||
} catch (error) {
|
||||
this.$toast.error(this.$parseError(error))
|
||||
@@ -393,7 +392,6 @@ export default {
|
||||
},
|
||||
|
||||
'subtask.master_task_id'(value) {
|
||||
// FIX: Request na BE pre mastertasks/{id}
|
||||
if (!value) return
|
||||
this.subtask._master_task = this.mastertasks.find((mastertask) => mastertask.id == this.subtask.master_task_id)
|
||||
this.subtask.project_code = this.subtask._master_task?.project_code || null
|
||||
|
||||
Reference in new issue
Block a user