feat: add instance recreate action

This commit is contained in:
jialin
2026-05-15 16:22:07 +08:00
committed by jialin
parent c6e7075bf5
commit 87c8a3a64d
36 changed files with 616 additions and 106 deletions
+3 -11
View File
@@ -66,10 +66,10 @@ const GPUServiceStorage: React.FC = () => {
{ ...params, namespace, clusterID: effectiveClusterID },
options
);
const total = res.items?.length ?? 0;
const total = res?.items?.length ?? 0;
const perPage = params.perPage || 10;
return {
items: res.items ?? [],
items: res?.items ?? [],
pagination: {
total,
totalPage: Math.ceil(total / perPage),
@@ -311,15 +311,7 @@ const GPUServiceStorage: React.FC = () => {
showSorterTooltip={false}
rowKey={(record) => record.metadata?.name as any}
onChange={handleTableChange}
pagination={{
size: 'middle',
showSizeChanger: true,
pageSize: queryParams.perPage,
current: queryParams.page,
total: dataSource.total,
hideOnSinglePage: queryParams.perPage === 10,
onChange: handlePageChange
}}
pagination={false}
/>
</ConfigProvider>
</PageContainerInner>