From e0a80f2e49b93a145fcf46b3c8905ca732adc6f6 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com>
Date: Thu, 10 Oct 2019 09:02:28 +0800
Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 .../courses/coursesDetail/CoursesLeftNav.js   | 33 ++++++++++++-------
 1 file changed, 22 insertions(+), 11 deletions(-)

diff --git a/public/react/src/modules/courses/coursesDetail/CoursesLeftNav.js b/public/react/src/modules/courses/coursesDetail/CoursesLeftNav.js
index a97a827b6..e47f83c1f 100644
--- a/public/react/src/modules/courses/coursesDetail/CoursesLeftNav.js
+++ b/public/react/src/modules/courses/coursesDetail/CoursesLeftNav.js
@@ -1055,7 +1055,7 @@ class Coursesleftnav extends Component{
 																																		iem.category_id===0?"":
                                                                     iem.category_type==="graduation_topics"||iem.category_type==="graduation_tasks"?
                                                                       (
-                                                                        iem.category_name.length<13?
+                                                                        iem.category_name&&iem.category_name.length<13?
                                                                           <span className={"fr mr20 color999  Draggablelichild font-14"} >{iem.category_count===0?"":iem.category_count}</span>
                                                                           :
                                                                           <Tooltip placement="right" key={index} title={iem.category_name}  visible={toopvisibleindexs===undefined?false:toopvisibleindexs===index?true:false}>
@@ -1064,7 +1064,7 @@ class Coursesleftnav extends Component{
                                                                       )
                                                                       :
                                                                       (
-                                                                        iem.category_name.length<13?
+                                                                        iem.category_name&&iem.category_name.length<13?
                                                                           <Popover placement="right" content={this.content(item,iem,index)} trigger="hover" key={index} onMouseEnter={(e)=>this.twosandianshowyss(e)}>
                                                                             <i className={"iconfont icon-sandian fr color999 mr15 Draggablelichild"}></i>
                                                                           </Popover>
@@ -1147,15 +1147,26 @@ class Coursesleftnav extends Component{
                              {/*title={iem.category_name.length<10?"":iem.category_name}*/}
 
                              <li className="clearfix Draggableli" key={index} style={{ width: '244px'}}  >
-                               <Tooltip placement="right" key={index} title={iem.category_name}>
-                                 <a className="fl pl46 pd0 Draggablelichild" onClick={(e)=>this.selectnavids(e,key,iem.category_id,item.type+"child",iem.second_category_url,key)} >
-                                     {/*<span className="fl ml38 maxwidth170 task-hide">{iem.category_name}</span>*/}
-                                   {/*{iem.category_name.length<10?"":*/}
-                                   {/*  iem.category_name}*/}
-                                     <span className={this.props.location.pathname===iem.second_category_url?"color-blue fl ml38 maxwidth170 task-hide  Draggablelichild":"fl ml38 maxwidth170 task-hide  Draggablelichild"}>{iem.category_name}</span>
-                                   <span className={twosandiantype===undefined?this.props.location.pathname===iem.second_category_url?"fr mr20 color-blue font-14":"fr mr20 color999 font-14":twosandiantype===index&&item.type!="graduation"?"none":this.props.location.pathname===iem.second_category_url?"fr mr20 color-blue font-14":"fr mr20 color999 font-14"}>{iem.category_count===0?"":iem.category_count}</span>
-                                 </a>
-                               </Tooltip>
+                               {
+                                   iem.category_name&&iem.category_name.length<13?
+                                       <a className="fl pl46 pd0 Draggablelichild" onClick={(e)=>this.selectnavids(e,key,iem.category_id,item.type+"child",iem.second_category_url,key)} >
+                                         {/*<span className="fl ml38 maxwidth170 task-hide">{iem.category_name}</span>*/}
+                                         {/*{iem.category_name.length<10?"":*/}
+                                         {/*  iem.category_name}*/}
+                                         <span className={this.props.location.pathname===iem.second_category_url?"color-blue fl ml38 maxwidth170 task-hide  Draggablelichild":"fl ml38 maxwidth170 task-hide  Draggablelichild"}>{iem.category_name}</span>
+                                         <span className={twosandiantype===undefined?this.props.location.pathname===iem.second_category_url?"fr mr20 color-blue font-14":"fr mr20 color999 font-14":twosandiantype===index&&item.type!="graduation"?"none":this.props.location.pathname===iem.second_category_url?"fr mr20 color-blue font-14":"fr mr20 color999 font-14"}>{iem.category_count===0?"":iem.category_count}</span>
+                                       </a>
+                                     :
+                                     <Tooltip placement="right" key={index} title={iem.category_name}>
+                                       <a className="fl pl46 pd0 Draggablelichild" onClick={(e)=>this.selectnavids(e,key,iem.category_id,item.type+"child",iem.second_category_url,key)} >
+                                         {/*<span className="fl ml38 maxwidth170 task-hide">{iem.category_name}</span>*/}
+                                         {/*{iem.category_name.length<10?"":*/}
+                                         {/*  iem.category_name}*/}
+                                         <span className={this.props.location.pathname===iem.second_category_url?"color-blue fl ml38 maxwidth170 task-hide  Draggablelichild":"fl ml38 maxwidth170 task-hide  Draggablelichild"}>{iem.category_name}</span>
+                                         <span className={twosandiantype===undefined?this.props.location.pathname===iem.second_category_url?"fr mr20 color-blue font-14":"fr mr20 color999 font-14":twosandiantype===index&&item.type!="graduation"?"none":this.props.location.pathname===iem.second_category_url?"fr mr20 color-blue font-14":"fr mr20 color999 font-14"}>{iem.category_count===0?"":iem.category_count}</span>
+                                       </a>
+                                     </Tooltip>
+                               }
                                </li>
 
                            </a>