equipment-file.vue 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. <template>
  2. <view class="mt-3 px3">
  3. <view class="f-size-30 f-weight-bold py2 border-bottom my3">设备图片</view>
  4. <!-- <view class="main d-flex a-center mb-3">
  5. <view class="img">
  6. <image src="../../static/images/add.png" mode=""></image>
  7. </view>
  8. <view class="content ml-2">
  9. <view class="text-color-3 f-size-30 one-ellipsis">2020年北京互联网技术交流会年北京互联网技术交流会</view>
  10. <view class="text-color-9 f-size-24">PDF文件</view>
  11. </view>
  12. <view class="icon ml-auto">
  13. <u-icon name="download " size="45"></u-icon>
  14. </view>
  15. </view> -->
  16. <!-- -->
  17. <view v-for="(item, index) in infoData.sbFileList" :key="index">
  18. <image
  19. style="width: 120rpx; height: 120rpx"
  20. :src="item.url"
  21. mode=""
  22. ></image>
  23. </view>
  24. <view class="f-size-30 f-weight-bold py2 border-bottom my3">验收文件</view>
  25. <view v-for="(item, index) in infoData.recheckFileList" :key="index">
  26. <image
  27. style="width: 120rpx; height: 120rpx"
  28. :src="item.url"
  29. mode=""
  30. ></image>
  31. </view>
  32. <view class="f-size-30 f-weight-bold py2 border-bottom my3">维保手册</view>
  33. <view v-for="(item, index) in infoData.repairFileList" :key="index">
  34. <image
  35. style="width: 120rpx; height: 120rpx"
  36. :src="item.url"
  37. mode=""
  38. ></image>
  39. </view>
  40. <view class="f-size-30 f-weight-bold py2 border-bottom my3">使用手册</view>
  41. <view v-for="(item, index) in infoData.useFileList" :key="index">
  42. <image
  43. style="width: 120rpx; height: 120rpx"
  44. :src="item.url"
  45. mode=""
  46. ></image>
  47. </view>
  48. </view>
  49. </template>
  50. <script>
  51. export default {
  52. data() {
  53. return {
  54. infoData: {},
  55. detailId: ''
  56. };
  57. },
  58. onLoad(options) {
  59. this.detailId = options.detailId;
  60. this.initData();
  61. },
  62. methods: {
  63. initData() {
  64. this.$Http
  65. .fetchSbInfo({
  66. id: this.detailId
  67. })
  68. .then((res) => {
  69. this.infoData = res.data;
  70. res.data.sbFileList.forEach((d) => {
  71. d.url = this.$BaseTool.UserUtil.getFileUrl(d.url);
  72. d.recheckFileList = this.$BaseTool.UserUtil.getFileUrl(
  73. d.recheckFileList
  74. );
  75. d.useFileList = this.$BaseTool.UserUtil.getFileUrl(d.useFileList);
  76. d.repairFileList = this.$BaseTool.UserUtil.getFileUrl(
  77. d.repairFileList
  78. );
  79. });
  80. });
  81. }
  82. }
  83. };
  84. </script>
  85. <style lang="less" scoped>
  86. .main {
  87. .img {
  88. width: 76rpx;
  89. height: 76rpx;
  90. border-radius: 10rpx;
  91. image {
  92. width: 76rpx;
  93. height: 76rpx;
  94. border-radius: 10rpx;
  95. }
  96. }
  97. .content {
  98. .text-color-3 {
  99. width: 500rpx;
  100. }
  101. }
  102. }
  103. </style>