diff --git a/ui/src/components/business/folder-tree/MoveToDialog.vue b/ui/src/components/business/folder-tree/MoveToDialog.vue index 60101f3b09c..5b05ad1d1f3 100644 --- a/ui/src/components/business/folder-tree/MoveToDialog.vue +++ b/ui/src/components/business/folder-tree/MoveToDialog.vue @@ -12,8 +12,11 @@ const emit = defineEmits<{ submit: [targetFolderId: string] }>() const visible = ref(false) const selectedTargetId = ref(FOLDER_ENTRY_ID.ALL) +const initialFolderId = ref(FOLDER_ENTRY_ID.ALL) -const canSubmit = computed(() => Boolean(selectedTargetId.value) && selectedTargetId.value !== FOLDER_ENTRY_ID.ALL) +const canSubmit = computed( + () => Boolean(selectedTargetId.value) && selectedTargetId.value !== FOLDER_ENTRY_ID.ALL && selectedTargetId.value !== initialFolderId.value, +) /* 移动提交 */ function handleSubmit() { @@ -22,11 +25,13 @@ function handleSubmit() { } function open(currentFolderId = FOLDER_ENTRY_ID.ALL) { + initialFolderId.value = currentFolderId selectedTargetId.value = currentFolderId visible.value = true } function resetData() { + initialFolderId.value = FOLDER_ENTRY_ID.ALL selectedTargetId.value = FOLDER_ENTRY_ID.ALL } diff --git a/ui/src/components/business/folder-tree/index.vue b/ui/src/components/business/folder-tree/index.vue index de2f4c35734..4873b5faa56 100644 --- a/ui/src/components/business/folder-tree/index.vue +++ b/ui/src/components/business/folder-tree/index.vue @@ -331,7 +331,7 @@ const movingFolder = ref() function handleOpenMoveFolder(folder: FolderItem) { movingFolder.value = folder - moveToDialogRef.value?.open(folder.parent_id ?? FOLDER_ENTRY_ID.ALL) + moveToDialogRef.value?.open(folder.id ?? FOLDER_ENTRY_ID.ALL) } function handleMoveFolder(targetFolderId: string) { diff --git a/ui/src/components/mk-echart/LineCharts.vue b/ui/src/components/mk-echart/LineCharts.vue index 792648391e0..2b4285256e4 100644 --- a/ui/src/components/mk-echart/LineCharts.vue +++ b/ui/src/components/mk-echart/LineCharts.vue @@ -2,6 +2,7 @@ import { computed } from 'vue' import { use, type ComposeOption } from 'echarts/core' import { LineChart, type LineSeriesOption } from 'echarts/charts' +import { LegacyGridContainLabel } from 'echarts/features' import { GridComponent, LegendComponent, @@ -14,7 +15,7 @@ import { numberFormat } from '@/utils/number' import MkEchart from './index.vue' import type { MkLineChartOption } from './types' -use([LineChart, GridComponent, LegendComponent, TooltipComponent]) +use([LineChart, GridComponent, LegendComponent, TooltipComponent, LegacyGridContainLabel]) defineOptions({ name: 'MkLineChart' }) const props = withDefaults( defineProps<{ @@ -44,15 +45,15 @@ const chartOption = computed(() => ({ itemHeight: 8, textStyle: { color: '#646A73' }, }, - // 为居中显示的日期预留两端空间,避免裁切或挤掉相邻标签。 - grid: { left: 0, right: 0, top: 56, bottom: 0, outerBoundsMode: 'same', outerBoundsContain: 'axisLabel' }, + // 保留纵轴和底部标签空间,右端日期超出画布时直接裁切。 + grid: { left: 0, right: 0, top: 56, bottom: 0, containLabel: true }, xAxis: { type: 'category', data: props.option.xData, boundaryGap: false, axisLine: { lineStyle: { color: '#EFF0F1' } }, axisTick: { show: false }, - axisLabel: { color: '#646A73', margin: 16 }, + axisLabel: { color: '#646A73', margin: 16, align: 'left' }, }, yAxis: { type: 'value', diff --git a/ui/src/views/application-detail/setting/index.vue b/ui/src/views/application-detail/setting/index.vue index 89b7daee3c6..23442d3dd64 100644 --- a/ui/src/views/application-detail/setting/index.vue +++ b/ui/src/views/application-detail/setting/index.vue @@ -1,7 +1,7 @@