diff --git a/src/views/product/index.vue b/src/views/product/index.vue index 35a9037..66cea89 100644 --- a/src/views/product/index.vue +++ b/src/views/product/index.vue @@ -110,7 +110,7 @@ export default { return { dayjs, query: { - productId:'', + productId: '', name: '', categoryId: '', typeEnum: '' @@ -172,11 +172,10 @@ export default { }, // 设置热门 async changeHot(e, row) { - console.log(row) try { this.tableData.loading = true await tbProductIsHot({ - shopId: localStorage.getItem('shopId'), + isHot: e, id: row.id }) this.getTableData() @@ -203,7 +202,7 @@ export default { async getTableData() { try { let localQuery = JSON.parse(localStorage.getItem('shopIndexQuery')) - if (localQuery != null&&localQuery.hasOwnProperty('productId')) { + if (localQuery != null && localQuery.hasOwnProperty('productId')) { this.query = localQuery } @@ -214,7 +213,7 @@ export default { size: this.tableData.size, name: this.query.name, categoryId: this.query.categoryId, - id:this.query.productId, + id: this.query.productId, typeEnum: this.query.typeEnum, shopId: localStorage.getItem('shopId') })