InspectionSheet.vue 973 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. <template>
  2. <!-- 质检单 -->
  3. <view class="">
  4. <view class="img-wrap" v-if="imgList.length > 0">
  5. <image class="image" :src="apiUrl + item.accessUrl" mode="" v-for="item in imgList"></image>
  6. </view>
  7. <view class="u-empty" v-else>
  8. <u-empty></u-empty>
  9. </view>
  10. </view>
  11. </template>
  12. <script>
  13. import { get } from '@/utils/api.js'
  14. export default {
  15. props: ['batchNum', 'inventoryCode', 'code'],
  16. data() {
  17. return {
  18. imgList: []
  19. }
  20. },
  21. created() {
  22. this.getdata()
  23. },
  24. methods: {
  25. getdata() {
  26. let par = {
  27. batchNum: this.batchNum,
  28. inventoryCode: this.inventoryCode,
  29. code: this.code
  30. }
  31. par = this.URLSearchParams(par)
  32. // get(this.apiUrl + "/InventoryBook/select/getAnalysisCertificate?" + par).then((res) => {
  33. // if (res.success) {
  34. // this.imgList = res.data || []
  35. // }
  36. // });
  37. }
  38. }
  39. }
  40. </script>
  41. <style lang="scss" scoped>
  42. .image {
  43. width: 100%;
  44. }
  45. .u-empty {
  46. padding: 30rpx;
  47. }
  48. </style>