From 3bdfad22e6d585a3ecbda70074d26c957cc3ad03 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matej=20Glasn=C3=A1k?= Date: Thu, 2 Feb 2023 08:44:41 +0100 Subject: [PATCH] [Team modal] Temporary edit team fix --- app/public/mock/v1/overview/tasks.GET.json | 28 +++++++++---------- .../app/_layout/app/_components/a-header.vue | 8 +++--- app/src/plugins/tm@dashboard/tasks/tasks.vue | 2 ++ .../tm@modal/task/z-complete-task-modal.vue | 4 +-- .../plugins/tm@modal/team/z-team-modal.vue | 8 ++++-- 5 files changed, 28 insertions(+), 22 deletions(-) diff --git a/app/public/mock/v1/overview/tasks.GET.json b/app/public/mock/v1/overview/tasks.GET.json index 9148896..f1159d9 100644 --- a/app/public/mock/v1/overview/tasks.GET.json +++ b/app/public/mock/v1/overview/tasks.GET.json @@ -38,8 +38,8 @@ "tasks": [ { "id": 1, - "starts_at": "2023-01-26T08:01:00+00:00", - "ends_at": "2023-01-26T09:00:00+00:00", + "starts_at": "2023-02-02T08:01:00+00:00", + "ends_at": "2023-02-02T09:00:00+00:00", "title": "Task DNES", "project_code": "CO-2201", "master_task_color": "#E9FFE6", @@ -48,8 +48,8 @@ { "id": 2, - "starts_at": "2023-01-27T08:30:00+00:00", - "ends_at": "2023-01-27T09:00:00+00:00", + "starts_at": "2023-02-02T08:30:00+00:00", + "ends_at": "2023-02-02T09:00:00+00:00", "title": "Kratky 30min Lorem ipsum dolor sit amet, consectetur adipiscing e", "project_code": "CO-2201", "master_task_color": "#f27e57", @@ -58,8 +58,8 @@ { "id": 3, - "starts_at": "2023-01-27T10:30:00+00:00", - "ends_at": "2023-01-27T10:45:00+00:00", + "starts_at": "2023-02-02T10:30:00+00:00", + "ends_at": "2023-02-02T10:45:00+00:00", "title": "Kratky 15min", "project_code": "CO-2201", "master_task_color": "#57e0f2", @@ -68,8 +68,8 @@ { "id": 4, - "starts_at": "2023-01-26T08:00:00+00:00", - "ends_at": "2023-01-26T10:00:00+00:00", + "starts_at": "2023-02-02T08:00:00+00:00", + "ends_at": "2023-02-02T10:00:00+00:00", "title": "Task 2", "project_code": "CO-2201", "master_task_color": "#FDE1FF", @@ -78,8 +78,8 @@ { "id": 6, - "starts_at": "2023-01-27T09:00:00+00:00", - "ends_at": "2023-01-27T12:00:00+00:00", + "starts_at": "2023-02-03T09:00:00+00:00", + "ends_at": "2023-02-03T12:00:00+00:00", "title": "Task 6", "project_code": "CO-2201", "master_task_color": "#57e0f2", @@ -88,8 +88,8 @@ { "id": 7, - "starts_at": "2023-01-28T12:00:00+00:00", - "ends_at": "2023-01-28T16:00:00+00:00", + "starts_at": "2023-02-03T12:00:00+00:00", + "ends_at": "2023-02-03T16:00:00+00:00", "title": "Task 7", "project_code": "CO-2201", "master_task_color": "#E7DBF8", @@ -98,8 +98,8 @@ { "id": 8, - "starts_at": "2023-01-21T07:00:00+00:00", - "ends_at": "2023-01-21T09:00:00+00:00", + "starts_at": "2023-02-03T07:00:00+00:00", + "ends_at": "2023-02-03T09:00:00+00:00", "title": "Task 8", "project_code": "CO-2201", "master_task_color": "#57e0f2", diff --git a/app/src/plugins/app/_layout/app/_components/a-header.vue b/app/src/plugins/app/_layout/app/_components/a-header.vue index 0fc1d84..2b521d1 100644 --- a/app/src/plugins/app/_layout/app/_components/a-header.vue +++ b/app/src/plugins/app/_layout/app/_components/a-header.vue @@ -11,7 +11,7 @@ @@ -132,9 +132,9 @@ export default { border-radius: 6px .button - background: #7f39fb - border-radius: 4px - color: #fff + height: 36px !important + min-width: 127px !important + .menu-dropdown border: 1px solid rgba(33, 33, 33, 0.08) !important border-radius: 16px diff --git a/app/src/plugins/tm@dashboard/tasks/tasks.vue b/app/src/plugins/tm@dashboard/tasks/tasks.vue index 7ace1f0..0e27252 100644 --- a/app/src/plugins/tm@dashboard/tasks/tasks.vue +++ b/app/src/plugins/tm@dashboard/tasks/tasks.vue @@ -82,6 +82,8 @@ export default { event.split = diffInDays * (-1) + 1 }) + console.log(this.timelineData.tasks) + this.unscheduledTime = 0 this.timelineData.unscheduled_times.forEach(time => { diff --git a/app/src/plugins/tm@modal/task/z-complete-task-modal.vue b/app/src/plugins/tm@modal/task/z-complete-task-modal.vue index b45e7a2..b16f3ef 100644 --- a/app/src/plugins/tm@modal/task/z-complete-task-modal.vue +++ b/app/src/plugins/tm@modal/task/z-complete-task-modal.vue @@ -11,8 +11,8 @@ > - ÁNO - ZRUŠIŤ + ÁNO + ZRUŠIŤ diff --git a/app/src/plugins/tm@modal/team/z-team-modal.vue b/app/src/plugins/tm@modal/team/z-team-modal.vue index a1adf36..8e96329 100644 --- a/app/src/plugins/tm@modal/team/z-team-modal.vue +++ b/app/src/plugins/tm@modal/team/z-team-modal.vue @@ -67,6 +67,7 @@ import useVuelidate from '@vuelidate/core' import { required } from '@vuelidate/validators' import errorUtils from '@/plugins/lib@auth/_utils/error.utils' import tmUtils from '@/plugins/tm@_utils/tm.utils' +import axios from 'axios' const atLeastOne = (value) => value.length @@ -124,9 +125,12 @@ export default { async save() { if (!(await this.v$.$validate())) return + try { - if (this.team.id) - await this.$axios.put_auth_data(`v1/teams/${this.team.id}`, this.team) + if (this.team.id) { + // await this.$axios.put_auth_data(`v1/teams/${this.team.id}`, this.team) + await axios.put(`v1/teams/${this.team.id}`, {data: this.team}) + } else await this.$axios.post_auth_data(`v1/teams`, this.team)