diff --git a/dbm-ui/frontend/src/components/apply-items/AffinityItem.vue b/dbm-ui/frontend/src/components/apply-items/AffinityItem.vue index ae77d8d13c..3afab42ea3 100644 --- a/dbm-ui/frontend/src/components/apply-items/AffinityItem.vue +++ b/dbm-ui/frontend/src/components/apply-items/AffinityItem.vue @@ -33,6 +33,11 @@ import { useSystemEnviron } from '@stores'; + interface Props { + defaultValue?: string + } + + const props = defineProps(); const modelValue = defineModel({ default: '', }); @@ -48,7 +53,12 @@ watch(() => affinityList, (list) => { if (list && list.length > 0) { - modelValue.value = list[0].value; + if (props.defaultValue) { + const index = list.findIndex(affinityItem => affinityItem.value === props.defaultValue); + modelValue.value = index > -1 ? props.defaultValue : list[0].value; + } else { + modelValue.value = list[0].value; + } } }, { immediate: true, diff --git a/dbm-ui/frontend/src/locales/zh-cn.json b/dbm-ui/frontend/src/locales/zh-cn.json index 22705a7f44..2918f9e4b7 100644 --- a/dbm-ui/frontend/src/locales/zh-cn.json +++ b/dbm-ui/frontend/src/locales/zh-cn.json @@ -2626,8 +2626,8 @@ "降低": "降低", "格式为:(库名).(名称)_如 admin.linda": "格式为:(库名).(名称),如 admin.linda", "由 1~32 位字母、数字、下划线(_)、点(.)、减号(-)字符组成以字母或数字开头": "由 1~32 位字母、数字、下划线(_)、点(.)、减号(-)字符组成以字母或数字开头", - "Mongo复制": "Mongo 复制", - "Mongo分片": "Mongo 分片", + "Mongo副本集": "Mongo 副本集", + "Mongo分片集": "Mongo 分片集", "需要n台": "需要 {n} 台", "Shard数量": "Shard数量", "所需机组数": "所需机组数", diff --git a/dbm-ui/frontend/src/views/db-configure/components/TopTab.vue b/dbm-ui/frontend/src/views/db-configure/components/TopTab.vue index b97aced1cb..4ad4fcf538 100644 --- a/dbm-ui/frontend/src/views/db-configure/components/TopTab.vue +++ b/dbm-ui/frontend/src/views/db-configure/components/TopTab.vue @@ -112,12 +112,12 @@ { moduleId: 'mongodb', id: ClusterTypes.MONGO_REPLICA_SET, - name: t('Mongo复制'), + name: t('Mongo副本集'), }, { moduleId: 'mongodb', id: ClusterTypes.MONGO_SHARED_CLUSTER, - name: t('Mongo分片'), + name: t('Mongo分片集'), }, ]; diff --git a/dbm-ui/frontend/src/views/mongodb-manage/mongodb-instance/list/index.vue b/dbm-ui/frontend/src/views/mongodb-manage/mongodb-instance/list/index.vue index 6aa7557001..9d33b2aa11 100644 --- a/dbm-ui/frontend/src/views/mongodb-manage/mongodb-instance/list/index.vue +++ b/dbm-ui/frontend/src/views/mongodb-manage/mongodb-instance/list/index.vue @@ -40,9 +40,6 @@ ref="tableRef" :columns="columns" :data-source="getMongoInstancesList" - :is-anomalies="isAnomalies" - :pagination="renderPagination" - :pagination-extra="{ small: false }" :row-class="setRowClass" selectable :settings="settings" @@ -65,8 +62,6 @@ import { createTicket } from '@services/source/ticket'; import { - type IPagination, - useDefaultPagination, useStretchLayout, useTableSettings, useTicketMessage, @@ -123,7 +118,6 @@ } = useStretchLayout(); const tableRef = ref(); - const isAnomalies = ref(false); const isInstanceDropdown = ref(false); const roleListType = ref<{ @@ -133,7 +127,6 @@ const searchValues = ref([]); const selected = ref([]); - const pagination = ref(useDefaultPagination()); const hasSelected = computed(() => selected.value.length > 0); const selectedIds = computed(() => selected.value.map(item => item.bk_host_id)); @@ -268,21 +261,6 @@ return list; }); - const renderPagination = computed(() => { - if (pagination.value.count < 10) { - return false; - } - if (!isStretchLayoutOpen.value) { - return { ...pagination.value }; - } - return { - ...pagination.value, - small: true, - align: 'left', - layout: ['total', 'limit', 'list'], - }; - }); - const searchData = computed(() => [ { name: '实例', diff --git a/dbm-ui/frontend/src/views/mongodb-manage/replica-set-apply/Index.vue b/dbm-ui/frontend/src/views/mongodb-manage/replica-set-apply/Index.vue index b22a05196c..2df0006817 100644 --- a/dbm-ui/frontend/src/views/mongodb-manage/replica-set-apply/Index.vue +++ b/dbm-ui/frontend/src/views/mongodb-manage/replica-set-apply/Index.vue @@ -33,7 +33,9 @@ ref="regionItemRef" v-model="formData.details.city_code" /> - + @@ -236,7 +239,7 @@ domain: string, name: string, }>, - start_port: 25501, + start_port: 27001, node_count: 3, replica_count: 1, node_replica_count: 1, diff --git a/dbm-ui/frontend/src/views/resource-manage/spec/Index.vue b/dbm-ui/frontend/src/views/resource-manage/spec/Index.vue index c928b1436a..5e73e423dc 100644 --- a/dbm-ui/frontend/src/views/resource-manage/spec/Index.vue +++ b/dbm-ui/frontend/src/views/resource-manage/spec/Index.vue @@ -252,7 +252,7 @@ }, { moduleId: 'mongodb', - label: t('Mongo复制'), + label: t('Mongo副本集'), name: ClusterTypes.MONGO_REPLICA_SET, children: [ { @@ -263,7 +263,7 @@ }, { moduleId: 'mongodb', - label: t('Mongo分片'), + label: t('Mongo分片集'), name: ClusterTypes.MONGO_SHARED_CLUSTER, children: [ {