提交一下

This commit is contained in:
aixianling
2024-06-24 11:10:40 +08:00
parent a55715f620
commit c868d651d2

View File

@@ -39,7 +39,7 @@ export default {
return {
height: '600px',
search: {
type: '',
type: '1',
categoryId: '',
hourNum: ""
},
@@ -87,15 +87,16 @@ export default {
methods: {
getData() {
const {$http, $waitFor} = window
console.log("筛选条件:", this.search)
$waitFor($http).then(() => this.getStores())
.then(() => Promise.all([this.getCameras(), this.getStoreKeyGoods(), this.getCategorySales()]))
.then(() => {
this.stores = this.stores.map(({storeName, storeCode}) => {
const {storeCameraVOList} = this.cameras.find(e => e.storeCode == storeCode) || {}
this.stores = this.stores?.map(storeCode => {
const {storeCameraVOList, storeName} = this.cameras.find(e => e.storeCode == storeCode) || {}
const keyGoods = this.storeKeyGoods.filter(e => e.storeCode == storeCode) || []
const categorySale = this.categorySales.filter(e => e.storeCode == storeCode) || []
return {storeCode, storeName, camera: storeCameraVOList.map(e => e.url), keyGoods, categorySale}
})
return {storeCode, storeName, camera: storeCameraVOList.map(e => e.cameraUrl), keyGoods, categorySale}
}) || []
})
},
getStores() {