Merge branch 'master' of http://192.168.0.12:13000/sc/Audit_APP
This commit is contained in:
commit
f7e064070c
112 files changed
+2211
-7486
No files matched your search
+3
-2
@@ -24,13 +24,14 @@
|
||||
<bindingRedirect oldVersion="0.0.0.0-2.0.6.0" newVersion="2.0.6.0"/>
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
<legacyUnhandledExceptionPolicy enabled="1"/>
|
||||
</runtime>
|
||||
<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=scddns.f3322.net\EXPRESS,21344;initial catalog=BatchDyeingCentral;persist security info=True;user id=sa;password=SC971216@server;MultipleActiveResultSets=True;App=EntityFramework""
|
||||
connectionString="metadata=res://*/SQL_BD.csdl|res://*/SQL_BD.ssdl|res://*/SQL_BD.msl;provider=System.Data.SqlClient;provider connection string="data source=.\EXPRESS,1433;initial catalog=BatchDyeingCentral;persist security info=True;user id=sa;password=sunlight;MultipleActiveResultSets=True;App=EntityFramework""
|
||||
providerName="System.Data.EntityClient" />
|
||||
<add name="TicketEntities"
|
||||
connectionString="metadata=res://*/SQL_Ti.csdl|res://*/SQL_Ti.ssdl|res://*/SQL_Ti.msl;provider=System.Data.SqlClient;provider connection string="data source=scddns.f3322.net\EXPRESS,21344;initial catalog=Ticket;persist security info=True;user id=sa;password=SC971216@server;MultipleActiveResultSets=True;App=EntityFramework""
|
||||
connectionString="metadata=res://*/SQL_Ti.csdl|res://*/SQL_Ti.ssdl|res://*/SQL_Ti.msl;provider=System.Data.SqlClient;provider connection string="data source=.\EXPRESS,1433;initial catalog=Ticket;persist security info=True;user id=sa;password=sunlight;MultipleActiveResultSets=True;App=EntityFramework""
|
||||
providerName="System.Data.EntityClient" />
|
||||
</connectionStrings>
|
||||
</configuration>
|
||||
@@ -1,4 +1,4 @@
|
||||
<Application x:Class="Audit.App" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="clr-namespace:Audit" StartupUri="Windows/LogWindow.xaml" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" d1p1:Ignorable="d" xmlns:d1p1="http://schemas.openxmlformats.org/markup-compatibility/2006">
|
||||
<Application x:Class="Audit.App" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="clr-namespace:Audit" StartupUri="MainWindow.xaml" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" d1p1:Ignorable="d" xmlns:d1p1="http://schemas.openxmlformats.org/markup-compatibility/2006" >
|
||||
<Application.Resources>
|
||||
<ResourceDictionary>
|
||||
<ResourceDictionary.MergedDictionaries>
|
||||
|
||||
+38
-6
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using MahApps.Metro.Controls;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Configuration;
|
||||
using System.Data;
|
||||
@@ -7,9 +8,11 @@ using System.IO;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows;
|
||||
|
||||
|
||||
namespace Audit
|
||||
{
|
||||
/// <summary>
|
||||
@@ -20,25 +23,54 @@ namespace Audit
|
||||
/// <summary>
|
||||
/// App.xaml 的交互逻辑
|
||||
/// </summary>
|
||||
System.Threading.Mutex mutex;
|
||||
/// <summary>
|
||||
///检查应用进程,防止重复启动。
|
||||
/// </summary>
|
||||
|
||||
public App()
|
||||
{
|
||||
this.Startup += new StartupEventHandler(App_Startup);
|
||||
this.DispatcherUnhandledException += new System.Windows.Threading.DispatcherUnhandledExceptionEventHandler(App_DispatcherUnhandledException);
|
||||
}
|
||||
|
||||
System.Threading.Mutex mutex;
|
||||
void App_Startup(object sender, StartupEventArgs e)
|
||||
{
|
||||
bool ret;
|
||||
mutex = new System.Threading.Mutex(true, "ElectronicNeedleTherapySystem", out ret);
|
||||
|
||||
if (!ret)
|
||||
{
|
||||
MessageBox.Show("SC:审计管理已启动");
|
||||
Environment.Exit(0);
|
||||
}
|
||||
}
|
||||
|
||||
protected override void OnStartup(StartupEventArgs e)
|
||||
{
|
||||
base.OnStartup(e);
|
||||
//UI线程的异常捕捉
|
||||
this.DispatcherUnhandledException += App_DispatcherUnhandledException;
|
||||
}
|
||||
|
||||
private void App_DispatcherUnhandledException(object sender, System.Windows.Threading.DispatcherUnhandledExceptionEventArgs e)
|
||||
{
|
||||
|
||||
e.Handled = true;
|
||||
if (e.Exception.InnerException == null)
|
||||
{
|
||||
MessageBox.Show("(1)发生了一个错误!请联系开发人员!" + Environment.NewLine
|
||||
+ "(2)错误源:" + e.Exception.Source + Environment.NewLine
|
||||
+ "(3)详细信息:" + e.Exception.Message + Environment.NewLine
|
||||
// + "(4)报错区域:" + e.Exception.StackTrace
|
||||
);
|
||||
}
|
||||
else
|
||||
{
|
||||
MessageBox.Show("(1)发生了一个错误!请联系开发人员!" + Environment.NewLine
|
||||
+ "(2)错误源:" + e.Exception.InnerException.Source + Environment.NewLine
|
||||
+ "(3)错误信息:" + e.Exception.Message + Environment.NewLine
|
||||
+ "(4)详细信息:" + e.Exception.InnerException.Message + Environment.NewLine
|
||||
// + "(5)报错区域:" + e.Exception.InnerException.StackTrace
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
+31
-1
@@ -18,7 +18,7 @@
|
||||
</NuGetPackageImportStamp>
|
||||
<IsWebBootstrapper>false</IsWebBootstrapper>
|
||||
<TargetFrameworkProfile />
|
||||
<PublishUrl>publish\</PublishUrl>
|
||||
<PublishUrl>C:\Users\尚彩-沈忱\Desktop\</PublishUrl>
|
||||
<Install>true</Install>
|
||||
<InstallFrom>Disk</InstallFrom>
|
||||
<UpdateEnabled>false</UpdateEnabled>
|
||||
@@ -166,15 +166,30 @@
|
||||
</ApplicationDefinition>
|
||||
<Compile Include="AuditData.cs" />
|
||||
<Compile Include="ConvertMoels\ColorSQLConvert.cs" />
|
||||
<Compile Include="ConvertMoels\ConsumptionConvert.cs" />
|
||||
<Compile Include="ConvertMoels\DeviationConvert.cs" />
|
||||
<Compile Include="ConvertMoels\GramsSQLConvert.cs" />
|
||||
<Compile Include="ConvertMoels\GramsSumConvert.cs" />
|
||||
<Compile Include="ConvertMoels\MachinesDyelotsNumberConvert.cs" />
|
||||
<Compile Include="ConvertMoels\MachinesGramsSumConvert.cs" />
|
||||
<Compile Include="ConvertMoels\ProductTypeSQLConvert.cs" />
|
||||
<Compile Include="ConvertMoels\StatenConvert.cs" />
|
||||
<Compile Include="ConvertMoels\StatenERRConvert.cs" />
|
||||
<Compile Include="ViewModel\LogViewModel.cs" />
|
||||
<Compile Include="ViewModel\MachinesViewModel.cs" />
|
||||
<Compile Include="ViewModel\MainViewModel.cs" />
|
||||
<Compile Include="ViewModel\PipesViewModel.cs" />
|
||||
<Compile Include="ViewModel\QueryViewModel.cs" />
|
||||
<Compile Include="ViewModel\StatisticsViewModel.cs" />
|
||||
<Compile Include="ViewModel\StuffViewModel.cs" />
|
||||
<Compile Include="ViewModel\UserViewModel.cs" />
|
||||
<Compile Include="ViewModel\ViewModelLocator.cs" />
|
||||
<Compile Include="View\MachinesView.xaml.cs">
|
||||
<DependentUpon>MachinesView.xaml</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="View\PipesView.xaml.cs">
|
||||
<DependentUpon>PipesView.xaml</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="View\QueryView.xaml.cs">
|
||||
<DependentUpon>QueryView.xaml</DependentUpon>
|
||||
</Compile>
|
||||
@@ -193,6 +208,9 @@
|
||||
<Compile Include="Windows\Set_up_Sql.xaml.cs">
|
||||
<DependentUpon>Set_up_Sql.xaml</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Windows\user.xaml.cs">
|
||||
<DependentUpon>user.xaml</DependentUpon>
|
||||
</Compile>
|
||||
<Page Include="MainWindow.xaml">
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
<SubType>Designer</SubType>
|
||||
@@ -209,6 +227,14 @@
|
||||
<SubType>Designer</SubType>
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
</Page>
|
||||
<Page Include="View\MachinesView.xaml">
|
||||
<SubType>Designer</SubType>
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
</Page>
|
||||
<Page Include="View\PipesView.xaml">
|
||||
<SubType>Designer</SubType>
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
</Page>
|
||||
<Page Include="View\QueryView.xaml">
|
||||
<SubType>Designer</SubType>
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
@@ -233,6 +259,10 @@
|
||||
<SubType>Designer</SubType>
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
</Page>
|
||||
<Page Include="Windows\user.xaml">
|
||||
<SubType>Designer</SubType>
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
</Page>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Properties\AssemblyInfo.cs">
|
||||
|
||||
@@ -0,0 +1,46 @@
|
||||
using Audit.View;
|
||||
using Models;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Globalization;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Data;
|
||||
|
||||
/// <summary>
|
||||
/// 统计消耗量变换器
|
||||
/// 输入:原料代码、时间区间
|
||||
/// 输出:消耗总量(KG)
|
||||
/// </summary>
|
||||
namespace Audit.ConvertMoels
|
||||
{
|
||||
internal class ConsumptionConvert : IValueConverter
|
||||
{
|
||||
private DyelotsBulkedRecipe dyelotsBulkedRecipe = new DyelotsBulkedRecipe();
|
||||
// public static string Code = null;
|
||||
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(StatisticsView.query_start)) StatisticsView.query_start = DateTime.Now.AddDays(-30).ToString("yyyy-MM-dd");//默认开始时间当前日期前30天
|
||||
if (string.IsNullOrWhiteSpace(StatisticsView.query_end)) StatisticsView.query_end = DateTime.Now.AddDays(1).ToString("yyyy-MM-dd");//默认结束时间当前日期后一天
|
||||
dyelotsBulkedRecipe.ProductCode = System.Convert.ToString(value);//传递原料代码
|
||||
dyelotsBulkedRecipe.DispenseStartTime = System.Convert.ToDateTime(StatisticsView.query_start);//传递开始时间
|
||||
dyelotsBulkedRecipe.DispenseEndTime = System.Convert.ToDateTime(StatisticsView.query_end);//传递结束时间
|
||||
float sum_grams = (float)new DyelotsBulkedRecipeProvider().SelectCode(dyelotsBulkedRecipe).Sum(x => x.DispenseGrams);//查询并返回统计结果
|
||||
if (sum_grams == 0)//统计结果为0返回空非0返回实际值
|
||||
{
|
||||
return null;
|
||||
}
|
||||
else
|
||||
{
|
||||
float sum = sum_grams / 1000;//计算
|
||||
return sum.ToString("#0.00");//返回总成本两位小数(元)
|
||||
}
|
||||
}
|
||||
|
||||
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -12,11 +12,11 @@ namespace Audit.ConvertMoels
|
||||
{
|
||||
public object Convert(object[] values, Type targetType, object parameter, CultureInfo culture)
|
||||
{
|
||||
string a = System.Convert.ToString(values[0]);
|
||||
string b = System.Convert.ToString(values[1]);
|
||||
string a = System.Convert.ToString(values[0]);//转换数组1的信息
|
||||
string b = System.Convert.ToString(values[1]);//转换数组2的信息
|
||||
if (a != "" && b != "")
|
||||
{
|
||||
string c = (System.Convert.ToSingle(b) - System.Convert.ToSingle(a)).ToString("0.0");
|
||||
string c = (System.Convert.ToSingle(b) - System.Convert.ToSingle(a)).ToString("0.0");//计算值1和2的差值并返回字符串
|
||||
//string c = "0";
|
||||
return c;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,47 @@
|
||||
using Audit.View;
|
||||
using Models;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Globalization;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Data;
|
||||
|
||||
/// <summary>
|
||||
/// 统计成本变换器
|
||||
/// 输入:原料代码、原料价格、时间区间
|
||||
/// 输出:总成本
|
||||
/// </summary>
|
||||
namespace Audit.ConvertMoels
|
||||
{
|
||||
internal class GramsSumConvert : IMultiValueConverter
|
||||
{
|
||||
private DyelotsBulkedRecipe dyelotsBulkedRecipe = new DyelotsBulkedRecipe();
|
||||
public object Convert(object[] values, Type targetType, object parameter, CultureInfo culture)
|
||||
{
|
||||
string productcode = System.Convert.ToString(values[0]);//转换数组1的信息原料代码
|
||||
float price = System.Convert.ToSingle(values[1]);//转换数组2的信息单价
|
||||
if (string.IsNullOrWhiteSpace(StatisticsView.query_start)) StatisticsView.query_start = DateTime.Now.AddDays(-30).ToString("yyyy-MM-dd");//默认开始时间当前日期前30天
|
||||
if (string.IsNullOrWhiteSpace(StatisticsView.query_end)) StatisticsView.query_end = DateTime.Now.AddDays(1).ToString("yyyy-MM-dd");//默认结束时间当前日期后一天
|
||||
dyelotsBulkedRecipe.ProductCode = System.Convert.ToString(productcode);//传递原料代码
|
||||
dyelotsBulkedRecipe.DispenseStartTime = System.Convert.ToDateTime(StatisticsView.query_start);//传递开始时间
|
||||
dyelotsBulkedRecipe.DispenseEndTime = System.Convert.ToDateTime(StatisticsView.query_end);//传递结束时间
|
||||
float sum_grams = (float)new DyelotsBulkedRecipeProvider().SelectCode(dyelotsBulkedRecipe).Sum(x => x.DispenseGrams);//查询并返回统计结果
|
||||
if (sum_grams > 0 && price > 0)
|
||||
{
|
||||
float sum = (sum_grams * price) / 1000;//计算
|
||||
return sum.ToString("#0.00");//返回总成本两位小数(元)
|
||||
}
|
||||
else
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
public object[] ConvertBack(object value, Type[] targetType, object parameter, CultureInfo culture)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,58 @@
|
||||
using Audit.View;
|
||||
using Models;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Globalization;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Data;
|
||||
|
||||
/// <summary>
|
||||
/// 统计机台单料数变换器
|
||||
/// 输入:原料代码、机台代码、时间区间
|
||||
/// 输出:机台料单数
|
||||
/// </summary>
|
||||
namespace Audit.ConvertMoels
|
||||
{
|
||||
internal class MachinesDyelotsNumberConvert : IValueConverter
|
||||
{
|
||||
private Dyelots dyelots = new Dyelots();
|
||||
private DyelotsBulkedRecipe dyelotsBulkedRecipe = new DyelotsBulkedRecipe();
|
||||
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
|
||||
{
|
||||
string machines = System.Convert.ToString(value);//转换机台号
|
||||
if (string.IsNullOrWhiteSpace(StatisticsView.query_start)) StatisticsView.query_start = DateTime.Now.AddDays(-30).ToString("yyyy-MM-dd");//默认开始时间当前日期前30天
|
||||
if (string.IsNullOrWhiteSpace(StatisticsView.query_end)) StatisticsView.query_end = DateTime.Now.AddDays(1).ToString("yyyy-MM-dd");//默认结束时间当前日期后一天
|
||||
dyelots.Machine = System.Convert.ToString(machines);//传递机台
|
||||
//dyelots.StartTime = System.Convert.ToString(machines);
|
||||
//float sum_grams = (float)new DyelotsBulkedRecipeProvider().SelectCode(dyelotsBulkedRecipe).Sum(x => x.DispenseGrams);//查询并返回统计结果
|
||||
if (string.IsNullOrWhiteSpace(StatisticsView.DataGridStatistics_ProductCode))//原料代码名有效返回数据,无效返回空
|
||||
{
|
||||
return null;
|
||||
}
|
||||
else
|
||||
{
|
||||
dyelotsBulkedRecipe.Dispenser = System.Convert.ToString(machines);//传递机台
|
||||
dyelotsBulkedRecipe.ProductCode = StatisticsView.DataGridStatistics_ProductCode;
|
||||
dyelotsBulkedRecipe.DispenseStartTime = System.Convert.ToDateTime(StatisticsView.query_start);
|
||||
dyelotsBulkedRecipe.DispenseEndTime = System.Convert.ToDateTime(StatisticsView.query_end);
|
||||
float Machines_Number = (float)new DyelotsBulkedRecipeProvider().SelectMachineSUM(dyelotsBulkedRecipe).Count(t => t.ReDye == 0);//查询并返回统计结果
|
||||
if (Machines_Number == 0)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
else
|
||||
{
|
||||
return Machines_Number;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,57 @@
|
||||
using Audit.View;
|
||||
using Models;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Globalization;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Data;
|
||||
|
||||
/// <summary>
|
||||
/// 统计机台消耗变换器
|
||||
/// 输入:原料代码、机台代码、时间区间
|
||||
/// 输出:机台消耗
|
||||
/// </summary>
|
||||
namespace Audit.ConvertMoels
|
||||
{
|
||||
internal class MachinesGramsSumConvert : IValueConverter
|
||||
{
|
||||
private Dyelots dyelots = new Dyelots();
|
||||
private DyelotsBulkedRecipe dyelotsBulkedRecipe = new DyelotsBulkedRecipe();
|
||||
|
||||
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
|
||||
{
|
||||
string machines = System.Convert.ToString(value);//转换机台号
|
||||
if (string.IsNullOrWhiteSpace(StatisticsView.query_start)) StatisticsView.query_start = DateTime.Now.AddDays(-30).ToString("yyyy-MM-dd");//默认开始时间当前日期前30天
|
||||
if (string.IsNullOrWhiteSpace(StatisticsView.query_end)) StatisticsView.query_end = DateTime.Now.AddDays(1).ToString("yyyy-MM-dd");//默认结束时间当前日期后一天
|
||||
if (string.IsNullOrWhiteSpace(StatisticsView.DataGridStatistics_ProductCode))//原料代码名有效返回数据,无效返回空
|
||||
{
|
||||
return null;
|
||||
}
|
||||
else
|
||||
{
|
||||
dyelotsBulkedRecipe.Dispenser = System.Convert.ToString(machines);//传递机台
|
||||
dyelotsBulkedRecipe.ProductCode = StatisticsView.DataGridStatistics_ProductCode;
|
||||
dyelotsBulkedRecipe.DispenseStartTime = System.Convert.ToDateTime(StatisticsView.query_start);
|
||||
dyelotsBulkedRecipe.DispenseEndTime = System.Convert.ToDateTime(StatisticsView.query_end);
|
||||
float Machines_sum = (float)new DyelotsBulkedRecipeProvider().SelectMachineSUM(dyelotsBulkedRecipe).Sum(x => x.DispenseGrams);//查询并返回统计结果
|
||||
if (Machines_sum == 0)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
else
|
||||
{
|
||||
string Machines_grams_sum = (Machines_sum / 1000).ToString("#0.00");
|
||||
return Machines_grams_sum;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -19,7 +19,7 @@ namespace Audit.ConvertMoels
|
||||
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
|
||||
{
|
||||
string ProductType = System.Convert.ToString(value);
|
||||
if (ProductType == "0")//类型0:染料,1:助剂,2:粉体助剂,其它:未知
|
||||
if (ProductType == "0")//类型0:染料,1:助剂,2:粉体助剂,3:液体染料,其它:未知
|
||||
{
|
||||
return "染料";
|
||||
}
|
||||
@@ -36,12 +36,19 @@ namespace Audit.ConvertMoels
|
||||
return "粉体助剂";
|
||||
}
|
||||
else
|
||||
{
|
||||
if (ProductType == "3")
|
||||
{
|
||||
return "液体染料";
|
||||
}
|
||||
else
|
||||
{
|
||||
return "未知类型";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// </summary>
|
||||
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
|
||||
|
||||
@@ -0,0 +1,50 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows;
|
||||
using System.Windows.Data;
|
||||
using System.Windows.Input;
|
||||
using System.Windows.Controls;
|
||||
|
||||
/// <summary>
|
||||
/// 运行状态变换器
|
||||
/// 输入:状态码
|
||||
/// 输出:状态文字
|
||||
/// </summary>
|
||||
namespace Audit.ConvertMoels
|
||||
{
|
||||
internal class StatenConvert : IValueConverter
|
||||
{
|
||||
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
||||
{
|
||||
if (value == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
else
|
||||
{
|
||||
string Staten = null;
|
||||
string i = value.ToString();
|
||||
|
||||
if (i == "101") Staten = "准备就绪";
|
||||
if (i == "102") Staten = "计量输送";
|
||||
if (i == "201") Staten = "自动状态";
|
||||
if (i == "202") Staten = "转入排队";
|
||||
if (i == "203") Staten = "等待命令";
|
||||
if (i == "301") Staten = "工单完成";
|
||||
if (i == "309") Staten = "输送异常";
|
||||
|
||||
return Staten;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,40 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows;
|
||||
using System.Windows.Data;
|
||||
using System.Windows.Input;
|
||||
using System.Windows.Controls;
|
||||
|
||||
namespace Audit.ConvertMoels
|
||||
{
|
||||
internal class StatenERRConvert : IValueConverter
|
||||
{
|
||||
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
||||
{
|
||||
if (value == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (value.ToString() == "309")
|
||||
{
|
||||
return "red";//零返回红色
|
||||
}
|
||||
else
|
||||
{
|
||||
return "black";//非零返回黑色
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
using Audit.View;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Globalization;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Data;
|
||||
|
||||
namespace Audit.ConvertMoels
|
||||
{
|
||||
internal class SumSQLConvert : IValueConverter
|
||||
{
|
||||
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
|
||||
{
|
||||
string a = StatisticsView.query_start;
|
||||
string b = StatisticsView.query_end;
|
||||
return null;
|
||||
}
|
||||
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
+61
-4
@@ -4,13 +4,16 @@
|
||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
xmlns:local="clr-namespace:Audit"
|
||||
xmlns:ConvertMoels="clr-namespace:Audit.ConvertMoels"
|
||||
xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
|
||||
xmlns:mah="http://metro.mahapps.com/winfx/xaml/controls"
|
||||
x:Class="Audit.MainWindow"
|
||||
mc:Ignorable="d"
|
||||
Background="#FFF5F5F5"
|
||||
Title="SUNLIGHT" Height="900" Width="1280" WindowStartupLocation="CenterScreen">
|
||||
|
||||
<mah:MetroWindow.Resources>
|
||||
|
||||
<Style x:Key="RadioButtonStyle" TargetType="{x:Type RadioButton}">
|
||||
<Setter Property="Background" Value="{DynamicResource MahApps.Brushes.ThemeBackground}"/>
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource MahApps.Brushes.CheckBox}"/>
|
||||
@@ -58,6 +61,53 @@
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
<Style x:Key="RadioButtonStyle2" TargetType="{x:Type RadioButton}">
|
||||
<Setter Property="Background" Value="{DynamicResource MahApps.Brushes.ThemeBackground}"/>
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource MahApps.Brushes.CheckBox}"/>
|
||||
<Setter Property="FocusVisualStyle" Value="{DynamicResource {x:Static SystemParameters.FocusVisualStyleKey}}"/>
|
||||
<Setter Property="FontFamily" Value="{DynamicResource MahApps.Fonts.Family.Control}"/>
|
||||
<Setter Property="FontSize" Value="{DynamicResource MahApps.Font.Size.Content}"/>
|
||||
<Setter Property="Foreground" Value="{DynamicResource MahApps.Brushes.Text}"/>
|
||||
<Setter Property="HorizontalContentAlignment" Value="Left"/>
|
||||
<Setter Property="OverridesDefaultStyle" Value="True"/>
|
||||
<Setter Property="Padding" Value="6 0 0 0"/>
|
||||
<Setter Property="SnapsToDevicePixels" Value="True"/>
|
||||
<Setter Property="Stylus.IsPressAndHoldEnabled" Value="False"/>
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type RadioButton}">
|
||||
<Grid>
|
||||
<Border x:Name="border" Background="{TemplateBinding Background}">
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition>
|
||||
</ColumnDefinition>
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBlock Grid.Row="0" Grid.Column="0"
|
||||
Text="{TemplateBinding Tag}"
|
||||
FontFamily="Fonts/#FontAwesome"
|
||||
HorizontalAlignment="Left"
|
||||
Width="40" FontSize="30" Margin="10,10,0,0"/>
|
||||
<TextBlock Grid.Row="0" Grid.Column="1"
|
||||
Text="{TemplateBinding Content}"
|
||||
FontFamily="Fonts/#FontAwesome"
|
||||
HorizontalAlignment="Center"
|
||||
Width="130" FontSize="30" Margin="10,10,0,0"/>
|
||||
</Grid>
|
||||
</Border>
|
||||
</Grid>
|
||||
<ControlTemplate.Triggers>
|
||||
<Trigger Property="IsMouseOver" Value="True">
|
||||
<Setter Property="Background" Value="#FFA0A0A0" TargetName="border"/>
|
||||
</Trigger>
|
||||
<Trigger Property="IsChecked" Value="True">
|
||||
<Setter Property="Background" Value="#FFF5F5F5" TargetName="border"/>
|
||||
</Trigger>
|
||||
</ControlTemplate.Triggers>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
<Style x:Key="Style" TargetType="{x:Type RadioButton}">
|
||||
<Setter Property="Background" Value="{DynamicResource MahApps.Brushes.ThemeBackground}"/>
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource MahApps.Brushes.CheckBox}"/>
|
||||
@@ -104,13 +154,15 @@
|
||||
</Style>
|
||||
</mah:MetroWindow.Resources>
|
||||
<Grid>
|
||||
|
||||
<Rectangle HorizontalAlignment="Left" Width="140" Margin="0,0,0,0" Fill="#FFCCCCCC"/>
|
||||
<RadioButton Content="查询" Tag="" HorizontalAlignment="Left" Height="55" Margin="0,190,0,0" VerticalAlignment="Top" Width="140" Background="#FFCCCCCC" Style="{DynamicResource RadioButtonStyle}" Checked="RadioButton_Checked"/>
|
||||
<RadioButton Content="统计" Tag="" HorizontalAlignment="Left" Height="55" Margin="0,245,0,0" VerticalAlignment="Top" Width="140" Background="#FFCCCCCC" Style="{DynamicResource RadioButtonStyle}" Checked="RadioButton_Checked"/>
|
||||
<RadioButton Content="原料" Tag="" HorizontalAlignment="Left" Height="55" Margin="0,300,0,0" VerticalAlignment="Top" Width="140" Background="#FFCCCCCC" Style="{DynamicResource RadioButtonStyle}" Checked="RadioButton_Checked"/>
|
||||
<RadioButton Content="退出" Tag="" HorizontalAlignment="Left" Height="55" Margin="0,0,0,50" VerticalAlignment="Bottom" Width="140" Background="#FFCCCCCC" Style="{DynamicResource Style}" Checked="Exit" />
|
||||
<RadioButton Content="信息" Tag="" HorizontalAlignment="Left" Height="55" Margin="0,0,0,105" VerticalAlignment="Bottom" Width="140" Background="#FFCCCCCC" Style="{DynamicResource Style}" Checked="Help" />
|
||||
<RadioButton Content="管理" Tag="" HorizontalAlignment="Left" Height="55" Margin="0,300,0,0" VerticalAlignment="Top" Width="140" Background="#FFCCCCCC" Style="{DynamicResource RadioButtonStyle}" Checked="RadioButton_Checked" x:Name="RadioButtonk1"/>
|
||||
<RadioButton Content="设定" Tag="" HorizontalAlignment="Left" Height="55" Margin="0,0,0,190" VerticalAlignment="Bottom" Width="140" Background="#FFCCCCCC" Style="{DynamicResource Style}" Checked="Set_up" x:Name="RadioButtonk12"/>
|
||||
<RadioButton Content="用户" Tag="" HorizontalAlignment="Left" Height="55" Margin="0,0,0,135" VerticalAlignment="Bottom" Width="140" Background="#FFCCCCCC" Style="{DynamicResource Style}" Checked="User" />
|
||||
<RadioButton Content="退出" Tag="" HorizontalAlignment="Left" Height="55" Margin="0,0,0,25" VerticalAlignment="Bottom" Width="140" Background="#FFCCCCCC" Style="{DynamicResource Style}" Checked="Exit" />
|
||||
<RadioButton Content="信息" Tag="" HorizontalAlignment="Left" Height="55" Margin="0,0,0,80" VerticalAlignment="Bottom" Width="140" Background="#FFCCCCCC" Style="{DynamicResource Style}" Checked="Help" />
|
||||
<TextBlock x:Name="user_time" HorizontalAlignment="Left" Height="25" Margin="10,0,0,0" VerticalAlignment="Bottom" Width="100" />
|
||||
<Rectangle HorizontalAlignment="Left" Height="120" Margin="10,10,0,0" VerticalAlignment="Top" Width="120">
|
||||
<Rectangle.Fill>
|
||||
<ImageBrush ImageSource="/Logo/sunlight_sc.png"/>
|
||||
@@ -120,6 +172,11 @@
|
||||
<Grid Grid.Column="1">
|
||||
<ContentControl x:Name="container" Margin="140,0,0,0"/>
|
||||
</Grid>
|
||||
<RadioButton x:Name="RadioButtonk2" Content="-" Tag="" HorizontalAlignment="Left" Height="55" Margin="140,140,0,0" VerticalAlignment="Top" Width="140" Background="#FFEBEBEB" Style="{DynamicResource RadioButtonStyle2}" Checked="RadioButton_Checked2" Opacity="0.85" Visibility="Collapsed"/>
|
||||
<RadioButton x:Name="RadioButtonk21" Content="原料管理" HorizontalAlignment="Left" Height="55" Margin="140,190,0,0" VerticalAlignment="Top" Width="140" Background="#FFEBEBEB" Style="{DynamicResource RadioButtonStyle2}" Checked="RadioButton_Checked2" Opacity="0.95" Visibility="Collapsed"/>
|
||||
<RadioButton x:Name="RadioButtonk22" Content="染机管理" HorizontalAlignment="Left" Height="55" Margin="140,245,0,0" VerticalAlignment="Top" Width="140" Background="#FFEBEBEB" Style="{DynamicResource RadioButtonStyle2}" Checked="RadioButton_Checked2" Opacity="0.95" Visibility="Collapsed"/>
|
||||
<RadioButton x:Name="RadioButtonk23" Content="设备管理" HorizontalAlignment="Left" Height="55" Margin="140,300,0,0" VerticalAlignment="Top" Width="140" Background="#FFEBEBEB" Style="{DynamicResource RadioButtonStyle2}" Checked="RadioButton_Checked2" Opacity="0.95" Visibility="Collapsed"/>
|
||||
<RadioButton x:Name="RadioButtonk24" Content="输送原料" HorizontalAlignment="Left" Height="55" Margin="140,355,0,0" VerticalAlignment="Top" Width="140" Background="#FFEBEBEB" Style="{DynamicResource RadioButtonStyle2}" Checked="RadioButton_Checked2" Opacity="0.95" Visibility="Collapsed"/>
|
||||
|
||||
</Grid>
|
||||
</mah:MetroWindow>
|
||||
+135
-7
@@ -15,6 +15,7 @@ using System.Windows.Media;
|
||||
using System.Windows.Media.Imaging;
|
||||
using System.Windows.Navigation;
|
||||
using System.Windows.Shapes;
|
||||
using System.Windows.Threading;
|
||||
|
||||
namespace Audit
|
||||
{
|
||||
@@ -29,14 +30,16 @@ namespace Audit
|
||||
public MainWindow()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
private void TimePicker_SelectedDateTimeChanged(object sender, RoutedPropertyChangedEventArgs<DateTime?> e)
|
||||
{
|
||||
this.RadioButtonk1.Visibility = Visibility.Collapsed;//隐藏管理
|
||||
this.RadioButtonk12.Visibility = Visibility.Collapsed;//隐藏设置
|
||||
CountDown();//执行循环方法
|
||||
}
|
||||
|
||||
private void Exit(object sender, RoutedEventArgs e)
|
||||
{
|
||||
if (user_t > 0)//判断登录状态
|
||||
user_t = 0;//登录倒计时清除
|
||||
else
|
||||
Application.Current.Shutdown();//关闭全部窗口
|
||||
}
|
||||
|
||||
@@ -45,6 +48,60 @@ namespace Audit
|
||||
Windows.help help = new Windows.help();
|
||||
help.ShowDialog();//实例化并置顶打开信息窗口
|
||||
}
|
||||
private void User(object sender, RoutedEventArgs e)
|
||||
{
|
||||
Windows.user user = new Windows.user();
|
||||
user.ShowDialog();//实例化并置顶打开用户窗口
|
||||
}
|
||||
|
||||
private void Set_up(object sender, RoutedEventArgs e)
|
||||
{
|
||||
Windows.Set_up_Sql set = new Windows.Set_up_Sql();
|
||||
set.ShowDialog();//实例化并置顶打开设置窗口
|
||||
}
|
||||
|
||||
public static int user_t = 0;
|
||||
public static string user_n = null;
|
||||
|
||||
public void DisTimer_Tick(object sender, EventArgs e)//循环事件
|
||||
{
|
||||
if (string.IsNullOrEmpty(user_n))
|
||||
{
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
if (user_t > 0)
|
||||
{
|
||||
this.RadioButtonk1.Visibility = Visibility.Visible;//显示管理
|
||||
this.RadioButtonk12.Visibility = Visibility.Visible;//显示设置
|
||||
user_time.Text = user_n + ":" + user_t.ToString();//前端计时显示
|
||||
user_t--;//计时减一
|
||||
}
|
||||
else
|
||||
{
|
||||
container.Content = new QueryView();//打开查询
|
||||
this.RadioButtonk1.Visibility = Visibility.Collapsed;//隐藏管理
|
||||
this.RadioButtonk12.Visibility = Visibility.Collapsed;//隐藏设置
|
||||
this.RadioButtonk2.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk21.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk22.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk23.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk24.Visibility = Visibility.Collapsed;//隐藏管理副目录
|
||||
user_n = null;//状态清空
|
||||
user_time.Text = null;//前端计数显示空
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private DispatcherTimer disTimer = new DispatcherTimer();//循环功能
|
||||
public void CountDown()
|
||||
{
|
||||
//设置定时器
|
||||
disTimer.Tick += new EventHandler(DisTimer_Tick);//每一秒执行的方法
|
||||
disTimer.Interval = new TimeSpan(10000000); //时间间隔为一秒。
|
||||
disTimer.Start();//计时开始
|
||||
}
|
||||
|
||||
private void RadioButton_Checked(object sender, RoutedEventArgs e)
|
||||
{
|
||||
@@ -52,12 +109,83 @@ namespace Audit
|
||||
if (string.IsNullOrEmpty(button.Content.ToString())) return;
|
||||
switch (button.Content.ToString())
|
||||
{
|
||||
case "查询": container.Content = new QueryView(); break;
|
||||
case "原料": container.Content = new StuffView(); break;
|
||||
case "统计": container.Content = new StatisticsView(); break;
|
||||
case "查询":
|
||||
container.Content = new QueryView();
|
||||
this.RadioButtonk2.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk21.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk22.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk23.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk24.Visibility = Visibility.Collapsed;
|
||||
break;
|
||||
case "统计":
|
||||
container.Content = new StatisticsView();
|
||||
this.RadioButtonk2.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk21.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk22.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk23.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk24.Visibility = Visibility.Collapsed;
|
||||
break;
|
||||
case "管理":
|
||||
this.RadioButtonk2.Visibility = Visibility.Visible;
|
||||
this.RadioButtonk21.Visibility = Visibility.Visible;
|
||||
this.RadioButtonk22.Visibility = Visibility.Visible;
|
||||
this.RadioButtonk23.Visibility = Visibility.Visible;
|
||||
this.RadioButtonk24.Visibility = Visibility.Visible;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
private void RadioButton_Checked2(object sender, RoutedEventArgs e)
|
||||
{
|
||||
if (!(sender is RadioButton button)) return;
|
||||
if (string.IsNullOrEmpty(button.Content.ToString())) return;
|
||||
switch (button.Content.ToString())
|
||||
{
|
||||
case "-":
|
||||
this.RadioButtonk2.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk21.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk22.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk23.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk24.Visibility = Visibility.Collapsed;
|
||||
break;
|
||||
case "原料管理":
|
||||
container.Content = new StuffView();
|
||||
this.RadioButtonk2.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk21.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk22.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk23.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk24.Visibility = Visibility.Collapsed;
|
||||
break;
|
||||
case "染机管理":
|
||||
container.Content = new View.MachinesView();
|
||||
this.RadioButtonk2.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk21.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk22.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk23.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk24.Visibility = Visibility.Collapsed;
|
||||
break;
|
||||
case "设备管理":
|
||||
|
||||
this.RadioButtonk2.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk21.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk22.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk23.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk24.Visibility = Visibility.Collapsed;
|
||||
break;
|
||||
case "输送原料":
|
||||
container.Content = new PipesView();
|
||||
this.RadioButtonk2.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk21.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk22.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk23.Visibility = Visibility.Collapsed;
|
||||
this.RadioButtonk24.Visibility = Visibility.Collapsed;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
+1
-1
@@ -3,5 +3,5 @@
|
||||
<configSections>
|
||||
<!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->
|
||||
</configSections>
|
||||
<connectionStrings><add name="TicketEntities" connectionString="metadata=res://*/SQL_Ti.csdl|res://*/SQL_Ti.ssdl|res://*/SQL_Ti.msl;provider=System.Data.SqlClient;provider connection string="data source=SCSERVER\EXPRESS;initial catalog=Ticket;persist security info=True;user id=sa;password=SC971216@server;MultipleActiveResultSets=True;App=EntityFramework"" providerName="System.Data.EntityClient" /><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=scddns.f3322.net,21344;initial catalog=BatchDyeingCentral;persist security info=True;user id=sa;password=SC971216@server;MultipleActiveResultSets=True;App=EntityFramework"" providerName="System.Data.EntityClient" /></connectionStrings>
|
||||
<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=.\sqlexpress,1433;initial catalog=BatchDyeingCentral;persist security info=True;user id=sa;password=123;MultipleActiveResultSets=True;App=EntityFramework"" providerName="System.Data.EntityClient" /><add name="TicketEntities" connectionString="metadata=res://*/SQL_Ti.csdl|res://*/SQL_Ti.ssdl|res://*/SQL_Ti.msl;provider=System.Data.SqlClient;provider connection string="data source=.\SQLEXPRESS;initial catalog=Ticket;integrated security=True;MultipleActiveResultSets=True;App=EntityFramework"" providerName="System.Data.EntityClient" /></connectionStrings>
|
||||
</configuration>
|
||||
@@ -1,29 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,29 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,26 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class BucketCrane
|
||||
{
|
||||
public string Dyelot { get; set; }
|
||||
public Nullable<int> ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> DevideNo { get; set; }
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public string DID { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,26 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class BucketCraneHistory
|
||||
{
|
||||
public string Dyelot { get; set; }
|
||||
public Nullable<int> ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public Nullable<int> DevideNo { get; set; }
|
||||
public Nullable<int> BucketNo { get; set; }
|
||||
public string DID { get; set; }
|
||||
public Nullable<int> State { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,35 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
public Nullable<int> Locked { get; set; }
|
||||
public string ProductCode { get; set; }
|
||||
public string OriginDyelot { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,35 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
public Nullable<int> Locked { get; set; }
|
||||
public string ProductCode { get; set; }
|
||||
public string OriginDyelot { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,29 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,29 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,21 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,40 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DBRDetail
|
||||
{
|
||||
public long ID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int Redye { get; set; }
|
||||
public int StepNumber { get; set; }
|
||||
public string ProductCode { get; set; }
|
||||
public string ProductName { get; set; }
|
||||
public Nullable<double> Grams { get; set; }
|
||||
public Nullable<double> DispenseGrams { get; set; }
|
||||
public Nullable<int> Buckets { get; set; }
|
||||
public System.DateTime DispenseStartTime { get; set; }
|
||||
public Nullable<System.DateTime> DispenseEndTime { get; set; }
|
||||
public Nullable<int> DispenseSeconds { get; set; }
|
||||
public Nullable<System.DateTime> ProductStartTime { get; set; }
|
||||
public Nullable<System.DateTime> ProductEndTime { get; set; }
|
||||
public Nullable<int> ProductSeconds { get; set; }
|
||||
public Nullable<double> LDXGrams { get; set; }
|
||||
public Nullable<int> LDXBuckets { get; set; }
|
||||
public Nullable<int> IsDeduct { get; set; }
|
||||
public Nullable<int> DeductBox { get; set; }
|
||||
public string BoxNo { get; set; }
|
||||
public Nullable<int> DispenseResult { get; set; }
|
||||
public Nullable<double> BucketWeight { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,34 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 Device { 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; }
|
||||
}
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DispenserLifeStatus
|
||||
{
|
||||
public string Dispenser { get; set; }
|
||||
public string Device { get; set; }
|
||||
public Nullable<int> HeartBeat { get; set; }
|
||||
public Nullable<int> LifeTime { get; set; }
|
||||
public Nullable<System.DateTime> UpdateDate { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DispenserUtilization
|
||||
{
|
||||
public string Dispenser { 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 Nullable<System.DateTime> UtilStartDate { get; set; }
|
||||
public Nullable<System.DateTime> UtilEndDate { get; set; }
|
||||
public Nullable<int> UtilTimes { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,37 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 string Action { get; set; }
|
||||
public string ProductCode { get; set; }
|
||||
public Nullable<int> SN { 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; }
|
||||
}
|
||||
}
|
||||
@@ -1,29 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DissolveArt
|
||||
{
|
||||
public string Name { get; set; }
|
||||
public Nullable<int> ProductClass { get; set; }
|
||||
public Nullable<double> LiquidRatio { get; set; }
|
||||
public Nullable<double> MinWeight { get; set; }
|
||||
public Nullable<double> MaxWeight { get; set; }
|
||||
public Nullable<int> DissolveTemperature { get; set; }
|
||||
public Nullable<int> UseLiquidDye { get; set; }
|
||||
public Nullable<int> UseChemical { get; set; }
|
||||
public string Process { get; set; }
|
||||
public Nullable<int> TankSize { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,29 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class DissolveArtHistory
|
||||
{
|
||||
public string Name { get; set; }
|
||||
public Nullable<int> ProductClass { get; set; }
|
||||
public Nullable<double> LiquidRatio { get; set; }
|
||||
public Nullable<double> MinWeight { get; set; }
|
||||
public Nullable<double> MaxWeight { get; set; }
|
||||
public Nullable<int> DissolveTemperature { get; set; }
|
||||
public Nullable<int> UseLiquidDye { get; set; }
|
||||
public Nullable<int> UseChemical { get; set; }
|
||||
public string Process { get; set; }
|
||||
public Nullable<int> TankSize { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,28 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,28 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,40 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,29 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,29 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,65 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -17,51 +17,12 @@ namespace Models
|
||||
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 Nullable<int> OnSchedule { get; set; }
|
||||
public Nullable<int> DyeStep { get; set; }
|
||||
public Nullable<short> PowderBlocked { get; set; }
|
||||
public Nullable<int> PowderOnSchedule { get; set; }
|
||||
public Nullable<int> PowderStep { get; set; }
|
||||
public string DispensedVolume { get; set; }
|
||||
public Nullable<int> Times { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
public string FabricName { get; set; }
|
||||
public string ColorNo { 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<System.DateTime> ModifyDT { get; set; }
|
||||
public Nullable<System.DateTime> CreateDT { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,38 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -19,14 +19,11 @@ namespace Models
|
||||
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; }
|
||||
@@ -35,51 +32,9 @@ namespace Models
|
||||
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<double> TargetGrams { get; set; }
|
||||
public Nullable<double> 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<int> Flow { get; set; }
|
||||
public Nullable<System.DateTime> CallTime { get; set; }
|
||||
public Nullable<double> BreakGrams { get; set; }
|
||||
public Nullable<int> RecoveryAction { get; set; }
|
||||
public Nullable<int> SmallDye { get; set; }
|
||||
public string PrepareTank { get; set; }
|
||||
public Nullable<int> DeductBox { get; set; }
|
||||
public Nullable<int> Shade { get; set; }
|
||||
public string stuffid { get; set; }
|
||||
public string tfname { get; set; }
|
||||
public string tftips { get; set; }
|
||||
public string program { get; set; }
|
||||
public Nullable<decimal> dosage { get; set; }
|
||||
public string groupid { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,68 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -31,9 +31,23 @@ namespace Models
|
||||
return db.DyelotsBulkedRecipe.SqlQuery(sqlselect).ToList();
|
||||
}
|
||||
|
||||
public List<DyelotsBulkedRecipe> Select()//查询前300条
|
||||
public List<DyelotsBulkedRecipe> SelectCode(DyelotsBulkedRecipe t)//以单号查询消耗
|
||||
{
|
||||
return db.DyelotsBulkedRecipe.SqlQuery("select TOP (300) * from DyelotsBulkedRecipe").ToList();//查询前300条
|
||||
string sqlselect = "select * from DyelotsBulkedRecipe Where ProductCode = " + "'" + t.ProductCode.ToString()
|
||||
+ "' and Created > '" + t.DispenseStartTime + "' and Created < '" + t.DispenseEndTime + "'";
|
||||
return db.DyelotsBulkedRecipe.SqlQuery(sqlselect).ToList();
|
||||
}
|
||||
|
||||
public List<DyelotsBulkedRecipe> SelectMachineSUM(DyelotsBulkedRecipe t)//以机台查询消耗
|
||||
{
|
||||
string sqlselect = "SELECT * FROM [BatchDyeingCentral].[dbo].[DyelotsBulkedRecipe] where Dyelot in (SELECT dyelot FROM [BatchDyeingCentral].[dbo].[Dyelots] where Machine = '"
|
||||
+ t.Dispenser.ToString() + "') and Created > '" + t.DispenseStartTime.ToString() + "' and Created < '" + t.DispenseEndTime.ToString() +"' and ProductCode = '" + t.ProductCode.ToString() + "'";
|
||||
return db.DyelotsBulkedRecipe.SqlQuery(sqlselect).ToList();
|
||||
}
|
||||
|
||||
public List<DyelotsBulkedRecipe> Select()//查询前500条
|
||||
{
|
||||
return db.DyelotsBulkedRecipe.SqlQuery("select TOP (500) * from DyelotsBulkedRecipe").ToList();//查询前500条
|
||||
}
|
||||
public int Update(DyelotsBulkedRecipe t)
|
||||
{
|
||||
|
||||
@@ -1,52 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,26 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,26 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -32,7 +32,7 @@ namespace Models
|
||||
|
||||
public List<Dyelots> Select()
|
||||
{
|
||||
string sqlselect= "select TOP (300) * from Dyelots Where CreationTime > '" + DateTime.Now.ToString("yyyy-MM-dd") + "'";
|
||||
string sqlselect= "select * from Dyelots Where CreationTime > '" + DateTime.Now.ToString("yyyy-MM-dd") + "'";
|
||||
return db.Dyelots.SqlQuery(sqlselect).ToList();
|
||||
}
|
||||
|
||||
@@ -55,6 +55,7 @@ namespace Models
|
||||
+ "' and CreationTime > '" + t.StartTime.ToString() + "' and Machine = '" + t.Machine.ToString() + "'";
|
||||
return db.Dyelots.SqlQuery(sqlselect).ToList();
|
||||
}
|
||||
|
||||
public int Update(Dyelots t)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
|
||||
@@ -1,23 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,23 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,41 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,42 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -78,11 +78,5 @@ namespace Models
|
||||
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 OnDevice { get; set; }
|
||||
public string PwdDispenseDyelot { get; set; }
|
||||
public Nullable<int> PwdDispenseReDye { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,50 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 string CheDispenseDyelot { get; set; }
|
||||
public Nullable<int> CheDispenseReDye { get; set; }
|
||||
public string PwdDispenseDyelot { get; set; }
|
||||
public Nullable<int> PwdDispenseReDye { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,46 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class MachinesHistoryOld
|
||||
{
|
||||
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; }
|
||||
}
|
||||
}
|
||||
@@ -12,26 +12,114 @@ namespace Models
|
||||
|
||||
public int Delete(Machines t)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
if (t == null) return 0;
|
||||
var model = db.Machines.ToList().FirstOrDefault(item => t.Name == item.Name.Trim());
|
||||
if (model == null) return 0;
|
||||
db.Machines.Remove(model);
|
||||
int count = db.SaveChanges();
|
||||
return count;
|
||||
}
|
||||
|
||||
public int Insert(Machines t)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
if (t == null) return 0;
|
||||
if (String.IsNullOrEmpty(t.Name)) return 0;
|
||||
db.Machines.Add(t);
|
||||
int count = db.SaveChanges();
|
||||
return count;
|
||||
}
|
||||
|
||||
public List<Machines> Select()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
return db.Machines.SqlQuery("select * from Machines").ToList();//查询机台
|
||||
}
|
||||
|
||||
public List<Machines> Selectsql(Machines t)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
string sqlselect = "select * from Machines Where Name = " + "'" + t.Name.ToString() + "'";
|
||||
return db.Machines.SqlQuery(sqlselect).ToList();
|
||||
}
|
||||
public int Update(Machines t)
|
||||
public int Update(Machines t)//更新信息
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
if (t == null) return 0;
|
||||
var model = db.Machines.ToList().FirstOrDefault(item => item.Name.Trim() == t.Name);
|
||||
if (model == null) return 0;
|
||||
model.DispenseDyelot = t.DispenseDyelot;
|
||||
model.DyeDispenseDyelot = t.DyeDispenseDyelot;
|
||||
model.ChemicalStation = t.ChemicalStation;
|
||||
model.DyeStation = t.DyeStation;
|
||||
model.PowderStation = t.PowderStation;
|
||||
model.ChemicalDispenser = t.ChemicalDispenser;
|
||||
model.DyeDispenser = t.DyeDispenser;
|
||||
model.PowderDispenser = t.PowderDispenser;
|
||||
model.ChemicalCallOff = t.ChemicalCallOff;
|
||||
model.ChemicalCallOff2 = t.ChemicalCallOff2;
|
||||
model.ChemicalState = t.ChemicalState;
|
||||
model.ChemicalState2 = t.ChemicalState2;
|
||||
model.DyeCallOff = t.DyeCallOff;
|
||||
model.DyeState = t.DyeState;
|
||||
model.PowderCallOff = t.PowderCallOff;
|
||||
model.PowderState = t.PowderState;
|
||||
model.ChemicalEnabled = t.ChemicalEnabled;
|
||||
model.DyeEnabled = t.DyeEnabled;
|
||||
model.PowderEnabled = t.PowderEnabled;
|
||||
int count = db.SaveChanges();
|
||||
return count;
|
||||
}
|
||||
|
||||
public int Update1(Machines t)
|
||||
{
|
||||
if (t == null) return 0;
|
||||
var model = db.Machines.ToList().FirstOrDefault(item => item.Name.Trim() == t.Name);
|
||||
if (model == null) return 0;
|
||||
model.DispenseDyelot = t.DispenseDyelot;
|
||||
model.DyeDispenseDyelot = t.DyeDispenseDyelot;
|
||||
model.ChemicalStation = t.ChemicalStation;
|
||||
model.ChemicalCallOff = t.ChemicalCallOff;
|
||||
model.ChemicalCallOff2 = t.ChemicalCallOff2;
|
||||
model.ChemicalState = t.ChemicalState;
|
||||
model.ChemicalState2 = t.ChemicalState2;
|
||||
model.DyeCallOff = t.DyeCallOff;
|
||||
model.DyeState = t.DyeState;
|
||||
model.PowderCallOff = t.PowderCallOff;
|
||||
model.PowderState = t.PowderState;
|
||||
int count = db.SaveChanges();
|
||||
return count;
|
||||
}
|
||||
|
||||
public int Update2(Machines t)
|
||||
{
|
||||
if (t == null) return 0;
|
||||
var model = db.Machines.ToList().FirstOrDefault(item => item.Name.Trim() == t.Name);
|
||||
if (model == null) return 0;
|
||||
model.ChemicalCallOff = t.ChemicalCallOff;
|
||||
model.ChemicalCallOff2 = t.ChemicalCallOff2;
|
||||
model.ChemicalState = t.ChemicalState;
|
||||
model.ChemicalState2 = t.ChemicalState2;
|
||||
int count = db.SaveChanges();
|
||||
return count;
|
||||
}
|
||||
|
||||
public int Update3(Machines t)
|
||||
{
|
||||
if (t == null) return 0;
|
||||
var model = db.Machines.ToList().FirstOrDefault(item => item.Name.Trim() == t.Name);
|
||||
if (model == null) return 0;
|
||||
model.DyeCallOff = t.DyeCallOff;
|
||||
model.DyeState = t.DyeState;
|
||||
int count = db.SaveChanges();
|
||||
return count;
|
||||
}
|
||||
|
||||
public int Update4(Machines t)
|
||||
{
|
||||
if (t == null) return 0;
|
||||
var model = db.Machines.ToList().FirstOrDefault(item => item.Name.Trim() == t.Name);
|
||||
if (model == null) return 0;
|
||||
model.PowderCallOff = t.PowderCallOff;
|
||||
model.PowderState = t.PowderState;
|
||||
int count = db.SaveChanges();
|
||||
return count;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,28 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,28 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
+5
-178
@@ -86,198 +86,28 @@
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="AuxDslvQueue.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="AuxDslvQueueHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="BucketCrane.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="BucketCraneHistory.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="DBRDetail.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="DissolveArt.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="DissolveArtHistory.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="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="DyelotsBulkedRecipeProvider.cs" />
|
||||
<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="DyelotsProvider.cs" />
|
||||
<Compile Include="EventList.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="IProvider.cs" />
|
||||
<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="MachinesHistoryOld.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="MachinesProvider.cs" />
|
||||
<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="PipeRefill.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="PipeRefillHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Pipes.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="PipesProvider.cs" />
|
||||
<Compile Include="Product.cs">
|
||||
<DependentUpon>SQL_Ti.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="ProductLocation.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="ProductLocationHistory.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="ProductProvider.cs" />
|
||||
<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="RecipeDetail.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Recipes.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="ScheduledDyelot.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="ScheduledDyelotHistory.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>
|
||||
@@ -308,9 +138,6 @@
|
||||
<DesignTime>True</DesignTime>
|
||||
<DependentUpon>SQL_Ti.edmx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="TagShelf.cs">
|
||||
<DependentUpon>SQL_BD.tt</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="UserAccount.cs">
|
||||
<DependentUpon>SQL_Ti.tt</DependentUpon>
|
||||
</Compile>
|
||||
@@ -322,10 +149,6 @@
|
||||
</None>
|
||||
<None Include="App.Config" />
|
||||
<None Include="packages.config" />
|
||||
<EntityDeploy Include="SQL_Ti.edmx">
|
||||
<Generator>EntityModelCodeGenerator</Generator>
|
||||
<LastGenOutput>SQL_Ti.Designer.cs</LastGenOutput>
|
||||
</EntityDeploy>
|
||||
<EntityDeploy Include="SQL_BD.edmx">
|
||||
<Generator>EntityModelCodeGenerator</Generator>
|
||||
<LastGenOutput>SQL_BD.Designer.cs</LastGenOutput>
|
||||
@@ -333,6 +156,10 @@
|
||||
<None Include="SQL_BD.edmx.diagram">
|
||||
<DependentUpon>SQL_BD.edmx</DependentUpon>
|
||||
</None>
|
||||
<EntityDeploy Include="SQL_Ti.edmx">
|
||||
<Generator>EntityModelCodeGenerator</Generator>
|
||||
<LastGenOutput>SQL_Ti.Designer.cs</LastGenOutput>
|
||||
</EntityDeploy>
|
||||
<None Include="SQL_Ti.edmx.diagram">
|
||||
<DependentUpon>SQL_Ti.edmx</DependentUpon>
|
||||
</None>
|
||||
|
||||
@@ -1,33 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 Device { 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; }
|
||||
}
|
||||
}
|
||||
@@ -1,33 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 Device { 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; }
|
||||
}
|
||||
}
|
||||
@@ -1,29 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class PipeRefill
|
||||
{
|
||||
public string ProductCode { get; set; }
|
||||
public string ProductName { get; set; }
|
||||
public Nullable<int> ProductType { get; set; }
|
||||
public string ProductLot { get; set; }
|
||||
public string Dispenser { get; set; }
|
||||
public Nullable<int> No { get; set; }
|
||||
public Nullable<double> Qty { get; set; }
|
||||
public Nullable<double> Percentage { get; set; }
|
||||
public Nullable<System.DateTime> RefillTime { get; set; }
|
||||
public Nullable<System.DateTime> AlarmTime { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,29 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class PipeRefillHistory
|
||||
{
|
||||
public string ProductCode { get; set; }
|
||||
public string ProductName { get; set; }
|
||||
public Nullable<int> ProductType { get; set; }
|
||||
public string ProductLot { get; set; }
|
||||
public string Dispenser { get; set; }
|
||||
public Nullable<int> No { get; set; }
|
||||
public Nullable<double> Qty { get; set; }
|
||||
public Nullable<double> Percentage { get; set; }
|
||||
public Nullable<System.DateTime> RefillTime { get; set; }
|
||||
public Nullable<System.DateTime> AlarmTime { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -16,8 +16,6 @@ namespace Models
|
||||
{
|
||||
public string ProductCode { get; set; }
|
||||
public string ProductName { get; set; }
|
||||
public Nullable<int> ProductType { get; set; }
|
||||
public string ProductLot { get; set; }
|
||||
public string Dispenser { get; set; }
|
||||
public Nullable<int> Enabled { get; set; }
|
||||
public Nullable<int> No { get; set; }
|
||||
|
||||
@@ -0,0 +1,49 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Models
|
||||
{
|
||||
public class PipesProvider : IProvider<Pipes>
|
||||
{
|
||||
private readonly BatchDyeingCentralEntities db = new BatchDyeingCentralEntities();
|
||||
|
||||
public int Delete(Pipes t)
|
||||
{
|
||||
if (t == null) return 0;
|
||||
var model = db.Pipes.ToList().FirstOrDefault(item => t.ProductCode == item.ProductCode);
|
||||
if (model == null) return 0;
|
||||
db.Pipes.Remove(model);
|
||||
int count = db.SaveChanges();
|
||||
return count;
|
||||
}
|
||||
|
||||
public int Insert(Pipes t)
|
||||
{
|
||||
if (t == null) return 0;
|
||||
if (String.IsNullOrEmpty(t.ProductCode)) return 0;
|
||||
db.Pipes.Add(t);
|
||||
int count = db.SaveChanges();
|
||||
return count;
|
||||
}
|
||||
|
||||
public List<Pipes> Select()
|
||||
{
|
||||
string sqlselect = "select * from Pipes ";
|
||||
return db.Pipes.SqlQuery(sqlselect).ToList();
|
||||
}
|
||||
|
||||
public List<Pipes> Selectsql(Pipes t)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
public int Update(Pipes t)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
+11
-45
@@ -16,63 +16,29 @@ namespace Models
|
||||
{
|
||||
public string ProductCode { get; set; }
|
||||
public string ProductName { get; set; }
|
||||
public Nullable<double> Price { get; set; }
|
||||
public Nullable<double> Deduct { get; set; }
|
||||
public Nullable<double> FullWeight { get; set; }
|
||||
public Nullable<int> LampPosition { get; set; }
|
||||
public string TablePosition { get; set; }
|
||||
public string AREA { get; set; }
|
||||
public Nullable<double> SafetyStock { get; set; }
|
||||
public Nullable<int> ProductUnit { get; set; }
|
||||
public Nullable<int> ProductType { get; set; }
|
||||
public Nullable<int> ProductClass { get; set; }
|
||||
public Nullable<double> CurrentStock { get; set; }
|
||||
public Nullable<int> Color { get; set; }
|
||||
public string ProductLot { get; set; }
|
||||
public Nullable<double> FullWeight { get; set; }
|
||||
public Nullable<int> ProductUnit { get; set; }
|
||||
public Nullable<double> SafetyStock { get; set; }
|
||||
public Nullable<double> Price { get; set; }
|
||||
public Nullable<double> CurrentStock { get; set; }
|
||||
public Nullable<double> Deduct { get; set; }
|
||||
public Nullable<System.DateTime> RplDate { get; set; }
|
||||
public Nullable<System.DateTime> UsedDate { get; set; }
|
||||
public string CuMonth { get; set; }
|
||||
public Nullable<double> LaStock { get; set; }
|
||||
public Nullable<double> ThStock { get; set; }
|
||||
public Nullable<double> ThUsed { get; set; }
|
||||
public Nullable<int> Color { get; set; }
|
||||
public Nullable<double> LastTime { get; set; }
|
||||
public Nullable<double> CalTime { get; set; }
|
||||
public Nullable<int> BackflowTime { get; set; }
|
||||
public Nullable<int> Tol_G { get; set; }
|
||||
public Nullable<int> Tol_P { get; set; }
|
||||
public Nullable<int> Alarm { get; set; }
|
||||
public Nullable<int> Change_Bucket { get; set; }
|
||||
public Nullable<int> Small_Volume_by_manual { get; set; }
|
||||
public Nullable<int> Target_Weight { get; set; }
|
||||
public Nullable<int> Pre_Weight { get; set; }
|
||||
public Nullable<int> One_Sec { get; set; }
|
||||
public Nullable<int> GetscalTime { get; set; }
|
||||
public Nullable<int> DelayOpenValve { get; set; }
|
||||
public string ValveMap { get; set; }
|
||||
public string PumpMap { get; set; }
|
||||
public Nullable<int> Includepump { get; set; }
|
||||
public Nullable<int> Once_minimum_weight { get; set; }
|
||||
public Nullable<int> Once_minimum_max_weight { get; set; }
|
||||
public Nullable<int> Once_minimum_time { get; set; }
|
||||
public string Res_S1 { get; set; }
|
||||
public string Res_S2 { get; set; }
|
||||
public string Res_S3 { get; set; }
|
||||
public string Res_S4 { get; set; }
|
||||
public Nullable<int> Res_I1 { get; set; }
|
||||
public Nullable<int> Res_I2 { get; set; }
|
||||
public Nullable<int> Res_I3 { get; set; }
|
||||
public Nullable<int> Res_I4 { get; set; }
|
||||
public Nullable<double> Res_F1 { get; set; }
|
||||
public Nullable<double> Res_F2 { get; set; }
|
||||
public Nullable<double> Res_F3 { get; set; }
|
||||
public Nullable<double> Res_F4 { get; set; }
|
||||
public string Batch_NO { get; set; }
|
||||
public Nullable<int> LampPosition { get; set; }
|
||||
public string TablePosition { get; set; }
|
||||
public string Area { get; set; }
|
||||
public Nullable<double> Concentration { get; set; }
|
||||
public string Batch_NO { get; set; }
|
||||
public Nullable<int> Pump { get; set; }
|
||||
public Nullable<int> PRODUCT_KIND { get; set; }
|
||||
public string SUPPLIER { get; set; }
|
||||
public Nullable<System.DateTime> PRODUCT_MODIFY_DATE { get; set; }
|
||||
public double GRAVITY { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,30 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class ProductLocation
|
||||
{
|
||||
public string ProductCode { get; set; }
|
||||
public string ProductName { get; set; }
|
||||
public string Type { get; set; }
|
||||
public string Dispenser { get; set; }
|
||||
public Nullable<int> Position { get; set; }
|
||||
public string TablePosition { get; set; }
|
||||
public Nullable<System.DateTime> StockDate { get; set; }
|
||||
public Nullable<double> StockUsage { get; set; }
|
||||
public Nullable<double> StockOnHand { get; set; }
|
||||
public string Alarm { get; set; }
|
||||
public Nullable<System.DateTime> AlarmTime { get; set; }
|
||||
public Nullable<int> Enabled { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,31 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class ProductLocationHistory
|
||||
{
|
||||
public string ProductCode { get; set; }
|
||||
public string ProductName { get; set; }
|
||||
public string Type { get; set; }
|
||||
public string Dispenser { get; set; }
|
||||
public Nullable<int> Position { get; set; }
|
||||
public string TablePosition { get; set; }
|
||||
public Nullable<System.DateTime> StockDate { get; set; }
|
||||
public Nullable<double> StockUsage { get; set; }
|
||||
public Nullable<double> StockOnHand { get; set; }
|
||||
public string Alarm { get; set; }
|
||||
public Nullable<System.DateTime> AlarmTime { get; set; }
|
||||
public Nullable<int> Enabled { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -12,7 +12,7 @@ namespace Models
|
||||
public int Delete(Product t)//删除
|
||||
{
|
||||
if (t == null) return 0;
|
||||
var model = db.Product.ToList().FirstOrDefault(item => t.ProductCode == item.ProductCode);
|
||||
var model = db.Product.ToList().FirstOrDefault(item => t.ProductCode == item.ProductCode.Trim());
|
||||
if (model == null) return 0;
|
||||
db.Product.Remove(model);
|
||||
int count = db.SaveChanges();
|
||||
@@ -24,12 +24,13 @@ namespace Models
|
||||
if (t == null) return 0;
|
||||
if (String.IsNullOrEmpty(t.ProductCode)) return 0;
|
||||
db.Product.Add(t);
|
||||
int counti = db.SaveChanges();
|
||||
return counti;
|
||||
int count = db.SaveChanges();
|
||||
return count;
|
||||
}
|
||||
|
||||
public List<Product> Select()
|
||||
{
|
||||
//var c = db.Product.SqlQuery("select * from Product").ToList();
|
||||
return db.Product.SqlQuery("select * from Product").ToList();//查询
|
||||
}
|
||||
|
||||
@@ -47,13 +48,30 @@ namespace Models
|
||||
return db.Product.SqlQuery("select * from Product where ProductType = 2").ToList();//类型2查询
|
||||
}
|
||||
|
||||
public List<Product> Selects3()
|
||||
{
|
||||
return db.Product.SqlQuery("select * from Product where ProductType = 3").ToList();//类型2查询
|
||||
}
|
||||
|
||||
public List<Product> Selectsql(Product t)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
string sqlselect = "select * from Product Where ProductCode = " + "'" + t.ProductCode.ToString() + "'";
|
||||
return db.Product.SqlQuery(sqlselect).ToList();
|
||||
}
|
||||
public int Update(Product t)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
if (t == null) return 0;
|
||||
var model = db.Product.ToList().FirstOrDefault(item => item.ProductCode.Trim() == t.ProductCode);
|
||||
if (model == null) return 0;
|
||||
model.Color = t.Color;
|
||||
model.Price = t.Price;
|
||||
model.SUPPLIER = t.SUPPLIER;
|
||||
model.ProductName = t.ProductName;
|
||||
model.GRAVITY = t.GRAVITY;
|
||||
model.Concentration = t.Concentration;
|
||||
model.ProductType = t.ProductType;
|
||||
int count = db.SaveChanges();
|
||||
return count;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,32 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 string Source { get; set; }
|
||||
public string Dest { get; set; }
|
||||
public string ProductCode { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,30 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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 string ProductCode { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,29 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,30 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class RecipeDetail
|
||||
{
|
||||
public string RcpCode { get; set; }
|
||||
public string ProductCode { get; set; }
|
||||
public string ProductName { get; set; }
|
||||
public Nullable<double> Conc { get; set; }
|
||||
public Nullable<int> HostRead { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,22 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class Recipes
|
||||
{
|
||||
public string RcpCode { get; set; }
|
||||
public string RcpName { get; set; }
|
||||
public string Unit { get; set; }
|
||||
public Nullable<System.DateTime> Created { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -25,67 +25,9 @@ namespace Models
|
||||
throw new UnintentionalCodeFirstException();
|
||||
}
|
||||
|
||||
public virtual DbSet<DBRDetail> DBRDetail { get; set; }
|
||||
public virtual DbSet<DyelotHead> DyelotHead { get; set; }
|
||||
public virtual DbSet<Dyelots> Dyelots { get; set; }
|
||||
public virtual DbSet<DyelotsBulkedRecipe> DyelotsBulkedRecipe { get; set; }
|
||||
public virtual DbSet<Machines> Machines { get; set; }
|
||||
public virtual DbSet<MachineState> MachineState { get; set; }
|
||||
public virtual DbSet<SchedulingLog> SchedulingLog { get; set; }
|
||||
public virtual DbSet<AuxDslvQueue> AuxDslvQueue { get; set; }
|
||||
public virtual DbSet<AuxDslvQueueHistory> AuxDslvQueueHistory { get; set; }
|
||||
public virtual DbSet<BucketCrane> BucketCrane { get; set; }
|
||||
public virtual DbSet<BucketCraneHistory> BucketCraneHistory { 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<DissolveArt> DissolveArt { get; set; }
|
||||
public virtual DbSet<DissolveArtHistory> DissolveArtHistory { 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<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<MachinesHistoryOld> MachinesHistoryOld { 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<PipeRefill> PipeRefill { get; set; }
|
||||
public virtual DbSet<PipeRefillHistory> PipeRefillHistory { get; set; }
|
||||
public virtual DbSet<Pipes> Pipes { get; set; }
|
||||
public virtual DbSet<ProductLocation> ProductLocation { get; set; }
|
||||
public virtual DbSet<ProductLocationHistory> ProductLocationHistory { get; set; }
|
||||
public virtual DbSet<RecipeDeduct> RecipeDeduct { get; set; }
|
||||
public virtual DbSet<RecipeDeductHistory> RecipeDeductHistory { get; set; }
|
||||
public virtual DbSet<RecipeDetail> RecipeDetail { get; set; }
|
||||
public virtual DbSet<Recipes> Recipes { 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<ScheduledDyelot> ScheduledDyelot { get; set; }
|
||||
public virtual DbSet<ScheduledDyelotHistory> ScheduledDyelotHistory { get; set; }
|
||||
public virtual DbSet<Shelf> Shelf { get; set; }
|
||||
public virtual DbSet<TagShelf> TagShelf { get; set; }
|
||||
}
|
||||
}
|
||||
+77
-4787
File diff suppressed because it is too large.
Load diff
@@ -4,69 +4,11 @@
|
||||
<edmx:Designer xmlns="http://schemas.microsoft.com/ado/2009/11/edmx">
|
||||
<!-- Diagram content (shape and connector positions) -->
|
||||
<edmx:Diagrams>
|
||||
<Diagram DiagramId="b36b8a03bd1f4d3fa1db2360f80bde25" Name="Diagram1" ZoomLevel="75">
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DBRDetail" Width="1.5" PointX="0.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotHead" Width="1.5" PointX="2.75" PointY="0.75" IsExpanded="true" />
|
||||
<Diagram DiagramId="b36b8a03bd1f4d3fa1db2360f80bde25" Name="Diagram1" ZoomLevel="81">
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Dyelots" Width="1.5" PointX="4.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotsBulkedRecipe" Width="1.5" PointX="6.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Machines" Width="1.5" PointX="8.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.MachineState" Width="1.5" PointX="10.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.SchedulingLog" Width="1.5" PointX="10.75" PointY="6.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.AuxDslvQueue" Width="1.5" PointX="10.75" PointY="10.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.AuxDslvQueueHistory" Width="1.5" PointX="0.75" PointY="11.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.BucketCrane" Width="1.5" PointX="2.75" PointY="11.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.BucketCraneHistory" Width="1.5" PointX="12.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.BucketInfo" Width="1.5" PointX="12.75" PointY="4.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.BucketShelf" Width="1.5" PointX="12.75" PointY="7.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.BucketShelfHistory" Width="1.5" PointX="12.75" PointY="12.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.BucketShelfQueue" Width="1.5" PointX="14.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.BucketShelfQueueHistory" Width="1.5" PointX="14.75" PointY="4.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.CleanDevice" Width="1.5" PointX="14.75" PointY="8.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DispenserEvent" Width="1.5" PointX="14.75" PointY="11.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DispenserLifeStatus" Width="1.5" PointX="0.75" PointY="15.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Dispensers" Width="1.5" PointX="2.75" PointY="15.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DispenserUtilization" Width="1.5" PointX="4.75" PointY="15.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DissolveArt" Width="1.5" PointX="6.75" PointY="15.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DissolveArtHistory" Width="1.5" PointX="8.75" PointY="15.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotBuckets" Width="1.5" PointX="16.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotBucketsHistory" Width="1.5" PointX="16.75" PointY="4.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotBucketSummary" Width="1.5" PointX="16.75" PointY="8.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotDetail" Width="1.5" PointX="16.75" PointY="11.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotDslvQueue" Width="1.5" PointX="10.75" PointY="17.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotDslvQueueHistory" Width="1.5" PointX="12.75" PointY="17.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotsBatch" Width="1.5" PointX="14.75" PointY="17.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotsBulkedRecipeHistory" Width="1.5" PointX="16.75" PointY="17.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotsHistory" Width="1.5" PointX="18.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotsInAuto" Width="1.5" PointX="18.75" PointY="9.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.DyelotsInAutoHistory" Width="1.5" PointX="18.75" PointY="13.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.EventList" Width="1.5" PointX="18.75" PointY="17.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.LA571Tanks" Width="1.5" PointX="4.75" PointY="19.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.LabDyeDslvQueue" Width="1.5" PointX="6.75" PointY="19.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.LabDyeDslvQueueHistory" Width="1.5" PointX="20.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.MachinesHistory" Width="1.5" PointX="20.75" PointY="4.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.MachinesHistoryOld" Width="1.5" PointX="20.75" PointY="12.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.MachineStateHistory" Width="1.5" PointX="18.75" PointY="20.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.ManualWeightQueue" Width="1.5" PointX="20.75" PointY="19.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.ManualWeightQueueHistory" Width="1.5" PointX="0.75" PointY="21.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.PartsStatus" Width="1.5" PointX="8.75" PointY="21.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.PartsStatusHistory" Width="1.5" PointX="10.75" PointY="21.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.PipeRefill" Width="1.5" PointX="22.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.PipeRefillHistory" Width="1.5" PointX="2.75" PointY="22.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Pipes" Width="1.5" PointX="22.75" PointY="4.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.ProductLocation" Width="1.5" PointX="22.75" PointY="9.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.ProductLocationHistory" Width="1.5" PointX="22.75" PointY="13.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.RecipeDeduct" Width="1.5" PointX="22.75" PointY="18.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.RecipeDeductHistory" Width="1.5" PointX="22.75" PointY="22.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.RecipeDetail" Width="1.5" PointX="4.75" PointY="23.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Recipes" Width="1.5" PointX="12.75" PointY="23.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.RFIDRecordQueue" Width="1.5" PointX="24.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.RFIDRecordQueueHistory" Width="1.5" PointX="24.75" PointY="5.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.SampleDyeDslvQueue" Width="1.5" PointX="24.75" PointY="9.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.SampleDyeDslvQueueHistory" Width="1.5" PointX="24.75" PointY="13.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.ScheduledDyelot" Width="1.5" PointX="24.75" PointY="17.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.ScheduledDyelotHistory" Width="1.5" PointX="24.75" PointY="21.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Shelf" Width="1.5" PointX="24.75" PointY="25.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.TagShelf" Width="1.5" PointX="26.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Machines" Width="1.5" PointX="0.75" PointY="0.75" />
|
||||
<EntityTypeShape EntityType="BatchDyeingCentralModel.Pipes" Width="1.5" PointX="3.375" PointY="4.75" />
|
||||
</Diagram>
|
||||
</edmx:Diagrams>
|
||||
</edmx:Designer>
|
||||
|
||||
@@ -25,7 +25,7 @@ namespace Models
|
||||
throw new UnintentionalCodeFirstException();
|
||||
}
|
||||
|
||||
public virtual DbSet<Product> Product { get; set; }
|
||||
public virtual DbSet<UserAccount> UserAccount { get; set; }
|
||||
public virtual DbSet<Product> Product { get; set; }
|
||||
}
|
||||
}
|
||||
Generated
+1
-1
@@ -1,4 +1,4 @@
|
||||
// 为模型“C:\Users\24018\source\repos\Audit_APP\Models\SQL_Ti.edmx”启用了 T4 代码生成。
|
||||
// 为模型“C:\Users\尚彩-沈忱\source\repos\Audit_APP\Models\SQL_Ti.edmx”启用了 T4 代码生成。
|
||||
// 要启用旧代码生成功能,请将“代码生成策略”设计器属性的值
|
||||
// 更改为“旧的 ObjectContext”。当在设计器中打开该模型时,此属性会出现在
|
||||
// “属性”窗口中。
|
||||
|
||||
+79
-296
@@ -5,174 +5,37 @@
|
||||
<!-- SSDL content -->
|
||||
<edmx:StorageModels>
|
||||
<Schema Namespace="TicketModel.Store" Provider="System.Data.SqlClient" ProviderManifestToken="2012" Alias="Self" xmlns:store="http://schemas.microsoft.com/ado/2007/12/edm/EntityStoreSchemaGenerator" xmlns:customannotation="http://schemas.microsoft.com/ado/2013/11/edm/customannotation" xmlns="http://schemas.microsoft.com/ado/2009/11/edm/ssdl">
|
||||
<!--生成过程中发现错误:
|
||||
警告 6013: 表/视图“Ticket.dbo.Authority”未定义主键,并且无法推断有效的主键。已排除了此表/视图。若要使用实体,将需要检查您的架构、添加正确的键并取消对实体的注释。
|
||||
<EntityType Name="Authority">
|
||||
<Property Name="tmp_field" Type="varchar" MaxLength="1" />
|
||||
<Property Name="GROUP_CODE" Type="varchar" MaxLength="50" />
|
||||
<Property Name="FM_30" Type="varchar" MaxLength="50" />
|
||||
<Property Name="FM_31" Type="varchar" MaxLength="50" />
|
||||
<Property Name="FM_32" Type="varchar" MaxLength="50" />
|
||||
</EntityType>-->
|
||||
<!--生成过程中发现错误:
|
||||
警告 6002: 表/视图“Ticket.dbo.CHEMICAL_QUEUE”未定义主键。已推断出该键,并将定义创建为只读的表/视图。-->
|
||||
<!--生成过程中发现错误:
|
||||
警告 6002: 表/视图“Ticket.dbo.DYESTUFF_QUEUE”未定义主键。已推断出该键,并将定义创建为只读的表/视图。-->
|
||||
<!--生成过程中发现错误:
|
||||
警告 6013: 表/视图“Ticket.dbo.GroupAccount”未定义主键,并且无法推断有效的主键。已排除了此表/视图。若要使用实体,将需要检查您的架构、添加正确的键并取消对实体的注释。
|
||||
<EntityType Name="GroupAccount">
|
||||
<Property Name="tmp_field" Type="varchar" MaxLength="1" />
|
||||
<Property Name="GROUP_CODE" Type="varchar" MaxLength="50" />
|
||||
<Property Name="GROUP_LEVEL" Type="int" />
|
||||
</EntityType>-->
|
||||
<!--生成过程中发现错误:
|
||||
警告 6002: 表/视图“Ticket.dbo.JOBTKT”未定义主键。已推断出该键,并将定义创建为只读的表/视图。-->
|
||||
<!--生成过程中发现错误:
|
||||
警告 6002: 表/视图“Ticket.dbo.POWDER_QUEUE”未定义主键。已推断出该键,并将定义创建为只读的表/视图。-->
|
||||
<EntityType Name="Product">
|
||||
<Key>
|
||||
<PropertyRef Name="ProductCode" />
|
||||
</Key>
|
||||
<Property Name="ProductCode" Type="nchar" MaxLength="20" Nullable="false" />
|
||||
<Property Name="ProductCode" Type="nchar" MaxLength="30" Nullable="false" />
|
||||
<Property Name="ProductName" Type="nchar" MaxLength="50" />
|
||||
<Property Name="Price" Type="float" />
|
||||
<Property Name="Deduct" Type="float" />
|
||||
<Property Name="FullWeight" Type="float" />
|
||||
<Property Name="LampPosition" Type="int" />
|
||||
<Property Name="TablePosition" Type="nchar" MaxLength="5" />
|
||||
<Property Name="AREA" Type="nchar" MaxLength="5" />
|
||||
<Property Name="SafetyStock" Type="float" />
|
||||
<Property Name="ProductUnit" Type="int" />
|
||||
<Property Name="ProductType" Type="int" />
|
||||
<Property Name="ProductClass" Type="int" />
|
||||
<Property Name="CurrentStock" Type="float" />
|
||||
<Property Name="Color" Type="int" />
|
||||
<Property Name="ProductLot" Type="nchar" MaxLength="30" />
|
||||
<Property Name="FullWeight" Type="float" />
|
||||
<Property Name="ProductUnit" Type="int" />
|
||||
<Property Name="SafetyStock" Type="float" />
|
||||
<Property Name="Price" Type="float" />
|
||||
<Property Name="CurrentStock" Type="float" />
|
||||
<Property Name="Deduct" Type="float" />
|
||||
<Property Name="RplDate" Type="datetime" />
|
||||
<Property Name="UsedDate" Type="datetime" />
|
||||
<Property Name="CuMonth" Type="nchar" MaxLength="2" />
|
||||
<Property Name="LaStock" Type="float" />
|
||||
<Property Name="ThStock" Type="float" />
|
||||
<Property Name="ThUsed" Type="float" />
|
||||
<Property Name="Color" Type="int" />
|
||||
<Property Name="LastTime" Type="float" />
|
||||
<Property Name="CalTime" Type="float" />
|
||||
<Property Name="BackflowTime" Type="int" />
|
||||
<Property Name="Tol_G" Type="int" />
|
||||
<Property Name="Tol_P" Type="int" />
|
||||
<Property Name="Alarm" Type="int" />
|
||||
<Property Name="Change_Bucket" Type="int" />
|
||||
<Property Name="Small_Volume_by_manual" Type="int" />
|
||||
<Property Name="Target_Weight" Type="int" />
|
||||
<Property Name="Pre_Weight" Type="int" />
|
||||
<Property Name="One_Sec" Type="int" />
|
||||
<Property Name="GetscalTime" Type="int" />
|
||||
<Property Name="DelayOpenValve" Type="int" />
|
||||
<Property Name="ValveMap" Type="nchar" MaxLength="5" />
|
||||
<Property Name="PumpMap" Type="nchar" MaxLength="20" />
|
||||
<Property Name="Includepump" Type="int" />
|
||||
<Property Name="Once_minimum_weight" Type="int" />
|
||||
<Property Name="Once_minimum_max_weight" Type="int" />
|
||||
<Property Name="Once_minimum_time" Type="int" />
|
||||
<Property Name="Res_S1" Type="nchar" MaxLength="30" />
|
||||
<Property Name="Res_S2" Type="nchar" MaxLength="30" />
|
||||
<Property Name="Res_S3" Type="nchar" MaxLength="30" />
|
||||
<Property Name="Res_S4" Type="nchar" MaxLength="30" />
|
||||
<Property Name="Res_I1" Type="int" />
|
||||
<Property Name="Res_I2" Type="int" />
|
||||
<Property Name="Res_I3" Type="int" />
|
||||
<Property Name="Res_I4" Type="int" />
|
||||
<Property Name="Res_F1" Type="float" />
|
||||
<Property Name="Res_F2" Type="float" />
|
||||
<Property Name="Res_F3" Type="float" />
|
||||
<Property Name="Res_F4" Type="float" />
|
||||
<Property Name="Batch_NO" Type="varchar" MaxLength="30" />
|
||||
<Property Name="LampPosition" Type="int" />
|
||||
<Property Name="TablePosition" Type="nchar" MaxLength="5" />
|
||||
<Property Name="Area" Type="nchar" MaxLength="5" />
|
||||
<Property Name="Concentration" Type="float" />
|
||||
<Property Name="Batch_NO" Type="varchar" MaxLength="30" />
|
||||
<Property Name="Pump" Type="int" />
|
||||
<Property Name="PRODUCT_KIND" Type="int" />
|
||||
<Property Name="SUPPLIER" Type="varchar" MaxLength="48" />
|
||||
<Property Name="PRODUCT_MODIFY_DATE" Type="datetime" />
|
||||
<Property Name="SUPPLIER" Type="varchar" MaxLength="50" />
|
||||
<Property Name="GRAVITY" Type="float" Nullable="false" />
|
||||
<Property Name="UserAccount" Type="varchar" MaxLength="30" />
|
||||
</EntityType>
|
||||
<!--生成过程中发现错误:
|
||||
警告 6013: 表/视图“Ticket.dbo.ProductKind”未定义主键,并且无法推断有效的主键。已排除了此表/视图。若要使用实体,将需要检查您的架构、添加正确的键并取消对实体的注释。
|
||||
<EntityType Name="ProductKind">
|
||||
<Property Name="tmp_field" Type="varchar" MaxLength="1" />
|
||||
<Property Name="KIND_NAME" Type="nvarchar" MaxLength="50" />
|
||||
<Property Name="ORDER_NO" Type="int" />
|
||||
</EntityType>-->
|
||||
<!--生成过程中发现错误:
|
||||
警告 6002: 表/视图“Ticket.dbo.REMOTETERMINAL”未定义主键。已推断出该键,并将定义创建为只读的表/视图。-->
|
||||
<!--生成过程中发现错误:
|
||||
警告 6002: 表/视图“Ticket.dbo.TEMPCHEMICALTKT”未定义主键。已推断出该键,并将定义创建为只读的表/视图。-->
|
||||
<!--生成过程中发现错误:
|
||||
警告 6002: 表/视图“Ticket.dbo.TEMPDYESTUFFTKT”未定义主键。已推断出该键,并将定义创建为只读的表/视图。-->
|
||||
<!--生成过程中发现错误:
|
||||
警告 6002: 表/视图“Ticket.dbo.TEMPPOWDER”未定义主键。已推断出该键,并将定义创建为只读的表/视图。-->
|
||||
<!--生成过程中发现错误:
|
||||
警告 6002: 表/视图“Ticket.dbo.TICKET_DETAIL”未定义主键。已推断出该键,并将定义创建为只读的表/视图。-->
|
||||
<!--生成过程中发现错误:
|
||||
警告 6013: 表/视图“Ticket.dbo.TICKET_TITLE”未定义主键,并且无法推断有效的主键。已排除了此表/视图。若要使用实体,将需要检查您的架构、添加正确的键并取消对实体的注释。
|
||||
<EntityType Name="TICKET_TITLE">
|
||||
<Property Name="ID_NO" Type="char" MaxLength="30" />
|
||||
<Property Name="ID_TYPE" Type="char" MaxLength="1" />
|
||||
<Property Name="PROCEDURE_CODE" Type="char" MaxLength="24" />
|
||||
<Property Name="TOTAL_STEP" Type="int" />
|
||||
<Property Name="TICKET" Type="char" MaxLength="30" />
|
||||
<Property Name="MACHINE_NO" Type="char" MaxLength="30" />
|
||||
<Property Name="CUSTOMER_CODE" Type="char" MaxLength="30" />
|
||||
<Property Name="CUSTOMER_NAME" Type="char" MaxLength="30" />
|
||||
<Property Name="PROGRAM_CODE" Type="char" MaxLength="30" />
|
||||
<Property Name="PROGRAM_NAME" Type="char" MaxLength="30" />
|
||||
<Property Name="FABRIC_CODE" Type="char" MaxLength="30" />
|
||||
<Property Name="FABRIC_NAME" Type="char" MaxLength="30" />
|
||||
<Property Name="GRAMS_YARD" Type="float" />
|
||||
<Property Name="VOLUME" Type="float" />
|
||||
<Property Name="TOTAL_WT" Type="float" />
|
||||
<Property Name="TOTAL_LENGTH" Type="float" />
|
||||
<Property Name="COLOR_NAME" Type="char" MaxLength="30" />
|
||||
<Property Name="ORDER_NO" Type="char" MaxLength="30" />
|
||||
<Property Name="PILL" Type="char" MaxLength="30" />
|
||||
<Property Name="UNIT" Type="char" MaxLength="30" />
|
||||
<Property Name="BATCH" Type="char" MaxLength="30" />
|
||||
<Property Name="PRODUCT_LOT" Type="char" MaxLength="30" />
|
||||
<Property Name="CONC" Type="char" MaxLength="30" />
|
||||
<Property Name="PRICE" Type="char" MaxLength="30" />
|
||||
<Property Name="SHEET" Type="char" MaxLength="30" />
|
||||
<Property Name="SHADE" Type="char" MaxLength="30" />
|
||||
<Property Name="TOTAL_VALUE" Type="char" MaxLength="30" />
|
||||
<Property Name="YARN" Type="char" MaxLength="30" />
|
||||
<Property Name="USER25" Type="char" MaxLength="30" />
|
||||
<Property Name="USER26" Type="char" MaxLength="30" />
|
||||
<Property Name="USER27" Type="char" MaxLength="30" />
|
||||
<Property Name="USER28" Type="char" MaxLength="30" />
|
||||
<Property Name="USER29" Type="char" MaxLength="30" />
|
||||
<Property Name="USER30" Type="char" MaxLength="30" />
|
||||
<Property Name="ADD_ID_NO" Type="char" MaxLength="30" />
|
||||
<Property Name="ADD_FREQUENCY" Type="int" />
|
||||
<Property Name="CreateTime" Type="datetime" />
|
||||
<Property Name="UserAccount" Type="varchar" MaxLength="30" />
|
||||
<Property Name="lldid" Type="int" />
|
||||
<Property Name="Redye" Type="int" />
|
||||
<Property Name="Industry" Type="int" />
|
||||
<Property Name="UserCode" Type="char" MaxLength="10" />
|
||||
<Property Name="TotalLength" Type="float" />
|
||||
<Property Name="USER1" Type="varchar" MaxLength="30" />
|
||||
<Property Name="USER2" Type="varchar" MaxLength="30" />
|
||||
<Property Name="USER3" Type="varchar" MaxLength="30" />
|
||||
<Property Name="USER4" Type="varchar" MaxLength="30" />
|
||||
<Property Name="USER5" Type="varchar" MaxLength="30" />
|
||||
<Property Name="USER6" Type="varchar" MaxLength="30" />
|
||||
<Property Name="USER7" Type="varchar" MaxLength="30" />
|
||||
<Property Name="USER8" Type="varchar" MaxLength="30" />
|
||||
<Property Name="USER9" Type="varchar" MaxLength="30" />
|
||||
<Property Name="USER10" Type="varchar" MaxLength="30" />
|
||||
<Property Name="FormTypeName" Type="nvarchar" MaxLength="32" />
|
||||
</EntityType>-->
|
||||
<!--生成过程中发现错误:
|
||||
警告 6002: 表/视图“Ticket.dbo.TicketSerial”未定义主键。已推断出该键,并将定义创建为只读的表/视图。-->
|
||||
<!--生成过程中发现错误:
|
||||
警告 6002: 表/视图“Ticket.dbo.UserAccount”未定义主键。已推断出该键,并将定义创建为只读的表/视图。-->
|
||||
<EntityType Name="UserAccount">
|
||||
<Key>
|
||||
<PropertyRef Name="tmp_field" />
|
||||
@@ -188,89 +51,12 @@
|
||||
</EntityType>
|
||||
<EntityContainer Name="TicketModelStoreContainer">
|
||||
<EntitySet Name="Product" EntityType="Self.Product" Schema="dbo" store:Type="Tables" />
|
||||
<EntitySet Name="UserAccount" EntityType="Self.UserAccount" store:Type="Tables" store:Schema="dbo">
|
||||
<DefiningQuery>SELECT
|
||||
[UserAccount].[tmp_field] AS [tmp_field],
|
||||
[UserAccount].[UserCode] AS [UserCode],
|
||||
[UserAccount].[PassWord] AS [PassWord],
|
||||
[UserAccount].[JobTicket] AS [JobTicket],
|
||||
[UserAccount].[Report] AS [Report],
|
||||
[UserAccount].[PathSetup] AS [PathSetup],
|
||||
[UserAccount].[UserSetup] AS [UserSetup],
|
||||
[UserAccount].[GROUP_CODE] AS [GROUP_CODE]
|
||||
FROM [dbo].[UserAccount] AS [UserAccount]</DefiningQuery>
|
||||
</EntitySet>
|
||||
<EntitySet Name="UserAccount" EntityType="Self.UserAccount" Schema="dbo" store:Type="Tables" />
|
||||
</EntityContainer>
|
||||
</Schema>
|
||||
</edmx:StorageModels>
|
||||
</Schema></edmx:StorageModels>
|
||||
<!-- CSDL content -->
|
||||
<edmx:ConceptualModels>
|
||||
<Schema Namespace="TicketModel" Alias="Self" annotation:UseStrongSpatialTypes="false" xmlns:annotation="http://schemas.microsoft.com/ado/2009/02/edm/annotation" xmlns:customannotation="http://schemas.microsoft.com/ado/2013/11/edm/customannotation" xmlns="http://schemas.microsoft.com/ado/2009/11/edm">
|
||||
<EntityType Name="Product">
|
||||
<Key>
|
||||
<PropertyRef Name="ProductCode" />
|
||||
</Key>
|
||||
<Property Name="ProductCode" Type="String" MaxLength="20" FixedLength="true" Unicode="true" Nullable="false" />
|
||||
<Property Name="ProductName" Type="String" MaxLength="50" FixedLength="true" Unicode="true" />
|
||||
<Property Name="Price" Type="Double" />
|
||||
<Property Name="Deduct" Type="Double" />
|
||||
<Property Name="FullWeight" Type="Double" />
|
||||
<Property Name="LampPosition" Type="Int32" />
|
||||
<Property Name="TablePosition" Type="String" MaxLength="5" FixedLength="true" Unicode="true" />
|
||||
<Property Name="AREA" Type="String" MaxLength="5" FixedLength="true" Unicode="true" />
|
||||
<Property Name="SafetyStock" Type="Double" />
|
||||
<Property Name="ProductUnit" Type="Int32" />
|
||||
<Property Name="ProductType" Type="Int32" />
|
||||
<Property Name="ProductClass" Type="Int32" />
|
||||
<Property Name="CurrentStock" Type="Double" />
|
||||
<Property Name="ProductLot" Type="String" MaxLength="30" FixedLength="true" Unicode="true" />
|
||||
<Property Name="RplDate" Type="DateTime" Precision="3" />
|
||||
<Property Name="UsedDate" Type="DateTime" Precision="3" />
|
||||
<Property Name="CuMonth" Type="String" MaxLength="2" FixedLength="true" Unicode="true" />
|
||||
<Property Name="LaStock" Type="Double" />
|
||||
<Property Name="ThStock" Type="Double" />
|
||||
<Property Name="ThUsed" Type="Double" />
|
||||
<Property Name="Color" Type="Int32" />
|
||||
<Property Name="LastTime" Type="Double" />
|
||||
<Property Name="CalTime" Type="Double" />
|
||||
<Property Name="BackflowTime" Type="Int32" />
|
||||
<Property Name="Tol_G" Type="Int32" />
|
||||
<Property Name="Tol_P" Type="Int32" />
|
||||
<Property Name="Alarm" Type="Int32" />
|
||||
<Property Name="Change_Bucket" Type="Int32" />
|
||||
<Property Name="Small_Volume_by_manual" Type="Int32" />
|
||||
<Property Name="Target_Weight" Type="Int32" />
|
||||
<Property Name="Pre_Weight" Type="Int32" />
|
||||
<Property Name="One_Sec" Type="Int32" />
|
||||
<Property Name="GetscalTime" Type="Int32" />
|
||||
<Property Name="DelayOpenValve" Type="Int32" />
|
||||
<Property Name="ValveMap" Type="String" MaxLength="5" FixedLength="true" Unicode="true" />
|
||||
<Property Name="PumpMap" Type="String" MaxLength="20" FixedLength="true" Unicode="true" />
|
||||
<Property Name="Includepump" Type="Int32" />
|
||||
<Property Name="Once_minimum_weight" Type="Int32" />
|
||||
<Property Name="Once_minimum_max_weight" Type="Int32" />
|
||||
<Property Name="Once_minimum_time" Type="Int32" />
|
||||
<Property Name="Res_S1" Type="String" MaxLength="30" FixedLength="true" Unicode="true" />
|
||||
<Property Name="Res_S2" Type="String" MaxLength="30" FixedLength="true" Unicode="true" />
|
||||
<Property Name="Res_S3" Type="String" MaxLength="30" FixedLength="true" Unicode="true" />
|
||||
<Property Name="Res_S4" Type="String" MaxLength="30" FixedLength="true" Unicode="true" />
|
||||
<Property Name="Res_I1" Type="Int32" />
|
||||
<Property Name="Res_I2" Type="Int32" />
|
||||
<Property Name="Res_I3" Type="Int32" />
|
||||
<Property Name="Res_I4" Type="Int32" />
|
||||
<Property Name="Res_F1" Type="Double" />
|
||||
<Property Name="Res_F2" Type="Double" />
|
||||
<Property Name="Res_F3" Type="Double" />
|
||||
<Property Name="Res_F4" Type="Double" />
|
||||
<Property Name="Batch_NO" Type="String" MaxLength="30" FixedLength="false" Unicode="false" />
|
||||
<Property Name="Concentration" Type="Double" />
|
||||
<Property Name="Pump" Type="Int32" />
|
||||
<Property Name="PRODUCT_KIND" Type="Int32" />
|
||||
<Property Name="SUPPLIER" Type="String" MaxLength="48" FixedLength="false" Unicode="false" />
|
||||
<Property Name="PRODUCT_MODIFY_DATE" Type="DateTime" Precision="3" />
|
||||
<Property Name="GRAVITY" Type="Double" Nullable="false" />
|
||||
<Property Name="UserAccount" Type="String" MaxLength="30" FixedLength="false" Unicode="false" />
|
||||
</EntityType>
|
||||
<EntityType Name="UserAccount">
|
||||
<Key>
|
||||
<PropertyRef Name="tmp_field" />
|
||||
@@ -285,81 +71,46 @@
|
||||
<Property Name="GROUP_CODE" Type="String" MaxLength="50" FixedLength="false" Unicode="false" Nullable="false" />
|
||||
</EntityType>
|
||||
<EntityContainer Name="TicketEntities" annotation:LazyLoadingEnabled="true">
|
||||
<EntitySet Name="Product" EntityType="Self.Product" />
|
||||
<EntitySet Name="UserAccount" EntityType="Self.UserAccount" />
|
||||
<EntitySet Name="Product" EntityType="TicketModel.Product" />
|
||||
</EntityContainer>
|
||||
<EntityType Name="Product">
|
||||
<Key>
|
||||
<PropertyRef Name="ProductCode" />
|
||||
</Key>
|
||||
<Property Name="ProductCode" Type="String" Nullable="false" MaxLength="30" FixedLength="true" Unicode="true" />
|
||||
<Property Name="ProductName" Type="String" MaxLength="50" FixedLength="true" Unicode="true" />
|
||||
<Property Name="ProductType" Type="Int32" />
|
||||
<Property Name="ProductClass" Type="Int32" />
|
||||
<Property Name="Color" Type="Int32" />
|
||||
<Property Name="ProductLot" Type="String" MaxLength="30" FixedLength="true" Unicode="true" />
|
||||
<Property Name="FullWeight" Type="Double" />
|
||||
<Property Name="ProductUnit" Type="Int32" />
|
||||
<Property Name="SafetyStock" Type="Double" />
|
||||
<Property Name="Price" Type="Double" />
|
||||
<Property Name="CurrentStock" Type="Double" />
|
||||
<Property Name="Deduct" Type="Double" />
|
||||
<Property Name="RplDate" Type="DateTime" Precision="3" />
|
||||
<Property Name="UsedDate" Type="DateTime" Precision="3" />
|
||||
<Property Name="CuMonth" Type="String" MaxLength="2" FixedLength="true" Unicode="true" />
|
||||
<Property Name="LaStock" Type="Double" />
|
||||
<Property Name="ThStock" Type="Double" />
|
||||
<Property Name="ThUsed" Type="Double" />
|
||||
<Property Name="LampPosition" Type="Int32" />
|
||||
<Property Name="TablePosition" Type="String" MaxLength="5" FixedLength="true" Unicode="true" />
|
||||
<Property Name="Area" Type="String" MaxLength="5" FixedLength="true" Unicode="true" />
|
||||
<Property Name="Concentration" Type="Double" />
|
||||
<Property Name="Batch_NO" Type="String" MaxLength="30" FixedLength="false" Unicode="false" />
|
||||
<Property Name="Pump" Type="Int32" />
|
||||
<Property Name="SUPPLIER" Type="String" MaxLength="50" FixedLength="false" Unicode="false" />
|
||||
<Property Name="GRAVITY" Type="Double" Nullable="false" />
|
||||
</EntityType>
|
||||
</Schema>
|
||||
</edmx:ConceptualModels>
|
||||
<!-- C-S mapping content -->
|
||||
<edmx:Mappings>
|
||||
<Mapping Space="C-S" xmlns="http://schemas.microsoft.com/ado/2009/11/mapping/cs">
|
||||
<EntityContainerMapping StorageEntityContainer="TicketModelStoreContainer" CdmEntityContainer="TicketEntities">
|
||||
<EntitySetMapping Name="Product">
|
||||
<EntityTypeMapping TypeName="TicketModel.Product">
|
||||
<MappingFragment StoreEntitySet="Product">
|
||||
<ScalarProperty Name="ProductCode" ColumnName="ProductCode" />
|
||||
<ScalarProperty Name="ProductName" ColumnName="ProductName" />
|
||||
<ScalarProperty Name="Price" ColumnName="Price" />
|
||||
<ScalarProperty Name="Deduct" ColumnName="Deduct" />
|
||||
<ScalarProperty Name="FullWeight" ColumnName="FullWeight" />
|
||||
<ScalarProperty Name="LampPosition" ColumnName="LampPosition" />
|
||||
<ScalarProperty Name="TablePosition" ColumnName="TablePosition" />
|
||||
<ScalarProperty Name="AREA" ColumnName="AREA" />
|
||||
<ScalarProperty Name="SafetyStock" ColumnName="SafetyStock" />
|
||||
<ScalarProperty Name="ProductUnit" ColumnName="ProductUnit" />
|
||||
<ScalarProperty Name="ProductType" ColumnName="ProductType" />
|
||||
<ScalarProperty Name="ProductClass" ColumnName="ProductClass" />
|
||||
<ScalarProperty Name="CurrentStock" ColumnName="CurrentStock" />
|
||||
<ScalarProperty Name="ProductLot" ColumnName="ProductLot" />
|
||||
<ScalarProperty Name="RplDate" ColumnName="RplDate" />
|
||||
<ScalarProperty Name="UsedDate" ColumnName="UsedDate" />
|
||||
<ScalarProperty Name="CuMonth" ColumnName="CuMonth" />
|
||||
<ScalarProperty Name="LaStock" ColumnName="LaStock" />
|
||||
<ScalarProperty Name="ThStock" ColumnName="ThStock" />
|
||||
<ScalarProperty Name="ThUsed" ColumnName="ThUsed" />
|
||||
<ScalarProperty Name="Color" ColumnName="Color" />
|
||||
<ScalarProperty Name="LastTime" ColumnName="LastTime" />
|
||||
<ScalarProperty Name="CalTime" ColumnName="CalTime" />
|
||||
<ScalarProperty Name="BackflowTime" ColumnName="BackflowTime" />
|
||||
<ScalarProperty Name="Tol_G" ColumnName="Tol_G" />
|
||||
<ScalarProperty Name="Tol_P" ColumnName="Tol_P" />
|
||||
<ScalarProperty Name="Alarm" ColumnName="Alarm" />
|
||||
<ScalarProperty Name="Change_Bucket" ColumnName="Change_Bucket" />
|
||||
<ScalarProperty Name="Small_Volume_by_manual" ColumnName="Small_Volume_by_manual" />
|
||||
<ScalarProperty Name="Target_Weight" ColumnName="Target_Weight" />
|
||||
<ScalarProperty Name="Pre_Weight" ColumnName="Pre_Weight" />
|
||||
<ScalarProperty Name="One_Sec" ColumnName="One_Sec" />
|
||||
<ScalarProperty Name="GetscalTime" ColumnName="GetscalTime" />
|
||||
<ScalarProperty Name="DelayOpenValve" ColumnName="DelayOpenValve" />
|
||||
<ScalarProperty Name="ValveMap" ColumnName="ValveMap" />
|
||||
<ScalarProperty Name="PumpMap" ColumnName="PumpMap" />
|
||||
<ScalarProperty Name="Includepump" ColumnName="Includepump" />
|
||||
<ScalarProperty Name="Once_minimum_weight" ColumnName="Once_minimum_weight" />
|
||||
<ScalarProperty Name="Once_minimum_max_weight" ColumnName="Once_minimum_max_weight" />
|
||||
<ScalarProperty Name="Once_minimum_time" ColumnName="Once_minimum_time" />
|
||||
<ScalarProperty Name="Res_S1" ColumnName="Res_S1" />
|
||||
<ScalarProperty Name="Res_S2" ColumnName="Res_S2" />
|
||||
<ScalarProperty Name="Res_S3" ColumnName="Res_S3" />
|
||||
<ScalarProperty Name="Res_S4" ColumnName="Res_S4" />
|
||||
<ScalarProperty Name="Res_I1" ColumnName="Res_I1" />
|
||||
<ScalarProperty Name="Res_I2" ColumnName="Res_I2" />
|
||||
<ScalarProperty Name="Res_I3" ColumnName="Res_I3" />
|
||||
<ScalarProperty Name="Res_I4" ColumnName="Res_I4" />
|
||||
<ScalarProperty Name="Res_F1" ColumnName="Res_F1" />
|
||||
<ScalarProperty Name="Res_F2" ColumnName="Res_F2" />
|
||||
<ScalarProperty Name="Res_F3" ColumnName="Res_F3" />
|
||||
<ScalarProperty Name="Res_F4" ColumnName="Res_F4" />
|
||||
<ScalarProperty Name="Batch_NO" ColumnName="Batch_NO" />
|
||||
<ScalarProperty Name="Concentration" ColumnName="Concentration" />
|
||||
<ScalarProperty Name="Pump" ColumnName="Pump" />
|
||||
<ScalarProperty Name="PRODUCT_KIND" ColumnName="PRODUCT_KIND" />
|
||||
<ScalarProperty Name="SUPPLIER" ColumnName="SUPPLIER" />
|
||||
<ScalarProperty Name="PRODUCT_MODIFY_DATE" ColumnName="PRODUCT_MODIFY_DATE" />
|
||||
<ScalarProperty Name="GRAVITY" ColumnName="GRAVITY" />
|
||||
<ScalarProperty Name="UserAccount" ColumnName="UserAccount" />
|
||||
</MappingFragment>
|
||||
</EntityTypeMapping>
|
||||
</EntitySetMapping>
|
||||
<EntitySetMapping Name="UserAccount">
|
||||
<EntityTypeMapping TypeName="TicketModel.UserAccount">
|
||||
<MappingFragment StoreEntitySet="UserAccount">
|
||||
@@ -374,6 +125,38 @@
|
||||
</MappingFragment>
|
||||
</EntityTypeMapping>
|
||||
</EntitySetMapping>
|
||||
<EntitySetMapping Name="Product">
|
||||
<EntityTypeMapping TypeName="TicketModel.Product">
|
||||
<MappingFragment StoreEntitySet="Product">
|
||||
<ScalarProperty Name="GRAVITY" ColumnName="GRAVITY" />
|
||||
<ScalarProperty Name="SUPPLIER" ColumnName="SUPPLIER" />
|
||||
<ScalarProperty Name="Pump" ColumnName="Pump" />
|
||||
<ScalarProperty Name="Batch_NO" ColumnName="Batch_NO" />
|
||||
<ScalarProperty Name="Concentration" ColumnName="Concentration" />
|
||||
<ScalarProperty Name="Area" ColumnName="Area" />
|
||||
<ScalarProperty Name="TablePosition" ColumnName="TablePosition" />
|
||||
<ScalarProperty Name="LampPosition" ColumnName="LampPosition" />
|
||||
<ScalarProperty Name="ThUsed" ColumnName="ThUsed" />
|
||||
<ScalarProperty Name="ThStock" ColumnName="ThStock" />
|
||||
<ScalarProperty Name="LaStock" ColumnName="LaStock" />
|
||||
<ScalarProperty Name="CuMonth" ColumnName="CuMonth" />
|
||||
<ScalarProperty Name="UsedDate" ColumnName="UsedDate" />
|
||||
<ScalarProperty Name="RplDate" ColumnName="RplDate" />
|
||||
<ScalarProperty Name="Deduct" ColumnName="Deduct" />
|
||||
<ScalarProperty Name="CurrentStock" ColumnName="CurrentStock" />
|
||||
<ScalarProperty Name="Price" ColumnName="Price" />
|
||||
<ScalarProperty Name="SafetyStock" ColumnName="SafetyStock" />
|
||||
<ScalarProperty Name="ProductUnit" ColumnName="ProductUnit" />
|
||||
<ScalarProperty Name="FullWeight" ColumnName="FullWeight" />
|
||||
<ScalarProperty Name="ProductLot" ColumnName="ProductLot" />
|
||||
<ScalarProperty Name="Color" ColumnName="Color" />
|
||||
<ScalarProperty Name="ProductClass" ColumnName="ProductClass" />
|
||||
<ScalarProperty Name="ProductType" ColumnName="ProductType" />
|
||||
<ScalarProperty Name="ProductName" ColumnName="ProductName" />
|
||||
<ScalarProperty Name="ProductCode" ColumnName="ProductCode" />
|
||||
</MappingFragment>
|
||||
</EntityTypeMapping>
|
||||
</EntitySetMapping>
|
||||
</EntityContainerMapping>
|
||||
</Mapping>
|
||||
</edmx:Mappings>
|
||||
|
||||
@@ -4,9 +4,9 @@
|
||||
<edmx:Designer xmlns="http://schemas.microsoft.com/ado/2009/11/edmx">
|
||||
<!-- Diagram content (shape and connector positions) -->
|
||||
<edmx:Diagrams>
|
||||
<Diagram DiagramId="89d520d3675442b5b0979c510546a2e9" Name="Diagram1" ZoomLevel="60">
|
||||
<EntityTypeShape EntityType="TicketModel.Product" Width="1.5" PointX="0.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="TicketModel.UserAccount" Width="1.5" PointX="3.5" PointY="3.625" IsExpanded="true" />
|
||||
<Diagram DiagramId="b4c3f4749235450782ad7a88197423ed" Name="Diagram1" ZoomLevel="62">
|
||||
<EntityTypeShape EntityType="TicketModel.UserAccount" Width="1.5" PointX="0.75" PointY="0.75" IsExpanded="true" />
|
||||
<EntityTypeShape EntityType="TicketModel.Product" Width="1.5" PointX="3.375" PointY="0.75" />
|
||||
</Diagram>
|
||||
</edmx:Diagrams>
|
||||
</edmx:Designer>
|
||||
|
||||
@@ -1,28 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,28 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,29 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class ScheduledDyelot
|
||||
{
|
||||
public int ID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string Process { get; set; }
|
||||
public string Dispenser { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public Nullable<int> TankNo { get; set; }
|
||||
public Nullable<System.DateTime> ScheduledTime { get; set; }
|
||||
public string Checked { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,30 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码已从模板生成。
|
||||
//
|
||||
// 手动更改此文件可能导致应用程序出现意外的行为。
|
||||
// 如果重新生成代码,将覆盖对此文件的手动更改。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Models
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
public partial class ScheduledDyelotHistory
|
||||
{
|
||||
public int ID { get; set; }
|
||||
public string Dyelot { get; set; }
|
||||
public int ReDye { get; set; }
|
||||
public Nullable<int> StepNumber { get; set; }
|
||||
public string Process { get; set; }
|
||||
public string Dispenser { get; set; }
|
||||
public string Machine { get; set; }
|
||||
public Nullable<int> TankNo { get; set; }
|
||||
public Nullable<System.DateTime> ScheduledTime { get; set; }
|
||||
public string Checked { get; set; }
|
||||
public string UserAccount { get; set; }
|
||||
public Nullable<System.DateTime> Updated { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,26 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,21 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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; }
|
||||
}
|
||||
}
|
||||
@@ -1,28 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <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,181 @@
|
||||
<UserControl x:Class="Audit.View.MachinesView"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||
xmlns:local="clr-namespace:Audit.View"
|
||||
mc:Ignorable="d"
|
||||
d:DesignHeight="900" d:DesignWidth="1140"
|
||||
xmlns:ConvertMoels="clr-namespace:Audit.ConvertMoels"
|
||||
DataContext="{Binding Source={StaticResource Locator},Path=Machines}">
|
||||
|
||||
<UserControl.Resources>
|
||||
<ConvertMoels:StatenConvert x:Key="StatenConvert"/>
|
||||
<ConvertMoels:StatenERRConvert x:Key="StatenERRConvert"/>
|
||||
</UserControl.Resources>
|
||||
|
||||
<Grid>
|
||||
<!--布局-->
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="30"/>
|
||||
<RowDefinition/>
|
||||
</Grid.RowDefinitions>
|
||||
<Border BorderThickness="0,0,0,1" BorderBrush="#CCCCCC">
|
||||
</Border>
|
||||
<Grid Grid.Row="0"/>
|
||||
<Grid Grid.Row="1">
|
||||
<!--表-->
|
||||
<DataGrid x:Name="DataGridMachines" MouseDoubleClick="DataGridStuff_MouseDoubleClick" ItemsSource="{Binding Machines, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
SelectionMode="Single" AlternationCount="2" IsReadOnly="True" HorizontalAlignment="Left" Margin="15,15,0,150" d:ItemsSource="{d:SampleData ItemCount=200}" AutoGenerateColumns="False" MinColumnWidth="30" HorizontalGridLinesBrush="#FFC9C9C9" VerticalGridLinesBrush="#FFC9C9C9" GridLinesVisibility="All" BorderBrush="#CCCCCC" BorderThickness="1,1,1,1" ColumnHeaderHeight="40" HorizontalContentAlignment="Right" Grid.ColumnSpan="2" CanUserReorderColumns="False">
|
||||
<DataGrid.RowStyle >
|
||||
<Style TargetType="{x:Type DataGridRow}">
|
||||
<Style.Triggers>
|
||||
<Trigger Property="ItemsControl.AlternationIndex" Value="0">
|
||||
<Setter Property="Background" Value="#FFFFFFFF" />
|
||||
</Trigger>
|
||||
<Trigger Property="ItemsControl.AlternationIndex" Value="1">
|
||||
<Setter Property="Background" Value="#FFF5F5F5" />
|
||||
</Trigger>
|
||||
<Trigger Property="IsMouseOver" Value="False">
|
||||
</Trigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</DataGrid.RowStyle>
|
||||
<DataGrid.CellStyle>
|
||||
<Style TargetType="DataGridCell">
|
||||
<Setter Property="BorderThickness" Value="0"/>
|
||||
<Setter Property="MinWidth" Value="20"/>
|
||||
<Style.Triggers>
|
||||
<Trigger Property="IsSelected" Value="True">
|
||||
<Setter Property="Background" Value="#FFC0C0C0"/>
|
||||
<Setter Property="BorderBrush" Value="#FFC0C0C0"/>
|
||||
<Setter Property="Foreground" Value="#000000"/>
|
||||
</Trigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</DataGrid.CellStyle>
|
||||
<DataGrid.Columns>
|
||||
<!--列信息绑定-->
|
||||
<DataGridTextColumn Header="染机代码" Width="100" FontSize="15" Binding="{Binding Name}" MaxWidth="130" MinWidth="100" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="染机名称" Width="100" FontSize="15" Binding="{Binding ChemicalStation}" MaxWidth="200" MinWidth="100" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="运行单号" Width="120" FontSize="15" Binding="{Binding DispenseDyelot}" MaxWidth="200" MinWidth="100" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="助剂状态" Width="80" FontSize="15" MaxWidth="80" MinWidth="50" CanUserReorder="False">
|
||||
<!--事件名称:工作状态数字转文字显示,转换器StatenConvert-->
|
||||
<DataGridTextColumn.ElementStyle>
|
||||
<Style TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="Text" Value="{Binding Path=ChemicalState,Converter={StaticResource StatenConvert}}">
|
||||
</Setter>
|
||||
<Setter Property="Foreground" Value="{Binding Path=ChemicalState,Converter={StaticResource StatenERRConvert}}">
|
||||
</Setter>
|
||||
</Style>
|
||||
</DataGridTextColumn.ElementStyle>
|
||||
</DataGridTextColumn>
|
||||
<DataGridTextColumn Header="助剂状态2" Width="80" FontSize="15" MaxWidth="80" MinWidth="50" CanUserReorder="False">
|
||||
<!--事件名称:工作状态数字转文字显示,转换器StatenConvertt-->
|
||||
<DataGridTextColumn.ElementStyle>
|
||||
<Style TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="Text" Value="{Binding Path=ChemicalState2,Converter={StaticResource StatenConvert}}">
|
||||
</Setter>
|
||||
<Setter Property="Foreground" Value="{Binding Path=ChemicalState2,Converter={StaticResource StatenERRConvert}}">
|
||||
</Setter>
|
||||
</Style>
|
||||
</DataGridTextColumn.ElementStyle>
|
||||
</DataGridTextColumn>
|
||||
<DataGridTextColumn Header="液体助剂组" Width="100" FontSize="15" Binding="{Binding ChemicalDispenser}" MaxWidth="100" MinWidth="100" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="液体助剂启用" Width="0" FontSize="15" Binding="{Binding ChemicalEnabled}" MaxWidth="0" MinWidth="0" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="染料状态" Width="80" FontSize="15" MaxWidth="80" MinWidth="50" CanUserReorder="False">
|
||||
<!--事件名称:工作状态数字转文字显示,转换器StatenConvert-->
|
||||
<DataGridTextColumn.ElementStyle>
|
||||
<Style TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="Text" Value="{Binding Path=DyeState,Converter={StaticResource StatenConvert}}">
|
||||
</Setter>
|
||||
<Setter Property="Foreground" Value="{Binding Path=DyeState,Converter={StaticResource StatenERRConvert}}">
|
||||
</Setter>
|
||||
</Style>
|
||||
</DataGridTextColumn.ElementStyle>
|
||||
</DataGridTextColumn>
|
||||
<DataGridTextColumn Header="染料溶解组" Width="100" FontSize="15" Binding="{Binding DyeDispenser}" MaxWidth="100" MinWidth="100" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="染料启用" Width="0" FontSize="15" Binding="{Binding DyeEnabled}" MaxWidth="0" MinWidth="0" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="粉体状态" Width="80" FontSize="15" MaxWidth="80" MinWidth="50" CanUserReorder="False">
|
||||
<!--事件名称:工作状态数字转文字显示,转换器StatenConvert-->
|
||||
<DataGridTextColumn.ElementStyle>
|
||||
<Style TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="Text" Value="{Binding Path=PowderState,Converter={StaticResource StatenConvert}}">
|
||||
</Setter>
|
||||
<Setter Property="Foreground" Value="{Binding Path=PowderState,Converter={StaticResource StatenERRConvert}}">
|
||||
</Setter>
|
||||
</Style>
|
||||
</DataGridTextColumn.ElementStyle>
|
||||
</DataGridTextColumn>
|
||||
<DataGridTextColumn Header="粉体助剂组" Width="100" FontSize="15" Binding="{Binding PowderDispenser}" MaxWidth="100" MinWidth="100" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="粉体启用" Width="0" FontSize="15" Binding="{Binding PowderEnabled}" MaxWidth="0" MinWidth="0" CanUserReorder="False"/>
|
||||
</DataGrid.Columns>
|
||||
</DataGrid>
|
||||
<!--染机代码-->
|
||||
<TextBox x:Name="name" HorizontalAlignment="Left" Height="30" Margin="105,0,0,100" Text=""
|
||||
VerticalAlignment="Bottom" Width="155" FontSize="16" MaxLines="1" MaxLength="25"
|
||||
InputMethod.IsInputMethodEnabled="False"/>
|
||||
<TextBlock HorizontalAlignment="Left" Height="30" Margin="15,0,0,100" TextWrapping="Wrap" Text="染机代码"
|
||||
VerticalAlignment="Bottom" Width="100" FontSize="20"/>
|
||||
<!--染机名称-->
|
||||
<TextBox x:Name="Station" HorizontalAlignment="Left" Height="30" Margin="360,0,0,100" Text=""
|
||||
VerticalAlignment="Bottom" Width="200" FontSize="16" MaxLines="1" MaxLength="50"/>
|
||||
<TextBlock HorizontalAlignment="Left" Height="30" Margin="270,0,0,100" TextWrapping="Wrap" Text="染机名称"
|
||||
VerticalAlignment="Bottom" Width="100" FontSize="20"/>
|
||||
<!--操作-->
|
||||
<ComboBox x:Name="operate" HorizontalAlignment="Left" Height="30" Margin="620,0,0,100" Text=""
|
||||
VerticalAlignment="Bottom" Width="140" FontSize="16" IsReadOnly="True" IsEditable="True">
|
||||
<ComboBoxItem Content="清除工单"></ComboBoxItem>
|
||||
<ComboBoxItem Content="助剂完成"></ComboBoxItem>
|
||||
<ComboBoxItem Content="染料完成"></ComboBoxItem>
|
||||
<ComboBoxItem Content="粉体完成"></ComboBoxItem>
|
||||
<ComboBoxItem Content="修改信息"></ComboBoxItem>
|
||||
</ComboBox>
|
||||
<TextBlock HorizontalAlignment="Left" Height="30" Margin="575,0,0,100" TextWrapping="Wrap" Text="操作"
|
||||
VerticalAlignment="Bottom" Width="100" FontSize="20"/>
|
||||
<!--液体助剂机组-->
|
||||
<TextBox x:Name="chemicaldispenser" HorizontalAlignment="Left" Height="30" Margin="130,0,0,50" Text=""
|
||||
VerticalAlignment="Bottom" Width="130" FontSize="16" MaxLines="1" MaxLength="25"
|
||||
InputMethod.IsInputMethodEnabled="False"/>
|
||||
<ComboBox x:Name="chemicaldispenser_operate" HorizontalAlignment="Left" Height="30" Margin="60,0,0,50" Text=""
|
||||
VerticalAlignment="Bottom" Width="65" FontSize="16" IsReadOnly="True" IsEditable="True">
|
||||
<ComboBoxItem Content="禁用"></ComboBoxItem>
|
||||
<ComboBoxItem Content="启用"></ComboBoxItem>
|
||||
</ComboBox>
|
||||
<TextBlock HorizontalAlignment="Left" Height="30" Margin="15,0,0,50" TextWrapping="Wrap" Text="助剂"
|
||||
VerticalAlignment="Bottom" Width="50" FontSize="20"/>
|
||||
<!--染料染剂机组-->
|
||||
<TextBox x:Name="dyedispenser" HorizontalAlignment="Left" Height="30" Margin="380,0,0,50" Text=""
|
||||
VerticalAlignment="Bottom" Width="130" FontSize="16" MaxLines="1" MaxLength="25"
|
||||
InputMethod.IsInputMethodEnabled="False"/>
|
||||
<ComboBox x:Name="dyedispenser_operate" HorizontalAlignment="Left" Height="30" Margin="310,0,0,50" Text=""
|
||||
VerticalAlignment="Bottom" Width="65" FontSize="16" IsReadOnly="True" IsEditable="True">
|
||||
<ComboBoxItem Content="禁用"></ComboBoxItem>
|
||||
<ComboBoxItem Content="启用"></ComboBoxItem>
|
||||
</ComboBox>
|
||||
<TextBlock HorizontalAlignment="Left" Height="30" Margin="265,0,0,50" TextWrapping="Wrap" Text="染料"
|
||||
VerticalAlignment="Bottom" Width="50" FontSize="20"/>
|
||||
<!--粉体助剂机组-->
|
||||
<TextBox x:Name="powderdispenser" HorizontalAlignment="Left" Height="30" Margin="630,0,0,50" Text=""
|
||||
VerticalAlignment="Bottom" Width="130" FontSize="16" MaxLines="1" MaxLength="25"
|
||||
InputMethod.IsInputMethodEnabled="False"/>
|
||||
<ComboBox x:Name="powderdispenser_operate" HorizontalAlignment="Left" Height="30" Margin="560,0,0,50" Text=""
|
||||
VerticalAlignment="Bottom" Width="65" FontSize="16" IsReadOnly="True" IsEditable="True">
|
||||
<ComboBoxItem Content="禁用"></ComboBoxItem>
|
||||
<ComboBoxItem Content="启用"></ComboBoxItem>
|
||||
</ComboBox>
|
||||
<TextBlock HorizontalAlignment="Left" Height="30" Margin="515,0,0,50" TextWrapping="Wrap" Text="粉体"
|
||||
VerticalAlignment="Bottom" Width="50" FontSize="20"/>
|
||||
<!--存储按钮-->
|
||||
<Button Content="确认" HorizontalAlignment="Left" Height="65" Margin="795,0,0,60"
|
||||
VerticalAlignment="Bottom" Width="145" FontSize="40" BorderBrush="{x:Null}" Background="#FFCECECE"
|
||||
Click="Button_Preservation">
|
||||
</Button>
|
||||
<!--删除按钮-->
|
||||
<Button Content="删除" HorizontalAlignment="Left" Height="65" Margin="975,0,0,60"
|
||||
VerticalAlignment="Bottom" Width="145" FontSize="40" BorderBrush="{x:Null}" Background="#FFCECECE"
|
||||
Click="Button_Delete">
|
||||
</Button>
|
||||
</Grid>
|
||||
</Grid>
|
||||
</UserControl>
|
||||
@@ -0,0 +1,246 @@
|
||||
using Models;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Text.RegularExpressions;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows;
|
||||
using System.Windows.Controls;
|
||||
using System.Windows.Data;
|
||||
using System.Windows.Documents;
|
||||
using System.Windows.Input;
|
||||
using System.Windows.Media;
|
||||
using System.Windows.Media.Imaging;
|
||||
using System.Windows.Navigation;
|
||||
using System.Windows.Shapes;
|
||||
|
||||
namespace Audit.View
|
||||
{
|
||||
/// <summary>
|
||||
/// MachinesView.xaml 的交互逻辑
|
||||
/// </summary>
|
||||
public partial class MachinesView : UserControl
|
||||
{
|
||||
public MachinesView()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
private Machines machines = new Machines();//最终存入sql的实体
|
||||
private Machines machines_temp = new Machines();//取出自sql的实体缓存
|
||||
public static Boolean Button_sql = true;
|
||||
public static int Buttontype_sql = -1;
|
||||
|
||||
private void DataGridStuff_MouseDoubleClick(object sender, MouseButtonEventArgs e)
|
||||
{
|
||||
int rownum = DataGridMachines.SelectedIndex;//获取鼠标选中行并定义变量
|
||||
if (rownum != -1)//判断鼠标定位是否有效
|
||||
{
|
||||
string DataGridMachines_Name = (DataGridMachines.Columns[0].GetCellContent(DataGridMachines.Items[rownum]) as TextBlock).Text;//定位第0列,
|
||||
string DataGridMachines_ChemicalStation = (DataGridMachines.Columns[1].GetCellContent(DataGridMachines.Items[rownum]) as TextBlock).Text;//定位第1列,
|
||||
string DataGridMachines_ChemicalDispenser = (DataGridMachines.Columns[5].GetCellContent(DataGridMachines.Items[rownum]) as TextBlock).Text;//定位第2列,
|
||||
string DataGridMachines_Chemicale = (DataGridMachines.Columns[6].GetCellContent(DataGridMachines.Items[rownum]) as TextBlock).Text;//定位第2列,
|
||||
string DataGridMachines_DyeDispenser = (DataGridMachines.Columns[8].GetCellContent(DataGridMachines.Items[rownum]) as TextBlock).Text;//定位第3列,
|
||||
string DataGridMachines_Dyee = (DataGridMachines.Columns[9].GetCellContent(DataGridMachines.Items[rownum]) as TextBlock).Text;//定位第3列,
|
||||
string DataGridMachines_PowderDispenser = (DataGridMachines.Columns[11].GetCellContent(DataGridMachines.Items[rownum]) as TextBlock).Text;//定位第4列,
|
||||
string DataGridMachines_Powdere = (DataGridMachines.Columns[12].GetCellContent(DataGridMachines.Items[rownum]) as TextBlock).Text;//定位第4列,
|
||||
name.Text = DataGridMachines_Name.Trim();
|
||||
Station.Text = DataGridMachines_ChemicalStation.Trim();
|
||||
chemicaldispenser.Text = DataGridMachines_ChemicalDispenser.Trim();
|
||||
dyedispenser.Text = DataGridMachines_DyeDispenser.Trim();
|
||||
powderdispenser.Text = DataGridMachines_PowderDispenser.Trim();
|
||||
if (DataGridMachines_Chemicale == "1") this.chemicaldispenser_operate.Text = "启用";
|
||||
else this.chemicaldispenser_operate.Text = "禁用";
|
||||
if (DataGridMachines_Dyee == "1") this.dyedispenser_operate.Text = "启用";
|
||||
else this.dyedispenser_operate.Text = "禁用";
|
||||
if (DataGridMachines_Powdere == "1") this.powderdispenser_operate.Text = "启用";
|
||||
else this.powderdispenser_operate.Text = "禁用";
|
||||
this.operate.Text =null;//清除附属操作
|
||||
machines_temp.Name = DataGridMachines_Name;//写入sql实体缓存
|
||||
}
|
||||
}
|
||||
|
||||
private void Button_Preservation(object sender, RoutedEventArgs e)//存储按钮
|
||||
{
|
||||
int int_operate = 0;
|
||||
Regex re_char = new Regex(@"^[A-Za-z0-9\s@()()/+!!_-]+$");//校验用正则表达式由数字,26个英文字母,空白字符和@()()/+!!_-组成的字符串
|
||||
if (this.operate.Text == "") int_operate = 0;//创建机台
|
||||
if (this.operate.Text == "清除工单") int_operate = 1;//附属操作
|
||||
if (this.operate.Text == "助剂完成") int_operate = 2;
|
||||
if (this.operate.Text == "染料完成") int_operate = 3;
|
||||
if (this.operate.Text == "粉体完成") int_operate = 4;
|
||||
if (this.operate.Text == "修改信息") int_operate = 5;
|
||||
if (re_char.IsMatch(this.name.Text) == false) System.Windows.MessageBox.Show("ERR.C0201:无效的机台信息", "错误");//检查机台代码
|
||||
else
|
||||
if (string.IsNullOrEmpty(this.Station.Text)) System.Windows.MessageBox.Show("ERR.C0201-2:无效的机台信息", "错误");//检查机台名称
|
||||
else
|
||||
{
|
||||
if (int_operate == 0)//创建机台
|
||||
{
|
||||
machines.Name = this.name.Text;
|
||||
machines.DispenseDyelot = null;
|
||||
machines.DyeDispenseDyelot = null;
|
||||
machines.ChemicalStation = this.Station.Text;
|
||||
machines.DyeStation = this.Station.Text;
|
||||
machines.PowderStation = this.Station.Text;
|
||||
machines.ChemicalDispenser = this.chemicaldispenser.Text;
|
||||
machines.DyeDispenser = this.dyedispenser.Text;
|
||||
machines.PowderDispenser = this.powderdispenser.Text;
|
||||
machines.ChemicalCallOff = 0;
|
||||
machines.ChemicalCallOff2 = 0;
|
||||
machines.ChemicalState = 101;
|
||||
machines.ChemicalState2 = 101;
|
||||
machines.DyeCallOff = 0;
|
||||
machines.DyeState = 101;
|
||||
machines.PowderCallOff = 0;
|
||||
machines.PowderState = 101;
|
||||
if (this.chemicaldispenser_operate.Text == "启用") machines.ChemicalEnabled = 1;
|
||||
else machines.ChemicalEnabled = 0;
|
||||
if (this.dyedispenser_operate.Text == "启用") machines.DyeEnabled = 1;
|
||||
else machines.DyeEnabled = 0;
|
||||
if (this.powderdispenser_operate.Text == "启用") machines.PowderEnabled = 1;
|
||||
else machines.PowderEnabled = 0;
|
||||
if (new MachinesProvider().Selectsql(machines).Count == 0)//判断数据库设定目标信息是否存在。
|
||||
{
|
||||
var count = new MachinesProvider().Insert(machines);//添加数据库信息
|
||||
Button_sql = true;
|
||||
if (count == 0) MessageBox.Show("ERR.C0210-2:机台创建失败", "错误");
|
||||
}
|
||||
else
|
||||
{
|
||||
System.Windows.MessageBox.Show("ERR.C0211:机台已存在终止操作", "错误");//判断执行是否成功
|
||||
}
|
||||
}
|
||||
|
||||
if (int_operate == 1)//清除信息
|
||||
{
|
||||
machines.Name = this.name.Text;
|
||||
machines.DispenseDyelot = null;
|
||||
machines.DyeDispenseDyelot = null;
|
||||
machines.ChemicalCallOff = 0;
|
||||
machines.ChemicalCallOff2 = 0;
|
||||
machines.ChemicalState = 101;
|
||||
machines.ChemicalState2 = 101;
|
||||
machines.DyeCallOff = 0;
|
||||
machines.DyeState = 101;
|
||||
machines.PowderCallOff = 0;
|
||||
machines.PowderState = 101;
|
||||
if (new MachinesProvider().Selectsql(machines).Count == 0)//判断数据库设定目标信息是否存在。
|
||||
{
|
||||
System.Windows.MessageBox.Show("ERR.C0202-5:机台信息错误", "错误");//执行是否成功
|
||||
}
|
||||
else
|
||||
{
|
||||
var count = new MachinesProvider().Update1(machines);//添加数据库信息。
|
||||
Button_sql = true;
|
||||
if (count == 0) MessageBox.Show("ERR.C0210-2:机台创建失败", "错误");
|
||||
}
|
||||
}
|
||||
|
||||
if (int_operate == 2)//助剂完成
|
||||
{
|
||||
machines.Name = this.name.Text;
|
||||
machines.ChemicalCallOff = 0;
|
||||
machines.ChemicalCallOff2 = 0;
|
||||
machines.ChemicalState = 101;
|
||||
machines.ChemicalState2 = 101;
|
||||
if (new MachinesProvider().Selectsql(machines).Count == 0)//判断数据库设定目标信息是否存在。
|
||||
{
|
||||
System.Windows.MessageBox.Show("ERR.C0202-5:机台信息错误", "错误");//执行是否成功
|
||||
}
|
||||
else
|
||||
{
|
||||
var count = new MachinesProvider().Update2(machines);//修改数据库信息。
|
||||
Button_sql = true;
|
||||
if (count == 0) System.Windows.MessageBox.Show("ERR.C0210-1:信息修改失败", "错误");//判断执行是否成功
|
||||
}
|
||||
}
|
||||
|
||||
if (int_operate == 3)//染料完成
|
||||
{
|
||||
machines.Name = this.name.Text;
|
||||
machines.DyeCallOff = 0;
|
||||
machines.DyeState = 101;
|
||||
if (new MachinesProvider().Selectsql(machines).Count == 0)//判断数据库设定目标信息是否存在。
|
||||
{
|
||||
System.Windows.MessageBox.Show("ERR.C0202-5:机台信息错误", "错误");//执行是否成功
|
||||
}
|
||||
else
|
||||
{
|
||||
var count = new MachinesProvider().Update3(machines);//修改数据库信息。
|
||||
Button_sql = true;
|
||||
if (count == 0) System.Windows.MessageBox.Show("ERR.C0210-1:信息修改失败", "错误");//判断执行是否成功
|
||||
}
|
||||
}
|
||||
|
||||
if (int_operate == 4)//粉体完成
|
||||
{
|
||||
machines.Name = this.name.Text;
|
||||
machines.PowderCallOff = 0;
|
||||
machines.PowderState = 101;
|
||||
if (new MachinesProvider().Selectsql(machines).Count == 0)//判断数据库设定目标信息是否存在。
|
||||
{
|
||||
System.Windows.MessageBox.Show("ERR.C0202-5:机台信息错误", "错误");//执行是否成功
|
||||
}
|
||||
else
|
||||
{
|
||||
var count = new MachinesProvider().Update4(machines);//添加数据库信息。
|
||||
Button_sql = true;
|
||||
if (count == 0) System.Windows.MessageBox.Show("ERR.C0210-1:信息修改失败", "错误");//判断执行是否成功
|
||||
}
|
||||
}
|
||||
|
||||
if (int_operate == 5)//修改机台
|
||||
{
|
||||
machines.Name = this.name.Text;
|
||||
machines.DispenseDyelot = null;
|
||||
machines.DyeDispenseDyelot = null;
|
||||
machines.ChemicalStation = this.Station.Text;
|
||||
machines.DyeStation = this.Station.Text;
|
||||
machines.PowderStation = this.Station.Text;
|
||||
machines.ChemicalDispenser = this.chemicaldispenser.Text;
|
||||
machines.DyeDispenser = this.dyedispenser.Text;
|
||||
machines.PowderDispenser = this.powderdispenser.Text;
|
||||
machines.ChemicalCallOff = 0;
|
||||
machines.ChemicalCallOff2 = 0;
|
||||
machines.ChemicalState = 101;
|
||||
machines.ChemicalState2 = 101;
|
||||
machines.DyeCallOff = 0;
|
||||
machines.DyeState = 101;
|
||||
machines.PowderCallOff = 0;
|
||||
machines.PowderState = 101;
|
||||
if (this.chemicaldispenser_operate.Text == "启用") machines.ChemicalEnabled = 1;
|
||||
else machines.ChemicalEnabled = 0;
|
||||
if (this.dyedispenser_operate.Text == "启用") machines.DyeEnabled = 1;
|
||||
else machines.DyeEnabled = 0;
|
||||
if (this.powderdispenser_operate.Text == "启用") machines.PowderEnabled = 1;
|
||||
else machines.PowderEnabled = 0;
|
||||
if (new MachinesProvider().Selectsql(machines).Count == 0)//判断数据库设定目标信息是否存在。
|
||||
{
|
||||
System.Windows.MessageBox.Show("ERR.C0202-5:机台信息错误", "错误");//执行是否成功
|
||||
}
|
||||
else
|
||||
{
|
||||
var count = new MachinesProvider().Update(machines);//添加数据库信息
|
||||
Button_sql = true;
|
||||
if (count == 0) MessageBox.Show("ERR.C0210-2:机台修改失败", "错误");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void Button_Delete(object sender, RoutedEventArgs e)//删除按钮
|
||||
{
|
||||
machines.Name = this.name.Text;//原料代码
|
||||
string ShowProductName = "是否删除机台【" + this.name.Text + "】" + this.Station.Text;//获取原料信息并拼接提示字符串
|
||||
MessageBoxResult showProductName = System.Windows.MessageBox.Show(ShowProductName, "提示", MessageBoxButton.YesNo, MessageBoxImage.Warning, MessageBoxResult.Yes);//弹窗提示是否删除目标原料
|
||||
if (showProductName == MessageBoxResult.Yes)//判断是否删除原料
|
||||
{
|
||||
var count = new MachinesProvider().Delete(machines_temp);//删除数据库目标信息。
|
||||
if (count == 0) System.Windows.MessageBox.Show("ERR.C0210-2:删除失败", "错误");//判断执行是否成功
|
||||
else Button_sql = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,69 @@
|
||||
<UserControl x:Class="Audit.View.PipesView"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||
xmlns:local="clr-namespace:Audit.View"
|
||||
mc:Ignorable="d"
|
||||
d:DesignHeight="900" d:DesignWidth="1140"
|
||||
xmlns:ConvertMoels="clr-namespace:Audit.ConvertMoels"
|
||||
DataContext="{Binding Source={StaticResource Locator},Path=Pipes}">
|
||||
|
||||
<UserControl.Resources>
|
||||
|
||||
</UserControl.Resources>
|
||||
|
||||
<Grid>
|
||||
<!--布局-->
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="30"/>
|
||||
<RowDefinition/>
|
||||
</Grid.RowDefinitions>
|
||||
<Border BorderThickness="0,0,0,1" BorderBrush="#CCCCCC">
|
||||
</Border>
|
||||
<Grid Grid.Row="0"/>
|
||||
<Grid Grid.Row="1">
|
||||
<!--表-->
|
||||
<DataGrid x:Name="DataGridStatistics" MouseDoubleClick="DataGridStatistics_MouseDoubleClick"
|
||||
ItemsSource="{Binding Pipes, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
SelectionMode="Single" AlternationCount="2" IsReadOnly="True" HorizontalAlignment="Left"
|
||||
Margin="15,15,0,150" d:ItemsSource="{d:SampleData ItemCount=200}" AutoGenerateColumns="False"
|
||||
MinColumnWidth="30" HorizontalGridLinesBrush="#FFC9C9C9" VerticalGridLinesBrush="#FFC9C9C9"
|
||||
GridLinesVisibility="All" BorderBrush="#CCCCCC" BorderThickness="1,1,1,1" ColumnHeaderHeight="40"
|
||||
HorizontalContentAlignment="Right" Grid.ColumnSpan="2" CanUserReorderColumns="False">
|
||||
<DataGrid.RowStyle >
|
||||
<Style TargetType="{x:Type DataGridRow}">
|
||||
<Style.Triggers>
|
||||
<Trigger Property="ItemsControl.AlternationIndex" Value="0">
|
||||
<Setter Property="Background" Value="#FFFFFFFF" />
|
||||
</Trigger>
|
||||
<Trigger Property="ItemsControl.AlternationIndex" Value="1">
|
||||
<Setter Property="Background" Value="#FFF5F5F5" />
|
||||
</Trigger>
|
||||
<Trigger Property="IsMouseOver" Value="False">
|
||||
</Trigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</DataGrid.RowStyle>
|
||||
<DataGrid.CellStyle>
|
||||
<Style TargetType="DataGridCell">
|
||||
<Setter Property="BorderThickness" Value="0"/>
|
||||
<Setter Property="MinWidth" Value="20"/>
|
||||
<Style.Triggers>
|
||||
<Trigger Property="IsSelected" Value="True">
|
||||
<Setter Property="Background" Value="#FFC0C0C0"/>
|
||||
<Setter Property="BorderBrush" Value="#FFC0C0C0"/>
|
||||
<Setter Property="Foreground" Value="#000000"/>
|
||||
</Trigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</DataGrid.CellStyle>
|
||||
<DataGrid.Columns>
|
||||
<!--列信息绑定-->
|
||||
<DataGridTextColumn Header="原料代码" Width="100" FontSize="15" Binding="{Binding ProductCode}" MaxWidth="150" MinWidth="100" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="原料名称" Width="130" FontSize="15" Binding="{Binding ProductName}" MaxWidth="200" MinWidth="50" CanUserReorder="False"/>
|
||||
</DataGrid.Columns>
|
||||
</DataGrid>
|
||||
</Grid>
|
||||
</Grid>
|
||||
</UserControl>
|
||||
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows;
|
||||
using System.Windows.Controls;
|
||||
using System.Windows.Data;
|
||||
using System.Windows.Documents;
|
||||
using System.Windows.Input;
|
||||
using System.Windows.Media;
|
||||
using System.Windows.Media.Imaging;
|
||||
using System.Windows.Navigation;
|
||||
using System.Windows.Shapes;
|
||||
|
||||
namespace Audit.View
|
||||
{
|
||||
/// <summary>
|
||||
/// PipesView.xaml 的交互逻辑
|
||||
/// </summary>
|
||||
public partial class PipesView : UserControl
|
||||
{
|
||||
public PipesView()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
public static Boolean Button_pipessql = true;//全局变量按钮状态
|
||||
|
||||
private void DataGridStatistics_MouseDoubleClick(object sender, MouseButtonEventArgs e)//数据表双击事件
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
+15
-6
@@ -6,7 +6,9 @@
|
||||
xmlns:local="clr-namespace:Audit.View"
|
||||
xmlns:ConvertMoels="clr-namespace:Audit.ConvertMoels"
|
||||
mc:Ignorable="d" DataContext="{Binding Source={StaticResource Locator},Path=Query}"
|
||||
d:DesignHeight="900" d:DesignWidth="1140">
|
||||
d:DesignHeight="900" d:DesignWidth="1140"
|
||||
Loaded="UserControl_Loaded">
|
||||
|
||||
<UserControl.Resources>
|
||||
<ConvertMoels:GramsSQLConvert x:Key="GramsSQLConvert"/>
|
||||
<ConvertMoels:DeviationConvert x:Key="DeviationConvert"/>
|
||||
@@ -19,7 +21,7 @@
|
||||
<Border BorderThickness="0,0,0,1" BorderBrush="#CCCCCC">
|
||||
</Border>
|
||||
<Grid Grid.Row="1">
|
||||
<DataGrid x:Name="DataGridDyelots" MouseDoubleClick="DataGridDyelot_MouseDoubleClick" ItemsSource="{Binding Dyelots}" SelectionMode="Single" AlternationCount="2" IsReadOnly="True" HorizontalAlignment="Left" Margin="15,15,0,150" VerticalAlignment="Stretch" Width="320" d:ItemsSource="{d:SampleData ItemCount=100}" AutoGenerateColumns="False" MinColumnWidth="30" HorizontalGridLinesBrush="#FFC9C9C9" VerticalGridLinesBrush="#FFC9C9C9" GridLinesVisibility="All" BorderBrush="#CCCCCC" BorderThickness="1,1,1,1" ColumnHeaderHeight="40" HorizontalContentAlignment="Right" CanUserReorderColumns="False">
|
||||
<DataGrid x:Name="DataGridDyelots" MouseDoubleClick="DataGridDyelot_MouseDoubleClick" ItemsSource="{Binding Dyelots}" SelectionMode="Single" AlternationCount="2" IsReadOnly="True" HorizontalAlignment="Left" Margin="15,15,0,150" VerticalAlignment="Stretch" Width="335" d:ItemsSource="{d:SampleData ItemCount=100}" AutoGenerateColumns="False" MinColumnWidth="30" HorizontalGridLinesBrush="#FFC9C9C9" VerticalGridLinesBrush="#FFC9C9C9" GridLinesVisibility="All" BorderBrush="#CCCCCC" BorderThickness="1,1,1,1" ColumnHeaderHeight="40" HorizontalContentAlignment="Right" CanUserReorderColumns="False">
|
||||
<DataGrid.RowStyle>
|
||||
<Style TargetType="{x:Type DataGridRow}">
|
||||
<Style.Triggers>
|
||||
@@ -46,13 +48,20 @@
|
||||
</Style>
|
||||
</DataGrid.CellStyle>
|
||||
<DataGrid.Columns>
|
||||
<DataGridTemplateColumn Header="单次" Width="50" MinWidth="10" IsReadOnly="True">
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock FontSize="15" Text="{Binding RelativeSource={RelativeSource Mode=FindAncestor,AncestorType={x:Type DataGridRow}}, Path=Header}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="10,0,0,0"></TextBlock>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<DataGridTextColumn Header="工单" Width="158" FontSize="15" Binding="{Binding Dyelot}" MaxWidth="158" MinWidth="158" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="重染" Width="56" FontSize="15" Binding="{Binding ReDye}" MaxWidth="56" MinWidth="56" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="染机" Width="90" FontSize="15" Binding="{Binding Machine}" MaxWidth="90" MinWidth="90" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="开单时间" Width="200" FontSize="15" Binding="{Binding CreationTime,StringFormat='yyyy-MM-dd HH:mm:ss'}" MaxWidth="0" MinWidth="0" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="开单时间" Width="0" FontSize="15" Binding="{Binding Creation,StringFormat='yyyy-MM-dd HH:mm:ss'}" MaxWidth="0" MinWidth="0" CanUserReorder="False"/>
|
||||
</DataGrid.Columns>
|
||||
</DataGrid>
|
||||
<DataGrid x:Name="DataGridDyelotsBulkedRecipe" ItemsSource="{Binding DyelotsBulkedRecipe}" SelectionMode="Single" AlternationCount="2" IsReadOnly="True" HorizontalAlignment="Left" Margin="350,15,15,150" VerticalAlignment="Stretch" d:ItemsSource="{d:SampleData ItemCount=200}" AutoGenerateColumns="False" MinColumnWidth="30" HorizontalGridLinesBrush="#FFC9C9C9" VerticalGridLinesBrush="#FFC9C9C9" GridLinesVisibility="All" BorderBrush="#CCCCCC" BorderThickness="1,1,1,1" ColumnHeaderHeight="40" HorizontalContentAlignment="Right" CanUserReorderColumns="False">
|
||||
<DataGrid x:Name="DataGridDyelotsBulkedRecipe" ItemsSource="{Binding DyelotsBulkedRecipe}" SelectionMode="Single" AlternationCount="2" IsReadOnly="True" HorizontalAlignment="Left" Margin="365,15,15,150" VerticalAlignment="Stretch" d:ItemsSource="{d:SampleData ItemCount=200}" AutoGenerateColumns="False" MinColumnWidth="30" HorizontalGridLinesBrush="#FFC9C9C9" VerticalGridLinesBrush="#FFC9C9C9" GridLinesVisibility="All" BorderBrush="#CCCCCC" BorderThickness="1,1,1,1" ColumnHeaderHeight="40" HorizontalContentAlignment="Right" CanUserReorderColumns="False">
|
||||
<DataGrid.RowStyle >
|
||||
<Style TargetType="{x:Type DataGridRow}">
|
||||
<Style.Triggers>
|
||||
@@ -95,15 +104,15 @@
|
||||
</DataGridTextColumn.ElementStyle>
|
||||
</DataGridTextColumn>
|
||||
<!--事件名称:偏差值计算,转换器DeviationConvert-->
|
||||
<DataGridTextColumn Header="偏差" Width="70" FontSize="15" MinWidth="70" MaxWidth="150" CanUserReorder="False">
|
||||
<DataGridTextColumn Header="偏差" Width="0" FontSize="15" MinWidth="0" MaxWidth="150" CanUserReorder="False">
|
||||
<DataGridTextColumn.Binding>
|
||||
<MultiBinding StringFormat="{}{0}" Converter="{StaticResource DeviationConvert}">
|
||||
<Binding Path="Grams"></Binding>
|
||||
<Binding Path="DispenseGrams"></Binding>
|
||||
</MultiBinding>
|
||||
</DataGridTextColumn.Binding>
|
||||
|
||||
</DataGridTextColumn>
|
||||
<DataGridTextColumn Header="开始时间" Width="300" FontSize="15" Binding="{Binding DispenseStartTime,StringFormat='yyyy-MM-dd HH:mm:ss'}" MaxWidth="200" MinWidth="500" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="结束时间" Width="300" FontSize="15" Binding="{Binding DispenseEndTime,StringFormat='yyyy-MM-dd HH:mm:ss'}" MaxWidth="200" MinWidth="500" CanUserReorder="False"/>
|
||||
</DataGrid.Columns>
|
||||
</DataGrid>
|
||||
|
||||
+29
-10
@@ -27,18 +27,35 @@ namespace Audit.View
|
||||
public QueryView()
|
||||
{
|
||||
InitializeComponent();
|
||||
this.DataGridDyelots.LoadingRow += new EventHandler<DataGridRowEventArgs>(this.DataGridEquipment_LoadingRow);//生成序列号
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 生成序列号的方法
|
||||
/// </summary>
|
||||
private void DataGridEquipment_LoadingRow(object sender, DataGridRowEventArgs e)
|
||||
{
|
||||
e.Row.Header = e.Row.GetIndex() + 1;
|
||||
}
|
||||
|
||||
public static string query_start = null;//全局变量开始时间
|
||||
public static string query_end = null;//全局变量结束时间
|
||||
private void UserControl_Loaded(object sender, RoutedEventArgs e)//打开页面执行
|
||||
{
|
||||
this.query_date_start.Text = DateTime.Now.ToString("yyyy-MM-dd");//填入当天时间
|
||||
this.query_date_end.Text = DateTime.Now.ToString("yyyy-MM-dd");//填入当天时间
|
||||
}
|
||||
|
||||
//public static string Dyelots_Button = null;
|
||||
public static int sqlButton_Click=0;
|
||||
public static int sqlButton_Click=10;
|
||||
public static Dyelots Dyelots_Button = new Dyelots();
|
||||
public static DyelotsBulkedRecipe DyelotsBulkedRecipe_Button = new DyelotsBulkedRecipe();
|
||||
private void Button_Click(object sender, RoutedEventArgs e)//确认按钮事件
|
||||
{
|
||||
string DataGridDyelots_Button = this.Dyelots_Dyelot.Text;//传递工单输入框
|
||||
string DataGridMachine_Button = this.Dyelots_Machine.Text;//传递机台输入框
|
||||
string query_start = this.query_date_start.Text;//传递开始时间
|
||||
string query_end = this.query_date_end.Text;//传递结束时间
|
||||
query_start = this.query_date_start.Text;//传递开始时间
|
||||
query_end = this.query_date_end.Text;//传递结束时间
|
||||
if (string.IsNullOrWhiteSpace(DataGridDyelots_Button))//工单为空进入下一步判断
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(query_start) && string.IsNullOrWhiteSpace(query_end))//判断查询时间是否存在
|
||||
@@ -47,7 +64,9 @@ namespace Audit.View
|
||||
}
|
||||
else
|
||||
{
|
||||
query_end = DateTime.Now.AddDays(1).ToString("yyyy-MM-dd");
|
||||
string t =DateTime.Now.ToString("yyyy-MM-dd");
|
||||
int query_endT = DateTime.Compare(Convert.ToDateTime(query_end), Convert.ToDateTime(t)); //比较结束时间及当期,小于-1 等于0 大于1
|
||||
if(query_endT == 0) query_end = DateTime.Now.AddDays(1).ToString("yyyy-MM-dd"); //如果结束时间为空则填入当天时间加1天
|
||||
int query_TimeCompare = DateTime.Compare(Convert.ToDateTime(query_start), Convert.ToDateTime(query_end)); //比较开始结束时间,小于-1 等于0 大于1
|
||||
if (query_TimeCompare == 1)//判断查询时间是否有效,等于1无效
|
||||
{
|
||||
@@ -84,13 +103,13 @@ namespace Audit.View
|
||||
int rownum = this.DataGridDyelots.SelectedIndex;//获取鼠标选中行并定义变量
|
||||
if (rownum != -1)
|
||||
{
|
||||
string DataGridDyelots_value = (DataGridDyelots.Columns[0].GetCellContent(DataGridDyelots.Items[rownum]) as TextBlock).Text;//定位第0列选中行单元格,单号
|
||||
string DataGridReDye_value = (DataGridDyelots.Columns[1].GetCellContent(DataGridDyelots.Items[rownum]) as TextBlock).Text;//定位第1列选中行单元格,重染
|
||||
//string DataGridMachine_value = (DataGridDyelots.Columns[2].GetCellContent(DataGridDyelots.Items[rownum]) as TextBlock).Text;//定位第2列选中行单元格,机台
|
||||
string DataGridCreationTime_value = (DataGridDyelots.Columns[3].GetCellContent(DataGridDyelots.Items[rownum]) as TextBlock).Text;//定位第3列选中行单元格,开单时间
|
||||
//Dyelots_Dyelot.Text = DataGridDyelots_value.ToString();//获取工单单元格字符串填入工单输入框
|
||||
string DataGridDyelots_value = (DataGridDyelots.Columns[1].GetCellContent(DataGridDyelots.Items[rownum]) as TextBlock).Text;//定位第0列选中行单元格,单号
|
||||
string DataGridReDye_value = (DataGridDyelots.Columns[2].GetCellContent(DataGridDyelots.Items[rownum]) as TextBlock).Text;//定位第1列选中行单元格,重染
|
||||
string DataGridMachine_value = (DataGridDyelots.Columns[3].GetCellContent(DataGridDyelots.Items[rownum]) as TextBlock).Text;//定位第2列选中行单元格,机台
|
||||
string DataGridCreationTime_value = (DataGridDyelots.Columns[4].GetCellContent(DataGridDyelots.Items[rownum]) as TextBlock).Text;//定位第3列选中行单元格,开单时间
|
||||
Dyelots_Dyelot.Text = DataGridDyelots_value.ToString();//获取工单单元格字符串填入工单输入框
|
||||
Dyelots_ReDye.Text = DataGridReDye_value.ToString(); //获取重染单元格字符串填入重染框
|
||||
//Dyelots_Machine.Text = DataGridMachine_value.ToString();//获取机台单元格字符串填入机台输入框
|
||||
Dyelots_Machine.Text = DataGridMachine_value.ToString();//获取机台单元格字符串填入机台输入框
|
||||
Dyelots_CreationTime.Text = DataGridCreationTime_value.ToString();//获取开单时间单元格字符串填入开单时间框
|
||||
DyelotsBulkedRecipe_Button.Dyelot = DataGridDyelots_value;//传递工单信息至sql实例
|
||||
sqlButton_Click = 2;//传递按钮信息以查询
|
||||
|
||||
+165
-6
@@ -4,12 +4,19 @@
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||
xmlns:local="clr-namespace:Audit.View"
|
||||
xmlns:ConvertMoels="clr-namespace:Audit.ConvertMoels"
|
||||
mc:Ignorable="d" DataContext="{Binding Source={StaticResource Locator},Path=Statistics}"
|
||||
d:DesignHeight="900" d:DesignWidth="1140"
|
||||
Loaded="UserControl_Loaded"
|
||||
xmlns:mah="clr-namespace:MahApps.Metro.Controls;assembly=MahApps.Metro">
|
||||
<UserControl.Resources>
|
||||
|
||||
<UserControl.Resources>
|
||||
<ConvertMoels:ConsumptionConvert x:Key="ConsumptionConvert"/>
|
||||
<ConvertMoels:GramsSumConvert x:Key="GramsSumConvert"/>
|
||||
<ConvertMoels:MachinesGramsSumConvert x:Key="MachinesGramsSumConvert"/>
|
||||
<ConvertMoels:MachinesDyelotsNumberConvert x:Key="MachinesDyelotsNumberConvert"/>
|
||||
</UserControl.Resources>
|
||||
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="30"/>
|
||||
@@ -19,11 +26,163 @@
|
||||
</Border>
|
||||
<Grid Grid.Row="0"/>
|
||||
<Grid Grid.Row="1">
|
||||
<Grid Grid.Column="1">
|
||||
<ContentControl x:Name="ContentControl" Margin="0,31,0,0">
|
||||
<Label Content="统计" HorizontalAlignment="Left" Height="195" Margin="390,179,0,0" VerticalAlignment="Top" Width="530" FontSize="48" Background="{x:Null}"/>
|
||||
</ContentControl>
|
||||
</Grid>
|
||||
<Grid Grid.Column="1"/>
|
||||
<DataGrid x:Name="DataGridStatistics" MouseDoubleClick="DataGridStatistics_MouseDoubleClick"
|
||||
ItemsSource="{Binding Product, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
SelectionMode="Single" AlternationCount="2" IsReadOnly="True" HorizontalAlignment="Left"
|
||||
Margin="15,15,0,150" d:ItemsSource="{d:SampleData ItemCount=200}" AutoGenerateColumns="False"
|
||||
MinColumnWidth="30" HorizontalGridLinesBrush="#FFC9C9C9" VerticalGridLinesBrush="#FFC9C9C9"
|
||||
GridLinesVisibility="All" BorderBrush="#CCCCCC" BorderThickness="1,1,1,1" ColumnHeaderHeight="40"
|
||||
HorizontalContentAlignment="Right" Grid.ColumnSpan="2" CanUserReorderColumns="False">
|
||||
<DataGrid.RowStyle >
|
||||
<Style TargetType="{x:Type DataGridRow}">
|
||||
<Style.Triggers>
|
||||
<Trigger Property="ItemsControl.AlternationIndex" Value="0">
|
||||
<Setter Property="Background" Value="#FFFFFFFF" />
|
||||
</Trigger>
|
||||
<Trigger Property="ItemsControl.AlternationIndex" Value="1">
|
||||
<Setter Property="Background" Value="#FFF5F5F5" />
|
||||
</Trigger>
|
||||
<Trigger Property="IsMouseOver" Value="False">
|
||||
</Trigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</DataGrid.RowStyle>
|
||||
<DataGrid.CellStyle>
|
||||
<Style TargetType="DataGridCell">
|
||||
<Setter Property="BorderThickness" Value="0"/>
|
||||
<Setter Property="MinWidth" Value="20"/>
|
||||
<Style.Triggers>
|
||||
<Trigger Property="IsSelected" Value="True">
|
||||
<Setter Property="Background" Value="#FFC0C0C0"/>
|
||||
<Setter Property="BorderBrush" Value="#FFC0C0C0"/>
|
||||
<Setter Property="Foreground" Value="#000000"/>
|
||||
</Trigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</DataGrid.CellStyle>
|
||||
<DataGrid.Columns>
|
||||
<!--列信息绑定-->
|
||||
<DataGridTextColumn Header="原料代码" Width="100" FontSize="15" Binding="{Binding ProductCode}" MaxWidth="150" MinWidth="100" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="原料名称" Width="130" FontSize="15" Binding="{Binding ProductName}" MaxWidth="200" MinWidth="50" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="单价(¥/kg)" Width="0" FontSize="15" Binding="{Binding Price}" MaxWidth="0" MinWidth="0" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="总消耗(kg)" Width="120" FontSize="15" MaxWidth="200" MinWidth="100" CanUserReorder="False">
|
||||
<!--事件名称:消耗总量计算,转换器ConsumptionConvert-->
|
||||
<DataGridTextColumn.ElementStyle>
|
||||
<Style TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="Text" Value="{Binding Path=ProductCode,Converter={StaticResource ConsumptionConvert}}">
|
||||
</Setter>
|
||||
<Setter Property="TextAlignment" Value="Right"/>
|
||||
</Style>
|
||||
</DataGridTextColumn.ElementStyle>
|
||||
</DataGridTextColumn>
|
||||
<DataGridTextColumn Header="总金额(¥)" Width="0" FontSize="15" MaxWidth="0" MinWidth="0" CanUserReorder="False">
|
||||
<!--事件名称:总价计算,转换器GramsSumConvert-->
|
||||
<DataGridTextColumn.Binding>
|
||||
<MultiBinding StringFormat="{}{0}" Converter="{StaticResource GramsSumConvert}">
|
||||
<Binding Path="ProductCode"></Binding>
|
||||
<Binding Path="Price"></Binding>
|
||||
</MultiBinding>
|
||||
</DataGridTextColumn.Binding>
|
||||
</DataGridTextColumn>
|
||||
</DataGrid.Columns>
|
||||
</DataGrid>
|
||||
<DatePicker x:Name="query_date_start" HorizontalAlignment="Left" Height="30" Margin="450,0,0,100" VerticalAlignment="Bottom" Width="225" FontSize="15" Padding="1,1,0,1">
|
||||
<DatePicker.Resources>
|
||||
<Style TargetType="DatePickerTextBox">
|
||||
<Setter Property="IsReadOnly" Value="True"/>
|
||||
</Style>
|
||||
</DatePicker.Resources>
|
||||
</DatePicker>
|
||||
<DatePicker x:Name="query_date_end" HorizontalAlignment="Left" Height="30" Margin="715,0,0,100" VerticalAlignment="Bottom" Width="225" FontSize="15" Padding="1,1,0,1" DisplayDate="2022-03-08">
|
||||
<DatePicker.Resources>
|
||||
<Style TargetType="DatePickerTextBox">
|
||||
<Setter Property="IsReadOnly" Value="True"/>
|
||||
<Setter Property="Text" Value=""/>
|
||||
</Style>
|
||||
</DatePicker.Resources>
|
||||
</DatePicker>
|
||||
<TextBlock HorizontalAlignment="Left" Height="45" Margin="675,0,0,101" TextWrapping="Wrap" Text="~"
|
||||
VerticalAlignment="Bottom" Width="40" FontSize="40"/>
|
||||
<Button Content="统计" HorizontalAlignment="Left" Margin="965,0,0,50"
|
||||
VerticalAlignment="Bottom" Height="65" Width="135" FontSize="40"
|
||||
BorderBrush="{x:Null}" Background="#FFCECECE" Click="Button_Click"/>
|
||||
<!--原料类型-->
|
||||
<ComboBox x:Name="stuff_ProductType" HorizontalAlignment="Left" Height="30" Margin="815,0,0,50" Text="全部原料"
|
||||
VerticalAlignment="Bottom" Width="125" FontSize="16" IsReadOnly="True" IsEditable="True">
|
||||
<ComboBoxItem Content="全部原料"></ComboBoxItem>
|
||||
<ComboBoxItem Content="染料"></ComboBoxItem>
|
||||
<ComboBoxItem Content="助剂"></ComboBoxItem>
|
||||
<ComboBoxItem Content="粉体助剂"></ComboBoxItem>
|
||||
<ComboBoxItem Content="液体染料"></ComboBoxItem>
|
||||
</ComboBox>
|
||||
<TextBox x:Name="productcode" HorizontalAlignment="Left" Height="30" Margin="100,0,0,100" VerticalAlignment="Bottom" Width="235" FontSize="16" IsReadOnly="True" MaxLines="1"/>
|
||||
<TextBox x:Name="productname" HorizontalAlignment="Left" Height="30" Margin="100,0,0,50" VerticalAlignment="Bottom" Width="235" FontSize="16" IsReadOnly="True" MaxLines="1"/>
|
||||
<TextBox x:Name="productsum" HorizontalAlignment="Left" Height="30" Margin="450,0,0,50" VerticalAlignment="Bottom" Width="235" FontSize="16" IsReadOnly="True" MaxLines="1"/>
|
||||
<TextBlock HorizontalAlignment="Left" Height="30" Margin="725,0,0,50" TextWrapping="Wrap" Text="原料类型"
|
||||
VerticalAlignment="Bottom" Width="90" FontSize="20"/>
|
||||
<TextBlock HorizontalAlignment="Left" Height="30" Margin="350,0,0,100" TextWrapping="Wrap" Text="日期范围"
|
||||
VerticalAlignment="Bottom" Width="90" FontSize="20"/>
|
||||
<TextBlock HorizontalAlignment="Left" Height="30" Margin="15,0,0,100" TextWrapping="Wrap" Text="原料代码"
|
||||
VerticalAlignment="Bottom" Width="90" FontSize="20"/>
|
||||
<TextBlock HorizontalAlignment="Left" Height="30" Margin="15,0,0,50" TextWrapping="Wrap" Text="原料名称"
|
||||
VerticalAlignment="Bottom" Width="90" FontSize="20"/>
|
||||
<TextBlock HorizontalAlignment="Left" Height="30" Margin="350,0,0,50" TextWrapping="Wrap" Text="消耗总量"
|
||||
VerticalAlignment="Bottom" Width="90" FontSize="20"/>
|
||||
<DataGrid x:Name="DataGridStatistics_Copy"
|
||||
ItemsSource="{Binding Machines , Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
SelectionMode="Single" AlternationCount="2" IsReadOnly="True" HorizontalAlignment="Left"
|
||||
Margin="400,15,0,150" d:ItemsSource="{d:SampleData ItemCount=200}" AutoGenerateColumns="False"
|
||||
MinColumnWidth="30" HorizontalGridLinesBrush="#FFC9C9C9" VerticalGridLinesBrush="#FFC9C9C9"
|
||||
GridLinesVisibility="All" BorderBrush="#CCCCCC" BorderThickness="1,1,1,1" ColumnHeaderHeight="40"
|
||||
HorizontalContentAlignment="Right" CanUserReorderColumns="False" SelectionChanged="DataGridStatistics_Copy_SelectionChanged">
|
||||
<DataGrid.RowStyle >
|
||||
<Style TargetType="{x:Type DataGridRow}">
|
||||
<Style.Triggers>
|
||||
<Trigger Property="ItemsControl.AlternationIndex" Value="0">
|
||||
<Setter Property="Background" Value="#FFFFFFFF" />
|
||||
</Trigger>
|
||||
<Trigger Property="ItemsControl.AlternationIndex" Value="1">
|
||||
<Setter Property="Background" Value="#FFF5F5F5" />
|
||||
</Trigger>
|
||||
<Trigger Property="IsMouseOver" Value="False"/>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</DataGrid.RowStyle>
|
||||
<DataGrid.CellStyle>
|
||||
<Style TargetType="{x:Type DataGridCell}">
|
||||
<Setter Property="BorderThickness" Value="0"/>
|
||||
<Setter Property="MinWidth" Value="20"/>
|
||||
<Style.Triggers>
|
||||
<Trigger Property="IsSelected" Value="True">
|
||||
<Setter Property="Background" Value="#FFC0C0C0"/>
|
||||
<Setter Property="BorderBrush" Value="#FFC0C0C0"/>
|
||||
<Setter Property="Foreground" Value="#000000"/>
|
||||
</Trigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</DataGrid.CellStyle>
|
||||
<DataGrid.Columns>
|
||||
<!--列信息绑定-->
|
||||
<DataGridTextColumn Header="机台" Width="100" FontSize="15" Binding="{Binding Name}" MaxWidth="150" MinWidth="100" CanUserReorder="False"/>
|
||||
<DataGridTextColumn Header="机台消耗(kg)" Width="120" FontSize="15" MaxWidth="180" MinWidth="100" CanUserReorder="False">
|
||||
<DataGridTextColumn.ElementStyle>
|
||||
<Style TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="Text" Value="{Binding Path=Name,Converter={StaticResource MachinesGramsSumConvert}}"/>
|
||||
<Setter Property="TextAlignment" Value="Right"/>
|
||||
</Style>
|
||||
</DataGridTextColumn.ElementStyle>
|
||||
</DataGridTextColumn>
|
||||
<DataGridTextColumn Header="料单数量" Width="70" FontSize="15" MaxWidth="150" MinWidth="50" CanUserReorder="False">
|
||||
<DataGridTextColumn.ElementStyle>
|
||||
<Style TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="Text" Value="{Binding Path=Name,Converter={StaticResource MachinesDyelotsNumberConvert}}"/>
|
||||
<Setter Property="TextAlignment" Value="Right"/>
|
||||
</Style>
|
||||
</DataGridTextColumn.ElementStyle>
|
||||
</DataGridTextColumn>
|
||||
</DataGrid.Columns>
|
||||
</DataGrid>
|
||||
</Grid>
|
||||
</Grid>
|
||||
</UserControl>
|
||||
@@ -27,5 +27,66 @@ namespace Audit.View
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
public static string DataGridStatistics_ProductCode = null;
|
||||
public static Boolean Button_machines_sql = false;
|
||||
private void DataGridStatistics_MouseDoubleClick(object sender, MouseButtonEventArgs e)//数据表双击事件
|
||||
{
|
||||
int rownum = DataGridStatistics.SelectedIndex;//获取鼠标选中行并定义变量
|
||||
if (rownum != -1)//判断鼠标定位是否有效
|
||||
{
|
||||
/*定位选中行及指定列单元格文本信息*/
|
||||
DataGridStatistics_ProductCode = (DataGridStatistics.Columns[0].GetCellContent(DataGridStatistics.Items[rownum]) as TextBlock).Text;//定位第0列,原料代码
|
||||
string DataGridStatistics_ProductName = (DataGridStatistics.Columns[1].GetCellContent(DataGridStatistics.Items[rownum]) as TextBlock).Text;//定位第1列,原料名称
|
||||
string DataGridStatistics_unit_price = (DataGridStatistics.Columns[2].GetCellContent(DataGridStatistics.Items[rownum]) as TextBlock).Text;//定位第2列,原料名称
|
||||
string DataGridStatistics_sum = (DataGridStatistics.Columns[3].GetCellContent(DataGridStatistics.Items[rownum]) as TextBlock).Text;//定位第3列,原料名称
|
||||
string DataGridStatistics_total_price = (DataGridStatistics.Columns[4].GetCellContent(DataGridStatistics.Items[rownum]) as TextBlock).Text;//定位第4列,原料名称
|
||||
this.productname.Text = DataGridStatistics_ProductName;//填入原料名
|
||||
this.productcode.Text = DataGridStatistics_ProductCode;//填入
|
||||
this.productsum.Text = DataGridStatistics_sum + "KG";//填入
|
||||
Button_machines_sql = true;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public static string query_start = null;//全局变量开始时间
|
||||
public static string query_end = null;//全局变量结束时间
|
||||
private void UserControl_Loaded(object sender, RoutedEventArgs e)//打开页面执行
|
||||
{
|
||||
this.query_date_start.Text = DateTime.Now.AddDays(-30).ToString("yyyy-MM-dd");//填入当天时间前30天
|
||||
this.query_date_end.Text = DateTime.Now.ToString("yyyy-MM-dd");//填入当天时间
|
||||
}
|
||||
|
||||
public static int Buttontype_sql = -2;//全局变量原料类型
|
||||
public static Boolean Button_sql = true;//全局变量按钮状态
|
||||
private void Button_Click(object sender, RoutedEventArgs e)
|
||||
{
|
||||
query_start = this.query_date_start.Text;//传递开始时间
|
||||
query_end = this.query_date_end.Text;//传递结束时间
|
||||
string t =DateTime.Now.ToString("yyyy-MM-dd");
|
||||
int query_endT = DateTime.Compare(Convert.ToDateTime(query_end), Convert.ToDateTime(t)); //比较结束时间及当期,小于-1 等于0 大于1
|
||||
if (query_endT == 0) query_end = DateTime.Now.AddDays(1).ToString("yyyy-MM-dd"); //如果结束时间为空则填入当天时间加1天
|
||||
if (query_end == DateTime.Now.ToString("yyyy-MM-dd")) query_end = DateTime.Now.AddDays(1).ToString("yyyy-MM-dd");
|
||||
int query_TimeCompare = DateTime.Compare(Convert.ToDateTime(query_start), Convert.ToDateTime(query_end)); //比较开始结束时间,小于-1 等于0 大于1
|
||||
if (query_TimeCompare == 1)//判断查询时间是否有效,等于1无效
|
||||
{
|
||||
MessageBox.Show("SC:无效查询时间", "错误");//返回无效时间弹窗
|
||||
}
|
||||
else
|
||||
{
|
||||
if (this.stuff_ProductType.Text == "染料") Buttontype_sql = 0;//原料类型0。染料,1助剂,2粉体
|
||||
if (this.stuff_ProductType.Text == "助剂") Buttontype_sql = 1;
|
||||
if (this.stuff_ProductType.Text == "粉体助剂") Buttontype_sql = 2;
|
||||
if (this.stuff_ProductType.Text == "液体染料") Buttontype_sql = 3;
|
||||
if (this.stuff_ProductType.Text == "全部原料") Buttontype_sql = -1;
|
||||
Button_sql = true;
|
||||
}
|
||||
}
|
||||
|
||||
private void DataGridStatistics_Copy_SelectionChanged(object sender, SelectionChangedEventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
Loaded 100 of 112 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user