瀏覽代碼

Merge branch 'develop_cuxiao' of http://git.chelingzhu.com/jianguan-web/jg-ocs-html into develop_cuxiao

lilei 1 年之前
父節點
當前提交
0b9f2f8d49

+ 2 - 2
src/views/promotionRulesManagement/dealerPromotions/tableType1.vue

@@ -309,7 +309,7 @@ export default {
       const newClassifyArr = []
       mainArr.forEach(item => {
         if (item.productTypeLevel == 1) {
-          if (!item.dataRef.children) {
+          if ((item.dataRef&&!item.dataRef.children)||(!item.dataRef &&!item.children)) {
             const objType1 = {
               productTypeSn1: item.snPaths
             }
@@ -321,7 +321,7 @@ export default {
           }
         }
         if (item.productTypeLevel == 2) {
-          if (!item.dataRef.children) {
+          if ((item.dataRef&&!item.dataRef.children)||(!item.dataRef &&!item.children)) {
             const typeArr1 = item.snPaths ? item.snPaths.split(',') : []
             const objType2 = {
               productTypeSn1: typeArr1[0],

+ 2 - 2
src/views/promotionRulesManagement/dealerPromotions/tableType2.vue

@@ -280,7 +280,7 @@ export default {
       const newClassifyArr = []
       mainArr.forEach(item => {
         if (item.productTypeLevel == 1) {
-          if (!item.dataRef.children) {
+          if ((item.dataRef && !item.dataRef.children) || (!item.dataRef && !item.children)) {
             const objType1 = {
               productTypeSn1: item.snPaths
             }
@@ -291,7 +291,7 @@ export default {
           }
         }
         if (item.productTypeLevel == 2) {
-          if (!item.dataRef.children) {
+          if ((item.dataRef && !item.dataRef.children) || (!item.dataRef && !item.children)) {
             const typeArr1 = item.snPaths ? item.snPaths.split(',') : []
             const objType2 = {
               productTypeSn1: typeArr1[0],

+ 2 - 2
src/views/promotionRulesManagement/dealerPromotions/tableType3.vue

@@ -367,7 +367,7 @@ export default {
       const newClassifyArr = []
       mainArr.forEach(item => {
         if (item.productTypeLevel == 1) {
-          if (!item.dataRef.children) {
+          if ((item.dataRef && !item.dataRef.children) || (!item.dataRef && !item.children)) {
             const objType1 = {
               productTypeSn1: item.snPaths
             }
@@ -379,7 +379,7 @@ export default {
           }
         }
         if (item.productTypeLevel == 2) {
-          if (!item.dataRef.children) {
+          if ((item.dataRef && !item.dataRef.children) || (!item.dataRef && !item.children)) {
             const typeArr1 = item.snPaths ? item.snPaths.split(',') : []
             const objType2 = {
               productTypeSn1: typeArr1[0],