zxl
4 天以前 c1e567ddda7f65651179a8a73ca849b07b066b14
manager/src/views/goods/goods-info/goods.vue
@@ -89,9 +89,12 @@
        <template slot="goodsSlot" slot-scope="{ row }">
          <div style="margin: 5px 0px; height: 80px; display: flex">
            <div style="">
              <img
              <img v-if="row.original"
                :src="row.original"
                style="height: 60px; margin-top: 1px; width: 60px"
              />
              <video v-else
                     :src="row.goodsVideo" style="height: 60px; margin-top: 1px; width: 60px"
              />
            </div>
@@ -159,6 +162,7 @@
<script>
import { getGoodsListData, upGoods, lowGoods } from "@/api/goods";
import {getSts} from '@/api/file'
import vueQr from "vue-qr";
export default {
  components: {
@@ -376,6 +380,18 @@
        this.loading = false;
        if (res.success) {
          this.data = res.result.records;
          getSts().then(res => {
         const endpoint = res.data.endpoint
            this.data.forEach(item => {
              if (item.goodsVideo != null && item.goodsVideo.indexOf('http')===-1) {
                item.goodsVideo = endpoint + '/' + item.goodsVideo;
              }
              if (item.original !=null && item.original.indexOf('http') ===-1) {
                item.original = endpoint + '/' + item.original;
              }
            })
          })
          this.total = res.result.total;
        }
      });