Merge branch 'master' of http://192.168.0.12:13000/sc/Audit_APP
This commit is contained in:
commit
03e18f9676
97 files changed
+334
-3368
No files matched your search
@@ -0,0 +1,29 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class Alarms
|
||||
{
|
||||
public int ID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public string Name { get; set; }
|
||||
public string Category { get; set; }
|
||||
public string Variable { get; set; }
|
||||
public System.DateTime StartTime { get; set; }
|
||||
public System.DateTime EndTime { get; set; }
|
||||
public double Duration { get; set; }
|
||||
public string Shift { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<configSections>
|
||||
<!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->
|
||||
</configSections>
|
||||
<connectionStrings>
|
||||
<add name="BatchDyeingCentralEntities" connectionString="metadata=res://*/SQL_BD.csdl|res://*/SQL_BD.ssdl|res://*/SQL_BD.msl;provider=System.Data.SqlClient;provider connection string="data source=SCSERVER\EXPRESS;initial catalog=BatchDyeingCentral;persist security info=True;user id=sa;password=SC971216@server;MultipleActiveResultSets=True;App=EntityFramework"" providerName="System.Data.EntityClient" />
|
||||
</connectionStrings>
|
||||
</configuration>
|
||||
@@ -0,0 +1,29 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class AuxDslvQueue
|
||||
{
|
||||
public Nullable<int> TankNo { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string Station { get; set; }
|
||||
public Nullable<int> Industry { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public string Volume { get; set; }
|
||||
public Nullable<int> ShelfID { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class AuxDslvQueueHistory
|
||||
{
|
||||
public Nullable<int> TankNo { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string Station { get; set; }
|
||||
public Nullable<int> Industry { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public string Volume { get; set; }
|
||||
public Nullable<int> ShelfID { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class BucketInfo
|
||||
{
|
||||
public int BucketNo { get; set; }
|
||||
public string DID { get; set; }
|
||||
public Nullable<System.DateTime> StartTime { get; set; }
|
||||
public Nullable<System.DateTime> EndTime { get; set; }
|
||||
public Nullable<int> Used { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class BucketShelf
|
||||
{
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public Nullable<int> ShelfID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string Station { get; set; }
|
||||
public string DID { get; set; }
|
||||
public Nullable<int> TotalBuckets { get; set; }
|
||||
public Nullable<int> DevideNo { get; set; }
|
||||
public Nullable<int> XPos { get; set; }
|
||||
public Nullable<int> YPos { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<System.DateTime> OnShelfTime { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class BucketShelfHistory
|
||||
{
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public Nullable<int> ShelfID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string Station { get; set; }
|
||||
public string DID { get; set; }
|
||||
public Nullable<int> TotalBuckets { get; set; }
|
||||
public Nullable<int> DevideNo { get; set; }
|
||||
public Nullable<int> XPos { get; set; }
|
||||
public Nullable<int> YPos { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<System.DateTime> OnShelfTime { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class BucketShelfQueue
|
||||
{
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public Nullable<int> ShelfID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> TotalBuckets { get; set; }
|
||||
public Nullable<int> DevideNo { get; set; }
|
||||
public Nullable<int> XPos { get; set; }
|
||||
public Nullable<int> YPos { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class BucketShelfQueueHistory
|
||||
{
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public Nullable<int> ShelfID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> TotalBuckets { get; set; }
|
||||
public Nullable<int> DevideNo { get; set; }
|
||||
public Nullable<int> XPos { get; set; }
|
||||
public Nullable<int> YPos { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,21 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class CleanDevice
|
||||
{
|
||||
public string ID { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<int> Enabled { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class Customize
|
||||
{
|
||||
public int AutoKey { get; set; }
|
||||
public string StoppageReasons { get; set; }
|
||||
public string Inefficiencies { get; set; }
|
||||
public string Company { get; set; }
|
||||
public string Shifts { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class Delays
|
||||
{
|
||||
public int ID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public string Name { get; set; }
|
||||
public int Number { get; set; }
|
||||
public System.DateTime StartTime { get; set; }
|
||||
public System.DateTime EndTime { get; set; }
|
||||
public double Duration { get; set; }
|
||||
public string Shift { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DispenserEvent
|
||||
{
|
||||
public int EventID { get; set; }
|
||||
public Nullable<int> EventType { get; set; }
|
||||
public string Dispenser { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public Nullable<int> ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> Code { get; set; }
|
||||
public string Description { get; set; }
|
||||
public string Description_BIG { get; set; }
|
||||
public string Description_GB { get; set; }
|
||||
public Nullable<System.DateTime> CreateDate { get; set; }
|
||||
public Nullable<System.DateTime> ConfirmDate { get; set; }
|
||||
public Nullable<System.DateTime> FinishDate { get; set; }
|
||||
public string Shift { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,21 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DispenserLifeStatus
|
||||
{
|
||||
public string Dispenser { get; set; }
|
||||
public Nullable<int> HeartBeat { get; set; }
|
||||
public Nullable<System.DateTime> UpdateDate { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DispenserUtilization
|
||||
{
|
||||
public string Dispenser { get; set; }
|
||||
public Nullable<System.DateTime> UtilDate { get; set; }
|
||||
public Nullable<int> UtilTimes { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class Dispensers
|
||||
{
|
||||
public string Name { get; set; }
|
||||
public string Description { get; set; }
|
||||
public string Device { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public Nullable<int> ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string Station { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public string Status { get; set; }
|
||||
public Nullable<int> Automatic { get; set; }
|
||||
public Nullable<int> Enabled { get; set; }
|
||||
public Nullable<int> HeartBeat { get; set; }
|
||||
public Nullable<int> CheckPeriod { get; set; }
|
||||
public Nullable<System.DateTime> UpdateDate { get; set; }
|
||||
public Nullable<System.DateTime> CreateDate { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DyelotBucketSummary
|
||||
{
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> TotalBuckets { get; set; }
|
||||
public Nullable<int> Final { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DyelotBuckets
|
||||
{
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> DevideNo { get; set; }
|
||||
public string ProductCode { get; set; }
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public string DID { get; set; }
|
||||
public Nullable<int> Final { get; set; }
|
||||
public Nullable<int> Dissolved { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DyelotBucketsHistory
|
||||
{
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> DevideNo { get; set; }
|
||||
public string ProductCode { get; set; }
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public string DID { get; set; }
|
||||
public Nullable<int> Final { get; set; }
|
||||
public Nullable<int> Dissolved { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,40 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DyelotDetail
|
||||
{
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string Station { get; set; }
|
||||
public string ProductCode { get; set; }
|
||||
public string ProductName { get; set; }
|
||||
public int ProductType { get; set; }
|
||||
public Nullable<double> Grams { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
public Nullable<int> SN { get; set; }
|
||||
public Nullable<System.DateTime> DispenseTime { get; set; }
|
||||
public Nullable<double> DispenseGrams { get; set; }
|
||||
public Nullable<double> CurrDispGrams { get; set; }
|
||||
public Nullable<int> LADispenseResult { get; set; }
|
||||
public Nullable<int> Error { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
public string Volume { get; set; }
|
||||
public Nullable<int> CurrDispTime { get; set; }
|
||||
public string CurrVolume { get; set; }
|
||||
public string RemainVolume { get; set; }
|
||||
public Nullable<double> FinalPickup { get; set; }
|
||||
public Nullable<int> LFManual { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DyelotDslvQueue
|
||||
{
|
||||
public Nullable<int> TankNo { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> TotalBuckets { get; set; }
|
||||
public Nullable<int> DivideNo { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<int> ShelfID { get; set; }
|
||||
public Nullable<System.DateTime> SchDispenseTime { get; set; }
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DyelotDslvQueueHistory
|
||||
{
|
||||
public Nullable<int> TankNo { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> TotalBuckets { get; set; }
|
||||
public Nullable<int> DivideNo { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<int> ShelfID { get; set; }
|
||||
public Nullable<System.DateTime> SchDispenseTime { get; set; }
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,65 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DyelotHead
|
||||
{
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<System.DateTime> StartTime { get; set; }
|
||||
public Nullable<System.DateTime> EndTime { get; set; }
|
||||
public Nullable<System.DateTime> CreationTime { get; set; }
|
||||
public string TotalVolume { get; set; }
|
||||
public Nullable<int> DispenseTimes { get; set; }
|
||||
public Nullable<int> CurrDispTime { get; set; }
|
||||
public string CurrTotalVolume { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<short> Sequence { get; set; }
|
||||
public Nullable<int> Color { get; set; }
|
||||
public Nullable<double> PickUp { get; set; }
|
||||
public Nullable<double> GramsYard { get; set; }
|
||||
public Nullable<double> TotalLength { get; set; }
|
||||
public Nullable<double> FabricWidth { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
public string RefTotalVolume { get; set; }
|
||||
public string RestVolume { get; set; }
|
||||
public string LFDefine { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public Nullable<int> Blocked { get; set; }
|
||||
public Nullable<int> Industry { get; set; }
|
||||
public string Volume { get; set; }
|
||||
public Nullable<double> StandardTime { get; set; }
|
||||
public Nullable<int> LFArt { get; set; }
|
||||
public string RemainVolume { get; set; }
|
||||
public Nullable<double> FinalPickUp { get; set; }
|
||||
public Nullable<int> LFWasher { get; set; }
|
||||
public string ActualTotalVolume { get; set; }
|
||||
public Nullable<double> ActualTotalLength { get; set; }
|
||||
public Nullable<double> UsedPickup { get; set; }
|
||||
public string RemainPadderVol { get; set; }
|
||||
public Nullable<System.DateTime> ExecuteTime { get; set; }
|
||||
public string RealAdd1 { get; set; }
|
||||
public string RealAdd2 { get; set; }
|
||||
public string RealAdd3 { get; set; }
|
||||
public string RealAdd4 { get; set; }
|
||||
public string RealAdd5 { get; set; }
|
||||
public string PromptAdd1 { get; set; }
|
||||
public string PromptAdd2 { get; set; }
|
||||
public string PromptAdd3 { get; set; }
|
||||
public string PromptAdd4 { get; set; }
|
||||
public string PromptAdd5 { get; set; }
|
||||
public Nullable<int> StartButton { get; set; }
|
||||
public Nullable<int> EndButton { get; set; }
|
||||
public string MergerVol { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,21 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DyelotHistories
|
||||
{
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public byte[] History { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,83 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class Dyelots
|
||||
{
|
||||
public int ID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> Industry { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public string DispenseMachine { get; set; }
|
||||
public Nullable<System.DateTime> StartTime { get; set; }
|
||||
public Nullable<System.DateTime> EndTime { get; set; }
|
||||
public Nullable<double> StandardTime { get; set; }
|
||||
public Nullable<int> TotalShot { get; set; }
|
||||
public Nullable<short> State { get; set; }
|
||||
public Nullable<short> Blocked { get; set; }
|
||||
public string Program { get; set; }
|
||||
public Nullable<int> Color { get; set; }
|
||||
public Nullable<System.DateTime> CreationTime { get; set; }
|
||||
public string Batch { get; set; }
|
||||
public string OrderNo { get; set; }
|
||||
public Nullable<double> TotalWeight { get; set; }
|
||||
public string LiquidRatio { get; set; }
|
||||
public string TotalVolume { get; set; }
|
||||
public Nullable<int> AcidQty { get; set; }
|
||||
public Nullable<int> ActualAcidQty { get; set; }
|
||||
public Nullable<int> Sequence { get; set; }
|
||||
public Nullable<int> DispenseMode { get; set; }
|
||||
public Nullable<int> DyeDissolve { get; set; }
|
||||
public Nullable<int> CheDissolve { get; set; }
|
||||
public Nullable<int> TotalBuckets { get; set; }
|
||||
public Nullable<int> SpcTotalBuckets { get; set; }
|
||||
public Nullable<int> DissolveMethod { get; set; }
|
||||
public string ReferenceDyelot { get; set; }
|
||||
public Nullable<int> Final { get; set; }
|
||||
public Nullable<int> Shade { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
public string FabricName { get; set; }
|
||||
public string ColorName { get; set; }
|
||||
public string CustomerName { get; set; }
|
||||
public string CUSTOMER_CODE { get; set; }
|
||||
public string FABRIC_CODE { get; set; }
|
||||
public Nullable<double> GRAMS_YARD { get; set; }
|
||||
public Nullable<int> NeedDissolving { get; set; }
|
||||
public Nullable<System.DateTime> EarliestStartTime { get; set; }
|
||||
public Nullable<short> Committed { get; set; }
|
||||
public string Parameters { get; set; }
|
||||
public string Notes { get; set; }
|
||||
public Nullable<short> SummarizeResult { get; set; }
|
||||
public string ProgramsUsed { get; set; }
|
||||
public string ColorNo { get; set; }
|
||||
public Nullable<System.DateTime> ModifyDT { get; set; }
|
||||
public Nullable<System.DateTime> CreateDT { get; set; }
|
||||
public Nullable<int> Yard { get; set; }
|
||||
public string SheetNo { get; set; }
|
||||
public Nullable<double> AlarmTime { get; set; }
|
||||
public string ExRead { get; set; }
|
||||
public string FactoryTicketNo { get; set; }
|
||||
public string DyeingBatch { get; set; }
|
||||
public string EOCAlarms { get; set; }
|
||||
public Nullable<double> RunTime { get; set; }
|
||||
public Nullable<double> ProcessTime { get; set; }
|
||||
public Nullable<double> NormalTime { get; set; }
|
||||
public Nullable<double> SleepTime { get; set; }
|
||||
public Nullable<double> DelayTime { get; set; }
|
||||
public string EOCDelays { get; set; }
|
||||
public Nullable<short> DyelotStartShift { get; set; }
|
||||
public Nullable<short> DyelotEndShift { get; set; }
|
||||
public short DyeDissolving { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,38 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DyelotsBatch
|
||||
{
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string Station { get; set; }
|
||||
public Nullable<int> ShotNo { get; set; }
|
||||
public string ProductCode { get; set; }
|
||||
public Nullable<int> SN { get; set; }
|
||||
public Nullable<double> Grams { get; set; }
|
||||
public Nullable<System.DateTime> DispenseStartTime { get; set; }
|
||||
public Nullable<System.DateTime> DispenseEndTime { get; set; }
|
||||
public Nullable<double> DispenseGrams { get; set; }
|
||||
public Nullable<int> LADispenseResult { get; set; }
|
||||
public Nullable<System.DateTime> DyeWeightTime { get; set; }
|
||||
public string Process { get; set; }
|
||||
public string FinalProcess { get; set; }
|
||||
public Nullable<int> DispenseWater { get; set; }
|
||||
public Nullable<int> DrainWater { get; set; }
|
||||
public Nullable<int> DissolveTemperature { get; set; }
|
||||
public Nullable<System.DateTime> SchDispenseTime { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,82 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DyelotsBulkedRecipe
|
||||
{
|
||||
public int ID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string Station { get; set; }
|
||||
public Nullable<int> DevideNo { get; set; }
|
||||
public Nullable<int> ShotNo { get; set; }
|
||||
public string ProductCode { get; set; }
|
||||
public string ProductName { get; set; }
|
||||
public Nullable<int> ProductType { get; set; }
|
||||
public string ProductLot { get; set; }
|
||||
public Nullable<int> ProductClass { get; set; }
|
||||
public Nullable<int> SN { get; set; }
|
||||
public string Amount { get; set; }
|
||||
public Nullable<double> Grams { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
public Nullable<System.DateTime> DispenseStartTime { get; set; }
|
||||
public Nullable<System.DateTime> DispenseEndTime { get; set; }
|
||||
public Nullable<System.DateTime> DispenseTime { get; set; }
|
||||
public Nullable<double> DispenseGrams { get; set; }
|
||||
public Nullable<int> DispenseResult { get; set; }
|
||||
public Nullable<int> LADispenseResult { get; set; }
|
||||
public string Volume { get; set; }
|
||||
public Nullable<int> HostRead { get; set; }
|
||||
public string State { get; set; }
|
||||
public Nullable<int> NeedDispense { get; set; }
|
||||
public Nullable<int> MixTankNo { get; set; }
|
||||
public Nullable<System.DateTime> DyeWeightTime { get; set; }
|
||||
public string Process { get; set; }
|
||||
public string FinalProcess { get; set; }
|
||||
public string Dispenser { get; set; }
|
||||
public Nullable<int> TankNo { get; set; }
|
||||
public Nullable<int> Error { get; set; }
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public string DID { get; set; }
|
||||
public Nullable<int> StepDevideNo { get; set; }
|
||||
public Nullable<int> StepTotalBuckets { get; set; }
|
||||
public string ReferenceDyelot { get; set; }
|
||||
public Nullable<int> DispenseWater { get; set; }
|
||||
public Nullable<int> DrainWater { get; set; }
|
||||
public Nullable<int> DissolveTemperature { get; set; }
|
||||
public Nullable<System.DateTime> SchDispenseTime { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
public Nullable<int> TargetGrams { get; set; }
|
||||
public Nullable<int> ActualGrams { get; set; }
|
||||
public Nullable<System.DateTime> FinishTime { get; set; }
|
||||
public string Tagged { get; set; }
|
||||
public Nullable<int> TotalBuckets { get; set; }
|
||||
public Nullable<int> Final { get; set; }
|
||||
public Nullable<int> DissolveManual { get; set; }
|
||||
public Nullable<double> Concentration { get; set; }
|
||||
public Nullable<int> DeductTotalBuckets { get; set; }
|
||||
public Nullable<int> DeductBuckets { get; set; }
|
||||
public Nullable<double> Kilograms { get; set; }
|
||||
public Nullable<double> DKilograms { get; set; }
|
||||
public Nullable<int> DyelotID { get; set; }
|
||||
public Nullable<int> MixTemperature { get; set; }
|
||||
public Nullable<int> MixVolume { get; set; }
|
||||
public Nullable<int> MixTime { get; set; }
|
||||
public Nullable<int> MixWater { get; set; }
|
||||
public Nullable<int> RoWater { get; set; }
|
||||
public string Notes { get; set; }
|
||||
public Nullable<int> ProductIndex { get; set; }
|
||||
public double GRAVITY { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,68 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DyelotsBulkedRecipeHistory
|
||||
{
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string Station { get; set; }
|
||||
public Nullable<int> DevideNo { get; set; }
|
||||
public Nullable<int> ShotNo { get; set; }
|
||||
public string ProductCode { get; set; }
|
||||
public string ProductName { get; set; }
|
||||
public Nullable<int> ProductType { get; set; }
|
||||
public string ProductLot { get; set; }
|
||||
public Nullable<int> ProductClass { get; set; }
|
||||
public Nullable<int> SN { get; set; }
|
||||
public string Amount { get; set; }
|
||||
public Nullable<double> Grams { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
public Nullable<System.DateTime> DispenseStartTime { get; set; }
|
||||
public Nullable<System.DateTime> DispenseEndTime { get; set; }
|
||||
public Nullable<System.DateTime> DispenseTime { get; set; }
|
||||
public Nullable<double> DispenseGrams { get; set; }
|
||||
public Nullable<int> DispenseResult { get; set; }
|
||||
public Nullable<int> LADispenseResult { get; set; }
|
||||
public string Volume { get; set; }
|
||||
public Nullable<int> HostRead { get; set; }
|
||||
public string State { get; set; }
|
||||
public Nullable<int> NeedDispense { get; set; }
|
||||
public Nullable<int> MixTankNo { get; set; }
|
||||
public Nullable<System.DateTime> DyeWeightTime { get; set; }
|
||||
public string Process { get; set; }
|
||||
public string FinalProcess { get; set; }
|
||||
public string Dispenser { get; set; }
|
||||
public Nullable<int> TankNo { get; set; }
|
||||
public Nullable<int> Error { get; set; }
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public string DID { get; set; }
|
||||
public Nullable<int> StepDevideNo { get; set; }
|
||||
public Nullable<int> StepTotalBuckets { get; set; }
|
||||
public string ReferenceDyelot { get; set; }
|
||||
public Nullable<int> DispenseWater { get; set; }
|
||||
public Nullable<int> DrainWater { get; set; }
|
||||
public Nullable<int> DissolveTemperature { get; set; }
|
||||
public Nullable<System.DateTime> SchDispenseTime { get; set; }
|
||||
public Nullable<System.DateTime> FinishTime { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
public string Tagged { get; set; }
|
||||
public Nullable<int> TotalBuckets { get; set; }
|
||||
public Nullable<int> Final { get; set; }
|
||||
public Nullable<int> DissolveManual { get; set; }
|
||||
public Nullable<int> DeductTotalBuckets { get; set; }
|
||||
public Nullable<int> DeductBuckets { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DyelotsByShift
|
||||
{
|
||||
public int ID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public System.DateTime StartTime { get; set; }
|
||||
public System.DateTime EndTime { get; set; }
|
||||
public double Duration { get; set; }
|
||||
public string Shift { get; set; }
|
||||
public string SingleShift { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,52 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DyelotsHistory
|
||||
{
|
||||
public int ID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> Industry { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public string DispenseMachine { get; set; }
|
||||
public Nullable<System.DateTime> StartTime { get; set; }
|
||||
public Nullable<System.DateTime> EndTime { get; set; }
|
||||
public Nullable<double> StandardTime { get; set; }
|
||||
public Nullable<int> TotalShot { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<int> Blocked { get; set; }
|
||||
public string Program { get; set; }
|
||||
public Nullable<int> Color { get; set; }
|
||||
public Nullable<System.DateTime> CreationTime { get; set; }
|
||||
public string Batch { get; set; }
|
||||
public string OrderNo { get; set; }
|
||||
public Nullable<double> TotalWeight { get; set; }
|
||||
public string LiquidRatio { get; set; }
|
||||
public string TotalVolume { get; set; }
|
||||
public Nullable<int> AcidQty { get; set; }
|
||||
public Nullable<int> ActualAcidQty { get; set; }
|
||||
public Nullable<int> Sequence { get; set; }
|
||||
public Nullable<int> DispenseMode { get; set; }
|
||||
public Nullable<int> DyeDissolve { get; set; }
|
||||
public Nullable<int> CheDissolve { get; set; }
|
||||
public Nullable<int> TotalBuckets { get; set; }
|
||||
public Nullable<int> SpcTotalBuckets { get; set; }
|
||||
public Nullable<int> DissolveMethod { get; set; }
|
||||
public string ReferenceDyelot { get; set; }
|
||||
public Nullable<int> Final { get; set; }
|
||||
public Nullable<int> Shade { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DyelotsInAuto
|
||||
{
|
||||
public string Machine { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public Nullable<int> ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> DyeState { get; set; }
|
||||
public Nullable<System.DateTime> SchDispenseTime { get; set; }
|
||||
public Nullable<int> IsCheck { get; set; }
|
||||
public Nullable<int> Shade { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DyelotsInAutoHistory
|
||||
{
|
||||
public string Machine { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public Nullable<int> ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> DyeState { get; set; }
|
||||
public Nullable<System.DateTime> SchDispenseTime { get; set; }
|
||||
public Nullable<int> IsCheck { get; set; }
|
||||
public Nullable<int> Shade { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class EventList
|
||||
{
|
||||
public Nullable<int> Code { get; set; }
|
||||
public string Description { get; set; }
|
||||
public string Description_BIG { get; set; }
|
||||
public string Description_GB { get; set; }
|
||||
public Nullable<System.DateTime> CreateDate { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class LA571Tanks
|
||||
{
|
||||
public string Name { get; set; }
|
||||
public string Station { get; set; }
|
||||
public Nullable<int> Tank { get; set; }
|
||||
public Nullable<double> Volume { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class LabDyeDslvQueue
|
||||
{
|
||||
public Nullable<int> TankNo { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<int> ShelfID { get; set; }
|
||||
public Nullable<int> DistID { get; set; }
|
||||
public Nullable<System.DateTime> SchDispenseTime { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class LabDyeDslvQueueHistory
|
||||
{
|
||||
public Nullable<int> TankNo { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<int> ShelfID { get; set; }
|
||||
public Nullable<int> DistID { get; set; }
|
||||
public Nullable<System.DateTime> SchDispenseTime { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class MachineState
|
||||
{
|
||||
public string Machine { get; set; }
|
||||
public string DispenseDyelot { get; set; }
|
||||
public Nullable<int> DispenseReDye { get; set; }
|
||||
public Nullable<int> ChemicalCallOff { get; set; }
|
||||
public Nullable<int> ChemicalState { get; set; }
|
||||
public Nullable<int> ChemicalTank { get; set; }
|
||||
public Nullable<int> ChemicalTankSize { get; set; }
|
||||
public string ChemicalDispenser { get; set; }
|
||||
public Nullable<int> ChemicalError { get; set; }
|
||||
public Nullable<int> ChemicalTargetSelect { get; set; }
|
||||
public Nullable<int> DyeCallOff { get; set; }
|
||||
public Nullable<int> DyeState { get; set; }
|
||||
public Nullable<int> DyeTank { get; set; }
|
||||
public Nullable<int> DyeTankSize { get; set; }
|
||||
public string DyeDispenser { get; set; }
|
||||
public Nullable<int> DyeError { get; set; }
|
||||
public Nullable<int> PowderCallOff { get; set; }
|
||||
public Nullable<int> PowderState { get; set; }
|
||||
public Nullable<int> PowderTank { get; set; }
|
||||
public Nullable<int> PowderTankSize { get; set; }
|
||||
public string PowderDispenser { get; set; }
|
||||
public Nullable<int> PowderError { get; set; }
|
||||
public Nullable<int> HostRead { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,42 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class MachineStateHistory
|
||||
{
|
||||
public string Machine { get; set; }
|
||||
public string DispenseDyelot { get; set; }
|
||||
public Nullable<int> DispenseReDye { get; set; }
|
||||
public Nullable<int> ChemicalCallOff { get; set; }
|
||||
public Nullable<int> ChemicalState { get; set; }
|
||||
public Nullable<int> ChemicalTank { get; set; }
|
||||
public Nullable<int> ChemicalTankSize { get; set; }
|
||||
public string ChemicalDispenser { get; set; }
|
||||
public Nullable<int> ChemicalError { get; set; }
|
||||
public Nullable<int> ChemicalTargetSelect { get; set; }
|
||||
public Nullable<int> DyeCallOff { get; set; }
|
||||
public Nullable<int> DyeState { get; set; }
|
||||
public Nullable<int> DyeTank { get; set; }
|
||||
public Nullable<int> DyeTankSize { get; set; }
|
||||
public string DyeDispenser { get; set; }
|
||||
public Nullable<int> DyeError { get; set; }
|
||||
public Nullable<int> PowderCallOff { get; set; }
|
||||
public Nullable<int> PowderState { get; set; }
|
||||
public Nullable<int> PowderTank { get; set; }
|
||||
public Nullable<int> PowderTankSize { get; set; }
|
||||
public string PowderDispenser { get; set; }
|
||||
public Nullable<int> PowderError { get; set; }
|
||||
public Nullable<int> HostRead { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,115 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class Machines
|
||||
{
|
||||
public string Name { get; set; }
|
||||
public string DispenseDyelot { get; set; }
|
||||
public Nullable<int> DispenseReDye { get; set; }
|
||||
public string RescheduleGroup { get; set; }
|
||||
public string Connect { get; set; }
|
||||
public Nullable<int> ChemicalCallOff { get; set; }
|
||||
public Nullable<int> ChemicalState { get; set; }
|
||||
public Nullable<int> ChemicalTank { get; set; }
|
||||
public Nullable<int> ChemicalTankSize { get; set; }
|
||||
public Nullable<int> ChemicalEnabled { get; set; }
|
||||
public string ChemicalStatus { get; set; }
|
||||
public string ChemicalDispenser { get; set; }
|
||||
public Nullable<int> ChemicalError { get; set; }
|
||||
public Nullable<int> ChemicalDistribute { get; set; }
|
||||
public string ChemicalStation { get; set; }
|
||||
public Nullable<int> ChemicalDevideNo { get; set; }
|
||||
public Nullable<System.DateTime> ChemicalDispensedTime { get; set; }
|
||||
public Nullable<int> ChemicalDefaultTank { get; set; }
|
||||
public Nullable<int> ChemicalDissolving { get; set; }
|
||||
public Nullable<int> ChemicalResp { get; set; }
|
||||
public Nullable<int> ChemicalCallOff2 { get; set; }
|
||||
public Nullable<int> ChemicalState2 { get; set; }
|
||||
public Nullable<int> ChemicalTank2 { get; set; }
|
||||
public string ChemicalStatus2 { get; set; }
|
||||
public Nullable<int> ChemicalResp2 { get; set; }
|
||||
public Nullable<int> ChemicalTargetSelect { get; set; }
|
||||
public string ChemicalTargetMachine { get; set; }
|
||||
public Nullable<int> DyeCallOff { get; set; }
|
||||
public Nullable<int> DyeState { get; set; }
|
||||
public Nullable<int> DyeTank { get; set; }
|
||||
public Nullable<int> DyeTankSize { get; set; }
|
||||
public Nullable<int> DyeEnabled { get; set; }
|
||||
public string DyeStatus { get; set; }
|
||||
public string DyeDispenser { get; set; }
|
||||
public Nullable<int> DyeError { get; set; }
|
||||
public Nullable<int> DyeDistribute { get; set; }
|
||||
public string DyeStation { get; set; }
|
||||
public Nullable<int> DyeDevideNo { get; set; }
|
||||
public Nullable<System.DateTime> DyeDispensedTime { get; set; }
|
||||
public Nullable<int> DyeDefaultTank { get; set; }
|
||||
public Nullable<int> DyeResp { get; set; }
|
||||
public string DyeDispenseDyelot { get; set; }
|
||||
public Nullable<int> DyeDispenseReDye { get; set; }
|
||||
public Nullable<int> DyeDissolving { get; set; }
|
||||
public Nullable<int> PowderCallOff { get; set; }
|
||||
public Nullable<int> PowderState { get; set; }
|
||||
public Nullable<int> PowderTank { get; set; }
|
||||
public Nullable<int> PowderTankSize { get; set; }
|
||||
public Nullable<int> PowderEnabled { get; set; }
|
||||
public string PowderStatus { get; set; }
|
||||
public string PowderDispenser { get; set; }
|
||||
public Nullable<int> PowderError { get; set; }
|
||||
public string PowderStation { get; set; }
|
||||
public Nullable<int> PowderDevideNo { get; set; }
|
||||
public Nullable<System.DateTime> PowderDispensedTime { get; set; }
|
||||
public Nullable<int> PowderDefaultTank { get; set; }
|
||||
public Nullable<int> PowderResp { get; set; }
|
||||
public Nullable<int> HostRead { get; set; }
|
||||
public string OnSystem { get; set; }
|
||||
public string SystemID { get; set; }
|
||||
public Nullable<System.DateTime> SchDispenseTime { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
public Nullable<int> AutoMode { get; set; }
|
||||
public Nullable<int> UseOnScheduling { get; set; }
|
||||
public string CheDispenseDyelot { get; set; }
|
||||
public Nullable<int> CheDispenseReDye { get; set; }
|
||||
public Nullable<int> SampleDye { get; set; }
|
||||
public string name1 { get; set; }
|
||||
public string Parameters { get; set; }
|
||||
public string ProgramGroup { get; set; }
|
||||
public string ReportGroup { get; set; }
|
||||
public string PortAddress { get; set; }
|
||||
public Nullable<short> Interrupt { get; set; }
|
||||
public Nullable<short> NetworkNumber { get; set; }
|
||||
public string SpecificMachineMimic { get; set; }
|
||||
public Nullable<short> OutOfService { get; set; }
|
||||
public Nullable<short> IsGhost { get; set; }
|
||||
public Nullable<short> ManualDownloadOnly { get; set; }
|
||||
public string LogicArtPort { get; set; }
|
||||
public Nullable<short> GastonLoggedOn { get; set; }
|
||||
public Nullable<short> DEnabled { get; set; }
|
||||
public Nullable<short> DLookAhead { get; set; }
|
||||
public Nullable<short> LogicArtUnlocked { get; set; }
|
||||
public Nullable<short> MaximumGradient { get; set; }
|
||||
public string LoggedOffReason { get; set; }
|
||||
public string LoggedOffNotes { get; set; }
|
||||
public Nullable<short> AutoDispense { get; set; }
|
||||
public Nullable<short> AllowRemoteReschedule { get; set; }
|
||||
public Nullable<short> CorrectionsAbove { get; set; }
|
||||
public Nullable<short> Is161 { get; set; }
|
||||
public Nullable<short> Locked { get; set; }
|
||||
public Nullable<short> AutoDownloadParams { get; set; }
|
||||
public Nullable<short> NoAutoDownloadMessages { get; set; }
|
||||
public string TonelloIP { get; set; }
|
||||
public string Test { get; set; }
|
||||
public string MainTemperature { get; set; }
|
||||
public Nullable<int> CallType { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,46 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class MachinesHistory
|
||||
{
|
||||
public string Machine { get; set; }
|
||||
public string DispenseDyelot { get; set; }
|
||||
public Nullable<int> DispenseReDye { get; set; }
|
||||
public Nullable<int> ChemicalCallOff { get; set; }
|
||||
public Nullable<int> ChemicalState { get; set; }
|
||||
public Nullable<int> ChemicalTank { get; set; }
|
||||
public Nullable<int> ChemicalTankSize { get; set; }
|
||||
public string ChemicalDispenser { get; set; }
|
||||
public Nullable<int> ChemicalError { get; set; }
|
||||
public Nullable<int> ChemicalCallOff2 { get; set; }
|
||||
public Nullable<int> ChemicalState2 { get; set; }
|
||||
public Nullable<int> ChemicalTank2 { get; set; }
|
||||
public Nullable<int> DyeCallOff { get; set; }
|
||||
public Nullable<int> DyeState { get; set; }
|
||||
public Nullable<int> DyeTank { get; set; }
|
||||
public Nullable<int> DyeTankSize { get; set; }
|
||||
public string DyeDispenser { get; set; }
|
||||
public Nullable<int> DyeError { get; set; }
|
||||
public Nullable<int> PowderCallOff { get; set; }
|
||||
public Nullable<int> PowderState { get; set; }
|
||||
public Nullable<int> PowderTank { get; set; }
|
||||
public Nullable<int> PowderTankSize { get; set; }
|
||||
public string PowderDispenser { get; set; }
|
||||
public Nullable<int> PowderError { get; set; }
|
||||
public Nullable<int> HostRead { get; set; }
|
||||
public string DyeDispenseDyelot { get; set; }
|
||||
public Nullable<int> DyeDispenseReDye { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class ManualWeightQueue
|
||||
{
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<System.DateTime> CallTime { get; set; }
|
||||
public Nullable<int> Module { get; set; }
|
||||
public string ModuleName { get; set; }
|
||||
public string Area { get; set; }
|
||||
public Nullable<System.DateTime> EndTime { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class ManualWeightQueueHistory
|
||||
{
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<System.DateTime> CallTime { get; set; }
|
||||
public Nullable<int> Module { get; set; }
|
||||
public string ModuleName { get; set; }
|
||||
public string Area { get; set; }
|
||||
public Nullable<System.DateTime> EndTime { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -31,8 +31,17 @@
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\EntityFramework.6.2.0\lib\net45\EntityFramework.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="EntityFramework.SqlServer, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\EntityFramework.6.2.0\lib\net45\EntityFramework.SqlServer.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.ComponentModel.DataAnnotations" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Runtime.Serialization" />
|
||||
<Reference Include="System.Security" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
@@ -41,7 +50,245 @@
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Alarms.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="AuxDslvQueue.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="AuxDslvQueueHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="BucketInfo.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="BucketShelf.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="BucketShelfHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="BucketShelfQueue.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="BucketShelfQueueHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="CleanDevice.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Customize.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Delays.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DispenserEvent.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DispenserLifeStatus.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Dispensers.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DispenserUtilization.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DyelotBuckets.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DyelotBucketsHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DyelotBucketSummary.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DyelotDetail.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DyelotDslvQueue.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DyelotDslvQueueHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DyelotHead.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DyelotHistories.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Dyelots.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DyelotsBatch.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DyelotsBulkedRecipe.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DyelotsBulkedRecipeHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DyelotsByShift.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DyelotsHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DyelotsInAuto.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DyelotsInAutoHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="EventList.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="LA571Tanks.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="LabDyeDslvQueue.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="LabDyeDslvQueueHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Machines.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="MachinesHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="MachineState.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="MachineStateHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="ManualWeightQueue.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="ManualWeightQueueHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="PartsStatus.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="PartsStatusHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="PipeFill.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="PipeHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Pipes.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="ProgramGroups.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Programs.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="ProgramsUsed.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="RecipeDeduct.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="RecipeDeductHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="record.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="RFIDRecordQueue.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="RFIDRecordQueueHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="SampleDyeDslvQueue.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="SampleDyeDslvQueueHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="SchedulingLog.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Shelf.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="SQL_BD.Context.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DesignTime>True</DesignTime>
|
||||
<DependentUpon>SQL_BD.Context.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="SQL_BD.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DesignTime>True</DesignTime>
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="SQL_BD.Designer.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DesignTime>True</DesignTime>
|
||||
<DependentUpon>SQL_BD.edmx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Steps.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="StepVisits.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Stoppages.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="TagShelf.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="UserGroup.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Users.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WaitChemical.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<EntityDeploy Include="SQL_BD.edmx">
|
||||
<Generator>EntityModelCodeGenerator</Generator>
|
||||
<LastGenOutput>SQL_BD.Designer.cs</LastGenOutput>
|
||||
</EntityDeploy>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.Config" />
|
||||
<None Include="packages.config" />
|
||||
<None Include="SQL_BD.edmx.diagram">
|
||||
<DependentUpon>SQL_BD.edmx</DependentUpon>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Content Include="SQL_BD.Context.tt">
|
||||
<Generator>TextTemplatingFileGenerator</Generator>
|
||||
<LastGenOutput>SQL_BD.Context.cs</LastGenOutput>
|
||||
<DependentUpon>SQL_BD.edmx</DependentUpon>
|
||||
</Content>
|
||||
<Content Include="SQL_BD.tt">
|
||||
<Generator>TextTemplatingFileGenerator</Generator>
|
||||
<DependentUpon>SQL_BD.edmx</DependentUpon>
|
||||
<LastGenOutput>SQL_BD.cs</LastGenOutput>
|
||||
</Content>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Service Include="{508349B6-6B84-4DF5-91F0-309BEEBAD82D}" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
</Project>
|
||||
@@ -0,0 +1,32 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class PartsStatus
|
||||
{
|
||||
public string CUST_CODE { get; set; }
|
||||
public string Dispenser { get; set; }
|
||||
public string PartsCode { get; set; }
|
||||
public string PartsName { get; set; }
|
||||
public Nullable<int> PartsType { get; set; }
|
||||
public string Description { get; set; }
|
||||
public Nullable<int> FactoryValue { get; set; }
|
||||
public Nullable<int> UsedCount { get; set; }
|
||||
public Nullable<int> RunningTime { get; set; }
|
||||
public Nullable<System.DateTime> ResetDate { get; set; }
|
||||
public Nullable<System.DateTime> WarnDate { get; set; }
|
||||
public Nullable<System.DateTime> UpdateDate { get; set; }
|
||||
public Nullable<System.DateTime> CreateDate { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class PartsStatusHistory
|
||||
{
|
||||
public string CUST_CODE { get; set; }
|
||||
public string Dispenser { get; set; }
|
||||
public string PartsCode { get; set; }
|
||||
public string PartsName { get; set; }
|
||||
public Nullable<int> PartsType { get; set; }
|
||||
public string Description { get; set; }
|
||||
public Nullable<int> FactoryValue { get; set; }
|
||||
public Nullable<int> UsedCount { get; set; }
|
||||
public Nullable<int> RunningTime { get; set; }
|
||||
public Nullable<System.DateTime> ResetDate { get; set; }
|
||||
public Nullable<System.DateTime> WarnDate { get; set; }
|
||||
public Nullable<System.DateTime> UpdateDate { get; set; }
|
||||
public Nullable<System.DateTime> CreateDate { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class PipeFill
|
||||
{
|
||||
public string ProductCode { get; set; }
|
||||
public string ProductName { get; set; }
|
||||
public string Dispenser { get; set; }
|
||||
public Nullable<int> No { get; set; }
|
||||
public Nullable<double> Qty { get; set; }
|
||||
public Nullable<System.DateTime> StartTime { get; set; }
|
||||
public Nullable<System.DateTime> EndTime { get; set; }
|
||||
public Nullable<System.DateTime> AlarmTime { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class PipeHistory
|
||||
{
|
||||
public string ProductCode { get; set; }
|
||||
public string ProductName { get; set; }
|
||||
public Nullable<int> ProductType { get; set; }
|
||||
public string Dispenser { get; set; }
|
||||
public Nullable<int> No { get; set; }
|
||||
public Nullable<double> Qty { get; set; }
|
||||
public Nullable<System.DateTime> StartTime { get; set; }
|
||||
public Nullable<System.DateTime> EndTime { get; set; }
|
||||
public Nullable<System.DateTime> AlarmTime { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class Pipes
|
||||
{
|
||||
public string ProductCode { get; set; }
|
||||
public string ProductName { get; set; }
|
||||
public Nullable<int> ProductType { get; set; }
|
||||
public string Dispenser { get; set; }
|
||||
public Nullable<int> Enabled { get; set; }
|
||||
public Nullable<int> No { get; set; }
|
||||
public Nullable<double> MinLimit { get; set; }
|
||||
public Nullable<double> MaxLimit { get; set; }
|
||||
public Nullable<int> MinAction { get; set; }
|
||||
public Nullable<int> MaxAction { get; set; }
|
||||
public Nullable<int> Conc { get; set; }
|
||||
public double Gravity { get; set; }
|
||||
public string Alarm { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,40 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class ProgramGroups
|
||||
{
|
||||
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors")]
|
||||
public ProgramGroups()
|
||||
{
|
||||
this.Programs = new HashSet<Programs>();
|
||||
}
|
||||
|
||||
public string Name { get; set; }
|
||||
public string UserPrompts { get; set; }
|
||||
public byte[] TypeLibrary { get; set; }
|
||||
public string Sections { get; set; }
|
||||
public Nullable<int> MaximumPrograms { get; set; }
|
||||
public Nullable<short> OutOfService { get; set; }
|
||||
public string DyelotParameterCommands { get; set; }
|
||||
public string CommandHelp { get; set; }
|
||||
public string UsesProgramsFromGroup { get; set; }
|
||||
public Nullable<short> MaximumGradient { get; set; }
|
||||
public Nullable<short> QQMinutes { get; set; }
|
||||
public Nullable<short> MessageMinutes { get; set; }
|
||||
public string Inefficiencies { get; set; }
|
||||
|
||||
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
|
||||
public virtual ICollection<Programs> Programs { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class Programs
|
||||
{
|
||||
public string ProgramGroup { get; set; }
|
||||
public int ProgramNumber { get; set; }
|
||||
public string Name { get; set; }
|
||||
public string Steps { get; set; }
|
||||
public string Notes { get; set; }
|
||||
public Nullable<System.DateTime> ModifiedTime { get; set; }
|
||||
public Nullable<double> StandardTime { get; set; }
|
||||
|
||||
public virtual ProgramGroups ProgramGroups { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class ProgramsUsed
|
||||
{
|
||||
public int ID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public string Program { get; set; }
|
||||
public string Name { get; set; }
|
||||
public string Steps { get; set; }
|
||||
public Nullable<int> StepsNoBpCrc { get; set; }
|
||||
public Nullable<double> ComputedTime { get; set; }
|
||||
public Nullable<int> MaxTemperature { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public System.DateTime StartTime { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class RFIDRecordQueue
|
||||
{
|
||||
public Nullable<int> Station { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public Nullable<int> DevideNo { get; set; }
|
||||
public Nullable<int> TotalBuckets { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public string DID { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class RFIDRecordQueueHistory
|
||||
{
|
||||
public Nullable<int> Station { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public Nullable<int> DevideNo { get; set; }
|
||||
public Nullable<int> TotalBuckets { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public string DID { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class RecipeDeduct
|
||||
{
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string Station { get; set; }
|
||||
public Nullable<int> ShotNo { get; set; }
|
||||
public string ProductCode { get; set; }
|
||||
public Nullable<System.DateTime> DeductTime { get; set; }
|
||||
public Nullable<double> DeductGrams { get; set; }
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public string DID { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,30 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class RecipeDeductHistory
|
||||
{
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string Station { get; set; }
|
||||
public Nullable<int> ShotNo { get; set; }
|
||||
public string ProductCode { get; set; }
|
||||
public Nullable<System.DateTime> DeductTime { get; set; }
|
||||
public Nullable<double> DeductGrams { get; set; }
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public string DID { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,94 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Data.Entity;
|
||||
using System.Data.Entity.Infrastructure;
|
||||
|
||||
public partial class BatchDyeingCentralEntities : DbContext
|
||||
{
|
||||
public BatchDyeingCentralEntities()
|
||||
: base("name=BatchDyeingCentralEntities")
|
||||
{
|
||||
}
|
||||
|
||||
protected override void OnModelCreating(DbModelBuilder modelBuilder)
|
||||
{
|
||||
throw new UnintentionalCodeFirstException();
|
||||
}
|
||||
|
||||
public virtual DbSet<Alarms> Alarms { get; set; }
|
||||
public virtual DbSet<Customize> Customize { get; set; }
|
||||
public virtual DbSet<Delays> Delays { get; set; }
|
||||
public virtual DbSet<DyelotHead> DyelotHead { get; set; }
|
||||
public virtual DbSet<DyelotHistories> DyelotHistories { get; set; }
|
||||
public virtual DbSet<Dyelots> Dyelots { get; set; }
|
||||
public virtual DbSet<DyelotsByShift> DyelotsByShift { get; set; }
|
||||
public virtual DbSet<Machines> Machines { get; set; }
|
||||
public virtual DbSet<MachineState> MachineState { get; set; }
|
||||
public virtual DbSet<ProgramGroups> ProgramGroups { get; set; }
|
||||
public virtual DbSet<Programs> Programs { get; set; }
|
||||
public virtual DbSet<ProgramsUsed> ProgramsUsed { get; set; }
|
||||
public virtual DbSet<record> record { get; set; }
|
||||
public virtual DbSet<SchedulingLog> SchedulingLog { get; set; }
|
||||
public virtual DbSet<Steps> Steps { get; set; }
|
||||
public virtual DbSet<StepVisits> StepVisits { get; set; }
|
||||
public virtual DbSet<Stoppages> Stoppages { get; set; }
|
||||
public virtual DbSet<Users> Users { get; set; }
|
||||
public virtual DbSet<AuxDslvQueue> AuxDslvQueue { get; set; }
|
||||
public virtual DbSet<AuxDslvQueueHistory> AuxDslvQueueHistory { get; set; }
|
||||
public virtual DbSet<BucketInfo> BucketInfo { get; set; }
|
||||
public virtual DbSet<BucketShelf> BucketShelf { get; set; }
|
||||
public virtual DbSet<BucketShelfHistory> BucketShelfHistory { get; set; }
|
||||
public virtual DbSet<BucketShelfQueue> BucketShelfQueue { get; set; }
|
||||
public virtual DbSet<BucketShelfQueueHistory> BucketShelfQueueHistory { get; set; }
|
||||
public virtual DbSet<CleanDevice> CleanDevice { get; set; }
|
||||
public virtual DbSet<DispenserEvent> DispenserEvent { get; set; }
|
||||
public virtual DbSet<DispenserLifeStatus> DispenserLifeStatus { get; set; }
|
||||
public virtual DbSet<Dispensers> Dispensers { get; set; }
|
||||
public virtual DbSet<DispenserUtilization> DispenserUtilization { get; set; }
|
||||
public virtual DbSet<DyelotBuckets> DyelotBuckets { get; set; }
|
||||
public virtual DbSet<DyelotBucketsHistory> DyelotBucketsHistory { get; set; }
|
||||
public virtual DbSet<DyelotBucketSummary> DyelotBucketSummary { get; set; }
|
||||
public virtual DbSet<DyelotDetail> DyelotDetail { get; set; }
|
||||
public virtual DbSet<DyelotDslvQueue> DyelotDslvQueue { get; set; }
|
||||
public virtual DbSet<DyelotDslvQueueHistory> DyelotDslvQueueHistory { get; set; }
|
||||
public virtual DbSet<DyelotsBatch> DyelotsBatch { get; set; }
|
||||
public virtual DbSet<DyelotsBulkedRecipe> DyelotsBulkedRecipe { get; set; }
|
||||
public virtual DbSet<DyelotsBulkedRecipeHistory> DyelotsBulkedRecipeHistory { get; set; }
|
||||
public virtual DbSet<DyelotsHistory> DyelotsHistory { get; set; }
|
||||
public virtual DbSet<DyelotsInAuto> DyelotsInAuto { get; set; }
|
||||
public virtual DbSet<DyelotsInAutoHistory> DyelotsInAutoHistory { get; set; }
|
||||
public virtual DbSet<EventList> EventList { get; set; }
|
||||
public virtual DbSet<LA571Tanks> LA571Tanks { get; set; }
|
||||
public virtual DbSet<LabDyeDslvQueue> LabDyeDslvQueue { get; set; }
|
||||
public virtual DbSet<LabDyeDslvQueueHistory> LabDyeDslvQueueHistory { get; set; }
|
||||
public virtual DbSet<MachinesHistory> MachinesHistory { get; set; }
|
||||
public virtual DbSet<MachineStateHistory> MachineStateHistory { get; set; }
|
||||
public virtual DbSet<ManualWeightQueue> ManualWeightQueue { get; set; }
|
||||
public virtual DbSet<ManualWeightQueueHistory> ManualWeightQueueHistory { get; set; }
|
||||
public virtual DbSet<PartsStatus> PartsStatus { get; set; }
|
||||
public virtual DbSet<PartsStatusHistory> PartsStatusHistory { get; set; }
|
||||
public virtual DbSet<PipeFill> PipeFill { get; set; }
|
||||
public virtual DbSet<PipeHistory> PipeHistory { get; set; }
|
||||
public virtual DbSet<Pipes> Pipes { get; set; }
|
||||
public virtual DbSet<RecipeDeduct> RecipeDeduct { get; set; }
|
||||
public virtual DbSet<RecipeDeductHistory> RecipeDeductHistory { get; set; }
|
||||
public virtual DbSet<RFIDRecordQueue> RFIDRecordQueue { get; set; }
|
||||
public virtual DbSet<RFIDRecordQueueHistory> RFIDRecordQueueHistory { get; set; }
|
||||
public virtual DbSet<SampleDyeDslvQueue> SampleDyeDslvQueue { get; set; }
|
||||
public virtual DbSet<SampleDyeDslvQueueHistory> SampleDyeDslvQueueHistory { get; set; }
|
||||
public virtual DbSet<Shelf> Shelf { get; set; }
|
||||
public virtual DbSet<TagShelf> TagShelf { get; set; }
|
||||
public virtual DbSet<UserGroup> UserGroup { get; set; }
|
||||
public virtual DbSet<WaitChemical> WaitChemical { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,636 @@
|
||||
<#@ template language="C#" debug="false" hostspecific="true"#>
|
||||
<#@ include file="EF6.Utility.CS.ttinclude"#><#@
|
||||
output extension=".cs"#><#
|
||||
|
||||
const string inputFile = @"SQL_BD.edmx";
|
||||
var textTransform = DynamicTextTransformation.Create(this);
|
||||
var code = new CodeGenerationTools(this);
|
||||
var ef = new MetadataTools(this);
|
||||
var typeMapper = new TypeMapper(code, ef, textTransform.Errors);
|
||||
var loader = new EdmMetadataLoader(textTransform.Host, textTransform.Errors);
|
||||
var itemCollection = loader.CreateEdmItemCollection(inputFile);
|
||||
var modelNamespace = loader.GetModelNamespace(inputFile);
|
||||
var codeStringGenerator = new CodeStringGenerator(code, typeMapper, ef);
|
||||
|
||||
var container = itemCollection.OfType<EntityContainer>().FirstOrDefault();
|
||||
if (container == null)
|
||||
{
|
||||
return string.Empty;
|
||||
}
|
||||
#>
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// <#=CodeGenerationTools.GetResourceString("Template_GeneratedCodeCommentLine1")#>
|
||||
//
|
||||
// <#=CodeGenerationTools.GetResourceString("Template_GeneratedCodeCommentLine2")#>
|
||||
// <#=CodeGenerationTools.GetResourceString("Template_GeneratedCodeCommentLine3")#>
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
<#
|
||||
|
||||
var codeNamespace = code.VsNamespaceSuggestion();
|
||||
if (!String.IsNullOrEmpty(codeNamespace))
|
||||
{
|
||||
#>
|
||||
namespace <#=code.EscapeNamespace(codeNamespace)#>
|
||||
{
|
||||
<#
|
||||
PushIndent(" ");
|
||||
}
|
||||
|
||||
#>
|
||||
using System;
|
||||
using System.Data.Entity;
|
||||
using System.Data.Entity.Infrastructure;
|
||||
<#
|
||||
if (container.FunctionImports.Any())
|
||||
{
|
||||
#>
|
||||
using System.Data.Entity.Core.Objects;
|
||||
using System.Linq;
|
||||
<#
|
||||
}
|
||||
#>
|
||||
|
||||
<#=Accessibility.ForType(container)#> partial class <#=code.Escape(container)#> : DbContext
|
||||
{
|
||||
public <#=code.Escape(container)#>()
|
||||
: base("name=<#=container.Name#>")
|
||||
{
|
||||
<#
|
||||
if (!loader.IsLazyLoadingEnabled(container))
|
||||
{
|
||||
#>
|
||||
this.Configuration.LazyLoadingEnabled = false;
|
||||
<#
|
||||
}
|
||||
|
||||
foreach (var entitySet in container.BaseEntitySets.OfType<EntitySet>())
|
||||
{
|
||||
// Note: the DbSet members are defined below such that the getter and
|
||||
// setter always have the same accessibility as the DbSet definition
|
||||
if (Accessibility.ForReadOnlyProperty(entitySet) != "public")
|
||||
{
|
||||
#>
|
||||
<#=codeStringGenerator.DbSetInitializer(entitySet)#>
|
||||
<#
|
||||
}
|
||||
}
|
||||
#>
|
||||
}
|
||||
|
||||
protected override void OnModelCreating(DbModelBuilder modelBuilder)
|
||||
{
|
||||
throw new UnintentionalCodeFirstException();
|
||||
}
|
||||
|
||||
<#
|
||||
foreach (var entitySet in container.BaseEntitySets.OfType<EntitySet>())
|
||||
{
|
||||
#>
|
||||
<#=codeStringGenerator.DbSet(entitySet)#>
|
||||
<#
|
||||
}
|
||||
|
||||
foreach (var edmFunction in container.FunctionImports)
|
||||
{
|
||||
WriteFunctionImport(typeMapper, codeStringGenerator, edmFunction, modelNamespace, includeMergeOption: false);
|
||||
}
|
||||
#>
|
||||
}
|
||||
<#
|
||||
|
||||
if (!String.IsNullOrEmpty(codeNamespace))
|
||||
{
|
||||
PopIndent();
|
||||
#>
|
||||
}
|
||||
<#
|
||||
}
|
||||
#>
|
||||
<#+
|
||||
|
||||
private void WriteFunctionImport(TypeMapper typeMapper, CodeStringGenerator codeStringGenerator, EdmFunction edmFunction, string modelNamespace, bool includeMergeOption)
|
||||
{
|
||||
if (typeMapper.IsComposable(edmFunction))
|
||||
{
|
||||
#>
|
||||
|
||||
[DbFunction("<#=edmFunction.NamespaceName#>", "<#=edmFunction.Name#>")]
|
||||
<#=codeStringGenerator.ComposableFunctionMethod(edmFunction, modelNamespace)#>
|
||||
{
|
||||
<#+
|
||||
codeStringGenerator.WriteFunctionParameters(edmFunction, WriteFunctionParameter);
|
||||
#>
|
||||
<#=codeStringGenerator.ComposableCreateQuery(edmFunction, modelNamespace)#>
|
||||
}
|
||||
<#+
|
||||
}
|
||||
else
|
||||
{
|
||||
#>
|
||||
|
||||
<#=codeStringGenerator.FunctionMethod(edmFunction, modelNamespace, includeMergeOption)#>
|
||||
{
|
||||
<#+
|
||||
codeStringGenerator.WriteFunctionParameters(edmFunction, WriteFunctionParameter);
|
||||
#>
|
||||
<#=codeStringGenerator.ExecuteFunction(edmFunction, modelNamespace, includeMergeOption)#>
|
||||
}
|
||||
<#+
|
||||
if (typeMapper.GenerateMergeOptionFunction(edmFunction, includeMergeOption))
|
||||
{
|
||||
WriteFunctionImport(typeMapper, codeStringGenerator, edmFunction, modelNamespace, includeMergeOption: true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void WriteFunctionParameter(string name, string isNotNull, string notNullInit, string nullInit)
|
||||
{
|
||||
#>
|
||||
var <#=name#> = <#=isNotNull#> ?
|
||||
<#=notNullInit#> :
|
||||
<#=nullInit#>;
|
||||
|
||||
<#+
|
||||
}
|
||||
|
||||
public const string TemplateId = "CSharp_DbContext_Context_EF6";
|
||||
|
||||
public class CodeStringGenerator
|
||||
{
|
||||
private readonly CodeGenerationTools _code;
|
||||
private readonly TypeMapper _typeMapper;
|
||||
private readonly MetadataTools _ef;
|
||||
|
||||
public CodeStringGenerator(CodeGenerationTools code, TypeMapper typeMapper, MetadataTools ef)
|
||||
{
|
||||
ArgumentNotNull(code, "code");
|
||||
ArgumentNotNull(typeMapper, "typeMapper");
|
||||
ArgumentNotNull(ef, "ef");
|
||||
|
||||
_code = code;
|
||||
_typeMapper = typeMapper;
|
||||
_ef = ef;
|
||||
}
|
||||
|
||||
public string Property(EdmProperty edmProperty)
|
||||
{
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0} {1} {2} {{ {3}get; {4}set; }}",
|
||||
Accessibility.ForProperty(edmProperty),
|
||||
_typeMapper.GetTypeName(edmProperty.TypeUsage),
|
||||
_code.Escape(edmProperty),
|
||||
_code.SpaceAfter(Accessibility.ForGetter(edmProperty)),
|
||||
_code.SpaceAfter(Accessibility.ForSetter(edmProperty)));
|
||||
}
|
||||
|
||||
public string NavigationProperty(NavigationProperty navProp)
|
||||
{
|
||||
var endType = _typeMapper.GetTypeName(navProp.ToEndMember.GetEntityType());
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0} {1} {2} {{ {3}get; {4}set; }}",
|
||||
AccessibilityAndVirtual(Accessibility.ForNavigationProperty(navProp)),
|
||||
navProp.ToEndMember.RelationshipMultiplicity == RelationshipMultiplicity.Many ? ("ICollection<" + endType + ">") : endType,
|
||||
_code.Escape(navProp),
|
||||
_code.SpaceAfter(Accessibility.ForGetter(navProp)),
|
||||
_code.SpaceAfter(Accessibility.ForSetter(navProp)));
|
||||
}
|
||||
|
||||
public string AccessibilityAndVirtual(string accessibility)
|
||||
{
|
||||
return accessibility + (accessibility != "private" ? " virtual" : "");
|
||||
}
|
||||
|
||||
public string EntityClassOpening(EntityType entity)
|
||||
{
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0} {1}partial class {2}{3}",
|
||||
Accessibility.ForType(entity),
|
||||
_code.SpaceAfter(_code.AbstractOption(entity)),
|
||||
_code.Escape(entity),
|
||||
_code.StringBefore(" : ", _typeMapper.GetTypeName(entity.BaseType)));
|
||||
}
|
||||
|
||||
public string EnumOpening(SimpleType enumType)
|
||||
{
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0} enum {1} : {2}",
|
||||
Accessibility.ForType(enumType),
|
||||
_code.Escape(enumType),
|
||||
_code.Escape(_typeMapper.UnderlyingClrType(enumType)));
|
||||
}
|
||||
|
||||
public void WriteFunctionParameters(EdmFunction edmFunction, Action<string, string, string, string> writeParameter)
|
||||
{
|
||||
var parameters = FunctionImportParameter.Create(edmFunction.Parameters, _code, _ef);
|
||||
foreach (var parameter in parameters.Where(p => p.NeedsLocalVariable))
|
||||
{
|
||||
var isNotNull = parameter.IsNullableOfT ? parameter.FunctionParameterName + ".HasValue" : parameter.FunctionParameterName + " != null";
|
||||
var notNullInit = "new ObjectParameter(\"" + parameter.EsqlParameterName + "\", " + parameter.FunctionParameterName + ")";
|
||||
var nullInit = "new ObjectParameter(\"" + parameter.EsqlParameterName + "\", typeof(" + TypeMapper.FixNamespaces(parameter.RawClrTypeName) + "))";
|
||||
writeParameter(parameter.LocalVariableName, isNotNull, notNullInit, nullInit);
|
||||
}
|
||||
}
|
||||
|
||||
public string ComposableFunctionMethod(EdmFunction edmFunction, string modelNamespace)
|
||||
{
|
||||
var parameters = _typeMapper.GetParameters(edmFunction);
|
||||
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0} IQueryable<{1}> {2}({3})",
|
||||
AccessibilityAndVirtual(Accessibility.ForMethod(edmFunction)),
|
||||
_typeMapper.GetTypeName(_typeMapper.GetReturnType(edmFunction), modelNamespace),
|
||||
_code.Escape(edmFunction),
|
||||
string.Join(", ", parameters.Select(p => TypeMapper.FixNamespaces(p.FunctionParameterType) + " " + p.FunctionParameterName).ToArray()));
|
||||
}
|
||||
|
||||
public string ComposableCreateQuery(EdmFunction edmFunction, string modelNamespace)
|
||||
{
|
||||
var parameters = _typeMapper.GetParameters(edmFunction);
|
||||
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"return ((IObjectContextAdapter)this).ObjectContext.CreateQuery<{0}>(\"[{1}].[{2}]({3})\"{4});",
|
||||
_typeMapper.GetTypeName(_typeMapper.GetReturnType(edmFunction), modelNamespace),
|
||||
edmFunction.NamespaceName,
|
||||
edmFunction.Name,
|
||||
string.Join(", ", parameters.Select(p => "@" + p.EsqlParameterName).ToArray()),
|
||||
_code.StringBefore(", ", string.Join(", ", parameters.Select(p => p.ExecuteParameterName).ToArray())));
|
||||
}
|
||||
|
||||
public string FunctionMethod(EdmFunction edmFunction, string modelNamespace, bool includeMergeOption)
|
||||
{
|
||||
var parameters = _typeMapper.GetParameters(edmFunction);
|
||||
var returnType = _typeMapper.GetReturnType(edmFunction);
|
||||
|
||||
var paramList = String.Join(", ", parameters.Select(p => TypeMapper.FixNamespaces(p.FunctionParameterType) + " " + p.FunctionParameterName).ToArray());
|
||||
if (includeMergeOption)
|
||||
{
|
||||
paramList = _code.StringAfter(paramList, ", ") + "MergeOption mergeOption";
|
||||
}
|
||||
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0} {1} {2}({3})",
|
||||
AccessibilityAndVirtual(Accessibility.ForMethod(edmFunction)),
|
||||
returnType == null ? "int" : "ObjectResult<" + _typeMapper.GetTypeName(returnType, modelNamespace) + ">",
|
||||
_code.Escape(edmFunction),
|
||||
paramList);
|
||||
}
|
||||
|
||||
public string ExecuteFunction(EdmFunction edmFunction, string modelNamespace, bool includeMergeOption)
|
||||
{
|
||||
var parameters = _typeMapper.GetParameters(edmFunction);
|
||||
var returnType = _typeMapper.GetReturnType(edmFunction);
|
||||
|
||||
var callParams = _code.StringBefore(", ", String.Join(", ", parameters.Select(p => p.ExecuteParameterName).ToArray()));
|
||||
if (includeMergeOption)
|
||||
{
|
||||
callParams = ", mergeOption" + callParams;
|
||||
}
|
||||
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"return ((IObjectContextAdapter)this).ObjectContext.ExecuteFunction{0}(\"{1}\"{2});",
|
||||
returnType == null ? "" : "<" + _typeMapper.GetTypeName(returnType, modelNamespace) + ">",
|
||||
edmFunction.Name,
|
||||
callParams);
|
||||
}
|
||||
|
||||
public string DbSet(EntitySet entitySet)
|
||||
{
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0} virtual DbSet<{1}> {2} {{ get; set; }}",
|
||||
Accessibility.ForReadOnlyProperty(entitySet),
|
||||
_typeMapper.GetTypeName(entitySet.ElementType),
|
||||
_code.Escape(entitySet));
|
||||
}
|
||||
|
||||
public string DbSetInitializer(EntitySet entitySet)
|
||||
{
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0} = Set<{1}>();",
|
||||
_code.Escape(entitySet),
|
||||
_typeMapper.GetTypeName(entitySet.ElementType));
|
||||
}
|
||||
|
||||
public string UsingDirectives(bool inHeader, bool includeCollections = true)
|
||||
{
|
||||
return inHeader == string.IsNullOrEmpty(_code.VsNamespaceSuggestion())
|
||||
? string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0}using System;{1}" +
|
||||
"{2}",
|
||||
inHeader ? Environment.NewLine : "",
|
||||
includeCollections ? (Environment.NewLine + "using System.Collections.Generic;") : "",
|
||||
inHeader ? "" : Environment.NewLine)
|
||||
: "";
|
||||
}
|
||||
}
|
||||
|
||||
public class TypeMapper
|
||||
{
|
||||
private const string ExternalTypeNameAttributeName = @"http://schemas.microsoft.com/ado/2006/04/codegeneration:ExternalTypeName";
|
||||
|
||||
private readonly System.Collections.IList _errors;
|
||||
private readonly CodeGenerationTools _code;
|
||||
private readonly MetadataTools _ef;
|
||||
|
||||
public static string FixNamespaces(string typeName)
|
||||
{
|
||||
return typeName.Replace("System.Data.Spatial.", "System.Data.Entity.Spatial.");
|
||||
}
|
||||
|
||||
public TypeMapper(CodeGenerationTools code, MetadataTools ef, System.Collections.IList errors)
|
||||
{
|
||||
ArgumentNotNull(code, "code");
|
||||
ArgumentNotNull(ef, "ef");
|
||||
ArgumentNotNull(errors, "errors");
|
||||
|
||||
_code = code;
|
||||
_ef = ef;
|
||||
_errors = errors;
|
||||
}
|
||||
|
||||
public string GetTypeName(TypeUsage typeUsage)
|
||||
{
|
||||
return typeUsage == null ? null : GetTypeName(typeUsage.EdmType, _ef.IsNullable(typeUsage), modelNamespace: null);
|
||||
}
|
||||
|
||||
public string GetTypeName(EdmType edmType)
|
||||
{
|
||||
return GetTypeName(edmType, isNullable: null, modelNamespace: null);
|
||||
}
|
||||
|
||||
public string GetTypeName(TypeUsage typeUsage, string modelNamespace)
|
||||
{
|
||||
return typeUsage == null ? null : GetTypeName(typeUsage.EdmType, _ef.IsNullable(typeUsage), modelNamespace);
|
||||
}
|
||||
|
||||
public string GetTypeName(EdmType edmType, string modelNamespace)
|
||||
{
|
||||
return GetTypeName(edmType, isNullable: null, modelNamespace: modelNamespace);
|
||||
}
|
||||
|
||||
public string GetTypeName(EdmType edmType, bool? isNullable, string modelNamespace)
|
||||
{
|
||||
if (edmType == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
var collectionType = edmType as CollectionType;
|
||||
if (collectionType != null)
|
||||
{
|
||||
return String.Format(CultureInfo.InvariantCulture, "ICollection<{0}>", GetTypeName(collectionType.TypeUsage, modelNamespace));
|
||||
}
|
||||
|
||||
var typeName = _code.Escape(edmType.MetadataProperties
|
||||
.Where(p => p.Name == ExternalTypeNameAttributeName)
|
||||
.Select(p => (string)p.Value)
|
||||
.FirstOrDefault())
|
||||
?? (modelNamespace != null && edmType.NamespaceName != modelNamespace ?
|
||||
_code.CreateFullName(_code.EscapeNamespace(edmType.NamespaceName), _code.Escape(edmType)) :
|
||||
_code.Escape(edmType));
|
||||
|
||||
if (edmType is StructuralType)
|
||||
{
|
||||
return typeName;
|
||||
}
|
||||
|
||||
if (edmType is SimpleType)
|
||||
{
|
||||
var clrType = UnderlyingClrType(edmType);
|
||||
if (!IsEnumType(edmType))
|
||||
{
|
||||
typeName = _code.Escape(clrType);
|
||||
}
|
||||
|
||||
typeName = FixNamespaces(typeName);
|
||||
|
||||
return clrType.IsValueType && isNullable == true ?
|
||||
String.Format(CultureInfo.InvariantCulture, "Nullable<{0}>", typeName) :
|
||||
typeName;
|
||||
}
|
||||
|
||||
throw new ArgumentException("edmType");
|
||||
}
|
||||
|
||||
public Type UnderlyingClrType(EdmType edmType)
|
||||
{
|
||||
ArgumentNotNull(edmType, "edmType");
|
||||
|
||||
var primitiveType = edmType as PrimitiveType;
|
||||
if (primitiveType != null)
|
||||
{
|
||||
return primitiveType.ClrEquivalentType;
|
||||
}
|
||||
|
||||
if (IsEnumType(edmType))
|
||||
{
|
||||
return GetEnumUnderlyingType(edmType).ClrEquivalentType;
|
||||
}
|
||||
|
||||
return typeof(object);
|
||||
}
|
||||
|
||||
public object GetEnumMemberValue(MetadataItem enumMember)
|
||||
{
|
||||
ArgumentNotNull(enumMember, "enumMember");
|
||||
|
||||
var valueProperty = enumMember.GetType().GetProperty("Value");
|
||||
return valueProperty == null ? null : valueProperty.GetValue(enumMember, null);
|
||||
}
|
||||
|
||||
public string GetEnumMemberName(MetadataItem enumMember)
|
||||
{
|
||||
ArgumentNotNull(enumMember, "enumMember");
|
||||
|
||||
var nameProperty = enumMember.GetType().GetProperty("Name");
|
||||
return nameProperty == null ? null : (string)nameProperty.GetValue(enumMember, null);
|
||||
}
|
||||
|
||||
public System.Collections.IEnumerable GetEnumMembers(EdmType enumType)
|
||||
{
|
||||
ArgumentNotNull(enumType, "enumType");
|
||||
|
||||
var membersProperty = enumType.GetType().GetProperty("Members");
|
||||
return membersProperty != null
|
||||
? (System.Collections.IEnumerable)membersProperty.GetValue(enumType, null)
|
||||
: Enumerable.Empty<MetadataItem>();
|
||||
}
|
||||
|
||||
public bool EnumIsFlags(EdmType enumType)
|
||||
{
|
||||
ArgumentNotNull(enumType, "enumType");
|
||||
|
||||
var isFlagsProperty = enumType.GetType().GetProperty("IsFlags");
|
||||
return isFlagsProperty != null && (bool)isFlagsProperty.GetValue(enumType, null);
|
||||
}
|
||||
|
||||
public bool IsEnumType(GlobalItem edmType)
|
||||
{
|
||||
ArgumentNotNull(edmType, "edmType");
|
||||
|
||||
return edmType.GetType().Name == "EnumType";
|
||||
}
|
||||
|
||||
public PrimitiveType GetEnumUnderlyingType(EdmType enumType)
|
||||
{
|
||||
ArgumentNotNull(enumType, "enumType");
|
||||
|
||||
return (PrimitiveType)enumType.GetType().GetProperty("UnderlyingType").GetValue(enumType, null);
|
||||
}
|
||||
|
||||
public string CreateLiteral(object value)
|
||||
{
|
||||
if (value == null || value.GetType() != typeof(TimeSpan))
|
||||
{
|
||||
return _code.CreateLiteral(value);
|
||||
}
|
||||
|
||||
return string.Format(CultureInfo.InvariantCulture, "new TimeSpan({0})", ((TimeSpan)value).Ticks);
|
||||
}
|
||||
|
||||
public bool VerifyCaseInsensitiveTypeUniqueness(IEnumerable<string> types, string sourceFile)
|
||||
{
|
||||
ArgumentNotNull(types, "types");
|
||||
ArgumentNotNull(sourceFile, "sourceFile");
|
||||
|
||||
var hash = new HashSet<string>(StringComparer.InvariantCultureIgnoreCase);
|
||||
if (types.Any(item => !hash.Add(item)))
|
||||
{
|
||||
_errors.Add(
|
||||
new CompilerError(sourceFile, -1, -1, "6023",
|
||||
String.Format(CultureInfo.CurrentCulture, CodeGenerationTools.GetResourceString("Template_CaseInsensitiveTypeConflict"))));
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
public IEnumerable<SimpleType> GetEnumItemsToGenerate(IEnumerable<GlobalItem> itemCollection)
|
||||
{
|
||||
return GetItemsToGenerate<SimpleType>(itemCollection)
|
||||
.Where(e => IsEnumType(e));
|
||||
}
|
||||
|
||||
public IEnumerable<T> GetItemsToGenerate<T>(IEnumerable<GlobalItem> itemCollection) where T: EdmType
|
||||
{
|
||||
return itemCollection
|
||||
.OfType<T>()
|
||||
.Where(i => !i.MetadataProperties.Any(p => p.Name == ExternalTypeNameAttributeName))
|
||||
.OrderBy(i => i.Name);
|
||||
}
|
||||
|
||||
public IEnumerable<string> GetAllGlobalItems(IEnumerable<GlobalItem> itemCollection)
|
||||
{
|
||||
return itemCollection
|
||||
.Where(i => i is EntityType || i is ComplexType || i is EntityContainer || IsEnumType(i))
|
||||
.Select(g => GetGlobalItemName(g));
|
||||
}
|
||||
|
||||
public string GetGlobalItemName(GlobalItem item)
|
||||
{
|
||||
if (item is EdmType)
|
||||
{
|
||||
return ((EdmType)item).Name;
|
||||
}
|
||||
else
|
||||
{
|
||||
return ((EntityContainer)item).Name;
|
||||
}
|
||||
}
|
||||
|
||||
public IEnumerable<EdmProperty> GetSimpleProperties(EntityType type)
|
||||
{
|
||||
return type.Properties.Where(p => p.TypeUsage.EdmType is SimpleType && p.DeclaringType == type);
|
||||
}
|
||||
|
||||
public IEnumerable<EdmProperty> GetSimpleProperties(ComplexType type)
|
||||
{
|
||||
return type.Properties.Where(p => p.TypeUsage.EdmType is SimpleType && p.DeclaringType == type);
|
||||
}
|
||||
|
||||
public IEnumerable<EdmProperty> GetComplexProperties(EntityType type)
|
||||
{
|
||||
return type.Properties.Where(p => p.TypeUsage.EdmType is ComplexType && p.DeclaringType == type);
|
||||
}
|
||||
|
||||
public IEnumerable<EdmProperty> GetComplexProperties(ComplexType type)
|
||||
{
|
||||
return type.Properties.Where(p => p.TypeUsage.EdmType is ComplexType && p.DeclaringType == type);
|
||||
}
|
||||
|
||||
public IEnumerable<EdmProperty> GetPropertiesWithDefaultValues(EntityType type)
|
||||
{
|
||||
return type.Properties.Where(p => p.TypeUsage.EdmType is SimpleType && p.DeclaringType == type && p.DefaultValue != null);
|
||||
}
|
||||
|
||||
public IEnumerable<EdmProperty> GetPropertiesWithDefaultValues(ComplexType type)
|
||||
{
|
||||
return type.Properties.Where(p => p.TypeUsage.EdmType is SimpleType && p.DeclaringType == type && p.DefaultValue != null);
|
||||
}
|
||||
|
||||
public IEnumerable<NavigationProperty> GetNavigationProperties(EntityType type)
|
||||
{
|
||||
return type.NavigationProperties.Where(np => np.DeclaringType == type);
|
||||
}
|
||||
|
||||
public IEnumerable<NavigationProperty> GetCollectionNavigationProperties(EntityType type)
|
||||
{
|
||||
return type.NavigationProperties.Where(np => np.DeclaringType == type && np.ToEndMember.RelationshipMultiplicity == RelationshipMultiplicity.Many);
|
||||
}
|
||||
|
||||
public FunctionParameter GetReturnParameter(EdmFunction edmFunction)
|
||||
{
|
||||
ArgumentNotNull(edmFunction, "edmFunction");
|
||||
|
||||
var returnParamsProperty = edmFunction.GetType().GetProperty("ReturnParameters");
|
||||
return returnParamsProperty == null
|
||||
? edmFunction.ReturnParameter
|
||||
: ((IEnumerable<FunctionParameter>)returnParamsProperty.GetValue(edmFunction, null)).FirstOrDefault();
|
||||
}
|
||||
|
||||
public bool IsComposable(EdmFunction edmFunction)
|
||||
{
|
||||
ArgumentNotNull(edmFunction, "edmFunction");
|
||||
|
||||
var isComposableProperty = edmFunction.GetType().GetProperty("IsComposableAttribute");
|
||||
return isComposableProperty != null && (bool)isComposableProperty.GetValue(edmFunction, null);
|
||||
}
|
||||
|
||||
public IEnumerable<FunctionImportParameter> GetParameters(EdmFunction edmFunction)
|
||||
{
|
||||
return FunctionImportParameter.Create(edmFunction.Parameters, _code, _ef);
|
||||
}
|
||||
|
||||
public TypeUsage GetReturnType(EdmFunction edmFunction)
|
||||
{
|
||||
var returnParam = GetReturnParameter(edmFunction);
|
||||
return returnParam == null ? null : _ef.GetElementType(returnParam.TypeUsage);
|
||||
}
|
||||
|
||||
public bool GenerateMergeOptionFunction(EdmFunction edmFunction, bool includeMergeOption)
|
||||
{
|
||||
var returnType = GetReturnType(edmFunction);
|
||||
return !includeMergeOption && returnType != null && returnType.EdmType.BuiltInTypeKind == BuiltInTypeKind.EntityType;
|
||||
}
|
||||
}
|
||||
|
||||
public static void ArgumentNotNull<T>(T arg, string name) where T : class
|
||||
{
|
||||
if (arg == null)
|
||||
{
|
||||
throw new ArgumentNullException(name);
|
||||
}
|
||||
}
|
||||
#>
|
||||
Generated
+10
@@ -0,0 +1,10 @@
|
||||
// 为模型“C:\Users\24018\source\repos\Audit_APP\Models\SQL_BD.edmx”启用了 T4 代码生成。
|
||||
// 要启用旧代码生成功能,请将“代码生成策略”设计器属性的值
|
||||
// 更改为“旧的 ObjectContext”。当在设计器中打开该模型时,此属性会出现在
|
||||
// “属性”窗口中。
|
||||
|
||||
// 如果没有生成任何上下文和实体类,可能是因为您创建了空模型但是
|
||||
// 尚未选择要使用的实体框架版本。要为您的模型生成一个上下文类和实体
|
||||
// 类,请在设计器中打开该模型,右键单击设计器图面,然后
|
||||
// 选择“从数据库更新模型...”、“从模型生成数据库...”或“添加代码生成
|
||||
// 项...”。
|
||||
@@ -0,0 +1,9 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
+5268
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,77 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<edmx:Edmx Version="3.0" xmlns:edmx="http://schemas.microsoft.com/ado/2009/11/edmx">
|
||||
<!-- EF Designer content (DO NOT EDIT MANUALLY BELOW HERE) -->
|
||||
<edmx:Designer xmlns="http://schemas.microsoft.com/ado/2009/11/edmx">
|
||||
<!-- Diagram content (shape and connector positions) -->
|
||||
<edmx:Diagrams>
|
||||
<Diagram DiagramId="ba808e87d99646bab9fba0afc7823f2a" Name="Diagram1">
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Alarms" Width="1.5" PointX="5.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Customize" Width="1.5" PointX="0.75" PointY="5.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Delays" Width="1.5" PointX="2.75" PointY="5.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotHead" Width="1.5" PointX="5.75" PointY="4.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotHistories" Width="1.5" PointX="7.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Dyelots" Width="1.5" PointX="7.75" PointY="3.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotsByShift" Width="1.5" PointX="9.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Machines" Width="1.5" PointX="0.75" PointY="9.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.MachineState" Width="1.5" PointX="2.75" PointY="9.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.ProgramGroups" Width="1.5" PointX="0.75" PointY="1" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Programs" Width="1.5" PointX="3" PointY="1.5" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.ProgramsUsed" Width="1.5" PointX="9.75" PointY="4.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.record" Width="1.5" PointX="9.75" PointY="8.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.SchedulingLog" Width="1.5" PointX="11.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Steps" Width="1.5" PointX="11.75" PointY="4.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.StepVisits" Width="1.5" PointX="11.75" PointY="9.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Stoppages" Width="1.5" PointX="13.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Users" Width="1.5" PointX="13.75" PointY="4.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.AuxDslvQueue" Width="1.5" PointX="13.75" PointY="7.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.AuxDslvQueueHistory" Width="1.5" PointX="13.75" PointY="11.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.BucketInfo" Width="1.5" PointX="15.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.BucketShelf" Width="1.5" PointX="2.75" PointY="15.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.BucketShelfHistory" Width="1.5" PointX="15.75" PointY="3.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.BucketShelfQueue" Width="1.5" PointX="4.75" PointY="15.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.BucketShelfQueueHistory" Width="1.5" PointX="15.75" PointY="8.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.CleanDevice" Width="1.5" PointX="15.75" PointY="12.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DispenserEvent" Width="1.5" PointX="13.75" PointY="15.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DispenserLifeStatus" Width="1.5" PointX="15.75" PointY="15.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Dispensers" Width="1.5" PointX="9.75" PointY="16.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DispenserUtilization" Width="1.5" PointX="17.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotBuckets" Width="1.5" PointX="17.75" PointY="3.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotBucketsHistory" Width="1.5" PointX="6.75" PointY="17.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotBucketSummary" Width="1.5" PointX="17.75" PointY="7.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotDetail" Width="1.5" PointX="17.75" PointY="10.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotDslvQueue" Width="1.5" PointX="17.75" PointY="16.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotDslvQueueHistory" Width="1.5" PointX="19.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotsBatch" Width="1.5" PointX="19.75" PointY="4.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotsBulkedRecipe" Width="1.5" PointX="19.75" PointY="10.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotsBulkedRecipeHistory" Width="1.5" PointX="2.75" PointY="20.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotsHistory" Width="1.5" PointX="11.75" PointY="20.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotsInAuto" Width="1.5" PointX="13.75" PointY="20.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotsInAutoHistory" Width="1.5" PointX="15.75" PointY="20.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.EventList" Width="1.5" PointX="21.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.LA571Tanks" Width="1.5" PointX="21.75" PointY="3.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.LabDyeDslvQueue" Width="1.5" PointX="4.75" PointY="21.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.LabDyeDslvQueueHistory" Width="1.5" PointX="21.75" PointY="6.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.MachinesHistory" Width="1.5" PointX="6.75" PointY="21.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.MachineStateHistory" Width="1.5" PointX="8.75" PointY="21.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.ManualWeightQueue" Width="1.5" PointX="21.75" PointY="10.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.ManualWeightQueueHistory" Width="1.5" PointX="21.75" PointY="14.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.PartsStatus" Width="1.5" PointX="21.75" PointY="18.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.PartsStatusHistory" Width="1.5" PointX="23.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.PipeFill" Width="1.5" PointX="23.75" PointY="5.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.PipeHistory" Width="1.5" PointX="23.75" PointY="9.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Pipes" Width="1.5" PointX="23.75" PointY="13.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.RecipeDeduct" Width="1.5" PointX="23.75" PointY="18.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.RecipeDeductHistory" Width="1.5" PointX="21.75" PointY="23.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.RFIDRecordQueue" Width="1.5" PointX="23.75" PointY="22.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.RFIDRecordQueueHistory" Width="1.5" PointX="13.75" PointY="24.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.SampleDyeDslvQueue" Width="1.5" PointX="15.75" PointY="24.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.SampleDyeDslvQueueHistory" Width="1.5" PointX="17.75" PointY="24.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Shelf" Width="1.5" PointX="25.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.TagShelf" Width="1.5" PointX="25.75" PointY="3.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.UserGroup" Width="1.5" PointX="25.75" PointY="7.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.WaitChemical" Width="1.5" PointX="25.75" PointY="10.75" IsExpanded="true" />
|
||||
<AssociationConnector Association="BatchDyeingCentralModel.FKProgramGroups" ManuallyRouted="false" />
|
||||
</Diagram>
|
||||
</edmx:Diagrams>
|
||||
</edmx:Designer>
|
||||
</edmx:Edmx>
|
||||
@@ -0,0 +1,733 @@
|
||||
<#@ template language="C#" debug="false" hostspecific="true"#>
|
||||
<#@ include file="EF6.Utility.CS.ttinclude"#><#@
|
||||
output extension=".cs"#><#
|
||||
|
||||
const string inputFile = @"SQL_BD.edmx";
|
||||
var textTransform = DynamicTextTransformation.Create(this);
|
||||
var code = new CodeGenerationTools(this);
|
||||
var ef = new MetadataTools(this);
|
||||
var typeMapper = new TypeMapper(code, ef, textTransform.Errors);
|
||||
var fileManager = EntityFrameworkTemplateFileManager.Create(this);
|
||||
var itemCollection = new EdmMetadataLoader(textTransform.Host, textTransform.Errors).CreateEdmItemCollection(inputFile);
|
||||
var codeStringGenerator = new CodeStringGenerator(code, typeMapper, ef);
|
||||
|
||||
if (!typeMapper.VerifyCaseInsensitiveTypeUniqueness(typeMapper.GetAllGlobalItems(itemCollection), inputFile))
|
||||
{
|
||||
return string.Empty;
|
||||
}
|
||||
|
||||
WriteHeader(codeStringGenerator, fileManager);
|
||||
|
||||
foreach (var entity in typeMapper.GetItemsToGenerate<EntityType>(itemCollection))
|
||||
{
|
||||
fileManager.StartNewFile(entity.Name + ".cs");
|
||||
BeginNamespace(code);
|
||||
#>
|
||||
<#=codeStringGenerator.UsingDirectives(inHeader: false)#>
|
||||
<#=codeStringGenerator.EntityClassOpening(entity)#>
|
||||
{
|
||||
<#
|
||||
var propertiesWithDefaultValues = typeMapper.GetPropertiesWithDefaultValues(entity);
|
||||
var collectionNavigationProperties = typeMapper.GetCollectionNavigationProperties(entity);
|
||||
var complexProperties = typeMapper.GetComplexProperties(entity);
|
||||
|
||||
if (propertiesWithDefaultValues.Any() || collectionNavigationProperties.Any() || complexProperties.Any())
|
||||
{
|
||||
#>
|
||||
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors")]
|
||||
public <#=code.Escape(entity)#>()
|
||||
{
|
||||
<#
|
||||
foreach (var edmProperty in propertiesWithDefaultValues)
|
||||
{
|
||||
#>
|
||||
this.<#=code.Escape(edmProperty)#> = <#=typeMapper.CreateLiteral(edmProperty.DefaultValue)#>;
|
||||
<#
|
||||
}
|
||||
|
||||
foreach (var navigationProperty in collectionNavigationProperties)
|
||||
{
|
||||
#>
|
||||
this.<#=code.Escape(navigationProperty)#> = new HashSet<<#=typeMapper.GetTypeName(navigationProperty.ToEndMember.GetEntityType())#>>();
|
||||
<#
|
||||
}
|
||||
|
||||
foreach (var complexProperty in complexProperties)
|
||||
{
|
||||
#>
|
||||
this.<#=code.Escape(complexProperty)#> = new <#=typeMapper.GetTypeName(complexProperty.TypeUsage)#>();
|
||||
<#
|
||||
}
|
||||
#>
|
||||
}
|
||||
|
||||
<#
|
||||
}
|
||||
|
||||
var simpleProperties = typeMapper.GetSimpleProperties(entity);
|
||||
if (simpleProperties.Any())
|
||||
{
|
||||
foreach (var edmProperty in simpleProperties)
|
||||
{
|
||||
#>
|
||||
<#=codeStringGenerator.Property(edmProperty)#>
|
||||
<#
|
||||
}
|
||||
}
|
||||
|
||||
if (complexProperties.Any())
|
||||
{
|
||||
#>
|
||||
|
||||
<#
|
||||
foreach(var complexProperty in complexProperties)
|
||||
{
|
||||
#>
|
||||
<#=codeStringGenerator.Property(complexProperty)#>
|
||||
<#
|
||||
}
|
||||
}
|
||||
|
||||
var navigationProperties = typeMapper.GetNavigationProperties(entity);
|
||||
if (navigationProperties.Any())
|
||||
{
|
||||
#>
|
||||
|
||||
<#
|
||||
foreach (var navigationProperty in navigationProperties)
|
||||
{
|
||||
if (navigationProperty.ToEndMember.RelationshipMultiplicity == RelationshipMultiplicity.Many)
|
||||
{
|
||||
#>
|
||||
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
|
||||
<#
|
||||
}
|
||||
#>
|
||||
<#=codeStringGenerator.NavigationProperty(navigationProperty)#>
|
||||
<#
|
||||
}
|
||||
}
|
||||
#>
|
||||
}
|
||||
<#
|
||||
EndNamespace(code);
|
||||
}
|
||||
|
||||
foreach (var complex in typeMapper.GetItemsToGenerate<ComplexType>(itemCollection))
|
||||
{
|
||||
fileManager.StartNewFile(complex.Name + ".cs");
|
||||
BeginNamespace(code);
|
||||
#>
|
||||
<#=codeStringGenerator.UsingDirectives(inHeader: false, includeCollections: false)#>
|
||||
<#=Accessibility.ForType(complex)#> partial class <#=code.Escape(complex)#>
|
||||
{
|
||||
<#
|
||||
var complexProperties = typeMapper.GetComplexProperties(complex);
|
||||
var propertiesWithDefaultValues = typeMapper.GetPropertiesWithDefaultValues(complex);
|
||||
|
||||
if (propertiesWithDefaultValues.Any() || complexProperties.Any())
|
||||
{
|
||||
#>
|
||||
public <#=code.Escape(complex)#>()
|
||||
{
|
||||
<#
|
||||
foreach (var edmProperty in propertiesWithDefaultValues)
|
||||
{
|
||||
#>
|
||||
this.<#=code.Escape(edmProperty)#> = <#=typeMapper.CreateLiteral(edmProperty.DefaultValue)#>;
|
||||
<#
|
||||
}
|
||||
|
||||
foreach (var complexProperty in complexProperties)
|
||||
{
|
||||
#>
|
||||
this.<#=code.Escape(complexProperty)#> = new <#=typeMapper.GetTypeName(complexProperty.TypeUsage)#>();
|
||||
<#
|
||||
}
|
||||
#>
|
||||
}
|
||||
|
||||
<#
|
||||
}
|
||||
|
||||
var simpleProperties = typeMapper.GetSimpleProperties(complex);
|
||||
if (simpleProperties.Any())
|
||||
{
|
||||
foreach(var edmProperty in simpleProperties)
|
||||
{
|
||||
#>
|
||||
<#=codeStringGenerator.Property(edmProperty)#>
|
||||
<#
|
||||
}
|
||||
}
|
||||
|
||||
if (complexProperties.Any())
|
||||
{
|
||||
#>
|
||||
|
||||
<#
|
||||
foreach(var edmProperty in complexProperties)
|
||||
{
|
||||
#>
|
||||
<#=codeStringGenerator.Property(edmProperty)#>
|
||||
<#
|
||||
}
|
||||
}
|
||||
#>
|
||||
}
|
||||
<#
|
||||
EndNamespace(code);
|
||||
}
|
||||
|
||||
foreach (var enumType in typeMapper.GetEnumItemsToGenerate(itemCollection))
|
||||
{
|
||||
fileManager.StartNewFile(enumType.Name + ".cs");
|
||||
BeginNamespace(code);
|
||||
#>
|
||||
<#=codeStringGenerator.UsingDirectives(inHeader: false, includeCollections: false)#>
|
||||
<#
|
||||
if (typeMapper.EnumIsFlags(enumType))
|
||||
{
|
||||
#>
|
||||
[Flags]
|
||||
<#
|
||||
}
|
||||
#>
|
||||
<#=codeStringGenerator.EnumOpening(enumType)#>
|
||||
{
|
||||
<#
|
||||
var foundOne = false;
|
||||
|
||||
foreach (MetadataItem member in typeMapper.GetEnumMembers(enumType))
|
||||
{
|
||||
foundOne = true;
|
||||
#>
|
||||
<#=code.Escape(typeMapper.GetEnumMemberName(member))#> = <#=typeMapper.GetEnumMemberValue(member)#>,
|
||||
<#
|
||||
}
|
||||
|
||||
if (foundOne)
|
||||
{
|
||||
this.GenerationEnvironment.Remove(this.GenerationEnvironment.Length - 3, 1);
|
||||
}
|
||||
#>
|
||||
}
|
||||
<#
|
||||
EndNamespace(code);
|
||||
}
|
||||
|
||||
fileManager.Process();
|
||||
|
||||
#>
|
||||
<#+
|
||||
|
||||
public void WriteHeader(CodeStringGenerator codeStringGenerator, EntityFrameworkTemplateFileManager fileManager)
|
||||
{
|
||||
fileManager.StartHeader();
|
||||
#>
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// <#=CodeGenerationTools.GetResourceString("Template_GeneratedCodeCommentLine1")#>
|
||||
//
|
||||
// <#=CodeGenerationTools.GetResourceString("Template_GeneratedCodeCommentLine2")#>
|
||||
// <#=CodeGenerationTools.GetResourceString("Template_GeneratedCodeCommentLine3")#>
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
<#=codeStringGenerator.UsingDirectives(inHeader: true)#>
|
||||
<#+
|
||||
fileManager.EndBlock();
|
||||
}
|
||||
|
||||
public void BeginNamespace(CodeGenerationTools code)
|
||||
{
|
||||
var codeNamespace = code.VsNamespaceSuggestion();
|
||||
if (!String.IsNullOrEmpty(codeNamespace))
|
||||
{
|
||||
#>
|
||||
namespace <#=code.EscapeNamespace(codeNamespace)#>
|
||||
{
|
||||
<#+
|
||||
PushIndent(" ");
|
||||
}
|
||||
}
|
||||
|
||||
public void EndNamespace(CodeGenerationTools code)
|
||||
{
|
||||
if (!String.IsNullOrEmpty(code.VsNamespaceSuggestion()))
|
||||
{
|
||||
PopIndent();
|
||||
#>
|
||||
}
|
||||
<#+
|
||||
}
|
||||
}
|
||||
|
||||
public const string TemplateId = "CSharp_DbContext_Types_EF6";
|
||||
|
||||
public class CodeStringGenerator
|
||||
{
|
||||
private readonly CodeGenerationTools _code;
|
||||
private readonly TypeMapper _typeMapper;
|
||||
private readonly MetadataTools _ef;
|
||||
|
||||
public CodeStringGenerator(CodeGenerationTools code, TypeMapper typeMapper, MetadataTools ef)
|
||||
{
|
||||
ArgumentNotNull(code, "code");
|
||||
ArgumentNotNull(typeMapper, "typeMapper");
|
||||
ArgumentNotNull(ef, "ef");
|
||||
|
||||
_code = code;
|
||||
_typeMapper = typeMapper;
|
||||
_ef = ef;
|
||||
}
|
||||
|
||||
public string Property(EdmProperty edmProperty)
|
||||
{
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0} {1} {2} {{ {3}get; {4}set; }}",
|
||||
Accessibility.ForProperty(edmProperty),
|
||||
_typeMapper.GetTypeName(edmProperty.TypeUsage),
|
||||
_code.Escape(edmProperty),
|
||||
_code.SpaceAfter(Accessibility.ForGetter(edmProperty)),
|
||||
_code.SpaceAfter(Accessibility.ForSetter(edmProperty)));
|
||||
}
|
||||
|
||||
public string NavigationProperty(NavigationProperty navProp)
|
||||
{
|
||||
var endType = _typeMapper.GetTypeName(navProp.ToEndMember.GetEntityType());
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0} {1} {2} {{ {3}get; {4}set; }}",
|
||||
AccessibilityAndVirtual(Accessibility.ForNavigationProperty(navProp)),
|
||||
navProp.ToEndMember.RelationshipMultiplicity == RelationshipMultiplicity.Many ? ("ICollection<" + endType + ">") : endType,
|
||||
_code.Escape(navProp),
|
||||
_code.SpaceAfter(Accessibility.ForGetter(navProp)),
|
||||
_code.SpaceAfter(Accessibility.ForSetter(navProp)));
|
||||
}
|
||||
|
||||
public string AccessibilityAndVirtual(string accessibility)
|
||||
{
|
||||
return accessibility + (accessibility != "private" ? " virtual" : "");
|
||||
}
|
||||
|
||||
public string EntityClassOpening(EntityType entity)
|
||||
{
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0} {1}partial class {2}{3}",
|
||||
Accessibility.ForType(entity),
|
||||
_code.SpaceAfter(_code.AbstractOption(entity)),
|
||||
_code.Escape(entity),
|
||||
_code.StringBefore(" : ", _typeMapper.GetTypeName(entity.BaseType)));
|
||||
}
|
||||
|
||||
public string EnumOpening(SimpleType enumType)
|
||||
{
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0} enum {1} : {2}",
|
||||
Accessibility.ForType(enumType),
|
||||
_code.Escape(enumType),
|
||||
_code.Escape(_typeMapper.UnderlyingClrType(enumType)));
|
||||
}
|
||||
|
||||
public void WriteFunctionParameters(EdmFunction edmFunction, Action<string, string, string, string> writeParameter)
|
||||
{
|
||||
var parameters = FunctionImportParameter.Create(edmFunction.Parameters, _code, _ef);
|
||||
foreach (var parameter in parameters.Where(p => p.NeedsLocalVariable))
|
||||
{
|
||||
var isNotNull = parameter.IsNullableOfT ? parameter.FunctionParameterName + ".HasValue" : parameter.FunctionParameterName + " != null";
|
||||
var notNullInit = "new ObjectParameter(\"" + parameter.EsqlParameterName + "\", " + parameter.FunctionParameterName + ")";
|
||||
var nullInit = "new ObjectParameter(\"" + parameter.EsqlParameterName + "\", typeof(" + TypeMapper.FixNamespaces(parameter.RawClrTypeName) + "))";
|
||||
writeParameter(parameter.LocalVariableName, isNotNull, notNullInit, nullInit);
|
||||
}
|
||||
}
|
||||
|
||||
public string ComposableFunctionMethod(EdmFunction edmFunction, string modelNamespace)
|
||||
{
|
||||
var parameters = _typeMapper.GetParameters(edmFunction);
|
||||
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0} IQueryable<{1}> {2}({3})",
|
||||
AccessibilityAndVirtual(Accessibility.ForMethod(edmFunction)),
|
||||
_typeMapper.GetTypeName(_typeMapper.GetReturnType(edmFunction), modelNamespace),
|
||||
_code.Escape(edmFunction),
|
||||
string.Join(", ", parameters.Select(p => TypeMapper.FixNamespaces(p.FunctionParameterType) + " " + p.FunctionParameterName).ToArray()));
|
||||
}
|
||||
|
||||
public string ComposableCreateQuery(EdmFunction edmFunction, string modelNamespace)
|
||||
{
|
||||
var parameters = _typeMapper.GetParameters(edmFunction);
|
||||
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"return ((IObjectContextAdapter)this).ObjectContext.CreateQuery<{0}>(\"[{1}].[{2}]({3})\"{4});",
|
||||
_typeMapper.GetTypeName(_typeMapper.GetReturnType(edmFunction), modelNamespace),
|
||||
edmFunction.NamespaceName,
|
||||
edmFunction.Name,
|
||||
string.Join(", ", parameters.Select(p => "@" + p.EsqlParameterName).ToArray()),
|
||||
_code.StringBefore(", ", string.Join(", ", parameters.Select(p => p.ExecuteParameterName).ToArray())));
|
||||
}
|
||||
|
||||
public string FunctionMethod(EdmFunction edmFunction, string modelNamespace, bool includeMergeOption)
|
||||
{
|
||||
var parameters = _typeMapper.GetParameters(edmFunction);
|
||||
var returnType = _typeMapper.GetReturnType(edmFunction);
|
||||
|
||||
var paramList = String.Join(", ", parameters.Select(p => TypeMapper.FixNamespaces(p.FunctionParameterType) + " " + p.FunctionParameterName).ToArray());
|
||||
if (includeMergeOption)
|
||||
{
|
||||
paramList = _code.StringAfter(paramList, ", ") + "MergeOption mergeOption";
|
||||
}
|
||||
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0} {1} {2}({3})",
|
||||
AccessibilityAndVirtual(Accessibility.ForMethod(edmFunction)),
|
||||
returnType == null ? "int" : "ObjectResult<" + _typeMapper.GetTypeName(returnType, modelNamespace) + ">",
|
||||
_code.Escape(edmFunction),
|
||||
paramList);
|
||||
}
|
||||
|
||||
public string ExecuteFunction(EdmFunction edmFunction, string modelNamespace, bool includeMergeOption)
|
||||
{
|
||||
var parameters = _typeMapper.GetParameters(edmFunction);
|
||||
var returnType = _typeMapper.GetReturnType(edmFunction);
|
||||
|
||||
var callParams = _code.StringBefore(", ", String.Join(", ", parameters.Select(p => p.ExecuteParameterName).ToArray()));
|
||||
if (includeMergeOption)
|
||||
{
|
||||
callParams = ", mergeOption" + callParams;
|
||||
}
|
||||
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"return ((IObjectContextAdapter)this).ObjectContext.ExecuteFunction{0}(\"{1}\"{2});",
|
||||
returnType == null ? "" : "<" + _typeMapper.GetTypeName(returnType, modelNamespace) + ">",
|
||||
edmFunction.Name,
|
||||
callParams);
|
||||
}
|
||||
|
||||
public string DbSet(EntitySet entitySet)
|
||||
{
|
||||
return string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0} virtual DbSet<{1}> {2} {{ get; set; }}",
|
||||
Accessibility.ForReadOnlyProperty(entitySet),
|
||||
_typeMapper.GetTypeName(entitySet.ElementType),
|
||||
_code.Escape(entitySet));
|
||||
}
|
||||
|
||||
public string UsingDirectives(bool inHeader, bool includeCollections = true)
|
||||
{
|
||||
return inHeader == string.IsNullOrEmpty(_code.VsNamespaceSuggestion())
|
||||
? string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0}using System;{1}" +
|
||||
"{2}",
|
||||
inHeader ? Environment.NewLine : "",
|
||||
includeCollections ? (Environment.NewLine + "using System.Collections.Generic;") : "",
|
||||
inHeader ? "" : Environment.NewLine)
|
||||
: "";
|
||||
}
|
||||
}
|
||||
|
||||
public class TypeMapper
|
||||
{
|
||||
private const string ExternalTypeNameAttributeName = @"http://schemas.microsoft.com/ado/2006/04/codegeneration:ExternalTypeName";
|
||||
|
||||
private readonly System.Collections.IList _errors;
|
||||
private readonly CodeGenerationTools _code;
|
||||
private readonly MetadataTools _ef;
|
||||
|
||||
public TypeMapper(CodeGenerationTools code, MetadataTools ef, System.Collections.IList errors)
|
||||
{
|
||||
ArgumentNotNull(code, "code");
|
||||
ArgumentNotNull(ef, "ef");
|
||||
ArgumentNotNull(errors, "errors");
|
||||
|
||||
_code = code;
|
||||
_ef = ef;
|
||||
_errors = errors;
|
||||
}
|
||||
|
||||
public static string FixNamespaces(string typeName)
|
||||
{
|
||||
return typeName.Replace("System.Data.Spatial.", "System.Data.Entity.Spatial.");
|
||||
}
|
||||
|
||||
public string GetTypeName(TypeUsage typeUsage)
|
||||
{
|
||||
return typeUsage == null ? null : GetTypeName(typeUsage.EdmType, _ef.IsNullable(typeUsage), modelNamespace: null);
|
||||
}
|
||||
|
||||
public string GetTypeName(EdmType edmType)
|
||||
{
|
||||
return GetTypeName(edmType, isNullable: null, modelNamespace: null);
|
||||
}
|
||||
|
||||
public string GetTypeName(TypeUsage typeUsage, string modelNamespace)
|
||||
{
|
||||
return typeUsage == null ? null : GetTypeName(typeUsage.EdmType, _ef.IsNullable(typeUsage), modelNamespace);
|
||||
}
|
||||
|
||||
public string GetTypeName(EdmType edmType, string modelNamespace)
|
||||
{
|
||||
return GetTypeName(edmType, isNullable: null, modelNamespace: modelNamespace);
|
||||
}
|
||||
|
||||
public string GetTypeName(EdmType edmType, bool? isNullable, string modelNamespace)
|
||||
{
|
||||
if (edmType == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
var collectionType = edmType as CollectionType;
|
||||
if (collectionType != null)
|
||||
{
|
||||
return String.Format(CultureInfo.InvariantCulture, "ICollection<{0}>", GetTypeName(collectionType.TypeUsage, modelNamespace));
|
||||
}
|
||||
|
||||
var typeName = _code.Escape(edmType.MetadataProperties
|
||||
.Where(p => p.Name == ExternalTypeNameAttributeName)
|
||||
.Select(p => (string)p.Value)
|
||||
.FirstOrDefault())
|
||||
?? (modelNamespace != null && edmType.NamespaceName != modelNamespace ?
|
||||
_code.CreateFullName(_code.EscapeNamespace(edmType.NamespaceName), _code.Escape(edmType)) :
|
||||
_code.Escape(edmType));
|
||||
|
||||
if (edmType is StructuralType)
|
||||
{
|
||||
return typeName;
|
||||
}
|
||||
|
||||
if (edmType is SimpleType)
|
||||
{
|
||||
var clrType = UnderlyingClrType(edmType);
|
||||
if (!IsEnumType(edmType))
|
||||
{
|
||||
typeName = _code.Escape(clrType);
|
||||
}
|
||||
|
||||
typeName = FixNamespaces(typeName);
|
||||
|
||||
return clrType.IsValueType && isNullable == true ?
|
||||
String.Format(CultureInfo.InvariantCulture, "Nullable<{0}>", typeName) :
|
||||
typeName;
|
||||
}
|
||||
|
||||
throw new ArgumentException("edmType");
|
||||
}
|
||||
|
||||
public Type UnderlyingClrType(EdmType edmType)
|
||||
{
|
||||
ArgumentNotNull(edmType, "edmType");
|
||||
|
||||
var primitiveType = edmType as PrimitiveType;
|
||||
if (primitiveType != null)
|
||||
{
|
||||
return primitiveType.ClrEquivalentType;
|
||||
}
|
||||
|
||||
if (IsEnumType(edmType))
|
||||
{
|
||||
return GetEnumUnderlyingType(edmType).ClrEquivalentType;
|
||||
}
|
||||
|
||||
return typeof(object);
|
||||
}
|
||||
|
||||
public object GetEnumMemberValue(MetadataItem enumMember)
|
||||
{
|
||||
ArgumentNotNull(enumMember, "enumMember");
|
||||
|
||||
var valueProperty = enumMember.GetType().GetProperty("Value");
|
||||
return valueProperty == null ? null : valueProperty.GetValue(enumMember, null);
|
||||
}
|
||||
|
||||
public string GetEnumMemberName(MetadataItem enumMember)
|
||||
{
|
||||
ArgumentNotNull(enumMember, "enumMember");
|
||||
|
||||
var nameProperty = enumMember.GetType().GetProperty("Name");
|
||||
return nameProperty == null ? null : (string)nameProperty.GetValue(enumMember, null);
|
||||
}
|
||||
|
||||
public System.Collections.IEnumerable GetEnumMembers(EdmType enumType)
|
||||
{
|
||||
ArgumentNotNull(enumType, "enumType");
|
||||
|
||||
var membersProperty = enumType.GetType().GetProperty("Members");
|
||||
return membersProperty != null
|
||||
? (System.Collections.IEnumerable)membersProperty.GetValue(enumType, null)
|
||||
: Enumerable.Empty<MetadataItem>();
|
||||
}
|
||||
|
||||
public bool EnumIsFlags(EdmType enumType)
|
||||
{
|
||||
ArgumentNotNull(enumType, "enumType");
|
||||
|
||||
var isFlagsProperty = enumType.GetType().GetProperty("IsFlags");
|
||||
return isFlagsProperty != null && (bool)isFlagsProperty.GetValue(enumType, null);
|
||||
}
|
||||
|
||||
public bool IsEnumType(GlobalItem edmType)
|
||||
{
|
||||
ArgumentNotNull(edmType, "edmType");
|
||||
|
||||
return edmType.GetType().Name == "EnumType";
|
||||
}
|
||||
|
||||
public PrimitiveType GetEnumUnderlyingType(EdmType enumType)
|
||||
{
|
||||
ArgumentNotNull(enumType, "enumType");
|
||||
|
||||
return (PrimitiveType)enumType.GetType().GetProperty("UnderlyingType").GetValue(enumType, null);
|
||||
}
|
||||
|
||||
public string CreateLiteral(object value)
|
||||
{
|
||||
if (value == null || value.GetType() != typeof(TimeSpan))
|
||||
{
|
||||
return _code.CreateLiteral(value);
|
||||
}
|
||||
|
||||
return string.Format(CultureInfo.InvariantCulture, "new TimeSpan({0})", ((TimeSpan)value).Ticks);
|
||||
}
|
||||
|
||||
public bool VerifyCaseInsensitiveTypeUniqueness(IEnumerable<string> types, string sourceFile)
|
||||
{
|
||||
ArgumentNotNull(types, "types");
|
||||
ArgumentNotNull(sourceFile, "sourceFile");
|
||||
|
||||
var hash = new HashSet<string>(StringComparer.InvariantCultureIgnoreCase);
|
||||
if (types.Any(item => !hash.Add(item)))
|
||||
{
|
||||
_errors.Add(
|
||||
new CompilerError(sourceFile, -1, -1, "6023",
|
||||
String.Format(CultureInfo.CurrentCulture, CodeGenerationTools.GetResourceString("Template_CaseInsensitiveTypeConflict"))));
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
public IEnumerable<SimpleType> GetEnumItemsToGenerate(IEnumerable<GlobalItem> itemCollection)
|
||||
{
|
||||
return GetItemsToGenerate<SimpleType>(itemCollection)
|
||||
.Where(e => IsEnumType(e));
|
||||
}
|
||||
|
||||
public IEnumerable<T> GetItemsToGenerate<T>(IEnumerable<GlobalItem> itemCollection) where T: EdmType
|
||||
{
|
||||
return itemCollection
|
||||
.OfType<T>()
|
||||
.Where(i => !i.MetadataProperties.Any(p => p.Name == ExternalTypeNameAttributeName))
|
||||
.OrderBy(i => i.Name);
|
||||
}
|
||||
|
||||
public IEnumerable<string> GetAllGlobalItems(IEnumerable<GlobalItem> itemCollection)
|
||||
{
|
||||
return itemCollection
|
||||
.Where(i => i is EntityType || i is ComplexType || i is EntityContainer || IsEnumType(i))
|
||||
.Select(g => GetGlobalItemName(g));
|
||||
}
|
||||
|
||||
public string GetGlobalItemName(GlobalItem item)
|
||||
{
|
||||
if (item is EdmType)
|
||||
{
|
||||
return ((EdmType)item).Name;
|
||||
}
|
||||
else
|
||||
{
|
||||
return ((EntityContainer)item).Name;
|
||||
}
|
||||
}
|
||||
|
||||
public IEnumerable<EdmProperty> GetSimpleProperties(EntityType type)
|
||||
{
|
||||
return type.Properties.Where(p => p.TypeUsage.EdmType is SimpleType && p.DeclaringType == type);
|
||||
}
|
||||
|
||||
public IEnumerable<EdmProperty> GetSimpleProperties(ComplexType type)
|
||||
{
|
||||
return type.Properties.Where(p => p.TypeUsage.EdmType is SimpleType && p.DeclaringType == type);
|
||||
}
|
||||
|
||||
public IEnumerable<EdmProperty> GetComplexProperties(EntityType type)
|
||||
{
|
||||
return type.Properties.Where(p => p.TypeUsage.EdmType is ComplexType && p.DeclaringType == type);
|
||||
}
|
||||
|
||||
public IEnumerable<EdmProperty> GetComplexProperties(ComplexType type)
|
||||
{
|
||||
return type.Properties.Where(p => p.TypeUsage.EdmType is ComplexType && p.DeclaringType == type);
|
||||
}
|
||||
|
||||
public IEnumerable<EdmProperty> GetPropertiesWithDefaultValues(EntityType type)
|
||||
{
|
||||
return type.Properties.Where(p => p.TypeUsage.EdmType is SimpleType && p.DeclaringType == type && p.DefaultValue != null);
|
||||
}
|
||||
|
||||
public IEnumerable<EdmProperty> GetPropertiesWithDefaultValues(ComplexType type)
|
||||
{
|
||||
return type.Properties.Where(p => p.TypeUsage.EdmType is SimpleType && p.DeclaringType == type && p.DefaultValue != null);
|
||||
}
|
||||
|
||||
public IEnumerable<NavigationProperty> GetNavigationProperties(EntityType type)
|
||||
{
|
||||
return type.NavigationProperties.Where(np => np.DeclaringType == type);
|
||||
}
|
||||
|
||||
public IEnumerable<NavigationProperty> GetCollectionNavigationProperties(EntityType type)
|
||||
{
|
||||
return type.NavigationProperties.Where(np => np.DeclaringType == type && np.ToEndMember.RelationshipMultiplicity == RelationshipMultiplicity.Many);
|
||||
}
|
||||
|
||||
public FunctionParameter GetReturnParameter(EdmFunction edmFunction)
|
||||
{
|
||||
ArgumentNotNull(edmFunction, "edmFunction");
|
||||
|
||||
var returnParamsProperty = edmFunction.GetType().GetProperty("ReturnParameters");
|
||||
return returnParamsProperty == null
|
||||
? edmFunction.ReturnParameter
|
||||
: ((IEnumerable<FunctionParameter>)returnParamsProperty.GetValue(edmFunction, null)).FirstOrDefault();
|
||||
}
|
||||
|
||||
public bool IsComposable(EdmFunction edmFunction)
|
||||
{
|
||||
ArgumentNotNull(edmFunction, "edmFunction");
|
||||
|
||||
var isComposableProperty = edmFunction.GetType().GetProperty("IsComposableAttribute");
|
||||
return isComposableProperty != null && (bool)isComposableProperty.GetValue(edmFunction, null);
|
||||
}
|
||||
|
||||
public IEnumerable<FunctionImportParameter> GetParameters(EdmFunction edmFunction)
|
||||
{
|
||||
return FunctionImportParameter.Create(edmFunction.Parameters, _code, _ef);
|
||||
}
|
||||
|
||||
public TypeUsage GetReturnType(EdmFunction edmFunction)
|
||||
{
|
||||
var returnParam = GetReturnParameter(edmFunction);
|
||||
return returnParam == null ? null : _ef.GetElementType(returnParam.TypeUsage);
|
||||
}
|
||||
|
||||
public bool GenerateMergeOptionFunction(EdmFunction edmFunction, bool includeMergeOption)
|
||||
{
|
||||
var returnType = GetReturnType(edmFunction);
|
||||
return !includeMergeOption && returnType != null && returnType.EdmType.BuiltInTypeKind == BuiltInTypeKind.EntityType;
|
||||
}
|
||||
}
|
||||
|
||||
public static void ArgumentNotNull<T>(T arg, string name) where T : class
|
||||
{
|
||||
if (arg == null)
|
||||
{
|
||||
throw new ArgumentNullException(name);
|
||||
}
|
||||
}
|
||||
#>
|
||||
@@ -0,0 +1,28 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class SampleDyeDslvQueue
|
||||
{
|
||||
public Nullable<int> TankNo { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<int> PassAuto { get; set; }
|
||||
public Nullable<int> ShelfID { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public Nullable<System.DateTime> SchDispenseTime { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class SampleDyeDslvQueueHistory
|
||||
{
|
||||
public Nullable<int> TankNo { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<int> PassAuto { get; set; }
|
||||
public Nullable<int> ShelfID { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public Nullable<System.DateTime> SchDispenseTime { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class SchedulingLog
|
||||
{
|
||||
public int ID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int Redye { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public System.DateTime CallTime { get; set; }
|
||||
public Nullable<System.DateTime> EndTime { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public string Status { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,21 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class Shelf
|
||||
{
|
||||
public int ShelfID { get; set; }
|
||||
public Nullable<int> MaxLayer { get; set; }
|
||||
public Nullable<int> MaxPosition { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,42 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class StepVisits
|
||||
{
|
||||
public int ID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public Nullable<int> OverallStepNumber { get; set; }
|
||||
public string XX { get; set; }
|
||||
public string Parameter1 { get; set; }
|
||||
public string Parameter2 { get; set; }
|
||||
public string Parameter3 { get; set; }
|
||||
public string Parameter4 { get; set; }
|
||||
public string Parameter5 { get; set; }
|
||||
public string Command { get; set; }
|
||||
public string Parameters { get; set; }
|
||||
public string Notes { get; set; }
|
||||
public System.DateTime StartTime { get; set; }
|
||||
public System.DateTime EndTime { get; set; }
|
||||
public double Duration { get; set; }
|
||||
public Nullable<double> PlannedDuration { get; set; }
|
||||
public Nullable<double> OverRun { get; set; }
|
||||
public Nullable<int> TemperatureAfter { get; set; }
|
||||
public string ProgramNumber { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> StartTemperature { get; set; }
|
||||
public Nullable<int> EndTemperature { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class Steps
|
||||
{
|
||||
public int ID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public Nullable<int> OverallStepNumber { get; set; }
|
||||
public string XX { get; set; }
|
||||
public string ParameterValues { get; set; }
|
||||
public string Command { get; set; }
|
||||
public string Parameters { get; set; }
|
||||
public string Notes { get; set; }
|
||||
public Nullable<double> PlannedDuration { get; set; }
|
||||
public Nullable<double> ActualDuration { get; set; }
|
||||
public Nullable<double> OverRun { get; set; }
|
||||
public Nullable<int> TemperatureAfter { get; set; }
|
||||
public string ProgramNumber { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class Stoppages
|
||||
{
|
||||
public int AutoKey { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public string Reason { get; set; }
|
||||
public System.DateTime StartTime { get; set; }
|
||||
public Nullable<System.DateTime> EndTime { get; set; }
|
||||
public string Notes { get; set; }
|
||||
public Nullable<double> Duration { get; set; }
|
||||
public string Shift { get; set; }
|
||||
public string SingleShift { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class TagShelf
|
||||
{
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public string Machines { get; set; }
|
||||
public Nullable<int> TagManagerNo { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string DID { get; set; }
|
||||
public Nullable<int> TotalBuckets { get; set; }
|
||||
public Nullable<int> DevideNo { get; set; }
|
||||
public Nullable<System.DateTime> OnShelfTime { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class UserGroup
|
||||
{
|
||||
public string Name { get; set; }
|
||||
public string password { get; set; }
|
||||
public Nullable<int> Permission { get; set; }
|
||||
public string User_Group { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class Users
|
||||
{
|
||||
public string Name { get; set; }
|
||||
public string Xml { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class WaitChemical
|
||||
{
|
||||
public int ID { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public int StepNumber { get; set; }
|
||||
public System.DateTime CreationTime { get; set; }
|
||||
public Nullable<int> ProductType { get; set; }
|
||||
public string ProductCode { get; set; }
|
||||
public string ProductName { get; set; }
|
||||
public double Weight { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<int> Volume { get; set; }
|
||||
public Nullable<double> ActWeight { get; set; }
|
||||
public Nullable<double> FuzhuWeight { get; set; }
|
||||
public Nullable<System.DateTime> DispenseTime { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="EntityFramework" version="6.2.0" targetFramework="net48" />
|
||||
<package id="EntityFramework.zh-Hans" version="6.2.0" targetFramework="net48" />
|
||||
</packages>
|
||||
@@ -0,0 +1,21 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class record
|
||||
{
|
||||
public int ID { get; set; }
|
||||
public string record1 { get; set; }
|
||||
public Nullable<System.DateTime> time { get; set; }
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user