feat: add "Hide_Balance_Query" environment variable

This commit is contained in:
Constaline
2023-06-25 20:20:36 +08:00
parent 8f66da1128
commit c05de45d99
8 changed files with 49 additions and 23 deletions

View File

@@ -13,6 +13,7 @@ export interface AccessControlStore {
needCode: boolean;
hideUserApiKey: boolean;
openaiUrl: string;
hideBalanceQuery: boolean;
updateToken: (_: string) => void;
updateCode: (_: string) => void;
@@ -36,6 +37,7 @@ export const useAccessStore = create<AccessControlStore>()(
needCode: true,
hideUserApiKey: false,
openaiUrl: DEFAULT_OPENAI_URL,
hideBalanceQuery: false,
enabledAccessControl() {
get().fetch();