feat: 修改主机额外配置.
This commit is contained in:
@@ -256,10 +256,10 @@
|
||||
const localeRef = ref();
|
||||
|
||||
// 打开应用设置
|
||||
const openAppSetting = inject(openAppSettingKey) as () => void;
|
||||
const openAppSetting = inject<() => void>(openAppSettingKey);
|
||||
|
||||
// 注入收缩菜单
|
||||
const toggleDrawerMenu = inject(toggleDrawerMenuKey) as () => void;
|
||||
const toggleDrawerMenu = inject<() => void>(toggleDrawerMenuKey);
|
||||
|
||||
// 切换主题
|
||||
const handleToggleTheme = () => {
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
|
||||
const props = defineProps({
|
||||
modelValue: Number,
|
||||
authorized: Boolean
|
||||
});
|
||||
|
||||
const emits = defineEmits(['update:modelValue']);
|
||||
@@ -45,7 +46,9 @@
|
||||
onBeforeMount(async () => {
|
||||
setLoading(true);
|
||||
try {
|
||||
const hostIdentities = await cacheStore.loadHostIdentities();
|
||||
const hostIdentities = props.authorized
|
||||
? await cacheStore.loadAuthorizedHostIdentities()
|
||||
: await cacheStore.loadHostIdentities();
|
||||
optionData.value = hostIdentities.map(s => {
|
||||
return {
|
||||
label: `${s.name} (${s.username})`,
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
|
||||
const props = defineProps({
|
||||
modelValue: Number,
|
||||
authorized: Boolean
|
||||
});
|
||||
|
||||
const emits = defineEmits(['update:modelValue']);
|
||||
@@ -45,7 +46,9 @@
|
||||
onBeforeMount(async () => {
|
||||
setLoading(true);
|
||||
try {
|
||||
const hostKeys = await cacheStore.loadHostKeys();
|
||||
const hostKeys = props.authorized
|
||||
? await cacheStore.loadAuthorizedHostKeys()
|
||||
: await cacheStore.loadHostKeys();
|
||||
optionData.value = hostKeys.map(s => {
|
||||
return {
|
||||
label: s.name,
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
:cancel-button-props="{ disabled: loading }"
|
||||
:on-before-ok="handlerOk"
|
||||
@close="handleClose">
|
||||
<a-spin :loading="loading">
|
||||
<a-spin class="full" :loading="loading">
|
||||
<a-form :model="formModel"
|
||||
ref="formRef"
|
||||
label-align="right"
|
||||
|
||||
Reference in New Issue
Block a user