Place.ts 963 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. import { Str, Uid, Attr, Num } from 'pinia-orm/dist/decorators'
  2. import ApiModel from '~/models/ApiModel'
  3. import { Assert, IriEncoded } from '~/models/decorators'
  4. import Country from '~/models/Core/Country'
  5. /**
  6. * AP2i Model : Freemium / Place
  7. *
  8. * */
  9. export default class Place extends ApiModel {
  10. static entity = 'freemium/places'
  11. @Uid()
  12. declare id: number | string | null
  13. @Attr(null)
  14. declare EventId: number | null
  15. @Str(null)
  16. @Assert({ nullable: false, max: 255 })
  17. declare name: string | null
  18. @Str(null)
  19. declare streetAddress: string | null
  20. @Str(null)
  21. declare streetAddressSecond: string | null
  22. @Str(null)
  23. declare streetAddressThird: string | null
  24. @Str(null)
  25. declare postalCode: string | null
  26. @Str(null)
  27. declare addressCity: string | null
  28. @IriEncoded(Country)
  29. @Attr(null)
  30. declare addressCountry: number | null
  31. @Num(null)
  32. declare latitude: number | null
  33. @Num(null)
  34. declare longitude: number | null
  35. }