map.vue 941 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. <template>
  2. <view>
  3. <page-head :title="title"></page-head>
  4. <view class="uni-common-mt">
  5. <view>
  6. <map :latitude="latitude" :longitude="longitude" :markers="covers">
  7. </map>
  8. </view>
  9. </view>
  10. </view>
  11. </template>
  12. <script>
  13. export default {
  14. data() {
  15. return {
  16. title: 'map',
  17. latitude: 39.909,
  18. longitude: 116.39742,
  19. covers: [{
  20. latitude: 39.9085,
  21. longitude: 116.39747,
  22. // #ifdef APP-PLUS
  23. iconPath: '../../../static/app-plus/location@3x.png',
  24. // #endif
  25. // #ifndef APP-PLUS
  26. iconPath: '../../../static/location.png',
  27. // #endif
  28. }, {
  29. latitude: 39.90,
  30. longitude: 116.39,
  31. // #ifdef APP-PLUS
  32. iconPath: '../../../static/app-plus/location@3x.png',
  33. // #endif
  34. // #ifndef APP-PLUS
  35. iconPath: '../../../static/location.png',
  36. // #endif
  37. }]
  38. }
  39. },
  40. methods: {
  41. }
  42. }
  43. </script>
  44. <style>
  45. map {
  46. width: 100%;
  47. height: 600rpx;
  48. }
  49. </style>