예제 #1
0
 /// <summary>
 /// 删除资金帐号
 /// </summary>
 /// <param name="bankAccountsId">付款帐号Id</param>
 public void Delete(Guid bankAccountsId)
 {
     if (Math.Round(_wasteBookDao.GetBalance(bankAccountsId), 3) == 0)
     {
         if (bankAccountsId != Guid.Empty)
         {
             _bankAccounts.Delete(bankAccountsId);
         }
     }
     else
     {
         throw new ApplicationException("账户中仍有余额,不允许删除!");
     }
 }