예제 #1
0
 public void UpdateGeneralLedgerSetting(GeneralLedgerSetting setting)
 {
     _glSettingRepo.Update(setting);
 }
예제 #2
0
        public static GeneralLedgerSetting InitGeneralLedgerSetting()
        {
            var glSetting = new GeneralLedgerSetting()
            {
                Company = _context.Companies.FirstOrDefault(),
                GoodsReceiptNoteClearingAccount = _context.Accounts.Where(a => a.AccountCode == "10810").FirstOrDefault(),
                ShippingChargeAccount = _context.Accounts.Where(a => a.AccountCode == "40500").FirstOrDefault(),
                SalesDiscountAccount = _context.Accounts.Where(a => a.AccountCode == "40400").FirstOrDefault(),
                CreatedBy = "System",
                CreatedOn = DateTime.Now,
                ModifiedBy = "System",
                ModifiedOn = DateTime.Now
            };
            _context.GeneralLedgerSettings.Add(glSetting);
            _context.SaveChanges();

            return glSetting;
        }