mirror of
https://github.com/strapi/strapi.git
synced 2025-12-05 19:42:05 +00:00
Merge pull request #15632 from strapi/feature/review-workflow-feature-flag
Settings: wrap check to display review workflows in a feature flag
This commit is contained in:
commit
10bae148b1
@ -13,6 +13,7 @@ window.strapi = {
|
|||||||
features: {
|
features: {
|
||||||
SSO: 'sso',
|
SSO: 'sso',
|
||||||
AUDIT_LOGS: 'audit-logs',
|
AUDIT_LOGS: 'audit-logs',
|
||||||
|
REVIEW_WORKFLOWS: 'review-workflows',
|
||||||
},
|
},
|
||||||
projectType: 'Community',
|
projectType: 'Community',
|
||||||
};
|
};
|
||||||
|
|||||||
@ -1,17 +1,17 @@
|
|||||||
import adminPermissions from '../../../../../admin/src/permissions';
|
import adminPermissions from '../../../../../admin/src/permissions';
|
||||||
|
|
||||||
const auditLogsRoutes = strapi.features.isEnabled(strapi.features.AUDIT_LOGS)
|
const items = [];
|
||||||
? [
|
|
||||||
{
|
|
||||||
intlLabel: { id: 'global.auditLogs', defaultMessage: 'Audit Logs' },
|
|
||||||
to: '/settings/audit-logs?pageSize=50&page=1&sort=date:DESC',
|
|
||||||
id: 'auditLogs',
|
|
||||||
isDisplayed: false,
|
|
||||||
permissions: adminPermissions.settings.auditLogs.main,
|
|
||||||
},
|
|
||||||
]
|
|
||||||
: [];
|
|
||||||
|
|
||||||
const customAdminLinks = [...auditLogsRoutes];
|
if (window.strapi.features.isEnabled(window.strapi.features.AUDIT_LOGS)) {
|
||||||
|
items.push({
|
||||||
|
intlLabel: { id: 'global.auditLogs', defaultMessage: 'Audit Logs' },
|
||||||
|
to: '/settings/audit-logs?pageSize=50&page=1&sort=date:DESC',
|
||||||
|
id: 'auditLogs',
|
||||||
|
isDisplayed: false,
|
||||||
|
permissions: adminPermissions.settings.auditLogs.main,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
const customAdminLinks = items;
|
||||||
|
|
||||||
export default customAdminLinks;
|
export default customAdminLinks;
|
||||||
|
|||||||
@ -2,7 +2,7 @@ import adminPermissions from '../../../../../admin/src/permissions';
|
|||||||
|
|
||||||
const items = [];
|
const items = [];
|
||||||
|
|
||||||
if (window.strapi.features.isEnabled(strapi.features.SSO)) {
|
if (window.strapi.features.isEnabled(window.strapi.features.SSO)) {
|
||||||
items.push({
|
items.push({
|
||||||
intlLabel: { id: 'Settings.sso.title', defaultMessage: 'Single Sign-On' },
|
intlLabel: { id: 'Settings.sso.title', defaultMessage: 'Single Sign-On' },
|
||||||
to: '/settings/single-sign-on',
|
to: '/settings/single-sign-on',
|
||||||
@ -12,7 +12,7 @@ if (window.strapi.features.isEnabled(strapi.features.SSO)) {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
if (window.strapi.isEE) {
|
if (window.strapi.features.isEnabled(window.strapi.features.REVIEW_WORKFLOWS)) {
|
||||||
items.push({
|
items.push({
|
||||||
intlLabel: { id: 'Settings.review-workflows.title', defaultMessage: 'Review Workflow' },
|
intlLabel: { id: 'Settings.review-workflows.title', defaultMessage: 'Review Workflow' },
|
||||||
to: '/settings/review-workflows',
|
to: '/settings/review-workflows',
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user