Renamed the admin type to corporate
This commit is contained in:
@@ -24,7 +24,7 @@ export default function BatchCodeGenerator({user}: {user: User}) {
|
||||
});
|
||||
|
||||
useEffect(() => {
|
||||
if (user && (user.type === "admin" || user.type === "teacher")) {
|
||||
if (user && (user.type === "corporate" || user.type === "teacher")) {
|
||||
setExpiryDate(user.subscriptionExpirationDate || null);
|
||||
}
|
||||
}, [user]);
|
||||
@@ -126,8 +126,8 @@ export default function BatchCodeGenerator({user}: {user: User}) {
|
||||
<Button
|
||||
className="w-44 2xl:w-48"
|
||||
variant="outline"
|
||||
onClick={() => generateCode("admin")}
|
||||
disabled={emails.length === 0 || isLoading || !PERMISSIONS.generateCode.admin.includes(user.type)}>
|
||||
onClick={() => generateCode("corporate")}
|
||||
disabled={emails.length === 0 || isLoading || !PERMISSIONS.generateCode.corporate.includes(user.type)}>
|
||||
Admin
|
||||
</Button>
|
||||
<Button
|
||||
|
||||
Reference in New Issue
Block a user