Update procedure IO/IOB x controllo ODL e pezziODL corrente

This commit is contained in:
Samuele E. Locatelli
2018-09-24 16:43:29 +02:00
parent 1e8e4f0a5b
commit cf2e9eecc8
7 changed files with 225 additions and 35 deletions
Vendored
+1 -1
View File
@@ -17,7 +17,7 @@ pipeline {
/* calcolo numero versione... diverso x branch MASTER/DEVELOP */
script {
withEnv(['NEXT_BUILD_NUMBER=811']) {
withEnv(['NEXT_BUILD_NUMBER=812']) {
// env.versionNumber = VersionNumber(versionNumberString : '6.0.${BUILD_DATE_FORMATTED, "yyMM"}.${BUILDS_ALL_TIME}', projectStartDate : '2006-01-01', skipFailedBuilds: true)
env.versionNumber = VersionNumber(versionNumberString : '6.0.${BUILD_DATE_FORMATTED, "yyMM"}.${BUILDS_ALL_TIME}', projectStartDate : '2006-01-01', skipFailedBuilds: true, overrideBuildsAllTime: '${NEXT_BUILD_NUMBER}')
env.APP_NAME = 'MAPO'
+14 -4
View File
@@ -80,7 +80,11 @@ namespace MP_IO.Controllers
{
string answ = "";
// formato yyyymmddHHMMSSnnn ovvero da anno a millisecondi
if (cnt == null) cnt = "0";
if (cnt == null)
{
cnt = "0";
}
DateTime dataOraEvento = DateTime.Now;
if (memLayer.ML.CRI("_logLevel") > 6)
{
@@ -102,7 +106,11 @@ namespace MP_IO.Controllers
{
string answ = "";
// formato yyyymmddHHMMSSnnn ovvero da anno a millisecondi
if (cnt == null) cnt = "0";
if (cnt == null)
{
cnt = "0";
}
DateTime dataOraEvento = DateTime.Now;
if (memLayer.ML.CRI("_logLevel") > 6)
{
@@ -207,7 +215,6 @@ namespace MP_IO.Controllers
public string getCounterTCRec(string id)
{
string answ = "";
// !!!FARE!!! ottimizzare e leggere da DB solo ogni tot minuti e x il resto usare redis?!?
try
{
answ = DataLayer.pzCounterTC(id).ToString();
@@ -337,7 +344,10 @@ namespace MP_IO.Controllers
// !!!FARE!!! temporanemanete genera a caso vuoto o 3000 x permettere test... altrimenti gestisce VERA coda... secondi pari...
int resto = 0;
Math.DivRem(DateTime.Now.Second, 2, out resto);
if (resto == 0) answ = "3000";
if (resto == 0)
{
answ = "3000";
}
return answ;
}
+134 -2
View File
@@ -9052,6 +9052,8 @@ namespace MapoDb {
private global::System.Data.DataColumn columnidxMacchina;
private global::System.Data.DataColumn columnIdxOdl;
private global::System.Data.DataColumn columnPzTotODL;
private global::System.Data.DataColumn columnPzConfScarto;
@@ -9064,6 +9066,10 @@ namespace MapoDb {
private global::System.Data.DataColumn columnPz2RecScarto;
private global::System.Data.DataColumn columnDataFrom;
private global::System.Data.DataColumn columnDataTo;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public StatoProdDataTable() {
@@ -9105,6 +9111,14 @@ namespace MapoDb {
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public global::System.Data.DataColumn IdxOdlColumn {
get {
return this.columnIdxOdl;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public global::System.Data.DataColumn PzTotODLColumn {
@@ -9153,6 +9167,22 @@ namespace MapoDb {
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public global::System.Data.DataColumn DataFromColumn {
get {
return this.columnDataFrom;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public global::System.Data.DataColumn DataToColumn {
get {
return this.columnDataTo;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
[global::System.ComponentModel.Browsable(false)]
@@ -9190,16 +9220,19 @@ namespace MapoDb {
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public StatoProdRow AddStatoProdRow(string idxMacchina, int PzTotODL, int PzConfScarto, int PzConfBuoni, int PzRichODL, int Pz2RecTot, int Pz2RecScarto) {
public StatoProdRow AddStatoProdRow(string idxMacchina, int IdxOdl, int PzTotODL, int PzConfScarto, int PzConfBuoni, int PzRichODL, int Pz2RecTot, int Pz2RecScarto, System.DateTime DataFrom, System.DateTime DataTo) {
StatoProdRow rowStatoProdRow = ((StatoProdRow)(this.NewRow()));
object[] columnValuesArray = new object[] {
idxMacchina,
IdxOdl,
PzTotODL,
PzConfScarto,
PzConfBuoni,
PzRichODL,
Pz2RecTot,
Pz2RecScarto};
Pz2RecScarto,
DataFrom,
DataTo};
rowStatoProdRow.ItemArray = columnValuesArray;
this.Rows.Add(rowStatoProdRow);
return rowStatoProdRow;
@@ -9223,12 +9256,15 @@ namespace MapoDb {
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
internal void InitVars() {
this.columnidxMacchina = base.Columns["idxMacchina"];
this.columnIdxOdl = base.Columns["IdxOdl"];
this.columnPzTotODL = base.Columns["PzTotODL"];
this.columnPzConfScarto = base.Columns["PzConfScarto"];
this.columnPzConfBuoni = base.Columns["PzConfBuoni"];
this.columnPzRichODL = base.Columns["PzRichODL"];
this.columnPz2RecTot = base.Columns["Pz2RecTot"];
this.columnPz2RecScarto = base.Columns["Pz2RecScarto"];
this.columnDataFrom = base.Columns["DataFrom"];
this.columnDataTo = base.Columns["DataTo"];
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
@@ -9236,6 +9272,8 @@ namespace MapoDb {
private void InitClass() {
this.columnidxMacchina = new global::System.Data.DataColumn("idxMacchina", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnidxMacchina);
this.columnIdxOdl = new global::System.Data.DataColumn("IdxOdl", typeof(int), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnIdxOdl);
this.columnPzTotODL = new global::System.Data.DataColumn("PzTotODL", typeof(int), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnPzTotODL);
this.columnPzConfScarto = new global::System.Data.DataColumn("PzConfScarto", typeof(int), null, global::System.Data.MappingType.Element);
@@ -9248,17 +9286,24 @@ namespace MapoDb {
base.Columns.Add(this.columnPz2RecTot);
this.columnPz2RecScarto = new global::System.Data.DataColumn("Pz2RecScarto", typeof(int), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnPz2RecScarto);
this.columnDataFrom = new global::System.Data.DataColumn("DataFrom", typeof(global::System.DateTime), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnDataFrom);
this.columnDataTo = new global::System.Data.DataColumn("DataTo", typeof(global::System.DateTime), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnDataTo);
this.Constraints.Add(new global::System.Data.UniqueConstraint("PK", new global::System.Data.DataColumn[] {
this.columnidxMacchina}, false));
this.columnidxMacchina.ReadOnly = true;
this.columnidxMacchina.Unique = true;
this.columnidxMacchina.MaxLength = 50;
this.columnIdxOdl.ReadOnly = true;
this.columnPzTotODL.ReadOnly = true;
this.columnPzConfScarto.ReadOnly = true;
this.columnPzConfBuoni.ReadOnly = true;
this.columnPzRichODL.ReadOnly = true;
this.columnPz2RecTot.ReadOnly = true;
this.columnPz2RecScarto.ReadOnly = true;
this.columnDataFrom.ReadOnly = true;
this.columnDataTo.ReadOnly = true;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
@@ -14449,6 +14494,22 @@ namespace MapoDb {
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public int IdxOdl {
get {
try {
return ((int)(this[this.tableStatoProd.IdxOdlColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("Il valore della colonna \'IdxOdl\' nella tabella \'StatoProd\' è DBNull.", e);
}
}
set {
this[this.tableStatoProd.IdxOdlColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public int PzTotODL {
@@ -14545,6 +14606,38 @@ namespace MapoDb {
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public System.DateTime DataFrom {
get {
try {
return ((global::System.DateTime)(this[this.tableStatoProd.DataFromColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("Il valore della colonna \'DataFrom\' nella tabella \'StatoProd\' è DBNull.", e);
}
}
set {
this[this.tableStatoProd.DataFromColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public System.DateTime DataTo {
get {
try {
return ((global::System.DateTime)(this[this.tableStatoProd.DataToColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("Il valore della colonna \'DataTo\' nella tabella \'StatoProd\' è DBNull.", e);
}
}
set {
this[this.tableStatoProd.DataToColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public bool IsidxMacchinaNull() {
@@ -14557,6 +14650,18 @@ namespace MapoDb {
this[this.tableStatoProd.idxMacchinaColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public bool IsIdxOdlNull() {
return this.IsNull(this.tableStatoProd.IdxOdlColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public void SetIdxOdlNull() {
this[this.tableStatoProd.IdxOdlColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public bool IsPzTotODLNull() {
@@ -14628,6 +14733,30 @@ namespace MapoDb {
public void SetPz2RecScartoNull() {
this[this.tableStatoProd.Pz2RecScartoColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public bool IsDataFromNull() {
return this.IsNull(this.tableStatoProd.DataFromColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public void SetDataFromNull() {
this[this.tableStatoProd.DataFromColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public bool IsDataToNull() {
return this.IsNull(this.tableStatoProd.DataToColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
public void SetDataToNull() {
this[this.tableStatoProd.DataToColumn] = global::System.Convert.DBNull;
}
}
/// <summary>
@@ -26372,12 +26501,15 @@ FROM MappaStatoExpl";
tableMapping.SourceTable = "Table";
tableMapping.DataSetTable = "StatoProd";
tableMapping.ColumnMappings.Add("idxMacchina", "idxMacchina");
tableMapping.ColumnMappings.Add("IdxOdl", "IdxOdl");
tableMapping.ColumnMappings.Add("PzTotODL", "PzTotODL");
tableMapping.ColumnMappings.Add("PzConfScarto", "PzConfScarto");
tableMapping.ColumnMappings.Add("PzConfBuoni", "PzConfBuoni");
tableMapping.ColumnMappings.Add("PzRichODL", "PzRichODL");
tableMapping.ColumnMappings.Add("Pz2RecTot", "Pz2RecTot");
tableMapping.ColumnMappings.Add("Pz2RecScarto", "Pz2RecScarto");
tableMapping.ColumnMappings.Add("DataFrom", "DataFrom");
tableMapping.ColumnMappings.Add("DataTo", "DataTo");
this._adapter.TableMappings.Add(tableMapping);
}
+16 -10
View File
@@ -2028,7 +2028,7 @@ FROM dbo.v_RegistroScarti</CommandText>
</TableAdapter>
<TableAdapter BaseClass="System.ComponentModel.Component" DataAccessorModifier="AutoLayout, AnsiClass, Class, Public" DataAccessorName="StatoProdTableAdapter" GeneratorDataComponentClassName="StatoProdTableAdapter" Name="StatoProd" UserDataComponentName="StatoProdTableAdapter">
<MainSource>
<DbSource ConnectionRef="MoonProConnectionString (Settings)" DbObjectName="MoonPro.dbo.stp_StatoProd_getByMacchina" DbObjectType="StoredProcedure" FillMethodModifier="Public" FillMethodName="Fill" GenerateMethods="Both" GenerateShortCommands="true" GeneratorGetMethodName="GetData" GeneratorSourceName="Fill" GetMethodModifier="Public" GetMethodName="GetData" QueryType="Rowset" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetData" UserSourceName="Fill">
<DbSource ConnectionRef="MoonProConnectionString (Settings)" DbObjectName="MoonPro.dbo.stp_StatoProd_getByMacchina" DbObjectType="StoredProcedure" FillMethodModifier="Public" FillMethodName="Fill" GenerateMethods="Both" GenerateShortCommands="false" GeneratorGetMethodName="GetData" GeneratorSourceName="Fill" GetMethodModifier="Public" GetMethodName="GetData" QueryType="Rowset" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="false" UserGetMethodName="GetData" UserSourceName="Fill">
<SelectCommand>
<DbCommand CommandType="StoredProcedure" ModifiedByUser="false">
<CommandText>dbo.stp_StatoProd_getByMacchina</CommandText>
@@ -2043,12 +2043,15 @@ FROM dbo.v_RegistroScarti</CommandText>
</MainSource>
<Mappings>
<Mapping SourceColumn="idxMacchina" DataSetColumn="idxMacchina" />
<Mapping SourceColumn="IdxOdl" DataSetColumn="IdxOdl" />
<Mapping SourceColumn="PzTotODL" DataSetColumn="PzTotODL" />
<Mapping SourceColumn="PzConfScarto" DataSetColumn="PzConfScarto" />
<Mapping SourceColumn="PzConfBuoni" DataSetColumn="PzConfBuoni" />
<Mapping SourceColumn="PzRichODL" DataSetColumn="PzRichODL" />
<Mapping SourceColumn="Pz2RecTot" DataSetColumn="Pz2RecTot" />
<Mapping SourceColumn="Pz2RecScarto" DataSetColumn="Pz2RecScarto" />
<Mapping SourceColumn="DataFrom" DataSetColumn="DataFrom" />
<Mapping SourceColumn="DataTo" DataSetColumn="DataTo" />
</Mappings>
<Sources />
</TableAdapter>
@@ -2570,7 +2573,7 @@ SELECT idxPromessa, KeyRichiesta, Attivabile, IdxODL, CodArticolo, CodGruppo, Id
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="MappaStatoExpl" msprop:Generator_TableClassName="MappaStatoExplDataTable" msprop:Generator_TableVarName="tableMappaStatoExpl" msprop:Generator_RowChangedName="MappaStatoExplRowChanged" msprop:Generator_TablePropName="MappaStatoExpl" msprop:Generator_RowDeletingName="MappaStatoExplRowDeleting" msprop:Generator_RowChangingName="MappaStatoExplRowChanging" msprop:Generator_RowEvHandlerName="MappaStatoExplRowChangeEventHandler" msprop:Generator_RowDeletedName="MappaStatoExplRowDeleted" msprop:Generator_RowClassName="MappaStatoExplRow" msprop:Generator_UserTableName="MappaStatoExpl" msprop:Generator_RowEvArgName="MappaStatoExplRowChangeEvent">
<xs:element name="MappaStatoExpl" msprop:Generator_TableClassName="MappaStatoExplDataTable" msprop:Generator_TableVarName="tableMappaStatoExpl" msprop:Generator_TablePropName="MappaStatoExpl" msprop:Generator_RowDeletingName="MappaStatoExplRowDeleting" msprop:Generator_RowChangingName="MappaStatoExplRowChanging" msprop:Generator_RowEvHandlerName="MappaStatoExplRowChangeEventHandler" msprop:Generator_RowDeletedName="MappaStatoExplRowDeleted" msprop:Generator_UserTableName="MappaStatoExpl" msprop:Generator_RowChangedName="MappaStatoExplRowChanged" msprop:Generator_RowEvArgName="MappaStatoExplRowChangeEvent" msprop:Generator_RowClassName="MappaStatoExplRow">
<xs:complexType>
<xs:sequence>
<xs:element name="RowNum" msdata:ReadOnly="true" msdata:AutoIncrement="true" msdata:AutoIncrementSeed="-1" msdata:AutoIncrementStep="-1" msprop:Generator_ColumnVarNameInTable="columnRowNum" msprop:Generator_ColumnPropNameInRow="RowNum" msprop:Generator_ColumnPropNameInTable="RowNumColumn" msprop:Generator_UserColumnName="RowNum" type="xs:int" />
@@ -2651,7 +2654,7 @@ SELECT idxPromessa, KeyRichiesta, Attivabile, IdxODL, CodArticolo, CodGruppo, Id
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="ProduzioneAs400" msprop:Generator_TableClassName="ProduzioneAs400DataTable" msprop:Generator_TableVarName="tableProduzioneAs400" msprop:Generator_TablePropName="ProduzioneAs400" msprop:Generator_RowDeletingName="ProduzioneAs400RowDeleting" msprop:Generator_RowChangingName="ProduzioneAs400RowChanging" msprop:Generator_RowEvHandlerName="ProduzioneAs400RowChangeEventHandler" msprop:Generator_RowDeletedName="ProduzioneAs400RowDeleted" msprop:Generator_UserTableName="ProduzioneAs400" msprop:Generator_RowChangedName="ProduzioneAs400RowChanged" msprop:Generator_RowEvArgName="ProduzioneAs400RowChangeEvent" msprop:Generator_RowClassName="ProduzioneAs400Row">
<xs:element name="ProduzioneAs400" msprop:Generator_TableClassName="ProduzioneAs400DataTable" msprop:Generator_TableVarName="tableProduzioneAs400" msprop:Generator_RowChangedName="ProduzioneAs400RowChanged" msprop:Generator_TablePropName="ProduzioneAs400" msprop:Generator_RowDeletingName="ProduzioneAs400RowDeleting" msprop:Generator_RowChangingName="ProduzioneAs400RowChanging" msprop:Generator_RowEvHandlerName="ProduzioneAs400RowChangeEventHandler" msprop:Generator_RowDeletedName="ProduzioneAs400RowDeleted" msprop:Generator_RowClassName="ProduzioneAs400Row" msprop:Generator_UserTableName="ProduzioneAs400" msprop:Generator_RowEvArgName="ProduzioneAs400RowChangeEvent">
<xs:complexType>
<xs:sequence>
<xs:element name="IdxODL" msprop:Generator_ColumnVarNameInTable="columnIdxODL" msprop:Generator_ColumnPropNameInRow="IdxODL" msprop:Generator_ColumnPropNameInTable="IdxODLColumn" msprop:Generator_UserColumnName="IdxODL" type="xs:int" />
@@ -2680,7 +2683,7 @@ SELECT idxPromessa, KeyRichiesta, Attivabile, IdxODL, CodArticolo, CodGruppo, Id
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="ResProdDett_splitODL" msprop:Generator_TableClassName="ResProdDett_splitODLDataTable" msprop:Generator_TableVarName="tableResProdDett_splitODL" msprop:Generator_RowChangedName="ResProdDett_splitODLRowChanged" msprop:Generator_TablePropName="ResProdDett_splitODL" msprop:Generator_RowDeletingName="ResProdDett_splitODLRowDeleting" msprop:Generator_RowChangingName="ResProdDett_splitODLRowChanging" msprop:Generator_RowEvHandlerName="ResProdDett_splitODLRowChangeEventHandler" msprop:Generator_RowDeletedName="ResProdDett_splitODLRowDeleted" msprop:Generator_RowClassName="ResProdDett_splitODLRow" msprop:Generator_UserTableName="ResProdDett_splitODL" msprop:Generator_RowEvArgName="ResProdDett_splitODLRowChangeEvent">
<xs:element name="ResProdDett_splitODL" msprop:Generator_TableClassName="ResProdDett_splitODLDataTable" msprop:Generator_TableVarName="tableResProdDett_splitODL" msprop:Generator_TablePropName="ResProdDett_splitODL" msprop:Generator_RowDeletingName="ResProdDett_splitODLRowDeleting" msprop:Generator_RowChangingName="ResProdDett_splitODLRowChanging" msprop:Generator_RowEvHandlerName="ResProdDett_splitODLRowChangeEventHandler" msprop:Generator_RowDeletedName="ResProdDett_splitODLRowDeleted" msprop:Generator_UserTableName="ResProdDett_splitODL" msprop:Generator_RowChangedName="ResProdDett_splitODLRowChanged" msprop:Generator_RowEvArgName="ResProdDett_splitODLRowChangeEvent" msprop:Generator_RowClassName="ResProdDett_splitODLRow">
<xs:complexType>
<xs:sequence>
<xs:element name="IdxODL" msprop:Generator_ColumnVarNameInTable="columnIdxODL" msprop:Generator_ColumnPropNameInRow="IdxODL" msprop:Generator_ColumnPropNameInTable="IdxODLColumn" msprop:Generator_UserColumnName="IdxODL" type="xs:int" minOccurs="0" />
@@ -2692,7 +2695,7 @@ SELECT idxPromessa, KeyRichiesta, Attivabile, IdxODL, CodArticolo, CodGruppo, Id
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="ResProdDett_splitGG" msprop:Generator_TableClassName="ResProdDett_splitGGDataTable" msprop:Generator_TableVarName="tableResProdDett_splitGG" msprop:Generator_RowChangedName="ResProdDett_splitGGRowChanged" msprop:Generator_TablePropName="ResProdDett_splitGG" msprop:Generator_RowDeletingName="ResProdDett_splitGGRowDeleting" msprop:Generator_RowChangingName="ResProdDett_splitGGRowChanging" msprop:Generator_RowEvHandlerName="ResProdDett_splitGGRowChangeEventHandler" msprop:Generator_RowDeletedName="ResProdDett_splitGGRowDeleted" msprop:Generator_RowClassName="ResProdDett_splitGGRow" msprop:Generator_UserTableName="ResProdDett_splitGG" msprop:Generator_RowEvArgName="ResProdDett_splitGGRowChangeEvent">
<xs:element name="ResProdDett_splitGG" msprop:Generator_TableClassName="ResProdDett_splitGGDataTable" msprop:Generator_TableVarName="tableResProdDett_splitGG" msprop:Generator_TablePropName="ResProdDett_splitGG" msprop:Generator_RowDeletingName="ResProdDett_splitGGRowDeleting" msprop:Generator_RowChangingName="ResProdDett_splitGGRowChanging" msprop:Generator_RowEvHandlerName="ResProdDett_splitGGRowChangeEventHandler" msprop:Generator_RowDeletedName="ResProdDett_splitGGRowDeleted" msprop:Generator_UserTableName="ResProdDett_splitGG" msprop:Generator_RowChangedName="ResProdDett_splitGGRowChanged" msprop:Generator_RowEvArgName="ResProdDett_splitGGRowChangeEvent" msprop:Generator_RowClassName="ResProdDett_splitGGRow">
<xs:complexType>
<xs:sequence>
<xs:element name="Data" msdata:ReadOnly="true" msprop:Generator_ColumnVarNameInTable="columnData" msprop:Generator_ColumnPropNameInRow="Data" msprop:Generator_ColumnPropNameInTable="DataColumn" msprop:Generator_UserColumnName="Data" type="xs:dateTime" minOccurs="0" />
@@ -2717,7 +2720,7 @@ SELECT idxPromessa, KeyRichiesta, Attivabile, IdxODL, CodArticolo, CodGruppo, Id
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="ResProdTot" msprop:Generator_TableClassName="ResProdTotDataTable" msprop:Generator_TableVarName="tableResProdTot" msprop:Generator_TablePropName="ResProdTot" msprop:Generator_RowDeletingName="ResProdTotRowDeleting" msprop:Generator_RowChangingName="ResProdTotRowChanging" msprop:Generator_RowEvHandlerName="ResProdTotRowChangeEventHandler" msprop:Generator_RowDeletedName="ResProdTotRowDeleted" msprop:Generator_UserTableName="ResProdTot" msprop:Generator_RowChangedName="ResProdTotRowChanged" msprop:Generator_RowEvArgName="ResProdTotRowChangeEvent" msprop:Generator_RowClassName="ResProdTotRow">
<xs:element name="ResProdTot" msprop:Generator_TableClassName="ResProdTotDataTable" msprop:Generator_TableVarName="tableResProdTot" msprop:Generator_RowChangedName="ResProdTotRowChanged" msprop:Generator_TablePropName="ResProdTot" msprop:Generator_RowDeletingName="ResProdTotRowDeleting" msprop:Generator_RowChangingName="ResProdTotRowChanging" msprop:Generator_RowEvHandlerName="ResProdTotRowChangeEventHandler" msprop:Generator_RowDeletedName="ResProdTotRowDeleted" msprop:Generator_RowClassName="ResProdTotRow" msprop:Generator_UserTableName="ResProdTot" msprop:Generator_RowEvArgName="ResProdTotRowChangeEvent">
<xs:complexType>
<xs:sequence>
<xs:element name="Nome" msprop:Generator_ColumnVarNameInTable="columnNome" msprop:Generator_ColumnPropNameInRow="Nome" msprop:Generator_ColumnPropNameInTable="NomeColumn" msprop:Generator_UserColumnName="Nome">
@@ -2755,7 +2758,7 @@ SELECT idxPromessa, KeyRichiesta, Attivabile, IdxODL, CodArticolo, CodGruppo, Id
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="RegistroControlli" msprop:Generator_TableClassName="RegistroControlliDataTable" msprop:Generator_TableVarName="tableRegistroControlli" msprop:Generator_RowChangedName="RegistroControlliRowChanged" msprop:Generator_TablePropName="RegistroControlli" msprop:Generator_RowDeletingName="RegistroControlliRowDeleting" msprop:Generator_RowChangingName="RegistroControlliRowChanging" msprop:Generator_RowEvHandlerName="RegistroControlliRowChangeEventHandler" msprop:Generator_RowDeletedName="RegistroControlliRowDeleted" msprop:Generator_RowClassName="RegistroControlliRow" msprop:Generator_UserTableName="RegistroControlli" msprop:Generator_RowEvArgName="RegistroControlliRowChangeEvent">
<xs:element name="RegistroControlli" msprop:Generator_TableClassName="RegistroControlliDataTable" msprop:Generator_TableVarName="tableRegistroControlli" msprop:Generator_TablePropName="RegistroControlli" msprop:Generator_RowDeletingName="RegistroControlliRowDeleting" msprop:Generator_RowChangingName="RegistroControlliRowChanging" msprop:Generator_RowEvHandlerName="RegistroControlliRowChangeEventHandler" msprop:Generator_RowDeletedName="RegistroControlliRowDeleted" msprop:Generator_UserTableName="RegistroControlli" msprop:Generator_RowChangedName="RegistroControlliRowChanged" msprop:Generator_RowEvArgName="RegistroControlliRowChangeEvent" msprop:Generator_RowClassName="RegistroControlliRow">
<xs:complexType>
<xs:sequence>
<xs:element name="IdxControllo" msdata:ReadOnly="true" msdata:AutoIncrement="true" msdata:AutoIncrementSeed="-1" msdata:AutoIncrementStep="-1" msprop:Generator_ColumnVarNameInTable="columnIdxControllo" msprop:Generator_ColumnPropNameInRow="IdxControllo" msprop:Generator_ColumnPropNameInTable="IdxControlloColumn" msprop:Generator_UserColumnName="IdxControllo" type="xs:int" />
@@ -2794,7 +2797,7 @@ SELECT idxPromessa, KeyRichiesta, Attivabile, IdxODL, CodArticolo, CodGruppo, Id
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="RegistroScarti" msprop:Generator_TableClassName="RegistroScartiDataTable" msprop:Generator_TableVarName="tableRegistroScarti" msprop:Generator_RowChangedName="RegistroScartiRowChanged" msprop:Generator_TablePropName="RegistroScarti" msprop:Generator_RowDeletingName="RegistroScartiRowDeleting" msprop:Generator_RowChangingName="RegistroScartiRowChanging" msprop:Generator_RowEvHandlerName="RegistroScartiRowChangeEventHandler" msprop:Generator_RowDeletedName="RegistroScartiRowDeleted" msprop:Generator_RowClassName="RegistroScartiRow" msprop:Generator_UserTableName="RegistroScarti" msprop:Generator_RowEvArgName="RegistroScartiRowChangeEvent">
<xs:element name="RegistroScarti" msprop:Generator_TableClassName="RegistroScartiDataTable" msprop:Generator_TableVarName="tableRegistroScarti" msprop:Generator_TablePropName="RegistroScarti" msprop:Generator_RowDeletingName="RegistroScartiRowDeleting" msprop:Generator_RowChangingName="RegistroScartiRowChanging" msprop:Generator_RowEvHandlerName="RegistroScartiRowChangeEventHandler" msprop:Generator_RowDeletedName="RegistroScartiRowDeleted" msprop:Generator_UserTableName="RegistroScarti" msprop:Generator_RowChangedName="RegistroScartiRowChanged" msprop:Generator_RowEvArgName="RegistroScartiRowChangeEvent" msprop:Generator_RowClassName="RegistroScartiRow">
<xs:complexType>
<xs:sequence>
<xs:element name="IdxMacchina" msprop:Generator_ColumnVarNameInTable="columnIdxMacchina" msprop:Generator_ColumnPropNameInRow="IdxMacchina" msprop:Generator_ColumnPropNameInTable="IdxMacchinaColumn" msprop:Generator_UserColumnName="IdxMacchina">
@@ -2860,7 +2863,7 @@ SELECT idxPromessa, KeyRichiesta, Attivabile, IdxODL, CodArticolo, CodGruppo, Id
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="StatoProd" msprop:Generator_TableClassName="StatoProdDataTable" msprop:Generator_TableVarName="tableStatoProd" msprop:Generator_RowChangedName="StatoProdRowChanged" msprop:Generator_TablePropName="StatoProd" msprop:Generator_RowDeletingName="StatoProdRowDeleting" msprop:Generator_RowChangingName="StatoProdRowChanging" msprop:Generator_RowEvHandlerName="StatoProdRowChangeEventHandler" msprop:Generator_RowDeletedName="StatoProdRowDeleted" msprop:Generator_RowClassName="StatoProdRow" msprop:Generator_UserTableName="StatoProd" msprop:Generator_RowEvArgName="StatoProdRowChangeEvent">
<xs:element name="StatoProd" msprop:Generator_TableClassName="StatoProdDataTable" msprop:Generator_TableVarName="tableStatoProd" msprop:Generator_TablePropName="StatoProd" msprop:Generator_RowDeletingName="StatoProdRowDeleting" msprop:Generator_RowChangingName="StatoProdRowChanging" msprop:Generator_RowEvHandlerName="StatoProdRowChangeEventHandler" msprop:Generator_RowDeletedName="StatoProdRowDeleted" msprop:Generator_UserTableName="StatoProd" msprop:Generator_RowChangedName="StatoProdRowChanged" msprop:Generator_RowEvArgName="StatoProdRowChangeEvent" msprop:Generator_RowClassName="StatoProdRow">
<xs:complexType>
<xs:sequence>
<xs:element name="idxMacchina" msdata:ReadOnly="true" msprop:Generator_ColumnVarNameInTable="columnidxMacchina" msprop:Generator_ColumnPropNameInRow="idxMacchina" msprop:Generator_ColumnPropNameInTable="idxMacchinaColumn" msprop:Generator_UserColumnName="idxMacchina" minOccurs="0">
@@ -2870,16 +2873,19 @@ SELECT idxPromessa, KeyRichiesta, Attivabile, IdxODL, CodArticolo, CodGruppo, Id
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:element name="IdxOdl" msdata:ReadOnly="true" msprop:Generator_ColumnVarNameInTable="columnIdxOdl" msprop:Generator_ColumnPropNameInRow="IdxOdl" msprop:Generator_ColumnPropNameInTable="IdxOdlColumn" msprop:Generator_UserColumnName="IdxOdl" type="xs:int" minOccurs="0" />
<xs:element name="PzTotODL" msdata:ReadOnly="true" msprop:Generator_ColumnVarNameInTable="columnPzTotODL" msprop:Generator_ColumnPropNameInRow="PzTotODL" msprop:Generator_ColumnPropNameInTable="PzTotODLColumn" msprop:Generator_UserColumnName="PzTotODL" type="xs:int" minOccurs="0" />
<xs:element name="PzConfScarto" msdata:ReadOnly="true" msprop:Generator_ColumnVarNameInTable="columnPzConfScarto" msprop:Generator_ColumnPropNameInRow="PzConfScarto" msprop:Generator_ColumnPropNameInTable="PzConfScartoColumn" msprop:Generator_UserColumnName="PzConfScarto" type="xs:int" minOccurs="0" />
<xs:element name="PzConfBuoni" msdata:ReadOnly="true" msprop:Generator_ColumnVarNameInTable="columnPzConfBuoni" msprop:Generator_ColumnPropNameInRow="PzConfBuoni" msprop:Generator_ColumnPropNameInTable="PzConfBuoniColumn" msprop:Generator_UserColumnName="PzConfBuoni" type="xs:int" minOccurs="0" />
<xs:element name="PzRichODL" msdata:ReadOnly="true" msprop:Generator_ColumnVarNameInTable="columnPzRichODL" msprop:Generator_ColumnPropNameInRow="PzRichODL" msprop:Generator_ColumnPropNameInTable="PzRichODLColumn" msprop:Generator_UserColumnName="PzRichODL" type="xs:int" minOccurs="0" />
<xs:element name="Pz2RecTot" msdata:ReadOnly="true" msprop:Generator_ColumnVarNameInTable="columnPz2RecTot" msprop:Generator_ColumnPropNameInRow="Pz2RecTot" msprop:Generator_ColumnPropNameInTable="Pz2RecTotColumn" msprop:Generator_UserColumnName="Pz2RecTot" type="xs:int" minOccurs="0" />
<xs:element name="Pz2RecScarto" msdata:ReadOnly="true" msprop:Generator_ColumnVarNameInTable="columnPz2RecScarto" msprop:Generator_ColumnPropNameInRow="Pz2RecScarto" msprop:Generator_ColumnPropNameInTable="Pz2RecScartoColumn" msprop:Generator_UserColumnName="Pz2RecScarto" type="xs:int" minOccurs="0" />
<xs:element name="DataFrom" msdata:ReadOnly="true" msprop:Generator_ColumnVarNameInTable="columnDataFrom" msprop:Generator_ColumnPropNameInRow="DataFrom" msprop:Generator_ColumnPropNameInTable="DataFromColumn" msprop:Generator_UserColumnName="DataFrom" type="xs:dateTime" minOccurs="0" />
<xs:element name="DataTo" msdata:ReadOnly="true" msprop:Generator_ColumnVarNameInTable="columnDataTo" msprop:Generator_ColumnPropNameInRow="DataTo" msprop:Generator_ColumnPropNameInTable="DataToColumn" msprop:Generator_UserColumnName="DataTo" type="xs:dateTime" minOccurs="0" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="PromesseODL" msprop:Generator_TableClassName="PromesseODLDataTable" msprop:Generator_TableVarName="tablePromesseODL" msprop:Generator_TablePropName="PromesseODL" msprop:Generator_RowDeletingName="PromesseODLRowDeleting" msprop:Generator_RowChangingName="PromesseODLRowChanging" msprop:Generator_RowEvHandlerName="PromesseODLRowChangeEventHandler" msprop:Generator_RowDeletedName="PromesseODLRowDeleted" msprop:Generator_UserTableName="PromesseODL" msprop:Generator_RowChangedName="PromesseODLRowChanged" msprop:Generator_RowEvArgName="PromesseODLRowChangeEvent" msprop:Generator_RowClassName="PromesseODLRow">
<xs:element name="PromesseODL" msprop:Generator_TableClassName="PromesseODLDataTable" msprop:Generator_TableVarName="tablePromesseODL" msprop:Generator_RowChangedName="PromesseODLRowChanged" msprop:Generator_TablePropName="PromesseODL" msprop:Generator_RowDeletingName="PromesseODLRowDeleting" msprop:Generator_RowChangingName="PromesseODLRowChanging" msprop:Generator_RowEvHandlerName="PromesseODLRowChangeEventHandler" msprop:Generator_RowDeletedName="PromesseODLRowDeleted" msprop:Generator_RowClassName="PromesseODLRow" msprop:Generator_UserTableName="PromesseODL" msprop:Generator_RowEvArgName="PromesseODLRowChangeEvent">
<xs:complexType>
<xs:sequence>
<xs:element name="idxPromessa" msdata:ReadOnly="true" msdata:AutoIncrement="true" msdata:AutoIncrementSeed="-1" msdata:AutoIncrementStep="-1" msprop:Generator_ColumnVarNameInTable="columnidxPromessa" msprop:Generator_ColumnPropNameInRow="idxPromessa" msprop:Generator_ColumnPropNameInTable="idxPromessaColumn" msprop:Generator_UserColumnName="idxPromessa" type="xs:int" />
+3 -3
View File
@@ -4,7 +4,7 @@
Changes to this file may cause incorrect behavior and will be lost if
the code is regenerated.
</autogenerated>-->
<DiagramLayout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" ex:showrelationlabel="False" ViewPortX="-10" ViewPortY="208" xmlns:ex="urn:schemas-microsoft-com:xml-msdatasource-layout-extended" xmlns="urn:schemas-microsoft-com:xml-msdatasource-layout">
<DiagramLayout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" ex:showrelationlabel="False" ViewPortX="-10" ViewPortY="227" xmlns:ex="urn:schemas-microsoft-com:xml-msdatasource-layout-extended" xmlns="urn:schemas-microsoft-com:xml-msdatasource-layout">
<Shapes>
<Shape ID="DesignTable:TempiCicloRilevati" ZOrder="5" X="266" Y="244" Height="296" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="145" />
<Shape ID="DesignTable:ODL" ZOrder="1" X="590" Y="407" Height="457" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="306" />
@@ -14,7 +14,7 @@
<Shape ID="DesignTable:stp_PzProd_getByMacchina" ZOrder="11" X="181" Y="769" Height="250" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="122" />
<Shape ID="DesignTable:DatiConfermati" ZOrder="21" X="585" Y="50" Height="411" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="306" />
<Shape ID="DesignTable:CalendFesteFerie" ZOrder="22" X="13" Y="736" Height="135" Width="287" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="76" />
<Shape ID="DesignTable:stp_TempoByIdxMaccPeriodClass" ZOrder="20" X="154" Y="998" Height="113" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="54" />
<Shape ID="DesignTable:stp_TempoByIdxMaccPeriodClass" ZOrder="20" X="154" Y="988" Height="113" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="54" />
<Shape ID="DesignTable:DatiProduzione" ZOrder="9" X="554" Y="922" Height="457" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="306" />
<Shape ID="DesignTable:stp_repDonati_getDatiProdMacchina" ZOrder="19" X="1005" Y="771" Height="365" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="306" />
<Shape ID="DesignTable:stp_repDonati_getLastStatoDurataMacchina" ZOrder="18" X="1003" Y="1118" Height="135" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="76" />
@@ -27,7 +27,7 @@
<Shape ID="DesignTable:ResProdTot" ZOrder="14" X="271" Y="20" Height="273" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="214" />
<Shape ID="DesignTable:RegistroControlli" ZOrder="8" X="536" Y="1403" Height="365" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="237" />
<Shape ID="DesignTable:RegistroScarti" ZOrder="7" X="172" Y="1581" Height="457" Width="300" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="306" />
<Shape ID="DesignTable:StatoProd" ZOrder="6" X="572" Y="1795" Height="250" Width="295" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="191" />
<Shape ID="DesignTable:StatoProd" ZOrder="6" X="539" Y="1784" Height="319" Width="295" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="260" />
<Shape ID="DesignTable:PromesseODL" ZOrder="2" X="927" Y="1720" Height="365" Width="266" AdapterExpanded="true" DataTableExpanded="true" OldAdapterHeight="0" OldDataTableHeight="0" SplitterPosition="283" />
</Shapes>
<Connectors />
+27 -5
View File
@@ -4,7 +4,6 @@ using System.Collections.Generic;
using System.Data.SqlClient;
using System.Globalization;
using System.Reflection;
using System.Threading;
namespace MapoDb
{
@@ -400,7 +399,7 @@ namespace MapoDb
string answ = "";
try
{
DS_applicazione.AnagraficaOperatoriRow oper = (DS_applicazione.AnagraficaOperatoriRow)DataLayer.obj.taOp.getByMatrOpr(MatrOpr)[0];
DS_applicazione.AnagraficaOperatoriRow oper = DataLayer.obj.taOp.getByMatrOpr(MatrOpr)[0];
answ = string.Format("{0} {1}", oper.Cognome, oper.Nome);
}
catch
@@ -1422,10 +1421,33 @@ namespace MapoDb
}
try
{
answ = DataLayer.obj.taMSE.getByIdxMacchina(idxMacchina)[0].PezziProd;
// recupero con stored NUOVA...
var datiProdAct = DataLayer.obj.taStatoProd.GetData(idxMacchina, DateTime.Now);
if (datiProdAct.Rows.Count > 0)
{
// solo SE ho idxODL (altrimenti loggo errore)
if (datiProdAct[0].IdxOdl > 0)
{
answ = datiProdAct[0].PzTotODL;
}
else
{
logger.lg.scriviLog("Errore in currODL x idxMacchina " + idxMacchina + ": IdxOdl = 0");
}
}
else
{
logger.lg.scriviLog("Errore in currODL x idxMacchina " + idxMacchina + ": datiProdAct vuota");
}
#if false
// vecchia procedura di lettura da MSE...
answ = DataLayer.obj.taMSE.getByIdxMacchina(idxMacchina)[0].PezziProd;
#endif
}
catch (Exception exc)
{
logger.lg.scriviLog(string.Format("Eccezione in pzCounterTC x idxMacchina {0}{1}{2}", idxMacchina, Environment.NewLine, exc), tipoLog.EXCEPTION);
}
catch
{ }
return answ;
}
/// <summary>
+30 -10
View File
@@ -2,8 +2,6 @@ using SteamWare;
using System;
using System.Collections.Generic;
using System.Data;
using System.Diagnostics;
using System.Threading;
namespace MapoDb
{
@@ -189,7 +187,7 @@ namespace MapoDb
// effettuo cambio stato INDIPENDENTEMENTE da stato precedente
try
{
rigaTransStati = taTranSt.GetUserForcedTransitions(IdxMacchina, IdxTipo)[0];
rigaTransStati = taTranSt.GetUserForcedTransitions(IdxMacchina, IdxTipo)[0];
// solo se cambia stato...
if (rigaTransStati.IdxStato != rigaTransStati.next_IdxStato)
{
@@ -253,7 +251,7 @@ namespace MapoDb
DS_applicazione.AnagraficaOperatoriRow rigaOpr;
try
{
rigaOpr = (DS_applicazione.AnagraficaOperatoriRow)(taAnOpr.getByMatrOpr(matrOpr)[0]);
rigaOpr = taAnOpr.getByMatrOpr(matrOpr)[0];
cognNome = string.Format("{0} {1}", rigaOpr.Cognome, rigaOpr.Nome);
}
catch
@@ -408,7 +406,7 @@ namespace MapoDb
bool answ = false;
try
{
answ = ((DS_applicazione.DatiMacchineRow)taDatiMacch.GetByIdx(idxMacchina)[0]).insEnabled;
answ = taDatiMacch.GetByIdx(idxMacchina)[0].insEnabled;
}
catch
{ }
@@ -422,6 +420,27 @@ namespace MapoDb
public string currODL(string idxMacchina)
{
string answ = "";
// recupero con stored NUOVA...
var datiProdAct = DataLayer.obj.taStatoProd.GetData(idxMacchina, DateTime.Now);
if (datiProdAct.Rows.Count > 0)
{
// solo SE ho idxODL (altrimenti loggo errore
if (datiProdAct[0].IdxOdl > 0)
{
answ = datiProdAct[0].IdxOdl.ToString();
}
else
{
logger.lg.scriviLog("Errore in currODL x idxMacchina " + idxMacchina + ": IdxOdl = 0");
}
}
else
{
logger.lg.scriviLog("Errore in currODL x idxMacchina " + idxMacchina + ": datiProdAct vuota");
}
// vecchia chiamata diretta
#if false
var tab = taODL.getByMacchinaAperto(idxMacchina);
if (tab.Rows.Count > 0)
{
@@ -431,7 +450,8 @@ namespace MapoDb
}
catch
{ }
}
}
#endif
return answ;
}
/// <summary>
@@ -450,7 +470,7 @@ namespace MapoDb
//2017.06.09 forzo inizializzazione oggetto..
taDatiMacch = new DS_applicazioneTableAdapters.DatiMacchineTableAdapter();
}
answ = ((DS_applicazione.DatiMacchineRow)taDatiMacch.GetByIdx(idxMacchina)[0]).sLogEnabled;
answ = taDatiMacch.GetByIdx(idxMacchina)[0].sLogEnabled;
}
catch
{ }
@@ -472,7 +492,7 @@ namespace MapoDb
//2017.06.09 forzo inizializzazione oggetto..
taMSFD = new DS_applicazioneTableAdapters.MSFDTableAdapter();
}
answ = ((DS_applicazione.MSFDRow)taMSFD.getByIdxMacc(idxMacchina)[0]).Multi == 1;
answ = taMSFD.getByIdxMacc(idxMacchina)[0].Multi == 1;
}
catch
{ }
@@ -1347,7 +1367,7 @@ namespace MapoDb
DS_applicazione.TransizioneIngressiRow rigaIngr;
try
{
rigaIngr = (DS_applicazione.TransizioneIngressiRow)(taTransIngr.GetNextStatus(IdxMacchina, IdxMicroStato, ValoreIngresso)[0]);
rigaIngr = taTransIngr.GetNextStatus(IdxMacchina, IdxMicroStato, ValoreIngresso)[0];
valori.IdxTipoEvento = rigaIngr.IdxTipoEvento;
valori.next_IdxMicroStato = rigaIngr.next_IdxMicroStato;
}
@@ -1369,7 +1389,7 @@ namespace MapoDb
DS_applicazione.StatoMacchineRow rigaStato;
try
{
rigaStato = (DS_applicazione.StatoMacchineRow)(taStatoMacchine.GetDataByIdxMacchina(idxMacchina)[0]);
rigaStato = taStatoMacchine.GetDataByIdxMacchina(idxMacchina)[0];
// cerco il colore...
try
{