<el-table-column label="图片" align="center" prop="postImageList" width="400">

        <template slot-scope="scope">

          <image-preview v-for="(item,index) in scope.row.postImageList"

            :src="item"

            style="width: 100px; height: 100px"

            />

            <!-- :preview-src-list="getImgList(scope.row.workPhoto, index)" -->

        </template>

      </el-table-column>

 /** 查询我的空间列表 */

    getList() {

      this.loading = true;

      listMyspace(this.queryParams).then(response => {

        this.myspaceList = response.rows;

        for (var i = 0; i < this.myspaceList.length; i++) {

          this.myspaceList[i].postImageList = this.myspaceList[i].postImages.split(',');

        };

       

        this.total = response.total;

        this.loading = false;

      });

    },

Logo

汇聚全球AI编程工具,助力开发者即刻编程。

更多推荐