|
|
@@ -165,8 +165,9 @@ namespace UAS_MES.Make
|
|
|
ChoosedList.Clear();
|
|
|
if (LogicHandler.CheckStepAttribute(Tag.ToString(), User.UserSourceCode, out ErrorMessage))
|
|
|
{
|
|
|
- LogicHandler.GetMakeInfo(ms_sncode.Text, out oMakeCode, out ErrorMessage);
|
|
|
- if (LogicHandler.CheckStepSNAndMacode(ma_code.Text != oMakeCode && oMakeCode != "" ? oMakeCode : ma_code.Text, User.UserSourceCode, ms_sncode.Text, User.UserCode, out oMakeCode, out oMSID, out ErrorMessage))
|
|
|
+ string oStatus = "";
|
|
|
+ LogicHandler.GetMakeInfo(ms_sncode.Text, out oMakeCode, out oStatus, out ErrorMessage);
|
|
|
+ if (LogicHandler.CheckStepSNAndMacode(ma_code.Text != oMakeCode && oMakeCode != "" && oStatus != "2" ? oMakeCode : ma_code.Text, User.UserSourceCode, ms_sncode.Text, User.UserCode, out oMakeCode, out oMSID, out ErrorMessage))
|
|
|
{
|
|
|
if (ma_code.Text != oMakeCode && oMakeCode != null)
|
|
|
{
|
|
|
@@ -225,7 +226,7 @@ namespace UAS_MES.Make
|
|
|
sql.Append("select bg_code||':'||bg_name bg_name,bg_code from badgroup left join (select pb_badgroup,pr_kind ");
|
|
|
sql.Append("from product left join productkind on pk_name=pr_kind ");
|
|
|
sql.Append("left join productbadgroup on pk_code=PB_KINDCODE where pr_code='" + ma_prodcode.Text + "')");
|
|
|
- sql.Append("on pb_badgroup=bg_code order by case when bg_code='"+User.DefaultBadGroup+"' then 0 else 1 end");
|
|
|
+ sql.Append("on pb_badgroup=bg_code order by case when bg_code='" + User.DefaultBadGroup + "' then 0 else 1 end");
|
|
|
DataTable dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
|
|
|
bc_groupcode.DisplayMember = "bg_name";
|
|
|
bc_groupcode.ValueMember = "bg_code";
|
|
|
@@ -391,7 +392,8 @@ namespace UAS_MES.Make
|
|
|
if (LogicHandler.CheckStepAttribute(Tag.ToString(), User.UserSourceCode, out ErrorMessage))
|
|
|
{
|
|
|
//判断界面工单是否为空时的序列号是否自动归属工单
|
|
|
- if (!LogicHandler.GetMakeInfo(ms_sncode.Text, out oMakeCode, out ErrorMessage))
|
|
|
+ string oStatus = "";
|
|
|
+ if (!LogicHandler.GetMakeInfo(ms_sncode.Text, out oMakeCode, out oStatus, out ErrorMessage))
|
|
|
{
|
|
|
if (ma_code.Text == "")
|
|
|
{
|