mirror of
https://github.com/MCSManager/MCSManager.git
synced 2025-01-30 15:19:32 +08:00
Feat: optimized code
This commit is contained in:
parent
6d9885b459
commit
94cf34f09b
@ -38,7 +38,7 @@ const columns = [
|
||||
{
|
||||
title: t("字节流编码"),
|
||||
dataIndex: "ie",
|
||||
customRender: (e: any) => {
|
||||
customRender: (e: { text: string; record: { oe: string; ie: string } }) => {
|
||||
return `${e.text}/${e.record.oe}`;
|
||||
}
|
||||
},
|
||||
@ -69,7 +69,7 @@ const getInstanceList = async () => {
|
||||
});
|
||||
};
|
||||
|
||||
const operate = (e: any) => {
|
||||
const operate = (e: { serviceUuid: string; instanceUuid: string }) => {
|
||||
router.push({
|
||||
path: "/instances/terminal",
|
||||
query: {
|
||||
|
@ -37,19 +37,18 @@ const computedStatusList = computed(() => {
|
||||
{
|
||||
type: "instance_running",
|
||||
title: t("实例正在运行中的数量"),
|
||||
value: state.value.instances.filter((e: any) => e.status == 3).length
|
||||
value: state.value.instances.filter((e) => e.status == 3).length
|
||||
},
|
||||
{
|
||||
type: "instance_stop",
|
||||
title: t("实例未处于运行中的数量"),
|
||||
value: state.value.instances.filter((e: any) => e.status == 0).length
|
||||
value: state.value.instances.filter((e) => e.status == 0).length
|
||||
},
|
||||
{
|
||||
type: "instance_error",
|
||||
title: t("暂时不可使用的实例数"),
|
||||
value: state.value.instances.filter(
|
||||
(e: any) => e.status == -1 || e.status == 1 || e.status == 2
|
||||
).length
|
||||
value: state.value.instances.filter((e) => e.status == -1 || e.status == 1 || e.status == 2)
|
||||
.length
|
||||
}
|
||||
];
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user