Browse Source

fix: provide ltar state to save row

Signed-off-by: mertmit <mertmit99@gmail.com>
pull/8371/head
mertmit 6 months ago
parent
commit
190e62da15
  1. 3
      packages/nc-gui/components/smartsheet/grid/Table.vue
  2. 1
      packages/nc-gui/components/virtual-cell/components/UnLinkedItems.vue

3
packages/nc-gui/components/smartsheet/grid/Table.vue

@ -1073,9 +1073,8 @@ const saveOrUpdateRecords = async (
/** if new record save row and save the LTAR cells */
if (currentRow.rowMeta.new) {
const beforeSave = clone(currentRow)
const savedRow = await updateOrSaveRow?.(currentRow, '', {}, args)
const savedRow = await updateOrSaveRow?.(currentRow, '', currentRow.rowMeta.ltarState || {}, args)
if (savedRow) {
await syncLTARRefs?.(currentRow, savedRow, args)
currentRow.rowMeta.changed = false
} else {
if (args.keepNewRecords) {

1
packages/nc-gui/components/virtual-cell/components/UnLinkedItems.vue

@ -201,7 +201,6 @@ const addNewRecord = () => {
const onCreatedRecord = (record: any) => {
addLTARRef(record, injectedColumn?.value as ColumnType)
saveRow!()
reloadTrigger?.trigger({
shouldShowLoading: false,

Loading…
Cancel
Save