public bool DeleteDate() { JAUTDocumentTable AT = new JAUTDocumentTable(); AT.SetValueProperty(this); if (AT.Delete()) { Nodes.Delete(Nodes.CurrentNode); return(true); } else { return(false); } }
public bool Delete() { if (!JPermission.CheckPermission("BusManagment.Documents.JAUTDocument.Delete")) { return(false); } JAUTDocumentTable AT = new JAUTDocumentTable(); AT.SetValueProperty(this); if (AT.Delete()) { Nodes.Delete(Nodes.CurrentNode); ClassLibrary.JHistory jHistory = new ClassLibrary.JHistory(); jHistory.Save("BusManagment.JAUTDocument", AT.Code, 0, 0, 0, "حذف سند", "", 0); return(true); } else { return(false); } }
public bool CascadeDelete(JDataBase db) { JAUTDocumentTable AT = new JAUTDocumentTable(); AT.SetValueProperty(this); if (JAUTDocumentDetails.Delete(db, this.Code)) { if (AT.Delete(db)) { ClassLibrary.JHistory jHistory = new ClassLibrary.JHistory(); jHistory.Save("BusManagment.JAUTDocument", AT.Code, 0, 0, 0, "حذف سند و جزئیات", "", 0); return(true); } else { return(false); } } else { return(false); } }