Exemple #1
0
        // GET: SubsidiaryLedger
        public ActionResult ViewSubsidiaryLedger()
        {
            SearchSubsidiaryLedgerViewModel SrchSubLedge = new SearchSubsidiaryLedgerViewModel();


            SrchSubLedge.ZoneGroupList = db.ZoneGroup.SqlQuery("SELECT * FROM ZoneGroups EXCEPT SELECT * FROM ZoneGroups WHERE ZoneGroupName = 'Super User'").ToList();


            return(View("ViewSubsidiaryLedger", SrchSubLedge));
        }
        // GET: ReportsMonthlyAging

        public ActionResult ViewMonthlyAging(FormCollection frm)
        {
            ApplicationDbContext context = new ApplicationDbContext();
            var    userid        = User.Identity.GetUserId();
            string ZoneGroupCode = context.Users.FirstOrDefault(n => n.Id == userid).ZoneGroup;
            SearchSubsidiaryLedgerViewModel ForBilling = new SearchSubsidiaryLedgerViewModel();

            //ForBillPeriod.BillingPeriodList = db.BillingPeriod.Where(x => x.groupCode == ZoneGroupCode).ToList();
            ForBilling.BCSAgingOutput = db.BCSAgingOutput.Select(x => x.BillOriginYear).Distinct().OrderBy(x => x).ToList();
            return(View("ViewMonthlyAging", ForBilling));
        }
Exemple #3
0
        public JsonResult GetAddress(string comp2)
        {
            try
            {
                SearchSubsidiaryLedgerViewModel searchadd = new SearchSubsidiaryLedgerViewModel();

                var code    = comp2.Split('-');
                var DevName = code[0];
                var EcoName = code[1];

                double compid = Convert.ToDouble(DevName);

                //  var zonez = db.Zone.FirstOrDefault(x => x.ZoneName == EcoName).ZoneCode;
                var address = db.Company.FirstOrDefault(x => x.CompanyID == compid).Address;
                return(Json(address));
            }
            catch (Exception ex) { }


            return(Json(null));
        }