forked from phoenix/litellm-mirror
(fix) creating key for a team
This commit is contained in:
parent
046571ebea
commit
37db367ba6
2 changed files with 8 additions and 4 deletions
|
@ -18,7 +18,7 @@ const { Option } = Select;
|
||||||
|
|
||||||
interface CreateKeyProps {
|
interface CreateKeyProps {
|
||||||
userID: string;
|
userID: string;
|
||||||
teamID: string | null;
|
team: any | null;
|
||||||
userRole: string | null;
|
userRole: string | null;
|
||||||
accessToken: string;
|
accessToken: string;
|
||||||
data: any[] | null;
|
data: any[] | null;
|
||||||
|
@ -27,7 +27,7 @@ interface CreateKeyProps {
|
||||||
|
|
||||||
const CreateKey: React.FC<CreateKeyProps> = ({
|
const CreateKey: React.FC<CreateKeyProps> = ({
|
||||||
userID,
|
userID,
|
||||||
teamID,
|
team,
|
||||||
userRole,
|
userRole,
|
||||||
accessToken,
|
accessToken,
|
||||||
data,
|
data,
|
||||||
|
@ -130,7 +130,8 @@ const CreateKey: React.FC<CreateKeyProps> = ({
|
||||||
<Form.Item label="Team ID" name="team_id">
|
<Form.Item label="Team ID" name="team_id">
|
||||||
<Input
|
<Input
|
||||||
placeholder="ai_team"
|
placeholder="ai_team"
|
||||||
defaultValue={teamID ? teamID : ""}
|
defaultValue={team && team["team_alias"] ? team["team_alias"] : ""}
|
||||||
|
disabled={true}
|
||||||
/>
|
/>
|
||||||
</Form.Item>
|
</Form.Item>
|
||||||
<Form.Item label="Models" name="models">
|
<Form.Item label="Models" name="models">
|
||||||
|
|
|
@ -203,6 +203,8 @@ const UserDashboard: React.FC<UserDashboardProps> = ({
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
console.log("inside user dashboard, selected team", selectedTeam);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
<Grid numItems={1} className="gap-0 p-10 h-[75vh] w-full">
|
<Grid numItems={1} className="gap-0 p-10 h-[75vh] w-full">
|
||||||
|
@ -220,8 +222,9 @@ const UserDashboard: React.FC<UserDashboardProps> = ({
|
||||||
setData={setKeys}
|
setData={setKeys}
|
||||||
/>
|
/>
|
||||||
<CreateKey
|
<CreateKey
|
||||||
|
key={selectedTeam ? selectedTeam.team_id : null}
|
||||||
userID={userID}
|
userID={userID}
|
||||||
teamID={selectedTeam ? selectedTeam["team_id"] : null}
|
team={selectedTeam ? selectedTeam : null}
|
||||||
userRole={userRole}
|
userRole={userRole}
|
||||||
userModels={userModels}
|
userModels={userModels}
|
||||||
accessToken={accessToken}
|
accessToken={accessToken}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue