roadPhotos.ts 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. import {ref} from "vue";
  2. import {PhotoRaw} from "@/store/photos";
  3. export type RoadPhotoTable = {
  4. arrivalTime: string,
  5. weather: string,
  6. conditions: string,
  7. location: string,
  8. illustrate: string,
  9. other: string,
  10. url?: string,
  11. compassAngle: number
  12. }
  13. export type RoadPhoto = {
  14. id: string
  15. photoUrl: string
  16. url: string
  17. title: string
  18. time: number,
  19. table?: RoadPhotoTable,
  20. data: any
  21. sceneData: {
  22. measures: PhotoRaw['measures'],
  23. fixPoints: PhotoRaw['fixPoints'],
  24. basePoints: PhotoRaw['basePoints']
  25. baseLines: PhotoRaw['baseLines']
  26. }
  27. }
  28. export const getDefaultTable = (road): RoadPhotoTable => {
  29. return road.table ? { ...road.table } : {
  30. arrivalTime: "2020-10-12",
  31. weather: "晴天",
  32. conditions: "普通",
  33. location: "",
  34. compassAngle: 0,
  35. illustrate: "说明:绘图比例为1:215,单位为米。车辆甲为小轿车,无车号。车辆乙为小轿车,无车号。选取道路边缘线为基准线,井盖为基准点。",
  36. other: "",
  37. }
  38. }
  39. export const roadPhotos = ref<RoadPhoto[]>([])