-
-
-
-
-
+
-
@* 系統-工程資訊sheet *@
diff --git a/AMESCoreStudio.WebApi/Controllers/AMES/WipBoardController.cs b/AMESCoreStudio.WebApi/Controllers/AMES/WipBoardController.cs
index acb38723..ff3826fc 100644
--- a/AMESCoreStudio.WebApi/Controllers/AMES/WipBoardController.cs
+++ b/AMESCoreStudio.WebApi/Controllers/AMES/WipBoardController.cs
@@ -83,38 +83,21 @@ namespace AMESCoreStudio.WebApi.Controllers.AMES
public async Task> PutWipBoard([FromBody] WipBoard wipBoard)
{
ResultModel result = new ResultModel();
-
- var getWipBoard = GetWipBoard(wipBoard.WipNo).Result.Value;
-
- if (getWipBoard != null)
- {
- _context.Entry(getWipBoard).State = EntityState.Modified;
- getWipBoard.BiosVer = wipBoard.BiosVer;
- getWipBoard.BiRatio = wipBoard.BiRatio;
- getWipBoard.BiTemperature = wipBoard.BiTemperature;
- getWipBoard.BiTime = wipBoard.BiTime;
- getWipBoard.Burn = wipBoard.Burn;
- getWipBoard.BurnLocation = wipBoard.BurnLocation;
- getWipBoard.Checksum = wipBoard.Checksum;
- getWipBoard.DipCarrier = wipBoard.DipCarrier;
- getWipBoard.DipSide = wipBoard.DipSide;
- getWipBoard.DipTape = wipBoard.DipTape;
- getWipBoard.PartsBake = wipBoard.PartsBake;
- getWipBoard.PartsBakeTime = wipBoard.PartsBakeTime;
- getWipBoard.PcbBake = wipBoard.PcbBake;
- getWipBoard.Smd = wipBoard.Smd;
- getWipBoard.SolderPaste = wipBoard.SolderPaste;
- getWipBoard.Engineer = wipBoard.Engineer;
- getWipBoard.UpdateDate = DateTime.Now;
- getWipBoard.UpdateUserID = 0;
- }
- else
- {
- _context.WipBoards.Add(wipBoard);
- }
-
try
{
+ if (GetWipBoard(wipBoard.WipNo).Result.Value != null)
+ {
+ _context.Entry(wipBoard).State = EntityState.Modified;
+ _context.Entry(wipBoard).Property("CreateDate").IsModified = false;
+ _context.Entry(wipBoard).Property("CreateUserID").IsModified = false;
+ wipBoard.UpdateDate = DateTime.Now;
+ wipBoard.UpdateUserID = 0;
+ }
+ else
+ {
+ _context.WipBoards.Add(wipBoard);
+ }
+
await _context.SaveChangesAsync();
result.Success = true;
result.Msg = "OK";
diff --git a/AMESCoreStudio.WebApi/Controllers/AMES/WipSystemController.cs b/AMESCoreStudio.WebApi/Controllers/AMES/WipSystemController.cs
index 3f7c0f65..1bb3b910 100644
--- a/AMESCoreStudio.WebApi/Controllers/AMES/WipSystemController.cs
+++ b/AMESCoreStudio.WebApi/Controllers/AMES/WipSystemController.cs
@@ -83,28 +83,11 @@ namespace AMESCoreStudio.WebApi.Controllers.AMES
var getwipSystem = GetWipSystem(wipSystem.WipNo).Result.Value;
if (getwipSystem != null)
{
- _context.Entry(getwipSystem).State = EntityState.Modified;
- getwipSystem.BiMemo = wipSystem.BiMemo;
- getwipSystem.BiosVer = wipSystem.BiosVer;
- getwipSystem.BiRatio = wipSystem.BiRatio;
- getwipSystem.BiTemperature = wipSystem.BiTemperature;
- getwipSystem.BiTime = wipSystem.BiTime;
- getwipSystem.Checksum = wipSystem.Checksum;
- getwipSystem.Cpu = wipSystem.Cpu;
- getwipSystem.DmiBi = wipSystem.DmiBi;
- getwipSystem.Ec = wipSystem.Ec;
- getwipSystem.FinePackage = wipSystem.FinePackage;
- getwipSystem.Fw = wipSystem.Fw;
- getwipSystem.Fw1 = wipSystem.Fw1;
- getwipSystem.Fw2 = wipSystem.Fw2;
- getwipSystem.Jumper = wipSystem.Jumper;
- getwipSystem.Memo = wipSystem.Memo;
- getwipSystem.OsVer = wipSystem.OsVer;
- getwipSystem.PowerMode = wipSystem.PowerMode;
- getwipSystem.Ram = wipSystem.Ram;
- getwipSystem.Engineer = wipSystem.Engineer;
- getwipSystem.UpdateDate = DateTime.Now;
- getwipSystem.UpdateUserID = 0;
+ _context.Entry(wipSystem).State = EntityState.Modified;
+ _context.Entry(wipSystem).Property("CreateDate").IsModified = false;
+ _context.Entry(wipSystem).Property("CreateUserID").IsModified = false;
+ wipSystem.UpdateDate = DateTime.Now;
+ wipSystem.UpdateUserID = 0;
}
else
{
diff --git a/AMESCoreStudio.WebApi/Enums/EnumPCS.cs b/AMESCoreStudio.WebApi/Enums/EnumPCS.cs
index ee71ba8e..b2b37ae8 100644
--- a/AMESCoreStudio.WebApi/Enums/EnumPCS.cs
+++ b/AMESCoreStudio.WebApi/Enums/EnumPCS.cs
@@ -276,7 +276,7 @@ namespace AMESCoreStudio.WebApi.Enum
/// NA
///
[Display(Name = "NA")]
- N = 0,
+ N = 3,
}
///
diff --git a/AMESCoreStudio.WebApi/Models/AMES/WipBoard.cs b/AMESCoreStudio.WebApi/Models/AMES/WipBoard.cs
index 6fc2c1b9..115d138c 100644
--- a/AMESCoreStudio.WebApi/Models/AMES/WipBoard.cs
+++ b/AMESCoreStudio.WebApi/Models/AMES/WipBoard.cs
@@ -60,11 +60,10 @@ namespace AMESCoreStudio.WebApi.Models.AMES
public string SmdRemarks { get; set; }
///
- /// SMD點防焊膠(Y/N)
+ /// SMD點防焊膠
///
- [Required]
[Column("SMD_SOLDER_MASK")]
- [StringLength(2)]
+ [StringLength(30)]
[DataMember]
public string SmdSolderMask { get; set; }
@@ -73,7 +72,7 @@ namespace AMESCoreStudio.WebApi.Models.AMES
///
[Column("SMD_SM_REMARKS")]
[DataMember]
- [Display(Name = "SMD點膠")]
+ [Display(Name = "SMD點防焊膠備註")]
public string SmdSMRemarks { get; set; }
///
@@ -114,6 +113,15 @@ namespace AMESCoreStudio.WebApi.Models.AMES
[Display(Name = "貼付膠帶")]
public string DipTape { get; set; }
+ ///
+ /// 是否需要點防焊膠(Y/N)
+ ///
+ [Required]
+ [Column("DIP_SOLDER_MASK")]
+ [StringLength(2)]
+ [DataMember]
+ public string DipSolderMask { get; set; }
+
///
/// 是否燒錄(Y/N)
///
@@ -340,6 +348,12 @@ namespace AMESCoreStudio.WebApi.Models.AMES
[NotMapped]
public virtual List SMDs { get; set; }
+ ///
+ /// SMD防焊膠s
+ ///
+ [NotMapped]
+ public virtual List SmdSolderMasks { get; set; }
+
///
/// 正背面
///
diff --git a/AMESCoreStudio.WebApi/Models/AMES/WipInfo.cs b/AMESCoreStudio.WebApi/Models/AMES/WipInfo.cs
index 3fdfa75d..2017a2bc 100644
--- a/AMESCoreStudio.WebApi/Models/AMES/WipInfo.cs
+++ b/AMESCoreStudio.WebApi/Models/AMES/WipInfo.cs
@@ -137,6 +137,13 @@ namespace AMESCoreStudio.WebApi.Models.AMES
[Display(Name = "單箱數量")]
public int BoxCNT { get; set; } = 0;
+ ///
+ /// SFIS流程確認(Y/N)
+ ///
+ [Column("SFIS_FLOW_CK")]
+ [DataMember]
+ public string SFISFlowCk { get; set; } = "N";
+
///
/// 判斷前製程是否已經投入 (Y-判斷;N-不判斷)
///