jinx 1 year ago
parent
commit
ea07353b92
1 changed files with 33 additions and 11 deletions
  1. 33 11
      packages/app-cdfg/src/store/modules/tag.js

+ 33 - 11
packages/app-cdfg/src/store/modules/tag.js

@@ -987,24 +987,46 @@ export default {
                                 if (hotData.visiblePanos) {
                                     delete hotData.visiblePanos
                                 }
-                                let data = {
-                                    sid: hotData.sid,
-                                    hotData: JSON.stringify(hotData),
+                                let data = null
+                                if (hotData.brandId) {
+                                    data = {
+                                        sid: hotData.sid,
+                                        brandId: hotData.brandId,
+                                        hotData: JSON.stringify(hotData),
+                                    }
+                                } else {
+                                    data = {
+                                        sid: hotData.sid,
+                                        hotData: JSON.stringify(hotData),
+                                    }
                                 }
                                 tagList.push(data)
                             }
                         }
                     }
+
                     // state.changeTagsList = []
                 } else {
-                    tagList.push({
-                        sid: hotData.sid,
-                        hotData: JSON.stringify({
-                            ...hotData,
-                            products: [],
-                        }),
-                        ...addparams,
-                    })
+                    if (hotData.brandId) {
+                        tagList.push({
+                            sid: hotData.sid,
+                            brandId: hotData.brandId,
+                            hotData: JSON.stringify({
+                                ...hotData,
+                                products: [],
+                            }),
+                            ...addparams,
+                        })
+                    } else {
+                        tagList.push({
+                            sid: hotData.sid,
+                            hotData: JSON.stringify({
+                                ...hotData,
+                                products: [],
+                            }),
+                            ...addparams,
+                        })
+                    }
                 }
 
                 console.error(hotData)