구매 sid 검사 기능 추가
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
using System;
|
||||
using FCOMMON;
|
||||
using FEQ0000.Purchase;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
@@ -16,6 +18,8 @@ namespace FEQ0000
|
||||
dsPurchase.EETGW_PurchaseCRRow dr;
|
||||
public Boolean repeatAdd = false;
|
||||
Boolean binit = false;
|
||||
string sidchk = string.Empty;
|
||||
|
||||
public fPurchaseCR_Add(dsPurchase.EETGW_PurchaseCRRow dr_)
|
||||
{
|
||||
InitializeComponent();
|
||||
@@ -278,6 +282,12 @@ namespace FEQ0000
|
||||
//}
|
||||
binit = true;
|
||||
|
||||
if (dr.RowState == DataRowState.Detached || dr.RowState == DataRowState.Added)
|
||||
sidchk = string.Empty;
|
||||
else
|
||||
sidchk = tbSID.Text;
|
||||
|
||||
timer1.Start();
|
||||
|
||||
|
||||
}
|
||||
@@ -443,6 +453,21 @@ namespace FEQ0000
|
||||
return false;
|
||||
}
|
||||
|
||||
if (string.IsNullOrWhiteSpace(this.sidchk))
|
||||
{
|
||||
FCOMMON.Util.MsgE("SID검사가 필요합니다.\n상단의 검사 버튼을 눌러 SPR/NR 재고 여부를 확인 하세요");
|
||||
btSIDChk.Focus();
|
||||
return false;
|
||||
}
|
||||
|
||||
//시드검사한 자료와 현재 입력된 시드가 다르면 검사를 다시 하게 한다
|
||||
if (this.tbSID.Text.Trim().Equals(this.sidchk) == false)
|
||||
{
|
||||
Util.MsgE("SID검사 자료가 변경되었습니다. 다시 검사 하세요");
|
||||
sidchk = string.Empty;
|
||||
return false;
|
||||
}
|
||||
|
||||
//if (cbProcess.Text.Trim() == "")
|
||||
//{
|
||||
// FCOMMON.Util.MsgE("추가정보내의 [공정]을 선택하세요.");
|
||||
@@ -914,5 +939,56 @@ namespace FEQ0000
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
private void timer1_Tick(object sender, EventArgs e)
|
||||
{
|
||||
if (tbSID.TextLength != 9)
|
||||
{
|
||||
if (btSIDChk.BackColor == Color.Gray)
|
||||
btSIDChk.BackColor = Color.Tomato;
|
||||
else
|
||||
btSIDChk.BackColor = Color.Gray;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(sidchk))
|
||||
{
|
||||
if (btSIDChk.BackColor == Color.Lime)
|
||||
btSIDChk.BackColor = Color.White;
|
||||
else
|
||||
btSIDChk.BackColor = Color.Lime;
|
||||
}
|
||||
else btSIDChk.BackColor = SystemColors.Control;
|
||||
}
|
||||
}
|
||||
|
||||
private void btSIDChk_Click(object sender, EventArgs e)
|
||||
{
|
||||
var sid = tbSID.Text.Trim();
|
||||
if (sid.Length != 9)
|
||||
{
|
||||
FCOMMON.Util.MsgE("검색 할 SID를 입력하세요");
|
||||
tbSID.Focus();
|
||||
tbSID.SelectAll();
|
||||
return;
|
||||
}
|
||||
|
||||
var dt = Amkor.RestfulService.SPMSIDSearch(sid);
|
||||
if (dt.Complete)
|
||||
{
|
||||
var f = new fSIDListSelect(sid, dt.Result);
|
||||
if (f.ShowDialog() == DialogResult.OK)
|
||||
this.sidchk = sid;
|
||||
else
|
||||
{
|
||||
FCOMMON.Util.MsgE("목록표시 창에서 '확인' 버튼을 눌러야 SID검색이 완료됩니다.");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
FCOMMON.Util.MsgI("SPM/NR 에서 검색된 정보가 없습니다\n저장이 가능 합니다");
|
||||
this.sidchk = sid;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user