feat: change tensorrt button logic (#10805)

This commit is contained in:
CityFun 2025-10-28 18:56:45 +08:00 committed by GitHub
parent c327936db1
commit 2cef8dcea4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -192,7 +192,7 @@ const buttons = [
{ {
label: i18n.global.t('commons.button.start'), label: i18n.global.t('commons.button.start'),
disabled: (row: AI.TensorRTLLM) => { disabled: (row: AI.TensorRTLLM) => {
return row.status === 'running'; return row.status === 'Running';
}, },
click: (row: AI.TensorRTLLM) => { click: (row: AI.TensorRTLLM) => {
operate(row, 'start'); operate(row, 'start');
@ -201,7 +201,7 @@ const buttons = [
{ {
label: i18n.global.t('commons.button.stop'), label: i18n.global.t('commons.button.stop'),
disabled: (row: AI.TensorRTLLM) => { disabled: (row: AI.TensorRTLLM) => {
return row.status !== 'running'; return row.status !== 'Running';
}, },
click: (row: AI.TensorRTLLM) => { click: (row: AI.TensorRTLLM) => {
operate(row, 'stop'); operate(row, 'stop');
@ -209,9 +209,6 @@ const buttons = [
}, },
{ {
label: i18n.global.t('commons.button.restart'), label: i18n.global.t('commons.button.restart'),
disabled: (row: AI.TensorRTLLM) => {
return row.status !== 'running';
},
click: (row: AI.TensorRTLLM) => { click: (row: AI.TensorRTLLM) => {
operate(row, 'restart'); operate(row, 'restart');
}, },