Пример #1
0
        public IActionResult List(QueryPageUrlModel item)
        {
            using (var db = new DataContext(App.DbKey.Api))
            {
                var page = new PageModel();
                page.PageSize = item.PageSize == 0 ? 10 : item.PageSize;
                page.PageId   = item.PageId == 0 ? 1 : item.PageId;

                var param = new List <OracleParameter>();
                param.Add(new OracleParameter {
                    ParameterName = "Key", Value = item.Key
                });
                param.Add(new OracleParameter {
                    ParameterName = "Ip", Value = item.Ip
                });
                param.Add(new OracleParameter {
                    ParameterName = "Day", Value = item.Day.ToDate("yyyy-MM-dd").ToDate()
                });
                param.Add(new OracleParameter {
                    ParameterName = "Success", Value = item.Success
                });

                var info = FastMap.QueryPage(page, "Api.Log", param.ToArray(), db);

                return(PartialView("List", info));
            }
        }
Пример #2
0
        /// <summary>
        /// 完整性检查列表
        /// </summary>
        /// <param name="DpetID">科室</param>
        /// <param name="Start">出院开始时间</param>
        /// <param name="Stop">出院结束时间</param>
        /// <param name="Zyh">病人ID或病案号(健康卡号)</param>
        /// <param name="Name">病人姓名</param>
        /// <param name="page">当前页</param>
        /// <param name="limit">每页几条</param>
        /// <returns></returns>
        public ActionResult MedicalRecordCheckList(string DpetID, string Start, string Stop, string Zyh, string Name, int page, int limit)
        {
            using (var db = new DataContext(AppEmr.DbConst.EmrDb))
            {
                var param = new List <OracleParameter>();
                param.Add(new OracleParameter {
                    ParameterName = "DpetID", Value = DpetID
                });
                param.Add(new OracleParameter {
                    ParameterName = "LeaveTimeStart", Value = Start
                });
                param.Add(new OracleParameter {
                    ParameterName = "LeaveTimeStop", Value = Stop
                });
                param.Add(new OracleParameter {
                    ParameterName = "Zyh", Value = Zyh
                });
                param.Add(new OracleParameter {
                    ParameterName = "Name", Value = Name
                });

                //如果page为0 输出所有的数据
                if (page == 0 && limit == 0)
                {
                    var list = FastMap.Query("Inpatient.MedicalRecordCheck.List", param.ToArray(), db);
                    return(Json(new { code = 0, data = list, count = list.Count }));
                }
                //分页
                var pageModel = new PageModel();
                pageModel.PageId   = page == 0 ? 1 : page;
                pageModel.PageSize = limit == 0 ? 10 : limit;
                var pageInfo = FastMap.QueryPage(pageModel, "Inpatient.MedicalRecordCheck.List", param.ToArray(), db);
                return(Json(new { code = 0, data = pageInfo.list, count = pageInfo.pModel.TotalRecord }));
            }
        }
Пример #3
0
        public IActionResult DownList(QueryPageUrlModel item)
        {
            using (var db = new DataContext(App.DbKey.Api))
            {
                var page = new PageModel();
                page.PageSize = item.PageSize == 0 ? 10 : item.PageSize;
                page.PageId   = item.PageId == 0 ? 1 : item.PageId;
                var info = new PageResult();

                if (!string.IsNullOrEmpty(item.Key))
                {
                    var param = new List <OracleParameter>();
                    param.Add(new OracleParameter {
                        ParameterName = "Key", Value = item.Key.ToUpper()
                    });
                    info = FastMap.QueryPage(page, "Api.DownUrl", param.ToArray(), db);
                }
                else
                {
                    info.list = new List <Dictionary <string, object> >();
                }

                //是否显示下游表单
                if (item.Success == "1" && info.list.Count > 0)
                {
                    info.list.ForEach(a => a.Add("IsShowForm", item.Success));
                }

                return(PartialView("DownList", info));
            }
        }
Пример #4
0
        /// <summary>
        /// 统计列表
        /// </summary>
        /// <param name="DpetID">科室id</param>
        /// <param name="Start">开始时间</param>
        /// <param name="Stop">结束时间</param>
        /// <param name="page">当前页</param>
        /// <param name="limit">每页几条</param>
        /// <returns></returns>
        public ActionResult GetStatisticsList(string DpetID, string Start, string Stop, int page, int limit)
        {
            using (var db = new DataContext(AppEmr.DbConst.EmrDb))
            {
                var param = new List <OracleParameter>();
                param.Add(new OracleParameter {
                    ParameterName = "DeptID", Value = DpetID
                });
                param.Add(new OracleParameter {
                    ParameterName = "Start", Value = Start
                });
                param.Add(new OracleParameter {
                    ParameterName = "Stop", Value = Stop
                });


                //如果page为0 输出所有的数据
                if (page == 0 && limit == 0)
                {
                    var list = FastMap.Query("Dept.KeepWardLog.List", param.ToArray(), db);
                    return(Json(new { code = 0, data = list, count = list.Count }));
                }

                //分页
                var pageModel = new PageModel();
                pageModel.PageId   = page == 0 ? 1 : page;
                pageModel.PageSize = limit == 0 ? 10 : limit;
                var pageInfo = FastMap.QueryPage(pageModel, "Dept.KeepWardLog.List", param.ToArray(), db);
                return(Json(new { code = 0, data = pageInfo.list, count = pageInfo.pModel.TotalRecord }));
            }
        }
Пример #5
0
        public IActionResult UrlList(QueryPageUrlModel item)
        {
            using (var db = new DataContext(App.DbKey.Api))
            {
                var page = new PageModel();
                page.PageSize = item.PageSize == 0 ? 10 : item.PageSize;
                page.PageId   = item.PageId == 0 ? 1 : item.PageId;

                var param = new List <OracleParameter>();
                param.Add(new OracleParameter {
                    ParameterName = "Key", Value = item.Key
                });
                var info = FastMap.QueryPage(page, "Api.Url", param.ToArray(), db);

                return(PartialView("UrlList", info));
            }
        }
Пример #6
0
        public ActionResult GetAllUser(int page, int limit, string MyOrganId, string keyword)
        {
            var param = new List <OracleParameter>();

            param.Add(new OracleParameter {
                ParameterName = "OrganId", Value = MyOrganId
            });
            param.Add(new OracleParameter {
                ParameterName = "UserName", Value = keyword
            });

            var pageModel = new PageModel();

            pageModel.PageId   = page == 0 ? 1 : page;
            pageModel.PageSize = limit == 0 ? 10 : limit;

            var pageInfo = FastMap.QueryPage(pageModel, "User.List", param.ToArray(), null, AppEmr.DbConst.EmrDb);

            return(Json(new { code = 0, data = pageInfo.list, count = pageInfo.pModel.TotalRecord }));
        }