Exemple #1
0
 public object Get(JObject req)
 {
     using (var db = new LUOLAI1401Context())
     {
         db.Database.Connection.Open();
         try {
             var cmd = db.Database.Connection.CreateCommand();
             cmd.CommandType = System.Data.CommandType.StoredProcedure;
             cmd.CommandText = "proc_SearchList";
             cmd.Parameters.Add(new SqlParameter("@tableName", "KZ_cpfbmx"));
             cmd.Parameters.Add(new SqlParameter("@fieldNames", "KZ_cpfbmx.省份 AS 省份,KZ_cpfbmx.城市 AS 城市,KZ_cpfbmx.终端类型 AS 终端类型,KZ_cpfbmx.客户名称 AS 客户名称,KZ_cpfbmx.库存量 AS 库存量,KZ_cpfbmx.产品 AS 产品,KZ_cpfbmx.规格 AS 规格"));
             cmd.Parameters.Add(new SqlParameter("@fieldSort", "省份"));
             var sbCondition = new StringBuilder();
             sbCondition.Append(string.Format("{0}{1}{2}{3}{4}", "((CompCode='", (System.Web.HttpContext.Current.Session["sys_user"] as sys_user).CompCode, "') or ('", (System.Web.HttpContext.Current.Session["sys_user"] as sys_user).UserCode, "'='super'))"));
             sbCondition.Append(" AND ");
             SerachCondition.TextBox(sbCondition, "省份", "省份", "varchar");
             SerachCondition.TextBox(sbCondition, "城市", "城市", "varchar");
             SerachCondition.Dropdown(sbCondition, "终端类型", "终端类型", "varchar");
             SerachCondition.TextBox(sbCondition, "产品", "产品", "varchar");
             if (sbCondition.Length > 5)
             {
                 sbCondition.Length -= 5;
                 cmd.Parameters.Add(new SqlParameter("@condition", sbCondition.ToString()));
             }
             if (HttpContext.Current.Request.Get("_report_") == "1")
             {
                 // 报表请求条件合成
                 return(sbCondition.ToString());
             }
             SqlParameter rowTotalParameter = null;
             int          rowTotal          = 0;
             int.TryParse(HttpContext.Current.Request.Get("total"), out rowTotal);
             var rq = new PageRequest();
             if (rq.Page.HasValue)
             {
                 var pageSize = rq.Rows.HasValue ? rq.Rows.Value : 20;
                 var rowStart = (rq.Page.Value - 1) * pageSize + 1;
                 var rowEnd   = rq.Page.Value * pageSize;
                 cmd.Parameters.Add(new SqlParameter("@rowStart", rowStart));
                 cmd.Parameters.Add(new SqlParameter("@rowEnd", rowEnd));
                 if (rowStart == 1)
                 {
                     cmd.Parameters.Add(rowTotalParameter = new SqlParameter("@rowTotal", System.Data.SqlDbType.Int, 8, System.Data.ParameterDirection.Output, true, 0, 0, null, System.Data.DataRowVersion.Default, 0));
                 }
             }
             string jsonArrayString = null;
             using (var reader = cmd.ExecuteReader())
             {
                 jsonArrayString = reader.ToJsonArrayString();
             }
             if (rowTotalParameter != null)
             {
                 rowTotal = (int)rowTotalParameter.Value;
             }
             return(JObject.Parse("{rows:" + jsonArrayString + ", total:" + rowTotal + "}"));
         } finally {
             db.Database.Connection.Close();
         }
     }
 }
Exemple #2
0
 public object Get(JObject req)
 {
     using (var db = new LUOLAI1401Context())
     {
         db.Database.Connection.Open();
         try {
             var cmd = db.Database.Connection.CreateCommand();
             cmd.CommandType = System.Data.CommandType.StoredProcedure;
             cmd.CommandText = "proc_SearchList";
             cmd.Parameters.Add(new SqlParameter("@tableName", "zdwdxl"));
             cmd.Parameters.Add(new SqlParameter("@fieldNames", "zdwdxl.终端编号 AS 终端编号,zdwdxl.终端名称 AS 终端名称,zdwdxl.联系人 AS 联系人,zdwdxl.联系电话 AS 联系电话,zdwdxl.联系手机 AS 联系手机,zdwdxl.地址 AS 地址,zdwdxl.老板名 AS 老板名,zdwdxl.老板电话 AS 老板电话,zdwdxl.老板手机 AS 老板手机,zdwdxl.终端类型 AS 终端类型,zdwdxl.结算方式 AS 结算方式,zdwdxl.商超营业面积 AS 商超营业面积,zdwdxl.采购方式 AS 采购方式,zdwdxl.上座率 AS 上座率,zdwdxl.平均消费 AS 平均消费,zdwdxl.进店类型 AS 进店类型,zdwdxl.包间数 AS 包间数,zdwdxl.流通营业面积 AS 流通营业面积,zdwdxl.门面数 AS 门面数,zdwdxl.酒水容量 AS 酒水容量,zdwdxl.团购金额 AS 团购金额,zdwdxl.业务员编号 AS 业务员编号,zdwdxl.业务员名称 AS 业务员名称"));
             cmd.Parameters.Add(new SqlParameter("@fieldSort", "zdwdxl.终端编号"));
             var sbCondition = new StringBuilder();
             sbCondition.Append(string.Format("{0}{1}{2}{3}{4}{5}{6}", "((业务员编号 IN (SELECT UserCode FROM dbo.sys_user WHERE OrganizeName LIKE '", System.Web.HttpContext.Current.Session["OrganizeName"], "%')AND 所属公司='", (System.Web.HttpContext.Current.Session["sys_user"] as sys_user).CompCode, "') or ('", (System.Web.HttpContext.Current.Session["sys_user"] as sys_user).UserCode, "'='super'))"));
             sbCondition.Append(" AND ");
             SerachCondition.TextBox(sbCondition, "终端名称", "终端名称", "");
             SerachCondition.TextBox(sbCondition, "联系人", "联系人", "");
             SerachCondition.TextBox(sbCondition, "联系手机", "联系手机", "");
             SerachCondition.Dropdown(sbCondition, "终端类型", "终端类型", "");
             if (sbCondition.Length > 5)
             {
                 sbCondition.Length -= 5;
                 cmd.Parameters.Add(new SqlParameter("@condition", sbCondition.ToString()));
             }
             if (HttpContext.Current.Request.Get("_report_") == "1")
             {
                 // 报表请求条件合成
                 return(sbCondition.ToString());
             }
             SqlParameter rowTotalParameter = null;
             int          rowTotal          = 0;
             int.TryParse(HttpContext.Current.Request.Get("total"), out rowTotal);
             var rq = new PageRequest();
             if (rq.Page.HasValue)
             {
                 var pageSize = rq.Rows.HasValue ? rq.Rows.Value : 20;
                 var rowStart = (rq.Page.Value - 1) * pageSize + 1;
                 var rowEnd   = rq.Page.Value * pageSize;
                 cmd.Parameters.Add(new SqlParameter("@rowStart", rowStart));
                 cmd.Parameters.Add(new SqlParameter("@rowEnd", rowEnd));
                 if (rowStart == 1)
                 {
                     cmd.Parameters.Add(rowTotalParameter = new SqlParameter("@rowTotal", System.Data.SqlDbType.Int, 8, System.Data.ParameterDirection.Output, true, 0, 0, null, System.Data.DataRowVersion.Default, 0));
                 }
             }
             string jsonArrayString = null;
             using (var reader = cmd.ExecuteReader())
             {
                 jsonArrayString = reader.ToJsonArrayString();
             }
             if (rowTotalParameter != null)
             {
                 rowTotal = (int)rowTotalParameter.Value;
             }
             return(JObject.Parse("{rows:" + jsonArrayString + ", total:" + rowTotal + "}"));
         } finally {
             db.Database.Connection.Close();
         }
     }
 }
 public object Get(JObject req)
 {
     using (var db = new LUOLAI1401Context())
     {
         db.Database.Connection.Open();
         try {
             var cmd = db.Database.Connection.CreateCommand();
             cmd.CommandType = System.Data.CommandType.StoredProcedure;
             cmd.CommandText = "proc_SearchList";
             cmd.Parameters.Add(new SqlParameter("@tableName", "HR_SocialSecRecords"));
             cmd.Parameters.Add(new SqlParameter("@fieldNames", "HR_SocialSecRecords.FYear AS FYear,HR_SocialSecRecords.FMonth AS FMonth,HR_SocialSecRecords.empCode AS empCode,HR_SocialSecRecords.SSType AS SSType,HR_SocialSecRecords.SSAmt AS SSAmt,HR_SocialSecRecords.indvPension AS indvPension,HR_SocialSecRecords.indvMedical AS indvMedical,HR_SocialSecRecords.indvUnemploy AS indvUnemploy,HR_SocialSecRecords.corpPension AS corpPension,HR_SocialSecRecords.corpBaseMedical AS corpBaseMedical,HR_SocialSecRecords.corpLocalMedical AS corpLocalMedical,HR_SocialSecRecords.corpUnemploy AS corpUnemploy,HR_SocialSecRecords.corpInjury AS corpInjury,HR_SocialSecRecords.corpBirth AS corpBirth,HR_SocialSecRecords.indvTotal AS indvTotal,HR_SocialSecRecords.corpTotal AS corpTotal,HR_SocialSecRecords.Total AS Total,HR_SocialSecRecords.Remark AS Remark"));
             cmd.Parameters.Add(new SqlParameter("@fieldSort", "FMonth,FYear desc"));
             var sbCondition = new StringBuilder();
             SerachCondition.TextBox(sbCondition, "FYear", "FYear", "");
             SerachCondition.TextBox(sbCondition, "FMonth", "FMonth", "");
             SerachCondition.PopupSelect(sbCondition, "empCode", "empCode", "");
             SerachCondition.Dropdown(sbCondition, "SSType", "SSType", "");
             if (sbCondition.Length > 5)
             {
                 sbCondition.Length -= 5;
                 cmd.Parameters.Add(new SqlParameter("@condition", sbCondition.ToString()));
             }
             if (HttpContext.Current.Request.Get("_report_") == "1")
             {
                 // 报表请求条件合成
                 return(sbCondition.ToString());
             }
             SqlParameter rowTotalParameter = null;
             int          rowTotal          = 0;
             int.TryParse(HttpContext.Current.Request.Get("total"), out rowTotal);
             var rq = new PageRequest();
             if (rq.Page.HasValue)
             {
                 var pageSize = rq.Rows.HasValue ? rq.Rows.Value : 20;
                 var rowStart = (rq.Page.Value - 1) * pageSize + 1;
                 var rowEnd   = rq.Page.Value * pageSize;
                 cmd.Parameters.Add(new SqlParameter("@rowStart", rowStart));
                 cmd.Parameters.Add(new SqlParameter("@rowEnd", rowEnd));
                 if (rowStart == 1)
                 {
                     cmd.Parameters.Add(rowTotalParameter = new SqlParameter("@rowTotal", System.Data.SqlDbType.Int, 8, System.Data.ParameterDirection.Output, true, 0, 0, null, System.Data.DataRowVersion.Default, 0));
                 }
             }
             string jsonArrayString = null;
             using (var reader = cmd.ExecuteReader())
             {
                 jsonArrayString = reader.ToJsonArrayString();
             }
             if (rowTotalParameter != null)
             {
                 rowTotal = (int)rowTotalParameter.Value;
             }
             return(JObject.Parse("{rows:" + jsonArrayString + ", total:" + rowTotal + "}"));
         } finally {
             db.Database.Connection.Close();
         }
     }
 }
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.Dropdown(sbCondition, "Corp", "a.Corp", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <FA_InvoicesListModel>(db.Database, "a.InvoicesID ,a.invoiceCode ,b.Text Corp_RefText ,a.Corp ,c.Contact CustID_RefText ,a.CustID ,d.Code PID_RefText ,a.PID ,a.FDate ,a.Amt ,a.invoiceTitle ,a.taxNumber ,e.Text taxType_RefText ,a.taxType ,f.Remarks invoiceType_RefText ,a.invoiceType ,a.invoiceContent ,a.Remark ", "FA_Invoices a LEFT JOIN [Bcp.Sysy].dbo.sys_code b ON a.Corp = b.Value AND (b.CodeType='HtCorp') LEFT JOIN BD_Customers c ON a.CustID = c.FID LEFT JOIN PM_Contracts d ON a.PID = d.Code LEFT JOIN [Bcp.Sysy].dbo.sys_code e ON a.taxType = e.Value AND (e.CodeType='taxType') LEFT JOIN HR_NewInvoices f ON a.invoiceType = f.FID ", sbCondition.ToString(), "a.InvoicesID", "desc"));
            }
        }
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.Dropdown(sbCondition, "Corp", "a.Corp", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <FA_InvAcceptsListModel>(db.Database, "a.FID ,b.Text Corp_RefText ,a.Corp ,c.Contact CustID_RefText ,a.CustID ,a.PID ,a.Fdate ,a.Amt ,a.invoiceTitle ,d.Remarks invoiceType_RefText ,a.invoiceType ,a.Remark ,a.CreatePerson ,a.CreateDate ,a.UpdateDate ", "FA_InvAccepts a LEFT JOIN [Bcp.Sysy].dbo.sys_code b ON a.Corp = b.Value AND (b.CodeType='HtCorp') LEFT JOIN BD_Customers c ON a.CustID = c.FID LEFT JOIN HR_NewInvoices d ON a.invoiceType = d.FID ", sbCondition.ToString(), "a.FID", "desc"));
            }
        }
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.Dropdown(sbCondition, "frommodule", "a.frommodule", "");
            SerachCondition.Dropdown(sbCondition, "memid", "a.memid", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <fw_recordinfoListModel>(db.Database, "a.Id ,a.fromid ,b.Text frommodule_RefText ,a.frommodule ,a.price ,a.counts ,c.realname memid_RefText ,a.memid ", "fw_recordinfo a LEFT JOIN [SYS_YLW].dbo.sys_code b ON a.frommodule = b.Value AND (b.CodeType='SourceModule') LEFT JOIN fw_memberinfo c ON a.memid = c.memid ", sbCondition.ToString(), "a.Id", "desc"));
            }
        }
Exemple #7
0
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.Dropdown(sbCondition, "MemId", "a.MemId", "");
            SerachCondition.TextBox(sbCondition, "orderid", "a.orderid", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <fw_ObjectionResultListModel>(db.Database, "a.objectionid ,b.corpname MemId_RefText ,a.MemId ,a.orderid ,c.Text IsContinue_RefText ,a.IsContinue ,d.corpname paymemId_RefText ,a.paymemId ,a.payment ,e.Text paymentmode_RefText ,a.paymentmode ,a.paymentendtime ,f.Text resultstatus_RefText ,a.resultstatus ,a.explain ,a.resultperson ,a.resultphone ,a.finalresult ", "fw_ObjectionResult a LEFT JOIN v_MemberAll b ON a.MemId = b.memid LEFT JOIN [SYS_YLW].dbo.sys_code c ON a.IsContinue = c.Value AND (c.CodeType='YN') LEFT JOIN v_MemberAll d ON a.paymemId = d.memid LEFT JOIN [SYS_YLW].dbo.sys_code e ON a.paymentmode = e.Value AND (e.CodeType='PayKind') LEFT JOIN [SYS_YLW].dbo.sys_code f ON a.resultstatus = f.Value AND (f.CodeType='ObjState') ", sbCondition.ToString(), "a.objectionid", "desc"));
            }
        }
Exemple #8
0
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.TextBox(sbCondition, "newstitle", "a.newstitle", "");
            SerachCondition.Dropdown(sbCondition, "userid", "a.userid", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <fw_newsinfoListModel>(db.Database, "a.newsid ,a.newstitle ,a.category ,a.clicks ,b.Text isslide_RefText ,a.isslide ,c.UserName userid_RefText ,a.userid ,a.pubtime ", "fw_newsinfo a LEFT JOIN [SYS_YLW].dbo.sys_code b ON a.isslide = b.Value AND (b.CodeType='YN') LEFT JOIN [SYS_YLW].dbo.sys_user c ON a.userid = c.UserCode ", sbCondition.ToString(), "a.newsid", "desc"));
            }
        }
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.Dropdown(sbCondition, "Corp", "a.Corp", "");
            SerachCondition.Dropdown(sbCondition, "CustID", "a.CustID", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <PrepaidTaxListModel>(db.Database, "a.FID ,a.Code ,b.Text Corp_RefText ,a.Corp ,c.Contact CustID_RefText ,a.CustID ,d.invoiceTitle Invoice_RefText ,a.Invoice ,a.Amt ,a.DeductibleAmt ,a.ReceiptDate ,a.InvoicesRise ", "PrepaidTax a LEFT JOIN [Bcp.Sysy].dbo.sys_code b ON a.Corp = b.Value AND (b.CodeType='HtCorp') LEFT JOIN BD_Customers c ON a.CustID = c.FID LEFT JOIN FA_Invoices d ON a.Invoice = d.invoiceCode ", sbCondition.ToString(), "a.FID", "desc"));
            }
        }
Exemple #10
0
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.PopupSelect(sbCondition, "empID", "a.empID", "");
            SerachCondition.Dropdown(sbCondition, "HFType", "a.HFType", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <HR_WageSetsListModel>(db.Database, "a.FID ,b.empID empID_RefText ,a.empID ,c.Text HFType_RefText ,a.HFType ,a.SSBaseAmt ,a.HFBaseAmt ,d.Contact CustID_RefText ,a.CustID ,a.START_TIME ,a.END_TIME ,a.Remark ,a.CreatePerson ,a.CreateDate ,a.UpdateDate ", "HR_WageSets a LEFT JOIN HR_PractiseCerts b ON a.empID = b.FID LEFT JOIN [Bcp.Sysy].dbo.sys_code c ON a.HFType = c.Value AND (c.CodeType='FType') LEFT JOIN BD_Customers d ON a.CustID = d.FID ", sbCondition.ToString(), "a.FID", "desc"));
            }
        }
Exemple #11
0
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.TextBox(sbCondition, "proname", "a.proname", "");
            SerachCondition.Dropdown(sbCondition, "memid", "a.memid", "");
            SerachCondition.Dropdown(sbCondition, "isactive", "a.isactive", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <fw_teambuyingListModel>(db.Database, "a.procode ,a.catid ,a.proname ,a.spec ,b.realname memid_RefText ,a.memid ,a.sellmode ,a.price ,a.GroupPrice ,a.grade ,a.minprodcount ,a.stock ,c.Text isactive_RefText ,a.isactive ,a.depositbuyer ,a.cautionAmt ,a.endtime ,a.starttime ,d.Text ispassed_RefText ,a.ispassed ,e.Text cautionFlay_RefText ,a.cautionFlay ,f.Text ispayback_RefText ,a.ispayback ,g.Text dealFlag_RefText ,a.dealFlag ,a.dealTimes ,h.Text isSuccess_RefText ,a.isSuccess ", "fw_teambuying a LEFT JOIN fw_memberinfo b ON a.memid = b.memid LEFT JOIN [SYS_YLW].dbo.sys_code c ON a.isactive = c.Value AND (c.CodeType='YN') LEFT JOIN [SYS_YLW].dbo.sys_code d ON a.ispassed = d.Value AND (d.CodeType='YN') LEFT JOIN [SYS_YLW].dbo.sys_code e ON a.cautionFlay = e.Value AND (e.CodeType='YN') LEFT JOIN [SYS_YLW].dbo.sys_code f ON a.ispayback = f.Value AND (f.CodeType='YN') LEFT JOIN [SYS_YLW].dbo.sys_code g ON a.dealFlag = g.Value AND (g.CodeType='YN') LEFT JOIN [SYS_YLW].dbo.sys_code h ON a.isSuccess = h.Value AND (h.CodeType='YN') ", sbCondition.ToString(), "a.procode", "desc"));
            }
        }
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.TextBox(sbCondition, "appNumber", "a.appNumber", "");
            SerachCondition.Dropdown(sbCondition, "depAmtStatus", "a.depAmtStatus", "");
            SerachCondition.TextBox(sbCondition, "PManager", "a.PManager", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <PM_ProjectInfoBidsListModel>(db.Database, "a.Code ,a.ProjName ,b.Contact CustID_RefText ,a.CustID ,a.appNumber ,a.Owner ,a.totalInvAmt ,a.depAmt ,c.Text depAmtStatus_RefText ,a.depAmtStatus ,a.advAmt ,a.bookAmt ,a.bidAmt ,a.agencyAmt ,a.PManager ,a.bidDate ,a.bidAddress ,a.bidPerson ,a.bidAgent ,a.Attention ,a.Winner ,a.Remark ,a.CreatePerson ,a.CreateDate ,a.UpdateDate ,a.UpdatePerson ", "PM_ProjectInfoBids a LEFT JOIN BD_Customers b ON a.CustID = b.FID LEFT JOIN [Bcp.Sysy].dbo.sys_code c ON a.depAmtStatus = c.Value AND (c.CodeType='depAmt') ", sbCondition.ToString(), "a.Code", "desc"));
            }
        }
Exemple #13
0
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            sbCondition.AppendFormat("({0}) AND ", string.Format("{0}{1}{2}{3}{4}", "(a.CompCode= '", (System.Web.HttpContext.Current.Session["sys_user"] as sys_user).CompCode, "' or '", (System.Web.HttpContext.Current.Session["sys_user"] as sys_user).UserCode, "'='super') AND c.CodeType='MON'"));
            SerachCondition.PopupSelect(sbCondition, "UserCode", "a.UserCode", "varchar");
            SerachCondition.Dropdown(sbCondition, "Month", "a.Month", "varchar");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <wq_planListModel>(db.Database, "a.id ,b.name UserCode_RefText ,a.UserCode ,c.Text Month_RefText ,a.Month ,a.SellAmt ,a.IncomeAmt ", "wq_plan a LEFT JOIN PersonInfo b ON a.UserCode = b.psncode LEFT JOIN [Bcp.Sys].dbo.sys_code c ON a.Month = c.Value ", sbCondition.ToString(), "id", "desc"));
            }
        }
Exemple #14
0
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.Date(sbCondition, "BorrowDate", "a.BorrowDate", "");
            SerachCondition.Dropdown(sbCondition, "CustID", "a.CustID", "");
            SerachCondition.Dropdown(sbCondition, "BorrowName", "a.BorrowName", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <HR_BorrowsListModel>(db.Database, "a.FID ,a.BorrowDate ,b.Text CustID_RefText ,a.CustID ,c.Name BorrowName_RefText ,a.BorrowName ,a.Used ,a.BorrowPerson ,a.BorrowPhone ,a.ReturePerson ", "HR_Borrows a LEFT JOIN [Bcp.Sysy].dbo.sys_code b ON a.CustID = b.Value AND (b.CodeType='FType') LEFT JOIN v_Certificate c ON a.BorrowName = c.FID ", sbCondition.ToString(), "a.FID", "desc"));
            }
        }
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.TextBox(sbCondition, "orderid", "a.orderid", "");
            SerachCondition.TextBox(sbCondition, "MemId", "a.MemId", "");
            SerachCondition.Dropdown(sbCondition, "isShow", "a.isShow", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <fw_ObjectionListModel>(db.Database, "a.objectionid ,a.orderid ,a.orderprice ,b.Text Objectionstatus_RefText ,a.Objectionstatus ,c.Text otherstatus_RefText ,a.otherstatus ,a.otherprice ,d.Text IsContinue_RefText ,a.IsContinue ,a.MemId ,a.MemIdSeller ,e.Text objState_RefText ,a.objState ,f.Text isShow_RefText ,a.isShow ,a.Cimg1 ,a.Cimg2 ,a.Cimg3 ,g.Text IsAgreed_RefText ,a.IsAgreed ,h.Text IsOnJudge_RefText ,a.IsOnJudge ", "fw_Objection a LEFT JOIN [SYS_YLW].dbo.sys_code b ON a.Objectionstatus = b.Value AND (b.CodeType='HandleState') LEFT JOIN [SYS_YLW].dbo.sys_code c ON a.otherstatus = c.Value AND (c.CodeType='OtherState') LEFT JOIN [SYS_YLW].dbo.sys_code d ON a.IsContinue = d.Value AND (d.CodeType='YN') LEFT JOIN [SYS_YLW].dbo.sys_code e ON a.objState = e.Value AND (e.CodeType='YN') LEFT JOIN [SYS_YLW].dbo.sys_code f ON a.isShow = f.Value AND (f.CodeType='YN') LEFT JOIN [SYS_YLW].dbo.sys_code g ON a.IsAgreed = g.Value AND (g.CodeType='JJResult') LEFT JOIN [SYS_YLW].dbo.sys_code h ON a.IsOnJudge = h.Value AND (h.CodeType='YN') ", sbCondition.ToString(), "a.objectionid", "desc"));
            }
        }
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.TextBox(sbCondition, "CID", "a.CID", "");
            SerachCondition.TextBox(sbCondition, "Department", "a.Department", "");
            SerachCondition.Dropdown(sbCondition, "TRemark", "a.TRemark", "");
            SerachCondition.Dropdown(sbCondition, "DRemark", "a.DRemark", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <HR_CertLoansListModel>(db.Database, "a.FID ,a.CID ,a.Department ,a.GAddress ,a.ProjName ,a.Amt ,a.loanDate ,a.EndTime ,a.KAmt ,b.Text TRemark_RefText ,a.TRemark ,c.Text DRemark_RefText ,a.DRemark ,a.Scan ", "HR_CertLoans a LEFT JOIN [Bcp.Sysy].dbo.sys_code b ON a.TRemark = b.Value AND (b.CodeType='Tui') LEFT JOIN [Bcp.Sysy].dbo.sys_code c ON a.DRemark = c.Value AND (c.CodeType='yes/no') ", sbCondition.ToString(), "a.FID", "desc"));
            }
        }
Exemple #17
0
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.Dropdown(sbCondition, "selleruserid", "a.selleruserid", "");
            SerachCondition.Dropdown(sbCondition, "buyeruserid", "a.buyeruserid", "");
            SerachCondition.Dropdown(sbCondition, "tranmode", "a.tranmode", "");
            SerachCondition.Dropdown(sbCondition, "ordstate", "a.ordstate", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <fw_orderinfoListModel>(db.Database, "a.ordid ,b.realname selleruserid_RefText ,a.selleruserid ,c.realname buyeruserid_RefText ,a.buyeruserid ,d.Text tranmode_RefText ,a.tranmode ,a.fromid ,e.Text ordstate_RefText ,a.ordstate ,f.Text isactive_RefText ,a.isactive ,g.Text SelfMentioning_RefText ,a.SelfMentioning ,a.pathvoucher ", "fw_orderinfo a LEFT JOIN fw_memberinfo b ON a.selleruserid = b.memid LEFT JOIN fw_memberinfo c ON a.buyeruserid = c.memid LEFT JOIN [SYS_YLW].dbo.sys_code d ON a.tranmode = d.Value AND (d.CodeType='TradingMode') LEFT JOIN [SYS_YLW].dbo.sys_code e ON a.ordstate = e.Value AND (e.CodeType='OrderState') LEFT JOIN [SYS_YLW].dbo.sys_code f ON a.isactive = f.Value AND (f.CodeType='YN') LEFT JOIN [SYS_YLW].dbo.sys_code g ON a.SelfMentioning = g.Value AND (g.CodeType='JHFS') ", sbCondition.ToString(), "a.ordid", "desc"));
            }
        }
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.TextBox(sbCondition, "ProName", "a.ProName", "");
            SerachCondition.Dropdown(sbCondition, "memid", "a.memid", "");
            SerachCondition.Dropdown(sbCondition, "ispassed", "a.ispassed", "");
            SerachCondition.Dropdown(sbCondition, "isactive", "a.isactive", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <fw_auctionbuyinginfoListModel>(db.Database, "a.aucid ,a.ProName ,a.primePrice ,a.floorPrice ,a.addPrice ,a.cellingPrice ,a.counts ,b.realname memid_RefText ,a.memid ,a.starttime ,a.endtime ,a.minUserCount ,c.Text ispassed_RefText ,a.ispassed ,d.Text isactive_RefText ,a.isactive ", "fw_auctionbuyinginfo a LEFT JOIN fw_memberinfo b ON a.memid = b.memid LEFT JOIN [SYS_YLW].dbo.sys_code c ON a.ispassed = c.Value AND (c.CodeType='ShState') LEFT JOIN [SYS_YLW].dbo.sys_code d ON a.isactive = d.Value AND (d.CodeType='UpdownFrame') ", sbCondition.ToString(), "a.aucid", "desc"));
            }
        }
Exemple #19
0
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.PopupSelect(sbCondition, "CustID", "a.CustID", "");
            SerachCondition.Date(sbCondition, "BeginDate", "a.BeginDate", "");
            SerachCondition.Date(sbCondition, "EndDate", "a.EndDate", "");
            SerachCondition.Dropdown(sbCondition, "projl", "a.projl", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <PM_ProjectInfosListModel>(db.Database, "a.FID ,a.appNumber ,a.Code ,a.ProjName ,b.Contact CustID_RefText ,a.CustID ,a.Owner ,a.BeginDate ,a.EndDate ,a.BaDate ,c.Text bClose_RefText ,a.bClose ,a.exDays ,a.proje ,d.empID projl_RefText ,a.projl ", "PM_ProjectInfos a LEFT JOIN BD_Customers b ON a.CustID = b.FID LEFT JOIN [Bcp.Sysy].dbo.sys_code c ON a.bClose = c.Value AND (c.CodeType='yes/no') LEFT JOIN HR_PractiseCerts d ON a.projl = d.FID ", sbCondition.ToString(), "a.FID", "desc"));
            }
        }
Exemple #20
0
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            sbCondition.AppendFormat("({0}) AND ", string.Format("{0}{1}{2}", "a.CompCode= '", (System.Web.HttpContext.Current.Session["sys_user"] as sys_user).CompCode, "'"));
            SerachCondition.PopupSelect(sbCondition, "RoleCode", "a.RoleCode", "varchar");
            SerachCondition.PopupSelect(sbCondition, "psncode", "a.psncode", "varchar");
            SerachCondition.Dropdown(sbCondition, "timingtype", "a.timingtype", "varchar");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <timingSetListModel>(db.Database, "a.id ,b.RoleName RoleCode_RefText ,a.RoleCode ,c.name psncode_RefText ,a.psncode ,d.Text timingtype_RefText ,a.timingtype ,a.interval ,a.mobegintime ,a.moendtime ,a.afbegintime ,a.afendtime ", "timingSet a LEFT JOIN [Bcp.Sys].dbo.sys_role b ON a.RoleCode = b.RoleCode LEFT JOIN PersonInfo c ON a.psncode = c.psncode LEFT JOIN [Bcp.Sys].dbo.sys_code d ON a.timingtype = d.Text ", sbCondition.ToString(), "id", "desc"));
            }
        }
Exemple #21
0
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.TextBox(sbCondition, "directtitle", "a.directtitle", "");
            SerachCondition.TextBox(sbCondition, "catid0", "a.catid0", "");
            SerachCondition.Date(sbCondition, "directtime0", "a.directtime0", "");
            SerachCondition.Dropdown(sbCondition, "isshow", "a.isshow", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <fw_directpriceListModel>(db.Database, "a.directid ,a.directtitle ,a.catid0 ,a.directtime0 ,a.directprice0 ,b.Text isshow_RefText ,a.isshow ,a.floatprice0 ,a.floatrate0 ", "fw_directprice a LEFT JOIN [SYS_YLW].dbo.sys_code b ON a.isshow = b.Value AND (b.CodeType='YN') ", sbCondition.ToString(), "a.directid", "desc"));
            }
        }
Exemple #22
0
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.TextBox(sbCondition, "memid", "a.memid", "");
            SerachCondition.TextBox(sbCondition, "realname", "a.realname", "");
            SerachCondition.TextBox(sbCondition, "qq", "a.qq", "");
            SerachCondition.TextBox(sbCondition, "wechat", "a.wechat", "");
            SerachCondition.Dropdown(sbCondition, "ispassed", "a.ispassed", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <fw_memberinfoListModel>(db.Database, "a.Fid ,a.memid ,a.realname ,b.Text gender_RefText ,a.gender ,a.email ,a.qq ,a.wechat ,a.regtime ,a.lasttime ,c.Text ispassed_RefText ,a.ispassed ,d.Text isenabled_RefText ,a.isenabled ,a.Cimg1 ,a.Cimg2 ,a.Cimg3 ,a.Cimgcode1 ,a.Cimgcode2 ,a.Xletterurl ,a.Cletterurl ", "fw_memberinfo a LEFT JOIN [SYS_YLW].dbo.sys_code b ON a.gender = b.Value AND (b.CodeType='Gender') LEFT JOIN [SYS_YLW].dbo.sys_code c ON a.ispassed = c.Value AND (c.CodeType='RZZT') LEFT JOIN [SYS_YLW].dbo.sys_code d ON a.isenabled = d.Value AND (d.CodeType='YN') ", sbCondition.ToString(), "a.regtime", "desc"));
            }
        }
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.Dropdown(sbCondition, "Corp", "a.Corp", "");
            SerachCondition.Dropdown(sbCondition, "SZType", "a.SZType", "");
            SerachCondition.PopupSelect(sbCondition, "CustID", "a.CustID", "");
            SerachCondition.Date(sbCondition, "Fdate", "a.Fdate", "");
            SerachCondition.Dropdown(sbCondition, "payType", "a.payType", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <FA_ReceiptsListModel>(db.Database, "a.FID ,b.Text Corp_RefText ,a.Corp ,c.Text SZType_RefText ,a.SZType ,d.Contact CustID_RefText ,a.CustID ,a.Fdate ,a.Amt ,e.Text payType_RefText ,a.payType ,a.Remark ,a.CreatePerson ,a.CreateDate ,a.UpdateDate ", "FA_Receipts a LEFT JOIN [Bcp.Sysy].dbo.sys_code b ON a.Corp = b.Value AND (b.CodeType='HtCorp') LEFT JOIN [Bcp.Sysy].dbo.sys_code c ON a.SZType = c.Value AND (c.CodeType='SHZHType') LEFT JOIN BD_Customers d ON a.CustID = d.FID LEFT JOIN [Bcp.Sysy].dbo.sys_code e ON a.payType = e.Value AND (e.CodeType='PayKind') ", sbCondition.ToString(), "a.FID", "desc"));
            }
        }
Exemple #24
0
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.TextBox(sbCondition, "psncode", "a.psncode", "");
            SerachCondition.TextBox(sbCondition, "name", "a.name", "");
            SerachCondition.TextBox(sbCondition, "Mobile", "a.Mobile", "");
            SerachCondition.Dropdown(sbCondition, "position", "a.position", "");
            SerachCondition.PopupSelect(sbCondition, "RoleCode", "a.RoleCode", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <PersonInfoListModel>(db.Database, "a.ID ,a.psncode ,a.name ,a.Mobile ,b.Text sex_RefText ,a.sex ,c.Text EmployeeStatus_RefText ,a.EmployeeStatus ,d.OrganizeName position_RefText ,a.position ,e.RoleName RoleCode_RefText ,a.RoleCode ,a.stuffdate ,a.is_status ,a.kq_status ", "PersonInfo a LEFT JOIN [Bcp.Sys].dbo.sys_code b ON a.sex = b.Value LEFT JOIN [Bcp.Sys].dbo.sys_code c ON a.EmployeeStatus = c.Value LEFT JOIN [Bcp.Sys].dbo.sys_organize d ON a.position = d.OrganizeCode LEFT JOIN [Bcp.Sys].dbo.sys_role e ON a.RoleCode = e.RoleCode ", sbCondition.ToString(), "a.ID", "desc"));
            }
        }
Exemple #25
0
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.TextBox(sbCondition, "name", "a.name", "");
            SerachCondition.TextBox(sbCondition, "CertNumber", "a.CertNumber", "");
            SerachCondition.Dropdown(sbCondition, "nativeplace", "a.nativeplace", "");
            SerachCondition.TextBox(sbCondition, "FileNumber", "a.FileNumber", "");
            SerachCondition.PopupSelect(sbCondition, "UserAccount", "a.UserAccount", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <PersonInfoListModel>(db.Database, "a.ID ,a.name ,a.Password ,a.CertNumber ,b.Text nativeplace_RefText ,a.nativeplace ,a.FileNumber ,c.Text UserAccount_RefText ,a.UserAccount ,a.psncode ,a.RoleCode ,a.WageCard ,a.SocialSecurity ,a.Mobile ,a.usedname ,a.sex ,a.birthdate ,a.age ,a.stuffdate ,a.effectdate ,a.workaddr ,a.BirthPlace ,a.nationality ,a.position ,a.permanreside ,a.characterrpr ,a.marital ,a.EmployeeStatus ,a.country ,a.idtype ,a.polity ,a.health ,a.Height ,a.Weight ,a.Vision ,a.lasteducation ,a.HighestDegree ,a.major ,a.rank ,a.GraduationSchool ,a.joinworkdate ,a.FreeWorkYears ,a.is_status ,a.kq_status ,a.glbdef1 ,a.Photo ,a.CompCode ,a.soft ,a.phonetype ,a.os ,a.isline ,a.KQ ", "PersonInfo a LEFT JOIN [Bcp.Sys].dbo.sys_code b ON a.nativeplace = b.Value LEFT JOIN [Bcp.Sys].dbo.sys_code c ON a.UserAccount = c.Value ", sbCondition.ToString(), "a.ID", "desc"));
            }
        }
Exemple #26
0
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.TextBox(sbCondition, "longname", "a.longname", "");
            SerachCondition.Dropdown(sbCondition, "mode", "a.mode", "");
            SerachCondition.Dropdown(sbCondition, "memid", "a.memid", "");
            SerachCondition.Dropdown(sbCondition, "isactive", "a.isactive", "");
            SerachCondition.Dropdown(sbCondition, "ispassed", "a.ispassed", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <fw_longterminfoListModel>(db.Database, "a.longid ,a.longname ,b.Text mode_RefText ,a.mode ,c.realname memid_RefText ,a.memid ,d.Text isactive_RefText ,a.isactive ,e.Text ispassed_RefText ,a.ispassed ", "fw_longterminfo a LEFT JOIN [SYS_YLW].dbo.sys_code b ON a.mode = b.Value AND (b.CodeType='TradingMode') LEFT JOIN fw_memberinfo c ON a.memid = c.memid LEFT JOIN [SYS_YLW].dbo.sys_code d ON a.isactive = d.Value AND (d.CodeType='YN') LEFT JOIN [SYS_YLW].dbo.sys_code e ON a.ispassed = e.Value AND (e.CodeType='ShState') ", sbCondition.ToString(), "a.longid", "desc"));
            }
        }
Exemple #27
0
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            sbCondition.AppendFormat("({0}) AND ", string.Format("{0}{1}{2}", "a.CompCode= '", (System.Web.HttpContext.Current.Session["sys_user"] as sys_user).CompCode, "'"));
            SerachCondition.TextBox(sbCondition, "PdtCode", "a.PdtCode", "varchar");
            SerachCondition.TextBox(sbCondition, "PdtName", "a.PdtName", "varchar");
            SerachCondition.SelectUser(sbCondition, "PdtCate", "a.PdtCate", "varchar");
            SerachCondition.TextBox(sbCondition, "Spec", "a.Spec", "varchar");
            SerachCondition.Dropdown(sbCondition, "BaseUnits", "a.BaseUnits", "varchar");
            SerachCondition.TextBox(sbCondition, "RetailPrc", "a.RetailPrc", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <base_productInfoListModel>(db.Database, "a.id ,a.PdtCode ,a.PdtName ,b.CateName PdtCate_RefText ,a.PdtCate ,a.Spec ,c.Text BaseUnits_RefText ,a.BaseUnits ,a.RetailPrc ,a.TradPrc ,a.Description ,a.DelFlag ", "base_productInfo a LEFT JOIN base_productCate b ON a.PdtCate = b.CateName LEFT JOIN [Bcp.Sys].dbo.sys_code c ON a.BaseUnits = c.Value ", sbCondition.ToString(), "a.id", "desc"));
            }
        }
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.Dropdown(sbCondition, "Corp", "a.Corp", "");
            SerachCondition.Dropdown(sbCondition, "Type", "a.Type", "");
            SerachCondition.Dropdown(sbCondition, "CustID", "a.CustID", "");
            SerachCondition.TextBox(sbCondition, "Owner", "a.Owner", "");
            SerachCondition.Dropdown(sbCondition, "Region", "a.Region", "");
            SerachCondition.Date(sbCondition, "FDate", "a.FDate", "");
            SerachCondition.Dropdown(sbCondition, "Scan1", "a.Scan1", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <PM_ContractsListModel>(db.Database, "a.Code ,b.Text Corp_RefText ,a.Corp ,c.Text Type_RefText ,a.Type ,a.Amt ,d.Contact CustID_RefText ,a.CustID ,a.Owner ,a.Situation ,a.taxAmt ,e.Text Region_RefText ,a.Region ,a.FDate ,a.Remark ,f.Text Scan1_RefText ,a.Scan1 ,a.Scan2,a.ArchStatus ,a.CreatePerson ,a.CreateDate ,a.UpdateDate ,a.affiliatedPM ", "PM_Contracts a LEFT JOIN [Bcp.Sysy].dbo.sys_code b ON a.Corp = b.Value AND (b.CodeType='HtCorp') LEFT JOIN [Bcp.Sysy].dbo.sys_code c ON a.Type = c.Value AND (c.CodeType='HtType') LEFT JOIN BD_Customers d ON a.CustID = d.FID LEFT JOIN [Bcp.Sysy].dbo.sys_code e ON a.Region = e.Value AND (e.CodeType='Region') LEFT JOIN [Bcp.Sysy].dbo.sys_code f ON a.Scan1 = f.Value AND (f.CodeType='GCLB') ", sbCondition.ToString(), "a.Code", "desc"));
            }
        }
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.Dropdown(sbCondition, "catid", "a.catid", "");
            SerachCondition.TextBox(sbCondition, "proname", "a.proname", "");
            SerachCondition.Dropdown(sbCondition, "memid", "a.memid", "");
            SerachCondition.Dropdown(sbCondition, "sellmode", "a.sellmode", "");
            SerachCondition.Dropdown(sbCondition, "isactive", "a.isactive", "");
            SerachCondition.Dropdown(sbCondition, "issale", "a.issale", "");
            SerachCondition.Date(sbCondition, "CreateDate", "a.CreateDate", "");
            SerachCondition.Dropdown(sbCondition, "ispassed", "a.ispassed", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <fw_productinfoListModel>(db.Database, "a.Fid ,b.catname catid_RefText ,a.catid ,a.proname ,c.Text spec_RefText ,a.spec ,d.realname memid_RefText ,a.memid ,a.price ,e.Text sellmode_RefText ,a.sellmode ,a.grade ,a.minprodcount ,a.stock ,f.Text isactive_RefText ,a.isactive ,a.depositseller ,a.depositbuyer ,g.Text issale_RefText ,a.issale ,a.viewcount ,a.CreateDate ,h.Text ispassed_RefText ,a.ispassed ", "fw_productinfo a LEFT JOIN fw_categoryinfo b ON a.catid = b.catid AND (b.parentid !='0') LEFT JOIN [SYS_YLW].dbo.sys_code c ON a.spec = c.Value AND (c.CodeType='MeasureUnit') LEFT JOIN fw_memberinfo d ON a.memid = d.memid LEFT JOIN [SYS_YLW].dbo.sys_code e ON a.sellmode = e.Value AND (e.CodeType='TradingMode') LEFT JOIN [SYS_YLW].dbo.sys_code f ON a.isactive = f.Value AND (f.CodeType='YN') LEFT JOIN [SYS_YLW].dbo.sys_code g ON a.issale = g.Value AND (g.CodeType='forseek') LEFT JOIN [SYS_YLW].dbo.sys_code h ON a.ispassed = h.Value AND (h.CodeType='ShState') ", sbCondition.ToString(), "a.Fid", "desc"));
            }
        }
        public object Get()
        {
            var sbCondition = new System.Text.StringBuilder();

            SerachCondition.TextBox(sbCondition, "empID", "a.empID", "");
            SerachCondition.Dropdown(sbCondition, "certType", "a.certType", "");
            SerachCondition.TextBox(sbCondition, "certOrgan", "a.certOrgan", "");
            SerachCondition.TextBox(sbCondition, "certNo", "a.certNo", "");
            SerachCondition.TextBox(sbCondition, "regNo", "a.regNo", "");
            SerachCondition.Date(sbCondition, "expireDate", "a.expireDate", "");
            SerachCondition.Dropdown(sbCondition, "bUsed", "a.bUsed", "");
            SerachCondition.Dropdown(sbCondition, "CustID", "a.CustID", "");

            if (sbCondition.Length > 4)
            {
                sbCondition.Length -= 4;
            }
            var pageReq = new PageRequest();

            using (var db = new LUOLAI1401Context())
            {
                return(pageReq.ToPageList <HR_PractiseCertsListModel>(db.Database, "a.FID ,a.certName ,b.Text Corp_RefText ,a.Corp ,a.empID ,c.Text certType_RefText ,a.certType ,a.CodeID ,a.certOrgan ,a.certNo ,a.regNo ,a.expireDate ,a.onProject ,a.START_TIME ,a.END_TIME ,a.GAmt ,d.Text bUsed_RefText ,a.bUsed ,a.trainStatus ,e.Text CustID_RefText ,a.CustID ", "HR_PractiseCerts a LEFT JOIN [Bcp.Sysy].dbo.sys_code b ON a.Corp = b.Value AND (b.CodeType='HtCorp') LEFT JOIN [Bcp.Sysy].dbo.sys_code c ON a.certType = c.Value AND (c.CodeType='zhengshutype') LEFT JOIN [Bcp.Sysy].dbo.sys_code d ON a.bUsed = d.Value AND (d.CodeType='yw') LEFT JOIN [Bcp.Sysy].dbo.sys_code e ON a.CustID = e.Value AND (e.CodeType='yw') ", sbCondition.ToString(), "a.FID", "desc"));
            }
        }