using System;
using System.Collections.Generic;
using System.Text;
using System.Data;
using SysBaseLibs;
using System.Web.Script.Serialization;
namespace SysDataLibs.TableClass
{
#region FSOnlineComplaints
public class FSOnlineComplaints_info : ITableInfo
{
#region FSOnlineComplaints表 字段信息
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: varchar;
/// 数据长度: 50;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 受理人;
///
public const string cAcceptancePeople = "AcceptancePeople";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: varchar;
/// 数据长度: 50;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 交办单号;
///
public const string cAssignedNo = "AssignedNo";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: nvarchar;
/// 数据长度: 100;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 承办部门编号;
///
public const string cComplaintsDept = "ComplaintsDept";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: varchar;
/// 数据长度: 50;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 举报投诉形式;
///
public const string cComplaintType = "ComplaintType";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: varchar;
/// 数据长度: 50;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 举报投诉人电话;
///
public const string cContactTel = "ContactTel";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: datetime;
/// 数据长度: 8;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 投诉举报时间;
///
public const string cCreateDate = "CreateDate";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: datetime;
/// 数据长度: 8;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 要求反馈时间;
///
public const string cEndHandleDate = "EndHandleDate";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: int;
/// 数据长度: 4;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 要求反馈天数;
///
public const string cEndHandleDateCount = "EndHandleDateCount";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: int;
/// 数据长度: 4;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 是否审核;
///
public const string cIsAudit = "IsAudit";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: int;
/// 数据长度: 4;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 是否删除;
///
public const string cIsDeleted = "IsDeleted";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: int;
/// 数据长度: 4;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 是否回复;
///
public const string cIsReply = "IsReply";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: text;
/// 数据长度: 16;
/// 是否允许为空: N;
/// 默认值: ;
/// 描述: 投诉举报内容;
///
public const string cOnlineComplaintsContent = "OnlineComplaintsContent";
///
/// 为关键字段: Y --- PrimaryKey;
/// 自动增长: N;
/// 数据类型: varchar;
/// 数据长度: 50;
/// 是否允许为空: N;
/// 默认值: ;
/// 描述: 编号;
///
public const string cOnlineComplaintsID = "OnlineComplaintsID";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: varchar;
/// 数据长度: 50;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 投诉举报人IP;
///
public const string cOnlineComplaintsIP = "OnlineComplaintsIP";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: nvarchar;
/// 数据长度: 100;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 投诉举报人姓名;
///
public const string cOnlineComplaintsName = "OnlineComplaintsName";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: text;
/// 数据长度: 16;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 备注信息;
///
public const string cOnlineComplaintsRemark = "OnlineComplaintsRemark";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: text;
/// 数据长度: 16;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 回复内容;
///
public const string cReplyContent = "ReplyContent";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: datetime;
/// 数据长度: 8;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 回复时间;
///
public const string cReplyDate = "ReplyDate";
///
/// 为关键字段: N ;
/// 自动增长: N;
/// 数据类型: nvarchar;
/// 数据长度: 100;
/// 是否允许为空: Y;
/// 默认值: ;
/// 描述: 回复人;
///
public const string cReplyPeople = "ReplyPeople";
#endregion
public FSOnlineComplaints_info() { }
public FSOnlineComplaints_info(DataRow poRow)
{
CreateTableInfo(poRow);
}
public void CreateTableInfo(DataRow poRow)
{
_AcceptancePeople = UtilStr.StrFromObj(poRow[cAcceptancePeople]);
_AssignedNo = UtilStr.StrFromObj(poRow[cAssignedNo]);
_ComplaintsDept = UtilStr.StrFromObj(poRow[cComplaintsDept]);
_ComplaintType = UtilStr.StrFromObj(poRow[cComplaintType]);
_ContactTel = UtilStr.StrFromObj(poRow[cContactTel]);
_CreateDate = UtilStr.StrFromObj(poRow[cCreateDate]);
_EndHandleDate = UtilStr.StrFromObj(poRow[cEndHandleDate]);
_EndHandleDateCount = UtilStr.StrFromObj(poRow[cEndHandleDateCount]);
_IsAudit = UtilStr.StrFromObj(poRow[cIsAudit]);
_IsDeleted = UtilStr.StrFromObj(poRow[cIsDeleted]);
_IsReply = UtilStr.StrFromObj(poRow[cIsReply]);
_OnlineComplaintsContent = UtilStr.StrFromObj(poRow[cOnlineComplaintsContent]);
_OnlineComplaintsID = UtilStr.StrFromObj(poRow[cOnlineComplaintsID]);
_OnlineComplaintsIP = UtilStr.StrFromObj(poRow[cOnlineComplaintsIP]);
_OnlineComplaintsName = UtilStr.StrFromObj(poRow[cOnlineComplaintsName]);
_OnlineComplaintsRemark = UtilStr.StrFromObj(poRow[cOnlineComplaintsRemark]);
_ReplyContent = UtilStr.StrFromObj(poRow[cReplyContent]);
_ReplyDate = UtilStr.StrFromObj(poRow[cReplyDate]);
_ReplyPeople = UtilStr.StrFromObj(poRow[cReplyPeople]);
}
public FSOnlineComplaints_info(string pcOnlineComplaintsID, DBConnSql poDBConn)
{
if (pcOnlineComplaintsID.Trim().Length > 0 && poDBConn != null)
{
string lcSql = "select * from " + Tn.FSOnlineComplaints + " where OnlineComplaintsID='" + pcOnlineComplaintsID + "'";
rsQuery loQuery = poDBConn.OpenQuery(lcSql);
if (loQuery != null && loQuery.IsOpened && loQuery.RecCount == 1)
{
loQuery.MoveFirst();
CreateTableInfo(loQuery.CurrentRow);
}
}
}
private string _AcceptancePeople = "";
public string AcceptancePeople
{
get { return _AcceptancePeople; }
set { _AcceptancePeople = value; }
}
private string _AssignedNo = "";
public string AssignedNo
{
get { return _AssignedNo; }
set { _AssignedNo = value; }
}
private string _ComplaintsDept = "";
public string ComplaintsDept
{
get { return _ComplaintsDept; }
set { _ComplaintsDept = value; }
}
private string _ComplaintType = "";
public string ComplaintType
{
get { return _ComplaintType; }
set { _ComplaintType = value; }
}
private string _ContactTel = "";
public string ContactTel
{
get { return _ContactTel; }
set { _ContactTel = value; }
}
private string _CreateDate = "";
public string CreateDate
{
get { return _CreateDate; }
set { _CreateDate = value; }
}
private string _EndHandleDate = "";
public string EndHandleDate
{
get { return _EndHandleDate; }
set { _EndHandleDate = value; }
}
private string _EndHandleDateCount = "";
public string EndHandleDateCount
{
get { return _EndHandleDateCount; }
set { _EndHandleDateCount = value; }
}
private string _IsAudit = "";
public string IsAudit
{
get { return _IsAudit; }
set { _IsAudit = value; }
}
private string _IsDeleted = "";
public string IsDeleted
{
get { return _IsDeleted; }
set { _IsDeleted = value; }
}
private string _IsReply = "";
public string IsReply
{
get { return _IsReply; }
set { _IsReply = value; }
}
private string _OnlineComplaintsContent = "";
public string OnlineComplaintsContent
{
get { return _OnlineComplaintsContent; }
set { _OnlineComplaintsContent = value; }
}
private string _OnlineComplaintsID = "";
public string OnlineComplaintsID
{
get { return _OnlineComplaintsID; }
set { _OnlineComplaintsID = value; }
}
private string _OnlineComplaintsIP = "";
public string OnlineComplaintsIP
{
get { return _OnlineComplaintsIP; }
set { _OnlineComplaintsIP = value; }
}
private string _OnlineComplaintsName = "";
public string OnlineComplaintsName
{
get { return _OnlineComplaintsName; }
set { _OnlineComplaintsName = value; }
}
private string _OnlineComplaintsRemark = "";
public string OnlineComplaintsRemark
{
get { return _OnlineComplaintsRemark; }
set { _OnlineComplaintsRemark = value; }
}
private string _ReplyContent = "";
public string ReplyContent
{
get { return _ReplyContent; }
set { _ReplyContent = value; }
}
private string _ReplyDate = "";
public string ReplyDate
{
get { return _ReplyDate; }
set { _ReplyDate = value; }
}
private string _ReplyPeople = "";
public string ReplyPeople
{
get { return _ReplyPeople; }
set { _ReplyPeople = value; }
}
[ScriptIgnore]
public rsXmlNode DataXMLNode
{
get
{
rsXmlNode loMainNode = new rsXmlNode("FSOnlineComplaintsRecord", "");
rsXmlNode loNode = null;
loNode = new rsXmlNode(cAcceptancePeople, AcceptancePeople);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cAssignedNo, AssignedNo);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cComplaintsDept, ComplaintsDept);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cComplaintType, ComplaintType);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cContactTel, ContactTel);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cCreateDate, CreateDate);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cEndHandleDate, EndHandleDate);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cEndHandleDateCount, EndHandleDateCount);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cIsAudit, IsAudit);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cIsDeleted, IsDeleted);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cIsReply, IsReply);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cOnlineComplaintsContent, OnlineComplaintsContent);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cOnlineComplaintsID, OnlineComplaintsID);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cOnlineComplaintsIP, OnlineComplaintsIP);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cOnlineComplaintsName, OnlineComplaintsName);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cOnlineComplaintsRemark, OnlineComplaintsRemark);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cReplyContent, ReplyContent);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cReplyDate, ReplyDate);
loMainNode.AddChild(loNode);
loNode = new rsXmlNode(cReplyPeople, ReplyPeople);
loMainNode.AddChild(loNode);
return loMainNode;
}
}
public string InsertSql()
{
return " insert into " + Tn.FSOnlineComplaints + " " +
" (" + cOnlineComplaintsID + "," + cOnlineComplaintsIP + "," + cOnlineComplaintsName + "," + cOnlineComplaintsContent + "," + cIsAudit + "," + cIsDeleted + "," + cIsReply +
"," + cCreateDate + "," + cComplaintsDept + "," + cReplyPeople + "," + cReplyDate + "," + cReplyContent + "," + cEndHandleDateCount + "," + cEndHandleDate + "," + cOnlineComplaintsRemark +
"," + cContactTel + "," + cComplaintType + "," + cAssignedNo + "," + cAcceptancePeople + ") " +
" values ('" + _OnlineComplaintsID + "','" + _OnlineComplaintsIP + "','" + _OnlineComplaintsName + "','" + _OnlineComplaintsContent + "'," + _IsAudit +
"," + _IsDeleted + "," + _IsReply + ",'" + _CreateDate + "','" + _ComplaintsDept + "','" + _ReplyPeople + "','" + _ReplyDate + "','" + _ReplyContent + "'," + _EndHandleDateCount +
",'" + _EndHandleDate + "','" + _OnlineComplaintsRemark + "','" + _ContactTel + "','" + _ComplaintType + "','" + _AssignedNo + "','" + _AcceptancePeople + "') ";
}
public string UpdateReplySql()
{
return " update " + Tn.FSOnlineComplaints + " " +
" set " + cIsReply + "=1," + cReplyDate + "='" + _ReplyDate + "', " + cReplyPeople + "='" + _ReplyPeople + "'," + cReplyContent + "='" + _ReplyContent + "' " +
" where " + cOnlineComplaintsID + "='" + _OnlineComplaintsID + "'";
}
public string UpdateDelaySql()
{
return " update " + Tn.FSOnlineComplaints + " " +
" set " + cEndHandleDate + "='" + _EndHandleDate + "' " +
" where " + cOnlineComplaintsID + "='" + _OnlineComplaintsID + "'";
}
public string UpdateComplaintsDeptSql()
{
return " update " + Tn.FSOnlineComplaints + " " +
" set " + cComplaintsDept + "='" + _ComplaintsDept + "' " +
" where " + cOnlineComplaintsID + "='" + _OnlineComplaintsID + "'";
}
public string DeleteSql()
{
return "Delete " + Tn.FSOnlineComplaints + " where " + cOnlineComplaintsID + "='" + _OnlineComplaintsID + "'";
}
/*public static int hasNotRead(string pcType, UserSession poSession)
{
string lcSql = "select count(*) as mscount from " + Tn.FSOnlineComplaints + " where " + BulletinInfo_info.cBulletinTypeID + "='" + pcType +
"' and " + BulletinInfo_info.cID + " not in (select " + Sys_AttachTables_info.cSourceKey + " from " + Tn.Sys_AttachTables + " where " + Sys_AttachTables_info.cTableId + "='" + Tn.BulletinInfo + "' and " + Sys_AttachTables_info.cUserID + "='" + poSession.UserInfo.UserID + "')";
rsQuery loQuery = poSession.DBConn.OpenQuery(lcSql);
if (loQuery != null && loQuery.IsOpened)
{
return loQuery.GetInt("mscount");
}
return 0;
}*/
}
#endregion
#region
public class FSOnlineComplaints_Qry : rsQuery
{
public String AcceptancePeople
{
get { return GetString(FSOnlineComplaints_info.cAcceptancePeople); }
// set { SetField(FSOnlineComplaints_info.cAcceptancePeople, value); }
}
public String AssignedNo
{
get { return GetString(FSOnlineComplaints_info.cAssignedNo); }
// set { SetField(FSOnlineComplaints_info.cAssignedNo, value); }
}
public String ComplaintsDept
{
get { return GetString(FSOnlineComplaints_info.cComplaintsDept); }
// set { SetField(FSOnlineComplaints_info.cComplaintsDept, value); }
}
public String ComplaintType
{
get { return GetString(FSOnlineComplaints_info.cComplaintType); }
// set { SetField(FSOnlineComplaints_info.cComplaintType, value); }
}
public String ContactTel
{
get { return GetString(FSOnlineComplaints_info.cContactTel); }
// set { SetField(FSOnlineComplaints_info.cContactTel, value); }
}
public DateTime CreateDate
{
get { return GetDateTime(FSOnlineComplaints_info.cCreateDate); }
// set { SetField(FSOnlineComplaints_info.cCreateDate, value); }
}
public DateTime EndHandleDate
{
get { return GetDateTime(FSOnlineComplaints_info.cEndHandleDate); }
// set { SetField(FSOnlineComplaints_info.cEndHandleDate, value); }
}
public Int64 EndHandleDateCount
{
get { return GetInt(FSOnlineComplaints_info.cEndHandleDateCount); }
// set { SetField(FSOnlineComplaints_info.cEndHandleDateCount, value); }
}
public Int64 IsAudit
{
get { return GetInt(FSOnlineComplaints_info.cIsAudit); }
// set { SetField(FSOnlineComplaints_info.cIsAudit, value); }
}
public Int64 IsDeleted
{
get { return GetInt(FSOnlineComplaints_info.cIsDeleted); }
// set { SetField(FSOnlineComplaints_info.cIsDeleted, value); }
}
public Int64 IsReply
{
get { return GetInt(FSOnlineComplaints_info.cIsReply); }
// set { SetField(FSOnlineComplaints_info.cIsReply, value); }
}
public String OnlineComplaintsContent
{
get { return GetString(FSOnlineComplaints_info.cOnlineComplaintsContent); }
// set { SetField(FSOnlineComplaints_info.cOnlineComplaintsContent, value); }
}
public String OnlineComplaintsID
{
get { return GetString(FSOnlineComplaints_info.cOnlineComplaintsID); }
// set { SetField(FSOnlineComplaints_info.cOnlineComplaintsID, value); }
}
public String OnlineComplaintsIP
{
get { return GetString(FSOnlineComplaints_info.cOnlineComplaintsIP); }
// set { SetField(FSOnlineComplaints_info.cOnlineComplaintsIP, value); }
}
public String OnlineComplaintsName
{
get { return GetString(FSOnlineComplaints_info.cOnlineComplaintsName); }
// set { SetField(FSOnlineComplaints_info.cOnlineComplaintsName, value); }
}
public String OnlineComplaintsRemark
{
get { return GetString(FSOnlineComplaints_info.cOnlineComplaintsRemark); }
// set { SetField(FSOnlineComplaints_info.cOnlineComplaintsRemark, value); }
}
public String ReplyContent
{
get { return GetString(FSOnlineComplaints_info.cReplyContent); }
// set { SetField(FSOnlineComplaints_info.cReplyContent, value); }
}
public DateTime ReplyDate
{
get { return GetDateTime(FSOnlineComplaints_info.cReplyDate); }
// set { SetField(FSOnlineComplaints_info.cReplyDate, value); }
}
public String ReplyPeople
{
get { return GetString(FSOnlineComplaints_info.cReplyPeople); }
// set { SetField(FSOnlineComplaints_info.cReplyPeople, value); }
}
}
#endregion
}