using System;
using System.Data;
using System.Data.SqlClient;
using DataLinkMesWork;
using System.Collections;
using System.Collections.Specialized;
//using SystemFramework;
namespace bizFacade
{
///
/// 电子看板信息系统
///
public partial class ShaftPosition
{
///
/// 测量数据合格_电子看板_质量数据_临时表_增加_返修工位
/// @EngineID nvarchar(50)=null,
/// @EngineType nvarchar(50)=null,
/// @EngineTypeID int = null,
/// @工位号 nvarchar(50)=null,
/// @工位号返修工位 nvarchar(50)=null,
/// @订单号 nvarchar(50)=null,
/// @合格标志 int
///
/// 工件号
/// 机型
/// 机型代码
/// 工位号(被返修的工位号)
/// 工位号返修工位
/// 订单号
/// 合格标志
static public void ShaftPosition_Data_OpNameRepair_Insert(string engineID, string engineType, int engineTypeID, string opName, string opNameRepair,string orderForm, int isOK)
{
string procedureName;
procedureName = "测量数据合格_电子看板_质量数据_临时表_增加_返修工位";
SqlParameter[] thisParmsSql = new SqlParameter[7];
thisParmsSql[0] = new SqlParameter("@EngineID", engineID);
thisParmsSql[1] = new SqlParameter("@EngineType", engineType);
thisParmsSql[2] = new SqlParameter("@EngineTypeID", engineTypeID);
thisParmsSql[3] = new SqlParameter("@工位号", opName);
thisParmsSql[4] = new SqlParameter("@工位号返修工位", opNameRepair);
thisParmsSql[5] = new SqlParameter("@订单号", orderForm);
thisParmsSql[6] = new SqlParameter("@合格标志", isOK);
DataAccess.ExecuteStoredProcedure(procedureName, ref thisParmsSql);
}
///
/// 测量数据合格_电子看板_质量数据_临时表_增加
/// @EngineID nvarchar(50)=null,
/// @EngineType nvarchar(50)=null,
/// @EngineTypeID int = null,
/// @工位号 nvarchar(50)=null,
/// @订单号 nvarchar(50)=null,
/// @合格标志 int
///
/// 工件号
/// 机型
/// 机型代码
/// 工位号
/// 订单号
/// 合格标志
static public void ShaftPosition_Data_Insert(string engineID, string engineType, int engineTypeID, string opName, string orderForm, int isOK)
{
string procedureName;
procedureName = "测量数据合格_电子看板_质量数据_临时表_增加";
SqlParameter[] thisParmsSql = new SqlParameter[6];
thisParmsSql[0] = new SqlParameter("@EngineID", engineID);
thisParmsSql[1] = new SqlParameter("@EngineType", engineType);
thisParmsSql[2] = new SqlParameter("@EngineTypeID", engineTypeID);
thisParmsSql[3] = new SqlParameter("@工位号", opName);
thisParmsSql[4] = new SqlParameter("@订单号", orderForm);
thisParmsSql[5] = new SqlParameter("@合格标志", isOK);
DataAccess.ExecuteStoredProcedure(procedureName, ref thisParmsSql);
}
///
///
///
///
///
///
///
///
///
///
///
static public void ShaftPosition_Data_Insert_RepairOpName(string opName, int shaftStep, string engineID, string engineType, int engineTypeID, int orderBy, string tagValue, int isOK)
{
string procedureName;
procedureName = "电子看板_质量数据_临时表_增加_备用拧紧工位";
SqlParameter[] thisParmsSql = new SqlParameter[8];
thisParmsSql[0] = new SqlParameter("@工位号", opName);
thisParmsSql[1] = new SqlParameter("@序号", shaftStep);
thisParmsSql[2] = new SqlParameter("@EngineID", engineID);
thisParmsSql[3] = new SqlParameter("@EngineType", engineType);
thisParmsSql[4] = new SqlParameter("@EngineTypeID", engineTypeID);
thisParmsSql[5] = new SqlParameter("@变量排序", orderBy);
thisParmsSql[6] = new SqlParameter("@测量值", tagValue);
thisParmsSql[7] = new SqlParameter("@合格标志", isOK);
DataAccess.ExecuteStoredProcedure(procedureName, ref thisParmsSql);
}
///
/// 电子看板_质量数据_临时表_增加
///
/// 工位号
/// 序号
/// 工件号
/// 机型
/// 机型代码
/// 变量代码
/// 变量值
/// 合格标志
static public void ShaftPosition_Data_Insert(string opName,int shaftStep, string engineID,string engineType, int engineTypeID, int tagID,string tagValue, int isOK)
{
string procedureName;
procedureName = "电子看板_质量数据_临时表_增加";
SqlParameter[] thisParmsSql = new SqlParameter[8];
thisParmsSql[0] = new SqlParameter("@工位号", opName);
thisParmsSql[1] = new SqlParameter("@序号", shaftStep);
thisParmsSql[2] = new SqlParameter("@EngineID", engineID);
thisParmsSql[3] = new SqlParameter("@EngineType", engineType);
thisParmsSql[4] = new SqlParameter("@EngineTypeID", engineTypeID);
thisParmsSql[5] = new SqlParameter("@TagID", tagID);
thisParmsSql[6] = new SqlParameter("@测量值", tagValue);
thisParmsSql[7] = new SqlParameter("@合格标志", isOK);
DataAccess.ExecuteStoredProcedure(procedureName, ref thisParmsSql);
}
///
/// 电子看板_质量数据_临时表_增加
///
/// 工位号
/// 序号
/// 工件号
/// 机型
/// 机型代码
/// 变量代码
/// 变量值
/// 合格标志
//static public void ShaftPosition_Data_Insert_Access(string opName, int shaftStep, string engineID, string engineType,
// int engineTypeID, int tagID, string tagValue, int isOK)
//{
// string sql;
// string sql_Delete;
// sql = "insert into 电子看板_质量数据_临时表(EngineID,EngineType,EngineTypeID,工位号,TagID,测量值,合格标志) ";
// sql = sql+" values(";
// sql = sql + "'" + engineID + "',";
// sql = sql + "'" + engineType + "',";
// sql = sql + "" + engineTypeID.ToString() + ",";
// sql = sql + "'" + opName + "',";
// sql = sql + "" + tagID.ToString() + ",";
// sql = sql + "'" + tagValue + "',";
// sql = sql + "" + isOK.ToString() + ")";
// sql_Delete = "delete from 电子看板_质量数据_临时表";
// sql_Delete = sql_Delete + " where tagID=" + tagID.ToString();
// DataAccess.ExecuteSQL_OleDb_Access(sql_Delete);
// DataAccess.ExecuteSQL_OleDb_Access(sql);
//}
///
/// 查询[电子看板_质量数据_临时表]数据
///
/// 工位号
/// 合格标志
//static public void ShaftPosition_Data_Select_Access(string opName, out DataTable dt)
//{
// string sql;
// sql = "select EngineID,EngineType,EngineTypeID,工位号,TagID,测量值 as TagValue,合格标志 as IsGoodBad";
// sql=sql+" from 电子看板_质量数据_临时表 ";
// sql = sql+" where 工位号='"+opName+"'";
// DataAccess.ExecuteDataTable_OleDb_Access(sql, out dt);
//}
///
/// 删除[电子看板_质量数据_临时表]数据
///
/// 工位号
//static public void ShaftPosition_Data_Delete_Access(string opName)
//{
// string sql;
// sql = "delete from 电子看板_质量数据_临时表 ";
// sql = sql + " where 工位号='" + opName + "'";
// DataAccess.ExecuteSQL_OleDb_Access(sql);
//}
///
/// 电子看板_质量数据_临时表_删除
///
/// 工位号
/// 列位置
/// EngineID
static public void ShaftPosition_Data_Delete(string opName, int shaftStep, string engineID)
{
string procedureName;
procedureName = "电子看板_质量数据_临时表_删除";
SqlParameter[] thisParmsSql = new SqlParameter[3];
thisParmsSql[0] = new SqlParameter("@工位号", opName);
thisParmsSql[1] = new SqlParameter("@列位置", shaftStep);
thisParmsSql[2] = new SqlParameter("@EngineID", engineID);
DataAccess.ExecuteStoredProcedure(procedureName, ref thisParmsSql);
}
}
}