mirror of
https://github.com/linux-do/new-api.git
synced 2025-11-06 22:33:41 +08:00
feat: 无可选分组时关闭令牌分组功能 #485
This commit is contained in:
@@ -439,10 +439,10 @@ const EditToken = (props) => {
|
|||||||
optionList={models}
|
optionList={models}
|
||||||
disabled={!model_limits_enabled}
|
disabled={!model_limits_enabled}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<div style={{ marginTop: 10 }}>
|
<div style={{ marginTop: 10 }}>
|
||||||
<Typography.Text>令牌分组,默认为用户的分组</Typography.Text>
|
<Typography.Text>令牌分组,默认为用户的分组</Typography.Text>
|
||||||
</div>
|
</div>
|
||||||
|
{groups.length > 0 ?
|
||||||
<Select
|
<Select
|
||||||
style={{ marginTop: 8 }}
|
style={{ marginTop: 8 }}
|
||||||
placeholder={'令牌分组,默认为用户的分组'}
|
placeholder={'令牌分组,默认为用户的分组'}
|
||||||
@@ -455,7 +455,14 @@ const EditToken = (props) => {
|
|||||||
value={inputs.group}
|
value={inputs.group}
|
||||||
autoComplete='new-password'
|
autoComplete='new-password'
|
||||||
optionList={groups}
|
optionList={groups}
|
||||||
|
/>:
|
||||||
|
<Select
|
||||||
|
style={{ marginTop: 8 }}
|
||||||
|
placeholder={'管理员未设置用户可选分组'}
|
||||||
|
name='gruop'
|
||||||
|
disabled={true}
|
||||||
/>
|
/>
|
||||||
|
}
|
||||||
</Spin>
|
</Spin>
|
||||||
</SideSheet>
|
</SideSheet>
|
||||||
</>
|
</>
|
||||||
|
|||||||
Reference in New Issue
Block a user