diff --git a/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/mysql/versionLocalUpgrade.ts b/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/mysql/versionLocalUpgrade.ts index db8e30aa45..bf1003d137 100644 --- a/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/mysql/versionLocalUpgrade.ts +++ b/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/mysql/versionLocalUpgrade.ts @@ -55,6 +55,7 @@ export async function generateMysqlVersionLocalUpgradeCloneData(ticketData: Tick currentVersion: clusters[clusterId].major_version, packageVersion: clusterListMap[clusterId].masters[0].version, moduleName: item.display_info.current_module_name, + moduleId: clusters[clusterId].db_module_id, cloudId: clusters[clusterId].bk_cloud_id, }, targetPackage: item.pkg_id, diff --git a/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/mysql/versionMigrateUpgrade.ts b/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/mysql/versionMigrateUpgrade.ts index 6af49b5c0d..d0ea40691a 100644 --- a/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/mysql/versionMigrateUpgrade.ts +++ b/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/mysql/versionMigrateUpgrade.ts @@ -46,6 +46,7 @@ export async function generateMysqlVersionMigrateUpgradeCloneData(ticketData: Ti currentVersion: clusters[clusterId].major_version, packageVersion: clusterListMap[clusterId].masters[0].version, moduleName: item.display_info.current_module_name, + moduleId: clusters[clusterId].db_module_id, cloudId: clusters[clusterId].bk_cloud_id, masterSlaveList: [ ...clusterListMap[clusterId].masters, diff --git a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/Index.vue b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/Index.vue index 5f751e81aa..69dd11bb75 100644 --- a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/Index.vue +++ b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/Index.vue @@ -107,14 +107,16 @@ useTicketCloneInfo({ type: TicketTypes.MYSQL_LOCAL_UPGRADE, onSuccess(cloneData) { - tableList.value = cloneData.tableList; - force.value = cloneData.force; - remark.value = cloneData.remark; - window.changeConfirm = true; - const isSingle = cloneData.tableList[0].clusterData.clusterType === ClusterTypes.TENDBSINGLE; formData.roleType = isSingle ? 'singleStorageLayer' : 'haStorageLayer'; formData.updateType = 'local'; + + nextTick(() => { + tableList.value = cloneData.tableList; + force.value = cloneData.force; + remark.value = cloneData.remark; + window.changeConfirm = true; + }); }, }); diff --git a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/RenderTargetVersion.vue b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/RenderTargetVersion.vue index 4ea13525c6..8a4d048c4d 100644 --- a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/RenderTargetVersion.vue +++ b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/RenderTargetVersion.vue @@ -94,6 +94,7 @@ clusterType: string; currentVersion: string; moduleName: string; + moduleId: number; }; targetVersion?: string; targetPackage?: number; @@ -159,8 +160,8 @@ manual: true, onSuccess(modules) { // const moduleList: IListItem[] = []; - const { moduleName } = props.data!; - const currentModule = modules.find((moduleItem) => moduleItem.alias_name === moduleName); + const { moduleId } = props.data!; + const currentModule = modules.find((moduleItem) => moduleItem.db_module_id === moduleId); if (currentModule) { const currentCharset = currentModule.db_module_info.conf_items.find( (confItem) => confItem.conf_name === 'charset', diff --git a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-local/Index.vue b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-local/Index.vue index d83fa9e9ef..a48fcf2671 100644 --- a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-local/Index.vue +++ b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-local/Index.vue @@ -188,6 +188,7 @@ currentVersion: item.major_version, packageVersion: item.masters[0].version, moduleName: item.db_module_name, + moduleId: item.db_module_id, cloudId: item.bk_cloud_id, }, }); diff --git a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-local/Row.vue b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-local/Row.vue index 8a1b5730e0..6418ed47c2 100644 --- a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-local/Row.vue +++ b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-local/Row.vue @@ -59,6 +59,7 @@ currentVersion: string; packageVersion: string; moduleName: string; + moduleId: number; }; targetPackage?: number; } diff --git a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-remote/Index.vue b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-remote/Index.vue index 02a0cee0a4..d87e7358b2 100644 --- a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-remote/Index.vue +++ b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-remote/Index.vue @@ -322,6 +322,7 @@ currentVersion: item.major_version, packageVersion: item.masters[0].version, moduleName: item.db_module_name, + moduleId: item.db_module_id, cloudId: item.bk_cloud_id, masterSlaveList: [...item.masters, ...item.slaves.filter((item) => item.is_stand_by)].map((item) => ({ bk_biz_id: item.bk_biz_id, diff --git a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-remote/RenderTargetVersion.vue b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-remote/RenderTargetVersion.vue index 95a88d2975..4631ea057c 100644 --- a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-remote/RenderTargetVersion.vue +++ b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-remote/RenderTargetVersion.vue @@ -165,6 +165,7 @@ clusterType: string; currentVersion: string; moduleName: string; + moduleId: number; }; targetVersion?: string; targetPackage?: number; @@ -276,8 +277,8 @@ manual: true, onSuccess(modules) { const moduleList: IListItem[] = []; - const { moduleName } = props.data!; - const currentModule = modules.find((moduleItem) => moduleItem.alias_name === moduleName); + const { moduleId } = props.data!; + const currentModule = modules.find((moduleItem) => moduleItem.db_module_id === moduleId); if (currentModule) { const currentCharset = currentModule.db_module_info.conf_items.find( (confItem) => confItem.conf_name === 'charset', diff --git a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-remote/Row.vue b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-remote/Row.vue index 45b0446242..9e6ae6cb4f 100644 --- a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-remote/Row.vue +++ b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/ha-storage-layer-remote/Row.vue @@ -112,6 +112,7 @@ currentVersion: string; packageVersion: string; moduleName: string; + moduleId: number; cloudId: number; masterSlaveList: IHostData[]; readonlySlaveList: IHostData[]; diff --git a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/single-storage-layer/Index.vue b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/single-storage-layer/Index.vue index c93275dfc3..52d5494da1 100644 --- a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/single-storage-layer/Index.vue +++ b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/single-storage-layer/Index.vue @@ -187,6 +187,7 @@ currentVersion: item.major_version, packageVersion: item.masters[0].version, moduleName: item.db_module_name, + moduleId: item.db_module_id, cloudId: item.bk_cloud_id, }, }); diff --git a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/single-storage-layer/Row.vue b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/single-storage-layer/Row.vue index 542ed24a46..cce287a3b2 100644 --- a/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/single-storage-layer/Row.vue +++ b/dbm-ui/frontend/src/views/db-manage/mysql/version-upgrade/pages/page1/components/single-storage-layer/Row.vue @@ -60,6 +60,7 @@ currentVersion: string; packageVersion: string; moduleName: string; + moduleId: number; }; targetPackage?: number; }