fix: delay querying backends

This commit is contained in:
jialin
2026-03-19 12:28:18 +08:00
committed by jialin
parent fd1a079271
commit a6af51dc32
19 changed files with 40 additions and 21 deletions
@@ -37,6 +37,7 @@ const ListSkeleton: React.FC<{
<SpinWrapper>
<Spin
spinning={loading}
size="middle"
style={{
width: '100%'
}}
@@ -472,6 +472,9 @@ const AddModal: FC<AddModalProps> = (props) => {
};
const handleOnOpen = async () => {
await new Promise((resolve) => {
setTimeout(resolve, 100);
});
const [backendOptions, gpuOptions] = await Promise.all([
form.current?.getBackendOptions?.({
cluster_id: initClusterId()
@@ -321,6 +321,7 @@ const HFModelFile: React.FC<HFModelFileProps> = forwardRef((props, ref) => {
<div className="spin-wrapper">
<Spin
spinning={dataSource.loading}
size="middle"
style={{ height: '100%', width: '100%' }}
></Spin>
</div>