mirror of
https://github.com/Unleash/unleash.git
synced 2025-02-23 00:22:19 +01:00
feat: copy strategy to current environment (#7730)
This commit is contained in:
parent
e0f7146402
commit
5cd657065f
@ -120,7 +120,7 @@ export const CopyStrategyIconMenu: VFC<ICopyStrategyIconMenuProps> = ({
|
||||
}
|
||||
/>
|
||||
<Tooltip
|
||||
title={`Copy to another environment${
|
||||
title={`Copy to environment${
|
||||
enabled ? '' : ' (Access denied)'
|
||||
}`}
|
||||
>
|
||||
@ -150,7 +150,7 @@ export const CopyStrategyIconMenu: VFC<ICopyStrategyIconMenuProps> = ({
|
||||
'aria-labelledby': `copy-strategy-icon-menu-${strategy.id}`,
|
||||
}}
|
||||
>
|
||||
{environments.map((environment) => {
|
||||
{[...environments, environmentId].map((environment) => {
|
||||
const access = checkAccess(
|
||||
CREATE_FEATURE_STRATEGY,
|
||||
environment,
|
||||
@ -179,7 +179,9 @@ export const CopyStrategyIconMenu: VFC<ICopyStrategyIconMenuProps> = ({
|
||||
}
|
||||
/>
|
||||
<ListItemText>
|
||||
Copy to {environment}
|
||||
{environment === environmentId
|
||||
? 'Duplicate in current'
|
||||
: `Copy to ${environment}`}
|
||||
</ListItemText>
|
||||
</MenuItem>
|
||||
</div>
|
||||
|
Loading…
Reference in New Issue
Block a user