Medical/Html/ajax/setcomment.ashx.cs

(开头部分) 3KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

using System;
using System.Collections;
using System.Collections.Generic;
using System.Web.SessionState;
using System.Web;
using System.Configuration;

namespace WebApplication.Html.ajax
{
    /// <summary>
    /// setcomment 的摘要说明
    /// </summary>
    public class setcomment : IHttpHandler,IRequiresSessionState
    {

        public void ProcessRequest(HttpContext context)
        {
            context.Response.ContentType = "text/plain";
            if (context.Request["infoid"] != null && context.Request["title"] != null)
            {
                if (context.Session["LoginInfoID"] != null)
                {

                    BLL.Models.GZXX_Model bll = new BLL.Models.GZXX_Model();

                    Hashtable ht = new Hashtable();
                    ht.Add("Inputer", context.Session["LoginInfoID"]);
                    ht.Add("DepartID", 1);
                    ht.Add("UserInfoID", context.Session["LoginInfoID"]);
                    ht.Add("UserName", context.Session["LoginTitle"]);
                    ht.Add("Title", context.Request["title"]);
                    ht.Add("CPInfoID", context.Request["infoid"]);
                    ht.Add("ChannelID", 1000055);
                    ht.Add("ClassID", 97);
                    ht.Add("Content", context.Request["content"]);
                    ht.Add("CreateDate", DateTime.Parse(DBUtility.DbHelperSQL.GetSingle("select getdate()").ToString()).ToString("yyyy-MM-dd HH:mm:ss"));

                    int infoid = bll.AddContent("GZXX_U_Comment", ht);

                    if (infoid > 0)
                    {
                        Hashtable h = new Hashtable();
                        h.Add("Inputer", context.Session["LoginInfoID"]);
                        h.Add("DepartID", 1);
                        h.Add("ChannelID", 1000065);
                        h.Add("ClassID", 142);
                        h.Add("Title", context.Session["LoginTitle"]);
                        h.Add("CreateDate", DateTime.Parse(DBUtility.DbHelperSQL.GetSingle("select getdate()").ToString()).ToString("yyyy-MM-dd HH:mm:ss"));
                        h.Add("UserInfoID", context.Session["LoginInfoID"]);
                        h.Add("Score", ConfigurationManager.AppSettings["PLScore"]);
                        h.Add("CPInfoID", context.Request["infoid"]);
                        List<DBUtility.CommandInfo> list = new List<DBUtility.CommandInfo>();
                        DBUtility.CommandInfo info = new DBUtility.CommandInfo();
                        info.CommandText = "update GZXX_U_UserTable set Score = IsNull(Score,0) + " + int.Parse(ConfigurationManager.AppSettings["PLScore"]) + " where InfoID = " + context.Session["LoginInfoID"];
                        info.Parameters = null;
                        info.EffentNextType = DBUtility.EffentNextType.ExcuteEffectRows;
                        list.Add(info);
                        bll.AddContent("GZXX_U_Score", h, list);


后面还有 27 行代码,购买后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明

AI 解读

登录后可用,每次 10 积分,解读结果公开显示在下面。

还没有人解读过这个文件。