Change interval to 1h. Create StatusTypes
This commit is contained in:
@@ -57,9 +57,9 @@
|
|||||||
resource-key="id"
|
resource-key="id"
|
||||||
resource-label="displayName"
|
resource-label="displayName"
|
||||||
resource-width="32"
|
resource-width="32"
|
||||||
:interval-start="12"
|
:interval-start="6"
|
||||||
:interval-count="36"
|
:interval-count="18"
|
||||||
:interval-minutes="30"
|
:interval-minutes="60"
|
||||||
cell-width="48"
|
cell-width="48"
|
||||||
style="--calendar-resources-width: 48px"
|
style="--calendar-resources-width: 48px"
|
||||||
resource-min-height="40"
|
resource-min-height="40"
|
||||||
@@ -115,6 +115,7 @@ import { Boat, useBoatStore } from 'src/stores/boat';
|
|||||||
import { useScheduleStore } from 'src/stores/schedule';
|
import { useScheduleStore } from 'src/stores/schedule';
|
||||||
import { date } from 'quasar';
|
import { date } from 'quasar';
|
||||||
import { computed } from 'vue';
|
import { computed } from 'vue';
|
||||||
|
import type { StatusTypes } from 'src/stores/schedule';
|
||||||
|
|
||||||
const durations = [1, 1.5, 2, 2.5, 3, 3.5, 4];
|
const durations = [1, 1.5, 2, 2.5, 3, 3.5, 4];
|
||||||
|
|
||||||
@@ -180,7 +181,7 @@ function getStyle(event: {
|
|||||||
left: number;
|
left: number;
|
||||||
width: number;
|
width: number;
|
||||||
title: string;
|
title: string;
|
||||||
status: 'tentative' | 'confirmed' | 'pending';
|
status: StatusTypes;
|
||||||
}) {
|
}) {
|
||||||
return {
|
return {
|
||||||
position: 'absolute',
|
position: 'absolute',
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ import { Boat, useBoatStore } from './boat';
|
|||||||
import { date } from 'quasar';
|
import { date } from 'quasar';
|
||||||
import { DateOptions } from 'quasar';
|
import { DateOptions } from 'quasar';
|
||||||
|
|
||||||
|
export type StatusTypes = 'tentative' | 'confirmed' | 'pending' | undefined;
|
||||||
export interface Reservation {
|
export interface Reservation {
|
||||||
id: number;
|
id: number;
|
||||||
user: string;
|
user: string;
|
||||||
@@ -11,7 +12,7 @@ export interface Reservation {
|
|||||||
end: Date;
|
end: Date;
|
||||||
resource: Boat;
|
resource: Boat;
|
||||||
reservationDate: Date;
|
reservationDate: Date;
|
||||||
status?: string;
|
status?: StatusTypes;
|
||||||
}
|
}
|
||||||
|
|
||||||
function getSampleData(): Reservation[] {
|
function getSampleData(): Reservation[] {
|
||||||
|
|||||||
Reference in New Issue
Block a user