mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-25 02:34:29 +00:00
Litellm dev 01 23 2025 p2 (#7962)
* fix(ui/): revert user team key view * fix(view_key_table.tsx): fix default team view - show all personal keys * fix(navbar.tsx): fix custom logo Fixes https://github.com/BerriAI/litellm/issues/7895 --------- Co-authored-by: Ishaan Jaff <ishaanjaffer0324@gmail.com>
This commit is contained in:
parent
70a3683552
commit
744b7709ca
7 changed files with 14 additions and 7 deletions
3
.gitignore
vendored
3
.gitignore
vendored
|
@ -69,4 +69,5 @@ tests/llm_translation/log.txt
|
|||
venv/
|
||||
tests/local_testing/log.txt
|
||||
|
||||
.codegpt
|
||||
.codegpt
|
||||
litellm/proxy/_new_new_secret_config.yaml
|
||||
|
|
|
@ -11,6 +11,7 @@ model_list:
|
|||
api_base: http://0.0.0.0:8090
|
||||
timeout: 2
|
||||
num_retries: 0
|
||||
|
||||
|
||||
litellm_settings:
|
||||
success_callback: ["langfuse"]
|
Binary file not shown.
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 49 KiB |
|
@ -84,7 +84,7 @@ const DashboardTeam: React.FC<DashboardTeamProps> = ({
|
|||
value={String(index)}
|
||||
onClick={() => {
|
||||
setSelectedTeam(team);
|
||||
setKeys(team["keys"]);
|
||||
// setKeys(team["keys"]);
|
||||
}}
|
||||
>
|
||||
{team["team_alias"]}
|
||||
|
|
|
@ -90,8 +90,13 @@ const Navbar: React.FC<NavbarProps> = ({
|
|||
{/* Left side - Just Logo */}
|
||||
<div className="flex items-center">
|
||||
<Link href="/" className="flex items-center">
|
||||
<span className="text-xl">🚅</span>
|
||||
<span className="ml-2 text-base font-medium text-gray-700">LiteLLM</span>
|
||||
<button className="text-gray-800 rounded text-center">
|
||||
<img
|
||||
src={imageUrl}
|
||||
alt="LiteLLM Brand"
|
||||
className="h-10 w-40 object-contain"
|
||||
/>
|
||||
</button>
|
||||
</Link>
|
||||
</div>
|
||||
|
||||
|
|
|
@ -206,14 +206,14 @@ const UserDashboard: React.FC<UserDashboardProps> = ({
|
|||
|
||||
setUserSpendData(response["user_info"]);
|
||||
console.log(`userSpendData: ${JSON.stringify(userSpendData)}`)
|
||||
setKeys(response["keys"]); // Assuming this is the correct path to your data
|
||||
const teamsArray = [...response["teams"]];
|
||||
if (teamsArray.length > 0) {
|
||||
console.log(`response['teams']: ${JSON.stringify(teamsArray)}`);
|
||||
setSelectedTeam(teamsArray[0]);
|
||||
setKeys(teamsArray[0]["keys"]); // Assuming this is the correct path to your data
|
||||
} else {
|
||||
setSelectedTeam(defaultTeam);
|
||||
setKeys(response["keys"]); // Assuming this is the correct path to your data
|
||||
|
||||
}
|
||||
sessionStorage.setItem(
|
||||
"userData" + userID,
|
||||
|
|
|
@ -166,7 +166,7 @@ const ViewKeyTable: React.FC<ViewKeyTableProps> = ({
|
|||
});
|
||||
|
||||
// If no team is selected, show all accessible keys
|
||||
if (!selectedTeam && data) {
|
||||
if ((!selectedTeam || selectedTeam.team_alias === "Default Team") && data) {
|
||||
const personalKeys = data.filter(key => !key.team_id || key.team_id === "default-team");
|
||||
const adminTeamKeys = teams
|
||||
.filter(team => isUserTeamAdmin(team))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue