DAL/Information.cs
(开头部分) 9KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Data;
using System.Text;
using System.Data.SqlClient;
using Maticsoft.DBUtility;//Please add references
namespace JY.DAL
{
/// <summary>
/// 数据访问类:Information
/// </summary>
public partial class Information
{
public Information()
{}
#region Method
/// <summary>
/// 是否存在该记录
/// </summary>
public bool Exists(long ID)
{
int rowsAffected;
SqlParameter[] parameters = {
new SqlParameter("@ID", SqlDbType.BigInt)
};
parameters[0].Value = ID;
int result= DbHelperSQL.RunProcedure("Information_Exists",parameters,out rowsAffected);
if(result==1)
{
return true;
}
else
{
return false;
}
}
/// <summary>
/// 增加一条数据
/// </summary>
public long Add(JY.Model.Information model)
{
int rowsAffected;
SqlParameter[] parameters = {
new SqlParameter("@ID", SqlDbType.BigInt,8),
new SqlParameter("@InformationTypeId", SqlDbType.Int,4),
new SqlParameter("@InformationName", SqlDbType.NVarChar,50),
new SqlParameter("@InformationContent", SqlDbType.NText),
new SqlParameter("@InformationPic", SqlDbType.NVarChar,50),
new SqlParameter("@Description", SqlDbType.NText),
new SqlParameter("@CreateDate", SqlDbType.DateTime),
new SqlParameter("@Sort", SqlDbType.Int,4),
new SqlParameter("@IsDelete", SqlDbType.Bit,1)};
parameters[0].Direction = ParameterDirection.Output;
parameters[1].Value = model.InformationTypeId;
parameters[2].Value = model.InformationName;
parameters[3].Value = model.InformationContent;
parameters[4].Value = model.InformationPic;
parameters[5].Value = model.Description;
后面还有 262 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
