Example #1
0
 /// <summary>
 /// Returns a list of MissingInstallmentDecreaseVw objects
 /// </summary>
 /// <returns></returns>
 public ActionResult Index(MissingInstallmentDecreaseVwViewModel Model)
 {
     if (Model.Filter.HasCriteria)
     {
         Db db = new Db(DbServices.ConnectionString);
         Model.List = MissingInstallmentDecreaseVwServices.Get(Model.Filter, db);
     }
     else
     {
         Model.List = new List <MissingInstallmentDecreaseVw>();
     }
     return(View(Model));
 }
Example #2
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        public ActionResult Details(Nullable <int> employee)
        {
            if (employee == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            MissingInstallmentDecreaseVwViewModel missingInstallmentDecreaseVwViewModel = new MissingInstallmentDecreaseVwViewModel();

            Db db = new Db(DbServices.ConnectionString);

            // missingInstallmentDecreaseVwViewModel.Instance = MissingInstallmentDecreaseVwServices.Get(employee.Value, db);
            missingInstallmentDecreaseVwViewModel.Instance = MissingInstallmentDecreaseVwServices.GetChildren(employee.Value, db);
            if (missingInstallmentDecreaseVwViewModel.Instance == null)
            {
                return(HttpNotFound());
            }


            return(View(missingInstallmentDecreaseVwViewModel));
        }