feat(secret-approval): implemented the new policy based approval system bare version

This commit is contained in:
Akhil Mohan
2023-10-05 20:34:50 +05:30
parent fc43511f5d
commit 63588b4e44
27 changed files with 1033 additions and 165 deletions
@@ -23,6 +23,7 @@ type Props = {
secretPath?: string;
// modal props
autoCapitalize?: boolean;
isProtectedBranch?: boolean;
};
export const CreateSecretForm = ({
@@ -30,7 +31,8 @@ export const CreateSecretForm = ({
workspaceId,
decryptFileKey,
secretPath = "/",
autoCapitalize = true
autoCapitalize = true,
isProtectedBranch = false
}: Props) => {
const {
register,
@@ -62,7 +64,9 @@ export const CreateSecretForm = ({
reset();
createNotification({
type: "success",
text: "Successfully created secret"
text: isProtectedBranch
? "Requested changes have been send for review"
: "Successfully created secret"
});
} catch (error) {
console.log(error);