fix(postgres): distinguish overloaded routines
This commit is contained in:
1 parent
823b4297d8
commit
a3f3cadb39
14 files changed
+146
-48
No files matched your search
@@ -22,6 +22,7 @@ const props = withDefaults(
|
||||
database: string;
|
||||
schema?: string;
|
||||
name: string;
|
||||
signature?: string;
|
||||
objectType: ObjectSourceKind;
|
||||
databaseType?: DatabaseType;
|
||||
dialect: "mysql" | "postgres" | "sqlserver";
|
||||
@@ -58,7 +59,7 @@ const canEdit = computed(() => sourceEditable.value && props.objectType !== "SEQ
|
||||
const title = computed(() => `${editing.value ? t("contextMenu.editView") : t("contextMenu.viewSource")} - ${props.name}`);
|
||||
|
||||
watch(
|
||||
() => [props.open, props.connectionId, props.database, props.schema, props.name, props.objectType, props.initialEditing] as const,
|
||||
() => [props.open, props.connectionId, props.database, props.schema, props.name, props.signature, props.objectType, props.initialEditing] as const,
|
||||
() => {
|
||||
if (props.open) void loadSource();
|
||||
},
|
||||
@@ -78,7 +79,7 @@ async function loadSource(nextEditing = props.initialEditing && canEdit.value) {
|
||||
try {
|
||||
if (!props.databaseType) throw new Error("Connection type is unavailable.");
|
||||
const schema = props.schema || props.database;
|
||||
const result = await api.getObjectSource(props.connectionId, props.database, schema, props.name, props.objectType);
|
||||
const result = await api.getObjectSource(props.connectionId, props.database, schema, props.name, props.objectType, props.signature);
|
||||
const editableAllowed = result.editable !== false;
|
||||
const editable = await buildEditableObjectSource({
|
||||
databaseType: props.databaseType,
|
||||
|
||||
Reference in new issue
Block a user