mirror of
https://bitbucket.org/studiotem/jandl-taskmanager-app.git
synced 2026-10-21 14:29:34 +00:00
Feat(task) Added estimated hours, fixed edit for office tasks
This commit is contained in:
1 parent
687681865c
commit
86bc41450e
10 files changed
+72
-44
No files matched your search
@@ -0,0 +1,27 @@
|
||||
<template>
|
||||
<v-row no-gutters class="align-center">
|
||||
<v-col cols="5">
|
||||
<v-sheet class="py-3">
|
||||
<div class="d-flex align-center">
|
||||
<v-icon icon="mdi-clock-time-three-outline" size="large"></v-icon>
|
||||
<p class="mx-3">Nacenené hodiny</p>
|
||||
</div>
|
||||
</v-sheet>
|
||||
</v-col>
|
||||
<v-col cols="7">
|
||||
<v-sheet class="py-3">
|
||||
<p>{{ hours || 0 }} h</p>
|
||||
</v-sheet>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
props: {
|
||||
hours: {
|
||||
type: [Number, undefined]
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -5,6 +5,7 @@
|
||||
<A-task-timeblocks :timeblocks="subtask.timeblocks" :subtask="subtask" @update-subtask="$emit('update-subtask', $event)" />
|
||||
<Z-created-by :employee-id="subtask.created_by" />
|
||||
<A-task-assigned-employee :employee="subtask._employee" />
|
||||
<A-task-estimated-duration :hours="subtask.estimated_duration" />
|
||||
<A-task-planned-time :hours="subtask.duration" />
|
||||
<A-task-remaining-time :hours="subtask.duration - subtask.spent_time" />
|
||||
<A-task-spent-time :hours="subtask.spent_time" :subtask="subtask" />
|
||||
@@ -23,6 +24,7 @@ import ATaskSpentTime from './_components/a-task-spent-time.vue'
|
||||
import ATaskRemainingTime from './_components/a-task-remaining-time.vue'
|
||||
import ATaskDeadline from './_components/a-task-deadline.vue'
|
||||
import ATaskDescription from './_components/a-task-description.vue'
|
||||
import ATaskEstimatedDuration from './_components/a-task-estimated-duration.vue'
|
||||
import ZFiles from '@/plugins/tm@modal/_components/read-only/z-files.vue'
|
||||
|
||||
export default {
|
||||
@@ -39,9 +41,10 @@ export default {
|
||||
ATaskSpentTime,
|
||||
ATaskRemainingTime,
|
||||
ATaskDescription,
|
||||
ATaskDeadline
|
||||
ATaskDeadline,
|
||||
ATaskEstimatedDuration
|
||||
},
|
||||
|
||||
|
||||
props: {
|
||||
subtask: {
|
||||
type: Object,
|
||||
|
||||
@@ -109,7 +109,7 @@
|
||||
<div class="d-flex justify-space-between align-center modal-header border-bottom pb-4">
|
||||
<h1>{{ subtask.title }}</h1>
|
||||
<div class="d-flex justify-start">
|
||||
<img class="icon" :src="require('@/plugins/app/_img/icons/pencil.svg')" alt="pencil-icon" @click.stop="editMode = !editMode" />
|
||||
<img class="icon" :src="require('@/plugins/app/_img/icons/pencil.svg')" alt="pencil-icon" @click.stop="toggleEditMode" />
|
||||
<img class="icon trash" :src="require('@/plugins/app/_img/icons/bin.svg')" alt="trash-icon" @click.stop="openDeleteTaskModal(subtask)" />
|
||||
</div>
|
||||
</div>
|
||||
@@ -239,6 +239,14 @@ export default {
|
||||
},
|
||||
|
||||
methods: {
|
||||
toggleEditMode() {
|
||||
// TODO office365: Only for office365 events
|
||||
return this.$events.emit('show-unable-to-edit-office-task-modal', { mode: 'edit' })
|
||||
|
||||
|
||||
// this.editMode = !this.editMode
|
||||
},
|
||||
|
||||
openDatepicker(ref) {
|
||||
this.$refs[ref].openMenu()
|
||||
},
|
||||
@@ -385,7 +393,9 @@ export default {
|
||||
},
|
||||
|
||||
openDeleteTaskModal(subtask) {
|
||||
this.$events.emit('show-delete-task-modal', { subtask })
|
||||
// TODO office365: Only for office365 events
|
||||
this.$events.emit('show-unable-to-edit-office-task-modal', { mode: 'delete' })
|
||||
// this.$events.emit('show-delete-task-modal', { subtask })
|
||||
},
|
||||
|
||||
showCompleteTaskModal() {
|
||||
|
||||
@@ -2,10 +2,10 @@
|
||||
<v-dialog v-model="visible" max-width="750" persistent>
|
||||
<v-card>
|
||||
<div class="d-flex justify-space-between align-center">
|
||||
<h1>Sub Task zosynchronizovaný z Office365 sa nedá upravovat. Upravte ho vo svojom kalendári a pockajte
|
||||
na zosynchronizovanie s Task Managerom</h1>
|
||||
<h1 v-if="mode === 'edit'">Sub Task zosynchronizovaný z Office365 sa nedá upravovat. Upravte ho vo svojom kalendári a pockajte na zosynchronizovanie s Task Managerom</h1>
|
||||
<h1 v-else-if="mode === 'delete'">Sub Task zosynchronizovaný z Office365 sa nedá zmazať. Zmažte ho vo svojom kalendári a pockajte na zosynchronizovanie s Task Managerom</h1>
|
||||
|
||||
<v-icon
|
||||
<v-icon
|
||||
@click.stop="closeModal()"
|
||||
icon="mdi-close"
|
||||
size="large"
|
||||
@@ -22,6 +22,13 @@ export default {
|
||||
mixins: [ modalMixin ],
|
||||
emits: ['close', 'on-subtask-edited'],
|
||||
|
||||
props: {
|
||||
mode: {
|
||||
type: String,
|
||||
default: 'edit' // edit or delete
|
||||
}
|
||||
},
|
||||
|
||||
data() {
|
||||
return {
|
||||
visible: false,
|
||||
|
||||
Reference in new issue
Block a user