|
|
@@ -490,7 +490,7 @@ namespace UAS_MES.Make
|
|
|
}
|
|
|
}
|
|
|
//验证是否已被使用
|
|
|
- string temSn = dh.getFieldDataByCondition("makeserial", "ms_sncode", "MS_mac='" + macOrBt + "'or ms_bt='"+macOrBt+"' and ms_status in (0,1,2,3) and ms_id <> '" + oMsid + "'").ToString();
|
|
|
+ string temSn = dh.getFieldDataByCondition("makeserial", "ms_sncode", "(MS_mac='" + macOrBt + "'or ms_bt='"+macOrBt+"') and ms_status in (0,1,2,3) and ms_id <> '" + oMsid + "'").ToString();
|
|
|
if (temSn != "")
|
|
|
{
|
|
|
OperateResult.AppendText("<<" + ListA.Rows[step - 2]["psr_type"].ToString() + ":" + code.Text + "错误,已被序列号" + temSn + "使用\n", Color.Red);
|
|
|
@@ -500,7 +500,7 @@ namespace UAS_MES.Make
|
|
|
else
|
|
|
{
|
|
|
//校验在sninfo表中是否存在
|
|
|
- temSn = dh.getFieldDataByCondition("sninfo", "si_sn", "si_mac='" + macOrBt + "' or si_bt='"+macOrBt+"' and si_id <>'" + siid + "'").ToString();
|
|
|
+ temSn = dh.getFieldDataByCondition("sninfo", "si_sn", "(si_mac='" + macOrBt + "' or si_bt='"+macOrBt+"') and si_id <>'" + siid + "'").ToString();
|
|
|
if (temSn != "")
|
|
|
{
|
|
|
OperateResult.AppendText("<<" + ListA.Rows[step - 2]["psr_type"].ToString() + ":" + code.Text + "错误,已被序列号" + temSn + "使用\n", Color.Red);
|