below code is the standard code in CustTable , few lines I need not to required to execute(green color lines). how I can do that?
boolean validateDelete()
{
boolean ret;
CustTable custTable;
SalesTable salesTable;
ret = super();
if (this.AccountNum)
{
select firstonly RecId from custTable
where custTable.InvoiceAccount == this.AccountNum;
if (custTable.RecId)
{
ret = checkFailed("@SYS67133");
}
select firstonly RecId from salesTable
where salesTable.InvoiceAccount == this.AccountNum;
if (salesTable.RecId)
{
ret = checkFailed(strFmt("@SYS75284", tablePName(SalesTable)));
}
}
if (ret)
{
ret = CustVendNetAgreementRelationship::validatePartyAssociationNotInCustVendNetAgreementRelationship(this);
}
if (ret && this.CustVendTable::isRelatedToIncompleteWorkflowWorkItems())
{
ret = checkFailed("@AccountsReceivable:CustomerDeletionWorkflowWorkItemError");
}
if (ret && this.isActiveOnCustHierarchyNode())
{
ret = checkFailed("@CustHierarchy:CustDeleteErrorMessage");
}
return ret;
}