verbessern vom pickeing, on goin

This commit is contained in:
Roland Drabesch
2022-08-15 15:52:07 +02:00
parent 0b9f98aa1f
commit 4a5a7da7c1
5 changed files with 134 additions and 36 deletions
@@ -130,8 +130,74 @@ namespace CordonelAssemblyLine.Model
NotifyPropertyChanged(nameof(Result));
}
}
string _lblS01Text;
public string lblS01Text { get { return _lblS01Text; } set { _lblS01Text = value; NotifyPropertyChanged(nameof(lblS01Text)); } }
string _lblS02Text;
public string lblS02Text { get { return _lblS02Text; } set { _lblS02Text = value; NotifyPropertyChanged(nameof(lblS02Text)); } }
string _lblS03Text;
public string lblS03Text { get { return _lblS03Text; } set { _lblS03Text = value; NotifyPropertyChanged(nameof(lblS03Text)); } }
string _lblS04Text;
public string lblS04Text { get { return _lblS04Text; } set { _lblS04Text = value; NotifyPropertyChanged(nameof(lblS04Text)); } }
string _lblS05Text;
public string lblS05Text { get { return _lblS05Text; } set { _lblS05Text = value; NotifyPropertyChanged(nameof(lblS05Text)); } }
string _lblS06Text;
public string lblS06Text { get { return _lblS06Text; } set { _lblS06Text = value; NotifyPropertyChanged(nameof(lblS06Text)); } }
string _lblS07Text;
public string lblS07Text { get { return _lblS07Text; } set { _lblS07Text = value; NotifyPropertyChanged(nameof(lblS07Text)); } }
string _lblS08Text;
public string lblS08Text { get { return _lblS08Text; } set { _lblS08Text = value; NotifyPropertyChanged(nameof(lblS08Text)); } }
string _lblS09Text;
public string lblS09Text { get { return _lblS09Text; } set { _lblS09Text = value; NotifyPropertyChanged(nameof(lblS09Text)); } }
string _lblS10Text;
public string lblS10Text { get { return _lblS10Text; } set { _lblS10Text = value; NotifyPropertyChanged(nameof(lblS10Text)); } }
string _lblS11Text;
public string lblS11Text { get { return _lblS11Text; } set { _lblS11Text = value; NotifyPropertyChanged(nameof(lblS11Text)); } }
System.Windows.Media.Brush _lblS01Color;
public System.Windows.Media.Brush lblS01Color { get { return _lblS01Color; } set { _lblS01Color = value; NotifyPropertyChanged(nameof(lblS01Color)); } }
System.Windows.Media.Brush _lblS02Color;
public System.Windows.Media.Brush lblS02Color { get { return _lblS02Color; } set { _lblS02Color = value; NotifyPropertyChanged(nameof(lblS02Color)); } }
System.Windows.Media.Brush _lblS03Color;
public System.Windows.Media.Brush lblS03Color { get { return _lblS03Color; } set { _lblS03Color = value; NotifyPropertyChanged(nameof(lblS03Color)); } }
System.Windows.Media.Brush _lblS04Color;
public System.Windows.Media.Brush lblS04Color { get { return _lblS04Color; } set { _lblS04Color = value; NotifyPropertyChanged(nameof(lblS04Color)); } }
System.Windows.Media.Brush _lblS05Color;
public System.Windows.Media.Brush lblS05Color { get { return _lblS05Color; } set { _lblS05Color = value; NotifyPropertyChanged(nameof(lblS05Color)); } }
System.Windows.Media.Brush _lblS06Color;
public System.Windows.Media.Brush lblS06Color { get { return _lblS06Color; } set { _lblS06Color = value; NotifyPropertyChanged(nameof(lblS06Color)); } }
System.Windows.Media.Brush _lblS07Color;
public System.Windows.Media.Brush lblS07Color { get { return _lblS07Color; } set { _lblS07Color = value; NotifyPropertyChanged(nameof(lblS07Color)); } }
System.Windows.Media.Brush _lblS08Color;
public System.Windows.Media.Brush lblS08Color { get { return _lblS08Color; } set { _lblS08Color = value; NotifyPropertyChanged(nameof(lblS08Color)); } }
System.Windows.Media.Brush _lblS09Color;
public System.Windows.Media.Brush lblS09Color { get { return _lblS09Color; } set { _lblS09Color = value; NotifyPropertyChanged(nameof(lblS09Color)); } }
System.Windows.Media.Brush _lblS10Color;
public System.Windows.Media.Brush lblS10Color { get { return _lblS10Color; } set { _lblS10Color = value; NotifyPropertyChanged(nameof(lblS10Color)); } }
System.Windows.Media.Brush _lblS11Color;
public System.Windows.Media.Brush lblS11Color { get { return _lblS11Color; } set { _lblS11Color = value; NotifyPropertyChanged(nameof(lblS11Color)); } }
public PickingViewModel()
{
_lblS01Text = "Auftrag Scan";
_lblS02Text = "Detektiere Pcb";
_lblS03Text = "Lade Autrag";
_lblS04Text = "Prüfe Region/ Frequenz";
_lblS05Text = "Prüfe Drucksensor";
_lblS06Text = "Prüfe FW Version";
_lblS07Text = "Prüfe Dateisystem";
_lblS08Text = "Battery fix";
_lblS09Text = "Produktions-datum";
_lblS10Text = "Display";
_lblS11Text = "Montage bestätigen";
InitProgressBar();
}
@@ -232,7 +298,7 @@ namespace CordonelAssemblyLine.Model
Input = ex.Message;
isRuning = false;
}
}
@@ -494,7 +560,7 @@ namespace CordonelAssemblyLine.Model
if (hasDetect)
{
setState( $"Pcb gefunden {PcbId}");
setState($"Pcb gefunden {PcbId}");
Log($"New PcbID detected {PcbId}");
sm = PickingStateMachine.GetOrderDetails;
ProgressBar.Where(n => n.Name == "Connect").First().State = Ui.ProductionControls.Enums.ImgStatus.Success;
@@ -534,7 +600,7 @@ namespace CordonelAssemblyLine.Model
{
OrderOverview = JsonConvert.DeserializeObject<OrderOverViewCordonelWithPicking>(str);
OrderDetails = OrderOverview.PickingCompareItem;
if (OrderOverview.OrderOverViewCordonel.Count == OrderOverview.OrderOverViewCordonel.AssignedPicking)
{
Result = "Auftrag schon komplett";
@@ -546,7 +612,7 @@ namespace CordonelAssemblyLine.Model
else
{
setState($"Auftragsdaten geladen {Order}");
sm = PickingStateMachine.Compare;
ProgressBar.Where(n => n.Name == "Order data").First().State = Ui.ProductionControls.Enums.ImgStatus.Success;
ProgressBar.Where(n => n.Name == "Compare").First().State = Ui.ProductionControls.Enums.ImgStatus.InProgress;
@@ -566,7 +632,7 @@ namespace CordonelAssemblyLine.Model
{
setState($"Fehlgeschlagen Register ist zu alt! Bitte QS informieren. KitronProductionDate:{OrderOverview.KitronProductionDate }");
// sm = PickingStateMachine.MeterError;
// sm = PickingStateMachine.MeterError;
var b = (System.Windows.Media.Brush)converter.ConvertFromString("#FFFF00");
b.Freeze();
@@ -575,7 +641,7 @@ namespace CordonelAssemblyLine.Model
//break;
}
if (Compare(OrderDetails.CheckAppsIdVersion, OrderDetails.FrequencyIndicator, OrderDetails.MeterSize, OrderDetails.PressurePresent))
{
@@ -596,7 +662,7 @@ namespace CordonelAssemblyLine.Model
break;
case PickingStateMachine.MeterError:
OrderDetails = null;
OrderOverview = null;
OrderOverview = null;
setState($"Vergleich abgeschlossen:{State}");
Result = $"Vergleich fertig fehlgeschlagen";
Thread.Sleep(10000);
@@ -685,7 +751,7 @@ namespace CordonelAssemblyLine.Model
ResultColor = b;
Thread.Sleep(5000);
setState($"Montage Rückmeldung erhalten, auftrag Scannen");
sm = PickingStateMachine.StartCom;
}
}