|
|
|
@ -111,7 +111,10 @@ const [useProvideLTARStore, useLTARStore] = useInjectionState(
|
|
|
|
|
reloadData?.() |
|
|
|
|
await loadChildrenList() |
|
|
|
|
} catch (e: any) { |
|
|
|
|
notification.error(await extractSdkResponseErrorMsg(e)) |
|
|
|
|
notification.error({ |
|
|
|
|
message: 'Delete failed', |
|
|
|
|
description: await extractSdkResponseErrorMsg(e), |
|
|
|
|
}) |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
}) |
|
|
|
@ -131,7 +134,7 @@ const [useProvideLTARStore, useLTARStore] = useInjectionState(
|
|
|
|
|
// this.$toast.info('Unlink is not possible, instead map to another parent.').goAway(3000);
|
|
|
|
|
// return;
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
try { |
|
|
|
|
// todo: audit
|
|
|
|
|
await $api.dbTableRow.nestedRemove( |
|
|
|
|
NOCO, |
|
|
|
@ -142,7 +145,12 @@ const [useProvideLTARStore, useLTARStore] = useInjectionState(
|
|
|
|
|
column.title, |
|
|
|
|
getRelatedTableRowId(row) as string, |
|
|
|
|
) |
|
|
|
|
|
|
|
|
|
} catch (e) { |
|
|
|
|
notification.error({ |
|
|
|
|
message: 'Unlink failed', |
|
|
|
|
description: await extractSdkResponseErrorMsg(e), |
|
|
|
|
}) |
|
|
|
|
} |
|
|
|
|
reloadData?.() |
|
|
|
|
// todo: reload table data and children list
|
|
|
|
|
// this.$emit('loadTableData');
|
|
|
|
@ -165,6 +173,7 @@ const [useProvideLTARStore, useLTARStore] = useInjectionState(
|
|
|
|
|
// this.newRecordModal = false;
|
|
|
|
|
// return;
|
|
|
|
|
// }
|
|
|
|
|
try { |
|
|
|
|
await $api.dbTableRow.nestedAdd( |
|
|
|
|
NOCO, |
|
|
|
|
project.value.title as string, |
|
|
|
@ -174,6 +183,12 @@ const [useProvideLTARStore, useLTARStore] = useInjectionState(
|
|
|
|
|
column.title, |
|
|
|
|
getRelatedTableRowId(row) as string, |
|
|
|
|
) |
|
|
|
|
} catch (e) { |
|
|
|
|
notification.error({ |
|
|
|
|
message: 'Linking failed', |
|
|
|
|
description: await extractSdkResponseErrorMsg(e), |
|
|
|
|
}) |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// todo: reload table data and child list
|
|
|
|
|
// this.pid = pid;
|
|
|
|
@ -213,6 +228,7 @@ const [useProvideLTARStore, useLTARStore] = useInjectionState(
|
|
|
|
|
loadChildrenList, |
|
|
|
|
row, |
|
|
|
|
deleteRelatedRow, |
|
|
|
|
getRelatedTableRowId, |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
'ltar-store', |
|
|
|
|