public async Task <int> AddAsync(COA_AccountAddModel model)
        {
            var account = ChartofaccountFactory.Create(model, _userId);
            await _repository.AddAsync(account);

            await _unitOfWork.SaveChangesAsync();

            return(account.Id);
        }
        public static COA_Account Create(COA_AccountAddModel model, string userId)
        {
            var account = new COA_Account
            {
                AccountName       = model.AccountName,
                AccountCode       = model.AccountCode,
                Description       = model.Description,
                COA_AccountTypeId = model.COA_AccountTypeId
            };

            return(account);
        }