about.vue 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. <template>
  2. <view>
  3. <view class="about">
  4. <view class="logo">
  5. <view>{{about.name?about.name:''}}
  6. <text v-if="about.version">当前版本:{{about.version}}</text>
  7. </view>
  8. </view>
  9. <view class="cellphone" @tap="callPhone" v-if="about.hotLine">服务热线:{{about.hotLine}}</view>
  10. <view class="info">
  11. <rich-text :nodes="about.aboutAs" @tap="richImg"></rich-text>
  12. </view>
  13. </view>
  14. <view class="copy">{{about.recordNumber?about.recordNumber:''}}</view>
  15. </view>
  16. </template>
  17. <script>
  18. const req = require("../../utils/request.js");
  19. export default {
  20. data() {
  21. return {
  22. about: {}
  23. };
  24. },
  25. components: {},
  26. props: {},
  27. onLoad: function (options) {
  28. this.getAbout();
  29. },
  30. methods: {
  31. callPhone() {
  32. uni.makePhoneCall({
  33. phoneNumber: this.about.hotLine
  34. });
  35. },
  36. getAbout() {
  37. var _this = this;
  38. req.getRequest('/api/aboutAs', {}, function (res) {
  39. _this.setData({
  40. about: res
  41. });
  42. }, true);
  43. }
  44. }
  45. };
  46. </script>
  47. <style>
  48. @import "./about.css";
  49. </style>