mirror of
https://bitbucket.org/studiotem/jandl-taskmanager-app.git
synced 2026-10-21 14:29:34 +00:00
bugy + CR
This commit is contained in:
1 parent
8972b538ea
commit
5c8daca94f
11 files changed
+48
-26
No files matched your search
@@ -55,7 +55,7 @@ const routes: Array<RouteRecordRaw> = [
|
|||||||
{
|
{
|
||||||
path: '/app/dashboard/tasks',
|
path: '/app/dashboard/tasks',
|
||||||
name: 'Dashboard - Tasks',
|
name: 'Dashboard - Tasks',
|
||||||
meta: { title: 'Tasks', requiresAuth: true },
|
meta: { title: 'Sub Tasks', requiresAuth: true },
|
||||||
component: () => import('@/plugins/tm@dashboard/tasks/tasks.vue')
|
component: () => import('@/plugins/tm@dashboard/tasks/tasks.vue')
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -74,13 +74,13 @@ const routes: Array<RouteRecordRaw> = [
|
|||||||
{
|
{
|
||||||
path: '/app/overview/unscheduled',
|
path: '/app/overview/unscheduled',
|
||||||
name: 'Overview - Unscheduled tasks',
|
name: 'Overview - Unscheduled tasks',
|
||||||
meta: { title: 'Unscheduled tasks', requiresAuth: true },
|
meta: { title: 'Unscheduled Sub Tasks', requiresAuth: true },
|
||||||
component: () => import('@/plugins/tm@overview/tasks-unscheduled/tasks-unscheduled.vue')
|
component: () => import('@/plugins/tm@overview/tasks-unscheduled/tasks-unscheduled.vue')
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: '/app/overview/ongoing',
|
path: '/app/overview/ongoing',
|
||||||
name: 'Overview - Ongoing tasks',
|
name: 'Overview - Ongoing tasks',
|
||||||
meta: { title: 'Ongoing tasks', requiresAuth: true },
|
meta: { title: 'Ongoing Sub Tasks', requiresAuth: true },
|
||||||
component: () => import('@/plugins/tm@overview/tasks-ongoing/tasks-ongoing.vue')
|
component: () => import('@/plugins/tm@overview/tasks-ongoing/tasks-ongoing.vue')
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ export default {
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
pages: [{
|
pages: [{
|
||||||
title: 'Tasks',
|
title: 'Sub Tasks',
|
||||||
pageName: 'Dashboard - Tasks'
|
pageName: 'Dashboard - Tasks'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -42,11 +42,11 @@ export default {
|
|||||||
pageName: 'Dashboard - Projects'
|
pageName: 'Dashboard - Projects'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'Unscheduled tasks',
|
title: 'Unscheduled Sub Tasks',
|
||||||
pageName: 'Overview - Unscheduled tasks'
|
pageName: 'Overview - Unscheduled tasks'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'Ongoing tasks',
|
title: 'Ongoing Sub Tasks',
|
||||||
pageName: 'Overview - Ongoing tasks'
|
pageName: 'Overview - Ongoing tasks'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -88,7 +88,7 @@ export default {
|
|||||||
<style lang="sass" scoped>
|
<style lang="sass" scoped>
|
||||||
ion-item
|
ion-item
|
||||||
font-weight: 500 !important
|
font-weight: 500 !important
|
||||||
font-size: 15px
|
font-size: 13.5px
|
||||||
--background: #fff
|
--background: #fff
|
||||||
|
|
||||||
&:hover
|
&:hover
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div v-if="Array.isArray(subtasks) && subtasks.length">
|
<div v-if="Array.isArray(subtasks) && subtasks.length">
|
||||||
<h1 class="px-3 py-3">Tasks</h1>
|
<h1 class="px-3 py-3">Subtasks</h1>
|
||||||
<v-table>
|
<v-table>
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr v-for="subtask in enrichedtasks" :key="subtask.id">
|
<tr v-for="subtask in enrichedtasks" :key="subtask.id">
|
||||||
|
|||||||
@@ -83,7 +83,7 @@
|
|||||||
<small class="event-initials-date">{{ event.date?.toLocaleDateString('sk-SK') }}</small>
|
<small class="event-initials-date">{{ event.date?.toLocaleDateString('sk-SK') }}</small>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="d-flex align-center">
|
<div v-if="event.type == 'subtask'" class="d-flex align-center">
|
||||||
<v-icon icon="mdi-skull-outline" size="small" />
|
<v-icon icon="mdi-skull-outline" size="small" />
|
||||||
<small v-if="event?.subtask.deadline" class="ml-1">{{ getDeadline(event?.subtask) }}</small>
|
<small v-if="event?.subtask.deadline" class="ml-1">{{ getDeadline(event?.subtask) }}</small>
|
||||||
<v-tooltip v-else text="Deadline z Mastertasku" location="bottom">
|
<v-tooltip v-else text="Deadline z Mastertasku" location="bottom">
|
||||||
@@ -453,7 +453,6 @@ export default {
|
|||||||
|
|
||||||
.vuecal__event
|
.vuecal__event
|
||||||
border-radius: 16px
|
border-radius: 16px
|
||||||
// padding: 20px 10px
|
|
||||||
min-height: 70px !important
|
min-height: 70px !important
|
||||||
text-align: left
|
text-align: left
|
||||||
background: rgba(248, 248, 248, 1)
|
background: rgba(248, 248, 248, 1)
|
||||||
@@ -503,14 +502,15 @@ export default {
|
|||||||
|
|
||||||
.mini-event
|
.mini-event
|
||||||
.event-content
|
.event-content
|
||||||
display: flex
|
// display: flex
|
||||||
align-items: center
|
// align-items: center
|
||||||
flex-wrap: nowrap
|
// flex-wrap: nowrap
|
||||||
justify-content: space-between
|
// justify-content: space-between
|
||||||
width: 100%
|
width: 100%
|
||||||
|
padding: 5px 10px
|
||||||
|
|
||||||
.event-initials-wrapper
|
.event-initials-wrapper
|
||||||
margin-bottom: 0
|
// margin-bottom: 0
|
||||||
.event-initials
|
.event-initials
|
||||||
margin-right: 0
|
margin-right: 0
|
||||||
|
|
||||||
|
|||||||
@@ -76,7 +76,7 @@
|
|||||||
<A-tasks-table :subtasks="mastertask.subtasks" />
|
<A-tasks-table :subtasks="mastertask.subtasks" />
|
||||||
|
|
||||||
<div class="d-flex align-center ">
|
<div class="d-flex align-center ">
|
||||||
<v-btn class="subtask-btn w-100" @click="addTask()" ><v-icon class="mx-1" icon="mdi-plus" />Pridať task</v-btn>
|
<v-btn class="subtask-btn w-100" @click="addTask()" ><v-icon class="mx-1" icon="mdi-plus" />Pridať sub task</v-btn>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</v-card-actions>
|
</v-card-actions>
|
||||||
|
|||||||
@@ -10,28 +10,46 @@
|
|||||||
</v-col>
|
</v-col>
|
||||||
<v-col cols="7">
|
<v-col cols="7">
|
||||||
<v-sheet class="py-3">
|
<v-sheet class="py-3">
|
||||||
<p v-if="deadline" :class="`${tmUtils.isAfter(deadline) ? 'text-black' : 'text-red-darken-4'}`">{{ tmUtils.formatDate(deadline) }}</p>
|
<p v-if="subtask.deadline" :class="`${tmUtils.isAfter(subtask.deadline) ? 'text-black' : 'text-red-darken-4'}`">{{ tmUtils.formatDate(subtask.deadline) }}</p>
|
||||||
<p v-else>Tento task nema určený deadline</p>
|
<v-tooltip v-else text="Deadline z Mastertasku" location="end">
|
||||||
|
<template v-slot:activator="{ props }">
|
||||||
|
<span class="cursor-pointer" v-bind="props">{{ getMasterTaskDeadline(subtask) }}*</span>
|
||||||
|
</template>
|
||||||
|
</v-tooltip>
|
||||||
</v-sheet>
|
</v-sheet>
|
||||||
</v-col>
|
</v-col>
|
||||||
</v-row>
|
</v-row>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import tmUtils from '@/plugins/tm@_utils/tm.utils'
|
import tmUtils from '@/plugins/tm@_utils/tm.utils'
|
||||||
|
import moment from 'moment'
|
||||||
|
import { mapGetters } from 'vuex'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
props: {
|
props: {
|
||||||
deadline: {
|
subtask: {
|
||||||
type: [String, Object, null],
|
type: [String, Object, null],
|
||||||
required: true
|
required: true
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
computed: {
|
||||||
|
...mapGetters('tm', ['mastertasks'])
|
||||||
|
},
|
||||||
|
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
tmUtils
|
tmUtils
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
methods: {
|
||||||
|
getMasterTaskDeadline(subtask) {
|
||||||
|
if(!this.mastertasks) return ''
|
||||||
|
const masterTask = this.mastertasks.find((mt) => mt.id === subtask.master_task_id)
|
||||||
|
return moment(masterTask).format('DD.MM.yyyy') ? moment(masterTask.deadline).format('DD.MM.yyyy') : ''
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<A-mastertask-name :name="subtask._master_task.name" :id="subtask.master_task_id" :color="subtask._master_task.color" @close-modal="$emit('close-modal')" />
|
<A-mastertask-name :name="subtask._master_task.name" :id="subtask.master_task_id" :color="subtask._master_task.color" @close-modal="$emit('close-modal')" />
|
||||||
<A-mastertask-status :isFinished="subtask.is_finished" />
|
<A-mastertask-status :isFinished="subtask.is_finished" />
|
||||||
<A-task-deadline :deadline="subtask.deadline" />
|
<A-task-deadline :subtask="subtask" />
|
||||||
<A-task-timeblocks :timeblocks="subtask.timeblocks" :subtask="subtask" @update-subtask="$emit('update-subtask', $event)" />
|
<A-task-timeblocks :timeblocks="subtask.timeblocks" :subtask="subtask" @update-subtask="$emit('update-subtask', $event)" />
|
||||||
<Z-created-by :employee-id="subtask.created_by" />
|
<Z-created-by :employee-id="subtask.created_by" />
|
||||||
<A-task-assigned-employee :employee="subtask._employee" />
|
<A-task-assigned-employee :employee="subtask._employee" />
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
<v-dialog v-model="visible" max-width="750" persistent>
|
<v-dialog v-model="visible" max-width="750" persistent>
|
||||||
<v-card>
|
<v-card>
|
||||||
<div class="d-flex justify-space-between align-center">
|
<div class="d-flex justify-space-between align-center">
|
||||||
<h1>Ste si istý, že chcete {{ subtask.is_finished ? 'znovu otvoriť' : 'dokončiť' }} task, z mastertasku <b>{{ subtask?.master_task?.name || subtask.master_task }}</b>?</h1>
|
<h1>Ste si istý, že chcete {{ subtask.is_finished ? 'znovu otvoriť' : 'dokončiť' }} sub task, z mastertasku <b>{{ subtask?.master_task?.name || subtask.master_task }}</b>?</h1>
|
||||||
<v-icon
|
<v-icon
|
||||||
@click.stop="closeModal()"
|
@click.stop="closeModal()"
|
||||||
icon="mdi-close"
|
icon="mdi-close"
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
<v-dialog v-model="visible" max-width="750" persistent>
|
<v-dialog v-model="visible" max-width="750" persistent>
|
||||||
<v-card>
|
<v-card>
|
||||||
<div class="d-flex justify-space-between align-center">
|
<div class="d-flex justify-space-between align-center">
|
||||||
<h1>Ste si istý, že chcete zmazať task z mastertasku <b>{{ subtask.project_code }}</b>?</h1>
|
<h1>Ste si istý, že chcete zmazať sub task z mastertasku <b>{{ subtask.project_code }}</b>?</h1>
|
||||||
|
|
||||||
<v-icon
|
<v-icon
|
||||||
@click.stop="closeModal()"
|
@click.stop="closeModal()"
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
<W-loadable :content="subtask" class="h-100">
|
<W-loadable :content="subtask" class="h-100">
|
||||||
<v-card v-if="editMode" height="100%" class="d-flex flex-column scrolling">
|
<v-card v-if="editMode" height="100%" class="d-flex flex-column scrolling">
|
||||||
<div class="d-flex justify-space-between align-center modal-header">
|
<div class="d-flex justify-space-between align-center modal-header">
|
||||||
<h1>{{ subtask?.id ? 'Upraviť task' : 'Vytvoriť task' }}</h1>
|
<h1>{{ subtask?.id ? 'Upraviť sub task' : 'Vytvoriť sub task' }}</h1>
|
||||||
<v-icon @click.stop="closeModal()" icon="mdi-close" size="large"></v-icon>
|
<v-icon @click.stop="closeModal()" icon="mdi-close" size="large"></v-icon>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
@@ -113,10 +113,14 @@ export default {
|
|||||||
try {
|
try {
|
||||||
if (this.team.id) {
|
if (this.team.id) {
|
||||||
const { team } = await this.$axios.put_auth(`v1/teams/${this.team.id}`, this.team)
|
const { team } = await this.$axios.put_auth(`v1/teams/${this.team.id}`, this.team)
|
||||||
this.$store.commit('tm/update_team', team)
|
|
||||||
|
const fullTeamResource = await this.$axios.get_auth_data(`v1/teams/${team.id}`)
|
||||||
|
this.$store.commit('tm/update_team', fullTeamResource)
|
||||||
} else {
|
} else {
|
||||||
const { team } = await this.$axios.post_auth(`v1/teams`, this.team)
|
const { team } = await this.$axios.post_auth(`v1/teams`, this.team)
|
||||||
this.$store.commit('tm/save_team', team)
|
|
||||||
|
const fullTeamResource = await this.$axios.get_auth_data(`v1/teams/${team.id}`)
|
||||||
|
this.$store.commit('tm/save_team', fullTeamResource)
|
||||||
}
|
}
|
||||||
|
|
||||||
this.closeModal()
|
this.closeModal()
|
||||||
|
|||||||
Reference in new issue
Block a user