From 558845242a07b68f42fa1802c45ab2769395d8b8 Mon Sep 17 00:00:00 2001
From: 闫增涛 <1829501689@qq.com>
Date: 星期一, 29 四月 2024 14:31:30 +0800
Subject: [PATCH] 合并代码

---
 packageBookService/pages/bookServices/detail/buyResource/index.js |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/packageBookService/pages/bookServices/detail/buyResource/index.js b/packageBookService/pages/bookServices/detail/buyResource/index.js
index b4032b9..8986936 100644
--- a/packageBookService/pages/bookServices/detail/buyResource/index.js
+++ b/packageBookService/pages/bookServices/detail/buyResource/index.js
@@ -127,7 +127,7 @@
   // 鎵佸钩鍖栨暟鎹浆鎹ree
   getTreeList(rootList, pathLength, newArr, path) {
     for (const item of rootList) {
-      if (item.productLinkPath.length == pathLength && item.productLinkPath.includes(path)) {
+      if ((pathLength - item.productLinkPath.length >= 0 && pathLength - item.productLinkPath.length <= 3) && item.productLinkPath.includes(path)) {
         if (item.sysType == 'CmsItem') {
           if (item.selectType == 'webpage') {
             item.disabled = true
@@ -288,7 +288,8 @@
         //   })
         // }
         // debugger
-        this.getTreeList(res.datas.cmsDatas[0].datas, 17, list, '\\')
+        const num = query.cmsPath.length + 6
+        this.getTreeList(res.datas.cmsDatas[0].datas, num, list, '\\')
         list = this.ensureTreeConsistency(list)
         list = this.changeResourceChildren(list)
         console.log('淇敼鍚庝簯', list);

--
Gitblit v1.9.1