Example #1
0
    private void MyJobList()
    {
        BLL.JobBLL bll         = new BLL.JobBLL();
        int        CurrentPage = ReInt("CurrentPage");
        DataSet    ds          = bll.GetJobPageList(" CreateUser='******' and Invalid=0 order by createTime desc ", CurrentPage, 20);


        RePage(ds);
    }
Example #2
0
    //获得职位列表
    private void GetJobList()
    {
        decimal JobTypeId       = ReDecimal("JobTypeId", 0);  //
        decimal WorkYearId      = ReDecimal("WorkYearId", 0); //工作年限id
        decimal JobPayId        = ReDecimal("JobPayId", 0);   //薪酬待遇ID
        decimal TownId          = ReDecimal("TownId", 0);     //城镇ID
        decimal SchoolExpId     = ReDecimal("SchoolExpId", 0);
        decimal ParentJobTypeId = ReDecimal("ParentJobTypeId", 0);

        decimal MerchantId  = ReDecimal("MerchantId", 0);
        string  inputStr    = ReStr("inputStr", "");
        int     currentPage = ReInt("currentPage");
        int     PageInt     = ReInt("PageInt", 40);
        bool    Invalid     = ReBool("Invalid", false);

        StringBuilder s = new StringBuilder();

        s.Append(" 1=1 ");

        s.Append(" and Invalid='" + Invalid.ToString() + "' ");


        if (MerchantId == 0)
        {
        }
        else
        {
            s.Append(" and MerchantId='" + MerchantId + "' ");
        }

        if (inputStr.Trim() != "")
        {
            s.Append(" and JobtTitle like '%" + inputStr + "%' or JobMemo like '%" + inputStr + "%' ");
        }

        if (JobTypeId != 0)
        {    //如果选择了子类别
            s.Append(" and  JobTypeId='" + JobTypeId + "' ");
        }
        else
        {
            //如果没有选择子类别

            if (ParentJobTypeId == 0)
            {
            }
            else
            {
                //选择的首级类别,则查询首级类别即可
                s.Append(" and ParentJobTypeId='" + ParentJobTypeId + "' ");
            }
        }

        if (WorkYearId != 0)
        {
            s.Append(" and WorkYearId='" + WorkYearId + "' ");
        }
        if (JobPayId != 0)
        {
            //选择的子类别

            s.Append(" and JobPayId='" + JobPayId + "' ");
        }
        if (SchoolExpId != 0)
        {
            s.Append(" and SchoolExpId ='" + SchoolExpId + "' ");
        }

        if (TownId != 0)
        {
            s.Append(" and TownId='" + TownId + "' ");
        }


        s.Append(" order by RecommendLv desc, CreateTime desc ");
        BLL.JobBLL bll = new BLL.JobBLL();

        DataSet ds = bll.GetJobPageList(s.ToString(), currentPage, PageInt);

        RePage(ds);
    }