* [task#139076] only show moreItems on zentaopms.
This commit is contained in:
@@ -744,6 +744,10 @@ function importFileToEditor(type, options)
|
||||
});
|
||||
}
|
||||
|
||||
function isOpenVersion(version) {
|
||||
return /^\d/.test(version || $('#zuiCSS').attr('href').split('?v=').pop());
|
||||
}
|
||||
|
||||
/**
|
||||
* 定义文档各个试图和 UI 元素的上的操作方法。
|
||||
* Define the operation methods on the views and UI elements of the doc.
|
||||
@@ -847,7 +851,7 @@ const actionsMap =
|
||||
}
|
||||
}
|
||||
const docApp = this;
|
||||
const isOpen = /^\d/.test(config.version || $('#zuiCSS').attr('href').split('?v=').pop());
|
||||
const isOpen = isOpenVersion(config.version);
|
||||
if(!isOpen && docApp && docApp.mode === 'view' && doc.status != 'draft' && !doc.api)
|
||||
{
|
||||
moreItems.push({icon: 'link', text: getLang('relateObject'), className: 'relateObject-btn', command: 'toggleViewSideTab/relateObject'})
|
||||
@@ -1043,7 +1047,7 @@ const actionsMap =
|
||||
}
|
||||
|
||||
const moreItems = [];
|
||||
if((doc.contentType === 'doc' || doc.contentType === 'markdown') && !isApiDoc(doc))
|
||||
if(isOpenVersion() && (doc.contentType === 'doc' || doc.contentType === 'markdown') && !isApiDoc(doc))
|
||||
{
|
||||
if(config.debug > 5) moreItems.push({text: lang.importConfluence, command: 'importFile/confluence'});
|
||||
moreItems.push(
|
||||
|
||||
Reference in New Issue
Block a user