Merge branch 'master' of gitee.com:beijing_hongye_huicheng/lilishop-ui
This commit is contained in:
		
						commit
						709a3f71fd
					
				@ -490,4 +490,24 @@ export const getHotWordsHistory = (params) => {
 | 
				
			|||||||
  return getRequest(`/hotwords/hotwords/history`,params);
 | 
					  return getRequest(`/hotwords/hotwords/history`,params);
 | 
				
			||||||
};
 | 
					};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					// 获取文件目录列表
 | 
				
			||||||
 | 
					export const getFileDirectory = () => {
 | 
				
			||||||
 | 
					  return getRequest(commonUrl+`/common/resource/fileDirectory`);
 | 
				
			||||||
 | 
					};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					// 添加文件目录
 | 
				
			||||||
 | 
					export const addFileDirectory = (params) => {
 | 
				
			||||||
 | 
					  return postRequestWithNoForm(commonUrl+`/common/resource/fileDirectory`,params);
 | 
				
			||||||
 | 
					};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					// 修改文件目录
 | 
				
			||||||
 | 
					export const updateFileDirectory = (params) => {
 | 
				
			||||||
 | 
					  return putRequestWithNoForm(commonUrl+`/common/resource/fileDirectory`,params);
 | 
				
			||||||
 | 
					};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					// 删除文件目录
 | 
				
			||||||
 | 
					export const delFileDirectory = (id) => {
 | 
				
			||||||
 | 
					  return deleteRequest(commonUrl+`/common/resource/fileDirectory/${id}`);
 | 
				
			||||||
 | 
					};
 | 
				
			||||||
 | 
				
			|||||||
@ -1,20 +1,20 @@
 | 
				
			|||||||
<template>
 | 
					<template>
 | 
				
			||||||
  <div>
 | 
					  <div>
 | 
				
			||||||
    <div class="breadcrumb">
 | 
					    <div class="breadcrumb">
 | 
				
			||||||
      <span @click="clickBreadcrumb(item,index)" :class="{'active':item.selected}" v-for="(item,index) in dateList"
 | 
					      <span @click="clickBreadcrumb(item, index)" :class="{ 'active': item.selected }" v-for="(item, index) in dateList"
 | 
				
			||||||
        :key="index"> {{item.title}}</span>
 | 
					        :key="index"> {{ item.title }}</span>
 | 
				
			||||||
      <div class="date-picker">
 | 
					      <div class="date-picker">
 | 
				
			||||||
        <Select @on-change="changeSelect(selectedWay)" v-model="month" placeholder="年月查询" clearable
 | 
					        <Select @on-change="changeSelect($event, selectedWay)" :value="month" placeholder="年月查询" clearable
 | 
				
			||||||
          style="width:200px;margin-left:10px;">
 | 
					          style="width:200px;margin-left:10px;">
 | 
				
			||||||
          <Option v-for="(item,index) in dates" :value="item.year+'-'+item.month" :key="index" clearable>
 | 
					          <Option v-for="(item, i) in dates" :value="item.year + '-' + item.month" :key="i" clearable>
 | 
				
			||||||
            {{ item.year+'年'+item.month+'月' }}</Option>
 | 
					            {{ item.year + '年' + item.month + '月' }}</Option>
 | 
				
			||||||
        </Select>
 | 
					        </Select>
 | 
				
			||||||
      </div>
 | 
					      </div>
 | 
				
			||||||
      <div class="shop-list" v-if="!closeShop">
 | 
					      <div class="shop-list" v-if="!closeShop">
 | 
				
			||||||
        <Select clearable @on-change="changeshop(selectedWay)" v-model="storeId" placeholder="店铺查询"
 | 
					        <Select clearable @on-change="changeshop(selectedWay)" v-model="storeId" placeholder="店铺查询"
 | 
				
			||||||
          style="width:200px;margin-left:10px;">
 | 
					          style="width:200px;margin-left:10px;">
 | 
				
			||||||
          <Scroll :on-reach-bottom="handleReachBottom">
 | 
					          <Scroll :on-reach-bottom="handleReachBottom">
 | 
				
			||||||
            <Option v-for="(item,index) in shopsData" :value="item.id" :key="index">{{ item.storeName }}</Option>
 | 
					            <Option v-for="(item, index) in shopsData" :value="item.id" :key="index">{{ item.storeName }}</Option>
 | 
				
			||||||
          </Scroll>
 | 
					          </Scroll>
 | 
				
			||||||
        </Select>
 | 
					        </Select>
 | 
				
			||||||
      </div>
 | 
					      </div>
 | 
				
			||||||
@ -31,7 +31,7 @@ export default {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
      selectedWay: {
 | 
					      selectedWay: {
 | 
				
			||||||
        // 可选时间项
 | 
					        // 可选时间项
 | 
				
			||||||
        title: "最近7天",
 | 
					        title: "过去7天",
 | 
				
			||||||
        selected: true,
 | 
					        selected: true,
 | 
				
			||||||
        searchType: "LAST_SEVEN",
 | 
					        searchType: "LAST_SEVEN",
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
@ -56,12 +56,35 @@ export default {
 | 
				
			|||||||
          searchType: "YESTERDAY",
 | 
					          searchType: "YESTERDAY",
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
          title: "最近7天",
 | 
					          title: "过去7天",
 | 
				
			||||||
          selected: true,
 | 
					          selected: true,
 | 
				
			||||||
          searchType: "LAST_SEVEN",
 | 
					          searchType: "LAST_SEVEN",
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
          title: "最近30天",
 | 
					          title: "过去30天",
 | 
				
			||||||
 | 
					          selected: false,
 | 
				
			||||||
 | 
					          searchType: "LAST_THIRTY",
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					      ],
 | 
				
			||||||
 | 
					      originDateList: [
 | 
				
			||||||
 | 
					        // 筛选条件
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					          title: "今天",
 | 
				
			||||||
 | 
					          selected: false,
 | 
				
			||||||
 | 
					          searchType: "TODAY",
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					          title: "昨天",
 | 
				
			||||||
 | 
					          selected: false,
 | 
				
			||||||
 | 
					          searchType: "YESTERDAY",
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					          title: "过去7天",
 | 
				
			||||||
 | 
					          selected: true,
 | 
				
			||||||
 | 
					          searchType: "LAST_SEVEN",
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					          title: "过去30天",
 | 
				
			||||||
          selected: false,
 | 
					          selected: false,
 | 
				
			||||||
          searchType: "LAST_THIRTY",
 | 
					          searchType: "LAST_THIRTY",
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
@ -126,8 +149,8 @@ export default {
 | 
				
			|||||||
      this.dates = dates.reverse();
 | 
					      this.dates = dates.reverse();
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    // 改变已选店铺
 | 
					    // 改变已选店铺
 | 
				
			||||||
    changeSelect() {
 | 
					    changeSelect(e) {
 | 
				
			||||||
      console.log(this.month);
 | 
					      this.month = e
 | 
				
			||||||
      if (this.month) {
 | 
					      if (this.month) {
 | 
				
			||||||
        this.dateList.forEach((res) => {
 | 
					        this.dateList.forEach((res) => {
 | 
				
			||||||
          res.selected = false;
 | 
					          res.selected = false;
 | 
				
			||||||
@ -138,29 +161,36 @@ export default {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        this.$emit("selected", this.selectedWay);
 | 
					        this.$emit("selected", this.selectedWay);
 | 
				
			||||||
      } else {
 | 
					      } else {
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        const current = this.dateList.find(item => { return item.selected })
 | 
				
			||||||
 | 
					        this.selectedWay = current
 | 
				
			||||||
 | 
					        this.clickBreadcrumb(current)
 | 
				
			||||||
 | 
					        this.$emit("selected", this.selectedWay);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    // 变更时间
 | 
					    // 变更时间
 | 
				
			||||||
    clickBreadcrumb(item) {
 | 
					    clickBreadcrumb(item) {
 | 
				
			||||||
      this.dateList.forEach((res) => {
 | 
					
 | 
				
			||||||
 | 
					      let currentIndex;
 | 
				
			||||||
 | 
					      this.dateList.forEach((res,index) => {
 | 
				
			||||||
        res.selected = false;
 | 
					        res.selected = false;
 | 
				
			||||||
 | 
					        if(res.title === item.title){
 | 
				
			||||||
 | 
					          currentIndex = index
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
      });
 | 
					      });
 | 
				
			||||||
      item.selected = true;
 | 
					      item.selected = true;
 | 
				
			||||||
      item.storeId = this.storeId;
 | 
					      item.storeId = this.storeId;
 | 
				
			||||||
      this.month = "";
 | 
					      this.month = "";
 | 
				
			||||||
 | 
					 | 
				
			||||||
      if (item.searchType == "") {
 | 
					      if (item.searchType == "") {
 | 
				
			||||||
        if (
 | 
					       let currentDate = this.originDateList[currentIndex].searchType
 | 
				
			||||||
          dateList.some((date) => {
 | 
					        if (currentDate) {
 | 
				
			||||||
            return date.title == item.title;
 | 
					          item.searchType = currentDate
 | 
				
			||||||
          })
 | 
					 | 
				
			||||||
        ) {
 | 
					 | 
				
			||||||
          item.searchType = date.searchType;
 | 
					 | 
				
			||||||
        } else {
 | 
					        } else {
 | 
				
			||||||
          item.searchType = "LAST_SEVEN";
 | 
					          item.searchType = "LAST_SEVEN";
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
 | 
					 | 
				
			||||||
      this.selectedWay = item;
 | 
					      this.selectedWay = item;
 | 
				
			||||||
      this.selectedWay.year = new Date().getFullYear();
 | 
					      this.selectedWay.year = new Date().getFullYear();
 | 
				
			||||||
      this.selectedWay.month = "";
 | 
					      this.selectedWay.month = "";
 | 
				
			||||||
@ -174,17 +204,19 @@ export default {
 | 
				
			|||||||
.breadcrumb {
 | 
					.breadcrumb {
 | 
				
			||||||
  display: flex;
 | 
					  display: flex;
 | 
				
			||||||
  align-items: center;
 | 
					  align-items: center;
 | 
				
			||||||
  > span {
 | 
					  >span {
 | 
				
			||||||
    margin-right: 15px;
 | 
					    margin-right: 15px;
 | 
				
			||||||
    cursor: pointer;
 | 
					    cursor: pointer;
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
.active {
 | 
					.active {
 | 
				
			||||||
  color: $theme_color;
 | 
					  color: $theme_color;
 | 
				
			||||||
  position: relative;
 | 
					  position: relative;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
.date-picker {
 | 
					
 | 
				
			||||||
}
 | 
					.date-picker {}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
.active:before {
 | 
					.active:before {
 | 
				
			||||||
  content: "";
 | 
					  content: "";
 | 
				
			||||||
  position: absolute;
 | 
					  position: absolute;
 | 
				
			||||||
 | 
				
			|||||||
@ -5,6 +5,19 @@
 | 
				
			|||||||
        <div class="div-flow-left">
 | 
					        <div class="div-flow-left">
 | 
				
			||||||
          <div class="div-form-default">
 | 
					          <div class="div-form-default">
 | 
				
			||||||
            <h3>退货申请</h3>
 | 
					            <h3>退货申请</h3>
 | 
				
			||||||
 | 
					            <dl>
 | 
				
			||||||
 | 
					              <dt>退货商品</dt>
 | 
				
			||||||
 | 
					              <dd>
 | 
				
			||||||
 | 
					                <div>
 | 
				
			||||||
 | 
					                  <img :src="afterSaleInfo.goodsImage" style="height: 60px">
 | 
				
			||||||
 | 
					                </div>
 | 
				
			||||||
 | 
					                <a @click="linkTo(afterSaleInfo.goodsId, afterSaleInfo.skuId)">{{ afterSaleInfo.goodsName }}
 | 
				
			||||||
 | 
					                </a><br>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					                <span>{{ afterSaleInfo.num }}(数量)</span>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					              </dd>
 | 
				
			||||||
 | 
					            </dl>
 | 
				
			||||||
            <dl>
 | 
					            <dl>
 | 
				
			||||||
              <dt>退货状态</dt>
 | 
					              <dt>退货状态</dt>
 | 
				
			||||||
              <dd>{{ afterSaleInfo.serviceName }}</dd>
 | 
					              <dd>{{ afterSaleInfo.serviceName }}</dd>
 | 
				
			||||||
@ -155,43 +168,6 @@
 | 
				
			|||||||
        </div>
 | 
					        </div>
 | 
				
			||||||
        <div class="div-flow-center"></div>
 | 
					        <div class="div-flow-center"></div>
 | 
				
			||||||
        <div class="div-flow-right">
 | 
					        <div class="div-flow-right">
 | 
				
			||||||
          <div class="div-form-default">
 | 
					 | 
				
			||||||
            <h3>相关商品交易信息</h3>
 | 
					 | 
				
			||||||
            <dl>
 | 
					 | 
				
			||||||
              <dt>
 | 
					 | 
				
			||||||
                <img :src="afterSaleInfo.goodsImage" height="60px" />
 | 
					 | 
				
			||||||
              </dt>
 | 
					 | 
				
			||||||
              <dd>
 | 
					 | 
				
			||||||
                <div class="div-zoom">
 | 
					 | 
				
			||||||
                  <a @click="linkTo(afterSaleInfo.goodsId, afterSaleInfo.skuId)">{{
 | 
					 | 
				
			||||||
                    afterSaleInfo.goodsName
 | 
					 | 
				
			||||||
                  }}</a>
 | 
					 | 
				
			||||||
                  <Poptip trigger="hover" title="扫码在手机中查看" transfer>
 | 
					 | 
				
			||||||
                    <div slot="content">
 | 
					 | 
				
			||||||
                      <vue-qr
 | 
					 | 
				
			||||||
                        :text="wapLinkTo(afterSaleInfo.goodsId, afterSaleInfo.skuId)"
 | 
					 | 
				
			||||||
                        :margin="0"
 | 
					 | 
				
			||||||
                        colorDark="#000"
 | 
					 | 
				
			||||||
                        colorLight="#fff"
 | 
					 | 
				
			||||||
                        :size="150"
 | 
					 | 
				
			||||||
                      ></vue-qr>
 | 
					 | 
				
			||||||
                    </div>
 | 
					 | 
				
			||||||
                    <img
 | 
					 | 
				
			||||||
                      src="../../../assets/qrcode.svg"
 | 
					 | 
				
			||||||
                      style="vertical-align: middle"
 | 
					 | 
				
			||||||
                      class="hover-pointer ml_10"
 | 
					 | 
				
			||||||
                      width="20"
 | 
					 | 
				
			||||||
                      height="20"
 | 
					 | 
				
			||||||
                      alt=""
 | 
					 | 
				
			||||||
                    />
 | 
					 | 
				
			||||||
                  </Poptip>
 | 
					 | 
				
			||||||
                </div>
 | 
					 | 
				
			||||||
                <div style="color: #999; font-size: 10px">
 | 
					 | 
				
			||||||
                  数量:x{{ afterSaleInfo.num }}
 | 
					 | 
				
			||||||
                </div>
 | 
					 | 
				
			||||||
              </dd>
 | 
					 | 
				
			||||||
            </dl>
 | 
					 | 
				
			||||||
          </div>
 | 
					 | 
				
			||||||
          <div class="div-form-default">
 | 
					          <div class="div-form-default">
 | 
				
			||||||
            <h3>订单相关信息</h3>
 | 
					            <h3>订单相关信息</h3>
 | 
				
			||||||
            <dl>
 | 
					            <dl>
 | 
				
			||||||
 | 
				
			|||||||
@ -8,6 +8,13 @@
 | 
				
			|||||||
            <dl>
 | 
					            <dl>
 | 
				
			||||||
              <dt>投诉商品</dt>
 | 
					              <dt>投诉商品</dt>
 | 
				
			||||||
              <dd>{{complaintInfo.goodsName}}</dd>
 | 
					              <dd>{{complaintInfo.goodsName}}</dd>
 | 
				
			||||||
 | 
					              <dd>
 | 
				
			||||||
 | 
					                <div>
 | 
				
			||||||
 | 
					                  <img :src="complaintInfo.goodsImage" style="height: 60px">
 | 
				
			||||||
 | 
					                </div>
 | 
				
			||||||
 | 
					                <a>{{ complaintInfo.goodsName }}</a><br>
 | 
				
			||||||
 | 
					                <span>{{ complaintInfo.num }}(数量)</span>
 | 
				
			||||||
 | 
					              </dd>
 | 
				
			||||||
            </dl>
 | 
					            </dl>
 | 
				
			||||||
            <dl>
 | 
					            <dl>
 | 
				
			||||||
              <dt>投诉状态</dt>
 | 
					              <dt>投诉状态</dt>
 | 
				
			||||||
@ -144,19 +151,6 @@
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        </div>
 | 
					        </div>
 | 
				
			||||||
        <div class="div-flow-right">
 | 
					        <div class="div-flow-right">
 | 
				
			||||||
          <div class="div-form-default">
 | 
					 | 
				
			||||||
            <h3>相关商品交易信息</h3>
 | 
					 | 
				
			||||||
            <dl>
 | 
					 | 
				
			||||||
              <dt>
 | 
					 | 
				
			||||||
                <img :src="complaintInfo.goodsImage" height="60px">
 | 
					 | 
				
			||||||
              </dt>
 | 
					 | 
				
			||||||
              <dd>
 | 
					 | 
				
			||||||
                <a @click="linkTo(complaintInfo.goodsId, complaintInfo.skuId)">{{complaintInfo.goodsName}}</a><br>
 | 
					 | 
				
			||||||
                <span>¥{{complaintInfo.goodsPrice}} * {{complaintInfo.num}}(数量)</span>
 | 
					 | 
				
			||||||
              </dd>
 | 
					 | 
				
			||||||
            </dl>
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
          </div>
 | 
					 | 
				
			||||||
          <div class="div-form-default">
 | 
					          <div class="div-form-default">
 | 
				
			||||||
            <h3>订单相关信息</h3>
 | 
					            <h3>订单相关信息</h3>
 | 
				
			||||||
            <dl>
 | 
					            <dl>
 | 
				
			||||||
 | 
				
			|||||||
@ -66,6 +66,13 @@
 | 
				
			|||||||
                  >
 | 
					                  >
 | 
				
			||||||
                </div>
 | 
					                </div>
 | 
				
			||||||
              </div>
 | 
					              </div>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					              <div class="decorate-view">
 | 
				
			||||||
 | 
					                <div class="decorate-view-title">当前页面状态</div>
 | 
				
			||||||
 | 
					                <div>
 | 
				
			||||||
 | 
					                  <Tag :type="result.pageShow === 'OPEN'  ? 'green' : 'red'">{{result.pageShow === 'OPEN' ? '开启' : '关闭'}}</Tag>
 | 
				
			||||||
 | 
					                </div>
 | 
				
			||||||
 | 
					              </div>
 | 
				
			||||||
            </div>
 | 
					            </div>
 | 
				
			||||||
          </div>
 | 
					          </div>
 | 
				
			||||||
        </div>
 | 
					        </div>
 | 
				
			||||||
@ -87,6 +94,7 @@ export default {
 | 
				
			|||||||
  },
 | 
					  },
 | 
				
			||||||
  data() {
 | 
					  data() {
 | 
				
			||||||
    return {
 | 
					    return {
 | 
				
			||||||
 | 
					      result:"",
 | 
				
			||||||
      picModelFlag: false, //图片选择器
 | 
					      picModelFlag: false, //图片选择器
 | 
				
			||||||
      type: "full", // 是否全屏
 | 
					      type: "full", // 是否全屏
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -131,6 +139,7 @@ export default {
 | 
				
			|||||||
        res.result.pageData
 | 
					        res.result.pageData
 | 
				
			||||||
          ? this.$set(this, "advertising", [JSON.parse(res.result.pageData)])
 | 
					          ? this.$set(this, "advertising", [JSON.parse(res.result.pageData)])
 | 
				
			||||||
          : "";
 | 
					          : "";
 | 
				
			||||||
 | 
					        this.result = res.result
 | 
				
			||||||
      });
 | 
					      });
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    // 点击链接
 | 
					    // 点击链接
 | 
				
			||||||
 | 
				
			|||||||
@ -66,6 +66,13 @@
 | 
				
			|||||||
                  >
 | 
					                  >
 | 
				
			||||||
                </div>
 | 
					                </div>
 | 
				
			||||||
              </div>
 | 
					              </div>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					              <div class="decorate-view">
 | 
				
			||||||
 | 
					                <div class="decorate-view-title">当前页面状态</div>
 | 
				
			||||||
 | 
					                <div>
 | 
				
			||||||
 | 
					                  <Tag :type="result.pageShow === 'OPEN'  ? 'green' : 'red'">{{result.pageShow === 'OPEN' ? '开启' : '关闭'}}</Tag>
 | 
				
			||||||
 | 
					                </div>
 | 
				
			||||||
 | 
					              </div>
 | 
				
			||||||
            </div>
 | 
					            </div>
 | 
				
			||||||
          </div>
 | 
					          </div>
 | 
				
			||||||
        </div>
 | 
					        </div>
 | 
				
			||||||
@ -90,6 +97,7 @@ export default {
 | 
				
			|||||||
  },
 | 
					  },
 | 
				
			||||||
  data() {
 | 
					  data() {
 | 
				
			||||||
    return {
 | 
					    return {
 | 
				
			||||||
 | 
					      result:"",
 | 
				
			||||||
      picModelFlag: false, //图片选择器
 | 
					      picModelFlag: false, //图片选择器
 | 
				
			||||||
      type: "full", // 展示方式
 | 
					      type: "full", // 展示方式
 | 
				
			||||||
      //全屏广告
 | 
					      //全屏广告
 | 
				
			||||||
@ -140,6 +148,7 @@ export default {
 | 
				
			|||||||
        res.result.pageData
 | 
					        res.result.pageData
 | 
				
			||||||
          ? this.$set(this, "advertising", [JSON.parse(res.result.pageData)])
 | 
					          ? this.$set(this, "advertising", [JSON.parse(res.result.pageData)])
 | 
				
			||||||
          : "";
 | 
					          : "";
 | 
				
			||||||
 | 
					        this.result = res.result
 | 
				
			||||||
      });
 | 
					      });
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    // 图片选择器回显
 | 
					    // 图片选择器回显
 | 
				
			||||||
 | 
				
			|||||||
@ -172,18 +172,20 @@
 | 
				
			|||||||
        <div>
 | 
					        <div>
 | 
				
			||||||
          <Table stripe :columns="columns" :data="data"></Table>
 | 
					          <Table stripe :columns="columns" :data="data"></Table>
 | 
				
			||||||
        </div>
 | 
					        </div>
 | 
				
			||||||
 | 
					        <!-- (index) => {
 | 
				
			||||||
 | 
					              refundParams.pageNumber = index;
 | 
				
			||||||
 | 
					            } -->
 | 
				
			||||||
 | 
					        <!-- (size) => {
 | 
				
			||||||
 | 
					              (refundParams.pageSize = size), (refundParams.pageNumber = 1);
 | 
				
			||||||
 | 
					            } -->
 | 
				
			||||||
        <Page
 | 
					        <Page
 | 
				
			||||||
          v-if="showRecords"
 | 
					          v-if="showRecords"
 | 
				
			||||||
          size="small"
 | 
					          size="small"
 | 
				
			||||||
          @on-change="
 | 
					          @on-change="
 | 
				
			||||||
            (index) => {
 | 
					            pageNumberChange
 | 
				
			||||||
              refundParams.pageNumber = index;
 | 
					 | 
				
			||||||
            }
 | 
					 | 
				
			||||||
          "
 | 
					          "
 | 
				
			||||||
          @on-page-size-change="
 | 
					          @on-page-size-change="
 | 
				
			||||||
            (size) => {
 | 
					            pageSizeChange
 | 
				
			||||||
              (refundParams.pageSize = size), (refundParams.pageNumber = 1);
 | 
					 | 
				
			||||||
            }
 | 
					 | 
				
			||||||
          "
 | 
					          "
 | 
				
			||||||
          class="mt_10"
 | 
					          class="mt_10"
 | 
				
			||||||
          show-total
 | 
					          show-total
 | 
				
			||||||
@ -523,6 +525,14 @@ export default {
 | 
				
			|||||||
    },
 | 
					    },
 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  methods: {
 | 
					  methods: {
 | 
				
			||||||
 | 
					    pageNumberChange(val){
 | 
				
			||||||
 | 
					      this.refundParams.pageNumber = val
 | 
				
			||||||
 | 
					      this.getOrderList();
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    pageSizeChange(val){
 | 
				
			||||||
 | 
					      this.refundParams.pageSize = val
 | 
				
			||||||
 | 
					      this.getOrderList();
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
    // 订单图
 | 
					    // 订单图
 | 
				
			||||||
    initOrderChart() {
 | 
					    initOrderChart() {
 | 
				
			||||||
      // 默认已经加载 legend-filter 交互
 | 
					      // 默认已经加载 legend-filter 交互
 | 
				
			||||||
@ -563,11 +573,13 @@ export default {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
    clickBreadcrumb(item, index) {
 | 
					    clickBreadcrumb(item, index) {
 | 
				
			||||||
      let callback = JSON.parse(JSON.stringify(item));
 | 
					      let callback = JSON.parse(JSON.stringify(item));
 | 
				
			||||||
 | 
					      console.log("callback",callback)
 | 
				
			||||||
      this.orderParams = callback;
 | 
					      this.orderParams = callback;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      this.overViewParams = callback;
 | 
					      this.overViewParams = callback;
 | 
				
			||||||
      this.refundParams = callback;
 | 
					      this.refundParams = callback;
 | 
				
			||||||
 | 
					      this.refundParams.pageNumber = 1
 | 
				
			||||||
 | 
					      this.refundParams.pageSize = 10
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    // 实例化订单概览
 | 
					    // 实例化订单概览
 | 
				
			||||||
 | 
				
			|||||||
@ -1,44 +1,62 @@
 | 
				
			|||||||
<style lang="scss">
 | 
					<style lang="scss">
 | 
				
			||||||
@import "./ossManage.scss";
 | 
					@import "./ossManage.scss";
 | 
				
			||||||
 | 
					.group-row {
 | 
				
			||||||
 | 
					  padding-top: 10px;
 | 
				
			||||||
 | 
					  border-top: 1px solid #ededed;
 | 
				
			||||||
 | 
					  margin-top: 10px;
 | 
				
			||||||
 | 
					  display: flex;
 | 
				
			||||||
 | 
					  align-items: center;
 | 
				
			||||||
 | 
					  justify-content: center;
 | 
				
			||||||
 | 
					  > * {
 | 
				
			||||||
 | 
					    margin-right: 10px;
 | 
				
			||||||
 | 
					  }
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					.article-category {
 | 
				
			||||||
 | 
					  flex: 2;
 | 
				
			||||||
 | 
					  min-width: 200px;
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					.table {
 | 
				
			||||||
 | 
					  flex: 11;
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					.ivu-card {
 | 
				
			||||||
 | 
					  width: 100%;
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					.modal-footer {
 | 
				
			||||||
 | 
					  text-align: center;
 | 
				
			||||||
 | 
					  > * {
 | 
				
			||||||
 | 
					    margin: 0 10px;
 | 
				
			||||||
 | 
					  }
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
</style>
 | 
					</style>
 | 
				
			||||||
<template>
 | 
					<template>
 | 
				
			||||||
  <div class="search">
 | 
					  <div class="search">
 | 
				
			||||||
 | 
					    <Row>
 | 
				
			||||||
      <Card>
 | 
					      <Card>
 | 
				
			||||||
        <div class="operation">
 | 
					        <div class="operation">
 | 
				
			||||||
          <Row @keydown.enter.native="handleSearch">
 | 
					          <Row @keydown.enter.native="handleSearch">
 | 
				
			||||||
          <Form ref="searchForm" :model="searchForm" inline :label-width="85"    class="search-form"
 | 
					            <Form
 | 
				
			||||||
 | 
					              ref="searchForm"
 | 
				
			||||||
 | 
					              :label-width="85"
 | 
				
			||||||
 | 
					              :model="searchForm"
 | 
				
			||||||
 | 
					              class="search-form"
 | 
				
			||||||
 | 
					              inline
 | 
				
			||||||
            >
 | 
					            >
 | 
				
			||||||
            <Form-item label="原文件名" prop="name">
 | 
					 | 
				
			||||||
              <Input
 | 
					 | 
				
			||||||
                type="text"
 | 
					 | 
				
			||||||
                v-model="searchForm.name"
 | 
					 | 
				
			||||||
                placeholder="请输入原文件名"
 | 
					 | 
				
			||||||
                clearable
 | 
					 | 
				
			||||||
                style="width: 200px"
 | 
					 | 
				
			||||||
              />
 | 
					 | 
				
			||||||
            </Form-item>
 | 
					 | 
				
			||||||
            <Form-item label="存储文件名" prop="fileKey">
 | 
					 | 
				
			||||||
              <Input
 | 
					 | 
				
			||||||
                type="text"
 | 
					 | 
				
			||||||
                v-model="searchForm.fileKey"
 | 
					 | 
				
			||||||
                placeholder="请输入存储文件名"
 | 
					 | 
				
			||||||
                clearable
 | 
					 | 
				
			||||||
                style="width: 200px"
 | 
					 | 
				
			||||||
              />
 | 
					 | 
				
			||||||
            </Form-item>
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
              <Form-item label="上传时间">
 | 
					              <Form-item label="上传时间">
 | 
				
			||||||
                <DatePicker
 | 
					                <DatePicker
 | 
				
			||||||
                  v-model="selectDate"
 | 
					                  v-model="selectDate"
 | 
				
			||||||
                type="daterange"
 | 
					 | 
				
			||||||
                format="yyyy-MM-dd"
 | 
					 | 
				
			||||||
                  clearable
 | 
					                  clearable
 | 
				
			||||||
                @on-change="selectDateRange"
 | 
					                  format="yyyy-MM-dd"
 | 
				
			||||||
                  placeholder="选择起始时间"
 | 
					                  placeholder="选择起始时间"
 | 
				
			||||||
                  style="width: 200px"
 | 
					                  style="width: 200px"
 | 
				
			||||||
 | 
					                  type="daterange"
 | 
				
			||||||
 | 
					                  @on-change="selectDateRange"
 | 
				
			||||||
                ></DatePicker>
 | 
					                ></DatePicker>
 | 
				
			||||||
              </Form-item>
 | 
					              </Form-item>
 | 
				
			||||||
             <Button @click="handleSearch" type="primary" icon="ios-search" class="search-btn"
 | 
					              <Button
 | 
				
			||||||
 | 
					                class="search-btn"
 | 
				
			||||||
 | 
					                icon="ios-search"
 | 
				
			||||||
 | 
					                type="primary"
 | 
				
			||||||
 | 
					                @click="handleSearch"
 | 
				
			||||||
              >搜索
 | 
					              >搜索
 | 
				
			||||||
              </Button>
 | 
					              </Button>
 | 
				
			||||||
            </Form>
 | 
					            </Form>
 | 
				
			||||||
@ -46,90 +64,100 @@
 | 
				
			|||||||
          <div class="oss-operation padding-row">
 | 
					          <div class="oss-operation padding-row">
 | 
				
			||||||
            <div>
 | 
					            <div>
 | 
				
			||||||
              <Upload
 | 
					              <Upload
 | 
				
			||||||
              style="display:inline-block;"
 | 
					 | 
				
			||||||
              :action="commonUrl + '/common/common/upload/file'"
 | 
					 | 
				
			||||||
              :headers="accessToken"
 | 
					 | 
				
			||||||
              :on-success="handleSuccess"
 | 
					 | 
				
			||||||
              :on-error="handleError"
 | 
					 | 
				
			||||||
              :show-upload-list="false"
 | 
					 | 
				
			||||||
              :max-size="2048"
 | 
					 | 
				
			||||||
              :on-exceeded-size="handleMaxSize"
 | 
					 | 
				
			||||||
              multiple
 | 
					 | 
				
			||||||
                ref="up"
 | 
					                ref="up"
 | 
				
			||||||
 | 
					                :action="commonUrl + '/common/common/upload/file'"
 | 
				
			||||||
 | 
					                :data="{
 | 
				
			||||||
 | 
					                  directoryPath: searchForm.fileDirectoryId,
 | 
				
			||||||
 | 
					                }"
 | 
				
			||||||
 | 
					                :headers="accessToken"
 | 
				
			||||||
 | 
					                :max-size="20480"
 | 
				
			||||||
 | 
					                :on-error="handleError"
 | 
				
			||||||
 | 
					                :on-exceeded-size="handleMaxSize"
 | 
				
			||||||
 | 
					                :on-success="handleSuccess"
 | 
				
			||||||
 | 
					                :show-upload-list="false"
 | 
				
			||||||
 | 
					                multiple
 | 
				
			||||||
 | 
					                style="display: inline-block"
 | 
				
			||||||
              >
 | 
					              >
 | 
				
			||||||
              <Button type="primary">上传文件</Button>
 | 
					                <Button>上传图片</Button>
 | 
				
			||||||
              </Upload>
 | 
					              </Upload>
 | 
				
			||||||
            <Dropdown @on-click="handleDropdown">
 | 
					              <Dropdown @on-click="handleDropdown" v-if="!isComponent">
 | 
				
			||||||
                <Button>
 | 
					                <Button>
 | 
				
			||||||
                  更多操作
 | 
					                  更多操作
 | 
				
			||||||
                  <Icon type="md-arrow-dropdown"/>
 | 
					                  <Icon type="md-arrow-dropdown"/>
 | 
				
			||||||
                </Button>
 | 
					                </Button>
 | 
				
			||||||
                <DropdownMenu slot="list">
 | 
					                <DropdownMenu slot="list">
 | 
				
			||||||
                  <DropdownItem name="refresh">刷新</DropdownItem>
 | 
					                  <DropdownItem name="refresh">刷新</DropdownItem>
 | 
				
			||||||
                <DropdownItem v-show="showType == 'list'" name="removeAll">批量删除
 | 
					                  <DropdownItem v-show="showType == 'list'" name="removeAll"
 | 
				
			||||||
 | 
					                  >批量删除
 | 
				
			||||||
                  </DropdownItem>
 | 
					                  </DropdownItem>
 | 
				
			||||||
                </DropdownMenu>
 | 
					                </DropdownMenu>
 | 
				
			||||||
              </Dropdown>
 | 
					              </Dropdown>
 | 
				
			||||||
            </div>
 | 
					            </div>
 | 
				
			||||||
 | 
					 | 
				
			||||||
          <div>
 | 
					 | 
				
			||||||
            <RadioGroup
 | 
					 | 
				
			||||||
              v-model="fileType"
 | 
					 | 
				
			||||||
              @on-change="changeFileType"
 | 
					 | 
				
			||||||
              type="button" button-style="solid"
 | 
					 | 
				
			||||||
              style="margin-right: 25px"
 | 
					 | 
				
			||||||
            >
 | 
					 | 
				
			||||||
              <Radio label="all">所有类型</Radio>
 | 
					 | 
				
			||||||
              <Radio label="pic">图片</Radio>
 | 
					 | 
				
			||||||
              <Radio label="video">视频</Radio>
 | 
					 | 
				
			||||||
            </RadioGroup>
 | 
					 | 
				
			||||||
            <RadioGroup
 | 
					 | 
				
			||||||
              v-model="showType"
 | 
					 | 
				
			||||||
              type="button" button-style="solid"
 | 
					 | 
				
			||||||
              @on-change="changeShowType"
 | 
					 | 
				
			||||||
            >
 | 
					 | 
				
			||||||
              <Radio title="列表" label="list">
 | 
					 | 
				
			||||||
                <Icon type="md-list"></Icon>
 | 
					 | 
				
			||||||
              </Radio>
 | 
					 | 
				
			||||||
              <Radio title="缩略图" label="thumb">
 | 
					 | 
				
			||||||
                <Icon type="ios-apps"></Icon>
 | 
					 | 
				
			||||||
              </Radio>
 | 
					 | 
				
			||||||
            </RadioGroup>
 | 
					 | 
				
			||||||
          </div>
 | 
					 | 
				
			||||||
          </div>
 | 
					          </div>
 | 
				
			||||||
        </div>
 | 
					        </div>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      <div v-show="showType == 'list'">
 | 
					        <Alert show-icon v-if="!isComponent">
 | 
				
			||||||
        <Row >
 | 
					 | 
				
			||||||
          <Alert show-icon>
 | 
					 | 
				
			||||||
          已选择
 | 
					          已选择
 | 
				
			||||||
            <span >{{ selectCount }}</span> 项
 | 
					          <span>{{ selectCount }}</span> 项
 | 
				
			||||||
          <a class="select-clear" @click="clearSelectAll">清空</a>
 | 
					          <a class="select-clear" @click="clearSelectAll">清空</a>
 | 
				
			||||||
          <span v-if="selectCount > 0" style="margin-left: 15px"
 | 
					          <span v-if="selectCount > 0" style="margin-left: 15px"
 | 
				
			||||||
          >共计 {{ totalSize }} 存储量</span
 | 
					          >共计 {{ totalSize }} 存储量</span
 | 
				
			||||||
          >
 | 
					          >
 | 
				
			||||||
        </Alert>
 | 
					        </Alert>
 | 
				
			||||||
        </Row>
 | 
					
 | 
				
			||||||
 | 
					        <div v-show="showType === 'list'" >
 | 
				
			||||||
 | 
					          <div class="flex">
 | 
				
			||||||
 | 
					            <div class="article-category mr_10">
 | 
				
			||||||
 | 
					              <Tree
 | 
				
			||||||
 | 
					                :data="treeData"
 | 
				
			||||||
 | 
					                @on-contextmenu="handleContextMenu"
 | 
				
			||||||
 | 
					                @on-select-change="handleCateChange"
 | 
				
			||||||
 | 
					              >
 | 
				
			||||||
 | 
					                <template slot="contextMenu" v-if="!isComponent">
 | 
				
			||||||
 | 
					                  <DropdownItem @click.native="handleContextMenuEdit"
 | 
				
			||||||
 | 
					                  >编辑
 | 
				
			||||||
 | 
					                  </DropdownItem
 | 
				
			||||||
 | 
					                  >
 | 
				
			||||||
 | 
					                  <DropdownItem
 | 
				
			||||||
 | 
					                    style="color: #ed4014"
 | 
				
			||||||
 | 
					                    @click.native="handleContextMenuDelete"
 | 
				
			||||||
 | 
					                  >删除
 | 
				
			||||||
 | 
					                  </DropdownItem
 | 
				
			||||||
 | 
					                  >
 | 
				
			||||||
 | 
					                </template>
 | 
				
			||||||
 | 
					              </Tree>
 | 
				
			||||||
 | 
					              <Alert v-if="!isComponent">鼠标右键编辑/删除分组</Alert>
 | 
				
			||||||
 | 
					              <div class="group-row flex" v-if="!isComponent">
 | 
				
			||||||
 | 
					                <Button @click="handleClickAddGroup">添加分组</Button>
 | 
				
			||||||
 | 
					              </div>
 | 
				
			||||||
 | 
					            </div>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
            <Table
 | 
					            <Table
 | 
				
			||||||
 | 
					              ref="table"
 | 
				
			||||||
 | 
					              :columns="isComponent ? viewColumns : columns"
 | 
				
			||||||
 | 
					              :data="data"
 | 
				
			||||||
              :loading="loading"
 | 
					              :loading="loading"
 | 
				
			||||||
              border
 | 
					              border
 | 
				
			||||||
          :columns="columns"
 | 
					              class="table"
 | 
				
			||||||
          :data="data"
 | 
					 | 
				
			||||||
          ref="table"
 | 
					 | 
				
			||||||
              sortable="custom"
 | 
					              sortable="custom"
 | 
				
			||||||
              @on-sort-change="changeSort"
 | 
					              @on-sort-change="changeSort"
 | 
				
			||||||
              @on-selection-change="changeSelect"
 | 
					              @on-selection-change="changeSelect"
 | 
				
			||||||
        ></Table>
 | 
					            >
 | 
				
			||||||
 | 
					              <template slot="fileKey" slot-scope="{ row }">
 | 
				
			||||||
 | 
					                <a @click="copyFileUrl(row)">{{ row.fileKey }}</a>
 | 
				
			||||||
 | 
					              </template>
 | 
				
			||||||
 | 
					            </Table>
 | 
				
			||||||
          </div>
 | 
					          </div>
 | 
				
			||||||
      <div v-show="showType == 'thumb'">
 | 
					        </div>
 | 
				
			||||||
 | 
					        <div v-show="showType === 'thumb'">
 | 
				
			||||||
          <div class="oss-wrapper">
 | 
					          <div class="oss-wrapper">
 | 
				
			||||||
            <Card v-for="(item, i) in data" :key="i" class="oss-card">
 | 
					            <Card v-for="(item, i) in data" :key="i" class="oss-card">
 | 
				
			||||||
              <div class="content">
 | 
					              <div class="content">
 | 
				
			||||||
                <img
 | 
					                <img
 | 
				
			||||||
                @click="showPic(item)"
 | 
					 | 
				
			||||||
                  v-if="item.fileType.indexOf('image') >= 0"
 | 
					                  v-if="item.fileType.indexOf('image') >= 0"
 | 
				
			||||||
                class="img"
 | 
					 | 
				
			||||||
                  :src="item.url"
 | 
					                  :src="item.url"
 | 
				
			||||||
 | 
					                  class="img"
 | 
				
			||||||
 | 
					                  @click="showPic(item)"
 | 
				
			||||||
                />
 | 
					                />
 | 
				
			||||||
                <div
 | 
					                <div
 | 
				
			||||||
                  v-else-if="item.fileType.indexOf('video') >= 0"
 | 
					                  v-else-if="item.fileType.indexOf('video') >= 0"
 | 
				
			||||||
@ -137,7 +165,7 @@
 | 
				
			|||||||
                  @click="showVideo(item)"
 | 
					                  @click="showVideo(item)"
 | 
				
			||||||
                >
 | 
					                >
 | 
				
			||||||
                  <!-- 文件小于5MB显示video -->
 | 
					                  <!-- 文件小于5MB显示video -->
 | 
				
			||||||
                <video class="cover" v-if="item.fileSize < 1024 * 1024 * 5">
 | 
					                  <video v-if="item.fileSize < 1024 * 1024 * 5" class="cover">
 | 
				
			||||||
                    <source :src="item.url"/>
 | 
					                    <source :src="item.url"/>
 | 
				
			||||||
                  </video>
 | 
					                  </video>
 | 
				
			||||||
                  <img class="play" src="@/assets/play.png"/>
 | 
					                  <img class="play" src="@/assets/play.png"/>
 | 
				
			||||||
@ -155,17 +183,21 @@
 | 
				
			|||||||
                <div class="actions">
 | 
					                <div class="actions">
 | 
				
			||||||
                  <div class="btn">
 | 
					                  <div class="btn">
 | 
				
			||||||
                    <Tooltip content="下载" placement="top">
 | 
					                    <Tooltip content="下载" placement="top">
 | 
				
			||||||
                    <Icon @click="download(item)" type="md-download" size="16"/>
 | 
					                      <Icon
 | 
				
			||||||
 | 
					                        size="16"
 | 
				
			||||||
 | 
					                        type="md-download"
 | 
				
			||||||
 | 
					                        @click="download(item)"
 | 
				
			||||||
 | 
					                      />
 | 
				
			||||||
                    </Tooltip>
 | 
					                    </Tooltip>
 | 
				
			||||||
                  </div>
 | 
					                  </div>
 | 
				
			||||||
                  <div class="btn">
 | 
					                  <div class="btn">
 | 
				
			||||||
                    <Tooltip content="重命名" placement="top">
 | 
					                    <Tooltip content="重命名" placement="top">
 | 
				
			||||||
                    <Icon @click="rename(item)" type="md-create" size="16"/>
 | 
					                      <Icon size="16" type="md-create" @click="rename(item)"/>
 | 
				
			||||||
                    </Tooltip>
 | 
					                    </Tooltip>
 | 
				
			||||||
                  </div>
 | 
					                  </div>
 | 
				
			||||||
                  <div class="btn-no">
 | 
					                  <div class="btn-no">
 | 
				
			||||||
                    <Tooltip content="删除" placement="top">
 | 
					                    <Tooltip content="删除" placement="top">
 | 
				
			||||||
                    <Icon @click="remove(item)" type="md-trash" size="16"/>
 | 
					                      <Icon size="16" type="md-trash" @click="remove(item)"/>
 | 
				
			||||||
                    </Tooltip>
 | 
					                    </Tooltip>
 | 
				
			||||||
                  </div>
 | 
					                  </div>
 | 
				
			||||||
                </div>
 | 
					                </div>
 | 
				
			||||||
@ -173,31 +205,29 @@
 | 
				
			|||||||
            </Card>
 | 
					            </Card>
 | 
				
			||||||
          </div>
 | 
					          </div>
 | 
				
			||||||
        </div>
 | 
					        </div>
 | 
				
			||||||
      <Row type="flex" justify="end" class="mt_10">
 | 
					        <Row class="mt_10" justify="end" type="flex">
 | 
				
			||||||
          <Page
 | 
					          <Page
 | 
				
			||||||
            :current="searchForm.pageNumber"
 | 
					            :current="searchForm.pageNumber"
 | 
				
			||||||
          :total="total"
 | 
					 | 
				
			||||||
            :page-size="searchForm.pageSize"
 | 
					            :page-size="searchForm.pageSize"
 | 
				
			||||||
          @on-change="changePage"
 | 
					 | 
				
			||||||
          @on-page-size-change="changePageSize"
 | 
					 | 
				
			||||||
            :page-size-opts="pageSizeOpts"
 | 
					            :page-size-opts="pageSizeOpts"
 | 
				
			||||||
          size="small"
 | 
					            :total="total"
 | 
				
			||||||
          show-total
 | 
					 | 
				
			||||||
            show-elevator
 | 
					            show-elevator
 | 
				
			||||||
            show-sizer
 | 
					            show-sizer
 | 
				
			||||||
 | 
					            show-total
 | 
				
			||||||
 | 
					            size="small"
 | 
				
			||||||
 | 
					            @on-change="changePage"
 | 
				
			||||||
 | 
					            @on-page-size-change="changePageSize"
 | 
				
			||||||
          ></Page>
 | 
					          ></Page>
 | 
				
			||||||
        </Row>
 | 
					        </Row>
 | 
				
			||||||
      </Card>
 | 
					      </Card>
 | 
				
			||||||
 | 
					    </Row>
 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    <Modal
 | 
					    <Modal
 | 
				
			||||||
      :title="modalTitle"
 | 
					 | 
				
			||||||
      v-model="modalVisible"
 | 
					      v-model="modalVisible"
 | 
				
			||||||
      :mask-closable="false"
 | 
					      :mask-closable="false"
 | 
				
			||||||
 | 
					      :title="modalTitle"
 | 
				
			||||||
      :width="500"
 | 
					      :width="500"
 | 
				
			||||||
    >
 | 
					    >
 | 
				
			||||||
      <Form ref="form" :model="form" :label-width="95" :rules="formValidate">
 | 
					      <Form ref="form" :label-width="95" :model="form" :rules="formValidate">
 | 
				
			||||||
        <FormItem label="原文件名" prop="name">
 | 
					        <FormItem label="原文件名" prop="name">
 | 
				
			||||||
          <Input v-model="form.name"/>
 | 
					          <Input v-model="form.name"/>
 | 
				
			||||||
        </FormItem>
 | 
					        </FormItem>
 | 
				
			||||||
@ -207,10 +237,9 @@
 | 
				
			|||||||
      </Form>
 | 
					      </Form>
 | 
				
			||||||
      <div slot="footer">
 | 
					      <div slot="footer">
 | 
				
			||||||
        <Button type="text" @click="handleCancel">取消</Button>
 | 
					        <Button type="text" @click="handleCancel">取消</Button>
 | 
				
			||||||
        <Button type="primary" :loading="submitLoading" @click="handleSubmit"
 | 
					        <Button :loading="submitLoading" type="primary" @click="handleSubmit"
 | 
				
			||||||
        >提交
 | 
					        >提交
 | 
				
			||||||
        </Button
 | 
					        </Button>
 | 
				
			||||||
        >
 | 
					 | 
				
			||||||
      </div>
 | 
					      </div>
 | 
				
			||||||
    </Modal>
 | 
					    </Modal>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -233,8 +262,8 @@
 | 
				
			|||||||
      v-model="videoVisible"
 | 
					      v-model="videoVisible"
 | 
				
			||||||
      :title="videoTitle"
 | 
					      :title="videoTitle"
 | 
				
			||||||
      :width="800"
 | 
					      :width="800"
 | 
				
			||||||
      @on-cancel="closeVideo"
 | 
					 | 
				
			||||||
      draggable
 | 
					      draggable
 | 
				
			||||||
 | 
					      @on-cancel="closeVideo"
 | 
				
			||||||
    >
 | 
					    >
 | 
				
			||||||
      <div id="dplayer"></div>
 | 
					      <div id="dplayer"></div>
 | 
				
			||||||
      <div slot="footer">
 | 
					      <div slot="footer">
 | 
				
			||||||
@ -245,32 +274,96 @@
 | 
				
			|||||||
        >
 | 
					        >
 | 
				
			||||||
      </div>
 | 
					      </div>
 | 
				
			||||||
    </Modal>
 | 
					    </Modal>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    <!-- 添加分组修改分组编辑框 -->
 | 
				
			||||||
 | 
					    <Modal
 | 
				
			||||||
 | 
					      v-model="enableGroup"
 | 
				
			||||||
 | 
					      :title="insertOrUpdate === 'insert' ? '添加分组' : '修改分组'"
 | 
				
			||||||
 | 
					      :loading="groupLoading"
 | 
				
			||||||
 | 
					      @on-ok="submitAddGroup"
 | 
				
			||||||
 | 
					      footer-hide
 | 
				
			||||||
 | 
					    >
 | 
				
			||||||
 | 
					      <Form
 | 
				
			||||||
 | 
					        ref="formValidate"
 | 
				
			||||||
 | 
					        :label-width="80"
 | 
				
			||||||
 | 
					        :model="groupFormValidate"
 | 
				
			||||||
 | 
					        :rules="groupRuleValidate"
 | 
				
			||||||
 | 
					      >
 | 
				
			||||||
 | 
					        <FormItem label="所在分组" prop="id">
 | 
				
			||||||
 | 
					          <Cascader
 | 
				
			||||||
 | 
					            v-model="groupFormValidate.id"
 | 
				
			||||||
 | 
					            :data="treeData"
 | 
				
			||||||
 | 
					            change-on-select
 | 
				
			||||||
 | 
					          ></Cascader>
 | 
				
			||||||
 | 
					        </FormItem>
 | 
				
			||||||
 | 
					        <FormItem label="分组名称" prop="directoryName">
 | 
				
			||||||
 | 
					          <Input v-model="groupFormValidate.directoryName"/>
 | 
				
			||||||
 | 
					        </FormItem>
 | 
				
			||||||
 | 
					      </Form>
 | 
				
			||||||
 | 
					      <div class="modal-footer">
 | 
				
			||||||
 | 
					        <Button @click="enableGroup = false">取消</Button>
 | 
				
			||||||
 | 
					        <Button type="primary" @click="submitAddGroup">确定</Button>
 | 
				
			||||||
 | 
					      </div>
 | 
				
			||||||
 | 
					    </Modal>
 | 
				
			||||||
  </div>
 | 
					  </div>
 | 
				
			||||||
</template>
 | 
					</template>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
<script>
 | 
					<script>
 | 
				
			||||||
import {
 | 
					import {
 | 
				
			||||||
 | 
					  addFileDirectory,
 | 
				
			||||||
 | 
					  deleteFile,
 | 
				
			||||||
 | 
					  delFileDirectory,
 | 
				
			||||||
 | 
					  getFileDirectory,
 | 
				
			||||||
  getFileListData,
 | 
					  getFileListData,
 | 
				
			||||||
  renameFile,
 | 
					  renameFile,
 | 
				
			||||||
  deleteFile,
 | 
					  updateFileDirectory,
 | 
				
			||||||
} from "@/api/index";
 | 
					} from "@/api/index";
 | 
				
			||||||
import DPlayer from "dplayer";
 | 
					import DPlayer from "dplayer";
 | 
				
			||||||
 | 
					 | 
				
			||||||
const config = require('@/config/index')
 | 
					 | 
				
			||||||
import { commonUrl } from "@/libs/axios";
 | 
					import { commonUrl } from "@/libs/axios";
 | 
				
			||||||
var dp;
 | 
					
 | 
				
			||||||
 | 
					const config = require("@/config/index");
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					let dp;
 | 
				
			||||||
export default {
 | 
					export default {
 | 
				
			||||||
  name: "oss-manage",
 | 
					  name: "oss-manage",
 | 
				
			||||||
  props:{
 | 
					  props: {
 | 
				
			||||||
    isComponent:{
 | 
					    isComponent: {
 | 
				
			||||||
      default: false,
 | 
					      default: false,
 | 
				
			||||||
      type:Boolean
 | 
					      type: Boolean,
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    choose: {
 | 
				
			||||||
 | 
					      type: String,
 | 
				
			||||||
 | 
					      default: ""
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  data() {
 | 
					  data() {
 | 
				
			||||||
    return {
 | 
					    return {
 | 
				
			||||||
      commonUrl, // 上传文件路径
 | 
					      commonUrl, // 上传文件路径
 | 
				
			||||||
      config, // api地址
 | 
					      config, // api地址
 | 
				
			||||||
 | 
					      fileDirectoryId: "",
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      groupFormValidate: {
 | 
				
			||||||
 | 
					        id: [],
 | 
				
			||||||
 | 
					        directoryName: "",
 | 
				
			||||||
 | 
					      },
 | 
				
			||||||
 | 
					      groupRuleValidate: {
 | 
				
			||||||
 | 
					        directoryName: [
 | 
				
			||||||
 | 
					          {
 | 
				
			||||||
 | 
					            required: true,
 | 
				
			||||||
 | 
					            message: "请输入分组名称",
 | 
				
			||||||
 | 
					            trigger: "blur",
 | 
				
			||||||
 | 
					          },
 | 
				
			||||||
 | 
					        ],
 | 
				
			||||||
 | 
					        id: [
 | 
				
			||||||
 | 
					          {
 | 
				
			||||||
 | 
					            required: true,
 | 
				
			||||||
 | 
					            message: "请选择分组",
 | 
				
			||||||
 | 
					            trigger: "blur",
 | 
				
			||||||
 | 
					            type: "array",
 | 
				
			||||||
 | 
					          },
 | 
				
			||||||
 | 
					        ],
 | 
				
			||||||
 | 
					      },
 | 
				
			||||||
 | 
					      enableGroup: false, // 是否展示分组
 | 
				
			||||||
      selectImage: false, //是否是选择
 | 
					      selectImage: false, //是否是选择
 | 
				
			||||||
      accessToken: {}, // 上传token鉴权
 | 
					      accessToken: {}, // 上传token鉴权
 | 
				
			||||||
      loading: false, // 表单加载状态
 | 
					      loading: false, // 表单加载状态
 | 
				
			||||||
@ -297,7 +390,8 @@ export default {
 | 
				
			|||||||
      },
 | 
					      },
 | 
				
			||||||
      selectDate: null, // 选择日期绑定modal
 | 
					      selectDate: null, // 选择日期绑定modal
 | 
				
			||||||
      oldKey: "", // 请求参数
 | 
					      oldKey: "", // 请求参数
 | 
				
			||||||
      form: { // 表单
 | 
					      form: {
 | 
				
			||||||
 | 
					        // 表单
 | 
				
			||||||
        name: "",
 | 
					        name: "",
 | 
				
			||||||
        fileKey: "",
 | 
					        fileKey: "",
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
@ -318,32 +412,16 @@ export default {
 | 
				
			|||||||
          width: 60,
 | 
					          width: 60,
 | 
				
			||||||
          align: "center",
 | 
					          align: "center",
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        {
 | 
					 | 
				
			||||||
          title: "原文件名",
 | 
					 | 
				
			||||||
          key: "name",
 | 
					 | 
				
			||||||
          minWidth: 130,
 | 
					 | 
				
			||||||
          sortable: true,
 | 
					 | 
				
			||||||
          ellipsis: false,
 | 
					 | 
				
			||||||
          tooltip: true,
 | 
					 | 
				
			||||||
        },
 | 
					 | 
				
			||||||
        {
 | 
					 | 
				
			||||||
          title: "存储文件名",
 | 
					 | 
				
			||||||
          key: "fileKey",
 | 
					 | 
				
			||||||
          width: 165,
 | 
					 | 
				
			||||||
          sortable: true,
 | 
					 | 
				
			||||||
          ellipsis: false,
 | 
					 | 
				
			||||||
          tooltip: true,
 | 
					 | 
				
			||||||
        },
 | 
					 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
          title: "缩略图(点击预览)",
 | 
					          title: "缩略图(点击预览)",
 | 
				
			||||||
          key: "url",
 | 
					          key: "url",
 | 
				
			||||||
          width: 150,
 | 
					          width: 300,
 | 
				
			||||||
          align: "center",
 | 
					          align: "center",
 | 
				
			||||||
          render: (h, params) => {
 | 
					          render: (h, params) => {
 | 
				
			||||||
            if (params.row.fileType.includes("image") > 0) {
 | 
					            if (params.row.fileType.includes("image") > 0) {
 | 
				
			||||||
              return h("img", {
 | 
					              return h("img", {
 | 
				
			||||||
                attrs: {
 | 
					                attrs: {
 | 
				
			||||||
                  src: params.row.url || '',
 | 
					                  src: params.row.url || "",
 | 
				
			||||||
                  alt: "加载图片失败",
 | 
					                  alt: "加载图片失败",
 | 
				
			||||||
                },
 | 
					                },
 | 
				
			||||||
                style: {
 | 
					                style: {
 | 
				
			||||||
@ -414,7 +492,6 @@ export default {
 | 
				
			|||||||
          title: "文件类型",
 | 
					          title: "文件类型",
 | 
				
			||||||
          key: "fileType",
 | 
					          key: "fileType",
 | 
				
			||||||
          width: 115,
 | 
					          width: 115,
 | 
				
			||||||
          sortable: true,
 | 
					 | 
				
			||||||
          className: this.selectImage == true ? "none" : "",
 | 
					          className: this.selectImage == true ? "none" : "",
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
@ -432,46 +509,39 @@ export default {
 | 
				
			|||||||
        {
 | 
					        {
 | 
				
			||||||
          title: "上传者",
 | 
					          title: "上传者",
 | 
				
			||||||
          key: "createBy",
 | 
					          key: "createBy",
 | 
				
			||||||
          width: 120,
 | 
					          width: 200,
 | 
				
			||||||
          sortable: true,
 | 
					 | 
				
			||||||
          render: (h, params) => {
 | 
					          render: (h, params) => {
 | 
				
			||||||
            let m = "";
 | 
					            let m = "";
 | 
				
			||||||
            if(params.row.userEnums=="MANAGER"){
 | 
					            if (params.row.userEnums == "MANAGER") {
 | 
				
			||||||
            m="[管理员]"
 | 
					              m = "[管理员]";
 | 
				
			||||||
            }else if(params.row.userEnums=="STORE"){
 | 
					            } else if (params.row.userEnums == "STORE") {
 | 
				
			||||||
              m="[店铺]"
 | 
					              m = "[店铺]";
 | 
				
			||||||
            }else{
 | 
					            } else {
 | 
				
			||||||
              m="[会员]"
 | 
					              m = "[会员]";
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
            m += params.row.createBy
 | 
					            m += params.row.createBy;
 | 
				
			||||||
            return h("span", m);
 | 
					            return h("span", m);
 | 
				
			||||||
          },
 | 
					          },
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        {
 | 
					 | 
				
			||||||
          title: "上传时间",
 | 
					 | 
				
			||||||
          key: "createTime",
 | 
					 | 
				
			||||||
          width: 180,
 | 
					 | 
				
			||||||
          sortable: true,
 | 
					 | 
				
			||||||
          sortType: "desc",
 | 
					 | 
				
			||||||
        },
 | 
					 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
          title: "操作",
 | 
					          title: "操作",
 | 
				
			||||||
          key: "action",
 | 
					          key: "action",
 | 
				
			||||||
          align: "center",
 | 
					          align: "center",
 | 
				
			||||||
          fixed: "right",
 | 
					          fixed: "right",
 | 
				
			||||||
          width: 200,
 | 
					          // width: 300,
 | 
				
			||||||
          render: (h, params) => {
 | 
					          render: (h, params) => {
 | 
				
			||||||
            return h("div", [
 | 
					            return h("div", [
 | 
				
			||||||
              h(
 | 
					              h(
 | 
				
			||||||
                "Button",
 | 
					                "Button",
 | 
				
			||||||
                {
 | 
					                {
 | 
				
			||||||
                  props: {
 | 
					                  props: {
 | 
				
			||||||
                    type: "primary",
 | 
					                    type: "default",
 | 
				
			||||||
                    size: "small",
 | 
					                    size: "small",
 | 
				
			||||||
                  },
 | 
					                  },
 | 
				
			||||||
                  style: {
 | 
					                  style: {
 | 
				
			||||||
                    marginRight: "5px",
 | 
					                    marginRight: "5px",
 | 
				
			||||||
                    display: this.selectImage == true ? "inline-block" : "none",
 | 
					                    display:
 | 
				
			||||||
 | 
					                      this.selectImage === true ? "inline-block" : "none",
 | 
				
			||||||
                  },
 | 
					                  },
 | 
				
			||||||
                  on: {
 | 
					                  on: {
 | 
				
			||||||
                    click: () => {
 | 
					                    click: () => {
 | 
				
			||||||
@ -500,25 +570,6 @@ export default {
 | 
				
			|||||||
                },
 | 
					                },
 | 
				
			||||||
                "下载"
 | 
					                "下载"
 | 
				
			||||||
              ),
 | 
					              ),
 | 
				
			||||||
              h(
 | 
					 | 
				
			||||||
                "Button",
 | 
					 | 
				
			||||||
                {
 | 
					 | 
				
			||||||
                  props: {
 | 
					 | 
				
			||||||
                    size: "small",
 | 
					 | 
				
			||||||
                    type: 'success'
 | 
					 | 
				
			||||||
                  },
 | 
					 | 
				
			||||||
                  style: {
 | 
					 | 
				
			||||||
                    marginRight: "5px",
 | 
					 | 
				
			||||||
                    display: this.selectImage == true ? "none" : "inline-block",
 | 
					 | 
				
			||||||
                  },
 | 
					 | 
				
			||||||
                  on: {
 | 
					 | 
				
			||||||
                    click: () => {
 | 
					 | 
				
			||||||
                      this.rename(params.row);
 | 
					 | 
				
			||||||
                    },
 | 
					 | 
				
			||||||
                  },
 | 
					 | 
				
			||||||
                },
 | 
					 | 
				
			||||||
                "重命名"
 | 
					 | 
				
			||||||
              ),
 | 
					 | 
				
			||||||
              h(
 | 
					              h(
 | 
				
			||||||
                "Button",
 | 
					                "Button",
 | 
				
			||||||
                {
 | 
					                {
 | 
				
			||||||
@ -541,17 +592,301 @@ export default {
 | 
				
			|||||||
          },
 | 
					          },
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
      ],
 | 
					      ],
 | 
				
			||||||
 | 
					      viewColumns: [
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					          title: "缩略图(点击预览)",
 | 
				
			||||||
 | 
					          key: "url",
 | 
				
			||||||
 | 
					          // width: 150,
 | 
				
			||||||
 | 
					          align: "center",
 | 
				
			||||||
 | 
					          render: (h, params) => {
 | 
				
			||||||
 | 
					            if (params.row.fileType.includes("image") > 0) {
 | 
				
			||||||
 | 
					              return h("img", {
 | 
				
			||||||
 | 
					                attrs: {
 | 
				
			||||||
 | 
					                  src: params.row.url || "",
 | 
				
			||||||
 | 
					                  alt: "加载图片失败",
 | 
				
			||||||
 | 
					                },
 | 
				
			||||||
 | 
					                style: {
 | 
				
			||||||
 | 
					                  cursor: "pointer",
 | 
				
			||||||
 | 
					                  width: "80px",
 | 
				
			||||||
 | 
					                  height: "60px",
 | 
				
			||||||
 | 
					                  margin: "10px 0",
 | 
				
			||||||
 | 
					                  "object-fit": "contain",
 | 
				
			||||||
 | 
					                },
 | 
				
			||||||
 | 
					                on: {
 | 
				
			||||||
 | 
					                  click: () => {
 | 
				
			||||||
 | 
					                    this.showPic(params.row);
 | 
				
			||||||
 | 
					                  },
 | 
				
			||||||
 | 
					                },
 | 
				
			||||||
 | 
					              });
 | 
				
			||||||
 | 
					            } else if (params.row.fileType.includes("video") > 0) {
 | 
				
			||||||
 | 
					              // 如果视频文件大小超过5MB不予加载video
 | 
				
			||||||
 | 
					              if (params.row.fileSize < 1024 * 1024 * 5) {
 | 
				
			||||||
 | 
					                return h(
 | 
				
			||||||
 | 
					                  "video",
 | 
				
			||||||
 | 
					                  {
 | 
				
			||||||
 | 
					                    style: {
 | 
				
			||||||
 | 
					                      cursor: "pointer",
 | 
				
			||||||
 | 
					                      width: "80px",
 | 
				
			||||||
 | 
					                      height: "60px",
 | 
				
			||||||
 | 
					                      margin: "10px 0",
 | 
				
			||||||
 | 
					                      "object-fit": "contain",
 | 
				
			||||||
 | 
					                    },
 | 
				
			||||||
 | 
					                    on: {
 | 
				
			||||||
 | 
					                      click: () => {
 | 
				
			||||||
 | 
					                        this.showVideo(params.row);
 | 
				
			||||||
 | 
					                      },
 | 
				
			||||||
 | 
					                    },
 | 
				
			||||||
 | 
					                  },
 | 
				
			||||||
 | 
					                  [
 | 
				
			||||||
 | 
					                    h("source", {
 | 
				
			||||||
 | 
					                      attrs: {
 | 
				
			||||||
 | 
					                        src: params.row.url,
 | 
				
			||||||
 | 
					                      },
 | 
				
			||||||
 | 
					                    }),
 | 
				
			||||||
 | 
					                  ]
 | 
				
			||||||
 | 
					                );
 | 
				
			||||||
 | 
					              } else {
 | 
				
			||||||
 | 
					                return h("img", {
 | 
				
			||||||
 | 
					                  attrs: {
 | 
				
			||||||
 | 
					                    src: require("@/assets/play.png"),
 | 
				
			||||||
 | 
					                  },
 | 
				
			||||||
 | 
					                  style: {
 | 
				
			||||||
 | 
					                    cursor: "pointer",
 | 
				
			||||||
 | 
					                    width: "80px",
 | 
				
			||||||
 | 
					                    height: "60px",
 | 
				
			||||||
 | 
					                    margin: "10px 0",
 | 
				
			||||||
 | 
					                    "object-fit": "contain",
 | 
				
			||||||
 | 
					                  },
 | 
				
			||||||
 | 
					                  on: {
 | 
				
			||||||
 | 
					                    click: () => {
 | 
				
			||||||
 | 
					                      this.showVideo(params.row);
 | 
				
			||||||
 | 
					                    },
 | 
				
			||||||
 | 
					                  },
 | 
				
			||||||
 | 
					                });
 | 
				
			||||||
 | 
					              }
 | 
				
			||||||
 | 
					            } else {
 | 
				
			||||||
 | 
					              return h("span", "非多媒体类型");
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					          },
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					          title: "上传者",
 | 
				
			||||||
 | 
					          key: "createBy",
 | 
				
			||||||
 | 
					          width: 120,
 | 
				
			||||||
 | 
					          sortable: true,
 | 
				
			||||||
 | 
					          render: (h, params) => {
 | 
				
			||||||
 | 
					            let m = "";
 | 
				
			||||||
 | 
					            if (params.row.userEnums == "MANAGER") {
 | 
				
			||||||
 | 
					              m = "[管理员]";
 | 
				
			||||||
 | 
					            } else if (params.row.userEnums == "STORE") {
 | 
				
			||||||
 | 
					              m = "[店铺]";
 | 
				
			||||||
 | 
					            } else {
 | 
				
			||||||
 | 
					              m = "[会员]";
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					            m += params.row.createBy;
 | 
				
			||||||
 | 
					            return h("span", m);
 | 
				
			||||||
 | 
					          },
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					          title: "操作",
 | 
				
			||||||
 | 
					          key: "action",
 | 
				
			||||||
 | 
					          align: "center",
 | 
				
			||||||
 | 
					          fixed: "right",
 | 
				
			||||||
 | 
					          width: 300,
 | 
				
			||||||
 | 
					          render: (h, params) => {
 | 
				
			||||||
 | 
					            return h("div", [
 | 
				
			||||||
 | 
					              h(
 | 
				
			||||||
 | 
					                "Button",
 | 
				
			||||||
 | 
					                {
 | 
				
			||||||
 | 
					                  props: {
 | 
				
			||||||
 | 
					                    type: "default",
 | 
				
			||||||
 | 
					                    size: "small",
 | 
				
			||||||
 | 
					                  },
 | 
				
			||||||
 | 
					                  style: {
 | 
				
			||||||
 | 
					                    marginRight: "5px",
 | 
				
			||||||
 | 
					                    display:
 | 
				
			||||||
 | 
					                      this.selectImage === true ? "inline-block" : "none",
 | 
				
			||||||
 | 
					                  },
 | 
				
			||||||
 | 
					                  on: {
 | 
				
			||||||
 | 
					                    click: () => {
 | 
				
			||||||
 | 
					                      this.selectedParams(params.row);
 | 
				
			||||||
 | 
					                    },
 | 
				
			||||||
 | 
					                  },
 | 
				
			||||||
 | 
					                },
 | 
				
			||||||
 | 
					                "选择"
 | 
				
			||||||
 | 
					              )
 | 
				
			||||||
 | 
					            ]);
 | 
				
			||||||
 | 
					          },
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					      ],
 | 
				
			||||||
      data: [], // 表单数据
 | 
					      data: [], // 表单数据
 | 
				
			||||||
      total: 0, // 表单数据总数
 | 
					      total: 0, // 表单数据总数
 | 
				
			||||||
      pageSizeOpts: [5, 10, 20], // 页码展示项
 | 
					      pageSizeOpts: [5, 10, 20], // 页码展示项
 | 
				
			||||||
 | 
					      list: [], // 列表
 | 
				
			||||||
 | 
					      //树结构
 | 
				
			||||||
 | 
					      treeData: [],
 | 
				
			||||||
 | 
					      treeDataDefault: [],
 | 
				
			||||||
 | 
					      selectedGroupData: "",
 | 
				
			||||||
 | 
					      insertOrUpdate: "insert",
 | 
				
			||||||
 | 
					      groupLoading: false,
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  watch:{
 | 
					  watch: {
 | 
				
			||||||
    selectImage(val) {
 | 
					    selectImage(val) {
 | 
				
			||||||
      if (val && !this.data.length) this.init()
 | 
					      if (val && !this.data.length) this.init();
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    choose(val) {
 | 
				
			||||||
 | 
					      if (val) this.selectImage = val
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  methods: {
 | 
					  methods: {
 | 
				
			||||||
 | 
					    handleContextMenu(val) {
 | 
				
			||||||
 | 
					      console.log("val", val);
 | 
				
			||||||
 | 
					      this.selectedGroupData = val;
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    // 编辑分组
 | 
				
			||||||
 | 
					    handleContextMenuEdit(val) {
 | 
				
			||||||
 | 
					      this.insertOrUpdate = "update";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      this.enableGroup = true;
 | 
				
			||||||
 | 
					      // this.groupFormValidate = this.selectedGroupData;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      this.groupFormValidate.directoryName = this.selectedGroupData.title;
 | 
				
			||||||
 | 
					      this.groupFormValidate.id = [this.selectedGroupData.value];
 | 
				
			||||||
 | 
					      this.groupFormValidate.level = this.selectedGroupData.level;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      this.groupFormValidate.parentId = this.selectedGroupData.parentId;
 | 
				
			||||||
 | 
					      console.log(this.groupFormValidate);
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    // 删除分组
 | 
				
			||||||
 | 
					    async handleContextMenuDelete(val) {
 | 
				
			||||||
 | 
					      this.$Modal.confirm({
 | 
				
			||||||
 | 
					        title: "提示",
 | 
				
			||||||
 | 
					        content: "是否删除该分组",
 | 
				
			||||||
 | 
					        onOk: async () => {
 | 
				
			||||||
 | 
					          const res = await delFileDirectory(this.selectedGroupData.value);
 | 
				
			||||||
 | 
					          if (res.success) {
 | 
				
			||||||
 | 
					            this.$Message.success("删除成功!");
 | 
				
			||||||
 | 
					            this.getAllList();
 | 
				
			||||||
 | 
					          }
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					      });
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    // 保存/修改分组
 | 
				
			||||||
 | 
					    async submitAddGroup() {
 | 
				
			||||||
 | 
					      this.$refs["formValidate"].validate(async (valid) => {
 | 
				
			||||||
 | 
					        if (valid) {
 | 
				
			||||||
 | 
					          let res
 | 
				
			||||||
 | 
					          const params = { ...this.groupFormValidate };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					          if (this.insertOrUpdate === "insert") {
 | 
				
			||||||
 | 
					            // params.directoryType = this.selectedGroupData.directoryType
 | 
				
			||||||
 | 
					            params.parentId = params.id[params.id.length - 1];
 | 
				
			||||||
 | 
					            // params.type = this.selectedGroupData.type
 | 
				
			||||||
 | 
					            params.level =
 | 
				
			||||||
 | 
					              params.parentId == "0" ? 0 : this.selectedGroupData.level + 1;
 | 
				
			||||||
 | 
					            delete params.id;
 | 
				
			||||||
 | 
					            res = await addFileDirectory(params);
 | 
				
			||||||
 | 
					          } else {
 | 
				
			||||||
 | 
					            params.id = params.id[params.id.length - 1];
 | 
				
			||||||
 | 
					            res = await updateFileDirectory(params);
 | 
				
			||||||
 | 
					          }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					          if (res.success) {
 | 
				
			||||||
 | 
					            this.$Message.success("操作成功!");
 | 
				
			||||||
 | 
					            this.enableGroup = false;
 | 
				
			||||||
 | 
					            this.getAllList();
 | 
				
			||||||
 | 
					          }
 | 
				
			||||||
 | 
					          this.$Modal.remove();
 | 
				
			||||||
 | 
					        } else {
 | 
				
			||||||
 | 
					          this.$Message.error("请填写完整信息!");
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					      });
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    // 添加/修改分组
 | 
				
			||||||
 | 
					    handleClickAddGroup() {
 | 
				
			||||||
 | 
					      this.insertOrUpdate = "insert";
 | 
				
			||||||
 | 
					      if (this.selectedGroupData) {
 | 
				
			||||||
 | 
					        this.groupFormValidate.id = [this.selectedGroupData.value];
 | 
				
			||||||
 | 
					      } else {
 | 
				
			||||||
 | 
					        this.groupFormValidate.id = ["0"];
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
 | 
					      this.enableGroup = true;
 | 
				
			||||||
 | 
					      this.groupFormValidate.directoryName = "";
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    copyFileUrl(row) {
 | 
				
			||||||
 | 
					      const textArea = document.createElement("textarea");
 | 
				
			||||||
 | 
					      textArea.value = row.url;
 | 
				
			||||||
 | 
					      document.body.appendChild(textArea);
 | 
				
			||||||
 | 
					      textArea.focus();
 | 
				
			||||||
 | 
					      textArea.select();
 | 
				
			||||||
 | 
					      try {
 | 
				
			||||||
 | 
					        document.execCommand("copy");
 | 
				
			||||||
 | 
					        this.$Message.success("复制成功");
 | 
				
			||||||
 | 
					      } catch (err) {
 | 
				
			||||||
 | 
					        console.error("Unable to copy to clipboard", err);
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
 | 
					      document.body.removeChild(textArea);
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    // 获取全部文件目录
 | 
				
			||||||
 | 
					    getAllList(parent_id) {
 | 
				
			||||||
 | 
					      this.loading = true;
 | 
				
			||||||
 | 
					      getFileDirectory(parent_id).then((res) => {
 | 
				
			||||||
 | 
					        this.loading = false;
 | 
				
			||||||
 | 
					        if (res.success) {
 | 
				
			||||||
 | 
					          this.treeData = this.getTree(res.result);
 | 
				
			||||||
 | 
					          this.treeDataDefault = this.getTree(res.result);
 | 
				
			||||||
 | 
					          this.treeData.unshift({
 | 
				
			||||||
 | 
					            title: "全部图片",
 | 
				
			||||||
 | 
					            label: "全部分类",
 | 
				
			||||||
 | 
					            value: "0",
 | 
				
			||||||
 | 
					            level: 0,
 | 
				
			||||||
 | 
					            children: [],
 | 
				
			||||||
 | 
					            id: "0",
 | 
				
			||||||
 | 
					            categoryId: 0,
 | 
				
			||||||
 | 
					          });
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					      });
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    // 文件目录分类格式化方法
 | 
				
			||||||
 | 
					    getTree(tree = []) {
 | 
				
			||||||
 | 
					      let arr = [];
 | 
				
			||||||
 | 
					      if (!!tree && tree.length !== 0) {
 | 
				
			||||||
 | 
					        tree.forEach((item) => {
 | 
				
			||||||
 | 
					          let obj = {};
 | 
				
			||||||
 | 
					          obj.title = item.directoryName;
 | 
				
			||||||
 | 
					          obj.value = item.id; // 拥有者id
 | 
				
			||||||
 | 
					          obj.type = item.directoryType; // 用户类型
 | 
				
			||||||
 | 
					          obj.label = item.directoryName;
 | 
				
			||||||
 | 
					          obj.level = item.level;
 | 
				
			||||||
 | 
					          obj.expand = false;
 | 
				
			||||||
 | 
					          obj.selected = false;
 | 
				
			||||||
 | 
					          obj.contextmenu = true;
 | 
				
			||||||
 | 
					          obj.parentId = item.parentId;
 | 
				
			||||||
 | 
					          obj.children = this.getTree(item.children); // 递归调用
 | 
				
			||||||
 | 
					          arr.push(obj);
 | 
				
			||||||
 | 
					        });
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
 | 
					      return arr;
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    // 选择分类回调
 | 
				
			||||||
 | 
					    handleCateChange(data) {
 | 
				
			||||||
 | 
					      this.selectedGroupData = data[0];
 | 
				
			||||||
 | 
					      let {value, type} = data[0];
 | 
				
			||||||
 | 
					      this.list.push({
 | 
				
			||||||
 | 
					        value,
 | 
				
			||||||
 | 
					        type,
 | 
				
			||||||
 | 
					      });
 | 
				
			||||||
 | 
					      this.searchForm.fileDirectoryId = value;
 | 
				
			||||||
 | 
					      if (value === "0") {
 | 
				
			||||||
 | 
					        delete this.searchForm.fileDirectoryId;
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
 | 
					      this.searchForm.userEnums = type;
 | 
				
			||||||
 | 
					      this.getDataList();
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
    /**
 | 
					    /**
 | 
				
			||||||
     * 选择
 | 
					     * 选择
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@ -560,9 +895,9 @@ export default {
 | 
				
			|||||||
    },
 | 
					    },
 | 
				
			||||||
    // 更多操作
 | 
					    // 更多操作
 | 
				
			||||||
    handleDropdown(name) {
 | 
					    handleDropdown(name) {
 | 
				
			||||||
      if (name == "refresh") {
 | 
					      if (name === "refresh") {
 | 
				
			||||||
        this.getDataList();
 | 
					        this.getDataList();
 | 
				
			||||||
      } else if (name == "removeAll") {
 | 
					      } else if (name === "removeAll") {
 | 
				
			||||||
        this.removeAll();
 | 
					        this.removeAll();
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
@ -572,6 +907,7 @@ export default {
 | 
				
			|||||||
        accessToken: this.getStore("accessToken"),
 | 
					        accessToken: this.getStore("accessToken"),
 | 
				
			||||||
      };
 | 
					      };
 | 
				
			||||||
      this.getDataList();
 | 
					      this.getDataList();
 | 
				
			||||||
 | 
					      this.getAllList();
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    // 查看大图
 | 
					    // 查看大图
 | 
				
			||||||
    showPic(v) {
 | 
					    showPic(v) {
 | 
				
			||||||
@ -725,13 +1061,16 @@ export default {
 | 
				
			|||||||
            ids += e.id + ",";
 | 
					            ids += e.id + ",";
 | 
				
			||||||
          });
 | 
					          });
 | 
				
			||||||
          ids = ids.substring(0, ids.length - 1);
 | 
					          ids = ids.substring(0, ids.length - 1);
 | 
				
			||||||
          deleteFile(ids).then((res) => {
 | 
					          deleteFile({ids: ids}).then((res) => {
 | 
				
			||||||
            this.$Modal.remove();
 | 
					            this.$Modal.remove();
 | 
				
			||||||
            if (res.success) {
 | 
					            if (res.success) {
 | 
				
			||||||
              this.$Message.success("批量删除文件成功");
 | 
					              this.$Message.success("批量删除文件成功");
 | 
				
			||||||
              this.clearSelectAll();
 | 
					              this.clearSelectAll();
 | 
				
			||||||
              this.getDataList();
 | 
					              this.getDataList();
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
 | 
					          })
 | 
				
			||||||
 | 
					            .catch((err) => {
 | 
				
			||||||
 | 
					              console.log("失败", err);
 | 
				
			||||||
            });
 | 
					            });
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
      });
 | 
					      });
 | 
				
			||||||
@ -743,13 +1082,13 @@ export default {
 | 
				
			|||||||
        content: "您确认要删除文件 " + v.name + " ?",
 | 
					        content: "您确认要删除文件 " + v.name + " ?",
 | 
				
			||||||
        loading: true,
 | 
					        loading: true,
 | 
				
			||||||
        onOk: () => {
 | 
					        onOk: () => {
 | 
				
			||||||
          deleteFile(v.id).then((res) => {
 | 
					          deleteFile({ids: v.id}).then((res) => {
 | 
				
			||||||
            this.$Modal.remove();
 | 
					            this.$Modal.remove();
 | 
				
			||||||
            if (res.success) {
 | 
					            if (res.success) {
 | 
				
			||||||
              this.$Message.success("删除文件 " + v.name + " 成功");
 | 
					              this.$Message.success("删除文件 " + v.name + " 成功");
 | 
				
			||||||
              this.getDataList();
 | 
					              this.getDataList();
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
          });
 | 
					          })
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
      });
 | 
					      });
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
@ -792,6 +1131,7 @@ export default {
 | 
				
			|||||||
    },
 | 
					    },
 | 
				
			||||||
    // 清除选中状态
 | 
					    // 清除选中状态
 | 
				
			||||||
    clearSelectAll() {
 | 
					    clearSelectAll() {
 | 
				
			||||||
 | 
					      console.log("清除选中状态");
 | 
				
			||||||
      this.$refs.table.selectAll(false);
 | 
					      this.$refs.table.selectAll(false);
 | 
				
			||||||
      this.totalSize = "";
 | 
					      this.totalSize = "";
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
@ -807,10 +1147,10 @@ export default {
 | 
				
			|||||||
    },
 | 
					    },
 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  mounted() {
 | 
					  mounted() {
 | 
				
			||||||
    if(!this.isComponent) { // 是组件的话,初始化不调用接口
 | 
					    if (!this.isComponent) {
 | 
				
			||||||
 | 
					      // 是组件的话,初始化不调用接口
 | 
				
			||||||
      this.init();
 | 
					      this.init();
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
 | 
					 | 
				
			||||||
};
 | 
					};
 | 
				
			||||||
</script>
 | 
					</script>
 | 
				
			||||||
 | 
				
			|||||||
@ -1,45 +1,42 @@
 | 
				
			|||||||
<template>
 | 
					<template>
 | 
				
			||||||
  <div>
 | 
					  <div>
 | 
				
			||||||
    <div class="breadcrumb">
 | 
					    <div class="breadcrumb">
 | 
				
			||||||
      <span @click="clickBreadcrumb(item,index)" :class="{'active':item.selected}" v-for="(item,index) in dateList" :key="index"> {{item.title}}</span>
 | 
					      <span @click="clickBreadcrumb(item, index)" :class="{ 'active': item.selected }" v-for="(item, index) in dateList"
 | 
				
			||||||
 | 
					        :key="index"> {{ item.title }}</span>
 | 
				
			||||||
      <div class="date-picker">
 | 
					      <div class="date-picker">
 | 
				
			||||||
        <Select @on-change="changeSelect(selectedWay)" v-model="month" placeholder="年月查询" style="width:200px;margin-left:10px;">
 | 
					        <Select @on-change="changeSelect($event, selectedWay)" :value="month" placeholder="年月查询"
 | 
				
			||||||
          <Option v-for="(item,index) in dates" :value="item.year+'-'+item.month" :key="index">{{ item.year+'年'+item.month+'月' }}</Option>
 | 
					          style="width:200px;margin-left:10px;">
 | 
				
			||||||
 | 
					          <Option v-for="(item, index) in dates" :value="item.year + '-' + item.month" :key="index">{{
 | 
				
			||||||
 | 
					            item.year + '年' + item.month + '月' }}</Option>
 | 
				
			||||||
        </Select>
 | 
					        </Select>
 | 
				
			||||||
      </div>
 | 
					      </div>
 | 
				
			||||||
 | 
					 | 
				
			||||||
    </div>
 | 
					    </div>
 | 
				
			||||||
  </div>
 | 
					  </div>
 | 
				
			||||||
</template>
 | 
					</template>
 | 
				
			||||||
<script>
 | 
					<script>
 | 
				
			||||||
import Cookies from "js-cookie";
 | 
					import { getShopListData } from "@/api/shops.js";
 | 
				
			||||||
export default {
 | 
					export default {
 | 
				
			||||||
  props: ["closeShop"],
 | 
					  props: ["closeShop"],
 | 
				
			||||||
  data() {
 | 
					  data() {
 | 
				
			||||||
    return {
 | 
					    return {
 | 
				
			||||||
      month: "", // 所选月份
 | 
					      month: "", // 月份
 | 
				
			||||||
 | 
					 | 
				
			||||||
      defuaultWay: {
 | 
					 | 
				
			||||||
        title: "最近7天",
 | 
					 | 
				
			||||||
        selected: true,
 | 
					 | 
				
			||||||
        searchType: "LAST_SEVEN",
 | 
					 | 
				
			||||||
      },
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
      selectedWay: {
 | 
					      selectedWay: {
 | 
				
			||||||
        title: "最近7天",
 | 
					        // 可选时间项
 | 
				
			||||||
 | 
					        title: "过去7天",
 | 
				
			||||||
        selected: true,
 | 
					        selected: true,
 | 
				
			||||||
        searchType: "LAST_SEVEN",
 | 
					        searchType: "LAST_SEVEN",
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      storeId: "", // 店铺id
 | 
					      storeId: "", // 店铺id
 | 
				
			||||||
      dates: [], // 日期列表
 | 
					      dates: [], // 日期列表
 | 
				
			||||||
      params: { // 请求参数
 | 
					      params: {
 | 
				
			||||||
 | 
					        // 请求参数
 | 
				
			||||||
        pageNumber: 1,
 | 
					        pageNumber: 1,
 | 
				
			||||||
        pageSize: 10,
 | 
					        pageSize: 10,
 | 
				
			||||||
        storeName: "",
 | 
					        storeName: "",
 | 
				
			||||||
        storeId: "",
 | 
					 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
 | 
					 | 
				
			||||||
      dateList: [
 | 
					      dateList: [
 | 
				
			||||||
 | 
					        // 筛选条件
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
          title: "今天",
 | 
					          title: "今天",
 | 
				
			||||||
          selected: false,
 | 
					          selected: false,
 | 
				
			||||||
@ -51,23 +48,77 @@ export default {
 | 
				
			|||||||
          searchType: "YESTERDAY",
 | 
					          searchType: "YESTERDAY",
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
          title: "最近7天",
 | 
					          title: "过去7天",
 | 
				
			||||||
          selected: true,
 | 
					          selected: true,
 | 
				
			||||||
          searchType: "LAST_SEVEN",
 | 
					          searchType: "LAST_SEVEN",
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
          title: "最近30天",
 | 
					          title: "过去30天",
 | 
				
			||||||
          selected: false,
 | 
					          selected: false,
 | 
				
			||||||
          searchType: "LAST_THIRTY",
 | 
					          searchType: "LAST_THIRTY",
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
      ],
 | 
					      ],
 | 
				
			||||||
 | 
					      originDateList: [
 | 
				
			||||||
 | 
					        // 筛选条件
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					          title: "今天",
 | 
				
			||||||
 | 
					          selected: false,
 | 
				
			||||||
 | 
					          searchType: "TODAY",
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					          title: "昨天",
 | 
				
			||||||
 | 
					          selected: false,
 | 
				
			||||||
 | 
					          searchType: "YESTERDAY",
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					          title: "过去7天",
 | 
				
			||||||
 | 
					          selected: true,
 | 
				
			||||||
 | 
					          searchType: "LAST_SEVEN",
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					          title: "过去30天",
 | 
				
			||||||
 | 
					          selected: false,
 | 
				
			||||||
 | 
					          searchType: "LAST_THIRTY",
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					      ],
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      shopTotal: "", // 店铺总数
 | 
				
			||||||
 | 
					      shopsData: [], // 店铺数据
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  mounted() {
 | 
					  mounted() {
 | 
				
			||||||
   this.storeId = JSON.parse(Cookies.get("userInfoSeller")).id;
 | 
					 | 
				
			||||||
    this.getFiveYears();
 | 
					    this.getFiveYears();
 | 
				
			||||||
 | 
					    this.getShopList();
 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  methods: {
 | 
					  methods: {
 | 
				
			||||||
 | 
					    // 页面触底
 | 
				
			||||||
 | 
					    handleReachBottom() {
 | 
				
			||||||
 | 
					      setTimeout(() => {
 | 
				
			||||||
 | 
					        if (this.params.pageNumber * this.params.pageSize <= this.shopTotal) {
 | 
				
			||||||
 | 
					          this.params.pageNumber++;
 | 
				
			||||||
 | 
					          this.getShopList();
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					      }, 1500);
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    // 查询店铺列表
 | 
				
			||||||
 | 
					    getShopList() {
 | 
				
			||||||
 | 
					      getShopListData(this.params).then((res) => {
 | 
				
			||||||
 | 
					        if (res.success) {
 | 
				
			||||||
 | 
					          /**
 | 
				
			||||||
 | 
					           * 解决数据请求中,滚动栏会一直上下跳动
 | 
				
			||||||
 | 
					           */
 | 
				
			||||||
 | 
					          this.shopTotal = res.result.total;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					          this.shopsData.push(...res.result.records);
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					      });
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    // 变更店铺
 | 
				
			||||||
 | 
					    changeshop(val) {
 | 
				
			||||||
 | 
					      this.selectedWay.storeId = this.storeId;
 | 
				
			||||||
 | 
					      this.$emit("selected", this.selectedWay);
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    // 获取近5年 年月
 | 
					    // 获取近5年 年月
 | 
				
			||||||
    getFiveYears() {
 | 
					    getFiveYears() {
 | 
				
			||||||
      let getYear = new Date().getFullYear();
 | 
					      let getYear = new Date().getFullYear();
 | 
				
			||||||
@ -89,8 +140,9 @@ export default {
 | 
				
			|||||||
      }
 | 
					      }
 | 
				
			||||||
      this.dates = dates.reverse();
 | 
					      this.dates = dates.reverse();
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    // 选择回调
 | 
					    // 改变已选店铺
 | 
				
			||||||
    changeSelect() {
 | 
					    changeSelect(e) {
 | 
				
			||||||
 | 
					      this.month = e
 | 
				
			||||||
      if (this.month) {
 | 
					      if (this.month) {
 | 
				
			||||||
        this.dateList.forEach((res) => {
 | 
					        this.dateList.forEach((res) => {
 | 
				
			||||||
          res.selected = false;
 | 
					          res.selected = false;
 | 
				
			||||||
@ -101,29 +153,36 @@ export default {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        this.$emit("selected", this.selectedWay);
 | 
					        this.$emit("selected", this.selectedWay);
 | 
				
			||||||
      } else {
 | 
					      } else {
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        const current = this.dateList.find(item => { return item.selected })
 | 
				
			||||||
 | 
					        this.selectedWay = current
 | 
				
			||||||
 | 
					        this.clickBreadcrumb(current)
 | 
				
			||||||
 | 
					        this.$emit("selected", this.selectedWay);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    // 点击时间筛选
 | 
					    // 变更时间
 | 
				
			||||||
    clickBreadcrumb(item) {
 | 
					    clickBreadcrumb(item) {
 | 
				
			||||||
      this.dateList.forEach((res) => {
 | 
					
 | 
				
			||||||
 | 
					      let currentIndex;
 | 
				
			||||||
 | 
					      this.dateList.forEach((res,index) => {
 | 
				
			||||||
        res.selected = false;
 | 
					        res.selected = false;
 | 
				
			||||||
 | 
					        if(res.title === item.title){
 | 
				
			||||||
 | 
					          currentIndex = index
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
      });
 | 
					      });
 | 
				
			||||||
      item.selected = true;
 | 
					      item.selected = true;
 | 
				
			||||||
      item.storeId = this.storeId;
 | 
					      item.storeId = this.storeId;
 | 
				
			||||||
      this.month = "";
 | 
					      this.month = "";
 | 
				
			||||||
 | 
					 | 
				
			||||||
      if (item.searchType == "") {
 | 
					      if (item.searchType == "") {
 | 
				
			||||||
        if (
 | 
					       let currentDate = this.originDateList[currentIndex].searchType
 | 
				
			||||||
          dateList.some((date) => {
 | 
					        if (currentDate) {
 | 
				
			||||||
            return date.title == item.title;
 | 
					          item.searchType = currentDate
 | 
				
			||||||
          })
 | 
					 | 
				
			||||||
        ) {
 | 
					 | 
				
			||||||
          item.searchType = date.searchType;
 | 
					 | 
				
			||||||
        } else {
 | 
					        } else {
 | 
				
			||||||
          item.searchType = "LAST_SEVEN";
 | 
					          item.searchType = "LAST_SEVEN";
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
 | 
					 | 
				
			||||||
      this.selectedWay = item;
 | 
					      this.selectedWay = item;
 | 
				
			||||||
      this.selectedWay.year = new Date().getFullYear();
 | 
					      this.selectedWay.year = new Date().getFullYear();
 | 
				
			||||||
      this.selectedWay.month = "";
 | 
					      this.selectedWay.month = "";
 | 
				
			||||||
@ -137,17 +196,20 @@ export default {
 | 
				
			|||||||
.breadcrumb {
 | 
					.breadcrumb {
 | 
				
			||||||
  display: flex;
 | 
					  display: flex;
 | 
				
			||||||
  align-items: center;
 | 
					  align-items: center;
 | 
				
			||||||
  > span {
 | 
					
 | 
				
			||||||
 | 
					  >span {
 | 
				
			||||||
    margin-right: 15px;
 | 
					    margin-right: 15px;
 | 
				
			||||||
    cursor: pointer;
 | 
					    cursor: pointer;
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
.active {
 | 
					.active {
 | 
				
			||||||
  color: $theme_color;
 | 
					  color: $theme_color;
 | 
				
			||||||
  position: relative;
 | 
					  position: relative;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
.date-picker {
 | 
					
 | 
				
			||||||
}
 | 
					.date-picker {}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
.active:before {
 | 
					.active:before {
 | 
				
			||||||
  content: "";
 | 
					  content: "";
 | 
				
			||||||
  position: absolute;
 | 
					  position: absolute;
 | 
				
			||||||
 | 
				
			|||||||
@ -7,7 +7,13 @@
 | 
				
			|||||||
            <h3>投诉信息</h3>
 | 
					            <h3>投诉信息</h3>
 | 
				
			||||||
            <dl>
 | 
					            <dl>
 | 
				
			||||||
              <dt>投诉商品</dt>
 | 
					              <dt>投诉商品</dt>
 | 
				
			||||||
              <dd>{{ complaintInfo.goodsName }}</dd>
 | 
					              <dd>
 | 
				
			||||||
 | 
					                <div>
 | 
				
			||||||
 | 
					                  <img :src="complaintInfo.goodsImage" style="height: 60px">
 | 
				
			||||||
 | 
					                </div>
 | 
				
			||||||
 | 
					                <a>{{ complaintInfo.goodsName }}</a><br>
 | 
				
			||||||
 | 
					                <span>¥{{ complaintInfo.goodsPrice | unitPrice }} * {{ complaintInfo.num }}(数量)</span>
 | 
				
			||||||
 | 
					              </dd>
 | 
				
			||||||
            </dl>
 | 
					            </dl>
 | 
				
			||||||
            <dl>
 | 
					            <dl>
 | 
				
			||||||
              <dt>投诉状态</dt>
 | 
					              <dt>投诉状态</dt>
 | 
				
			||||||
@ -160,19 +166,6 @@
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
        </div>
 | 
					        </div>
 | 
				
			||||||
        <div class="div-flow-right">
 | 
					        <div class="div-flow-right">
 | 
				
			||||||
          <div class="div-form-default">
 | 
					 | 
				
			||||||
            <h3>相关商品交易信息</h3>
 | 
					 | 
				
			||||||
            <dl>
 | 
					 | 
				
			||||||
              <dt>
 | 
					 | 
				
			||||||
                <img :src="complaintInfo.goodsImage" height="60px">
 | 
					 | 
				
			||||||
              </dt>
 | 
					 | 
				
			||||||
              <dd>
 | 
					 | 
				
			||||||
                <a>{{ complaintInfo.goodsName }}</a><br>
 | 
					 | 
				
			||||||
                <span>¥{{ complaintInfo.goodsPrice | unitPrice }} * {{ complaintInfo.num }}(数量)</span>
 | 
					 | 
				
			||||||
              </dd>
 | 
					 | 
				
			||||||
            </dl>
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
          </div>
 | 
					 | 
				
			||||||
          <div class="div-form-default">
 | 
					          <div class="div-form-default">
 | 
				
			||||||
            <h3>订单相关信息</h3>
 | 
					            <h3>订单相关信息</h3>
 | 
				
			||||||
            <dl>
 | 
					            <dl>
 | 
				
			||||||
 | 
				
			|||||||
@ -8,8 +8,15 @@
 | 
				
			|||||||
            <div class="div-form-default">
 | 
					            <div class="div-form-default">
 | 
				
			||||||
              <h3>售后申请</h3>
 | 
					              <h3>售后申请</h3>
 | 
				
			||||||
              <dl>
 | 
					              <dl>
 | 
				
			||||||
                <dt>售后状态</dt>
 | 
					                <dt>售后商品</dt>
 | 
				
			||||||
                <dd>{{filterStatus(afterSaleInfo.serviceStatus)}}</dd>
 | 
					                <dd>
 | 
				
			||||||
 | 
					                  <div>
 | 
				
			||||||
 | 
					                    <img :src="afterSaleInfo.goodsImage" style="height: 60px">
 | 
				
			||||||
 | 
					                  </div>
 | 
				
			||||||
 | 
					                  <a>{{ afterSaleInfo.goodsName }}</a><br>
 | 
				
			||||||
 | 
					                  <span>{{ afterSaleInfo.num }}(数量)</span>
 | 
				
			||||||
 | 
					                </dd>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
              </dl>
 | 
					              </dl>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
              <dl>
 | 
					              <dl>
 | 
				
			||||||
@ -155,20 +162,6 @@
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
          </div>
 | 
					          </div>
 | 
				
			||||||
          <div class="div-flow-right">
 | 
					          <div class="div-flow-right">
 | 
				
			||||||
            <div class="div-form-default">
 | 
					 | 
				
			||||||
              <h3>相关商品交易信息</h3>
 | 
					 | 
				
			||||||
              <dl>
 | 
					 | 
				
			||||||
                <dt>
 | 
					 | 
				
			||||||
                  <img :src="afterSaleInfo.goodsImage" height="60px">
 | 
					 | 
				
			||||||
                </dt>
 | 
					 | 
				
			||||||
                <dd>
 | 
					 | 
				
			||||||
                  <a>{{ afterSaleInfo.goodsName }}</a><br>
 | 
					 | 
				
			||||||
                  <span>{{ afterSaleInfo.num }}(数量)</span><br>
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
                </dd>
 | 
					 | 
				
			||||||
              </dl>
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
            </div>
 | 
					 | 
				
			||||||
            <div class="div-form-default">
 | 
					            <div class="div-form-default">
 | 
				
			||||||
              <h3>订单相关信息</h3>
 | 
					              <h3>订单相关信息</h3>
 | 
				
			||||||
              <dl>
 | 
					              <dl>
 | 
				
			||||||
 | 
				
			|||||||
@ -152,7 +152,7 @@
 | 
				
			|||||||
        <div>
 | 
					        <div>
 | 
				
			||||||
          <Table stripe :columns="columns" :data="data"></Table>
 | 
					          <Table stripe :columns="columns" :data="data"></Table>
 | 
				
			||||||
        </div>
 | 
					        </div>
 | 
				
			||||||
        <Page @on-change="(index)=>{refundParams.pageNumber = index}" @on-page-size-change="(size)=>{refundParams.pageSize= size}" class="mt_10" show-total show-elevator :total="total" />
 | 
					        <Page @on-change="pageNumberChange" @on-page-size-change="pageSizeChange" class="mt_10" show-total show-elevator :total="total" />
 | 
				
			||||||
      </div>
 | 
					      </div>
 | 
				
			||||||
    </Card>
 | 
					    </Card>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -459,6 +459,14 @@ export default {
 | 
				
			|||||||
    },
 | 
					    },
 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  methods: {
 | 
					  methods: {
 | 
				
			||||||
 | 
					    pageNumberChange(val){
 | 
				
			||||||
 | 
					      this.refundParams.pageNumber = val
 | 
				
			||||||
 | 
					      this.getOrderList();
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    pageSizeChange(val){
 | 
				
			||||||
 | 
					      this.refundParams.pageSize = val
 | 
				
			||||||
 | 
					      this.getOrderList();
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
    // 订单图
 | 
					    // 订单图
 | 
				
			||||||
    initOrderChart() {
 | 
					    initOrderChart() {
 | 
				
			||||||
      // 默认已经加载 legend-filter 交互
 | 
					      // 默认已经加载 legend-filter 交互
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user