7983-testToMaster_2438 #718

Merged
alexm merged 353 commits from 7983-testToMaster_2438 into master 2024-09-17 05:39:39 +00:00
2 changed files with 7 additions and 3 deletions
Showing only changes of commit 7358dab1d0 - Show all commits

View File

@ -296,6 +296,7 @@ defineExpose({
reload,
redirect: redirectFn,
selected,
CrudModelRef,
});
function handleOnDataSaved(_, res) {

View File

@ -262,10 +262,13 @@ const updateMinPrice = async (value, props) => {
});
};
const upsertPrice = async ({ row }, resetMinPrice = false) => {
const upsertPrice = async (props, resetMinPrice = false) => {
try {
if (resetMinPrice) row.hasMinPrice = 0;
row = await upsertFixedPrice(row);
const { row } = props;
if (tableRef.value.CrudModelRef.getChanges().updates.length > 0) {
if (resetMinPrice) row.hasMinPrice = 0;
await upsertFixedPrice(row);
}
} catch (err) {
console.error('Error editing price', err);
}