Skip to content

Commit

Permalink
feat(frontend): redis集群容量变更调整 #5659
Browse files Browse the repository at this point in the history
  • Loading branch information
3octaves authored and jinquantianxia committed Sep 11, 2024
1 parent 02b97b6 commit 399c95b
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 12 deletions.
3 changes: 0 additions & 3 deletions dbm-ui/frontend/src/services/model/ticket/details/redis.ts
Original file line number Diff line number Diff line change
Expand Up @@ -96,9 +96,6 @@ export interface RedisScaleUpDownDetails extends DetailBase {
affinity: 'CROS_SUBZONE';
};
};
display_info?: {
new_group_num: number;
};
}[];
specs: DetailSpecs;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@
}
return Promise.resolve({
shard_num: localValue.value.cluster_shard_num, // props.rowData!.shardNum
group_num: targetObj.value!.requireMachineGroupNum,
group_num: localValue.value.machine_pair, // targetObj.value!.requireMachineGroupNum,
capacity: futureCapacity.value ?? 1,
future_capacity: futureCapacity.value ?? 1,
update_mode: targetObj.value?.updateMode,
Expand All @@ -226,7 +226,6 @@
affinity: AffinityType.CROS_SUBZONE, // 暂时固定 'CROS_SUBZONE',
},
},
new_group_num: localValue.value.machine_pair,
});
},
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -191,17 +191,12 @@
targetCapacityRef.value!.getValue(),
]).then((data) => {
const [version, switchMode, targetCapacity] = data;
const displayInfo = {
new_group_num: targetCapacity.new_group_num,
};
delete targetCapacity.new_group_num;
return {
cluster_id: props.data.clusterId,
db_version: version,
bk_cloud_id: props.data.bkCloudId,
online_switch_type: switchMode,
...targetCapacity,
display_info: displayInfo,
};
});
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@
{
title: t('机器组数'),
render: () => {
const targetValue = data?.display_info?.new_group_num || 0
const targetValue = data.shard_num
return (
<>
<span>{targetValue}</span>
Expand All @@ -201,7 +201,7 @@
{
title: t('机器数量'),
render: () => {
const targetValue = (data?.display_info?.new_group_num || 0) * 2
const targetValue = data.shard_num * 2
return (
<>
<span>{targetValue}</span>
Expand Down

0 comments on commit 399c95b

Please sign in to comment.