This commit is contained in:
@@ -154,6 +154,12 @@ namespace AyaNova.Biz
|
||||
await ValidateCanDelete(dbObject);
|
||||
if (HasErrors)
|
||||
return false;
|
||||
|
||||
//todo: delete contacts and customer notes
|
||||
//see workorder* collections and delete for transactional inclusion etc
|
||||
//Will need to possibly display refintegrity error from the *linked* object delete attemp, i.e. Contact for here
|
||||
//so should test that out so that it flows to the UI so user understands they can't delete the Customer due to a Contact having links to other objects
|
||||
|
||||
ct.Customer.Remove(dbObject);
|
||||
await ct.SaveChangesAsync();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user