Commit d5765fc4 LN

工作界面增加补料按钮。

1 个父辈 659eab71
...@@ -2814,4 +2814,6 @@ ...@@ -2814,4 +2814,6 @@
<data name = "Column_imgName" xml:space = "preserve"> <value> Image Name </value> </data> <data name = "Column_imgName" xml:space = "preserve"> <value> Image Name </value> </data>
<data name = "Column_img" xml:space = "preserve"> <value> Image </value> </data> <data name = "Column_img" xml:space = "preserve"> <value> Image </value> </data>
<data name = "PWSureXuanzhuan" xml:space = "preserve"> <value> Rotate clockwise {0} degrees with the bottom left corner as the reference? </value> </data> <data name = "PWSureXuanzhuan" xml:space = "preserve"> <value> Rotate clockwise {0} degrees with the bottom left corner as the reference? </value> </data>
<data name = "FrmWork_lkPutCom_Text" xml:space = "preserve"> <value> Replenishment </value> </data>
<data name = "FrmWork_lklUpdateNum_Text" xml:space = "preserve"> <value> Modify </value> </data>
</root> </root>
\ No newline at end of file \ No newline at end of file
...@@ -2792,4 +2792,6 @@ ...@@ -2792,4 +2792,6 @@
<data name = "Column_imgName" xml:space = "preserve"> <value> 图片名称 </value> </data> <data name = "Column_imgName" xml:space = "preserve"> <value> 图片名称 </value> </data>
<data name = "Column_img" xml:space = "preserve"> <value> 图片 </value> </data> <data name = "Column_img" xml:space = "preserve"> <value> 图片 </value> </data>
<data name = "PWSureXuanzhuan" xml:space = "preserve"> <value> 以左下角为基准顺时针旋转{0}度? </value> </data> <data name = "PWSureXuanzhuan" xml:space = "preserve"> <value> 以左下角为基准顺时针旋转{0}度? </value> </data>
<data name = "FrmWork_lkPutCom_Text" xml:space = "preserve"> <value> 补料 </value> </data>
<data name = "FrmWork_lklUpdateNum_Text" xml:space = "preserve"> <value> 修改 </value> </data>
</root> </root>
\ No newline at end of file \ No newline at end of file
...@@ -3036,4 +3036,6 @@ ...@@ -3036,4 +3036,6 @@
<data name = "Column_imgName" xml:space = "preserve"> <value> 图片名称 </value> </data> <data name = "Column_imgName" xml:space = "preserve"> <value> 图片名称 </value> </data>
<data name = "Column_img" xml:space = "preserve"> <value> 图片 </value> </data> <data name = "Column_img" xml:space = "preserve"> <value> 图片 </value> </data>
<data name = "PWSureXuanzhuan" xml:space = "preserve"> <value> 以左下角为基准顺时针旋转{0}度? </value> </data> <data name = "PWSureXuanzhuan" xml:space = "preserve"> <value> 以左下角为基准顺时针旋转{0}度? </value> </data>
<data name = "FrmWork_lkPutCom_Text" xml:space = "preserve"> <value> 补料 </value> </data>
<data name = "FrmWork_lklUpdateNum_Text" xml:space = "preserve"> <value> 修改 </value> </data>
</root> </root>
\ No newline at end of file \ No newline at end of file
...@@ -104,6 +104,8 @@ ...@@ -104,6 +104,8 @@
this.groupPNImg = new System.Windows.Forms.GroupBox(); this.groupPNImg = new System.Windows.Forms.GroupBox();
this.panPNImg = new System.Windows.Forms.Panel(); this.panPNImg = new System.Windows.Forms.Panel();
this.picPNImg = new System.Windows.Forms.PictureBox(); this.picPNImg = new System.Windows.Forms.PictureBox();
this.lklUpdateNum = new System.Windows.Forms.LinkLabel();
this.lkPutCom = new System.Windows.Forms.LinkLabel();
this.groupBox3.SuspendLayout(); this.groupBox3.SuspendLayout();
this.groupBox1.SuspendLayout(); this.groupBox1.SuspendLayout();
this.groupBox2.SuspendLayout(); this.groupBox2.SuspendLayout();
...@@ -198,9 +200,9 @@ ...@@ -198,9 +200,9 @@
| System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right))); | System.Windows.Forms.AnchorStyles.Right)));
this.lblGuoBan.Font = new System.Drawing.Font("微软雅黑", 21.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.lblGuoBan.Font = new System.Drawing.Font("微软雅黑", 21.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblGuoBan.Location = new System.Drawing.Point(13, 17); this.lblGuoBan.Location = new System.Drawing.Point(6, 17);
this.lblGuoBan.Name = "lblGuoBan"; this.lblGuoBan.Name = "lblGuoBan";
this.lblGuoBan.Size = new System.Drawing.Size(625, 64); this.lblGuoBan.Size = new System.Drawing.Size(629, 64);
this.lblGuoBan.TabIndex = 285; this.lblGuoBan.TabIndex = 285;
this.lblGuoBan.Text = "过板模式"; this.lblGuoBan.Text = "过板模式";
this.lblGuoBan.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; this.lblGuoBan.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
...@@ -316,6 +318,8 @@ ...@@ -316,6 +318,8 @@
// //
// groupBox1 // groupBox1
// //
this.groupBox1.Controls.Add(this.lkPutCom);
this.groupBox1.Controls.Add(this.lklUpdateNum);
this.groupBox1.Controls.Add(this.btnCancel); this.groupBox1.Controls.Add(this.btnCancel);
this.groupBox1.Controls.Add(this.btnSave); this.groupBox1.Controls.Add(this.btnSave);
this.groupBox1.Controls.Add(this.lblComNotices); this.groupBox1.Controls.Add(this.lblComNotices);
...@@ -348,7 +352,7 @@ ...@@ -348,7 +352,7 @@
// //
this.btnCancel.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnCancel.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnCancel.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnCancel.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnCancel.Location = new System.Drawing.Point(558, 71); this.btnCancel.Location = new System.Drawing.Point(536, 71);
this.btnCancel.Name = "btnCancel"; this.btnCancel.Name = "btnCancel";
this.btnCancel.Size = new System.Drawing.Size(68, 43); this.btnCancel.Size = new System.Drawing.Size(68, 43);
this.btnCancel.TabIndex = 281; this.btnCancel.TabIndex = 281;
...@@ -361,7 +365,7 @@ ...@@ -361,7 +365,7 @@
// //
this.btnSave.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnSave.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnSave.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnSave.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnSave.Location = new System.Drawing.Point(489, 71); this.btnSave.Location = new System.Drawing.Point(467, 71);
this.btnSave.Name = "btnSave"; this.btnSave.Name = "btnSave";
this.btnSave.Size = new System.Drawing.Size(68, 43); this.btnSave.Size = new System.Drawing.Size(68, 43);
this.btnSave.TabIndex = 280; this.btnSave.TabIndex = 280;
...@@ -409,7 +413,7 @@ ...@@ -409,7 +413,7 @@
this.lblPositionNum.AutoSize = true; this.lblPositionNum.AutoSize = true;
this.lblPositionNum.Font = new System.Drawing.Font("微软雅黑", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.lblPositionNum.Font = new System.Drawing.Font("微软雅黑", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblPositionNum.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(192)))), ((int)(((byte)(192))))); this.lblPositionNum.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(192)))), ((int)(((byte)(192)))));
this.lblPositionNum.Location = new System.Drawing.Point(514, 9); this.lblPositionNum.Location = new System.Drawing.Point(492, 9);
this.lblPositionNum.Name = "lblPositionNum"; this.lblPositionNum.Name = "lblPositionNum";
this.lblPositionNum.Size = new System.Drawing.Size(50, 26); this.lblPositionNum.Size = new System.Drawing.Size(50, 26);
this.lblPositionNum.TabIndex = 8; this.lblPositionNum.TabIndex = 8;
...@@ -464,10 +468,10 @@ ...@@ -464,10 +468,10 @@
// txtCount // txtCount
// //
this.txtCount.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.txtCount.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.txtCount.Location = new System.Drawing.Point(512, 42); this.txtCount.Location = new System.Drawing.Point(490, 42);
this.txtCount.MaxLength = 6; this.txtCount.MaxLength = 6;
this.txtCount.Name = "txtCount"; this.txtCount.Name = "txtCount";
this.txtCount.Size = new System.Drawing.Size(88, 26); this.txtCount.Size = new System.Drawing.Size(80, 26);
this.txtCount.TabIndex = 278; this.txtCount.TabIndex = 278;
this.txtCount.Visible = false; this.txtCount.Visible = false;
// //
...@@ -501,7 +505,7 @@ ...@@ -501,7 +505,7 @@
this.label5.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.label5.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label5.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(192)))), ((int)(((byte)(192))))); this.label5.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(192)))), ((int)(((byte)(192)))));
this.label5.ImageAlign = System.Drawing.ContentAlignment.MiddleRight; this.label5.ImageAlign = System.Drawing.ContentAlignment.MiddleRight;
this.label5.Location = new System.Drawing.Point(356, 46); this.label5.Location = new System.Drawing.Point(334, 46);
this.label5.Name = "label5"; this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(157, 19); this.label5.Size = new System.Drawing.Size(157, 19);
this.label5.TabIndex = 274; this.label5.TabIndex = 274;
...@@ -513,7 +517,7 @@ ...@@ -513,7 +517,7 @@
this.lblCount.AutoSize = true; this.lblCount.AutoSize = true;
this.lblCount.Font = new System.Drawing.Font("微软雅黑", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.lblCount.Font = new System.Drawing.Font("微软雅黑", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblCount.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(192)))), ((int)(((byte)(192))))); this.lblCount.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(192)))), ((int)(((byte)(192)))));
this.lblCount.Location = new System.Drawing.Point(514, 42); this.lblCount.Location = new System.Drawing.Point(492, 43);
this.lblCount.Name = "lblCount"; this.lblCount.Name = "lblCount";
this.lblCount.Size = new System.Drawing.Size(50, 26); this.lblCount.Size = new System.Drawing.Size(50, 26);
this.lblCount.TabIndex = 273; this.lblCount.TabIndex = 273;
...@@ -535,7 +539,7 @@ ...@@ -535,7 +539,7 @@
this.label4.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.label4.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label4.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(192)))), ((int)(((byte)(192))))); this.label4.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(192)))), ((int)(((byte)(192)))));
this.label4.ImageAlign = System.Drawing.ContentAlignment.MiddleRight; this.label4.ImageAlign = System.Drawing.ContentAlignment.MiddleRight;
this.label4.Location = new System.Drawing.Point(356, 13); this.label4.Location = new System.Drawing.Point(334, 13);
this.label4.Name = "label4"; this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(157, 19); this.label4.Size = new System.Drawing.Size(157, 19);
this.label4.TabIndex = 7; this.label4.TabIndex = 7;
...@@ -991,6 +995,30 @@ ...@@ -991,6 +995,30 @@
this.picPNImg.TabIndex = 1; this.picPNImg.TabIndex = 1;
this.picPNImg.TabStop = false; this.picPNImg.TabStop = false;
// //
// lklUpdateNum
//
this.lklUpdateNum.ImageAlign = System.Drawing.ContentAlignment.MiddleRight;
this.lklUpdateNum.Location = new System.Drawing.Point(572, 46);
this.lklUpdateNum.Name = "lklUpdateNum";
this.lklUpdateNum.Size = new System.Drawing.Size(64, 17);
this.lklUpdateNum.TabIndex = 284;
this.lklUpdateNum.TabStop = true;
this.lklUpdateNum.Text = "修改";
this.lklUpdateNum.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
this.lklUpdateNum.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.lklUpdateNum_LinkClicked);
//
// lkPutCom
//
this.lkPutCom.ImageAlign = System.Drawing.ContentAlignment.MiddleRight;
this.lkPutCom.Location = new System.Drawing.Point(542, 15);
this.lkPutCom.Name = "lkPutCom";
this.lkPutCom.Size = new System.Drawing.Size(94, 17);
this.lkPutCom.TabIndex = 285;
this.lkPutCom.TabStop = true;
this.lkPutCom.Text = "补料";
this.lkPutCom.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
this.lkPutCom.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.lkPutCom_LinkClicked);
//
// FrmWork // FrmWork
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F); this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
...@@ -1128,5 +1156,7 @@ ...@@ -1128,5 +1156,7 @@
private System.Windows.Forms.GroupBox groupPNImg; private System.Windows.Forms.GroupBox groupPNImg;
private System.Windows.Forms.Panel panPNImg; private System.Windows.Forms.Panel panPNImg;
private System.Windows.Forms.PictureBox picPNImg; private System.Windows.Forms.PictureBox picPNImg;
private System.Windows.Forms.LinkLabel lkPutCom;
private System.Windows.Forms.LinkLabel lklUpdateNum;
} }
} }
\ No newline at end of file \ No newline at end of file
...@@ -142,6 +142,7 @@ namespace TSA_V ...@@ -142,6 +142,7 @@ namespace TSA_V
} }
HandRecordManager.Reset(); HandRecordManager.Reset();
isInitOk = true; isInitOk = true;
lkPutCom.Visible = !WorkModeUtil.OnlyGB;
// string ip = ConfigAppSettings.GetValue(Setting_Init.StatusServerIp); // string ip = ConfigAppSettings.GetValue(Setting_Init.StatusServerIp);
// bool result = StatusClient.instance.Connect(); // bool result = StatusClient.instance.Connect();
// LogUtil.info("连接状态服务器【" + ip + "】【" + result + "】【" + StatusClient.instance.ErrInfo + "】"); // LogUtil.info("连接状态服务器【" + ip + "】【" + result + "】【" + StatusClient.instance.ErrInfo + "】");
...@@ -538,7 +539,15 @@ namespace TSA_V ...@@ -538,7 +539,15 @@ namespace TSA_V
LogUtil.info(Name + " Shown end "); LogUtil.info(Name + " Shown end ");
WriteStateStr(); WriteStateStr();
if(ResourceCulture.GetLanguage().Equals(ResourceCulture.English))
{
lklUpdateNum.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
}
else
{
lklUpdateNum.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
}
if (needShowMsg != "") if (needShowMsg != "")
{ {
MessageBox.Show(needShowMsg); MessageBox.Show(needShowMsg);
...@@ -1026,6 +1035,7 @@ namespace TSA_V ...@@ -1026,6 +1035,7 @@ namespace TSA_V
} }
private void ShowUpdateCount(bool isShow) private void ShowUpdateCount(bool isShow)
{ {
lklUpdateNum.Visible = !isShow;
lblCount.Visible = !isShow; lblCount.Visible = !isShow;
txtCount.Visible = isShow; txtCount.Visible = isShow;
btnSave.Visible = isShow; btnSave.Visible = isShow;
...@@ -1399,5 +1409,89 @@ namespace TSA_V ...@@ -1399,5 +1409,89 @@ namespace TSA_V
cutImg = false; cutImg = false;
selectedRectangle = new Rectangle(0, 0, 0, 0); selectedRectangle = new Rectangle(0, 0, 0, 0);
} }
private void lklUpdateNum_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
{
if (lblCount.Visible)
{
ShowUpdateCount(true);
}
}
private void lkPutCom_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
{
try
{
if (WorkModeUtil.OnlyGB)
{
string msg = ResourceControl.GetString("GuobanMode", "操作失败,当前为过板模式");
MessageBoxMidle.Show(this, msg, ResourceCulture.GetString("提示"), MessageBoxButtons.OK, MessageBoxIcon.Error);
return;
}
List<BoardInfo> listb = new List<BoardInfo>(BoardManager.boardList);
var ls = listb.Select((point) => { return point.boardName; }).ToList();
string selectMode = ResourceCulture.GetString("ScanReplenish", "扫码补料模式");
int index=ls.IndexOf(BoardManager.CurrBoard.boardName);
FrmSelectPoint frma = new FrmSelectPoint(ResourceCulture.GetString("FrmBoardSelect_Text", "请选择程序"), ls, index, selectMode);
DialogResult result = frma.ShowDialog();
int workType = frma.SelectWorkMode;
if (result.Equals(DialogResult.OK))
{
BoardInfo board = listb[frma.SelectIndex];
List<ComponetInfo> allList = CSVBomManager.GetComList(board.bomName);
List<SMTPointInfo> plist = (from m in board.smtList where m.Disable.Equals(false) select m).ToList();
List<ComponetInfo> list = new List<ComponetInfo>();
foreach (ComponetInfo p in allList)
{
List<SMTPointInfo> hasList = new List<SMTPointInfo>();
if (String.IsNullOrEmpty(p.TagNo))
{
hasList = (from m in plist where m.PN.Equals(p.PN) select m).ToList();
}
else
{
hasList = (from m in plist where m.TagNo.Equals(p.TagNo) select m).ToList();
}
if (hasList.Count > 0)
{
list.Add(p);
}
}
list = (from m in list orderby m.PN ascending select m).ToList();
if (workType.Equals(1))
{
FrmScanPutCom frm = new FrmScanPutCom();
if (frm.SetOperateInfo(board, board.bomName, list))
{
this.Visible = false;
frm.ShowDialog();
this.Visible = true;
}
}
else
{
FrmBoardPutCom frm = new FrmBoardPutCom();
if (frm.SetOperateInfo(board, board.bomName, list))
{
this.Visible = false;
frm.ShowDialog();
this.Visible = true;
}
}
}
}
catch (Exception ex)
{
LogUtil.error("btnReplenish_Click 出错:" + ex.ToString());
MessageBox.Show(ex.ToString());
}
}
} }
} }
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!