* [bug#60557] Hidden the button of create sum chapter when doc is has no parent doc.

This commit is contained in:
xieqiyu
2025-03-14 15:22:10 +08:00
committed by 代婷婷
parent 957ae6635c
commit bbd328c820
+1 -1
View File
@@ -812,7 +812,7 @@ const actionsMap =
const moreItems =
[
hasPriv('addChapter') ? {icon: 'plus', text: lang.addSubChapter, command: `addChapter/${doc.id}`} : null,
hasPriv('addChapter') ? {icon: 'plus', text: lang.addSameChapter, command: `addChapter/${doc.parent}`} : null,
hasPriv('addChapter') && doc.parent != 0 ? {icon: 'plus', text: lang.addSameChapter, command: `addChapter/${doc.parent}`} : null,
hasPriv('create') ? {icon: 'plus', text: lang.addSubDoc, command: `startCreateDoc/${doc.id}`} : null,
!isChapter && canMoveDoc(doc) ? {icon: 'folder-move', text: lang.moveDoc, command: `moveDoc/${doc.id}`} : null,
!isChapter && hasPriv('delete') ? {icon: 'trash', text: lang.delete, command: `deleteDoc/${doc.id}`} : null,