mirror of
https://bitbucket.org/studiotem/jandl-taskmanager-app.git
synced 2026-10-21 14:29:34 +00:00
Merge branch 'main' of https://bitbucket.org/studiotem/jandl-taskmanager-appdass
This commit is contained in:
commit
df4fe36576
18 files changed
+403
-262
No files matched your search
@@ -1,4 +0,0 @@
|
|||||||
{
|
|
||||||
"Chyba": "",
|
|
||||||
"Zadali ste neplatný email.": ""
|
|
||||||
}
|
|
||||||
@@ -1,4 +1,9 @@
|
|||||||
{
|
{
|
||||||
"Value is not a valid email address": "Zadali ste neplatný email.",
|
"Value is not a valid email address": "Zadali ste neplatný email",
|
||||||
"error": "chyba"
|
"error": "chyba",
|
||||||
|
"Value is required": "Pole je povinné",
|
||||||
|
"This field should be at least 8 characters long": "Pole musí obsahovať aspoň 8 znakov",
|
||||||
|
"This field should be at least 6 characters long": "Pole musí obsahovať aspoň 6 znakov",
|
||||||
|
"This maximum length allowed is 6": "Pole musí obsahovať 6 znakov",
|
||||||
|
"The value must be equal to the other value": "Heslá sa nezhodujú"
|
||||||
}
|
}
|
||||||
@@ -24,7 +24,7 @@
|
|||||||
disabled
|
disabled
|
||||||
label="Zamestanec"
|
label="Zamestanec"
|
||||||
variant="outlined"
|
variant="outlined"
|
||||||
v-model="selectedEmployees[index].surname"
|
v-model="selectedEmployees[index]._fullName"
|
||||||
>
|
>
|
||||||
</v-text-field>
|
</v-text-field>
|
||||||
<v-icon
|
<v-icon
|
||||||
@@ -40,13 +40,15 @@
|
|||||||
<v-icon icon="mdi-plus" size="large"></v-icon>PRIDAŤ
|
<v-icon icon="mdi-plus" size="large"></v-icon>PRIDAŤ
|
||||||
ZAMESTNANCA</v-btn
|
ZAMESTNANCA</v-btn
|
||||||
> -->
|
> -->
|
||||||
<v-autocomplete
|
<!-- <v-autocomplete
|
||||||
class="modal-input"
|
class="modal-input"
|
||||||
label="Vyhľadať"
|
label="Vyhľadať"
|
||||||
variant="outlined"
|
variant="outlined"
|
||||||
:items="employeesOptions"
|
:items="employeesOptions"
|
||||||
v-model="selectedEmployee"
|
v-model="selectedEmployee"
|
||||||
></v-autocomplete>
|
></v-autocomplete> -->
|
||||||
|
|
||||||
|
<W-autocomplete :options="employeesOptions" class="modal-input" @option-selected="employeeSelected" />
|
||||||
|
|
||||||
</v-card-actions>
|
</v-card-actions>
|
||||||
|
|
||||||
@@ -57,7 +59,13 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import WAutocomplete from './w-autocomplete.vue'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
components: {
|
||||||
|
WAutocomplete
|
||||||
|
},
|
||||||
|
|
||||||
props: [
|
props: [
|
||||||
'visible'
|
'visible'
|
||||||
],
|
],
|
||||||
@@ -83,6 +91,13 @@ export default {
|
|||||||
this.selectedEmployees.splice(index, 1)
|
this.selectedEmployees.splice(index, 1)
|
||||||
},
|
},
|
||||||
|
|
||||||
|
employeeSelected(selectedOption) {
|
||||||
|
const employee = this.employees.find(empl => empl.id == selectedOption.key)
|
||||||
|
employee._fullName = `${employee.name} ${employee.surname}`
|
||||||
|
|
||||||
|
this.selectedEmployees.push(employee)
|
||||||
|
},
|
||||||
|
|
||||||
async createTeam() {
|
async createTeam() {
|
||||||
try{
|
try{
|
||||||
await this.$axios.post_auth('v1/teams')
|
await this.$axios.post_auth('v1/teams')
|
||||||
@@ -103,9 +118,12 @@ export default {
|
|||||||
(employee) => !selectedEmployeesIds.includes(employee.id)
|
(employee) => !selectedEmployeesIds.includes(employee.id)
|
||||||
);
|
);
|
||||||
|
|
||||||
return employees.map(
|
return employees.map(employee => {
|
||||||
(employee) => `${employee.name} ${employee.surname}`
|
return {
|
||||||
);
|
key: employee.id,
|
||||||
|
value: `${employee.name} ${employee.surname}`
|
||||||
|
}
|
||||||
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
show: {
|
show: {
|
||||||
|
|||||||
@@ -0,0 +1,54 @@
|
|||||||
|
<template>
|
||||||
|
<v-dialog v-model="showModal" max-width="650">
|
||||||
|
<v-card>
|
||||||
|
<div class="d-flex justify-space-between align-center">
|
||||||
|
<h1>Ste si istý, že chcete zmazať <b>{{ task.title }}</b>?</h1>
|
||||||
|
|
||||||
|
<v-icon
|
||||||
|
@click.stop="$emit('close-modal')"
|
||||||
|
icon="mdi-close"
|
||||||
|
size="large"
|
||||||
|
></v-icon>
|
||||||
|
</div>
|
||||||
|
<v-card-actions class="mt-10 d-flex justify-start align-center">
|
||||||
|
<v-btn class="create-btn" variant="flat" @click="$emit('delete-task', task.id)">ÁNO</v-btn>
|
||||||
|
<v-btn class="ml-7 cancel-btn" @click.stop="$emit('close-modal')">ZRUŠIŤ</v-btn>
|
||||||
|
</v-card-actions>
|
||||||
|
</v-card>
|
||||||
|
</v-dialog>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
emits: ['delete-task', 'close-modal'],
|
||||||
|
|
||||||
|
props: {
|
||||||
|
show: {
|
||||||
|
type: Boolean,
|
||||||
|
required: true
|
||||||
|
},
|
||||||
|
|
||||||
|
task: {
|
||||||
|
type: Object,
|
||||||
|
required: true
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
computed: {
|
||||||
|
showModal() {
|
||||||
|
return this.show
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="sass" scoped>
|
||||||
|
.cancel-btn
|
||||||
|
border: thin solid rgba(var(--v-border-color), var(--v-border-opacity))
|
||||||
|
color: #7f39fb
|
||||||
|
|
||||||
|
.create-btn
|
||||||
|
background: #7f39fb
|
||||||
|
border-radius: 4px
|
||||||
|
color: #fff
|
||||||
|
</style>
|
||||||
@@ -1,17 +1,17 @@
|
|||||||
<template>
|
<template>
|
||||||
<v-dialog v-model="show" max-width="650">
|
<v-dialog v-model="showModal" max-width="650">
|
||||||
<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ť tento tím?</h1>
|
<h1>Ste si istý, že chcete zmazať tím <b>{{ team.name }}</b>?</h1>
|
||||||
<v-icon
|
<v-icon
|
||||||
@click.stop="show = false"
|
@click.stop="$emit('close-modal')"
|
||||||
icon="mdi-close"
|
icon="mdi-close"
|
||||||
size="large"
|
size="large"
|
||||||
></v-icon>
|
></v-icon>
|
||||||
</div>
|
</div>
|
||||||
<v-card-actions class="mt-10 d-flex justify-start align-center">
|
<v-card-actions class="mt-10 d-flex justify-start align-center">
|
||||||
<v-btn class="create-btn" variant="flat" @click="deleteTeam()">ÁNO</v-btn>
|
<v-btn class="create-btn" variant="flat" @click="$emit('delete-team', team.id)">ÁNO</v-btn>
|
||||||
<v-btn class="ml-7 cancel-btn" @click.stop="show = false">ZRUŠIŤ</v-btn>
|
<v-btn class="ml-7 cancel-btn" @click.stop="$emit('close-modal')">ZRUŠIŤ</v-btn>
|
||||||
</v-card-actions>
|
</v-card-actions>
|
||||||
</v-card>
|
</v-card>
|
||||||
</v-dialog>
|
</v-dialog>
|
||||||
@@ -19,40 +19,24 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
props: [
|
emits: ['delete-team', 'close-modal'],
|
||||||
'visible'
|
|
||||||
],
|
|
||||||
|
|
||||||
data() {
|
props: {
|
||||||
return {
|
show: {
|
||||||
selectedEmployee: "",
|
type: Boolean,
|
||||||
selectedEmployees: [],
|
required: true
|
||||||
employees: null,
|
},
|
||||||
};
|
|
||||||
},
|
|
||||||
|
|
||||||
methods: {
|
team: {
|
||||||
async deleteTeam(id) {
|
type: Object,
|
||||||
try{
|
required: true
|
||||||
await this.$axios.delete(`v1/teams/${id}`)
|
|
||||||
this.$router.push({ name: 'Overview - Teams' })
|
|
||||||
this.show = false
|
|
||||||
} catch (error) {
|
|
||||||
this.$toast.error(error.response.data.error)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
computed: {
|
computed: {
|
||||||
show: {
|
showModal() {
|
||||||
get() {
|
return this.show
|
||||||
return this.visible
|
}
|
||||||
},
|
|
||||||
|
|
||||||
set(value) {
|
|
||||||
if (!value) this.$emit('close')
|
|
||||||
},
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -0,0 +1,94 @@
|
|||||||
|
<template>
|
||||||
|
<div class="wrapper">
|
||||||
|
<v-text-field
|
||||||
|
label="Vyhľadať zamestnanca"
|
||||||
|
variant="outlined"
|
||||||
|
v-model="search"
|
||||||
|
@keydown.enter="optionSelected()"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<div class="suggestion" v-if="suggestion">
|
||||||
|
<span class="hidden-part">{{ suggestion._suggestionHiddenPart }}</span>
|
||||||
|
<span>{{ suggestion._suggestionShownPart }}</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
emits: ['option-selected'],
|
||||||
|
|
||||||
|
props: {
|
||||||
|
options: {
|
||||||
|
type: Array,
|
||||||
|
required: true
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
search: ''
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
computed: {
|
||||||
|
suggestion() {
|
||||||
|
const normalizedSearch = this._normalize(this.search)
|
||||||
|
|
||||||
|
if (!normalizedSearch.length || !this.options.length)
|
||||||
|
return null
|
||||||
|
|
||||||
|
const filteredOptions = this.options.filter(option => {
|
||||||
|
const normalizedValue = this._normalize(option.value)
|
||||||
|
|
||||||
|
return normalizedSearch == normalizedValue.slice(0, normalizedSearch.length)
|
||||||
|
})
|
||||||
|
|
||||||
|
if (!filteredOptions[0])
|
||||||
|
return null
|
||||||
|
|
||||||
|
const suggestion = {
|
||||||
|
...filteredOptions[0],
|
||||||
|
_suggestionHiddenPart: filteredOptions[0].value.slice(0, normalizedSearch.length),
|
||||||
|
_suggestionShownPart: filteredOptions[0].value.slice(normalizedSearch.length, filteredOptions[0].value.length)
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
return suggestion
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
methods: {
|
||||||
|
optionSelected() {
|
||||||
|
if (!this.suggestion)
|
||||||
|
return
|
||||||
|
|
||||||
|
this.$emit('option-selected', this.suggestion)
|
||||||
|
this.search = ''
|
||||||
|
},
|
||||||
|
|
||||||
|
_normalize(value) {
|
||||||
|
return value
|
||||||
|
.trim()
|
||||||
|
.toLowerCase()
|
||||||
|
.normalize("NFD")
|
||||||
|
.replace(/[\u0300-\u036f]/g, "")
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="sass" scoped>
|
||||||
|
.wrapper
|
||||||
|
position: relative
|
||||||
|
|
||||||
|
.suggestion
|
||||||
|
position: absolute
|
||||||
|
top: 15.5px
|
||||||
|
left: 15.5px
|
||||||
|
opacity: 0.5
|
||||||
|
letter-spacing: 0.009375em
|
||||||
|
|
||||||
|
.hidden-part
|
||||||
|
opacity: 0
|
||||||
|
</style>
|
||||||
@@ -38,15 +38,8 @@ const options: Options = {
|
|||||||
ionic: {
|
ionic: {
|
||||||
disabled: false
|
disabled: false
|
||||||
},
|
},
|
||||||
toast: {
|
|
||||||
disabled: true
|
|
||||||
},
|
|
||||||
i18n: {
|
i18n: {
|
||||||
disabled: true,
|
|
||||||
languages: [
|
languages: [
|
||||||
{
|
|
||||||
title: 'English', flag: 'en', value: 'en'
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
title: "Slovenský", flag: "sk", value: "sk"
|
title: "Slovenský", flag: "sk", value: "sk"
|
||||||
}
|
}
|
||||||
@@ -57,6 +50,7 @@ const options: Options = {
|
|||||||
routes: {
|
routes: {
|
||||||
'GET v1/auth/info': true,
|
'GET v1/auth/info': true,
|
||||||
'POST v1/auth/forgot': true,
|
'POST v1/auth/forgot': true,
|
||||||
|
'POST v1/auth/reset': true,
|
||||||
'POST v1/auth/info': true,
|
'POST v1/auth/info': true,
|
||||||
'POST v1/auth/invalidate': true,
|
'POST v1/auth/invalidate': true,
|
||||||
'POST v1/auth/login': true,
|
'POST v1/auth/login': true,
|
||||||
@@ -89,17 +83,19 @@ const options: Options = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
createApp(App)
|
const app = createApp(App)
|
||||||
.use(router)
|
.use(router)
|
||||||
.use(store)
|
.use(store)
|
||||||
.use(w, options)
|
.use(w, options)
|
||||||
.use(IonicVue)
|
.use(IonicVue)
|
||||||
.use(vuetify)
|
.use(vuetify)
|
||||||
.use(wToast)
|
// .use(wToast)
|
||||||
.use(i18n, options)
|
|
||||||
.use(VueCal)
|
.use(VueCal)
|
||||||
.use(loader, {
|
.use(loader, {
|
||||||
color: '#6200EE'
|
color: '#6200EE'
|
||||||
})
|
})
|
||||||
.use(vueCal)
|
.use(vueCal)
|
||||||
.mount('#app')
|
.mount('#app')
|
||||||
|
|
||||||
|
// @ts-expect-error
|
||||||
|
export const $t = app.$i18n.t
|
||||||
@@ -45,33 +45,38 @@ const routes: Array<RouteRecordRaw> = [
|
|||||||
{
|
{
|
||||||
path: '/app/dashboard/tasks',
|
path: '/app/dashboard/tasks',
|
||||||
name: 'Dashboard - Tasks',
|
name: 'Dashboard - Tasks',
|
||||||
|
meta: { title: 'Úlohy' },
|
||||||
component: () => import('@/plugins/tm@dashboard/tasks/tasks.vue')
|
component: () => import('@/plugins/tm@dashboard/tasks/tasks.vue')
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: '/app/dashboard/teams',
|
path: '/app/dashboard/teams',
|
||||||
name: 'Dashboard - Teams',
|
name: 'Dashboard - Teams',
|
||||||
|
meta: { title: 'Tímové zobrazenie' },
|
||||||
component: () => import('@/plugins/tm@dashboard/teams/teams.vue')
|
component: () => import('@/plugins/tm@dashboard/teams/teams.vue')
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: '/app/dashboard/projects',
|
path: '/app/dashboard/projects',
|
||||||
name: 'Dashboard - Projects',
|
name: 'Dashboard - Projects',
|
||||||
|
meta: { title: 'Projektové zobrazenie' },
|
||||||
component: () => import('@/plugins/tm@dashboard/projects/projects.vue')
|
component: () => import('@/plugins/tm@dashboard/projects/projects.vue')
|
||||||
},
|
},
|
||||||
|
|
||||||
{
|
{
|
||||||
path: '/app/overview/unscheduled',
|
path: '/app/overview/unscheduled',
|
||||||
name: 'Overview - Unscheduled tasks',
|
name: 'Overview - Unscheduled tasks',
|
||||||
|
meta: { title: 'Nenaplánované úlohy' },
|
||||||
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: 'Prebiehajúce úlohy' },
|
||||||
component: () => import('@/plugins/tm@overview/tasks-ongoing/tasks-ongoing.vue')
|
component: () => import('@/plugins/tm@overview/tasks-ongoing/tasks-ongoing.vue')
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: '/app/overview/teams',
|
path: '/app/overview/teams',
|
||||||
name: 'Overview - Teams',
|
name: 'Overview - Teams',
|
||||||
|
meta: { title: 'Tímy' },
|
||||||
component: () => import('@/plugins/tm@overview/teams/teams.vue')
|
component: () => import('@/plugins/tm@overview/teams/teams.vue')
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -1,116 +1,75 @@
|
|||||||
<template>
|
<template>
|
||||||
<v-app-bar class="header">
|
<v-app-bar class="header">
|
||||||
<v-app-bar-nav-icon autoHide @click="eventBus.emit('toggle-menu')" class="menu-icon"></v-app-bar-nav-icon>
|
<v-app-bar-nav-icon @click="eventBus.emit('toggle-menu')" class="menu-icon"></v-app-bar-nav-icon>
|
||||||
|
|
||||||
<div class="d-flex align-center justify-space-between w-100 responsive-position">
|
<div class="d-flex justify-space-between align-center w-100">
|
||||||
<h1 class="mr-md-4 route-name mb-5">{{ $route.name }}</h1>
|
<h1>{{ $route.meta.title }}</h1>
|
||||||
|
|
||||||
<div class="d-flex justify-center align-center">
|
<div class="d-flex justify-end align-center w-100">
|
||||||
<div class="d-flex justify-center align-center pos-col">
|
<img class="search-icon mx-3" :src="require('@/plugins/app/_layout/app/_img/search-icon.svg')" alt="search-icon" />
|
||||||
<img
|
<input class="search-input mx-2" type="text" placeholder="Vyhľadávanie" />
|
||||||
class="search-icon"
|
|
||||||
:src="
|
|
||||||
require('@/plugins/app/_layout/app/_img/search-icon.svg')
|
|
||||||
"
|
|
||||||
alt="search-icon"
|
|
||||||
/>
|
|
||||||
<input
|
|
||||||
class="search-input"
|
|
||||||
type="text"
|
|
||||||
placeholder="Vyhľadávanie"
|
|
||||||
/>
|
|
||||||
<v-menu open-on-hover>
|
|
||||||
<template v-slot:activator="{ props }">
|
|
||||||
<v-btn v-bind="props" class="create-btn"
|
|
||||||
>+<span class="responsive-btn"
|
|
||||||
>Vytvoriť</span
|
|
||||||
></v-btn
|
|
||||||
>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<v-list class="text-left">
|
<v-menu>
|
||||||
<v-list-item class="dropdown-hover">
|
<template v-slot:activator="{ props }">
|
||||||
MASTER TASK
|
<v-btn v-bind="props" class="button mr-5">+<span class="responsive-btn">Vytvoriť</span></v-btn>
|
||||||
</v-list-item>
|
</template>
|
||||||
<v-list-item class="dropdown-hover">
|
|
||||||
SUB TASK
|
|
||||||
</v-list-item>
|
|
||||||
<v-list-item class="dropdown-hover" @click.stop="dialog=true" >
|
|
||||||
TÍM
|
|
||||||
<A-create-team-modal :visible="dialog" @close="dialog=false" />
|
|
||||||
</v-list-item>
|
|
||||||
<v-list-item class="dropdown-hover">
|
|
||||||
BLOKER
|
|
||||||
</v-list-item>
|
|
||||||
</v-list>
|
|
||||||
</v-menu>
|
|
||||||
<div
|
|
||||||
class="d-flex justify-center align-center employee-section mx-1"
|
|
||||||
>
|
|
||||||
<p v-if="user" class="employee-select">
|
|
||||||
{{
|
|
||||||
user.user.name.charAt(0) +
|
|
||||||
user.user.surname.charAt(0)
|
|
||||||
}}
|
|
||||||
</p>
|
|
||||||
<div class="text-center">
|
|
||||||
<v-menu open-on-hover>
|
|
||||||
<template v-slot:activator="{ props }">
|
|
||||||
<div>
|
|
||||||
<v-btn
|
|
||||||
class="text-transform"
|
|
||||||
v-if="user"
|
|
||||||
v-bind="props"
|
|
||||||
>
|
|
||||||
{{
|
|
||||||
`${user.user.name} ${user.user.surname}`
|
|
||||||
}}
|
|
||||||
<v-icon
|
|
||||||
class="pl-5"
|
|
||||||
icon="mdi-chevron-down"
|
|
||||||
size="x-small"
|
|
||||||
></v-icon>
|
|
||||||
</v-btn>
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<v-list class="text-center">
|
<v-list>
|
||||||
<v-list-item class="dropdown-hover">
|
<v-list-item class="cursor-pointer hover-background">MASTER TASK</v-list-item>
|
||||||
Working hours
|
<v-list-item class="cursor-pointer hover-background">SUB TASK</v-list-item>
|
||||||
</v-list-item>
|
<v-list-item class="cursor-pointer hover-background" @click="createTeamDialog = true">TÍM</v-list-item>
|
||||||
<v-list-item class="dropdown-hover">
|
<v-list-item class="cursor-pointer hover-background">BLOKER</v-list-item>
|
||||||
<v-btn class="logout-btn"
|
</v-list>
|
||||||
>Odhlásiť sa</v-btn
|
</v-menu>
|
||||||
>
|
|
||||||
</v-list-item>
|
<v-menu v-if="user">
|
||||||
</v-list>
|
<template v-slot:activator="{ props }">
|
||||||
</v-menu>
|
<v-btn class="menu-dropdown" v-bind="props">
|
||||||
|
<div class="d-flex justify-between align-center">
|
||||||
|
<p class="employee-select-avatar d-flex justify-center align-center">
|
||||||
|
{{ user.user.name.charAt(0) + user.user.surname.charAt(0) }}
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<div>
|
||||||
|
<span class="employee-name ml-4">{{ `${user.user.name} ${user.user.surname}` }}</span>
|
||||||
|
<v-icon class="ml-3" icon="mdi-chevron-down" size="x-small"></v-icon>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</v-btn>
|
||||||
</div>
|
</template>
|
||||||
|
|
||||||
|
<v-list class="text-center">
|
||||||
|
<v-list-item class="cursor-pointer hover-background">Working hours </v-list-item>
|
||||||
|
<v-list-item>
|
||||||
|
<v-btn class="button">Odhlásiť sa</v-btn>
|
||||||
|
</v-list-item>
|
||||||
|
</v-list>
|
||||||
|
</v-menu>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<A-team-modal :visible="createTeamDialog" @close="createTeamDialog = false" />
|
||||||
</v-app-bar>
|
</v-app-bar>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import ACreateTeamModal from '../../../_components/a-create-team-modal.vue'
|
import ATeamModal from '@/plugins/app/_components/a-team-modal.vue'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
ACreateTeamModal
|
ATeamModal
|
||||||
},
|
},
|
||||||
|
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
user: null,
|
user: null,
|
||||||
dialog: false
|
createTeamDialog: false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
async created() {
|
async created() {
|
||||||
try {
|
try {
|
||||||
this.user = await this.$axios.get_auth_data("v1/auth/info")
|
this.user = await this.$axios.get_auth_data('v1/auth/info')
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.log(error)
|
console.log(error)
|
||||||
}
|
}
|
||||||
@@ -119,77 +78,53 @@ export default {
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="sass" scoped>
|
<style lang="sass" scoped>
|
||||||
.route-name
|
|
||||||
font-size: 22px
|
|
||||||
|
|
||||||
.header
|
.header
|
||||||
position: relative !important
|
position: relative !important
|
||||||
box-shadow: none !important
|
box-shadow: none !important
|
||||||
border-bottom: 1px solid rgba(0, 0, 0, 0.2)
|
border-bottom: 1px solid rgba(0, 0, 0, 0.2)
|
||||||
padding: 25px 15px
|
padding: 25px 15px
|
||||||
|
|
||||||
@media (min-width: 992px)
|
.button
|
||||||
|
background: #7f39fb
|
||||||
|
border-radius: 4px
|
||||||
|
color: #fff
|
||||||
|
|
||||||
.menu-icon
|
.menu-icon
|
||||||
display: none
|
display: none
|
||||||
|
|
||||||
.create-btn
|
.search-input
|
||||||
background: #7f39fb
|
outline: none
|
||||||
border-radius: 4px
|
|
||||||
color: #fff
|
|
||||||
margin-right: 30px
|
|
||||||
|
|
||||||
.logout-btn
|
.search-icon
|
||||||
background: #7f39fb
|
border: 2px solid #e0e0e0
|
||||||
border-radius: 4px
|
padding: 6px
|
||||||
color: #fff
|
border-radius: 6px
|
||||||
|
|
||||||
.text-transform
|
|
||||||
text-transform: capitalize
|
|
||||||
|
|
||||||
.search-input
|
.menu-dropdown
|
||||||
outline: none
|
border: 1px solid rgba(33, 33, 33, 0.08) !important
|
||||||
margin-left: 10px
|
|
||||||
margin-right: 5px
|
|
||||||
|
|
||||||
.search-icon
|
|
||||||
border: 2px solid #e0e0e0
|
|
||||||
padding: 6px
|
|
||||||
border-radius: 6px
|
|
||||||
|
|
||||||
.employee-section
|
|
||||||
border: 1px solid rgba(33, 33, 33, 0.08)
|
|
||||||
border-radius: 16px
|
border-radius: 16px
|
||||||
height: 70px
|
height: 70px
|
||||||
|
|
||||||
.employee-select
|
.employee-select-avatar
|
||||||
background: #6200EE
|
background: #6200EE
|
||||||
color: #fff
|
color: #fff
|
||||||
border-radius: 50%
|
border-radius: 50%
|
||||||
padding: 13px
|
padding: 13px
|
||||||
margin-left: 10px
|
height: 42px
|
||||||
|
width: 42px
|
||||||
@media screen and (max-width: 772px)
|
|
||||||
.route-name, .search-icon
|
|
||||||
display: none
|
|
||||||
|
|
||||||
@media screen and (max-width: 617px)
|
|
||||||
.responsive-position
|
|
||||||
justify-content: center !important
|
|
||||||
.pos-col
|
|
||||||
display: flex
|
|
||||||
flex-direction: column-reverse
|
|
||||||
justify-content: center
|
|
||||||
margin: auto
|
|
||||||
|
|
||||||
.employee-section, .create-btn, .search-input
|
|
||||||
margin-top: 20px
|
|
||||||
|
|
||||||
.header
|
|
||||||
padding: 75px 0
|
|
||||||
|
|
||||||
.dropdown-hover
|
|
||||||
cursor: pointer !important
|
|
||||||
|
|
||||||
&:hover
|
&:hover
|
||||||
background: #F2E7FE
|
background-color: rgba(0, 0, 0, var(--v-hover-opacity))
|
||||||
|
cursor: pointer
|
||||||
|
|
||||||
|
@media (max-width: 991px)
|
||||||
|
.menu-icon
|
||||||
|
display: block !important
|
||||||
|
|
||||||
|
h1
|
||||||
|
display: none
|
||||||
|
|
||||||
|
.employee-name
|
||||||
|
display: none
|
||||||
</style>
|
</style>
|
||||||
@@ -33,33 +33,30 @@
|
|||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
unscheduledTasksLength: null,
|
pages: [{
|
||||||
pages: [
|
title: 'Úlohy',
|
||||||
{
|
pageName: 'Dashboard - Tasks'
|
||||||
title: "Úlohy",
|
},
|
||||||
pageName: "Dashboard - Tasks",
|
{
|
||||||
},
|
title: 'Tímove zobrazenie',
|
||||||
{
|
pageName: 'Dashboard - Teams'
|
||||||
title: "Tímove zobrazenie",
|
},
|
||||||
pageName: "Dashboard - Teams",
|
{
|
||||||
},
|
title: 'Projektové zobrazenie',
|
||||||
{
|
pageName: 'Dashboard - Projects'
|
||||||
title: "Projektové zobrazenie",
|
},
|
||||||
pageName: "Dashboard - Projects",
|
{
|
||||||
},
|
title: 'Nenaplánované úlohy',
|
||||||
{
|
pageName: 'Overview - Unscheduled tasks'
|
||||||
title: "Nenaplánované úlohy",
|
},
|
||||||
pageName: "Overview - Unscheduled tasks",
|
{
|
||||||
},
|
title: 'Prebiehajúce úlohy',
|
||||||
{
|
pageName: 'Overview - Ongoing tasks'
|
||||||
title: "Ongoing tasky",
|
},
|
||||||
pageName: "Overview - Ongoing tasks",
|
{
|
||||||
},
|
title: 'Tímy',
|
||||||
{
|
pageName: 'Overview - Teams'
|
||||||
title: "Tímy",
|
}]
|
||||||
pageName: "Overview - Teams",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
@@ -19,3 +19,9 @@ th
|
|||||||
|
|
||||||
.v-card
|
.v-card
|
||||||
padding: 35px !important
|
padding: 35px !important
|
||||||
|
|
||||||
|
.cursor-pointer:hover
|
||||||
|
cursor: pointer
|
||||||
|
|
||||||
|
.hover-background:hover
|
||||||
|
background-color: rgba(0, 0, 0, var(--v-hover-opacity))
|
||||||
@@ -1,5 +1,7 @@
|
|||||||
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@100&display=swap')
|
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@100&display=swap')
|
||||||
|
|
||||||
|
@import './vuetify/v-dialog'
|
||||||
|
|
||||||
@import './global'
|
@import './global'
|
||||||
@import '@/plugins/lib@auth/_theme/auth.theme'
|
@import '@/plugins/lib@auth/_theme/auth.theme'
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,4 @@
|
|||||||
|
.v-dialog
|
||||||
|
h1
|
||||||
|
font-size: 22px
|
||||||
|
font-weight: 300
|
||||||
@@ -1,7 +1,8 @@
|
|||||||
|
import { $t } from '@/plugins/app/_config/main'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
parseErrors(errors) {
|
parseErrors(errors) {
|
||||||
// @ts-expect-error
|
// @ts-expect-error
|
||||||
return Object.values(errors).map(error => error?.$message).join(', ')
|
return Object.values(errors).map(error => $t(error?.$message)).join('. ')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -46,8 +46,8 @@ export default {
|
|||||||
if (!(await this.v$.$validate())) return console.log(this.v$)
|
if (!(await this.v$.$validate())) return console.log(this.v$)
|
||||||
|
|
||||||
try {
|
try {
|
||||||
await this.$axios.post_data('v1/auth/forgot', this.form)
|
await this.$axios.post_data('v1/auth/reset', this.form)
|
||||||
this.$router.push({ name: 'Reset password' })
|
this.$router.push({ name: 'Login' })
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
this.$toast.error(error.data.error)
|
this.$toast.error(error.data.error)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -19,7 +19,9 @@
|
|||||||
<td class="task-action">
|
<td class="task-action">
|
||||||
<div class="d-flex justify-start">
|
<div class="d-flex justify-start">
|
||||||
<img class="pencil-icon" :src="require('@/plugins/tm@overview/_img/pencil-icon.svg')" alt="pencil-icon" />
|
<img class="pencil-icon" :src="require('@/plugins/tm@overview/_img/pencil-icon.svg')" alt="pencil-icon" />
|
||||||
<img class="trash-icon" :src="require('@/plugins/tm@overview/_img/trash-icon.svg')" alt="trash-icon" />
|
<img class="trash-icon" :src="require('@/plugins/tm@overview/_img/trash-icon.svg')" alt="trash-icon" @click.stop="showDeleteModal = true" />
|
||||||
|
|
||||||
|
<A-delete-task-modal :show="showDeleteModal" :task="task" @delete-task="deleteTask" @close-modal="showDeleteModal = false" />
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@@ -28,12 +30,35 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import ADeleteTaskModal from '@/plugins/app/_components/a-delete-task-modal.vue'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
components: {
|
||||||
|
ADeleteTaskModal
|
||||||
|
},
|
||||||
|
|
||||||
props: {
|
props: {
|
||||||
tasks: {
|
tasks: {
|
||||||
type: Array,
|
type: Array,
|
||||||
required: true
|
required: true
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
showDeleteModal: false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
methods: {
|
||||||
|
async deleteTask(id) {
|
||||||
|
try {
|
||||||
|
await this.$axios.delete(`v1/teams/${id}`)
|
||||||
|
this.showDeleteModal = false
|
||||||
|
} catch (error) {
|
||||||
|
this.$toast.error(error)
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -17,7 +17,9 @@
|
|||||||
<td class="task-action">
|
<td class="task-action">
|
||||||
<div class="d-flex justify-start">
|
<div class="d-flex justify-start">
|
||||||
<img class="pencil-icon" :src="require('@/plugins/tm@overview/_img/pencil-icon.svg')" alt="pencil-icon">
|
<img class="pencil-icon" :src="require('@/plugins/tm@overview/_img/pencil-icon.svg')" alt="pencil-icon">
|
||||||
<img class="trash-icon" :src="require('@/plugins/tm@overview/_img/trash-icon.svg')" alt="trash-icon">
|
<img class="trash-icon" :src="require('@/plugins/tm@overview/_img/trash-icon.svg')" alt="trash-icon" @click.stop="showDeleteModal = true">
|
||||||
|
|
||||||
|
<A-delete-task-modal :show="showDeleteModal" :task="task" @delete-task="deleteTask" @close-modal="showDeleteModal = false" />
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@@ -26,12 +28,35 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import ADeleteTaskModal from '@/plugins/app/_components/a-delete-task-modal.vue'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
components: {
|
||||||
|
ADeleteTaskModal
|
||||||
|
},
|
||||||
|
|
||||||
props: {
|
props: {
|
||||||
tasks: {
|
tasks: {
|
||||||
type: Array,
|
type: Array,
|
||||||
required: true
|
required: true
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
showDeleteModal: false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
methods: {
|
||||||
|
async deleteTask(id) {
|
||||||
|
try {
|
||||||
|
await this.$axios.delete(`v1/teams/${id}`)
|
||||||
|
this.showDeleteModal = false
|
||||||
|
} catch (error) {
|
||||||
|
this.$toast.error(error)
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -12,24 +12,10 @@
|
|||||||
<td>{{ team.name }}</td>
|
<td>{{ team.name }}</td>
|
||||||
<td class="task-action">
|
<td class="task-action">
|
||||||
<div class="d-flex justify-start">
|
<div class="d-flex justify-start">
|
||||||
<img
|
<img class="pencil-icon" :src="require('@/plugins/tm@overview/_img/pencil-icon.svg')" alt="pencil-icon" />
|
||||||
class="pencil-icon"
|
<img class="trash-icon" :src="require('@/plugins/tm@overview/_img/trash-icon.svg')" alt="trash-icon" @click.stop="showDeleteModal = true" />
|
||||||
:src="
|
|
||||||
require('@/plugins/tm@overview/_img/pencil-icon.svg')
|
<A-delete-team-modal :show="showDeleteModal" :team="team" @delete-team="deleteTeam" @close-modal="showDeleteModal = false" />
|
||||||
"
|
|
||||||
alt="pencil-icon"
|
|
||||||
@click.stop="editTeam=true"
|
|
||||||
/>
|
|
||||||
<A-edit-team-modal :visible="editTeam" @close="editTeam=false" />
|
|
||||||
<img
|
|
||||||
class="trash-icon"
|
|
||||||
:src="
|
|
||||||
require('@/plugins/tm@overview/_img/trash-icon.svg')
|
|
||||||
"
|
|
||||||
alt="trash-icon"
|
|
||||||
@click.stop="dialog=true"
|
|
||||||
/>
|
|
||||||
<A-delete-team-modal :visible="dialog" @close="dialog=false" />
|
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@@ -38,27 +24,35 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import ADeleteTeamModal from '../../../app/_components/a-delete-team-modal.vue'
|
import ADeleteTeamModal from '@/plugins/app/_components/a-delete-team-modal.vue'
|
||||||
import AEditTeamModal from '../../../app/_components/a-edit-team-modal.vue'
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
ADeleteTeamModal,
|
ADeleteTeamModal
|
||||||
AEditTeamModal
|
|
||||||
},
|
|
||||||
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
dialog: false,
|
|
||||||
editTeam: false
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
|
|
||||||
props: {
|
props: {
|
||||||
teams: {
|
teams: {
|
||||||
type: Array,
|
type: Array,
|
||||||
required: true,
|
required: true
|
||||||
},
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
showDeleteModal: false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
methods: {
|
||||||
|
async deleteTeam(id) {
|
||||||
|
try {
|
||||||
|
await this.$axios.delete(`v1/teams/${id}`)
|
||||||
|
this.showDeleteModal = false
|
||||||
|
} catch (error) {
|
||||||
|
this.$toast.error(error)
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Reference in new issue
Block a user