DAL/zhuhuxinxi.cs

(开头部分) 9KB

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

using System;
using System.Data;
using System.Text;
using System.Data.SqlClient;
using Maticsoft.DBUtility;//Please add references
namespace Maticsoft.DAL
{
	/// <summary>
	/// 数据访问类:zhuhuxinxi
	/// </summary>
	public partial class zhuhuxinxi
	{
		public zhuhuxinxi()
		{}
		#region  BasicMethod



		/// <summary>
		/// 增加一条数据
		/// </summary>
		public int Add(Maticsoft.Model.zhuhuxinxi model)
		{
			StringBuilder strSql=new StringBuilder();
			strSql.Append("insert into zhuhuxinxi(");
			strSql.Append("bianhao,xingming,xingbie,dianhua,chushengnianyue,zhiye,jiguan,beizhu)");
			strSql.Append(" values (");
			strSql.Append("@bianhao,@xingming,@xingbie,@dianhua,@chushengnianyue,@zhiye,@jiguan,@beizhu)");
			strSql.Append(";select @@IDENTITY");
			SqlParameter[] parameters = {
					new SqlParameter("@bianhao", SqlDbType.VarChar,50),
					new SqlParameter("@xingming", SqlDbType.VarChar,50),
					new SqlParameter("@xingbie", SqlDbType.VarChar,50),
					new SqlParameter("@dianhua", SqlDbType.VarChar,50),
					new SqlParameter("@chushengnianyue", SqlDbType.VarChar,50),
					new SqlParameter("@zhiye", SqlDbType.VarChar,50),
					new SqlParameter("@jiguan", SqlDbType.VarChar,50),
					new SqlParameter("@beizhu", SqlDbType.VarChar,50)};
			parameters[0].Value = model.bianhao;
			parameters[1].Value = model.xingming;
			parameters[2].Value = model.xingbie;
			parameters[3].Value = model.dianhua;
			parameters[4].Value = model.chushengnianyue;
			parameters[5].Value = model.zhiye;
			parameters[6].Value = model.jiguan;
			parameters[7].Value = model.beizhu;

			object obj = DbHelperSQL.GetSingle(strSql.ToString(),parameters);
			if (obj == null)
			{
				return 0;
			}
			else
			{
				return Convert.ToInt32(obj);
			}
		}
		/// <summary>
		/// 更新一条数据
		/// </summary>
后面还有 278 行代码,购买后查看完整代码

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

AI 解读 AI

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

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