private void BindDropDown()
    {
        DropDownList ddl_QNAProject = (DropDownList)pl_detail.FindControl("CAT_Activity_RelateQuestionnaire");

        if (ddl_QNAProject != null)
        {
            ddl_QNAProject.DataSource     = QNA_ProjectBLL.GetModelList("Classify = 3 AND Enabled='Y'");
            ddl_QNAProject.DataTextField  = "Name";
            ddl_QNAProject.DataValueField = "ID";
            ddl_QNAProject.DataBind();
            ddl_QNAProject.Items.Insert(0, new ListItem("请选择...", "0"));
        }
        IList <AC_AccountTitle> lists;

        if (ConfigHelper.GetConfigInt("ActivityFeeAccountTitle2") == 0)
        {
            lists = AC_AccountTitleBLL.GetListByFeeType(ConfigHelper.GetConfigInt("HDM-CATFeeType"));
        }
        else
        {
            lists = AC_AccountTitleBLL.GetModelList("(ID = 1 OR SuperID=" + ConfigHelper.GetConfigString("ActivityFeeAccountTitle2") + ") AND MCS_SYS.dbo.UF_Spilt2('MCS_Pub.dbo.AC_AccountTitle',ExtPropertys,'IsDisable')<>'Y'");
        }
        ddl_AccountTitle.DataSource = lists;
        ddl_AccountTitle.DataBind();

        ddl_Brand.DataSource = PDT_BrandBLL.GetModelList("IsOpponent=1");
        ddl_Brand.DataBind();
        ddl_Brand.Items.Insert(0, new ListItem("请选择...", "0"));
    }
Example #2
0
    protected void ddl_FeeType_SelectedIndexChanged(object sender, EventArgs e)
    {
        if (ddl_FeeType.SelectedValue != "0")
        {
            ddl_AccountTitle.DataSource = AC_AccountTitleBLL.GetListByFeeType(int.Parse(ddl_FeeType.SelectedValue));
            ddl_AccountTitle.DataBind();
        }

        ddl_AccountTitle.Items.Insert(0, new ListItem("请选择", "0"));
        ddl_AccountTitle.SelectedValue = "0";
    }
    private void BindDropDown()
    {
        #region 绑定物业租赁所需的费用科目
        int ContractFeeType      = Convert.ToInt32(System.Configuration.ConfigurationManager.AppSettings["ContractFeeType-PD"]);
        int ContractAccountTitle = Convert.ToInt32(System.Configuration.ConfigurationManager.AppSettings["ContractAccountTitle-PD"]);
        ddl_AccountTitle.DataSource = AC_AccountTitleBLL.GetListByFeeType(ContractFeeType).Where(p => p.SuperID == ContractAccountTitle || p.ID == ContractAccountTitle);
        ddl_AccountTitle.DataBind();
        #endregion

        #region 绑定付款周期
        ddl_PayMode.DataSource = DictionaryBLL.GetDicCollections("PUB_PayMode");
        ddl_PayMode.DataBind();
        ddl_PayMode.Items.Insert(0, new ListItem("所有", "0"));
        ddl_PayMode.SelectedValue = "1";
        #endregion
    }
Example #4
0
 protected void ddl_FeeType_SelectedIndexChanged(object sender, EventArgs e)
 {
     if (ConfigHelper.GetConfigBool("FeeApplyByAccountTitleLevel2"))
     {
         if (ddl_FeeType.SelectedValue != "0")
         {
             ddl_AccountTitle2.DataSource = AC_AccountTitleBLL.GetListByFeeType(int.Parse(ddl_FeeType.SelectedValue)).Where(p => p.Level == 2);
             ddl_AccountTitle2.DataBind();
         }
         else
         {
             ddl_AccountTitle2.Items.Clear();
         }
         ddl_AccountTitle2.Items.Insert(0, new ListItem("请选择...", "0"));
     }
 }
Example #5
0
    private void BindDropDown()
    {
        #region 绑定用户可管辖的管理片区
        Org_StaffBLL staff = new Org_StaffBLL((int)Session["UserID"]);
        tr_OrganizeCity.DataSource = staff.GetStaffOrganizeCity();

        if (tr_OrganizeCity.DataSource.Select("ID = 1").Length > 0)
        {
            tr_OrganizeCity.RootValue   = "0";
            tr_OrganizeCity.SelectValue = "1";
        }
        else
        {
            tr_OrganizeCity.RootValue   = new Addr_OrganizeCityBLL(staff.Model.OrganizeCity).Model.SuperID.ToString();
            tr_OrganizeCity.SelectValue = staff.Model.OrganizeCity.ToString();
        }
        #endregion

        int forwarddays = ConfigHelper.GetConfigInt("FeeApplyForwardDays");
        ddl_AccountMonth.DataSource = AC_AccountMonthBLL.GetModelList("EndDate>=GETDATE() AND BeginDate<='" + DateTime.Today.AddDays(forwarddays).ToString("yyyy-MM-dd") +
                                                                      "' AND Year>=" + (DateTime.Today.Year - 1).ToString());
        ddl_AccountMonth.DataBind();
        ddl_AccountMonth.SelectedValue = AC_AccountMonthBLL.GetMonthByDate(DateTime.Now.AddDays(forwarddays)).ToString();

        ddl_FeeType.DataSource = DictionaryBLL.GetDicCollections("FNA_FeeType").OrderBy(p => p.Value.Name).ToList();
        ddl_FeeType.DataBind();

        foreach (ListItem item in ddl_FeeType.Items)
        {
            if (AC_AccountTitleBLL.GetListByFeeType(int.Parse(item.Value)).Where(p => p.ID > 1).ToList().Count == 0)
            {
                item.Enabled = false;
            }
        }

        if (ConfigHelper.GetConfigBool("FeeApplyByAccountTitleLevel2"))
        {
            tr_AccountTitle2.Visible = true;
            ddl_FeeType.AutoPostBack = true;
            ddl_FeeType.Items.Insert(0, new ListItem("请选择...", "0"));
            ddl_FeeType_SelectedIndexChanged(null, null);
        }

        ddl_Brand.DataSource = PDT_BrandBLL.GetModelList("IsOpponent='1'");
        ddl_Brand.DataBind();
        ddl_Brand.Items.Insert(0, new ListItem("多品牌", "0"));
    }
Example #6
0
    protected IList <AC_AccountTitle> GetAccountTitleList()
    {
        IList <AC_AccountTitle> lists;

        if ((int)ViewState["AccountTitle2"] == 0)
        {
            lists = AC_AccountTitleBLL.GetListByFeeType((int)ViewState["FeeType"]);
        }
        else
        {
            lists = AC_AccountTitleBLL.GetModelList("(ID = 1 OR SuperID=" + ViewState["AccountTitle2"].ToString() + ") AND MCS_SYS.dbo.UF_Spilt2('MCS_Pub.dbo.AC_AccountTitle',ExtPropertys,'IsDisable')<>'Y'");
        }

        if (ViewState["FromGeneralFlow"].ToString() == "Y")
        {
            lists = lists.Where(p => p["CanApplyInGeneralFlow"] != "N").ToList();
        }
        return(lists);
    }
    private void BindDropDown()
    {
        #region 绑定用户可管辖的管理片区
        Org_StaffBLL staff = new Org_StaffBLL((int)Session["UserID"]);
        tr_OrganizeCity.DataSource = staff.GetStaffOrganizeCity();

        if (tr_OrganizeCity.DataSource.Select("ID = 1").Length > 0)
        {
            tr_OrganizeCity.RootValue   = "0";
            tr_OrganizeCity.SelectValue = "1";
        }
        else
        {
            tr_OrganizeCity.RootValue   = new Addr_OrganizeCityBLL(staff.Model.OrganizeCity).Model.SuperID.ToString();
            tr_OrganizeCity.SelectValue = staff.Model.OrganizeCity.ToString();
        }
        tr_OrganizeCity_Selected(null, null);
        #endregion

        int forwarddays = ConfigHelper.GetConfigInt("FeeApplyForwardDays");
        ddl_ApplyMonth.DataSource = AC_AccountMonthBLL.GetModelList("EndDate>=GETDATE() AND BeginDate<='" + DateTime.Today.AddDays(forwarddays).ToString("yyyy-MM-dd") +
                                                                    "' AND Year>=" + (DateTime.Today.Year - 1).ToString());
        ddl_ApplyMonth.DataBind();
        ddl_ApplyMonth.SelectedValue = AC_AccountMonthBLL.GetMonthByDate(DateTime.Now.AddDays(forwarddays)).ToString();

        rbl_GiftClassify.DataSource = DictionaryBLL.GetDicCollections("ORD_GiftClassify");
        rbl_GiftClassify.DataBind();
        rbl_GiftClassify.SelectedValue = "1";

        ddl_AccountTitle.DataSource = AC_AccountTitleBLL.GetListByFeeType((int)ViewState["GiftFeeType"]);
        ddl_AccountTitle.DataBind();

        ddl_LastWriteOffMonth.DataSource = AC_AccountMonthBLL.GetModelList("BeginDate>=GETDATE() AND BeginDate<DATEADD(month,5,GETDATE())");
        ddl_LastWriteOffMonth.DataBind();

        ddl_Brand.DataSource = PDT_BrandBLL.GetModelList("IsOpponent='1'");
        ddl_Brand.DataBind();
        ddl_Brand.Items.Insert(0, new ListItem("请选择...", "0"));
    }
    private void BindDropDown()
    {
        #region 绑定用户可管辖的管理片区
        Org_StaffBLL staff = new Org_StaffBLL((int)Session["UserID"]);
        tr_OrganizeCity.DataSource = staff.GetStaffOrganizeCity();

        if (tr_OrganizeCity.DataSource.Select("ID = 1").Length > 0)
        {
            tr_OrganizeCity.RootValue   = "0";
            tr_OrganizeCity.SelectValue = "1";
        }
        else
        {
            tr_OrganizeCity.RootValue   = new Addr_OrganizeCityBLL(staff.Model.OrganizeCity).Model.SuperID.ToString();
            tr_OrganizeCity.SelectValue = staff.Model.OrganizeCity.ToString();
        }
        #endregion

        rbl_FeeType.DataSource = DictionaryBLL.GetDicCollections("FNA_FeeType").OrderBy(p => p.Value.Name).ToList();
        rbl_FeeType.DataBind();

        foreach (ListItem item in rbl_FeeType.Items)
        {
            if (AC_AccountTitleBLL.GetListByFeeType(int.Parse(item.Value)).Where(p => p.ID > 1).ToList().Count == 0)
            {
                item.Enabled = false;
            }
        }
        rbl_FeeType.Items.Insert(0, new ListItem("请选择", "0"));
        ddl_InvoiceClassAB.DataSource = DictionaryBLL.GetDicCollections("FNA_InvoiceClassAB").OrderBy(p => p.Value.Name).ToList();
        ddl_InvoiceClassAB.DataBind();
        ddl_InvoiceClassAB.Items.Insert(0, new ListItem("请选择", "0"));

        //select_Client.PageUrl = "~/SubModule/CM/PopSearch/Search_SelectClient.aspx?ClientType=2&OrganizeCity=" + tr_OrganizeCity.SelectValue + "&ExtCondition=\"MCS_SYS.dbo.UF_Spilt(CM_Client.ExtPropertys,~|~,7) IN (1,3)\"";
        //select_Staff.PageUrl = "~/SubModule/StaffManage/Pop_Search_Staff.aspx?OrganizeCity=" + tr_OrganizeCity.SelectValue;
    }
Example #9
0
 protected IList <AC_AccountTitle> GetAccountTitleList()
 {
     return(AC_AccountTitleBLL.GetListByFeeType((int)ViewState["FeeType"]).
            Where(p => (p["MustApplyFirst"] == "N" || p.ID == 1)).ToList());
 }