Commit 509a5454 by 李伟康

fix(boutique): 修复页面数据状态管理问题

- 在获取策略状态时清空 boutiqueActivityData 数据
- 移除 Reception 组件中冗余的 tabIndex 判断条件
- 确保在特定条件下正确切换标签页状态
1 parent 203af23f
......@@ -730,6 +730,7 @@ export default {
* 查询策略首页数据状态(营销活动和客户列表是否有数据)
*/
async getStrategyStatus() {
this.$store.state.boutique.boutiqueActivityData = [] // 清空 boutiqueActivityData
const res = await uni.$api.activityApi.getActivityStatusAPI({merchantId: uni.$storage.get('userInfo').shopMerchantId})
console.log('%c查询策略首页数据状态(营销活动和客户列表是否有数据):', 'color: green;', res)
if (!res) return
......
......@@ -286,7 +286,7 @@ export default {
this.isSelect = false
this.updateViewKey = Date.now()
this.clearCanvas()
if (this.tabIndex == 0 && !this.$refs.sku && !this.hasBeforeActivity && !this.hasAfterActivity) this.changeTab(0, true, false)
if ( !this.$refs.sku && !this.hasBeforeActivity && !this.hasAfterActivity) this.changeTab(0, true, false)
},
changePreView(e, leave = true, clearBoard = true) {
let { currentItem } = this,
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!