WELOA.DAL/Equipment/sb_storageDAO.cs
(开头部分) 9KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using WELOA.Model;
using LSDAL_SQL;
using System.Data.SqlClient;
using System.Configuration;
using System.Data;
namespace SBDAL_SQL
{
public class sb_storageDAO
{
private DateSetInformation dsinfo = new DateSetInformation();
private ls_exception exlog = new ls_exception();
private ls_publicclass publicDAO = new ls_publicclass();
private Polytechnic trinfo = new Polytechnic();
public DateSetInformation select_Devicenumber(string strDevicenumber)
{
using (SqlConnection connection = new SqlConnection(ConfigurationManager.ConnectionStrings["lsstring"].ConnectionString))
{
SqlCommand command = connection.CreateCommand();
command.CommandText = "select * from [sb_storage] where devicenumber = @devicenumber Order by id desc";
command.Parameters.AddWithValue("@devicenumber", strDevicenumber);
SqlDataAdapter adapter = new SqlDataAdapter();
DataSet dataSet = new DataSet();
adapter.SelectCommand = command;
try
{
adapter.Fill(dataSet);
this.dsinfo.ds = dataSet;
}
catch (Exception exception)
{
this.exlog.insexception("sb_storageDAO.cs select_Devicenumber", exception.Message);
this.dsinfo.nException = 1;
return this.dsinfo;
}
}
return this.dsinfo;
}
public Polytechnic select_devicenumber_rowsCount(string strCategories)
{
using (SqlConnection connection = new SqlConnection(ConfigurationManager.ConnectionStrings["lsstring"].ConnectionString))
{
SqlCommand command = connection.CreateCommand();
command.CommandText = "select count(*) from [sb_storage] where categories = @strCategories ";
command.Parameters.AddWithValue("@strCategories", strCategories);
try
{
if (connection.State == ConnectionState.Closed)
{
connection.Open();
}
this.trinfo.rowscount = Convert.ToInt32(command.ExecuteScalar().ToString());
后面还有 173 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
