Esempio n. 1
0
        public void ProcessRequest(HttpContext context)
        {
            context.Response.ContentType = "text/json";
            string _action = MyCommFun.QueryString("myact");
            int id = MyCommFun.RequestInt("id");
            string openid = MyCommFun.RequestOpenid();  //得到微信用户的openid
            if (_action == "zf")
            {

                //转发
                Dictionary<string, string> jsonDict = new Dictionary<string, string>();

                BLL.wx_cards_gl countgbll = new BLL.wx_cards_gl();
                Model.wx_cards_gl cardscountg = new Model.wx_cards_gl();
                BLL.wx_cards gbll = new BLL.wx_cards();

                gbll.update(id);
                //转发记录
                cardscountg.cardsid = id;
                cardscountg.openid = MyCommFun.QueryString("openid");
                countgbll.Add(cardscountg);

                jsonDict.Add("error", "ok");
                jsonDict.Add("content", "ok");
                context.Response.Write(MyCommFun.getJsonStr(jsonDict));

            }
        }
Esempio n. 2
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if(! IsPostBack)
            {
                BLL.wx_cards gbll = new BLL.wx_cards();
                Model.wx_cards cards = new Model.wx_cards();

                BLL.wx_cards_gl countgbll = new BLL.wx_cards_gl();
                Model.wx_cards_gl cardscountg = new Model.wx_cards_gl();

                id = MyCommFun.RequestInt("aid");
                openid = MyCommFun.RequestOpenid();
                wid = MyCommFun.RequestInt("wid");
                this.hkid.Value = id.ToString();
                cards = gbll.GetModel(id);

                characters = cards.characters;
                //name = cards.name;
                createDate = cards.createDate.ToString();
                copyRight = cards.copyRight;
                zfCount = Convert.ToInt32(cards.zfCount);
                url = cards.backPic;
                title = cards.title;
                this.backimage.Value = cards.backPic;
                buttonCharacter = cards.buttonCharacter;

                imageback =   cards.backPic;
                music = cards.backMusic;

                if (MyCommFun.RequestInt("dh") != 0)
                {
                    dhId = MyCommFun.RequestInt("dh");
                }
                else
                {
                    dhId = MyCommFun.Obj2Int(cards.backCartoon);
                }

                if (MyCommFun.QueryString("name") != "")
                {
                    name = MyCommFun.QueryString("name");
                }
                else
                {
                    name = cards.name;
                }

                if (MyCommFun.QueryString("characters") != "")
                {
                    characters = MyCommFun.QueryString("characters");
                }
                else
                {
                    characters = cards.characters;
                }

              //查看次数
              gbll.updateck(id);

            }
        }
Esempio n. 3
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                BLL.wx_cards   gbll  = new BLL.wx_cards();
                Model.wx_cards cards = new Model.wx_cards();

                BLL.wx_cards_gl   countgbll   = new BLL.wx_cards_gl();
                Model.wx_cards_gl cardscountg = new Model.wx_cards_gl();

                id              = MyCommFun.RequestInt("aid");
                openid          = MyCommFun.RequestOpenid();
                wid             = MyCommFun.RequestInt("wid");
                this.hkid.Value = id.ToString();
                cards           = gbll.GetModel(id);

                characters = cards.characters;
                //name = cards.name;
                createDate           = cards.createDate.ToString();
                copyRight            = cards.copyRight;
                zfCount              = Convert.ToInt32(cards.zfCount);
                url                  = cards.backPic;
                title                = cards.title;
                this.backimage.Value = cards.backPic;
                buttonCharacter      = cards.buttonCharacter;

                imageback = cards.backPic;
                music     = cards.backMusic;

                if (MyCommFun.RequestInt("dh") != 0)
                {
                    dhId = MyCommFun.RequestInt("dh");
                }
                else
                {
                    dhId = MyCommFun.Obj2Int(cards.backCartoon);
                }

                if (MyCommFun.QueryString("name") != "")
                {
                    name = MyCommFun.QueryString("name");
                }
                else
                {
                    name = cards.name;
                }

                if (MyCommFun.QueryString("characters") != "")
                {
                    characters = MyCommFun.QueryString("characters");
                }
                else
                {
                    characters = cards.characters;
                }


                //查看次数
                gbll.updateck(id);
            }
        }