mirror of
https://github.com/rowyio/rowy.git
synced 2025-12-28 16:06:41 +01:00
fix table sort does not work if table has formula column
This commit is contained in:
@@ -386,9 +386,7 @@ export const updateFieldAtom = atom(
|
||||
);
|
||||
|
||||
if (!row) throw new Error("Could not find row");
|
||||
const isLocalRow =
|
||||
fieldName.startsWith("_rowy_formulaValue_") ||
|
||||
Boolean(find(tableRowsLocal, ["_rowy_ref.path", path]));
|
||||
const isLocalRow = Boolean(find(tableRowsLocal, ["_rowy_ref.path", path]));
|
||||
|
||||
const update: Partial<TableRow> = {};
|
||||
|
||||
@@ -469,14 +467,6 @@ export const updateFieldAtom = atom(
|
||||
deleteFields: deleteField ? [fieldName] : [],
|
||||
});
|
||||
|
||||
// TODO(han): Formula field persistence
|
||||
// const config = find(tableColumnsOrdered, (c) => {
|
||||
// const [, key] = fieldName.split("_rowy_formulaValue_");
|
||||
// return c.key === key;
|
||||
// });
|
||||
// if(!config.persist) return;
|
||||
if (fieldName.startsWith("_rowy_formulaValue")) return;
|
||||
|
||||
// If it has no missingRequiredFields, also write to db
|
||||
// And write entire row to handle the case where it doesn’t exist in db yet
|
||||
if (missingRequiredFields.length === 0) {
|
||||
|
||||
@@ -6,9 +6,7 @@ import {
|
||||
_deleteRowDbAtom,
|
||||
_updateRowDbAtom,
|
||||
tableNextPageAtom,
|
||||
tableRowsAtom,
|
||||
tableRowsDbAtom,
|
||||
tableRowsLocalAtom,
|
||||
tableScope,
|
||||
tableSettingsAtom,
|
||||
} from "@src/atoms/tableScope";
|
||||
|
||||
Reference in New Issue
Block a user