Esempio n. 1
0
 private void PromotionType()
 {
     Tz888.Model.SubscribeSet model = new Tz888.Model.SubscribeSet();
     Tz888.BLL.SubscribeSet   bll   = new Tz888.BLL.SubscribeSet();
     model         = bll.GetModels(id, out infotypeid, out htmlFile);
     SubscribeType = model.SubscribeType.Split(new char[] { ',' });    //推广类型
 }
Esempio n. 2
0
    private void bind()
    {
        Tz888.BLL.Conn           dal       = new Tz888.BLL.Conn();
        Tz888.BLL.SubscribeSet   bll       = new Tz888.BLL.SubscribeSet();
        Tz888.BLL.InnerInfo      infoBLL   = new Tz888.BLL.InnerInfo();
        Tz888.Model.InnerInfo    infomodel = new Tz888.Model.InnerInfo();
        Tz888.Model.SubscribeSet model     = new Tz888.Model.SubscribeSet();
        model  = bll.GetModels(id, out infotypeid, out htmlFile);
        InfoID = model.InfoID;
        title  = model.Title;
        bll.GetDescript(InfoID, infotypeid.Trim(), out descript);
        long CurrPage   = Convert.ToInt64(ViewState["CurrPage"]);
        long TotalCount = 0;

        string[] countryCode    = model.CountryCode.Split(new char[] { ',' });
        string[] provinceID     = model.ProvinceID.Split(new char[] { ',' });
        string[] cityid         = model.CityID.Split(new char[] { ',' });
        string[] countyId       = model.CountyID.Split(new char[] { ',' });
        string[] objectGradeID  = model.objectGradeID.Split(new char[] { ',' });
        string[] ManageTypeId   = model.ManageTypeId.Split(new char[] { ',' });
        string[] Promotioncount = model.Promotioncount.Split(new char[] { ',' }); //推广条数
        SubscribeType = model.SubscribeType.Split(new char[] { ',' });            //推广类型

        SubType = model.SubscribeType;
        ViewState["SubType"] = SubType;
        string strWhere   = "";
        int    countTatol = 0;

        for (int i = 0; i < countryCode.Length - 1; i++)
        {
            if (objectGradeID[i] != "")
            {
                strWhere += " memberGradeId='" + objectGradeID[i] + "'";//'1001'";
            }
            if (ManageTypeId[i] != "")
            {
                strWhere += " and ManageTypeId='" + ManageTypeId[i] + "'";//'2003'"
            }
            ViewState["strWhere"] = strWhere;
            if (provinceID[i] != "")
            {
                if (countyId[i] != "" && cityid[i] != "") //区

                {
                    strWhere += " and countyId='" + countyId[i] + "'";
                    SendSummey(dal, descript, htmlFile, ref CurrPage, ref TotalCount, Promotioncount, SubscribeType, ref strWhere, ref countTatol);
                }
                if (!site || !email || !phone)
                {
                    if (cityid[i] != "")//市

                    {
                        strWhere += " and CityId='" + cityid[i] + "'";
                        SendSummey(dal, descript, htmlFile, ref CurrPage, ref TotalCount, Promotioncount, SubscribeType, ref strWhere, ref countTatol);
                    }
                }
            }
            if (!site || !email || !phone)
            {
                if (provinceID[i] != "")//省

                {
                    strWhere += " and provinceID='" + provinceID[i] + "'";
                    SendSummey(dal, descript, htmlFile, ref CurrPage, ref TotalCount, Promotioncount, SubscribeType, ref strWhere, ref countTatol);
                }
            }
            if (!site || !email || !phone)
            {
                if (countryCode[i] != "")
                {
                    strWhere += " countryCode='" + countryCode[i] + "'";//国家
                    SendSummey(dal, descript, htmlFile, ref CurrPage, ref TotalCount, Promotioncount, SubscribeType, ref strWhere, ref countTatol);
                }
            }
            if (!site || !email || !phone)
            {
                SendSummey(dal, descript, htmlFile, ref CurrPage, ref TotalCount, Promotioncount, SubscribeType, ref strWhere, ref countTatol);
            }
            break;
        }
    }