diff --git a/apps/client/src/services/attributes.ts b/apps/client/src/services/attributes.ts index 52ea8967a..370fd1ce1 100644 --- a/apps/client/src/services/attributes.ts +++ b/apps/client/src/services/attributes.ts @@ -12,11 +12,12 @@ async function addLabel(noteId: string, name: string, value: string = "", isInhe }); } -export async function setLabel(noteId: string, name: string, value: string = "") { +export async function setLabel(noteId: string, name: string, value: string = "", isInheritable = false) { await server.put(`notes/${noteId}/set-attribute`, { type: "label", name: name, - value: value + value: value, + isInheritable }); } diff --git a/apps/client/src/widgets/view_widgets/table_view/col_editing.ts b/apps/client/src/widgets/view_widgets/table_view/col_editing.ts index ac8c7e740..cb3f90bc9 100644 --- a/apps/client/src/widgets/view_widgets/table_view/col_editing.ts +++ b/apps/client/src/widgets/view_widgets/table_view/col_editing.ts @@ -45,7 +45,8 @@ export default class TableColumnEditing extends Component { attr = { type: "label", name: `${type ?? "label"}:myLabel`, - value: "promoted,single,text" + value: "promoted,single,text", + isInheritable: true }; } @@ -78,7 +79,7 @@ export default class TableColumnEditing extends Component { return; } - const { name, value } = this.newAttribute; + const { name, value, isInheritable } = this.newAttribute; this.api.blockRedraw(); try { @@ -88,7 +89,7 @@ export default class TableColumnEditing extends Component { await renameColumn(this.parentNote.noteId, type as "label" | "relation", oldName, newName); } - attributes.setLabel(this.parentNote.noteId, name, value); + attributes.setLabel(this.parentNote.noteId, name, value, isInheritable); if (this.existingAttributeToEdit) { attributes.removeOwnedLabelByName(this.parentNote, this.existingAttributeToEdit.name); }