|
|
@@ -1111,14 +1111,14 @@ namespace UAS_MES_NEW.PublicMethod
|
|
|
if (iIfRepeat != "-1")
|
|
|
{
|
|
|
//判定条码是否已经上料了
|
|
|
- dt = (DataTable)dh.ExecuteSql("select cm_barcode from craftmaterial where cm_barcode='" + iSN + "' and cm_status=0", "select");
|
|
|
+ dt = (DataTable)dh.ExecuteSql("select cm_barcode from craftmaterial where cm_barcode=:sn and cm_status=0", "select",iSN);
|
|
|
if (dt.Rows.Count > 0)
|
|
|
{
|
|
|
ErrMessage = "条码" + iSN + "已经上料";
|
|
|
return false;
|
|
|
}
|
|
|
}
|
|
|
- dt = (DataTable)dh.ExecuteSql("select bar_prodcode,bar_code from barcode where bar_code='" + iSN + "'", "select");
|
|
|
+ dt = (DataTable)dh.ExecuteSql("select bar_prodcode,bar_code from barcode where bar_code=:sn", "select",iSN);
|
|
|
if (dt.Rows.Count > 0)
|
|
|
{
|
|
|
string bar_prodcode = dt.Rows[0]["bar_prodcode"].ToString();
|
|
|
@@ -1145,7 +1145,7 @@ namespace UAS_MES_NEW.PublicMethod
|
|
|
case "RULE":
|
|
|
if (iIfRepeat != "-1")
|
|
|
{
|
|
|
- dt = (DataTable)dh.ExecuteSql("select cm_barcode from craftmaterial where cm_barcode='" + iSN + "' and cm_status=0", "select");
|
|
|
+ dt = (DataTable)dh.ExecuteSql("select cm_barcode from craftmaterial where cm_barcode=:sn and cm_status=0", "select",iSN);
|
|
|
if (dt.Rows.Count > 0)
|
|
|
{
|
|
|
ErrMessage = "条码" + iSN + "已经上料";
|