""" Options: Date: 2024-12-22 21:28:27 Version: 8.51 Tip: To override a DTO option, remove "#" prefix before updating BaseUrl: https://blazor-gallery.servicestack.net #GlobalNamespace: #AddServiceStackTypes: True #AddResponseStatus: False #AddImplicitVersion: #AddDescriptionAsComments: True IncludeTypes: DeleteBooking.* #ExcludeTypes: #DefaultImports: datetime,decimal,marshmallow.fields:*,servicestack:*,typing:*,dataclasses:dataclass/field,dataclasses_json:dataclass_json/LetterCase/Undefined/config,enum:Enum/IntEnum #DataClass: #DataClassJson: """ import datetime import decimal from marshmallow.fields import * from servicestack import * from typing import * from dataclasses import dataclass, field from dataclasses_json import dataclass_json, LetterCase, Undefined, config from enum import Enum, IntEnum @dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE) @dataclass class Booking(AuditBase): """ Booking Details """ id: int = 0 name: Optional[str] = None room_type: Optional[RoomType] = None room_number: int = 0 booking_start_date: datetime.datetime = datetime.datetime(1, 1, 1) booking_end_date: Optional[datetime.datetime] = None cost: Decimal = decimal.Decimal(0) # @References(typeof(Coupon)) coupon_id: Optional[str] = None discount: Optional[Coupon] = None notes: Optional[str] = None cancelled: Optional[bool] = None # @Route("/booking/{Id}", "DELETE") # @ValidateRequest(Validator="HasRole(`Manager`)") @dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE) @dataclass class DeleteBooking(IReturnVoid, IDeleteDb[Booking]): """ Delete a Booking """ id: int = 0