@@ -46,6 +46,7 @@ import AddTagAttributes from "@views/Classification/AddTagAttributes";
4646import AssignCategory from "@views/Glossary/AssignCategory" ;
4747import AssignTerm from "@views/Glossary/AssignTerm" ;
4848import ShowMoreText from "@components/ShowMore/ShowMoreText" ;
49+ import AddUpdateGlossaryForm from "@views/Glossary/AddUpdateGlossaryForm" ;
4950
5051const DetailPageAttribute = ( {
5152 data,
@@ -63,13 +64,17 @@ const DetailPageAttribute = ({
6364 const [ tagModal , setTagModal ] = useState < boolean > ( false ) ;
6465 const [ editTermModal , setEditTermModal ] = useState ( false ) ;
6566 const [ editCategoryModal , setEditCategoryModal ] = useState ( false ) ;
66-
67+ const [ glossaryModal , setGlossaryModal ] = useState < boolean > ( false ) ;
6768 const [ openAddTagModal , setOpenAddTagModal ] = useState < boolean > ( false ) ;
6869 const [ attributeModal , setAttributeModal ] = useState < boolean > ( false ) ;
6970 const [ openAddTermModal , setOpenAddTermModal ] = useState < boolean > ( false ) ;
7071
7172 const [ categoryModal , setCategoryModal ] = useState < boolean > ( false ) ;
7273
74+ const handleCloseGlossaryModal = ( ) => {
75+ setGlossaryModal ( false ) ;
76+ } ;
77+
7378 const handleCloseTermModal = ( ) => {
7479 setOpenAddTermModal ( false ) ;
7580 } ;
@@ -140,14 +145,17 @@ const DetailPageAttribute = ({
140145 if ( ! isEmpty ( tagName ) ) {
141146 setTagModal ( true ) ;
142147 }
148+ if ( ! isEmpty ( guid ) && gtypeParams == "glossary" ) {
149+ setGlossaryModal ( true ) ;
150+ }
143151 if ( ! isEmpty ( guid ) && gtypeParams == "term" ) {
144152 setEditTermModal ( true ) ;
145153 }
146154 if ( ! isEmpty ( guid ) && gtypeParams == "category" ) {
147155 setEditCategoryModal ( true ) ;
148156 }
149157 } }
150- data-cy = "addTag "
158+ data-cy = "editButton "
151159 >
152160 < EditOutlinedIcon className = "table-filter-refresh" />
153161 </ CustomButton >
@@ -696,6 +704,15 @@ const DetailPageAttribute = ({
696704 relatedTerm = { undefined }
697705 />
698706 ) }
707+
708+ { glossaryModal && (
709+ < AddUpdateGlossaryForm
710+ open = { glossaryModal }
711+ isAdd = { false }
712+ onClose = { handleCloseGlossaryModal }
713+ node = { data || { } }
714+ />
715+ ) }
699716 </ >
700717 ) ;
701718} ;
0 commit comments