コード例 #1
0
        /// <summary>
        /// 绑定分点列表
        /// </summary>
        private void BindGridLabTo() //分点列表
        {
            try
            {
                //分页查询条件
                PageUtil  pageUtil = new PageUtil(gdLabItem.PageIndex, gdLabItem.PageSize);
                Hashtable ht1      = new Hashtable();
                //ht1.Add("Userid", DictUserId);
                ht1.Add("pageStart", pageUtil.GetPageStartNum()); //pageUtil.GetPageStartNum()
                ht1.Add("pageEnd", pageUtil.GetPageEndNum());     // pageUtil.GetPageEndNum()
                //设置总项数
                gdLabItem.RecordCount = new DictlabService().GetDictlabPageLstCount(ht1);
                gdLabItem.DataSource  = new DictlabService().GetDictlabPageLst(ht1);

                List <Dictlabdept> dictlabdep = new DictlabdeptService().GetDictlabdeptPageLstUser(ht1).ToList();
                //double userId = 0;
                //if (gvList.SelectedRowIndexArray.Length > 0)
                //{
                //    object[] objValue = gvList.DataKeys[gvList.SelectedRowIndexArray[0]];
                //    userId = TypeParse.StrToDouble(objValue[0], 0);
                //}

                //全部列表
                List <Dictlab> labLst = new DictlabService().GetDictlabPageLst(ht1).ToList <Dictlab>();
                Hashtable      ht2    = new Hashtable();
                ht2.Add("Userid", DictUserId);
                ht2.Add("pageStart", pageUtil.GetPageStartNum());
                ht2.Add("pageEnd", pageUtil.GetPageEndNum());
                IList <Dictuserandlab> dictlabList = new DictuserlabService().GetDictuserandlabPageLst(ht2);
                gdLabItem.DataBind();
                int[] labArray = new int[dictlabList.Count];
                if (dictlabList.Count != 0)
                {
                    int index = 0;
                    foreach (Dictuserandlab item in dictlabList)
                    {
                        labArray[index] = labLst.IndexOf(labLst.Find(lab => lab.Dictlabid == item.Dictlabid));
                        index++;
                    }
                    gdLabItem.SelectedRowIndexArray = labArray;
                }
                else
                {
                    gdLabItem.SelectedRowIndexArray = new int[] { };
                }
            }
            catch (Exception ex)
            {
                MessageBoxShow(ex.Message, MessageBoxIcon.Error);
            }
        }
コード例 #2
0
 private void BindGrid()
 {
     try
     {
         //分页查询条件
         PageUtil  pageUtil = new PageUtil(gvList.PageIndex, gvList.PageSize);
         Hashtable ht1      = new Hashtable();
         ht1.Add("strKey", Dp_Bingin.Text.ToString() == "" ? null : Dp_Bingin.Text);
         ht1.Add("endDate", this.DatePicker3.Text.ToString() == "" ? null : this.DatePicker3.SelectedDate.Value.AddDays(1).ToShortDateString());
         ht1.Add("pageStart", pageUtil.GetPageStartNum());
         ht1.Add("pageEnd", pageUtil.GetPageEndNum());
         ht1.Add("productid", dropProducts.SelectedValue);
         ht1.Add("active", dropStatus.SelectedValue);
         ht1.Add("dictsubcompanyid", dropSubCompany.SelectedValue);
         ht1.Add("Dictcustomerid", CustomerId);
         //设置总项数
         gvList.RecordCount = cs.GetDictcustomerdiscountedPageLstCount(ht1);
         gvList.DataSource  = cs.GetDictcustomerdiscountedPageDt(ht1);
         gvList.DataBind();
     }
     catch (Exception ex)
     {
         MessageBoxShow(ex.Message, MessageBoxIcon.Error);
     }
 }
コード例 #3
0
        private void BindGrid(string strid)
        {
            Dicttestitem item = new Dicttestitem();

            if (ViewState["TestItemID"] != null)
            {
                double?id = Convert.ToDouble(ViewState["TestItemID"]);
                item = testitemservice.SelectDicttestitemByDicttestitemid(id);
            }
            //分页查询条件
            PageUtil  pageUtil = new PageUtil(gdGroupNotIncludeTestItem.PageIndex, gdGroupNotIncludeTestItem.PageSize);
            Hashtable ht1      = new Hashtable();

            ht1.Add("strKey", btnSearchNoIn.Text.Trim() == "" ? null : btnSearchNoIn.Text.Trim());
            ht1.Add("pageStart", pageUtil.GetPageStartNum());
            ht1.Add("pageEnd", pageUtil.GetPageEndNum());
            ht1.Add("testitemid", item.Dicttestitemid);
            ht1.Add("strtestitemid", strid);
            //strtestitemid
            //设置总项数
            gdGroupNotIncludeTestItem.RecordCount = testitemservice.GetDicttestgroupPageLstCount(ht1);
            List <Dicttestitem> listNotIn = testitemservice.GetDicttestgroupPageLst(ht1);

            gdGroupNotIncludeTestItem.DataSource = listNotIn;
            gdGroupNotIncludeTestItem.DataBind();
        }
コード例 #4
0
        /// <summary>
        /// 取得查询参数
        /// </summary>
        /// <returns></returns>
        Hashtable GetParm()
        {
            Hashtable _parameterCache = new Hashtable();

            //复查时间
            _parameterCache.Add("StartDate", dpFrom.SelectedDate.Value.ToString("yyyy-MM-dd"));
            _parameterCache.Add("EndDate", dpTo.SelectedDate.Value.AddDays(1).ToString("yyyy-MM-dd"));
            if (dropDictLab.SelectedText.Length > 0) //分点选择
            {
                _parameterCache.Add("dropDictLab", dropDictLab.SelectedValue);
            }
            else
            {
                _parameterCache.Add("dropDictLab", null);
            }
            //跟进状态
            if (dropStatus.SelectedText != "全部")
            {
                _parameterCache.Add("reviewstate", dropStatus.SelectedValue);
            }
            else
            {
                _parameterCache.Add("reviewstate", null);
            }
            PageUtil pageUtil = new PageUtil(gdOrders.PageIndex, gdOrders.PageSize);

            _parameterCache.Add("pageStart", pageUtil.GetPageStartNum());
            _parameterCache.Add("pageEnd", pageUtil.GetPageEndNum());
            return(_parameterCache);
        }
コード例 #5
0
        //查询结果绑定
        private void BindData()
        {
            Hashtable ht = new Hashtable();

            if (string.IsNullOrWhiteSpace(datebegin.Text) || string.IsNullOrWhiteSpace(dateend.Text))
            {
                MessageBoxShow("请输入开始时间及结束时间查询!", MessageBoxIcon.Information);
                return;
            }
            PageUtil pageUtil = new PageUtil(GridOrders.PageIndex, GridOrders.PageSize);

            ht["DateStart"] = datebegin.Text;
            ht["DateEnd"]   = Convert.ToDateTime(dateend.Text).AddDays(1).ToString("yyyy-MM-dd");
            if (DropDictLab.SelectedValue == "0")
            {
                ht["labid"] = Userinfo.joinLabidstr;
            }
            else
            {
                ht["labid"] = DropDictLab.SelectedValue;
            }
            ht["realname"]   = tbxName.Text = TextUtility.ReplaceText(tbxName.Text);
            ht["ordernum"]   = tbxOrderNum.Text;
            ht["status"]     = dropStatus.SelectedIndex == 0 ? null : dropStatus.SelectedValue;
            ht["customerid"] = DropCustomer.SelectedValue == "-1" ? null : DropCustomer.SelectedValue;
            ht["iscancel"]   = DropIScancel.SelectedIndex == 0 ? null : DropIScancel.SelectedValue;
            ht["pageStart"]  = pageUtil.GetPageStartNum();
            ht["pageEnd"]    = pageUtil.GetPageEndNum();

            GridOrders.RecordCount = mamagement.GetManagementOrdersCount(ht);
            GridOrders.DataSource  = mamagement.GetManagementOrders(ht);
            GridOrders.DataBind();
        }
コード例 #6
0
        //数据绑定
        private void BindData()
        {
            try
            {
                Hashtable ht       = new Hashtable();
                PageUtil  pageUtil = new PageUtil(gvList.PageIndex, gvList.PageSize);
                ht["DateStart"]  = dtpStart.Text;
                ht["DateEnd"]    = Convert.ToDateTime(dtpEnd.Text).AddDays(1).ToString("yyyy-MM-dd");
                ht["labid"]      = dropLab.SelectedValue;
                ht["realname"]   = tbxName.Text = TextUtility.ReplaceText(tbxName.Text);
                ht["customerid"] = dropCustomer.SelectedValue == "-1" ? null : dropCustomer.SelectedValue;
                ht["ordernum"]   = TextUtility.ReplaceText(tbxordernum.Text);
                ht["sex"]        = null;
                ht["iscancel"]   = "0";
                ht["iolis"]      = dropIOLIS.SelectedValue == "-1" ? null : dropIOLIS.SelectedValue;
                ht["status"]     = dropStatus.SelectedValue == "-1" ? null : dropStatus.SelectedValue;
                ht["pageStart"]  = pageUtil.GetPageStartNum();
                ht["pageEnd"]    = pageUtil.GetPageEndNum();

                gvList.RecordCount = mamagement.GetManagementOrdersCount(ht);
                gvList.DataSource  = mamagement.GetManagementOrders(ht);
                gvList.DataBind();
            }
            catch (Exception ex)
            {
                MessageBoxShow(ex.Message, MessageBoxIcon.Error);
            }
        }
コード例 #7
0
        /// <summary>
        /// 绑定列表数据
        /// </summary>
        private void BindData()
        {
            try
            {
                //分页查询条件
                PageUtil  pageUtil = new PageUtil(gvList.PageIndex, gvList.PageSize);
                Hashtable ht1      = new Hashtable();
                ht1.Add("pageStart", pageUtil.GetPageStartNum());
                ht1.Add("pageEnd", pageUtil.GetPageEndNum());
                ht1.Add("Dictlabid", dropDictlab.SelectedValue);
                ht1.Add("IsActive", dropStatus.SelectedValue);
                ht1.Add("strKey", TextUtility.ReplaceText(txtStrKey.Text.Trim()) == "" ? null : TextUtility.ReplaceText(txtStrKey.Text.Trim()));

                DataTable dt    = null;
                int       count = 0;
                if (raoType.SelectedValue == "0")
                {
                    dt    = dictCustomerService.GetDictcustomerAuditList(ht1);
                    count = dictCustomerService.GetDictcustomerAuditListCount(ht1);
                }
                else
                {
                    dt    = dictCustomerService.GetDictcustomerdiscountedAuditList(ht1);
                    count = dictCustomerService.GetDictcustomerdiscountedAuditListCount(ht1);
                }
                gvList.DataSource  = dt;
                gvList.RecordCount = count;
                gvList.DataBind();
            }
            catch (Exception ex)
            {
                MessageBoxShow(ex.Message, MessageBoxIcon.Error);
            }
        }
コード例 #8
0
        //绑定数据
        private void BindDate()
        {
            Hashtable ht       = new Hashtable();
            PageUtil  pageutil = new PageUtil(gridList.PageIndex, gridList.PageSize);
            double    userid   = Userinfo.userId;

            ht["userid"] = userid;
            string uname = txtName.Text.ToString();

            ht["uname"] = uname;
            string status = dpStatus.SelectedValue;

            ht["status"] = status;
            string dateStart = string.Empty;

            if (!string.IsNullOrEmpty(TimeStart.SelectedDate.ToString()))
            {
                dateStart = Convert.ToDateTime(TimeStart.SelectedDate.ToString()).ToShortDateString();
            }
            string dateEnd = string.Empty;

            if (!string.IsNullOrEmpty(TimeEnd.SelectedDate.ToString()))
            {
                dateEnd = Convert.ToDateTime(TimeEnd.SelectedDate.Value.AddDays(1).ToString()).ToShortDateString();
            }
            ht["dateStart"]      = dateStart;
            ht["dateEnd"]        = dateEnd;
            ht["pagestart"]      = pageutil.GetPageStartNum();
            ht["pageend"]        = pageutil.GetPageEndNum();
            gridList.RecordCount = os.GetFinishOrdersListCount(ht, status);
            gridList.DataSource  = os.GetFinishOrdersList(ht, status);
            gridList.DataBind();
        }
コード例 #9
0
        /// <summary>
        /// 获取查询参数
        /// </summary>
        /// <returns></returns>
        private Hashtable GetParm()
        {
            Hashtable _parameterCache = new Hashtable();

            #region 分点
            if (dropDictLab.SelectedValue != "-1")
            {
                _parameterCache.Add("dropDictLab", dropDictLab.SelectedValue);
            }
            else
            {
                _parameterCache.Add("dropDictLab", null);
            }
            #endregion
            _parameterCache.Add("DropTransed", dropTransed.SelectedValue == "-1" ? null : dropTransed.SelectedValue == "0" ? "0 or TranSed is null" : dropTransed.SelectedValue);
            _parameterCache.Add("StartDate", ((DateTime)dpFrom.SelectedDate).ToString("yyyy-MM-dd"));
            _parameterCache.Add("EndDate", ((DateTime)dpTo.SelectedDate).AddDays(1).ToString("yyyy-MM-dd"));
            _parameterCache.Add("Dictcustomerid", dropDictcustomer.SelectedValue == "-1" ? null : dropDictcustomer.SelectedValue);

            if (tbStrKey.Text.Trim().Length > 0)
            {
                _parameterCache.Add("tbStrKey", TextUtility.ReplaceText(tbStrKey.Text));
            }
            else
            {
                _parameterCache.Add("tbStrKey", null);
            }
            PageUtil pageutil = new PageUtil(gdUploadPdfToSheQu.PageIndex, gdUploadPdfToSheQu.PageSize);
            _parameterCache.Add("PageStart", pageutil.GetPageStartNum());
            _parameterCache.Add("PageEnd", pageutil.GetPageEndNum());
            return(_parameterCache);
        }
コード例 #10
0
ファイル: FrmStat.aspx.cs プロジェクト: bigbigwood/daan
        /// <summary>
        /// 绑定查询列表数据
        /// </summary>
        private void BindData()
        {
            Hashtable ht       = new Hashtable();
            PageUtil  pageUtil = new PageUtil(GridAcconding.PageIndex, GridAcconding.PageSize);

            ht.Add("DateStart", Dp_BeginDate.Text == "" ? null : Dp_BeginDate.Text);
            ht.Add("DateEnd", Dp_EndDate.Text == "" ? null : Dp_EndDate.SelectedDate.Value.AddDays(1).ToString("yyyy-MM-dd"));
            if (dropDictLab.SelectedValue == "-1")
            {
                ht.Add("labid", Userinfo.joinLabidstr);
            }
            else
            {
                ht.Add("labid", dropDictLab.SelectedValue);
            }
            ht.Add("province", dropProvice.SelectedValue);
            ht.Add("pageStart", pageUtil.GetPageStartNum());
            ht.Add("pageEnd", pageUtil.GetPageEndNum());
            ht.Add("Section", txtSection.Text.Trim());
            if (DropCustomer.SelectedValue != "-1")
            {
                ht.Add("customername", DropCustomer.SelectedValue);
            }
            IDictionary <string, object> dic = GetDate(ddlStatus.SelectedValue, ht);

            GridAcconding.RecordCount = Convert.ToInt32(dic["RecordCount"].ToString());
            GridAcconding.DataSource  = (DataTable)dic["DataSource"];
            GridAcconding.DataBind();
        }
コード例 #11
0
        /// <summary>
        /// 加载数据进gdDicttestitem表中
        /// </summary>
        void InitgdDicttestitem(string strKey)
        {
            //
            PageUtil pageUtil = new PageUtil(gdDicttestitem.PageIndex, gdDicttestitem.PageSize);
            int      start    = pageUtil.GetPageStartNum();
            int      end      = pageUtil.GetPageEndNum();
            //从缓存中取数据,取检验项目(dicttestitem)
            var TestItemList = loginservice.GetLoginDicttestitemList().Where(c => (int.Parse(c.Testtype) < 3));//项目字典表

            //TestItemList.Join(gdOrdernexttest.DataKeys[2],a=>a.Dicttestitemid,b=>double.Parse(b.ToString()),
            if (strKey.Length == 0)//不进行筛选数据时
            {
                gdDicttestitem.RecordCount = TestItemList.Count();
                gdDicttestitem.DataSource  = TestItemList.Skip(start).Take(end - start);
                gdDicttestitem.DataBind();
            }
            else
            {
                //有关键字时,根据项目名称,快捷录入码,英文名进行筛选
                var p = TestItemList.Where(c => (ConVertClass(c).Testname.Contains(tbStrKey.Text)) || (ConVertClass(c).Fastcode.Contains(tbStrKey.Text)) ||
                                           (ConVertClass(c).Engname.Contains(tbStrKey.Text)));
                gdDicttestitem.RecordCount = p.Count();
                gdDicttestitem.DataSource  = p.Skip(start - 1).Take(end - start + 1);
                gdDicttestitem.DataBind();
            }
        }
コード例 #12
0
        /// <summary>
        /// 绑定列表
        /// </summary>
        private void BindGrid()
        {
            try
            {
                //分页查询条件
                PageUtil  pageUtil = new PageUtil(gvList.PageIndex, gvList.PageSize);
                Hashtable ht1      = new Hashtable();
                ht1.Add("strKey", TextUtility.ReplaceText(btSearch.Text.Trim()) == "" ? null : TextUtility.ReplaceText(btSearch.Text.Trim()));
                ht1.Add("IsActive", chkActive.Checked ? "1" : "0");
                ht1.Add("pageStart", pageUtil.GetPageStartNum());
                ht1.Add("pageEnd", pageUtil.GetPageEndNum());
                ht1.Add("DictlabId", dictlabId);
                //设置总项数
                gvList.RecordCount = new DictlabandtestService().GetDictlabandtestPageLstCount(ht1);
                gvList.DataSource  = new DictlabandtestService().GetDictlabandtestPageLst(ht1);
                gvList.DataBind();

                txtTestItemName.Text                 = "";
                this.radlIsactive.SelectedValue      = "1";
                this.radlIssendouttest.SelectedValue = "0";
            }
            catch (Exception ex)
            {
                MessageBoxShow(ex.Message, MessageBoxIcon.Error);
            }
        }
コード例 #13
0
        /// <summary>
        /// 绑定诊断建议字典
        /// </summary>
        public void BindDiagnosis(List <Dictdiagnosis> diagnosisAll)
        {
            PageUtil pageUtil = new PageUtil(gdDiagnosis.PageIndex, gdDiagnosis.PageSize);
            int      start    = pageUtil.GetPageStartNum();
            int      end      = pageUtil.GetPageEndNum();

            gdDiagnosis.RecordCount = diagnosisAll.Count;
            gdDiagnosis.DataSource  = diagnosisAll.Skip(start - 1).Take(end - start + 1);
            gdDiagnosis.DataBind();
        }
コード例 #14
0
        //账单头信息分页
        protected void gvList_PageIndexChange(object sender, ExtAspNet.GridPageEventArgs e)
        {
            gvList.PageIndex = e.NewPageIndex;
            PageUtil  pageUtil = new PageUtil(gvList.PageIndex, gvList.PageSize);
            Hashtable ht       = (Hashtable)ViewState["sqlWhere"];

            ht["pageStart"] = pageUtil.GetPageStartNum();
            ht["pageEnd"]   = pageUtil.GetPageEndNum();
            BindData();
        }
コード例 #15
0
ファイル: BillOut.aspx.cs プロジェクト: bigbigwood/daan
        private Hashtable GetDetailSqlWhere(string billheadid)
        {
            PageUtil  pageUtil = new PageUtil(gvDetail.PageIndex, gvDetail.PageSize);
            Hashtable ht       = new Hashtable();

            ht["billheadid"] = billheadid;
            ht["pageStart"]  = pageUtil.GetPageStartNum();
            ht["pageEnd"]    = pageUtil.GetPageEndNum();
            return(ht);
        }
コード例 #16
0
        //导出
        protected void btnExport_Click(object sender, EventArgs e)
        {
            try
            {
                Hashtable ht       = new Hashtable();
                PageUtil  pageUtil = new PageUtil(GridOrders.PageIndex, GridOrders.PageSize);
                ht["DateStart"] = datebegin.Text;
                ht["DateEnd"]   = Convert.ToDateTime(dateend.Text).AddDays(1).ToString("yyyy-MM-dd");
                if (DropDictLab.SelectedValue == "0")
                {
                    ht["labid"] = Userinfo.joinLabidstr;
                }
                else
                {
                    ht["labid"] = DropDictLab.SelectedValue;
                }
                ht["realname"]   = tbxName.Text = TextUtility.ReplaceText(tbxName.Text);
                ht["ordernum"]   = tbxOrderNum.Text;
                ht["status"]     = dropStatus.SelectedIndex == 0 ? null : dropStatus.SelectedValue;
                ht["customerid"] = DropCustomer.SelectedValue == "-1" ? null : DropCustomer.SelectedValue;
                ht["iscancel"]   = DropIScancel.SelectedIndex == 0 ? null : DropIScancel.SelectedValue;
                ht["pageStart"]  = pageUtil.GetPageStartNum();
                ht["pageEnd"]    = pageUtil.GetPageEndNum();

                DataTable source = mamagement.GetSusManagementOrdersList(ht);
                if (source.Rows.Count == 0)
                {
                    MessageBoxShow("导出没有数据!");
                    return;
                }
                string     sheetname = DateTime.Now.ToString("yyyy-MM-dd");
                string     filename  = DateTime.Now.ToString("yyyyMMdd_hhmmss");
                SortedList sortlist  = new SortedList(new MySort());
                //sortlist.Add("Provincename", "省份");
                //sortlist.Add("Cityname", "城市");
                //sortlist.Add("Countyname", "地区");
                sortlist.Add("Barcode", "条码号");
                sortlist.Add("Realname", "姓名");
                sortlist.Add("Sex", "性别");
                sortlist.Add("Birthday", "出生年月");
                sortlist.Add("Mobile", "手机号码");
                sortlist.Add("Idnumber", "身份证号");
                sortlist.Add("Testcode", "项目1编号");
                sortlist.Add("Customername", "客户(门店名称)");
                sortlist.Add("Addres", "客户(门店)详细地址");
                ExportDataTableToExcel(source, filename, sheetname, sortlist);
            }
            catch (Exception)
            {
                MessageBoxShow("导出数据出错,请联系管理员!");
            }
        }
コード例 #17
0
        //查询结果绑定
        private void BindData()
        {
            //存储过滤条件
            Hashtable ht       = new Hashtable();
            PageUtil  pageUtil = new PageUtil(GridOrders.PageIndex, GridOrders.PageSize);

            ht["pageStart"] = pageUtil.GetPageStartNum();
            ht["pageEnd"]   = pageUtil.GetPageEndNum();

            GridOrders.RecordCount = os.GetOverdueOrdersCount();
            GridOrders.DataSource  = os.GetOverdueOrders(ht);
            GridOrders.DataBind();
        }
コード例 #18
0
        /// <summary>
        /// 绑定查询数据列表
        /// </summary>
        private void BindData()
        {
            PageUtil  pageUtil = new PageUtil(GridAcconding.PageIndex, GridAcconding.PageSize);
            Hashtable ht       = new Hashtable();

            ht.Add("accordingtype", DropAccordingType.SelectedValue);
            ht.Add("begindate", Dp_BeginDate.Text == "" ? null : Dp_BeginDate.Text);
            ht.Add("enddate", this.Dp_EndDate.Text == "" ? null : this.Dp_EndDate.SelectedDate.Value.AddDays(1).ToString("yyyy-MM-dd"));
            ht.Add("pageStart", pageUtil.GetPageStartNum());
            ht.Add("pageEnd", pageUtil.GetPageEndNum());

            GridAcconding.RecordCount = os.GetHPVTMAccondingInfosCount(ht);
            GridAcconding.DataSource  = os.GetHPVTMAccondingInfos(ht);
            GridAcconding.DataBind();
        }
コード例 #19
0
        private void BindBulkImportDetailItem()
        {
            PageUtil  pageUtil = new PageUtil(gdBulkImportDetailItem.PageIndex, gdBulkImportDetailItem.PageSize);
            Hashtable ht1      = new Hashtable();

            object[] keys = gdBulkImportManageItem.DataKeys[gdBulkImportManageItem.SelectedRowIndexArray[0]];
            ht1["Orderfileheaderid"] = keys[0];
            ht1["pageStart"]         = pageUtil.GetPageStartNum();
            ht1["pageEnd"]           = pageUtil.GetPageEndNum();

            gdBulkImportDetailItem.RecordCount = detailService.GetgdBulkImportDetailItemPageLstCount(ht1);
            DataTable dt = detailService.GetgdBulkImportDetailItemPageLst(ht1);

            gdBulkImportDetailItem.DataSource = dt;
            gdBulkImportDetailItem.DataBind();
        }
コード例 #20
0
        /// <summary>构造查询参数
        ///
        /// </summary>
        /// <returns></returns>
        private Hashtable getPara()
        {
            Hashtable ht = new Hashtable();

            ht["DateStart"] = datebegin.Text;
            ht["DateEnd"]   = Convert.ToDateTime(dateend.Text).AddDays(1).ToString("yyyy-MM-dd");
            if (DropDictLab.SelectedValue == "0")
            {
                ht["labid"] = Userinfo.joinLabidstr;
            }
            else
            {
                ht["labid"] = DropDictLab.SelectedValue;
            }
            ht["memberid"]     = null;
            ht["realname"]     = tbxName.Text = TextUtility.ReplaceText(tbxName.Text);
            ht["ordernum"]     = tbxOrderNum.Text;
            ht["status"]       = dropStatus.SelectedIndex == 0 ? null : dropStatus.SelectedValue;
            ht["customerid"]   = DropCustomer.SelectedValue == "-1" ? null : DropCustomer.SelectedValue;
            ht["customertype"] = null;
            ht["iscancel"]     = DropIScancel.SelectedIndex == 0 ? null : DropIScancel.SelectedValue;
            PageUtil pageUtil = new PageUtil(GridOrders.PageIndex, GridOrders.PageSize);

            ht["pageStart"] = pageUtil.GetPageStartNum();
            ht["pageEnd"]   = pageUtil.GetPageEndNum();

            if (dpSFrom.Text != "")
            {
                ht.Add("sdatestart", dpSFrom.SelectedDate.Value.ToString("yyyy-MM-dd"));
            }
            if (dpSTo.Text != "")
            {
                ht.Add("sdateend", dpSTo.SelectedDate.Value.AddDays(1).ToString("yyyy-MM-dd"));
            }
            if (dpProvince.SelectedValue != "-1")
            {
                ht.Add("province", dpProvince.SelectedText);
            }
            if (dpCity.SelectedValue != "-1")
            {
                ht.Add("city", dpCity.SelectedText);
            }
            ht.Add("area", string.IsNullOrEmpty(tbxArea.Text.Trim()) ? null : TextUtility.ReplaceText(tbxArea.Text.Trim()));
            ht.Add("section", string.IsNullOrEmpty(tbxSection.Text.Trim()) ? null : TextUtility.ReplaceText(tbxSection.Text.Trim()));
            ht.Add("batchnumber", string.IsNullOrEmpty(tbxBatchNumber.Text.Trim()) ? null : TextUtility.ReplaceText(tbxBatchNumber.Text.Trim()));
            return(ht);
        }
コード例 #21
0
ファイル: Sms.aspx.cs プロジェクト: bigbigwood/daan
        /// <summary>绑定列表数据
        ///
        /// </summary>
        private void BindData()
        {
            PageUtil  pageUtil = new PageUtil(gvList.PageIndex, gvList.PageSize);
            Hashtable ht       = new Hashtable();

            ht.Add("ordernum", txtOrderNum.Text);
            ht.Add("labid", dropDictLab.SelectedValue);
            ht.Add("status", ddlStatus.SelectedValue);
            ht.Add("customerid", DropCustomer.SelectedValue);
            ht.Add("DateStart", datebegin.Text);
            ht.Add("DateEnd", Convert.ToDateTime(dateend.Text).AddDays(1).ToString("yyyy-MM-dd"));
            ht.Add("pageStart", pageUtil.GetPageStartNum());
            ht.Add("pageEnd", pageUtil.GetPageEndNum());
            gvList.RecordCount = orderService.WaitSendSmsUsersCount(ht);
            gvList.DataSource  = orderService.WaitSendSmsUsers(ht);
            gvList.DataBind();
        }
コード例 #22
0
        //页面加载绑定数据
        private void BindData(string ordernum)
        {
            PageUtil pageUtil = new PageUtil(gvList.PageIndex, gvList.PageSize);

            Hashtable ht = new Hashtable();

            ht["ordernum"]  = ordernum;
            ht["pageStart"] = pageUtil.GetPageStartNum();
            ht["pageEnd"]   = pageUtil.GetPageEndNum();

            OperationlogService  logservice = new OperationlogService();
            IList <Operationlog> logList    = logservice.SelectOperationlogByOrdernum(ht);

            gvList.RecordCount = logservice.SelectOperationlogCountByOrdernum(ordernum);
            gvList.DataSource  = logList;
            gvList.DataBind();
        }
コード例 #23
0
 //绑定列表数据
 private void BindDate()
 {
     try
     {
         PageUtil  pageUtil = new PageUtil(gridStat.PageIndex, gridStat.PageSize);
         Hashtable ht       = new Hashtable();
         ht.Add("searchid", dropSearch.SelectedValue);
         ht.Add("pageStart", pageUtil.GetPageStartNum());
         ht.Add("pageEnd", pageUtil.GetPageEndNum());
         gridStat.RecordCount = os.SelectTMStatSearchResultListCount(ht);
         gridStat.DataSource  = os.SelectTMStatSearchResultList(ht);
         gridStat.DataBind();
     }
     catch (Exception e)
     {
         MessageBoxShow("查询数据出错:" + e.Message);
     }
 }
コード例 #24
0
        protected void Binder()
        {
            PageUtil  pageUtil = new PageUtil(GridOrders.PageIndex, GridOrders.PageSize);
            Hashtable ht       = new Hashtable();

            ht.Add("Disposestate", DropState.SelectedValue);
            ht.Add("OrderNum", TextUtility.ReplaceText(txtOrderNum.Text));
            ht.Add("BarCode", TextUtility.ReplaceText(txtBarCode.Text));
            ht.Add("startDate", datebegin.Text.ToString() == "" ? null : datebegin.Text.ToString());
            ht.Add("endDate", dateend.Text.ToString() == "" ? null : dateend.Text.ToString());
            ht.Add("pageStart", pageUtil.GetPageStartNum());
            ht.Add("pageEnd", pageUtil.GetPageEndNum());

            //设置总项数
            GridOrders.RecordCount = service.SelectOrderExceptionCount(ht);
            GridOrders.DataSource  = service.SelectOrderExceptionLst(ht);
            GridOrders.DataBind();
        }
コード例 #25
0
ファイル: AnaResult.aspx.cs プロジェクト: bigbigwood/daan
        private void Binder()
        {
            PageUtil  pageUtil = new PageUtil(gvOrderUser.PageIndex, gvOrderUser.PageSize);
            Hashtable ht1      = new Hashtable();

            ht1.Add("nState", ddlStatus.SelectedValue == "-1" ? "5,10" : ddlStatus.SelectedValue);
            if (ddlDictlab.SelectedValue == "-1")
            {
                ht1.Add("nDictlabid", Userinfo.joinLabidstr);
            }
            else
            {
                ht1.Add("nDictlabid", ddlDictlab.SelectedValue == "-1" ? null : ddlDictlab.SelectedValue);
            }
            ht1.Add("strKey", TextUtility.ReplaceText(txtSearch.Text) == "" ? null : TextUtility.ReplaceText(txtSearch.Text));
            ht1.Add("startDate", dpStart.Text.ToString() == "" ? null : dpStart.Text.ToString());
            ht1.Add("endDate", dpEnd.Text.ToString() == "" ? null : dpEnd.Text.ToString());
            ht1.Add("pageStart", pageUtil.GetPageStartNum());
            ht1.Add("pageEnd", pageUtil.GetPageEndNum());

            //设置总项数
            gvOrderUser.RecordCount = orderTestService.GetOrderMemberPageLstCount(ht1);

            DataSet ds = orderTestService.GetOrderMemberPageLst(ht1);

            gvOrderUser.DataSource = ds.Tables[0].DefaultView;
            gvOrderUser.DataBind();

            #region 初始化
            // 科室检查结果列表
            List <Ordertest> tempOrderTestLst = new List <Ordertest>();
            gvOrderTest.DataSource = tempOrderTestLst;
            gvOrderTest.DataBind();

            //绑定科室小结列表
            gvOrderLabdeptResult.DataSource = OrderlabdeptresultData("0");
            gvOrderLabdeptResult.DataBind();

            //绑定诊断建议列表
            gvSuggestion.DataSource = OrderdiagnosisData("0");
            gvSuggestion.DataBind();
            gvOrderUser.SelectedRowIndexArray = new int[] { };
            #endregion
        }
コード例 #26
0
        protected void btnSearch_Click(object sender, EventArgs e)
        {
            gvList.PageIndex = 0;
            PageUtil  pageUtil = new PageUtil(gvList.PageIndex, gvList.PageSize);
            Hashtable ht       = new Hashtable();

            ht["status"]    = dropStatus.SelectedValue.ToString() == "-1" ? null : dropStatus.SelectedValue.ToString();
            ht["startDate"] = dtpStart.SelectedDate.HasValue == true?dtpStart.SelectedDate.Value.ToShortDateString() : null;

            ht["endDate"] = dtpEnd.SelectedDate.HasValue == true?dtpEnd.SelectedDate.Value.AddDays(1).ToShortDateString() : null;

            ht["dictlabid"] = dropLab.SelectedValue.ToString() == "-1" ? null : dropLab.SelectedValue.ToString();
            ht["pageStart"] = pageUtil.GetPageStartNum();
            ht["pageEnd"]   = pageUtil.GetPageEndNum();

            ViewState["sqlWhere"] = ht;
            BindData();
            BindDataCount();
            ViewState["dictlabname"] = dropLab.SelectedText;
        }
コード例 #27
0
 private void BindGrid()
 {
     try
     {
         //分页查询条件
         PageUtil  pageUtil = new PageUtil(gvList.PageIndex, gvList.PageSize);
         Hashtable ht1      = new Hashtable();
         ht1.Add("strKey", TextUtility.ReplaceText(btSearch.Text.Trim()) == "" ? null : TextUtility.ReplaceText(btSearch.Text.Trim()));
         ht1.Add("pageStart", pageUtil.GetPageStartNum());
         ht1.Add("pageEnd", pageUtil.GetPageEndNum());
         //设置总项数
         gvList.RecordCount = new DictfastCommentService().GetDictfastcommentLstCount(ht1);
         gvList.DataSource  = new DictfastCommentService().GetDictfastcommentPageLst(ht1);
         gvList.DataBind();
     }
     catch (Exception ex)
     {
         MessageBoxShow(ex.Message, MessageBoxIcon.Error);
     }
 }
コード例 #28
0
        /// <summary>
        /// 绑定列表
        /// </summary>
        private void BindGrid()
        {
            //分页查询条件
            PageUtil  pageUtil = new PageUtil(gvList.PageIndex, gvList.PageSize);
            Hashtable ht       = new Hashtable();

            ht["pageStart"] = pageUtil.GetPageStartNum();
            ht["pageEnd"]   = pageUtil.GetPageEndNum();
            ht["Start"]     = Start.Text;
            ht["End"]       = Convert.ToDateTime(End.Text).AddDays(1).ToString("yyyy-MM-dd");
            ht.Add("Dictcustomerid", Dictcustomerid.SelectedValue == "-1" ? null : Dictcustomerid.SelectedValue);
            ht.Add("Dicttestitemid", Dicttestitemid.SelectedValue == "-1" ? null : Dicttestitemid.SelectedValue);
            ht.Add("Instrumentsbarcode", Instrumentsbarcode.Text.Trim());
            ht.Add("Barcode", Barcode.Text.Trim());


            gvList.RecordCount = hpvService.GetHpvinstrumentsPageLstCountNew(ht);
            gvList.DataSource  = hpvService.GetHpvinstrumentsByWhereNew(ht);
            gvList.DataBind();
        }
コード例 #29
0
        private void BindGrid(string dictlibraryid)
        {
            //分页查询条件
            PageUtil  pageUtil = new PageUtil(gdFormularName.PageIndex, gdFormularName.PageSize);
            Hashtable ht1      = new Hashtable();

            ht1.Add("strKey", TextUtility.ReplaceText(ttbSearch.Text.Trim()) == "" ? null : TextUtility.ReplaceText(ttbSearch.Text.Trim()));
            ht1.Add("pageStart", pageUtil.GetPageStartNum());
            ht1.Add("pageEnd", pageUtil.GetPageEndNum());
            ht1.Add("Dictlabdeptid", dictlibraryid);
            ht1.Add("Dictlabid", ddlDictlabSearch.SelectedValue);
            //设置总项数
            gdFormularName.RecordCount = service.GetDictruleformularPageLstCount(ht1);
            List <Dictruleformular> list = service.GetDictruleformularPageLst(ht1);

            gdFormularName.DataSource = list;
            gdFormularName.DataBind();

            AddDictruleformular();
        }
コード例 #30
0
ファイル: DictTestItems.aspx.cs プロジェクト: bigbigwood/daan
        private void BindGrid(string testtype, string dictlabid)
        {
            //分页查询条件
            PageUtil  pageUtil = new PageUtil(gdTestItem.PageIndex, gdTestItem.PageSize);
            Hashtable ht1      = new Hashtable();

            ht1.Add("strKey", TextUtility.ReplaceText(ttbSearch.Text.Trim()) == "" ? null : TextUtility.ReplaceText(ttbSearch.Text.Trim()));
            ht1.Add("pageStart", pageUtil.GetPageStartNum());
            ht1.Add("pageEnd", pageUtil.GetPageEndNum());
            ht1.Add("testtype", testtype);
            ht1.Add("Dictlabdeptid", dictlabid);
            ht1.Add("IsActive", chkActive.Checked ? "1" : "0");

            //strtestitemid
            //设置总项数
            gdTestItem.RecordCount = testitemservice.GetDictTestItemPageLstCount(ht1);
            List <Dicttestitem> list = testitemservice.GetDictTestItemPageLst(ht1);

            gdTestItem.DataSource = list;
            gdTestItem.DataBind();
        }