Commit dd5394b2 LN

1

1 个父辈 c42ef82f
...@@ -307,7 +307,13 @@ namespace TSA_V.LoadCSVLibrary ...@@ -307,7 +307,13 @@ namespace TSA_V.LoadCSVLibrary
Dictionary<string, ComponetInfo> map = new Dictionary<string, ComponetInfo>(); Dictionary<string, ComponetInfo> map = new Dictionary<string, ComponetInfo>();
foreach (ComponetInfo com in comList) foreach (ComponetInfo com in comList)
{ {
if (map.ContainsKey(com.PartNum))
{
LogUtil.error("新增元器件库:" + bomName + ", 位号【" + com.PartNum + "】已存在,跳过一行");
continue;
}
map.Add(com.PartNum, com); map.Add(com.PartNum, com);
} }
allComMap.Add(bomName, map); allComMap.Add(bomName, map);
return SaveComponet(bomName, comList); return SaveComponet(bomName, comList);
......
...@@ -73,7 +73,7 @@ ...@@ -73,7 +73,7 @@
<!--AOI程序文件夹--> <!--AOI程序文件夹-->
<add key="AOIFileConfig" value="\config\AOIConfig\" /> <add key="AOIFileConfig" value="\config\AOIConfig\" />
<!--是否启动AOI--> <!--是否启动AOI-->
<add key="IsNeedAOI" value="1" /> <add key="IsNeedAOI" value="0" />
<add key="DefaultPointSize" value="5" /> <add key="DefaultPointSize" value="5" />
<add key="DefaultPointType" value="1" /> <add key="DefaultPointType" value="1" />
<add key="Config_Pwd" value="123456" /> <add key="Config_Pwd" value="123456" />
......
...@@ -132,7 +132,10 @@ namespace TSA_V ...@@ -132,7 +132,10 @@ namespace TSA_V
MessageBox.Show(ResourceCulture.GetString(ResourceCulture.SaveOk,"保存成功!")); MessageBox.Show(ResourceCulture.GetString(ResourceCulture.SaveOk,"保存成功!"));
this.Close(); this.Close();
} }
else
{
MessageBox.Show(ResourceCulture.GetString(ResourceCulture.SaveError, "保存失败!"));
}
} }
...@@ -150,6 +153,10 @@ namespace TSA_V ...@@ -150,6 +153,10 @@ namespace TSA_V
this.Close(); this.Close();
} }
} }
else
{
MessageBox.Show(ResourceCulture.GetString(ResourceCulture.SaveError, "保存失败!"));
}
} }
......
...@@ -923,8 +923,13 @@ namespace TSA_V ...@@ -923,8 +923,13 @@ namespace TSA_V
private void btnWorkInfo_Click(object sender, EventArgs e) private void btnWorkInfo_Click(object sender, EventArgs e)
{ {
FrmWorkCount frm = new FrmWorkCount(); //FrmWorkCount frm = new FrmWorkCount();
frm.ShowDialog(); //frm.ShowDialog();
MesUtil.ClearCode();
FrmCodeInPut frmCode = new FrmCodeInPut();
frmCode.SetCount(1);
frmCode.ShowDialog(this);
} }
private static bool IsSet = false; private static bool IsSet = false;
private void TSAVBean_InputCodeEvent(int count) private void TSAVBean_InputCodeEvent(int count)
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!