using System;
|
using System.Collections.Generic;
|
using System.Text;
|
using System.Data;
|
|
namespace DAL
|
{
|
public class ClsK3_Mould_Ctl:DBUtility.ClsGy_Base_Ctl
|
{
|
SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
|
|
public Model.ClsK3_Mould_Model oModel ;
|
//新增
|
public override bool AddNew()
|
{
|
|
try
|
{
|
oCn.BeginTran();
|
base.DeleteByID(oModel.HItemID);
|
oCn.RunProc("Insert into " + MvarItemKey + " " +
|
" (HItemID,HNumber,HBarCode" +
|
",HPhaseFlag,HhgNumber,HProcID) " +
|
" Values(" + oModel.HItemID.ToString() + ",'" + oModel.HNumber + "','" + oModel.HBarCode + "'" +
|
"," + Convert.ToString(oModel.HPhaseFlag ? 1 : 0) + ",'" + oModel.HhgNumber + "'," + oModel.HProcID.ToString() + ")", ref DBUtility.ClsPub.sExeReturnInfo);
|
oCn.Commit();
|
return true;
|
}
|
catch (Exception e)
|
{
|
oCn.RollBack();
|
throw (e);
|
}
|
}
|
|
//构造函数
|
public ClsK3_Mould_Ctl()
|
{
|
MvarItemKey = "K3_Mould_Extend";
|
MvarReportTitle = "模具设置";
|
oModel = new Model.ClsK3_Mould_Model();
|
}
|
}
|
}
|