合并提交

master
Yer 2023-10-09 13:30:56 +08:00
commit eed6ba43d9
4 changed files with 673 additions and 283 deletions

View File

@ -490,4 +490,24 @@ export const getHotWordsHistory = (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}`);
};

View File

@ -209,10 +209,14 @@ export default {
cursor: pointer;
}
}
.active {
color: $theme_color;
position: relative;
}
.date-picker {}
.active:before {
content: "";
position: absolute;

File diff suppressed because it is too large Load Diff

View File

@ -10,39 +10,33 @@
item.year + '年' + item.month + '月' }}</Option>
</Select>
</div>
</div>
</div>
</template>
<script>
import Cookies from "js-cookie";
import { getShopListData } from "@/api/shops.js";
export default {
props: ["closeShop"],
data() {
return {
month: "", //
defuaultWay: {
title: "最近7天",
selected: true,
searchType: "LAST_SEVEN",
},
month: "", //
selectedWay: {
title: "最近7天",
//
title: "过去7天",
selected: true,
searchType: "LAST_SEVEN",
},
storeId: "", // id
dates: [], //
params: { //
params: {
//
pageNumber: 1,
pageSize: 10,
storeName: "",
storeId: "",
},
dateList: [
//
{
title: "今天",
selected: false,
@ -54,17 +48,18 @@ export default {
searchType: "YESTERDAY",
},
{
title: "最近7天",
title: "过去7天",
selected: true,
searchType: "LAST_SEVEN",
},
{
title: "最近30天",
title: "过去30天",
selected: false,
searchType: "LAST_THIRTY",
},
],
originDateList: [
//
{
title: "今天",
selected: false,
@ -76,23 +71,54 @@ export default {
searchType: "YESTERDAY",
},
{
title: "最近7天",
title: "过去7天",
selected: true,
searchType: "LAST_SEVEN",
},
{
title: "最近30天",
title: "过去30天",
selected: false,
searchType: "LAST_THIRTY",
},
],
shopTotal: "", //
shopsData: [], //
};
},
mounted() {
this.storeId = JSON.parse(Cookies.get("userInfoSeller")).id;
this.getFiveYears();
this.getShopList();
},
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
getFiveYears() {
let getYear = new Date().getFullYear();
@ -114,7 +140,7 @@ export default {
}
this.dates = dates.reverse();
},
//
//
changeSelect(e) {
this.month = e
if (this.month) {
@ -136,13 +162,13 @@ export default {
}
},
//
//
clickBreadcrumb(item) {
let currentIndex;
this.dateList.forEach((res, index) => {
this.dateList.forEach((res,index) => {
res.selected = false;
if (res.title === item.title) {
if(res.title === item.title){
currentIndex = index
}
});
@ -150,7 +176,7 @@ export default {
item.storeId = this.storeId;
this.month = "";
if (item.searchType == "") {
let currentDate = this.originDateList[currentIndex].searchType
let currentDate = this.originDateList[currentIndex].searchType
if (currentDate) {
item.searchType = currentDate
} else {