A QCodo powered CMS
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

10 lines
592 B

/**
* This will DELETE this object's <%= $objTable->ClassName; %> instance from the database.
* It will also unassociate itself from any ManyToManyReferences.
*/
public function Delete<%= $objTable->ClassName; %>() {
<% foreach ($objTable->ManyToManyReferenceArray as $objManyToManyReference) { %>
$this-><%= $objCodeGen->VariableNameFromTable($objTable->Name) %>->UnassociateAll<%= $objManyToManyReference->ObjectDescriptionPlural %>();
<% } %>
$this-><%= $objCodeGen->VariableNameFromTable($objTable->Name); %>->Delete();
}