Office365(blocker) Changed color to blue

This commit is contained in:
Matej Glasnák committed 2024-12-24 09:12:13 +01:00
1 parent 7b09fe15c7
commit a98abb4f82
2 files changed
+29 -7

No files matched your search

+1 -1
View File
@@ -1,2 +1,2 @@
VUE_APP_WAXIOS_URL=https://taskmanager.internal.studiotem.com/api/
VUE_APP_WAXIOS_URL=https://tm.jandl.sk/api/
# VUE_APP_WAXIOS_URL=https://tm.jandl.sk/api/
@@ -7,27 +7,27 @@
</div>
</div>
<div v-else-if="['subtask', 'blocker', 'adhoc', 'vacation', 'free_day', 'office365', 'office365_blocker'].includes(event.type)" class="custom-event-body colWidth h-100 d-flex flex-column justify-space-between" :class="subtaskCssClass" :style="{ backgroundColor: event._timeblock_is_finished || event.subtask?.is_finished ? '#dedfe0' : event.color || event.subtask?.color }">
<div v-else-if="['subtask', 'blocker', 'adhoc', 'vacation', 'free_day', 'office365', 'office365_blocker'].includes(event.type)" class="custom-event-body colWidth h-100 d-flex flex-column justify-space-between" :class="subtaskCssClass" :style="{ backgroundColor: eventColor.backgroundColor, color: eventColor.color }">
<div class="event-content" :class="{ 'is-blocker': props.event.isBlocker }">
<template v-if="['subtask', 'office365'].includes(event.type)">
<small v-if="props.event.subtask.project_code" class="project-code">{{ props.event.subtask.project_code }}</small>
<h3>{{ props.event.subtask.title ?? props.event.subtask.master_task?.name ?? props.event.subtask.master_task }}</h3>
<h3 class="text-inherit">{{ props.event.subtask.title ?? props.event.subtask.master_task?.name ?? props.event.subtask.master_task }}</h3>
</template>
<template v-else>
<v-tooltip :text="event.blocker?.approved ? 'Schválený' : 'Neschválený'" location="bottom">
<template v-slot:activator="{ props }">
<div v-bind="props">
<h3>{{ props.event?.blocker?.approved ? props.event?.blocker?.name : props.event?.blocker?.name + '*' }}</h3>
<h3 class="text-inherit">{{ props.event?.blocker?.approved ? props.event?.blocker?.name : props.event?.blocker?.name + '*' }}</h3>
</div>
</template>
</v-tooltip>
</template>
<div class="d-flex align-center event-details event-initials-wrapper">
<div class="event-initials d-flex justify-center align-center">
<small>{{ props.event.initials }}</small>
<div class="event-initials d-flex justify-center align-center" :style="{ borderColor: eventColor.color }">
<small class="text-inherit">{{ props.event.initials }}</small>
</div>
<small class="event-initials-date">{{ props.event.date?.toLocaleDateString('sk-SK') }}</small>
<small class="event-initials-date text-inherit">{{ props.event.date?.toLocaleDateString('sk-SK') }}</small>
</div>
<div v-if="['subtask', 'office365'].includes(event.type)" class="d-flex align-center">
@@ -97,6 +97,25 @@ const deadline: ComputedRef<string | undefined> = computed(() => {
const eventLength: ComputedRef<number> = computed(() => props.event.end.getTime() - props.event.start.getTime())
const eventColor: ComputedRef<{ color: string, backgroundColor: string }> = computed(() => {
if (props.event.type === 'office365_blocker') {
return {
color: '#ffffff',
backgroundColor: '#326cb8'
}
} else if (props.event._timeblock_is_finished || props.event.subtask?.is_finished) {
return {
color: '#000000',
backgroundColor: '#dedfe0'
}
}
return {
color: '#000000',
backgroundColor: props.event.color || props.event.subtask?.color
}
})
const subtaskCssClass: ComputedRef<string> = computed(() => {
const classes = []
if (eventLength.value <= 9000000) classes.push('short-event')
@@ -112,6 +131,9 @@ const isOfficeEvent: ComputedRef<boolean> = computed(() => {
</script>
<style lang="sass" scoped>
.text-inherit
color: inherit !important
.event
height: 100%