Skip to content

Database governance built for humans and agents — controlling changes and access across every major database.

chore: update issue description title (#6029)

boojackbb11fc7fb8c0
diff --git a/frontend/src/components/Issue/IssueDescriptionPanel.vue b/frontend/src/components/Issue/IssueDescriptionPanel.vue
index d06a889ff2..219503c869 100644
--- a/frontend/src/components/Issue/IssueDescriptionPanel.vue
+++ b/frontend/src/components/Issue/IssueDescriptionPanel.vue
@@ -1,7 +1,7 @@
<template>
<!-- Description Bar -->
<div class="flex justify-between">
- <div class="textlabel">{{ $t("common.description") }}</div>
+ <div class="textlabel">{{ descriptionTitle }}</div>
<div v-if="!create" class="space-x-2">
<button
v-if="allowEditNameAndDescription && !state.editing"
@@ -70,9 +70,18 @@
</template>
<script lang="ts" setup>
-import { nextTick, onMounted, onUnmounted, ref, reactive, watch } from "vue";
+import {
+ nextTick,
+ onMounted,
+ onUnmounted,
+ ref,
+ reactive,
+ watch,
+ computed,
+} from "vue";
+import { useI18n } from "vue-i18n";
import type { Issue } from "@/types";
-import { sizeToFit } from "@/utils";
+import { isGrantRequestIssueType, sizeToFit } from "@/utils";
import { useExtraIssueLogic, useIssueLogic } from "./logic";
interface LocalState {
@@ -80,6 +89,7 @@ interface LocalState {
editDescription: string;
}
+const { t } = useI18n();
const { issue, create } = useIssueLogic();
const { allowEditNameAndDescription, updateDescription } = useExtraIssueLogic();
@@ -90,6 +100,16 @@ const state = reactive<LocalState>({
editDescription: issue.value.description,
});
+const isGrantRequestIssue = computed(() => {
+ return !!issue.value && isGrantRequestIssueType(issue.value.type);
+});
+
+const descriptionTitle = computed(() => {
+ return isGrantRequestIssue.value
+ ? t("common.reason")
+ : t("common.description");
+});
+
const keyboardHandler = (e: KeyboardEvent) => {
if (
state.editing &&
diff --git a/frontend/src/components/Issue/form/GrantRequestExporterForm.vue b/frontend/src/components/Issue/form/GrantRequestExporterForm.vue
index 9fe0296a53..d7c7655971 100644
--- a/frontend/src/components/Issue/form/GrantRequestExporterForm.vue
+++ b/frontend/src/components/Issue/form/GrantRequestExporterForm.vue
@@ -176,7 +176,10 @@ const dialect = computed((): SQLDialect => {
onMounted(() => {
if (create.value) {
- state.projectId = (issue.value as IssueCreate).projectId;
+ const projectId = (issue.value as IssueCreate).projectId;
+ if (projectId && projectId !== UNKNOWN_ID) {
+ state.projectId = projectId;
+ }
}
});
diff --git a/frontend/src/components/Issue/form/GrantRequestQuerierForm.vue b/frontend/src/components/Issue/form/GrantRequestQuerierForm.vue
index 0a867a0697..a133b42bb3 100644
--- a/frontend/src/components/Issue/form/GrantRequestQuerierForm.vue
+++ b/frontend/src/components/Issue/form/GrantRequestQuerierForm.vue
@@ -121,6 +121,7 @@ import {
Issue,
IssueCreate,
ProjectId,
+ UNKNOWN_ID,
} from "@/types";
import { getProjectMemberList, parseExpiredTimeString } from "@/utils";
import DatabasesSelectPanel from "../../DatabasesSelectPanel.vue";
@@ -196,7 +197,10 @@ const selectedDatabaseList = computed(() => {
onMounted(() => {
if (create.value) {
- state.projectId = (issue.value as IssueCreate).projectId;
+ const projectId = (issue.value as IssueCreate).projectId;
+ if (projectId && projectId !== UNKNOWN_ID) {
+ state.projectId = projectId;
+ }
}
});
diff --git a/frontend/src/locales/en-US.json b/frontend/src/locales/en-US.json
index e98d9455d0..dc3c9808e3 100644
--- a/frontend/src/locales/en-US.json
+++ b/frontend/src/locales/en-US.json
@@ -244,7 +244,8 @@
"expand": "Expand",
"collapse": "Collapse",
"select": "Select",
- "optional": "Optional"
+ "optional": "Optional",
+ "reason": "Reason"
},
"error-page": {
"go-back-home": "Go back home"
diff --git a/frontend/src/locales/es-ES.json b/frontend/src/locales/es-ES.json
index e518d6b950..5ffb9024c3 100644
--- a/frontend/src/locales/es-ES.json
+++ b/frontend/src/locales/es-ES.json
@@ -244,7 +244,8 @@
"expand": "Expandir",
"collapse": "Colapsar",
"select": "Seleccionar",
- "optional": "Opcional"
+ "optional": "Opcional",
+ "reason": "Razón"
},
"error-page": {
"go-back-home": "Volver al inicio"
diff --git a/frontend/src/locales/zh-CN.json b/frontend/src/locales/zh-CN.json
index db9490e428..253917d404 100644
--- a/frontend/src/locales/zh-CN.json
+++ b/frontend/src/locales/zh-CN.json
@@ -242,7 +242,8 @@
"expand": "展开",
"collapse": "收起",
"select": "选择",
- "optional": "可选"
+ "optional": "可选",
+ "reason": "理由"
},
"error-page": {
"go-back-home": "回到主页"