添加项目文件。
99
CleanMachineHMI.Model/CleanMachineHMI.Domain.csproj
Normal file
@@ -0,0 +1,99 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||||
|
<PropertyGroup>
|
||||||
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||||
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||||
|
<ProjectGuid>{F7AF907B-5DDC-469F-956C-08C5FD110448}</ProjectGuid>
|
||||||
|
<OutputType>Library</OutputType>
|
||||||
|
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||||
|
<RootNamespace>CleanMachineHMI.Domain</RootNamespace>
|
||||||
|
<AssemblyName>CleanMachineHMI.Domain</AssemblyName>
|
||||||
|
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
|
||||||
|
<FileAlignment>512</FileAlignment>
|
||||||
|
<Deterministic>true</Deterministic>
|
||||||
|
<TargetFrameworkProfile />
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||||
|
<DebugSymbols>true</DebugSymbols>
|
||||||
|
<DebugType>full</DebugType>
|
||||||
|
<Optimize>false</Optimize>
|
||||||
|
<OutputPath>bin\Debug\</OutputPath>
|
||||||
|
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
<WarningLevel>4</WarningLevel>
|
||||||
|
<Prefer32Bit>false</Prefer32Bit>
|
||||||
|
<PlatformTarget>x64</PlatformTarget>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||||
|
<DebugType>pdbonly</DebugType>
|
||||||
|
<Optimize>true</Optimize>
|
||||||
|
<OutputPath>bin\Release\</OutputPath>
|
||||||
|
<DefineConstants>TRACE</DefineConstants>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
<WarningLevel>4</WarningLevel>
|
||||||
|
<Prefer32Bit>false</Prefer32Bit>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x64'">
|
||||||
|
<DebugSymbols>true</DebugSymbols>
|
||||||
|
<OutputPath>bin\x64\Debug\</OutputPath>
|
||||||
|
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||||
|
<DebugType>full</DebugType>
|
||||||
|
<PlatformTarget>x64</PlatformTarget>
|
||||||
|
<LangVersion>7.3</LangVersion>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x64'">
|
||||||
|
<OutputPath>bin\x64\Release\</OutputPath>
|
||||||
|
<DefineConstants>TRACE</DefineConstants>
|
||||||
|
<Optimize>true</Optimize>
|
||||||
|
<DebugType>pdbonly</DebugType>
|
||||||
|
<PlatformTarget>x64</PlatformTarget>
|
||||||
|
<LangVersion>7.3</LangVersion>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x86'">
|
||||||
|
<DebugSymbols>true</DebugSymbols>
|
||||||
|
<OutputPath>bin\x86\Debug\</OutputPath>
|
||||||
|
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||||
|
<DebugType>full</DebugType>
|
||||||
|
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||||
|
<LangVersion>7.3</LangVersion>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x86'">
|
||||||
|
<OutputPath>bin\x86\Release\</OutputPath>
|
||||||
|
<DefineConstants>TRACE</DefineConstants>
|
||||||
|
<Optimize>true</Optimize>
|
||||||
|
<DebugType>pdbonly</DebugType>
|
||||||
|
<PlatformTarget>x86</PlatformTarget>
|
||||||
|
<LangVersion>7.3</LangVersion>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
</PropertyGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Reference Include="ComponentFactory.Krypton.Toolkit, Version=4.6.0.0, Culture=neutral, PublicKeyToken=a87e673e9ecb6e8e, processorArchitecture=MSIL">
|
||||||
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<HintPath>..\public\ComponentFactory.Krypton.Toolkit.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="System" />
|
||||||
|
<Reference Include="System.Core" />
|
||||||
|
<Reference Include="System.Windows.Forms" />
|
||||||
|
<Reference Include="System.Xml.Linq" />
|
||||||
|
<Reference Include="System.Data.DataSetExtensions" />
|
||||||
|
<Reference Include="Microsoft.CSharp" />
|
||||||
|
<Reference Include="System.Data" />
|
||||||
|
<Reference Include="System.Xml" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Compile Include="Enums\EnumFormType.cs" />
|
||||||
|
<Compile Include="Enums\EnumOperateType.cs" />
|
||||||
|
<Compile Include="Models\ViewModels\FormModel.cs" />
|
||||||
|
<Compile Include="Models\ViewModels\UserInfo.cs" />
|
||||||
|
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Folder Include="Models\ConditionModels\" />
|
||||||
|
<Folder Include="Models\ResultModels\" />
|
||||||
|
</ItemGroup>
|
||||||
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
|
</Project>
|
||||||
38
CleanMachineHMI.Model/Enums/EnumFormType.cs
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.Domain.Enums
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 窗体类别
|
||||||
|
/// </summary>
|
||||||
|
public enum EnumFormType
|
||||||
|
{
|
||||||
|
Main,
|
||||||
|
MainDetail,
|
||||||
|
MechineCheck,
|
||||||
|
Login,
|
||||||
|
Manual,
|
||||||
|
Parameter,
|
||||||
|
WorkingDataRecord,
|
||||||
|
PlcItemConfig,
|
||||||
|
PlcAlarmLog,
|
||||||
|
IoMonitor,
|
||||||
|
CurrWorkingIR,
|
||||||
|
CleanMode,
|
||||||
|
ContaminationDTL,
|
||||||
|
ContaminationType,
|
||||||
|
Role,
|
||||||
|
User,
|
||||||
|
SheetType,
|
||||||
|
Warning,
|
||||||
|
WorkingPallet,
|
||||||
|
Log,
|
||||||
|
Base,
|
||||||
|
DataSearch,
|
||||||
|
WarningLog,
|
||||||
|
Maintenance
|
||||||
|
}
|
||||||
|
}
|
||||||
19
CleanMachineHMI.Model/Enums/EnumOperateType.cs
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.Domain.Enums
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 操作类型
|
||||||
|
/// </summary>
|
||||||
|
public enum EnumOperateType
|
||||||
|
{
|
||||||
|
Add,
|
||||||
|
Edit,
|
||||||
|
Deleted,
|
||||||
|
Select,
|
||||||
|
}
|
||||||
|
}
|
||||||
20
CleanMachineHMI.Model/Models/ViewModels/FormModel.cs
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.Domain.Models.ViewModels
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 窗体模型
|
||||||
|
/// </summary>
|
||||||
|
public class FormModel<T> where T : Type
|
||||||
|
{
|
||||||
|
public T Form { get; set; }
|
||||||
|
|
||||||
|
public EnumFormType FormType { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
32
CleanMachineHMI.Model/Models/ViewModels/UserInfo.cs
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.Domain.Models.ViewModels
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 用户信息
|
||||||
|
/// </summary>
|
||||||
|
public class UserInfo
|
||||||
|
{
|
||||||
|
public int USER_ID { get; set; }
|
||||||
|
|
||||||
|
public string USER_CODE { get; set; }
|
||||||
|
|
||||||
|
public string USER_NAME { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 性别.0:男;1:女。
|
||||||
|
/// </summary>
|
||||||
|
public int GENDER { get; set; }
|
||||||
|
|
||||||
|
public string SCHEDULE_CODE { get; set; }
|
||||||
|
public int ROLE_ID { get; set; }
|
||||||
|
|
||||||
|
public int ROLE_GRADE { get; set; }
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
36
CleanMachineHMI.Model/Properties/AssemblyInfo.cs
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
using System.Reflection;
|
||||||
|
using System.Runtime.CompilerServices;
|
||||||
|
using System.Runtime.InteropServices;
|
||||||
|
|
||||||
|
// 有关程序集的一般信息由以下
|
||||||
|
// 控制。更改这些特性值可修改
|
||||||
|
// 与程序集关联的信息。
|
||||||
|
[assembly: AssemblyTitle("CleanMachineHMI.Domain")]
|
||||||
|
[assembly: AssemblyDescription("")]
|
||||||
|
[assembly: AssemblyConfiguration("")]
|
||||||
|
[assembly: AssemblyCompany("")]
|
||||||
|
[assembly: AssemblyProduct("CleanMachineHMI.Domain")]
|
||||||
|
[assembly: AssemblyCopyright("Copyright © 2020")]
|
||||||
|
[assembly: AssemblyTrademark("")]
|
||||||
|
[assembly: AssemblyCulture("")]
|
||||||
|
|
||||||
|
// 将 ComVisible 设置为 false 会使此程序集中的类型
|
||||||
|
//对 COM 组件不可见。如果需要从 COM 访问此程序集中的类型
|
||||||
|
//请将此类型的 ComVisible 特性设置为 true。
|
||||||
|
[assembly: ComVisible(false)]
|
||||||
|
|
||||||
|
// 如果此项目向 COM 公开,则下列 GUID 用于类型库的 ID
|
||||||
|
[assembly: Guid("f7af907b-5ddc-469f-956c-08c5fd110448")]
|
||||||
|
|
||||||
|
// 程序集的版本信息由下列四个值组成:
|
||||||
|
//
|
||||||
|
// 主版本
|
||||||
|
// 次版本
|
||||||
|
// 生成号
|
||||||
|
// 修订号
|
||||||
|
//
|
||||||
|
//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值
|
||||||
|
//通过使用 "*",如下所示:
|
||||||
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
|
[assembly: AssemblyVersion("1.0.0.0")]
|
||||||
|
[assembly: AssemblyFileVersion("1.0.0.0")]
|
||||||
88
CleanMachineHMI.sln
Normal file
@@ -0,0 +1,88 @@
|
|||||||
|
|
||||||
|
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||||
|
# Visual Studio Version 16
|
||||||
|
VisualStudioVersion = 16.0.30330.147
|
||||||
|
MinimumVisualStudioVersion = 10.0.40219.1
|
||||||
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CleanMachineHMI", "CleanMachineHMI\CleanMachineHMI.csproj", "{9CF77369-B471-4476-9F42-779945113EA5}"
|
||||||
|
EndProject
|
||||||
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CleanMachineHMI.Domain", "CleanMachineHMI.Model\CleanMachineHMI.Domain.csproj", "{F7AF907B-5DDC-469F-956C-08C5FD110448}"
|
||||||
|
EndProject
|
||||||
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LeadDataBaseUtility", "LeadDataBaseUtility\LeadDataBaseUtility.csproj", "{824348A6-FFFF-4C1B-BBF5-8B507A8C8CE5}"
|
||||||
|
EndProject
|
||||||
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NX_LogUtility", "NX_LogUtility\NX_LogUtility.csproj", "{925057D8-7EE8-42ED-8AA0-628AF82F10B2}"
|
||||||
|
EndProject
|
||||||
|
Project("{54435603-DBB4-11D2-8724-00A0C9A8B90C}") = "CleanMachineSoftware_Setup", "CleanMachineSoftware_Setup\CleanMachineSoftware_Setup.vdproj", "{497A7E73-E2E8-4134-93CA-8F6A5B72D992}"
|
||||||
|
EndProject
|
||||||
|
Global
|
||||||
|
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||||
|
Debug|Any CPU = Debug|Any CPU
|
||||||
|
Debug|x64 = Debug|x64
|
||||||
|
Debug|x86 = Debug|x86
|
||||||
|
Release|Any CPU = Release|Any CPU
|
||||||
|
Release|x64 = Release|x64
|
||||||
|
Release|x86 = Release|x86
|
||||||
|
EndGlobalSection
|
||||||
|
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||||
|
{9CF77369-B471-4476-9F42-779945113EA5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{9CF77369-B471-4476-9F42-779945113EA5}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{9CF77369-B471-4476-9F42-779945113EA5}.Debug|x64.ActiveCfg = Debug|x64
|
||||||
|
{9CF77369-B471-4476-9F42-779945113EA5}.Debug|x64.Build.0 = Debug|x64
|
||||||
|
{9CF77369-B471-4476-9F42-779945113EA5}.Debug|x86.ActiveCfg = Debug|x86
|
||||||
|
{9CF77369-B471-4476-9F42-779945113EA5}.Debug|x86.Build.0 = Debug|x86
|
||||||
|
{9CF77369-B471-4476-9F42-779945113EA5}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{9CF77369-B471-4476-9F42-779945113EA5}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
{9CF77369-B471-4476-9F42-779945113EA5}.Release|x64.ActiveCfg = Release|Any CPU
|
||||||
|
{9CF77369-B471-4476-9F42-779945113EA5}.Release|x64.Build.0 = Release|Any CPU
|
||||||
|
{9CF77369-B471-4476-9F42-779945113EA5}.Release|x86.ActiveCfg = Release|x86
|
||||||
|
{9CF77369-B471-4476-9F42-779945113EA5}.Release|x86.Build.0 = Release|x86
|
||||||
|
{F7AF907B-5DDC-469F-956C-08C5FD110448}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{F7AF907B-5DDC-469F-956C-08C5FD110448}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{F7AF907B-5DDC-469F-956C-08C5FD110448}.Debug|x64.ActiveCfg = Debug|x64
|
||||||
|
{F7AF907B-5DDC-469F-956C-08C5FD110448}.Debug|x64.Build.0 = Debug|x64
|
||||||
|
{F7AF907B-5DDC-469F-956C-08C5FD110448}.Debug|x86.ActiveCfg = Debug|x86
|
||||||
|
{F7AF907B-5DDC-469F-956C-08C5FD110448}.Debug|x86.Build.0 = Debug|x86
|
||||||
|
{F7AF907B-5DDC-469F-956C-08C5FD110448}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{F7AF907B-5DDC-469F-956C-08C5FD110448}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
{F7AF907B-5DDC-469F-956C-08C5FD110448}.Release|x64.ActiveCfg = Release|Any CPU
|
||||||
|
{F7AF907B-5DDC-469F-956C-08C5FD110448}.Release|x64.Build.0 = Release|Any CPU
|
||||||
|
{F7AF907B-5DDC-469F-956C-08C5FD110448}.Release|x86.ActiveCfg = Release|x86
|
||||||
|
{F7AF907B-5DDC-469F-956C-08C5FD110448}.Release|x86.Build.0 = Release|x86
|
||||||
|
{824348A6-FFFF-4C1B-BBF5-8B507A8C8CE5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{824348A6-FFFF-4C1B-BBF5-8B507A8C8CE5}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{824348A6-FFFF-4C1B-BBF5-8B507A8C8CE5}.Debug|x64.ActiveCfg = Debug|x64
|
||||||
|
{824348A6-FFFF-4C1B-BBF5-8B507A8C8CE5}.Debug|x64.Build.0 = Debug|x64
|
||||||
|
{824348A6-FFFF-4C1B-BBF5-8B507A8C8CE5}.Debug|x86.ActiveCfg = Debug|x86
|
||||||
|
{824348A6-FFFF-4C1B-BBF5-8B507A8C8CE5}.Debug|x86.Build.0 = Debug|x86
|
||||||
|
{824348A6-FFFF-4C1B-BBF5-8B507A8C8CE5}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{824348A6-FFFF-4C1B-BBF5-8B507A8C8CE5}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
{824348A6-FFFF-4C1B-BBF5-8B507A8C8CE5}.Release|x64.ActiveCfg = Release|Any CPU
|
||||||
|
{824348A6-FFFF-4C1B-BBF5-8B507A8C8CE5}.Release|x64.Build.0 = Release|Any CPU
|
||||||
|
{824348A6-FFFF-4C1B-BBF5-8B507A8C8CE5}.Release|x86.ActiveCfg = Release|x86
|
||||||
|
{824348A6-FFFF-4C1B-BBF5-8B507A8C8CE5}.Release|x86.Build.0 = Release|x86
|
||||||
|
{925057D8-7EE8-42ED-8AA0-628AF82F10B2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{925057D8-7EE8-42ED-8AA0-628AF82F10B2}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{925057D8-7EE8-42ED-8AA0-628AF82F10B2}.Debug|x64.ActiveCfg = Debug|x64
|
||||||
|
{925057D8-7EE8-42ED-8AA0-628AF82F10B2}.Debug|x64.Build.0 = Debug|x64
|
||||||
|
{925057D8-7EE8-42ED-8AA0-628AF82F10B2}.Debug|x86.ActiveCfg = Debug|x86
|
||||||
|
{925057D8-7EE8-42ED-8AA0-628AF82F10B2}.Debug|x86.Build.0 = Debug|x86
|
||||||
|
{925057D8-7EE8-42ED-8AA0-628AF82F10B2}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{925057D8-7EE8-42ED-8AA0-628AF82F10B2}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
{925057D8-7EE8-42ED-8AA0-628AF82F10B2}.Release|x64.ActiveCfg = Release|Any CPU
|
||||||
|
{925057D8-7EE8-42ED-8AA0-628AF82F10B2}.Release|x64.Build.0 = Release|Any CPU
|
||||||
|
{925057D8-7EE8-42ED-8AA0-628AF82F10B2}.Release|x86.ActiveCfg = Release|x86
|
||||||
|
{925057D8-7EE8-42ED-8AA0-628AF82F10B2}.Release|x86.Build.0 = Release|x86
|
||||||
|
{497A7E73-E2E8-4134-93CA-8F6A5B72D992}.Debug|Any CPU.ActiveCfg = Debug
|
||||||
|
{497A7E73-E2E8-4134-93CA-8F6A5B72D992}.Debug|x64.ActiveCfg = Debug
|
||||||
|
{497A7E73-E2E8-4134-93CA-8F6A5B72D992}.Debug|x86.ActiveCfg = Debug
|
||||||
|
{497A7E73-E2E8-4134-93CA-8F6A5B72D992}.Release|Any CPU.ActiveCfg = Release
|
||||||
|
{497A7E73-E2E8-4134-93CA-8F6A5B72D992}.Release|x64.ActiveCfg = Release
|
||||||
|
{497A7E73-E2E8-4134-93CA-8F6A5B72D992}.Release|x86.ActiveCfg = Release
|
||||||
|
EndGlobalSection
|
||||||
|
GlobalSection(SolutionProperties) = preSolution
|
||||||
|
HideSolutionNode = FALSE
|
||||||
|
EndGlobalSection
|
||||||
|
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||||
|
VisualSVNWorkingCopyRoot = .
|
||||||
|
SolutionGuid = {09FA6A17-2C18-418A-81E3-612D52950830}
|
||||||
|
EndGlobalSection
|
||||||
|
EndGlobal
|
||||||
64
CleanMachineHMI/App.config
Normal file
@@ -0,0 +1,64 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<configuration>
|
||||||
|
<configSections>
|
||||||
|
<!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->
|
||||||
|
<section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
|
||||||
|
</configSections>
|
||||||
|
<connectionStrings>
|
||||||
|
<add name="NX_CLEAR_MAC_20200915Entities" connectionString="metadata=res://*/Entitys.Model1.csdl|res://*/Entitys.Model1.ssdl|res://*/Entitys.Model1.msl;provider=System.Data.SqlClient;provider connection string="data source=.;initial catalog=NX_CLEAR_MAC_20200915;persist security info=True;user id=sa;password=1q2w3e4r!@;MultipleActiveResultSets=True;App=EntityFramework"" providerName="System.Data.EntityClient" />
|
||||||
|
<add name="CleanMachineHMI.Properties.Settings.NX_CLEAR_MAC_20200915ConnectionString" connectionString="Data Source=.;Initial Catalog=NX_CLEAR_MAC_20200915;Persist Security Info=True;User ID=sa;Password=1q2w3e4r!@" providerName="System.Data.SqlClient" />
|
||||||
|
</connectionStrings>
|
||||||
|
<startup>
|
||||||
|
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />
|
||||||
|
</startup>
|
||||||
|
<appSettings>
|
||||||
|
|
||||||
|
|
||||||
|
<add key="GlobalPaletteMode" value="Professionaloffice2003" />
|
||||||
|
<!--<add key="LanguageCode" value="Chinese"/>-->
|
||||||
|
<add key="LanguageCode" value="English" />
|
||||||
|
<add key="sqlmapConfigPath" value="Config/sqlmap.config" />
|
||||||
|
<!--MySql数据库连接字符串-->
|
||||||
|
<add key="LeadMySql" value="Data Source = localhost; Port=3306;Initial Catalog = testasrs; Persist Security Info=True;User ID = root; Password=sa1234567;" />
|
||||||
|
<!--SqlServer数据库连接字符串-->
|
||||||
|
<add key="LeadSqlServer" value="Data Source =localhost;Initial Catalog =NX_CLEAR_MAC;User Id = sa;Password =syl.syl503601;" />
|
||||||
|
<!--Oracle数据库连接字符串-->
|
||||||
|
<add key="LeadOracle" value="Data Source=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT=1521)))(CONNECT_DATA=(SERVICE_NAME=ORCL)));User Id=LEADASRS; Password=LEADASRS;" />
|
||||||
|
<!--SQLite数据库连接字符串-->
|
||||||
|
<!--<add key="LeadSQLite" value="Data Source=|DataDirectory|\\clearMac.db;Pooling=true;FailIfMissing=false"/>-->
|
||||||
|
<add key="LeadSQLite" value="Data Source=DataBase/clearMac.db" />
|
||||||
|
<!--串口名称-->
|
||||||
|
<add key="PortName" value="COM3" />
|
||||||
|
<!--串口波特率-->
|
||||||
|
<add key="BaudRate" value="9600" />
|
||||||
|
<!--串口数据位-->
|
||||||
|
<add key="DataBits" value="8" />
|
||||||
|
<!--停止位。 0:不使用停止位;1:使用一个停止位;2:使用两个停止位;3:使用 1.5 个停止位。-->
|
||||||
|
<add key="StopBits" value="1" />
|
||||||
|
<!--奇偶校验。0:无校验;1:奇校验;2:偶校验;-->
|
||||||
|
<add key="ParityMsg" value="2" />
|
||||||
|
<!--托盘序列号前缀-->
|
||||||
|
<add key="PalletIndexPrefix" value="Pallet" />
|
||||||
|
<!--托盘序列号生成日期-->
|
||||||
|
<add key="PalletIndexDateMsg" value="20201107" />
|
||||||
|
<!--托盘序列号长度-->
|
||||||
|
<add key="PalletIndexLen" value="6" />
|
||||||
|
<!--当前托盘序列号值-->
|
||||||
|
<add key="PalletIndexValue" value="1" />
|
||||||
|
<!--记录上一次登录用户名-->
|
||||||
|
<add key="LastTimeUserCode" value="" />
|
||||||
|
<add key="ClientSettingsProvider.ServiceUri" value="" />
|
||||||
|
</appSettings>
|
||||||
|
<system.web>
|
||||||
|
<membership defaultProvider="ClientAuthenticationMembershipProvider">
|
||||||
|
<providers>
|
||||||
|
<add name="ClientAuthenticationMembershipProvider" type="System.Web.ClientServices.Providers.ClientFormsAuthenticationMembershipProvider, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri="" />
|
||||||
|
</providers>
|
||||||
|
</membership>
|
||||||
|
<roleManager defaultProvider="ClientRoleProvider" enabled="true">
|
||||||
|
<providers>
|
||||||
|
<add name="ClientRoleProvider" type="System.Web.ClientServices.Providers.ClientRoleProvider, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri="" cacheTimeout="86400" />
|
||||||
|
</providers>
|
||||||
|
</roleManager>
|
||||||
|
</system.web>
|
||||||
|
</configuration>
|
||||||
665
CleanMachineHMI/CleanMachineHMI.csproj
Normal file
@@ -0,0 +1,665 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||||
|
<PropertyGroup>
|
||||||
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||||
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||||
|
<ProjectGuid>{9CF77369-B471-4476-9F42-779945113EA5}</ProjectGuid>
|
||||||
|
<OutputType>WinExe</OutputType>
|
||||||
|
<RootNamespace>CleanMachineHMI</RootNamespace>
|
||||||
|
<AssemblyName>CleanMachineHMI</AssemblyName>
|
||||||
|
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
|
||||||
|
<FileAlignment>512</FileAlignment>
|
||||||
|
<Deterministic>true</Deterministic>
|
||||||
|
<TargetFrameworkProfile />
|
||||||
|
<PublishUrl>publish\</PublishUrl>
|
||||||
|
<Install>true</Install>
|
||||||
|
<InstallFrom>Disk</InstallFrom>
|
||||||
|
<UpdateEnabled>false</UpdateEnabled>
|
||||||
|
<UpdateMode>Foreground</UpdateMode>
|
||||||
|
<UpdateInterval>7</UpdateInterval>
|
||||||
|
<UpdateIntervalUnits>Days</UpdateIntervalUnits>
|
||||||
|
<UpdatePeriodically>false</UpdatePeriodically>
|
||||||
|
<UpdateRequired>false</UpdateRequired>
|
||||||
|
<MapFileExtensions>true</MapFileExtensions>
|
||||||
|
<ApplicationRevision>0</ApplicationRevision>
|
||||||
|
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
|
||||||
|
<IsWebBootstrapper>false</IsWebBootstrapper>
|
||||||
|
<UseApplicationTrust>false</UseApplicationTrust>
|
||||||
|
<BootstrapperEnabled>true</BootstrapperEnabled>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||||
|
<PlatformTarget>x64</PlatformTarget>
|
||||||
|
<DebugSymbols>true</DebugSymbols>
|
||||||
|
<DebugType>full</DebugType>
|
||||||
|
<Optimize>false</Optimize>
|
||||||
|
<OutputPath>bin\Debug\</OutputPath>
|
||||||
|
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
<WarningLevel>4</WarningLevel>
|
||||||
|
<Prefer32Bit>false</Prefer32Bit>
|
||||||
|
<AllowUnsafeBlocks>false</AllowUnsafeBlocks>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||||
|
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||||
|
<DebugType>pdbonly</DebugType>
|
||||||
|
<Optimize>true</Optimize>
|
||||||
|
<OutputPath>bin\Release\</OutputPath>
|
||||||
|
<DefineConstants>TRACE</DefineConstants>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
<WarningLevel>4</WarningLevel>
|
||||||
|
<Prefer32Bit>false</Prefer32Bit>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup>
|
||||||
|
<ApplicationIcon>Resources\cleaner_128px_1238161_easyicon.net.ico</ApplicationIcon>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x64'">
|
||||||
|
<DebugSymbols>true</DebugSymbols>
|
||||||
|
<OutputPath>bin\x64\Debug\</OutputPath>
|
||||||
|
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||||
|
<DebugType>full</DebugType>
|
||||||
|
<PlatformTarget>x86</PlatformTarget>
|
||||||
|
<LangVersion>7.3</LangVersion>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x64'">
|
||||||
|
<OutputPath>bin\x64\Release\</OutputPath>
|
||||||
|
<DefineConstants>TRACE</DefineConstants>
|
||||||
|
<Optimize>true</Optimize>
|
||||||
|
<DebugType>pdbonly</DebugType>
|
||||||
|
<PlatformTarget>x64</PlatformTarget>
|
||||||
|
<LangVersion>7.3</LangVersion>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x86'">
|
||||||
|
<DebugSymbols>true</DebugSymbols>
|
||||||
|
<OutputPath>bin\x86\Debug\</OutputPath>
|
||||||
|
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||||
|
<DebugType>full</DebugType>
|
||||||
|
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||||
|
<LangVersion>7.3</LangVersion>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x86'">
|
||||||
|
<OutputPath>bin\x86\Release\</OutputPath>
|
||||||
|
<DefineConstants>TRACE</DefineConstants>
|
||||||
|
<Optimize>true</Optimize>
|
||||||
|
<DebugType>pdbonly</DebugType>
|
||||||
|
<PlatformTarget>x86</PlatformTarget>
|
||||||
|
<LangVersion>7.3</LangVersion>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
</PropertyGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Reference Include="ComponentFactory.Krypton.Navigator, Version=4.6.0.0, Culture=neutral, PublicKeyToken=a87e673e9ecb6e8e, processorArchitecture=MSIL">
|
||||||
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<HintPath>..\public\ComponentFactory.Krypton.Navigator.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="ComponentFactory.Krypton.Toolkit, Version=4.6.0.0, Culture=neutral, PublicKeyToken=a87e673e9ecb6e8e, processorArchitecture=MSIL">
|
||||||
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<HintPath>..\public\ComponentFactory.Krypton.Toolkit.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="FastReport, Version=2014.4.8.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<HintPath>..\public\FastReport.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="FastReport.Bars, Version=2014.4.8.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<HintPath>..\public\FastReport.Bars.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="FastReport.Editor, Version=2014.4.8.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<HintPath>..\public\FastReport.Editor.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="FastReport.Install, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<HintPath>..\public\FastReport.Install.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="FastReport.Service, Version=2014.4.8.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<HintPath>..\public\FastReport.Service.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="FastReport.Web, Version=2014.4.8.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<HintPath>..\public\FastReport.Web.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="LEase, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<HintPath>..\public\LEase.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="Microsoft.ReportViewer.Common, Version=14.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\Microsoft.ReportingServices.ReportViewerControl.Winforms.140.1000.523\lib\net40\Microsoft.ReportViewer.Common.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="Microsoft.ReportViewer.DataVisualization, Version=14.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\Microsoft.ReportingServices.ReportViewerControl.Winforms.140.1000.523\lib\net40\Microsoft.ReportViewer.DataVisualization.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="Microsoft.ReportViewer.Design, Version=14.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\Microsoft.ReportingServices.ReportViewerControl.Winforms.140.1000.523\lib\net40\Microsoft.ReportViewer.Design.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="Microsoft.ReportViewer.ProcessingObjectModel, Version=14.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\Microsoft.ReportingServices.ReportViewerControl.Winforms.140.1000.523\lib\net40\Microsoft.ReportViewer.ProcessingObjectModel.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="Microsoft.ReportViewer.WinForms, Version=14.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\Microsoft.ReportingServices.ReportViewerControl.Winforms.140.1000.523\lib\net40\Microsoft.ReportViewer.WinForms.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="Microsoft.SqlServer.Types, Version=14.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\Microsoft.SqlServer.Types.14.0.314.76\lib\net40\Microsoft.SqlServer.Types.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="Microsoft.VisualBasic" />
|
||||||
|
<Reference Include="Microsoft.VisualBasic.PowerPacks">
|
||||||
|
<HintPath>..\public\Microsoft.VisualBasic.PowerPacks.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="NModbus4, Version=2.1.0.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<HintPath>..\public\NModbus4.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="System" />
|
||||||
|
<Reference Include="System.Configuration" />
|
||||||
|
<Reference Include="System.Core" />
|
||||||
|
<Reference Include="System.Design" />
|
||||||
|
<Reference Include="System.Web" />
|
||||||
|
<Reference Include="System.Web.Extensions" />
|
||||||
|
<Reference Include="System.Xml.Linq" />
|
||||||
|
<Reference Include="System.Data.DataSetExtensions" />
|
||||||
|
<Reference Include="Microsoft.CSharp" />
|
||||||
|
<Reference Include="System.Data" />
|
||||||
|
<Reference Include="System.Deployment" />
|
||||||
|
<Reference Include="System.Drawing" />
|
||||||
|
<Reference Include="System.Windows.Forms" />
|
||||||
|
<Reference Include="System.Xml" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Compile Include="frmChild\frmPopupWarningMsg.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmPopupWarningMsg.Designer.cs">
|
||||||
|
<DependentUpon>frmPopupWarningMsg.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmSwitchRunDirection.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmSwitchRunDirection.Designer.cs">
|
||||||
|
<DependentUpon>frmSwitchRunDirection.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmIoMonitorNew.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmIoMonitorNew.Designer.cs">
|
||||||
|
<DependentUpon>frmIoMonitorNew.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmMainDetail.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmMainDetail.Designer.cs">
|
||||||
|
<DependentUpon>frmMainDetail.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmMaintenance.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmMaintenance.Designer.cs">
|
||||||
|
<DependentUpon>frmMaintenance.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmMechineCheck.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmMechineCheck.Designer.cs">
|
||||||
|
<DependentUpon>frmMechineCheck.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmPrinterMain.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmPrinterMain.Designer.cs">
|
||||||
|
<DependentUpon>frmPrinterMain.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmPlcItemConfig.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmPlcItemConfig.Designer.cs">
|
||||||
|
<DependentUpon>frmPlcItemConfig.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmPlcAlarmLog.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmPlcAlarmLog.Designer.cs">
|
||||||
|
<DependentUpon>frmPlcAlarmLog.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmManual.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmManual.Designer.cs">
|
||||||
|
<DependentUpon>frmManual.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmIOMonitor.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmIOMonitor.Designer.cs">
|
||||||
|
<DependentUpon>frmIOMonitor.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmCurrWorkingIrMsg.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmCurrWorkingIrMsg.Designer.cs">
|
||||||
|
<DependentUpon>frmCurrWorkingIrMsg.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\Base\frmCleanMode.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\Base\frmCleanMode.Designer.cs">
|
||||||
|
<DependentUpon>frmCleanMode.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\Base\frmContaminationDTL.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\Base\frmContaminationDTL.Designer.cs">
|
||||||
|
<DependentUpon>frmContaminationDTL.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\Base\frmContaminationType.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\Base\frmContaminationType.Designer.cs">
|
||||||
|
<DependentUpon>frmContaminationType.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmParamater.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\frmParamater.Designer.cs">
|
||||||
|
<DependentUpon>frmParamater.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\Base\frmRole.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\Base\frmRole.Designer.cs">
|
||||||
|
<DependentUpon>frmRole.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\Base\frmSheetType.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\Base\frmSheetType.Designer.cs">
|
||||||
|
<DependentUpon>frmSheetType.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\Base\frmUser.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\Base\frmUser.Designer.cs">
|
||||||
|
<DependentUpon>frmUser.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\Base\frmWarning.cs">
|
||||||
|
<SubType>UserControl</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmUserControl\Base\frmWarning.Designer.cs">
|
||||||
|
<DependentUpon>frmWarning.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Utils\GlobalHelper.cs" />
|
||||||
|
<Compile Include="Model\BasCleanTypeMsg.cs" />
|
||||||
|
<Compile Include="Model\BasPlcItemMd.cs" />
|
||||||
|
<Compile Include="Model\Bas_WarningMd.cs" />
|
||||||
|
<Compile Include="Utils\CircleButton.cs">
|
||||||
|
<SubType>Component</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Model\CM_WarningLogMd.cs" />
|
||||||
|
<Compile Include="frmSysExitAlarm.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmSysExitAlarm.Designer.cs">
|
||||||
|
<DependentUpon>frmSysExitAlarm.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Form2.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Form2.Designer.cs">
|
||||||
|
<DependentUpon>Form2.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddRole.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddRole.Designer.cs">
|
||||||
|
<DependentUpon>frmAddRole.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditRole.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditRole.Designer.cs">
|
||||||
|
<DependentUpon>frmEditRole.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditWorkingPalletData.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditWorkingPalletData.Designer.cs">
|
||||||
|
<DependentUpon>frmEditWorkingPalletData.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmSetRoleMenuPermission.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmSetRoleMenuPermission.Designer.cs">
|
||||||
|
<DependentUpon>frmSetRoleMenuPermission.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmBase.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmBase.Designer.cs">
|
||||||
|
<DependentUpon>frmBase.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddCleanCode.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddCleanCode.Designer.cs">
|
||||||
|
<DependentUpon>frmAddCleanCode.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditCleanCode.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditCleanCode.Designer.cs">
|
||||||
|
<DependentUpon>frmEditCleanCode.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddContaminationType.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddContaminationType.Designer.cs">
|
||||||
|
<DependentUpon>frmAddContaminationType.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditContaminationType.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditContaminationType.Designer.cs">
|
||||||
|
<DependentUpon>frmEditContaminationType.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddContaminationDtl.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddContaminationDtl.Designer.cs">
|
||||||
|
<DependentUpon>frmAddContaminationDtl.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditContaminationDtl.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditContaminationDtl.Designer.cs">
|
||||||
|
<DependentUpon>frmEditContaminationDtl.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddWaringMsg.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddWaringMsg.Designer.cs">
|
||||||
|
<DependentUpon>frmAddWaringMsg.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditParamater.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditParamater.Designer.cs">
|
||||||
|
<DependentUpon>frmEditParamater.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditWaringMsg.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditWaringMsg.Designer.cs">
|
||||||
|
<DependentUpon>frmEditWaringMsg.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddSheetType.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddSheetType.Designer.cs">
|
||||||
|
<DependentUpon>frmAddSheetType.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditSheetType.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditSheetType.Designer.cs">
|
||||||
|
<DependentUpon>frmEditSheetType.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditUser.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditUser.Designer.cs">
|
||||||
|
<DependentUpon>frmEditUser.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddPlcItem.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddPlcItem.Designer.cs">
|
||||||
|
<DependentUpon>frmAddPlcItem.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddUser.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmAddUser.Designer.cs">
|
||||||
|
<DependentUpon>frmAddUser.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditPlcItem.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmChild\frmEditPlcItem.Designer.cs">
|
||||||
|
<DependentUpon>frmEditPlcItem.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmIOMonitor_Old.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmIOMonitor_Old.Designer.cs">
|
||||||
|
<DependentUpon>frmIOMonitor_Old.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmLogin.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmLogin.Designer.cs">
|
||||||
|
<DependentUpon>frmLogin.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmMainNew.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="frmMainNew.Designer.cs">
|
||||||
|
<DependentUpon>frmMainNew.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Utils\LEnum.cs" />
|
||||||
|
<Compile Include="Utils\LEventArgs.cs" />
|
||||||
|
<Compile Include="Utils\LSwitchButton.cs">
|
||||||
|
<SubType>Component</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Utils\PlcOperationHelper.cs" />
|
||||||
|
<Compile Include="Program.cs" />
|
||||||
|
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||||
|
<Compile Include="Utils\KeyboardAutoPopUp.cs" />
|
||||||
|
<Compile Include="Utils\AppConfigHelper.cs" />
|
||||||
|
<Compile Include="Utils\FormTypeAttribute.cs" />
|
||||||
|
<Compile Include="Utils\frmUtil.cs" />
|
||||||
|
<EmbeddedResource Include="frmChild\frmPopupWarningMsg.resx">
|
||||||
|
<DependentUpon>frmPopupWarningMsg.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmSwitchRunDirection.resx">
|
||||||
|
<DependentUpon>frmSwitchRunDirection.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmIoMonitorNew.resx">
|
||||||
|
<DependentUpon>frmIoMonitorNew.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmSysExitAlarm.resx">
|
||||||
|
<DependentUpon>frmSysExitAlarm.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="Form2.resx">
|
||||||
|
<DependentUpon>Form2.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmAddRole.resx">
|
||||||
|
<DependentUpon>frmAddRole.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmEditRole.resx">
|
||||||
|
<DependentUpon>frmEditRole.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmEditWorkingPalletData.resx">
|
||||||
|
<DependentUpon>frmEditWorkingPalletData.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmSetRoleMenuPermission.resx">
|
||||||
|
<DependentUpon>frmSetRoleMenuPermission.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmAddCleanCode.resx">
|
||||||
|
<DependentUpon>frmAddCleanCode.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmAddContaminationDtl.resx">
|
||||||
|
<DependentUpon>frmAddContaminationDtl.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmAddContaminationType.resx">
|
||||||
|
<DependentUpon>frmAddContaminationType.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmAddWaringMsg.resx">
|
||||||
|
<DependentUpon>frmAddWaringMsg.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmEditCleanCode.resx">
|
||||||
|
<DependentUpon>frmEditCleanCode.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmEditContaminationDtl.resx">
|
||||||
|
<DependentUpon>frmEditContaminationDtl.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmEditContaminationType.resx">
|
||||||
|
<DependentUpon>frmEditContaminationType.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmEditParamater.resx">
|
||||||
|
<DependentUpon>frmEditParamater.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmEditWaringMsg.resx">
|
||||||
|
<DependentUpon>frmEditWaringMsg.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmAddSheetType.resx">
|
||||||
|
<DependentUpon>frmAddSheetType.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmAddUser.resx">
|
||||||
|
<DependentUpon>frmAddUser.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmEditSheetType.resx">
|
||||||
|
<DependentUpon>frmEditSheetType.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmEditUser.resx">
|
||||||
|
<DependentUpon>frmEditUser.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmIOMonitor_Old.resx">
|
||||||
|
<DependentUpon>frmIOMonitor_Old.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmLogin.resx">
|
||||||
|
<DependentUpon>frmLogin.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmMainNew.resx">
|
||||||
|
<DependentUpon>frmMainNew.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmBase.resx">
|
||||||
|
<DependentUpon>frmBase.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmAddPlcItem.resx">
|
||||||
|
<DependentUpon>frmAddPlcItem.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="frmChild\frmEditPlcItem.resx">
|
||||||
|
<DependentUpon>frmEditPlcItem.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\Base\frmCleanMode.resx">
|
||||||
|
<DependentUpon>frmCleanMode.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\Base\frmContaminationDTL.resx">
|
||||||
|
<DependentUpon>frmContaminationDTL.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\Base\frmContaminationType.resx">
|
||||||
|
<DependentUpon>frmContaminationType.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\Base\frmRole.resx">
|
||||||
|
<DependentUpon>frmRole.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\Base\frmSheetType.resx">
|
||||||
|
<DependentUpon>frmSheetType.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\Base\frmUser.resx">
|
||||||
|
<DependentUpon>frmUser.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\Base\frmWarning.resx">
|
||||||
|
<DependentUpon>frmWarning.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\frmCurrWorkingIrMsg.resx">
|
||||||
|
<DependentUpon>frmCurrWorkingIrMsg.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\frmIOMonitor.resx">
|
||||||
|
<DependentUpon>frmIOMonitor.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\frmMainDetail.resx">
|
||||||
|
<DependentUpon>frmMainDetail.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\frmMaintenance.resx">
|
||||||
|
<DependentUpon>frmMaintenance.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\frmManual.resx">
|
||||||
|
<DependentUpon>frmManual.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\frmMechineCheck.resx">
|
||||||
|
<DependentUpon>frmMechineCheck.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\frmParamater.resx">
|
||||||
|
<DependentUpon>frmParamater.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\frmPlcAlarmLog.resx">
|
||||||
|
<DependentUpon>frmPlcAlarmLog.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\frmPlcItemConfig.resx">
|
||||||
|
<DependentUpon>frmPlcItemConfig.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="FrmUserControl\frmPrinterMain.resx">
|
||||||
|
<DependentUpon>frmPrinterMain.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="Properties\Resources.resx">
|
||||||
|
<Generator>ResXFileCodeGenerator</Generator>
|
||||||
|
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<Compile Include="Properties\Resources.Designer.cs">
|
||||||
|
<AutoGen>True</AutoGen>
|
||||||
|
<DependentUpon>Resources.resx</DependentUpon>
|
||||||
|
<DesignTime>True</DesignTime>
|
||||||
|
</Compile>
|
||||||
|
<None Include="App.config" />
|
||||||
|
<None Include="DataBase\clearMac.db">
|
||||||
|
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||||
|
</None>
|
||||||
|
<None Include="packages.config" />
|
||||||
|
<None Include="Properties\Settings.settings">
|
||||||
|
<Generator>SettingsSingleFileGenerator</Generator>
|
||||||
|
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
|
||||||
|
</None>
|
||||||
|
<Compile Include="Properties\Settings.Designer.cs">
|
||||||
|
<AutoGen>True</AutoGen>
|
||||||
|
<DependentUpon>Settings.settings</DependentUpon>
|
||||||
|
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
||||||
|
</Compile>
|
||||||
|
<None Include="ReportMd\CleanMac_IRMsg_PrintMd.frd">
|
||||||
|
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||||
|
</None>
|
||||||
|
<None Include="ReportMd\CleanMac_IRMsg_PrintMd.frx">
|
||||||
|
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||||
|
</None>
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Content Include="Resources\cleaner_128px_1238161_easyicon.net.ico" />
|
||||||
|
<Content Include="Resources\cleaning_spray.ico" />
|
||||||
|
<Content Include="Resources\favicon.ico" />
|
||||||
|
<Content Include="Resources\add.png" />
|
||||||
|
<Content Include="Resources\conn.png" />
|
||||||
|
<None Include="Resources\上升.png" />
|
||||||
|
<None Include="Resources\下降.png" />
|
||||||
|
<None Include="Resources\下降_1.png" />
|
||||||
|
<None Include="Resources\上升_1.png" />
|
||||||
|
<Content Include="Resources\客情维护.png" />
|
||||||
|
<Content Include="Resources\报警 %281%29.png" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<WCFMetadata Include="Connected Services\" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<ProjectReference Include="..\CleanMachineHMI.Model\CleanMachineHMI.Domain.csproj">
|
||||||
|
<Project>{f7af907b-5ddc-469f-956c-08c5fd110448}</Project>
|
||||||
|
<Name>CleanMachineHMI.Domain</Name>
|
||||||
|
</ProjectReference>
|
||||||
|
<ProjectReference Include="..\LeadDataBaseUtility\LeadDataBaseUtility.csproj">
|
||||||
|
<Project>{824348a6-ffff-4c1b-bbf5-8b507a8c8ce5}</Project>
|
||||||
|
<Name>LeadDataBaseUtility</Name>
|
||||||
|
</ProjectReference>
|
||||||
|
<ProjectReference Include="..\NX_LogUtility\NX_LogUtility.csproj">
|
||||||
|
<Project>{925057d8-7ee8-42ed-8aa0-628af82f10b2}</Project>
|
||||||
|
<Name>NX_LogUtility</Name>
|
||||||
|
</ProjectReference>
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
|
||||||
|
<Visible>False</Visible>
|
||||||
|
<ProductName>.NET Framework 3.5 SP1</ProductName>
|
||||||
|
<Install>false</Install>
|
||||||
|
</BootstrapperPackage>
|
||||||
|
</ItemGroup>
|
||||||
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
|
</Project>
|
||||||
BIN
CleanMachineHMI/DataBase/clearMac.db
Normal file
224
CleanMachineHMI/Form2.Designer.cs
generated
Normal file
@@ -0,0 +1,224 @@
|
|||||||
|
namespace CleanMachineHMI
|
||||||
|
{
|
||||||
|
partial class Form2
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Required designer variable.
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Clean up any resources being used.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region Windows Form Designer generated code
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Required method for Designer support - do not modify
|
||||||
|
/// the contents of this method with the code editor.
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
this.components = new System.ComponentModel.Container();
|
||||||
|
this.kryptonNavigator1 = new ComponentFactory.Krypton.Navigator.KryptonNavigator();
|
||||||
|
this.kryptonButton1 = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonButton2 = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonButton3 = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonButton4 = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonButton5 = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonButton6 = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonButton7 = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonButton8 = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonButton9 = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonButton10 = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.timer1 = new System.Windows.Forms.Timer(this.components);
|
||||||
|
this.kryptonButton11 = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonTextBox1 = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonNavigator1)).BeginInit();
|
||||||
|
this.kryptonNavigator1.SuspendLayout();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// kryptonNavigator1
|
||||||
|
//
|
||||||
|
this.kryptonNavigator1.Button.ButtonDisplayLogic = ComponentFactory.Krypton.Navigator.ButtonDisplayLogic.ContextNextPrevious;
|
||||||
|
this.kryptonNavigator1.Button.CloseButtonDisplay = ComponentFactory.Krypton.Navigator.ButtonDisplay.Hide;
|
||||||
|
this.kryptonNavigator1.Location = new System.Drawing.Point(326, 45);
|
||||||
|
this.kryptonNavigator1.Name = "kryptonNavigator1";
|
||||||
|
this.kryptonNavigator1.Size = new System.Drawing.Size(589, 418);
|
||||||
|
this.kryptonNavigator1.TabIndex = 0;
|
||||||
|
this.kryptonNavigator1.Text = "kryptonNavigator1";
|
||||||
|
//
|
||||||
|
// kryptonButton1
|
||||||
|
//
|
||||||
|
this.kryptonButton1.Location = new System.Drawing.Point(35, 77);
|
||||||
|
this.kryptonButton1.Name = "kryptonButton1";
|
||||||
|
this.kryptonButton1.Size = new System.Drawing.Size(134, 25);
|
||||||
|
this.kryptonButton1.TabIndex = 1;
|
||||||
|
this.kryptonButton1.Values.Text = "测试窗体1";
|
||||||
|
this.kryptonButton1.BackColorChanged += new System.EventHandler(this.kryptonButton8_BackColorChanged);
|
||||||
|
this.kryptonButton1.Click += new System.EventHandler(this.kryptonButton1_Click);
|
||||||
|
//
|
||||||
|
// kryptonButton2
|
||||||
|
//
|
||||||
|
this.kryptonButton2.Location = new System.Drawing.Point(35, 124);
|
||||||
|
this.kryptonButton2.Name = "kryptonButton2";
|
||||||
|
this.kryptonButton2.Size = new System.Drawing.Size(134, 25);
|
||||||
|
this.kryptonButton2.TabIndex = 1;
|
||||||
|
this.kryptonButton2.Values.Text = "测试窗体2";
|
||||||
|
this.kryptonButton2.BackColorChanged += new System.EventHandler(this.kryptonButton8_BackColorChanged);
|
||||||
|
this.kryptonButton2.Click += new System.EventHandler(this.kryptonButton1_Click);
|
||||||
|
//
|
||||||
|
// kryptonButton3
|
||||||
|
//
|
||||||
|
this.kryptonButton3.Location = new System.Drawing.Point(35, 171);
|
||||||
|
this.kryptonButton3.Name = "kryptonButton3";
|
||||||
|
this.kryptonButton3.Size = new System.Drawing.Size(134, 25);
|
||||||
|
this.kryptonButton3.TabIndex = 1;
|
||||||
|
this.kryptonButton3.Values.Text = "测试窗体3";
|
||||||
|
this.kryptonButton3.BackColorChanged += new System.EventHandler(this.kryptonButton8_BackColorChanged);
|
||||||
|
this.kryptonButton3.Click += new System.EventHandler(this.kryptonButton1_Click);
|
||||||
|
//
|
||||||
|
// kryptonButton4
|
||||||
|
//
|
||||||
|
this.kryptonButton4.Location = new System.Drawing.Point(35, 215);
|
||||||
|
this.kryptonButton4.Name = "kryptonButton4";
|
||||||
|
this.kryptonButton4.Size = new System.Drawing.Size(134, 25);
|
||||||
|
this.kryptonButton4.TabIndex = 1;
|
||||||
|
this.kryptonButton4.Values.Text = "测试窗体4";
|
||||||
|
this.kryptonButton4.BackColorChanged += new System.EventHandler(this.kryptonButton8_BackColorChanged);
|
||||||
|
this.kryptonButton4.Click += new System.EventHandler(this.kryptonButton1_Click);
|
||||||
|
//
|
||||||
|
// kryptonButton5
|
||||||
|
//
|
||||||
|
this.kryptonButton5.Location = new System.Drawing.Point(35, 262);
|
||||||
|
this.kryptonButton5.Name = "kryptonButton5";
|
||||||
|
this.kryptonButton5.Size = new System.Drawing.Size(134, 25);
|
||||||
|
this.kryptonButton5.TabIndex = 1;
|
||||||
|
this.kryptonButton5.Values.Text = "测试窗体5";
|
||||||
|
this.kryptonButton5.BackColorChanged += new System.EventHandler(this.kryptonButton8_BackColorChanged);
|
||||||
|
this.kryptonButton5.Click += new System.EventHandler(this.kryptonButton1_Click);
|
||||||
|
//
|
||||||
|
// kryptonButton6
|
||||||
|
//
|
||||||
|
this.kryptonButton6.Location = new System.Drawing.Point(35, 304);
|
||||||
|
this.kryptonButton6.Name = "kryptonButton6";
|
||||||
|
this.kryptonButton6.Size = new System.Drawing.Size(134, 25);
|
||||||
|
this.kryptonButton6.TabIndex = 1;
|
||||||
|
this.kryptonButton6.Values.Text = "测试窗体6";
|
||||||
|
this.kryptonButton6.BackColorChanged += new System.EventHandler(this.kryptonButton8_BackColorChanged);
|
||||||
|
this.kryptonButton6.Click += new System.EventHandler(this.kryptonButton1_Click);
|
||||||
|
//
|
||||||
|
// kryptonButton7
|
||||||
|
//
|
||||||
|
this.kryptonButton7.Location = new System.Drawing.Point(35, 348);
|
||||||
|
this.kryptonButton7.Name = "kryptonButton7";
|
||||||
|
this.kryptonButton7.Size = new System.Drawing.Size(134, 25);
|
||||||
|
this.kryptonButton7.TabIndex = 1;
|
||||||
|
this.kryptonButton7.Values.Text = "测试窗体7";
|
||||||
|
this.kryptonButton7.BackColorChanged += new System.EventHandler(this.kryptonButton8_BackColorChanged);
|
||||||
|
this.kryptonButton7.Click += new System.EventHandler(this.kryptonButton1_Click);
|
||||||
|
//
|
||||||
|
// kryptonButton8
|
||||||
|
//
|
||||||
|
this.kryptonButton8.Location = new System.Drawing.Point(35, 389);
|
||||||
|
this.kryptonButton8.Name = "kryptonButton8";
|
||||||
|
this.kryptonButton8.Size = new System.Drawing.Size(134, 25);
|
||||||
|
this.kryptonButton8.TabIndex = 1;
|
||||||
|
this.kryptonButton8.Values.Text = "测试窗体8";
|
||||||
|
this.kryptonButton8.BackColorChanged += new System.EventHandler(this.kryptonButton8_BackColorChanged);
|
||||||
|
this.kryptonButton8.Click += new System.EventHandler(this.kryptonButton1_Click);
|
||||||
|
//
|
||||||
|
// kryptonButton9
|
||||||
|
//
|
||||||
|
this.kryptonButton9.Location = new System.Drawing.Point(35, 486);
|
||||||
|
this.kryptonButton9.Name = "kryptonButton9";
|
||||||
|
this.kryptonButton9.Size = new System.Drawing.Size(90, 25);
|
||||||
|
this.kryptonButton9.TabIndex = 2;
|
||||||
|
this.kryptonButton9.Values.Text = "添加";
|
||||||
|
this.kryptonButton9.Click += new System.EventHandler(this.kryptonButton9_Click);
|
||||||
|
//
|
||||||
|
// kryptonButton10
|
||||||
|
//
|
||||||
|
this.kryptonButton10.Location = new System.Drawing.Point(178, 486);
|
||||||
|
this.kryptonButton10.Name = "kryptonButton10";
|
||||||
|
this.kryptonButton10.Size = new System.Drawing.Size(90, 25);
|
||||||
|
this.kryptonButton10.TabIndex = 2;
|
||||||
|
this.kryptonButton10.Values.Text = "删除";
|
||||||
|
this.kryptonButton10.Click += new System.EventHandler(this.kryptonButton10_Click);
|
||||||
|
//
|
||||||
|
// timer1
|
||||||
|
//
|
||||||
|
this.timer1.Enabled = true;
|
||||||
|
this.timer1.Interval = 1000;
|
||||||
|
this.timer1.Tick += new System.EventHandler(this.timer1_Tick);
|
||||||
|
//
|
||||||
|
// kryptonButton11
|
||||||
|
//
|
||||||
|
this.kryptonButton11.Location = new System.Drawing.Point(326, 486);
|
||||||
|
this.kryptonButton11.Name = "kryptonButton11";
|
||||||
|
this.kryptonButton11.Size = new System.Drawing.Size(90, 25);
|
||||||
|
this.kryptonButton11.TabIndex = 3;
|
||||||
|
this.kryptonButton11.Values.Text = "kryptonButton11";
|
||||||
|
this.kryptonButton11.Click += new System.EventHandler(this.kryptonButton11_Click);
|
||||||
|
//
|
||||||
|
// kryptonTextBox1
|
||||||
|
//
|
||||||
|
this.kryptonTextBox1.Location = new System.Drawing.Point(456, 486);
|
||||||
|
this.kryptonTextBox1.Name = "kryptonTextBox1";
|
||||||
|
this.kryptonTextBox1.Size = new System.Drawing.Size(245, 23);
|
||||||
|
this.kryptonTextBox1.TabIndex = 4;
|
||||||
|
//
|
||||||
|
// Form2
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.ClientSize = new System.Drawing.Size(954, 557);
|
||||||
|
this.Controls.Add(this.kryptonTextBox1);
|
||||||
|
this.Controls.Add(this.kryptonButton11);
|
||||||
|
this.Controls.Add(this.kryptonButton10);
|
||||||
|
this.Controls.Add(this.kryptonButton9);
|
||||||
|
this.Controls.Add(this.kryptonButton8);
|
||||||
|
this.Controls.Add(this.kryptonButton7);
|
||||||
|
this.Controls.Add(this.kryptonButton6);
|
||||||
|
this.Controls.Add(this.kryptonButton5);
|
||||||
|
this.Controls.Add(this.kryptonButton4);
|
||||||
|
this.Controls.Add(this.kryptonButton3);
|
||||||
|
this.Controls.Add(this.kryptonButton2);
|
||||||
|
this.Controls.Add(this.kryptonButton1);
|
||||||
|
this.Controls.Add(this.kryptonNavigator1);
|
||||||
|
this.Name = "Form2";
|
||||||
|
this.Text = "Form2";
|
||||||
|
this.Load += new System.EventHandler(this.Form2_Load);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonNavigator1)).EndInit();
|
||||||
|
this.kryptonNavigator1.ResumeLayout(false);
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
this.PerformLayout();
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kryptonButton1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kryptonButton2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kryptonButton3;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kryptonButton4;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kryptonButton5;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kryptonButton6;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kryptonButton7;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kryptonButton8;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kryptonButton9;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kryptonButton10;
|
||||||
|
private System.Windows.Forms.Timer timer1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kryptonButton11;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox kryptonTextBox1;
|
||||||
|
private ComponentFactory.Krypton.Navigator.KryptonNavigator kryptonNavigator1;
|
||||||
|
}
|
||||||
|
}
|
||||||
148
CleanMachineHMI/Form2.cs
Normal file
@@ -0,0 +1,148 @@
|
|||||||
|
using ComponentFactory.Krypton.Navigator;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI
|
||||||
|
{
|
||||||
|
public partial class Form2 : Form
|
||||||
|
{
|
||||||
|
public Form2()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Form2_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
kryptonNavigator1.Pages.Clear();
|
||||||
|
AddFrmPage(null, null);
|
||||||
|
GlobalHelper.CmWarningLogMd_List_1 = new List<CM_WarningLogMd>();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kryptonButton8_BackColorChanged(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kryptonButton1_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KryptonButton kbtn = sender as KryptonButton;
|
||||||
|
AddFrmPage(kbtn.Name, kbtn.Text);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void AddFrmPage(string pageCode,string pageName)
|
||||||
|
{
|
||||||
|
if (kryptonNavigator1.Pages.Count == 0)
|
||||||
|
{
|
||||||
|
KryptonPage tmpPage = new KryptonPage { Text = "DefaultFrm", Name = "默认窗体" };
|
||||||
|
kryptonNavigator1.Pages.Add(tmpPage);
|
||||||
|
kryptonNavigator1.SelectedPage = tmpPage;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonPage tmpPage = kryptonNavigator1.Pages.FirstOrDefault(x => x.Text == pageCode);
|
||||||
|
if (tmpPage != null)
|
||||||
|
{
|
||||||
|
kryptonNavigator1.SelectedPage = tmpPage;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonPage tmpPage1 = new KryptonPage { Text = pageCode, Name = pageName };
|
||||||
|
kryptonNavigator1.Pages.Add(tmpPage1);
|
||||||
|
kryptonNavigator1.SelectedPage = tmpPage1;
|
||||||
|
ButtonSpecAny bsa = new ButtonSpecAny();
|
||||||
|
bsa.Style = PaletteButtonStyle.FormClose;
|
||||||
|
bsa.Type = PaletteButtonSpecStyle.FormClose;
|
||||||
|
bsa.Tag = kryptonNavigator1.SelectedPage;
|
||||||
|
bsa.Click += test_Click;
|
||||||
|
kryptonNavigator1.SelectedPage.ButtonSpecs.Add(bsa);
|
||||||
|
Form objFrm = new Form();
|
||||||
|
objFrm.TopLevel = false;
|
||||||
|
objFrm.FormBorderStyle = FormBorderStyle.None;
|
||||||
|
objFrm.MinimizeBox = false;
|
||||||
|
objFrm.Parent = tmpPage1;
|
||||||
|
objFrm.Dock = DockStyle.Fill;
|
||||||
|
objFrm.Show();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
private void test_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
ButtonSpecAny bsa = sender as ButtonSpecAny;
|
||||||
|
kryptonNavigator1.Pages.Remove(bsa.Tag);
|
||||||
|
}
|
||||||
|
private void CloseFrmPage()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kryptonButton9_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
GlobalHelper.CmWarningLogMd_List_1.Add(new CM_WarningLogMd {
|
||||||
|
WarningCode = "TestAlarm001",
|
||||||
|
WarningName = "TestAlarm001",
|
||||||
|
WarningType = "TestAlarm001",
|
||||||
|
WarningMessage = "TestAlarm001",
|
||||||
|
WarningTime = DateTime.Now,
|
||||||
|
PlcItemCode = "TestAlarm001",
|
||||||
|
WarningStatus = 0,
|
||||||
|
WarningHandleResult = 0,
|
||||||
|
CreateBy = 1,
|
||||||
|
CreateTime = DateTime.Now,
|
||||||
|
UpdateBy = 1,
|
||||||
|
UpdateTime = DateTime.Now,
|
||||||
|
DataVersion = 0,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kryptonButton10_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
CM_WarningLogMd tmpWarn = GlobalHelper.CmWarningLogMd_List_1.Find(x => x.WarningStatus == 0);
|
||||||
|
if (tmpWarn != null)
|
||||||
|
{
|
||||||
|
tmpWarn.WarningStatus = 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
private void timer1_Tick(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
//List<CM_WarningLogMd> lst = GlobalHelper.CmWarningLogMd_List_1.FindAll(x => x.WarningStatus == 0);
|
||||||
|
//if (lst.Count > 0)
|
||||||
|
//{
|
||||||
|
// if (!GlobalHelper.form3IsShow)
|
||||||
|
// {
|
||||||
|
// tmpFrm = new frmCurrentWarningMessage();
|
||||||
|
// tmpFrm.Show();
|
||||||
|
// frmCurrentWarningMessage.RefreshFrmHost(lst);
|
||||||
|
// GlobalHelper.form3IsShow = true;
|
||||||
|
// }
|
||||||
|
// else
|
||||||
|
// {
|
||||||
|
// frmCurrentWarningMessage.RefreshFrmHost(lst);
|
||||||
|
// GlobalHelper.form3IsShow = true;
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
//else
|
||||||
|
//{
|
||||||
|
// if (GlobalHelper.form3IsShow)
|
||||||
|
// {
|
||||||
|
// frmCurrentWarningMessage.RefreshFrmHost(null);
|
||||||
|
// tmpFrm.Close();
|
||||||
|
|
||||||
|
// GlobalHelper.form3IsShow = false;
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kryptonButton11_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
kryptonTextBox1.Text = GlobalHelper.GetPalletCode();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
123
CleanMachineHMI/Form2.resx
Normal file
@@ -0,0 +1,123 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<metadata name="timer1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
|
<value>17, 17</value>
|
||||||
|
</metadata>
|
||||||
|
</root>
|
||||||
358
CleanMachineHMI/FrmUserControl/Base/frmCleanMode.Designer.cs
generated
Normal file
@@ -0,0 +1,358 @@
|
|||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
partial class frmCleanMode
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 必需的设计器变量。
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清理所有正在使用的资源。
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region 组件设计器生成的代码
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设计器支持所需的方法 - 不要修改
|
||||||
|
/// 使用代码编辑器修改此方法的内容。
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
this.kryptonGroupBox2 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.dataGridView = new ComponentFactory.Krypton.Toolkit.KryptonDataGridView();
|
||||||
|
this.kryptonPanel1 = new ComponentFactory.Krypton.Toolkit.KryptonPanel();
|
||||||
|
this.kryptonGroupBox1 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kbt_Reset = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Edit = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Delete = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Query = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Add = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kdtp_CreateEndTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kdtp_CreateStartTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kryptonLabel2 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel5 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.ktb_CleanModeCode = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kryptonLabel4 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel3 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.ktb_CleanModeName = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox2.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel1)).BeginInit();
|
||||||
|
this.kryptonPanel1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox1.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox1.SuspendLayout();
|
||||||
|
this.tableLayoutPanel2.SuspendLayout();
|
||||||
|
this.tableLayoutPanel1.SuspendLayout();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowOnly;
|
||||||
|
this.kryptonGroupBox2.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox2.CaptionStyle = ComponentFactory.Krypton.Toolkit.LabelStyle.NormalControl;
|
||||||
|
this.kryptonGroupBox2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonGroupBox2.Location = new System.Drawing.Point(0, 131);
|
||||||
|
this.kryptonGroupBox2.Name = "kryptonGroupBox2";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.dataGridView);
|
||||||
|
this.kryptonGroupBox2.Size = new System.Drawing.Size(802, 460);
|
||||||
|
this.kryptonGroupBox2.TabIndex = 6;
|
||||||
|
this.kryptonGroupBox2.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// dataGridView
|
||||||
|
//
|
||||||
|
this.dataGridView.AllowUserToAddRows = false;
|
||||||
|
this.dataGridView.AllowUserToDeleteRows = false;
|
||||||
|
this.dataGridView.AllowUserToResizeRows = false;
|
||||||
|
this.dataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
|
||||||
|
this.dataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
|
||||||
|
this.dataGridView.DataMember = "TestData";
|
||||||
|
this.dataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.dataGridView.GridStyles.Style = ComponentFactory.Krypton.Toolkit.DataGridViewStyle.Mixed;
|
||||||
|
this.dataGridView.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.dataGridView.MultiSelect = false;
|
||||||
|
this.dataGridView.Name = "dataGridView";
|
||||||
|
this.dataGridView.ReadOnly = true;
|
||||||
|
this.dataGridView.RowHeadersVisible = false;
|
||||||
|
this.dataGridView.RowHeadersWidth = 100;
|
||||||
|
this.dataGridView.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
|
||||||
|
this.dataGridView.Size = new System.Drawing.Size(798, 456);
|
||||||
|
this.dataGridView.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// kryptonPanel1
|
||||||
|
//
|
||||||
|
this.kryptonPanel1.Controls.Add(this.kryptonGroupBox2);
|
||||||
|
this.kryptonPanel1.Controls.Add(this.kryptonGroupBox1);
|
||||||
|
this.kryptonPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonPanel1.Name = "kryptonPanel1";
|
||||||
|
this.kryptonPanel1.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.kryptonPanel1.TabIndex = 4;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.kryptonGroupBox1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonGroupBox1.Name = "kryptonGroupBox1";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.tableLayoutPanel2);
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.tableLayoutPanel1);
|
||||||
|
this.kryptonGroupBox1.Size = new System.Drawing.Size(802, 131);
|
||||||
|
this.kryptonGroupBox1.TabIndex = 0;
|
||||||
|
this.kryptonGroupBox1.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// tableLayoutPanel2
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.tableLayoutPanel2.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel2.ColumnCount = 5;
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 20F));
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Reset, 4, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Edit, 1, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Delete, 2, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Query, 3, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Add, 0, 0);
|
||||||
|
this.tableLayoutPanel2.Location = new System.Drawing.Point(237, 78);
|
||||||
|
this.tableLayoutPanel2.Name = "tableLayoutPanel2";
|
||||||
|
this.tableLayoutPanel2.RowCount = 1;
|
||||||
|
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||||
|
this.tableLayoutPanel2.Size = new System.Drawing.Size(561, 41);
|
||||||
|
this.tableLayoutPanel2.TabIndex = 6;
|
||||||
|
//
|
||||||
|
// kbt_Reset
|
||||||
|
//
|
||||||
|
this.kbt_Reset.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Reset.Location = new System.Drawing.Point(451, 3);
|
||||||
|
this.kbt_Reset.Name = "kbt_Reset";
|
||||||
|
this.kbt_Reset.Size = new System.Drawing.Size(107, 35);
|
||||||
|
this.kbt_Reset.TabIndex = 0;
|
||||||
|
this.kbt_Reset.Tag = "show";
|
||||||
|
this.kbt_Reset.Values.Text = "重置条件";
|
||||||
|
this.kbt_Reset.Click += new System.EventHandler(this.kbt_Reset_Click);
|
||||||
|
//
|
||||||
|
// kbt_Edit
|
||||||
|
//
|
||||||
|
this.kbt_Edit.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Edit.Location = new System.Drawing.Point(115, 3);
|
||||||
|
this.kbt_Edit.Name = "kbt_Edit";
|
||||||
|
this.kbt_Edit.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Edit.TabIndex = 0;
|
||||||
|
this.kbt_Edit.Values.Text = "编辑";
|
||||||
|
this.kbt_Edit.Click += new System.EventHandler(this.kbt_Edit_Click);
|
||||||
|
//
|
||||||
|
// kbt_Delete
|
||||||
|
//
|
||||||
|
this.kbt_Delete.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Delete.Location = new System.Drawing.Point(227, 3);
|
||||||
|
this.kbt_Delete.Name = "kbt_Delete";
|
||||||
|
this.kbt_Delete.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Delete.TabIndex = 0;
|
||||||
|
this.kbt_Delete.Values.Text = "删除";
|
||||||
|
this.kbt_Delete.Click += new System.EventHandler(this.kbt_Delete_Click);
|
||||||
|
//
|
||||||
|
// kbt_Query
|
||||||
|
//
|
||||||
|
this.kbt_Query.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Query.Location = new System.Drawing.Point(339, 3);
|
||||||
|
this.kbt_Query.Name = "kbt_Query";
|
||||||
|
this.kbt_Query.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Query.TabIndex = 0;
|
||||||
|
this.kbt_Query.Tag = "show";
|
||||||
|
this.kbt_Query.Values.Text = "查询";
|
||||||
|
this.kbt_Query.Click += new System.EventHandler(this.kbt_Query_Click);
|
||||||
|
//
|
||||||
|
// kbt_Add
|
||||||
|
//
|
||||||
|
this.kbt_Add.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Add.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kbt_Add.Name = "kbt_Add";
|
||||||
|
this.kbt_Add.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Add.TabIndex = 0;
|
||||||
|
this.kbt_Add.Values.Text = "新增";
|
||||||
|
this.kbt_Add.Click += new System.EventHandler(this.kbt_Add_Click);
|
||||||
|
//
|
||||||
|
// tableLayoutPanel1
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel1.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel1.ColumnCount = 4;
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 140F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 140F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateEndTime, 3, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateStartTime, 1, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel2, 0, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel5, 2, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_CleanModeCode, 1, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel4, 0, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel3, 2, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_CleanModeName, 3, 0);
|
||||||
|
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||||
|
this.tableLayoutPanel1.RowCount = 2;
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Size = new System.Drawing.Size(798, 72);
|
||||||
|
this.tableLayoutPanel1.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// kdtp_CreateEndTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateEndTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateEndTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateEndTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateEndTime.Location = new System.Drawing.Point(546, 43);
|
||||||
|
this.kdtp_CreateEndTime.Name = "kdtp_CreateEndTime";
|
||||||
|
this.kdtp_CreateEndTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateEndTime.Size = new System.Drawing.Size(245, 21);
|
||||||
|
this.kdtp_CreateEndTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kdtp_CreateStartTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateStartTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateStartTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateStartTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateStartTime.Location = new System.Drawing.Point(147, 43);
|
||||||
|
this.kdtp_CreateStartTime.Name = "kdtp_CreateStartTime";
|
||||||
|
this.kdtp_CreateStartTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateStartTime.Size = new System.Drawing.Size(245, 21);
|
||||||
|
this.kdtp_CreateStartTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kryptonLabel2
|
||||||
|
//
|
||||||
|
this.kryptonLabel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel2.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kryptonLabel2.Name = "kryptonLabel2";
|
||||||
|
this.kryptonLabel2.Size = new System.Drawing.Size(134, 30);
|
||||||
|
this.kryptonLabel2.TabIndex = 4;
|
||||||
|
this.kryptonLabel2.Values.Text = "清洁方式编码:";
|
||||||
|
//
|
||||||
|
// kryptonLabel5
|
||||||
|
//
|
||||||
|
this.kryptonLabel5.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kryptonLabel5.Location = new System.Drawing.Point(457, 44);
|
||||||
|
this.kryptonLabel5.Name = "kryptonLabel5";
|
||||||
|
this.kryptonLabel5.Size = new System.Drawing.Size(23, 20);
|
||||||
|
this.kryptonLabel5.TabIndex = 4;
|
||||||
|
this.kryptonLabel5.Values.Text = "至";
|
||||||
|
//
|
||||||
|
// ktb_CleanModeCode
|
||||||
|
//
|
||||||
|
this.ktb_CleanModeCode.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_CleanModeCode.Location = new System.Drawing.Point(147, 6);
|
||||||
|
this.ktb_CleanModeCode.Name = "ktb_CleanModeCode";
|
||||||
|
this.ktb_CleanModeCode.Size = new System.Drawing.Size(245, 23);
|
||||||
|
this.ktb_CleanModeCode.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// kryptonLabel4
|
||||||
|
//
|
||||||
|
this.kryptonLabel4.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel4.Location = new System.Drawing.Point(3, 39);
|
||||||
|
this.kryptonLabel4.Name = "kryptonLabel4";
|
||||||
|
this.kryptonLabel4.Size = new System.Drawing.Size(134, 30);
|
||||||
|
this.kryptonLabel4.TabIndex = 4;
|
||||||
|
this.kryptonLabel4.Values.Text = "创建时间:";
|
||||||
|
//
|
||||||
|
// kryptonLabel3
|
||||||
|
//
|
||||||
|
this.kryptonLabel3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel3.Location = new System.Drawing.Point(402, 3);
|
||||||
|
this.kryptonLabel3.Name = "kryptonLabel3";
|
||||||
|
this.kryptonLabel3.Size = new System.Drawing.Size(134, 30);
|
||||||
|
this.kryptonLabel3.TabIndex = 4;
|
||||||
|
this.kryptonLabel3.Values.Text = "清洁方式名称:";
|
||||||
|
//
|
||||||
|
// ktb_CleanModeName
|
||||||
|
//
|
||||||
|
this.ktb_CleanModeName.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_CleanModeName.Location = new System.Drawing.Point(546, 6);
|
||||||
|
this.ktb_CleanModeName.Name = "ktb_CleanModeName";
|
||||||
|
this.ktb_CleanModeName.Size = new System.Drawing.Size(245, 23);
|
||||||
|
this.ktb_CleanModeName.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// frmCleanMode
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.Controls.Add(this.kryptonPanel1);
|
||||||
|
this.Name = "frmCleanMode";
|
||||||
|
this.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.Load += new System.EventHandler(this.frmCleanMode_Load);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox2.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).EndInit();
|
||||||
|
this.kryptonGroupBox2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel1)).EndInit();
|
||||||
|
this.kryptonPanel1.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox1.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).EndInit();
|
||||||
|
this.kryptonGroupBox1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel2.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.PerformLayout();
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridView dataGridView;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonPanel kryptonPanel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox1;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Reset;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Edit;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Delete;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Query;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Add;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateEndTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateStartTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel5;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_CleanModeCode;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel4;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel3;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_CleanModeName;
|
||||||
|
}
|
||||||
|
}
|
||||||
200
CleanMachineHMI/FrmUserControl/Base/frmCleanMode.cs
Normal file
@@ -0,0 +1,200 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.frmChild;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using LeadDataBaseUtility;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
[FormType(EnumFormType.CleanMode)]
|
||||||
|
public partial class frmCleanMode : UserControl
|
||||||
|
{
|
||||||
|
private DataTable _InfoLanguageTextList;
|
||||||
|
public delegate void dlgRefreshFrmHost();
|
||||||
|
public static dlgRefreshFrmHost RefreshFrmHost;
|
||||||
|
|
||||||
|
public frmCleanMode()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
_InfoLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode);
|
||||||
|
|
||||||
|
}
|
||||||
|
protected override CreateParams CreateParams
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
CreateParams cp = base.CreateParams;
|
||||||
|
cp.ExStyle |= 0x02000000;
|
||||||
|
return cp;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public void Init()
|
||||||
|
{
|
||||||
|
var sql = $@"select CLEAN_MODE_ID 序号,CLEAN_MODE_CODE 清洁方式编码,CLEAN_MODE_NAME 清洁方式名称,CREATE_TIME 创建时间 from BAS_CLEAN_MODE where DEL_FLAG=0";
|
||||||
|
if (!string.IsNullOrEmpty(ktb_CleanModeCode.Text))
|
||||||
|
{
|
||||||
|
sql += $" AND CLEAN_MODE_CODE LIKE '%{ktb_CleanModeCode.Text}%'";
|
||||||
|
}
|
||||||
|
if (!string.IsNullOrEmpty(ktb_CleanModeName.Text))
|
||||||
|
{
|
||||||
|
sql += $" AND CLEAN_MODE_NAME LIKE '%{ktb_CleanModeName.Text}%'";
|
||||||
|
}
|
||||||
|
if (kdtp_CreateStartTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND CREATE_TIME >= '{kdtp_CreateStartTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
if (kdtp_CreateEndTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND CREATE_TIME <= '{kdtp_CreateEndTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
|
||||||
|
dataGridView.Columns.Clear();
|
||||||
|
dataGridView.DataSource = dt;
|
||||||
|
dataGridView.SetDataViewColumnText(this.Name, GlobalHelper.LanguageCode);
|
||||||
|
|
||||||
|
}
|
||||||
|
private void txt_GotFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.ShowInputPanel();
|
||||||
|
}
|
||||||
|
private void txt_LostFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.HideInputPanel();
|
||||||
|
}
|
||||||
|
private void InitControlEvent()
|
||||||
|
{
|
||||||
|
ktb_CleanModeCode.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_CleanModeCode.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
|
||||||
|
ktb_CleanModeName.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_CleanModeName.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
}
|
||||||
|
|
||||||
|
private void frmCleanMode_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
InitControlEvent();
|
||||||
|
this.SetFormControlText(GlobalHelper.LanguageCode);
|
||||||
|
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
|
||||||
|
RefreshFrmHost = new dlgRefreshFrmHost(Init);
|
||||||
|
Init();
|
||||||
|
|
||||||
|
foreach (Control item in tableLayoutPanel2.Controls)
|
||||||
|
{
|
||||||
|
if (item.Tag == null)
|
||||||
|
{
|
||||||
|
DataRow[] drs = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{this.Name}' AND MENU_PID = '-1'");
|
||||||
|
DataRow[] drs1 = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{item.Name}' AND MENU_PID = '{drs[0]["MENU_ID"]}'");
|
||||||
|
if (drs1.Length > 0)
|
||||||
|
{
|
||||||
|
item.Enabled = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
item.Enabled = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kryptonGroupBox2.Focus();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("加载清洁方式界面发生异常", "LoadFrmCleanModeExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Query_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
Init();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("查询清洁方式数据发生异常", "QueryCleanModeData") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Reset_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
ktb_CleanModeCode.Text = "";
|
||||||
|
ktb_CleanModeName.Text = "";
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Add_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
frmAddCleanCode frm = new frmAddCleanCode();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Edit_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (dataGridView.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
frmEditCleanCode frm = new frmEditCleanCode();
|
||||||
|
frm.CleanModeId = dataGridView.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要编辑的清洗方式数据行!", "SelectWantToEditRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Delete_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (dataGridView.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
DialogResult dr = KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("确定要删除所选的清洗方式数据吗?", "DeleteInfo"), "Prompt", MessageBoxButtons.OKCancel, MessageBoxIcon.Question);
|
||||||
|
if (dr == DialogResult.OK)
|
||||||
|
{
|
||||||
|
string CleanModeId = dataGridView.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
string sql = $@"DELETE FROM BAS_CLEAN_MODE WHERE CLEAN_MODE_ID = '{CleanModeId}'";
|
||||||
|
int row = LeadDbHelperSQLite.ExecuteSql(sql);
|
||||||
|
if (row > 0)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除清洗方式数据成功!", "DeleteSuccessInfo"));
|
||||||
|
RefreshFrmHost();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除清洗方式数据失败!", "DeleteFailInfo"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要删除的清洗方式数据行!", "SelectWantToDeleteRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除清洁方式数据发生异常", "DeleteCleanModeDataExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
120
CleanMachineHMI/FrmUserControl/Base/frmCleanMode.resx
Normal file
@@ -0,0 +1,120 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
</root>
|
||||||
391
CleanMachineHMI/FrmUserControl/Base/frmContaminationDTL.Designer.cs
generated
Normal file
@@ -0,0 +1,391 @@
|
|||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
partial class frmContaminationDTL
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 必需的设计器变量。
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清理所有正在使用的资源。
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region 组件设计器生成的代码
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设计器支持所需的方法 - 不要修改
|
||||||
|
/// 使用代码编辑器修改此方法的内容。
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
this.kryptonPanel3 = new ComponentFactory.Krypton.Toolkit.KryptonPanel();
|
||||||
|
this.kryptonPanel2 = new ComponentFactory.Krypton.Toolkit.KryptonPanel();
|
||||||
|
this.kryptonGroupBox2 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.dataGridView = new ComponentFactory.Krypton.Toolkit.KryptonDataGridView();
|
||||||
|
this.kryptonGroupBox1 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kbt_Reset = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Edit = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Delete = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Query = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Add = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kdtp_CreateEndTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kdtp_CreateStartTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kryptonLabel2 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel5 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.ktb_ContaminationDtlMsg = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kryptonLabel4 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel3 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kcmb_ContaminationType = new ComponentFactory.Krypton.Toolkit.KryptonComboBox();
|
||||||
|
this.kryptonPanel1 = new ComponentFactory.Krypton.Toolkit.KryptonPanel();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel3)).BeginInit();
|
||||||
|
this.kryptonPanel3.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel2)).BeginInit();
|
||||||
|
this.kryptonPanel2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox2.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox1.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox1.SuspendLayout();
|
||||||
|
this.tableLayoutPanel2.SuspendLayout();
|
||||||
|
this.tableLayoutPanel1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_ContaminationType)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel1)).BeginInit();
|
||||||
|
this.kryptonPanel1.SuspendLayout();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// kryptonPanel3
|
||||||
|
//
|
||||||
|
this.kryptonPanel3.Controls.Add(this.kryptonPanel2);
|
||||||
|
this.kryptonPanel3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonPanel3.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonPanel3.Name = "kryptonPanel3";
|
||||||
|
this.kryptonPanel3.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.kryptonPanel3.TabIndex = 1;
|
||||||
|
//
|
||||||
|
// kryptonPanel2
|
||||||
|
//
|
||||||
|
this.kryptonPanel2.Controls.Add(this.kryptonGroupBox2);
|
||||||
|
this.kryptonPanel2.Controls.Add(this.kryptonGroupBox1);
|
||||||
|
this.kryptonPanel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonPanel2.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonPanel2.Name = "kryptonPanel2";
|
||||||
|
this.kryptonPanel2.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.kryptonPanel2.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowOnly;
|
||||||
|
this.kryptonGroupBox2.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox2.CaptionStyle = ComponentFactory.Krypton.Toolkit.LabelStyle.NormalControl;
|
||||||
|
this.kryptonGroupBox2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonGroupBox2.Location = new System.Drawing.Point(0, 131);
|
||||||
|
this.kryptonGroupBox2.Name = "kryptonGroupBox2";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.dataGridView);
|
||||||
|
this.kryptonGroupBox2.Size = new System.Drawing.Size(802, 460);
|
||||||
|
this.kryptonGroupBox2.TabIndex = 7;
|
||||||
|
this.kryptonGroupBox2.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// dataGridView
|
||||||
|
//
|
||||||
|
this.dataGridView.AllowUserToAddRows = false;
|
||||||
|
this.dataGridView.AllowUserToDeleteRows = false;
|
||||||
|
this.dataGridView.AllowUserToResizeRows = false;
|
||||||
|
this.dataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.AllCells;
|
||||||
|
this.dataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
|
||||||
|
this.dataGridView.DataMember = "TestData";
|
||||||
|
this.dataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.dataGridView.GridStyles.Style = ComponentFactory.Krypton.Toolkit.DataGridViewStyle.Mixed;
|
||||||
|
this.dataGridView.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.dataGridView.MultiSelect = false;
|
||||||
|
this.dataGridView.Name = "dataGridView";
|
||||||
|
this.dataGridView.ReadOnly = true;
|
||||||
|
this.dataGridView.RowHeadersVisible = false;
|
||||||
|
this.dataGridView.RowHeadersWidth = 100;
|
||||||
|
this.dataGridView.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
|
||||||
|
this.dataGridView.Size = new System.Drawing.Size(798, 456);
|
||||||
|
this.dataGridView.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.kryptonGroupBox1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonGroupBox1.Name = "kryptonGroupBox1";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.tableLayoutPanel2);
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.tableLayoutPanel1);
|
||||||
|
this.kryptonGroupBox1.Size = new System.Drawing.Size(802, 131);
|
||||||
|
this.kryptonGroupBox1.TabIndex = 0;
|
||||||
|
this.kryptonGroupBox1.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// tableLayoutPanel2
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.tableLayoutPanel2.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel2.ColumnCount = 5;
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 20F));
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Reset, 4, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Edit, 1, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Delete, 2, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Query, 3, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Add, 0, 0);
|
||||||
|
this.tableLayoutPanel2.Location = new System.Drawing.Point(227, 78);
|
||||||
|
this.tableLayoutPanel2.Name = "tableLayoutPanel2";
|
||||||
|
this.tableLayoutPanel2.RowCount = 1;
|
||||||
|
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||||
|
this.tableLayoutPanel2.Size = new System.Drawing.Size(561, 41);
|
||||||
|
this.tableLayoutPanel2.TabIndex = 10;
|
||||||
|
//
|
||||||
|
// kbt_Reset
|
||||||
|
//
|
||||||
|
this.kbt_Reset.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Reset.Location = new System.Drawing.Point(451, 3);
|
||||||
|
this.kbt_Reset.Name = "kbt_Reset";
|
||||||
|
this.kbt_Reset.Size = new System.Drawing.Size(107, 35);
|
||||||
|
this.kbt_Reset.TabIndex = 0;
|
||||||
|
this.kbt_Reset.Tag = "show";
|
||||||
|
this.kbt_Reset.Values.Text = "重置条件";
|
||||||
|
this.kbt_Reset.Click += new System.EventHandler(this.kbt_Reset_Click);
|
||||||
|
//
|
||||||
|
// kbt_Edit
|
||||||
|
//
|
||||||
|
this.kbt_Edit.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Edit.Location = new System.Drawing.Point(115, 3);
|
||||||
|
this.kbt_Edit.Name = "kbt_Edit";
|
||||||
|
this.kbt_Edit.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Edit.TabIndex = 0;
|
||||||
|
this.kbt_Edit.Values.Text = "编辑";
|
||||||
|
this.kbt_Edit.Click += new System.EventHandler(this.kbt_Edit_Click);
|
||||||
|
//
|
||||||
|
// kbt_Delete
|
||||||
|
//
|
||||||
|
this.kbt_Delete.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Delete.Location = new System.Drawing.Point(227, 3);
|
||||||
|
this.kbt_Delete.Name = "kbt_Delete";
|
||||||
|
this.kbt_Delete.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Delete.TabIndex = 0;
|
||||||
|
this.kbt_Delete.Values.Text = "删除";
|
||||||
|
this.kbt_Delete.Click += new System.EventHandler(this.kbt_Delete_Click);
|
||||||
|
//
|
||||||
|
// kbt_Query
|
||||||
|
//
|
||||||
|
this.kbt_Query.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Query.Location = new System.Drawing.Point(339, 3);
|
||||||
|
this.kbt_Query.Name = "kbt_Query";
|
||||||
|
this.kbt_Query.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Query.TabIndex = 0;
|
||||||
|
this.kbt_Query.Tag = "show";
|
||||||
|
this.kbt_Query.Values.Text = "查询";
|
||||||
|
this.kbt_Query.Click += new System.EventHandler(this.kbt_Query_Click);
|
||||||
|
//
|
||||||
|
// kbt_Add
|
||||||
|
//
|
||||||
|
this.kbt_Add.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Add.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kbt_Add.Name = "kbt_Add";
|
||||||
|
this.kbt_Add.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Add.TabIndex = 0;
|
||||||
|
this.kbt_Add.Values.Text = "新增";
|
||||||
|
this.kbt_Add.Click += new System.EventHandler(this.kbt_Add_Click);
|
||||||
|
//
|
||||||
|
// tableLayoutPanel1
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel1.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel1.ColumnCount = 4;
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 220F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 130F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateEndTime, 3, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateStartTime, 1, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel2, 0, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel5, 2, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_ContaminationDtlMsg, 1, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel4, 0, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel3, 2, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kcmb_ContaminationType, 3, 0);
|
||||||
|
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||||
|
this.tableLayoutPanel1.RowCount = 2;
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Size = new System.Drawing.Size(798, 72);
|
||||||
|
this.tableLayoutPanel1.TabIndex = 9;
|
||||||
|
//
|
||||||
|
// kdtp_CreateEndTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateEndTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateEndTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateEndTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateEndTime.Location = new System.Drawing.Point(581, 43);
|
||||||
|
this.kdtp_CreateEndTime.Name = "kdtp_CreateEndTime";
|
||||||
|
this.kdtp_CreateEndTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateEndTime.Size = new System.Drawing.Size(210, 21);
|
||||||
|
this.kdtp_CreateEndTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kdtp_CreateStartTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateStartTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateStartTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateStartTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateStartTime.Location = new System.Drawing.Point(227, 43);
|
||||||
|
this.kdtp_CreateStartTime.Name = "kdtp_CreateStartTime";
|
||||||
|
this.kdtp_CreateStartTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateStartTime.Size = new System.Drawing.Size(210, 21);
|
||||||
|
this.kdtp_CreateStartTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kryptonLabel2
|
||||||
|
//
|
||||||
|
this.kryptonLabel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel2.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kryptonLabel2.Name = "kryptonLabel2";
|
||||||
|
this.kryptonLabel2.Size = new System.Drawing.Size(214, 30);
|
||||||
|
this.kryptonLabel2.TabIndex = 4;
|
||||||
|
this.kryptonLabel2.Values.Text = "污染明细信息:";
|
||||||
|
//
|
||||||
|
// kryptonLabel5
|
||||||
|
//
|
||||||
|
this.kryptonLabel5.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kryptonLabel5.Location = new System.Drawing.Point(497, 44);
|
||||||
|
this.kryptonLabel5.Name = "kryptonLabel5";
|
||||||
|
this.kryptonLabel5.Size = new System.Drawing.Size(23, 20);
|
||||||
|
this.kryptonLabel5.TabIndex = 4;
|
||||||
|
this.kryptonLabel5.Values.Text = "至";
|
||||||
|
//
|
||||||
|
// ktb_ContaminationDtlMsg
|
||||||
|
//
|
||||||
|
this.ktb_ContaminationDtlMsg.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_ContaminationDtlMsg.Location = new System.Drawing.Point(227, 6);
|
||||||
|
this.ktb_ContaminationDtlMsg.Name = "ktb_ContaminationDtlMsg";
|
||||||
|
this.ktb_ContaminationDtlMsg.Size = new System.Drawing.Size(210, 23);
|
||||||
|
this.ktb_ContaminationDtlMsg.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// kryptonLabel4
|
||||||
|
//
|
||||||
|
this.kryptonLabel4.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel4.Location = new System.Drawing.Point(3, 39);
|
||||||
|
this.kryptonLabel4.Name = "kryptonLabel4";
|
||||||
|
this.kryptonLabel4.Size = new System.Drawing.Size(214, 30);
|
||||||
|
this.kryptonLabel4.TabIndex = 4;
|
||||||
|
this.kryptonLabel4.Values.Text = "创建时间:";
|
||||||
|
//
|
||||||
|
// kryptonLabel3
|
||||||
|
//
|
||||||
|
this.kryptonLabel3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel3.Location = new System.Drawing.Point(447, 3);
|
||||||
|
this.kryptonLabel3.Name = "kryptonLabel3";
|
||||||
|
this.kryptonLabel3.Size = new System.Drawing.Size(124, 30);
|
||||||
|
this.kryptonLabel3.TabIndex = 4;
|
||||||
|
this.kryptonLabel3.Values.Text = "污染类型:";
|
||||||
|
//
|
||||||
|
// kcmb_ContaminationType
|
||||||
|
//
|
||||||
|
this.kcmb_ContaminationType.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kcmb_ContaminationType.DropDownWidth = 246;
|
||||||
|
this.kcmb_ContaminationType.Location = new System.Drawing.Point(581, 7);
|
||||||
|
this.kcmb_ContaminationType.Name = "kcmb_ContaminationType";
|
||||||
|
this.kcmb_ContaminationType.Size = new System.Drawing.Size(210, 21);
|
||||||
|
this.kcmb_ContaminationType.TabIndex = 8;
|
||||||
|
//
|
||||||
|
// kryptonPanel1
|
||||||
|
//
|
||||||
|
this.kryptonPanel1.Controls.Add(this.kryptonPanel3);
|
||||||
|
this.kryptonPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonPanel1.Name = "kryptonPanel1";
|
||||||
|
this.kryptonPanel1.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.kryptonPanel1.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// frmContaminationDTL
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.Controls.Add(this.kryptonPanel1);
|
||||||
|
this.Name = "frmContaminationDTL";
|
||||||
|
this.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.Load += new System.EventHandler(this.frmContaminationDTL_Load);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel3)).EndInit();
|
||||||
|
this.kryptonPanel3.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel2)).EndInit();
|
||||||
|
this.kryptonPanel2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox2.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).EndInit();
|
||||||
|
this.kryptonGroupBox2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox1.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).EndInit();
|
||||||
|
this.kryptonGroupBox1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel2.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_ContaminationType)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel1)).EndInit();
|
||||||
|
this.kryptonPanel1.ResumeLayout(false);
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonPanel kryptonPanel3;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonPanel kryptonPanel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridView dataGridView;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox1;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Reset;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Edit;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Delete;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Query;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Add;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateEndTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateStartTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel5;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_ContaminationDtlMsg;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel4;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel3;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonComboBox kcmb_ContaminationType;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonPanel kryptonPanel1;
|
||||||
|
}
|
||||||
|
}
|
||||||
205
CleanMachineHMI/FrmUserControl/Base/frmContaminationDTL.cs
Normal file
@@ -0,0 +1,205 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.frmChild;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using LeadDataBaseUtility;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Web.UI.WebControls;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
[FormType(EnumFormType.ContaminationDTL)]
|
||||||
|
public partial class frmContaminationDTL : UserControl
|
||||||
|
{
|
||||||
|
private DataTable _InfoLanguageTextList;
|
||||||
|
public delegate void dlgRefreshFrmHost();
|
||||||
|
public static dlgRefreshFrmHost RefreshFrmHost;
|
||||||
|
|
||||||
|
public frmContaminationDTL()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
_InfoLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void Init()
|
||||||
|
{
|
||||||
|
var sql = $@"SELECT A.CONTAMINATION_DTL_ID 序号,B.CONTAMINATION_TYPE_CODE 污染类型编码,B.CONTAMINATION_TYPE_NAME 污染类型名称,A.CONTAMINATION_DTL_CODE 污染明细编码,A.CONTAMINATION_DTL_NAME 污染明细名称,A.CREATE_TIME 创建时间 FROM BAS_CONTAMINATION_DTL A LEFT JOIN BAS_CONTAMINATION_TYPE B ON A.CONTAMINATION_TYPE_CODE = B.CONTAMINATION_TYPE_CODE WHERE 1=1 ";
|
||||||
|
if (!string.IsNullOrEmpty(ktb_ContaminationDtlMsg.Text))
|
||||||
|
{
|
||||||
|
sql += $" AND (A.CONTAMINATION_DTL_CODE LIKE '%{ktb_ContaminationDtlMsg.Text}%' or A.CONTAMINATION_DTL_NAME LIKE '%{ktb_ContaminationDtlMsg.Text}%')";
|
||||||
|
}
|
||||||
|
if (kcmb_ContaminationType.SelectedIndex != 0)
|
||||||
|
{
|
||||||
|
sql += $" AND B.CONTAMINATION_TYPE_CODE = '{((ListItem)kcmb_ContaminationType.SelectedItem).Value}'";
|
||||||
|
}
|
||||||
|
if (kdtp_CreateStartTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND A.CREATE_TIME >= '{kdtp_CreateStartTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
if (kdtp_CreateEndTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND A.CREATE_TIME <= '{kdtp_CreateEndTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
|
||||||
|
dataGridView.Columns.Clear();
|
||||||
|
dataGridView.DataSource = dt;
|
||||||
|
dataGridView.SetDataViewColumnText(this.Name, GlobalHelper.LanguageCode);
|
||||||
|
|
||||||
|
}
|
||||||
|
private void txt_GotFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.ShowInputPanel();
|
||||||
|
}
|
||||||
|
private void txt_LostFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.HideInputPanel();
|
||||||
|
}
|
||||||
|
private void InitControlEvent()
|
||||||
|
{
|
||||||
|
ktb_ContaminationDtlMsg.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_ContaminationDtlMsg.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void frmContaminationDTL_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
InitControlEvent();
|
||||||
|
this.SetFormControlText(GlobalHelper.LanguageCode);
|
||||||
|
string sql = $@"select CONTAMINATION_TYPE_CODE,CONTAMINATION_TYPE_NAME from BAS_CONTAMINATION_TYPE where DEL_FLAG=0";
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
if (dt != null && dt.Rows.Count > 0)
|
||||||
|
{
|
||||||
|
kcmb_ContaminationType.Items.Add(new ListItem
|
||||||
|
{
|
||||||
|
Value = "0",
|
||||||
|
Text = "Please Select",
|
||||||
|
});
|
||||||
|
foreach (DataRow item in dt.Rows)
|
||||||
|
{
|
||||||
|
kcmb_ContaminationType.Items.Add(new ListItem
|
||||||
|
{
|
||||||
|
Value = item["CONTAMINATION_TYPE_CODE"].ToString(),
|
||||||
|
Text = item["CONTAMINATION_TYPE_NAME"].ToString(),
|
||||||
|
});
|
||||||
|
}
|
||||||
|
kcmb_ContaminationType.SelectedIndex = 0;
|
||||||
|
}
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
RefreshFrmHost = new dlgRefreshFrmHost(Init);
|
||||||
|
Init();
|
||||||
|
foreach (Control item in tableLayoutPanel2.Controls)
|
||||||
|
{
|
||||||
|
if (item.Tag == null)
|
||||||
|
{
|
||||||
|
DataRow[] drs = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{this.Name}' AND MENU_PID = '-1'");
|
||||||
|
DataRow[] drs1 = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{item.Name}' AND MENU_PID = '{drs[0]["MENU_ID"]}'");
|
||||||
|
if (drs1.Length > 0)
|
||||||
|
{
|
||||||
|
item.Enabled = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
item.Enabled = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kryptonGroupBox2.Focus();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("加载污染明细界面发生异常", "LoadContaminationDTLExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Query_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
Init();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("查询污染明细数据发生异常", "QueryContaminationDTLData") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Reset_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
ktb_ContaminationDtlMsg.Text = "";
|
||||||
|
kcmb_ContaminationType.SelectedIndex = 0;
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Add_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
frmAddContaminationDtl frm = new frmAddContaminationDtl();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Edit_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (dataGridView.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
frmEditContaminationDtl frm = new frmEditContaminationDtl();
|
||||||
|
frm.ContaminationDtlId = dataGridView.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要编辑的污染明细数据行!", "SelectWantToEditRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Delete_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (dataGridView.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
DialogResult dr = KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("确定要删除所选的污染明细数据吗?", "DeleteInfo"), "Prompt", MessageBoxButtons.OKCancel, MessageBoxIcon.Question);
|
||||||
|
if (dr == DialogResult.OK)
|
||||||
|
{
|
||||||
|
string ContaminationDtlId = dataGridView.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
string sql = $@"DELETE FROM BAS_CONTAMINATION_DTL WHERE CONTAMINATION_DTL_ID = '{ContaminationDtlId}'";
|
||||||
|
int row = LeadDbHelperSQLite.ExecuteSql(sql);
|
||||||
|
if (row > 0)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除污染明细数据成功!", "DeleteSuccessInfo"));
|
||||||
|
RefreshFrmHost();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除污染明细数据失败!", "DeleteFailInfo"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要删除的污染明细数据行!", "SelectWantToDeleteRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除污染明细数据发生异常", "DeleteContaminationDTLDataExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
120
CleanMachineHMI/FrmUserControl/Base/frmContaminationDTL.resx
Normal file
@@ -0,0 +1,120 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
</root>
|
||||||
391
CleanMachineHMI/FrmUserControl/Base/frmContaminationType.Designer.cs
generated
Normal file
@@ -0,0 +1,391 @@
|
|||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
partial class frmContaminationType
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 必需的设计器变量。
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清理所有正在使用的资源。
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region 组件设计器生成的代码
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设计器支持所需的方法 - 不要修改
|
||||||
|
/// 使用代码编辑器修改此方法的内容。
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
this.kryptonPanel1 = new ComponentFactory.Krypton.Toolkit.KryptonPanel();
|
||||||
|
this.kryptonPanel3 = new ComponentFactory.Krypton.Toolkit.KryptonPanel();
|
||||||
|
this.kryptonPanel2 = new ComponentFactory.Krypton.Toolkit.KryptonPanel();
|
||||||
|
this.kryptonGroupBox2 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.dataGridView = new ComponentFactory.Krypton.Toolkit.KryptonDataGridView();
|
||||||
|
this.kryptonGroupBox1 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kbt_Reset = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Edit = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Delete = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Query = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Add = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kdtp_CreateEndTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kdtp_CreateStartTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kryptonLabel2 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel5 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.ktb_ContaminationTypeMsg = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kryptonLabel4 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel3 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kcmb_CleanMode = new ComponentFactory.Krypton.Toolkit.KryptonComboBox();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel1)).BeginInit();
|
||||||
|
this.kryptonPanel1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel3)).BeginInit();
|
||||||
|
this.kryptonPanel3.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel2)).BeginInit();
|
||||||
|
this.kryptonPanel2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox2.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox1.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox1.SuspendLayout();
|
||||||
|
this.tableLayoutPanel2.SuspendLayout();
|
||||||
|
this.tableLayoutPanel1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_CleanMode)).BeginInit();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// kryptonPanel1
|
||||||
|
//
|
||||||
|
this.kryptonPanel1.Controls.Add(this.kryptonPanel3);
|
||||||
|
this.kryptonPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonPanel1.Name = "kryptonPanel1";
|
||||||
|
this.kryptonPanel1.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.kryptonPanel1.TabIndex = 4;
|
||||||
|
//
|
||||||
|
// kryptonPanel3
|
||||||
|
//
|
||||||
|
this.kryptonPanel3.Controls.Add(this.kryptonPanel2);
|
||||||
|
this.kryptonPanel3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonPanel3.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonPanel3.Name = "kryptonPanel3";
|
||||||
|
this.kryptonPanel3.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.kryptonPanel3.TabIndex = 1;
|
||||||
|
//
|
||||||
|
// kryptonPanel2
|
||||||
|
//
|
||||||
|
this.kryptonPanel2.Controls.Add(this.kryptonGroupBox2);
|
||||||
|
this.kryptonPanel2.Controls.Add(this.kryptonGroupBox1);
|
||||||
|
this.kryptonPanel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonPanel2.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonPanel2.Name = "kryptonPanel2";
|
||||||
|
this.kryptonPanel2.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.kryptonPanel2.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowOnly;
|
||||||
|
this.kryptonGroupBox2.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox2.CaptionStyle = ComponentFactory.Krypton.Toolkit.LabelStyle.NormalControl;
|
||||||
|
this.kryptonGroupBox2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonGroupBox2.Location = new System.Drawing.Point(0, 129);
|
||||||
|
this.kryptonGroupBox2.Name = "kryptonGroupBox2";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.dataGridView);
|
||||||
|
this.kryptonGroupBox2.Size = new System.Drawing.Size(802, 462);
|
||||||
|
this.kryptonGroupBox2.TabIndex = 6;
|
||||||
|
this.kryptonGroupBox2.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// dataGridView
|
||||||
|
//
|
||||||
|
this.dataGridView.AllowUserToAddRows = false;
|
||||||
|
this.dataGridView.AllowUserToDeleteRows = false;
|
||||||
|
this.dataGridView.AllowUserToResizeRows = false;
|
||||||
|
this.dataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.AllCells;
|
||||||
|
this.dataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
|
||||||
|
this.dataGridView.DataMember = "TestData";
|
||||||
|
this.dataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.dataGridView.GridStyles.Style = ComponentFactory.Krypton.Toolkit.DataGridViewStyle.Mixed;
|
||||||
|
this.dataGridView.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.dataGridView.MultiSelect = false;
|
||||||
|
this.dataGridView.Name = "dataGridView";
|
||||||
|
this.dataGridView.ReadOnly = true;
|
||||||
|
this.dataGridView.RowHeadersVisible = false;
|
||||||
|
this.dataGridView.RowHeadersWidth = 100;
|
||||||
|
this.dataGridView.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
|
||||||
|
this.dataGridView.Size = new System.Drawing.Size(798, 458);
|
||||||
|
this.dataGridView.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.kryptonGroupBox1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonGroupBox1.Name = "kryptonGroupBox1";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.tableLayoutPanel2);
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.tableLayoutPanel1);
|
||||||
|
this.kryptonGroupBox1.Size = new System.Drawing.Size(802, 129);
|
||||||
|
this.kryptonGroupBox1.TabIndex = 0;
|
||||||
|
this.kryptonGroupBox1.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// tableLayoutPanel2
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.tableLayoutPanel2.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel2.ColumnCount = 5;
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 20F));
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Reset, 4, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Edit, 1, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Delete, 2, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Query, 3, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Add, 0, 0);
|
||||||
|
this.tableLayoutPanel2.Location = new System.Drawing.Point(236, 76);
|
||||||
|
this.tableLayoutPanel2.Name = "tableLayoutPanel2";
|
||||||
|
this.tableLayoutPanel2.RowCount = 1;
|
||||||
|
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||||
|
this.tableLayoutPanel2.Size = new System.Drawing.Size(561, 41);
|
||||||
|
this.tableLayoutPanel2.TabIndex = 8;
|
||||||
|
//
|
||||||
|
// kbt_Reset
|
||||||
|
//
|
||||||
|
this.kbt_Reset.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Reset.Location = new System.Drawing.Point(451, 3);
|
||||||
|
this.kbt_Reset.Name = "kbt_Reset";
|
||||||
|
this.kbt_Reset.Size = new System.Drawing.Size(107, 35);
|
||||||
|
this.kbt_Reset.TabIndex = 0;
|
||||||
|
this.kbt_Reset.Tag = "show";
|
||||||
|
this.kbt_Reset.Values.Text = "重置条件";
|
||||||
|
this.kbt_Reset.Click += new System.EventHandler(this.kbt_Reset_Click);
|
||||||
|
//
|
||||||
|
// kbt_Edit
|
||||||
|
//
|
||||||
|
this.kbt_Edit.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Edit.Location = new System.Drawing.Point(115, 3);
|
||||||
|
this.kbt_Edit.Name = "kbt_Edit";
|
||||||
|
this.kbt_Edit.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Edit.TabIndex = 0;
|
||||||
|
this.kbt_Edit.Values.Text = "编辑";
|
||||||
|
this.kbt_Edit.Click += new System.EventHandler(this.kbt_Edit_Click);
|
||||||
|
//
|
||||||
|
// kbt_Delete
|
||||||
|
//
|
||||||
|
this.kbt_Delete.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Delete.Location = new System.Drawing.Point(227, 3);
|
||||||
|
this.kbt_Delete.Name = "kbt_Delete";
|
||||||
|
this.kbt_Delete.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Delete.TabIndex = 0;
|
||||||
|
this.kbt_Delete.Values.Text = "删除";
|
||||||
|
this.kbt_Delete.Click += new System.EventHandler(this.kbt_Delete_Click);
|
||||||
|
//
|
||||||
|
// kbt_Query
|
||||||
|
//
|
||||||
|
this.kbt_Query.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Query.Location = new System.Drawing.Point(339, 3);
|
||||||
|
this.kbt_Query.Name = "kbt_Query";
|
||||||
|
this.kbt_Query.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Query.TabIndex = 0;
|
||||||
|
this.kbt_Query.Tag = "show";
|
||||||
|
this.kbt_Query.Values.Text = "查询";
|
||||||
|
this.kbt_Query.Click += new System.EventHandler(this.kbt_Query_Click);
|
||||||
|
//
|
||||||
|
// kbt_Add
|
||||||
|
//
|
||||||
|
this.kbt_Add.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Add.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kbt_Add.Name = "kbt_Add";
|
||||||
|
this.kbt_Add.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Add.TabIndex = 0;
|
||||||
|
this.kbt_Add.Values.Text = "新增";
|
||||||
|
this.kbt_Add.Click += new System.EventHandler(this.kbt_Add_Click);
|
||||||
|
//
|
||||||
|
// tableLayoutPanel1
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel1.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel1.ColumnCount = 4;
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 220F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 100F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateEndTime, 3, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateStartTime, 1, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel2, 0, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel5, 2, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_ContaminationTypeMsg, 1, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel4, 0, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel3, 2, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kcmb_CleanMode, 3, 0);
|
||||||
|
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||||
|
this.tableLayoutPanel1.RowCount = 2;
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Size = new System.Drawing.Size(798, 72);
|
||||||
|
this.tableLayoutPanel1.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kdtp_CreateEndTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateEndTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateEndTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateEndTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateEndTime.Location = new System.Drawing.Point(573, 43);
|
||||||
|
this.kdtp_CreateEndTime.Name = "kdtp_CreateEndTime";
|
||||||
|
this.kdtp_CreateEndTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateEndTime.Size = new System.Drawing.Size(210, 21);
|
||||||
|
this.kdtp_CreateEndTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kdtp_CreateStartTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateStartTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateStartTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateStartTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateStartTime.Location = new System.Drawing.Point(234, 43);
|
||||||
|
this.kdtp_CreateStartTime.Name = "kdtp_CreateStartTime";
|
||||||
|
this.kdtp_CreateStartTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateStartTime.Size = new System.Drawing.Size(210, 21);
|
||||||
|
this.kdtp_CreateStartTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kryptonLabel2
|
||||||
|
//
|
||||||
|
this.kryptonLabel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel2.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kryptonLabel2.Name = "kryptonLabel2";
|
||||||
|
this.kryptonLabel2.Size = new System.Drawing.Size(214, 30);
|
||||||
|
this.kryptonLabel2.TabIndex = 4;
|
||||||
|
this.kryptonLabel2.Values.Text = "污染类型信息:";
|
||||||
|
//
|
||||||
|
// kryptonLabel5
|
||||||
|
//
|
||||||
|
this.kryptonLabel5.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kryptonLabel5.Location = new System.Drawing.Point(497, 44);
|
||||||
|
this.kryptonLabel5.Name = "kryptonLabel5";
|
||||||
|
this.kryptonLabel5.Size = new System.Drawing.Size(23, 20);
|
||||||
|
this.kryptonLabel5.TabIndex = 4;
|
||||||
|
this.kryptonLabel5.Values.Text = "至";
|
||||||
|
//
|
||||||
|
// ktb_ContaminationTypeMsg
|
||||||
|
//
|
||||||
|
this.ktb_ContaminationTypeMsg.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_ContaminationTypeMsg.Location = new System.Drawing.Point(234, 6);
|
||||||
|
this.ktb_ContaminationTypeMsg.Name = "ktb_ContaminationTypeMsg";
|
||||||
|
this.ktb_ContaminationTypeMsg.Size = new System.Drawing.Size(210, 23);
|
||||||
|
this.ktb_ContaminationTypeMsg.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// kryptonLabel4
|
||||||
|
//
|
||||||
|
this.kryptonLabel4.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel4.Location = new System.Drawing.Point(3, 39);
|
||||||
|
this.kryptonLabel4.Name = "kryptonLabel4";
|
||||||
|
this.kryptonLabel4.Size = new System.Drawing.Size(214, 30);
|
||||||
|
this.kryptonLabel4.TabIndex = 4;
|
||||||
|
this.kryptonLabel4.Values.Text = "创建时间:";
|
||||||
|
//
|
||||||
|
// kryptonLabel3
|
||||||
|
//
|
||||||
|
this.kryptonLabel3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel3.Location = new System.Drawing.Point(462, 3);
|
||||||
|
this.kryptonLabel3.Name = "kryptonLabel3";
|
||||||
|
this.kryptonLabel3.Size = new System.Drawing.Size(94, 30);
|
||||||
|
this.kryptonLabel3.TabIndex = 4;
|
||||||
|
this.kryptonLabel3.Values.Text = "清洁方式:";
|
||||||
|
//
|
||||||
|
// kcmb_CleanMode
|
||||||
|
//
|
||||||
|
this.kcmb_CleanMode.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kcmb_CleanMode.DropDownWidth = 246;
|
||||||
|
this.kcmb_CleanMode.Location = new System.Drawing.Point(573, 7);
|
||||||
|
this.kcmb_CleanMode.Name = "kcmb_CleanMode";
|
||||||
|
this.kcmb_CleanMode.Size = new System.Drawing.Size(210, 21);
|
||||||
|
this.kcmb_CleanMode.TabIndex = 8;
|
||||||
|
//
|
||||||
|
// frmContaminationType
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.Controls.Add(this.kryptonPanel1);
|
||||||
|
this.Name = "frmContaminationType";
|
||||||
|
this.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.Load += new System.EventHandler(this.frmContaminationType_Load);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel1)).EndInit();
|
||||||
|
this.kryptonPanel1.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel3)).EndInit();
|
||||||
|
this.kryptonPanel3.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel2)).EndInit();
|
||||||
|
this.kryptonPanel2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox2.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).EndInit();
|
||||||
|
this.kryptonGroupBox2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox1.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).EndInit();
|
||||||
|
this.kryptonGroupBox1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel2.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_CleanMode)).EndInit();
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonPanel kryptonPanel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonPanel kryptonPanel3;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonPanel kryptonPanel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridView dataGridView;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox1;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Reset;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Edit;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Delete;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Query;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Add;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateEndTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateStartTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel5;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_ContaminationTypeMsg;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel4;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel3;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonComboBox kcmb_CleanMode;
|
||||||
|
}
|
||||||
|
}
|
||||||
215
CleanMachineHMI/FrmUserControl/Base/frmContaminationType.cs
Normal file
@@ -0,0 +1,215 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.frmChild;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using LeadDataBaseUtility;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Web.UI.WebControls;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
[FormType(EnumFormType.ContaminationType)]
|
||||||
|
public partial class frmContaminationType : UserControl
|
||||||
|
{
|
||||||
|
private DataTable _InfoLanguageTextList;
|
||||||
|
public delegate void dlgRefreshFrmHost();
|
||||||
|
public static dlgRefreshFrmHost RefreshFrmHost;
|
||||||
|
|
||||||
|
public frmContaminationType()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
_InfoLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override CreateParams CreateParams
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
CreateParams cp = base.CreateParams;
|
||||||
|
cp.ExStyle |= 0x02000000;
|
||||||
|
return cp;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public void Init()
|
||||||
|
{
|
||||||
|
var sql = $@"SELECT A.CONTAMINATION_TYPE_ID 序号,B.CLEAN_MODE_CODE 清洁方式编码,B.CLEAN_MODE_NAME 清洁方式名称,A.CONTAMINATION_TYPE_CODE 污染类型编码,A.CONTAMINATION_TYPE_NAME 污染类型名称,A.CREATE_TIME 创建时间 FROM BAS_CONTAMINATION_TYPE A LEFT JOIN BAS_CLEAN_MODE B ON A.CLEAN_MODE_CODE = B.CLEAN_MODE_CODE Where 1=1";
|
||||||
|
if (!string.IsNullOrEmpty(ktb_ContaminationTypeMsg.Text))
|
||||||
|
{
|
||||||
|
sql += $" AND (A.CONTAMINATION_TYPE_CODE LIKE '%{ktb_ContaminationTypeMsg.Text}%' or A.CONTAMINATION_TYPE_NAME LIKE '%{ktb_ContaminationTypeMsg.Text}%')";
|
||||||
|
}
|
||||||
|
if (kcmb_CleanMode.SelectedIndex != 0)
|
||||||
|
{
|
||||||
|
sql += $" AND B.CLEAN_MODE_CODE = '{((ListItem)kcmb_CleanMode.SelectedItem).Value}'";
|
||||||
|
}
|
||||||
|
if (kdtp_CreateStartTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND A.CREATE_TIME >= '{kdtp_CreateStartTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
if (kdtp_CreateEndTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND A.CREATE_TIME <= '{kdtp_CreateEndTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
|
||||||
|
dataGridView.Columns.Clear();
|
||||||
|
dataGridView.DataSource = dt;
|
||||||
|
dataGridView.SetDataViewColumnText(this.Name, GlobalHelper.LanguageCode);
|
||||||
|
|
||||||
|
}
|
||||||
|
private void txt_GotFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.ShowInputPanel();
|
||||||
|
}
|
||||||
|
private void txt_LostFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.HideInputPanel();
|
||||||
|
}
|
||||||
|
private void InitControlEvent()
|
||||||
|
{
|
||||||
|
ktb_ContaminationTypeMsg.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_ContaminationTypeMsg.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void frmContaminationType_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
InitControlEvent();
|
||||||
|
this.SetFormControlText(GlobalHelper.LanguageCode);
|
||||||
|
string sql = $@"select CLEAN_MODE_CODE,CLEAN_MODE_NAME from BAS_CLEAN_MODE where DEL_FLAG=0";
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
if (dt != null && dt.Rows.Count > 0)
|
||||||
|
{
|
||||||
|
kcmb_CleanMode.Items.Add(new ListItem
|
||||||
|
{
|
||||||
|
Value = "0",
|
||||||
|
Text = "Please Select",
|
||||||
|
});
|
||||||
|
foreach (DataRow item in dt.Rows)
|
||||||
|
{
|
||||||
|
kcmb_CleanMode.Items.Add(new ListItem
|
||||||
|
{
|
||||||
|
Value = item["CLEAN_MODE_CODE"].ToString(),
|
||||||
|
Text = item["CLEAN_MODE_NAME"].ToString(),
|
||||||
|
});
|
||||||
|
}
|
||||||
|
kcmb_CleanMode.SelectedIndex = 0;
|
||||||
|
}
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
RefreshFrmHost = new dlgRefreshFrmHost(Init);
|
||||||
|
Init();
|
||||||
|
foreach (Control item in tableLayoutPanel2.Controls)
|
||||||
|
{
|
||||||
|
if (item.Tag == null)
|
||||||
|
{
|
||||||
|
DataRow[] drs = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{this.Name}' AND MENU_PID = '-1'");
|
||||||
|
DataRow[] drs1 = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{item.Name}' AND MENU_PID = '{drs[0]["MENU_ID"]}'");
|
||||||
|
if (drs1.Length > 0)
|
||||||
|
{
|
||||||
|
item.Enabled = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
item.Enabled = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kryptonGroupBox2.Focus();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("加载污染类型界面发生异常", "LoadContaminationTypeExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Query_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
Init();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("查询污染类型数据发生异常", "QueryContaminationTypeData") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Reset_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
ktb_ContaminationTypeMsg.Text = "";
|
||||||
|
kcmb_CleanMode.SelectedIndex = 0;
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Add_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
frmAddContaminationType frm = new frmAddContaminationType();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Edit_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (dataGridView.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
frmEditContaminationType frm = new frmEditContaminationType();
|
||||||
|
frm.ContaminationId = dataGridView.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要编辑的污染类型数据行!", "SelectWantToEditRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Delete_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (dataGridView.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
DialogResult dr = KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("确定要删除所选的污染类型数据吗?", "DeleteInfo"), "Prompt", MessageBoxButtons.OKCancel, MessageBoxIcon.Question);
|
||||||
|
if (dr == DialogResult.OK)
|
||||||
|
{
|
||||||
|
string ContaminationId = dataGridView.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
string sql = $@"DELETE FROM BAS_CONTAMINATION_TYPE WHERE CONTAMINATION_TYPE_ID = '{ContaminationId}'";
|
||||||
|
int row = LeadDbHelperSQLite.ExecuteSql(sql);
|
||||||
|
if (row > 0)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除污染类型数据成功!", "DeleteSuccessInfo"));
|
||||||
|
RefreshFrmHost();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除污染类型数据失败!", "DeleteFailInfo"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要删除的污染类型数据行!", "SelectWantToDeleteRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除污染类型数据发生异常", "DeleteContaminationTypeDataExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
120
CleanMachineHMI/FrmUserControl/Base/frmContaminationType.resx
Normal file
@@ -0,0 +1,120 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
</root>
|
||||||
413
CleanMachineHMI/FrmUserControl/Base/frmRole.Designer.cs
generated
Normal file
@@ -0,0 +1,413 @@
|
|||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
partial class frmRole
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 必需的设计器变量。
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清理所有正在使用的资源。
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region 组件设计器生成的代码
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设计器支持所需的方法 - 不要修改
|
||||||
|
/// 使用代码编辑器修改此方法的内容。
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
this.kryptonPanel6 = new ComponentFactory.Krypton.Toolkit.KryptonPanel();
|
||||||
|
this.kryptonGroupBox1 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.dataGridView = new ComponentFactory.Krypton.Toolkit.KryptonDataGridView();
|
||||||
|
this.kryptonGroupBox2 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kbt_Add = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Reset = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Query = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Edit = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Delete = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.ktb_setRoleMenuPermission = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kdtp_CreateEndTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kdtp_CreateStartTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kryptonLabel2 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel5 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kcmb_roleGrade = new ComponentFactory.Krypton.Toolkit.KryptonComboBox();
|
||||||
|
this.ktb_roleMsg = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kryptonLabel4 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel3 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.dataGridViewTextBoxColumn2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
|
this.dataGridViewTextBoxColumn4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
|
this.dataGridViewTextBoxColumn3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
|
this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel6)).BeginInit();
|
||||||
|
this.kryptonPanel6.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox1.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox2.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox2.SuspendLayout();
|
||||||
|
this.tableLayoutPanel2.SuspendLayout();
|
||||||
|
this.tableLayoutPanel1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_roleGrade)).BeginInit();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// kryptonPanel6
|
||||||
|
//
|
||||||
|
this.kryptonPanel6.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
|
||||||
|
this.kryptonPanel6.Controls.Add(this.kryptonGroupBox1);
|
||||||
|
this.kryptonPanel6.Controls.Add(this.kryptonGroupBox2);
|
||||||
|
this.kryptonPanel6.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonPanel6.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonPanel6.Name = "kryptonPanel6";
|
||||||
|
this.kryptonPanel6.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.kryptonPanel6.TabIndex = 6;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowOnly;
|
||||||
|
this.kryptonGroupBox1.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox1.CaptionStyle = ComponentFactory.Krypton.Toolkit.LabelStyle.NormalControl;
|
||||||
|
this.kryptonGroupBox1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonGroupBox1.Location = new System.Drawing.Point(0, 129);
|
||||||
|
this.kryptonGroupBox1.Name = "kryptonGroupBox1";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.dataGridView);
|
||||||
|
this.kryptonGroupBox1.Size = new System.Drawing.Size(802, 462);
|
||||||
|
this.kryptonGroupBox1.TabIndex = 4;
|
||||||
|
this.kryptonGroupBox1.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// dataGridView
|
||||||
|
//
|
||||||
|
this.dataGridView.AllowUserToAddRows = false;
|
||||||
|
this.dataGridView.AllowUserToDeleteRows = false;
|
||||||
|
this.dataGridView.AllowUserToResizeRows = false;
|
||||||
|
this.dataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
|
||||||
|
this.dataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
|
||||||
|
this.dataGridView.DataMember = "TestData";
|
||||||
|
this.dataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.dataGridView.GridStyles.Style = ComponentFactory.Krypton.Toolkit.DataGridViewStyle.Mixed;
|
||||||
|
this.dataGridView.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.dataGridView.MultiSelect = false;
|
||||||
|
this.dataGridView.Name = "dataGridView";
|
||||||
|
this.dataGridView.ReadOnly = true;
|
||||||
|
this.dataGridView.RowHeadersVisible = false;
|
||||||
|
this.dataGridView.RowHeadersWidth = 100;
|
||||||
|
this.dataGridView.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
|
||||||
|
this.dataGridView.Size = new System.Drawing.Size(798, 458);
|
||||||
|
this.dataGridView.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.kryptonGroupBox2.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonGroupBox2.Name = "kryptonGroupBox2";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.tableLayoutPanel2);
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.tableLayoutPanel1);
|
||||||
|
this.kryptonGroupBox2.Size = new System.Drawing.Size(802, 129);
|
||||||
|
this.kryptonGroupBox2.TabIndex = 0;
|
||||||
|
this.kryptonGroupBox2.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// tableLayoutPanel2
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.tableLayoutPanel2.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel2.ColumnCount = 6;
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 16.66667F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 16.66667F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 16.66667F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 16.66667F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 16.66667F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 16.66667F));
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Add, 0, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Reset, 5, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Query, 4, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Edit, 1, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Delete, 2, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.ktb_setRoleMenuPermission, 3, 0);
|
||||||
|
this.tableLayoutPanel2.Location = new System.Drawing.Point(164, 78);
|
||||||
|
this.tableLayoutPanel2.Name = "tableLayoutPanel2";
|
||||||
|
this.tableLayoutPanel2.RowCount = 1;
|
||||||
|
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||||
|
this.tableLayoutPanel2.Size = new System.Drawing.Size(631, 41);
|
||||||
|
this.tableLayoutPanel2.TabIndex = 2;
|
||||||
|
//
|
||||||
|
// kbt_Add
|
||||||
|
//
|
||||||
|
this.kbt_Add.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Add.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kbt_Add.Name = "kbt_Add";
|
||||||
|
this.kbt_Add.Size = new System.Drawing.Size(99, 35);
|
||||||
|
this.kbt_Add.TabIndex = 0;
|
||||||
|
this.kbt_Add.Values.Text = "新增";
|
||||||
|
this.kbt_Add.Click += new System.EventHandler(this.kbt_Add_Click);
|
||||||
|
//
|
||||||
|
// kbt_Reset
|
||||||
|
//
|
||||||
|
this.kbt_Reset.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Reset.Location = new System.Drawing.Point(528, 3);
|
||||||
|
this.kbt_Reset.Name = "kbt_Reset";
|
||||||
|
this.kbt_Reset.Size = new System.Drawing.Size(100, 35);
|
||||||
|
this.kbt_Reset.TabIndex = 0;
|
||||||
|
this.kbt_Reset.Tag = "show";
|
||||||
|
this.kbt_Reset.Values.Text = "重置条件";
|
||||||
|
this.kbt_Reset.Click += new System.EventHandler(this.kbt_Reset_Click);
|
||||||
|
//
|
||||||
|
// kbt_Query
|
||||||
|
//
|
||||||
|
this.kbt_Query.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Query.Location = new System.Drawing.Point(423, 3);
|
||||||
|
this.kbt_Query.Name = "kbt_Query";
|
||||||
|
this.kbt_Query.Size = new System.Drawing.Size(99, 35);
|
||||||
|
this.kbt_Query.TabIndex = 0;
|
||||||
|
this.kbt_Query.Tag = "show";
|
||||||
|
this.kbt_Query.Values.Text = "查询";
|
||||||
|
this.kbt_Query.Click += new System.EventHandler(this.kbt_Query_Click);
|
||||||
|
//
|
||||||
|
// kbt_Edit
|
||||||
|
//
|
||||||
|
this.kbt_Edit.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Edit.Location = new System.Drawing.Point(108, 3);
|
||||||
|
this.kbt_Edit.Name = "kbt_Edit";
|
||||||
|
this.kbt_Edit.Size = new System.Drawing.Size(99, 35);
|
||||||
|
this.kbt_Edit.TabIndex = 0;
|
||||||
|
this.kbt_Edit.Values.Text = "编辑";
|
||||||
|
this.kbt_Edit.Click += new System.EventHandler(this.kbt_Edit_Click);
|
||||||
|
//
|
||||||
|
// kbt_Delete
|
||||||
|
//
|
||||||
|
this.kbt_Delete.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Delete.Location = new System.Drawing.Point(213, 3);
|
||||||
|
this.kbt_Delete.Name = "kbt_Delete";
|
||||||
|
this.kbt_Delete.Size = new System.Drawing.Size(99, 35);
|
||||||
|
this.kbt_Delete.TabIndex = 0;
|
||||||
|
this.kbt_Delete.Values.Text = "删除";
|
||||||
|
this.kbt_Delete.Click += new System.EventHandler(this.kbt_Delete_Click);
|
||||||
|
//
|
||||||
|
// ktb_setRoleMenuPermission
|
||||||
|
//
|
||||||
|
this.ktb_setRoleMenuPermission.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.ktb_setRoleMenuPermission.Location = new System.Drawing.Point(318, 3);
|
||||||
|
this.ktb_setRoleMenuPermission.Name = "ktb_setRoleMenuPermission";
|
||||||
|
this.ktb_setRoleMenuPermission.Size = new System.Drawing.Size(99, 35);
|
||||||
|
this.ktb_setRoleMenuPermission.TabIndex = 0;
|
||||||
|
this.ktb_setRoleMenuPermission.Values.Text = "权限配置";
|
||||||
|
this.ktb_setRoleMenuPermission.Click += new System.EventHandler(this.ktb_setRoleMenuPermission_Click);
|
||||||
|
//
|
||||||
|
// tableLayoutPanel1
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel1.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel1.ColumnCount = 4;
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 120F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 120F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateEndTime, 3, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateStartTime, 1, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel2, 0, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel5, 2, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kcmb_roleGrade, 3, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_roleMsg, 1, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel4, 0, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel3, 2, 0);
|
||||||
|
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||||
|
this.tableLayoutPanel1.RowCount = 2;
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Size = new System.Drawing.Size(798, 72);
|
||||||
|
this.tableLayoutPanel1.TabIndex = 0;
|
||||||
|
//
|
||||||
|
// kdtp_CreateEndTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateEndTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateEndTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateEndTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateEndTime.Location = new System.Drawing.Point(535, 43);
|
||||||
|
this.kdtp_CreateEndTime.Name = "kdtp_CreateEndTime";
|
||||||
|
this.kdtp_CreateEndTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateEndTime.Size = new System.Drawing.Size(246, 21);
|
||||||
|
this.kdtp_CreateEndTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kdtp_CreateStartTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateStartTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateStartTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateStartTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateStartTime.Location = new System.Drawing.Point(136, 43);
|
||||||
|
this.kdtp_CreateStartTime.Name = "kdtp_CreateStartTime";
|
||||||
|
this.kdtp_CreateStartTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateStartTime.Size = new System.Drawing.Size(246, 21);
|
||||||
|
this.kdtp_CreateStartTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kryptonLabel2
|
||||||
|
//
|
||||||
|
this.kryptonLabel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel2.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kryptonLabel2.Name = "kryptonLabel2";
|
||||||
|
this.kryptonLabel2.Size = new System.Drawing.Size(114, 30);
|
||||||
|
this.kryptonLabel2.TabIndex = 4;
|
||||||
|
this.kryptonLabel2.Values.Text = "角色信息:";
|
||||||
|
//
|
||||||
|
// kryptonLabel5
|
||||||
|
//
|
||||||
|
this.kryptonLabel5.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kryptonLabel5.Location = new System.Drawing.Point(447, 44);
|
||||||
|
this.kryptonLabel5.Name = "kryptonLabel5";
|
||||||
|
this.kryptonLabel5.Size = new System.Drawing.Size(23, 20);
|
||||||
|
this.kryptonLabel5.TabIndex = 4;
|
||||||
|
this.kryptonLabel5.Values.Text = "至";
|
||||||
|
//
|
||||||
|
// kcmb_roleGrade
|
||||||
|
//
|
||||||
|
this.kcmb_roleGrade.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kcmb_roleGrade.DropDownWidth = 121;
|
||||||
|
this.kcmb_roleGrade.Items.AddRange(new object[] {
|
||||||
|
"请选择",
|
||||||
|
"管理员",
|
||||||
|
"普通用户"});
|
||||||
|
this.kcmb_roleGrade.Location = new System.Drawing.Point(535, 7);
|
||||||
|
this.kcmb_roleGrade.Name = "kcmb_roleGrade";
|
||||||
|
this.kcmb_roleGrade.Size = new System.Drawing.Size(246, 21);
|
||||||
|
this.kcmb_roleGrade.TabIndex = 6;
|
||||||
|
//
|
||||||
|
// ktb_roleMsg
|
||||||
|
//
|
||||||
|
this.ktb_roleMsg.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_roleMsg.Location = new System.Drawing.Point(136, 6);
|
||||||
|
this.ktb_roleMsg.Name = "ktb_roleMsg";
|
||||||
|
this.ktb_roleMsg.Size = new System.Drawing.Size(246, 23);
|
||||||
|
this.ktb_roleMsg.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// kryptonLabel4
|
||||||
|
//
|
||||||
|
this.kryptonLabel4.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel4.Location = new System.Drawing.Point(3, 39);
|
||||||
|
this.kryptonLabel4.Name = "kryptonLabel4";
|
||||||
|
this.kryptonLabel4.Size = new System.Drawing.Size(114, 30);
|
||||||
|
this.kryptonLabel4.TabIndex = 4;
|
||||||
|
this.kryptonLabel4.Values.Text = "创建时间:";
|
||||||
|
//
|
||||||
|
// kryptonLabel3
|
||||||
|
//
|
||||||
|
this.kryptonLabel3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel3.Location = new System.Drawing.Point(402, 3);
|
||||||
|
this.kryptonLabel3.Name = "kryptonLabel3";
|
||||||
|
this.kryptonLabel3.Size = new System.Drawing.Size(114, 30);
|
||||||
|
this.kryptonLabel3.TabIndex = 4;
|
||||||
|
this.kryptonLabel3.Values.Text = "角色级别:";
|
||||||
|
//
|
||||||
|
// dataGridViewTextBoxColumn2
|
||||||
|
//
|
||||||
|
this.dataGridViewTextBoxColumn2.HeaderText = "报警类别";
|
||||||
|
this.dataGridViewTextBoxColumn2.Name = "dataGridViewTextBoxColumn2";
|
||||||
|
this.dataGridViewTextBoxColumn2.ReadOnly = true;
|
||||||
|
//
|
||||||
|
// dataGridViewTextBoxColumn4
|
||||||
|
//
|
||||||
|
this.dataGridViewTextBoxColumn4.HeaderText = "报警编码";
|
||||||
|
this.dataGridViewTextBoxColumn4.Name = "dataGridViewTextBoxColumn4";
|
||||||
|
this.dataGridViewTextBoxColumn4.ReadOnly = true;
|
||||||
|
//
|
||||||
|
// dataGridViewTextBoxColumn3
|
||||||
|
//
|
||||||
|
this.dataGridViewTextBoxColumn3.HeaderText = "报警名称";
|
||||||
|
this.dataGridViewTextBoxColumn3.Name = "dataGridViewTextBoxColumn3";
|
||||||
|
this.dataGridViewTextBoxColumn3.ReadOnly = true;
|
||||||
|
//
|
||||||
|
// dataGridViewTextBoxColumn1
|
||||||
|
//
|
||||||
|
this.dataGridViewTextBoxColumn1.HeaderText = "报警消息";
|
||||||
|
this.dataGridViewTextBoxColumn1.Name = "dataGridViewTextBoxColumn1";
|
||||||
|
this.dataGridViewTextBoxColumn1.ReadOnly = true;
|
||||||
|
//
|
||||||
|
// frmRole
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.Controls.Add(this.kryptonPanel6);
|
||||||
|
this.Name = "frmRole";
|
||||||
|
this.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.Load += new System.EventHandler(this.frmRole_Load);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel6)).EndInit();
|
||||||
|
this.kryptonPanel6.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox1.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).EndInit();
|
||||||
|
this.kryptonGroupBox1.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox2.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).EndInit();
|
||||||
|
this.kryptonGroupBox2.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel2.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_roleGrade)).EndInit();
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonPanel kryptonPanel6;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridView dataGridView;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox2;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Add;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Reset;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Query;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Edit;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Delete;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton ktb_setRoleMenuPermission;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateEndTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateStartTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel5;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonComboBox kcmb_roleGrade;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_roleMsg;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel4;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel3;
|
||||||
|
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn2;
|
||||||
|
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn4;
|
||||||
|
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn3;
|
||||||
|
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn1;
|
||||||
|
}
|
||||||
|
}
|
||||||
220
CleanMachineHMI/FrmUserControl/Base/frmRole.cs
Normal file
@@ -0,0 +1,220 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.frmChild;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using LeadDataBaseUtility;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
[FormType(EnumFormType.Role)]
|
||||||
|
public partial class frmRole : UserControl
|
||||||
|
{
|
||||||
|
public frmRole()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
_ComboBoxLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode, "KryptonComboBox");
|
||||||
|
_InfoLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
private DataTable _ComboBoxLanguageTextList;
|
||||||
|
private DataTable _InfoLanguageTextList;
|
||||||
|
public delegate void dlgRefreshFrmHost();
|
||||||
|
public static dlgRefreshFrmHost RefreshFrmHost;
|
||||||
|
public void Init()
|
||||||
|
{
|
||||||
|
var sql = $@"SELECT ROLE_ID 序号,ROLE_CODE 角色编码,ROLE_NAME 角色名称,CASE ROLE_GRADE WHEN '100' THEN 'Administrator' ELSE 'User' END 角色级别,CREATE_TIME 创建时间 FROM SYS_ROLE where DEL_FLAG = 0 ";
|
||||||
|
if (!string.IsNullOrEmpty(ktb_roleMsg.Text))
|
||||||
|
{
|
||||||
|
sql += $" And (ROLE_CODE like '%{ktb_roleMsg.Text}%' or ROLE_NAME like '%{ktb_roleMsg.Text}%')";
|
||||||
|
}
|
||||||
|
if (kcmb_roleGrade.SelectedIndex != 0)
|
||||||
|
{
|
||||||
|
if (kcmb_roleGrade.SelectedIndex == 1)
|
||||||
|
{
|
||||||
|
sql += $" AND ROLE_GRADE = '100'";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
sql += $" AND ROLE_GRADE = '1'";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (kdtp_CreateStartTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND CREATE_TIME >= '{kdtp_CreateStartTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
if (kdtp_CreateEndTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND CREATE_TIME <= '{kdtp_CreateEndTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
|
||||||
|
dataGridView.Columns.Clear();
|
||||||
|
dataGridView.DataSource = dt;
|
||||||
|
dataGridView.SetDataViewColumnText(this.Name, GlobalHelper.LanguageCode);
|
||||||
|
|
||||||
|
}
|
||||||
|
private void txt_GotFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.ShowInputPanel();
|
||||||
|
}
|
||||||
|
private void txt_LostFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.HideInputPanel();
|
||||||
|
}
|
||||||
|
private void InitControlEvent()
|
||||||
|
{
|
||||||
|
ktb_roleMsg.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_roleMsg.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
|
||||||
|
}
|
||||||
|
private void frmRole_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
InitControlEvent();
|
||||||
|
this.SetFormControlText(GlobalHelper.LanguageCode);
|
||||||
|
if (GlobalHelper.LanguageCode == "English")
|
||||||
|
{
|
||||||
|
kcmb_roleGrade.Items.Clear();
|
||||||
|
foreach (DataRow item in _ComboBoxLanguageTextList.GetComBoboxItemArr(kcmb_roleGrade.Name, "KryptonComboBox"))
|
||||||
|
{
|
||||||
|
kcmb_roleGrade.Items.Add(item["CONTROL_NAME"].ToString());
|
||||||
|
}
|
||||||
|
kcmb_roleGrade.SelectedIndex = 0;
|
||||||
|
}
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
RefreshFrmHost = new dlgRefreshFrmHost(Init);
|
||||||
|
Init();
|
||||||
|
foreach (Control item in tableLayoutPanel2.Controls)
|
||||||
|
{
|
||||||
|
if (item.Tag == null)
|
||||||
|
{
|
||||||
|
DataRow[] drs = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{this.Name}' AND MENU_PID = '-1'");
|
||||||
|
DataRow[] drs1 = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{item.Name}' AND MENU_PID = '{drs[0]["MENU_ID"]}'");
|
||||||
|
if (drs1.Length > 0)
|
||||||
|
{
|
||||||
|
item.Enabled = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
item.Enabled = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kryptonGroupBox2.Focus();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("加载角色信息界面发生异常", "LoadRoleMsgExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Add_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
frmAddRole frm = new frmAddRole();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Edit_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (dataGridView.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
frmEditRole frm = new frmEditRole();
|
||||||
|
frm.RoleId = dataGridView.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要编辑的角色数据行!", "SelectWantToEditRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Delete_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (dataGridView.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
DialogResult dr = KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("确定要删除所选的角色信息吗?", "DeleteInfo"), "Prompt", MessageBoxButtons.OKCancel, MessageBoxIcon.Question);
|
||||||
|
if (dr == DialogResult.OK)
|
||||||
|
{
|
||||||
|
string UserId = dataGridView.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
string sqlIsExistAdmin = $@"SELECT 1 FROM SYS_ROLE WHERE ROLE_GRADE = '100' AND ROLE_ID = '{UserId}'";
|
||||||
|
DataTable dtIsExistAdmin = LeadDbHelperSQLite.Query(sqlIsExistAdmin).Tables[0];
|
||||||
|
if (dtIsExistAdmin != null && dtIsExistAdmin.Rows.Count > 0)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("管理员角色不允许删除!", "DeleteAdminRoleInfo"));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
string sql = $@"DELETE FROM SYS_ROLE WHERE ROLE_ID = '{UserId}'";
|
||||||
|
int row = LeadDbHelperSQLite.ExecuteSql(sql);
|
||||||
|
if (row > 0)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除角色数据成功!", "DeleteSuccessInfo"));
|
||||||
|
RefreshFrmHost();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除角色数据失败!", "DeleteFailInfo"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要删除的角色数据行!", "SelectWantToDeleteRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除角色数据发生异常", "DeleteRoleDataExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Query_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
Init();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("查询角色信息数据发生异常", "QueryRoleMsgData") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Reset_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
ktb_roleMsg.Text = "";
|
||||||
|
kcmb_roleGrade.SelectedIndex = 0;
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void ktb_setRoleMenuPermission_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (dataGridView.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
frmSetRoleMenuPermission frm = new frmSetRoleMenuPermission();
|
||||||
|
frm.RoleId = dataGridView.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要授权菜单权限的角色数据行!", "SelectWantToPermissionRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
132
CleanMachineHMI/FrmUserControl/Base/frmRole.resx
Normal file
@@ -0,0 +1,132 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn4.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
</root>
|
||||||
358
CleanMachineHMI/FrmUserControl/Base/frmSheetType.Designer.cs
generated
Normal file
@@ -0,0 +1,358 @@
|
|||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
partial class frmSheetType
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 必需的设计器变量。
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清理所有正在使用的资源。
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region 组件设计器生成的代码
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设计器支持所需的方法 - 不要修改
|
||||||
|
/// 使用代码编辑器修改此方法的内容。
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
this.kryptonLabel2 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel5 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.ktb_SheetTypeCode = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kryptonLabel4 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.ktb_SheetTypeName = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kbt_Reset = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Edit = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Delete = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Query = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kdtp_CreateEndTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kdtp_CreateStartTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kbt_Add = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonLabel3 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kryptonGroupBox1 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.dataGridView = new ComponentFactory.Krypton.Toolkit.KryptonDataGridView();
|
||||||
|
this.kryptonGroupBox2 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.kryptonPanel1 = new ComponentFactory.Krypton.Toolkit.KryptonPanel();
|
||||||
|
this.tableLayoutPanel2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox1.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox1.SuspendLayout();
|
||||||
|
this.tableLayoutPanel1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox2.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel1)).BeginInit();
|
||||||
|
this.kryptonPanel1.SuspendLayout();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// kryptonLabel2
|
||||||
|
//
|
||||||
|
this.kryptonLabel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel2.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kryptonLabel2.Name = "kryptonLabel2";
|
||||||
|
this.kryptonLabel2.Size = new System.Drawing.Size(124, 30);
|
||||||
|
this.kryptonLabel2.TabIndex = 4;
|
||||||
|
this.kryptonLabel2.Values.Text = "板材编码:";
|
||||||
|
//
|
||||||
|
// kryptonLabel5
|
||||||
|
//
|
||||||
|
this.kryptonLabel5.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kryptonLabel5.Location = new System.Drawing.Point(452, 44);
|
||||||
|
this.kryptonLabel5.Name = "kryptonLabel5";
|
||||||
|
this.kryptonLabel5.Size = new System.Drawing.Size(23, 20);
|
||||||
|
this.kryptonLabel5.TabIndex = 4;
|
||||||
|
this.kryptonLabel5.Values.Text = "至";
|
||||||
|
//
|
||||||
|
// ktb_SheetTypeCode
|
||||||
|
//
|
||||||
|
this.ktb_SheetTypeCode.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_SheetTypeCode.Location = new System.Drawing.Point(141, 6);
|
||||||
|
this.ktb_SheetTypeCode.Name = "ktb_SheetTypeCode";
|
||||||
|
this.ktb_SheetTypeCode.Size = new System.Drawing.Size(246, 23);
|
||||||
|
this.ktb_SheetTypeCode.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// kryptonLabel4
|
||||||
|
//
|
||||||
|
this.kryptonLabel4.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel4.Location = new System.Drawing.Point(3, 39);
|
||||||
|
this.kryptonLabel4.Name = "kryptonLabel4";
|
||||||
|
this.kryptonLabel4.Size = new System.Drawing.Size(124, 30);
|
||||||
|
this.kryptonLabel4.TabIndex = 4;
|
||||||
|
this.kryptonLabel4.Values.Text = "创建时间:";
|
||||||
|
//
|
||||||
|
// ktb_SheetTypeName
|
||||||
|
//
|
||||||
|
this.ktb_SheetTypeName.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_SheetTypeName.Location = new System.Drawing.Point(540, 6);
|
||||||
|
this.ktb_SheetTypeName.Name = "ktb_SheetTypeName";
|
||||||
|
this.ktb_SheetTypeName.Size = new System.Drawing.Size(246, 23);
|
||||||
|
this.ktb_SheetTypeName.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// kbt_Reset
|
||||||
|
//
|
||||||
|
this.kbt_Reset.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Reset.Location = new System.Drawing.Point(451, 3);
|
||||||
|
this.kbt_Reset.Name = "kbt_Reset";
|
||||||
|
this.kbt_Reset.Size = new System.Drawing.Size(107, 35);
|
||||||
|
this.kbt_Reset.TabIndex = 0;
|
||||||
|
this.kbt_Reset.Tag = "show";
|
||||||
|
this.kbt_Reset.Values.Text = "重置条件";
|
||||||
|
this.kbt_Reset.Click += new System.EventHandler(this.kbt_Reset_Click);
|
||||||
|
//
|
||||||
|
// kbt_Edit
|
||||||
|
//
|
||||||
|
this.kbt_Edit.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Edit.Location = new System.Drawing.Point(115, 3);
|
||||||
|
this.kbt_Edit.Name = "kbt_Edit";
|
||||||
|
this.kbt_Edit.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Edit.TabIndex = 0;
|
||||||
|
this.kbt_Edit.Values.Text = "编辑";
|
||||||
|
this.kbt_Edit.Click += new System.EventHandler(this.kbt_Edit_Click);
|
||||||
|
//
|
||||||
|
// kbt_Delete
|
||||||
|
//
|
||||||
|
this.kbt_Delete.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Delete.Location = new System.Drawing.Point(227, 3);
|
||||||
|
this.kbt_Delete.Name = "kbt_Delete";
|
||||||
|
this.kbt_Delete.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Delete.TabIndex = 0;
|
||||||
|
this.kbt_Delete.Values.Text = "删除";
|
||||||
|
this.kbt_Delete.Click += new System.EventHandler(this.kbt_Delete_Click);
|
||||||
|
//
|
||||||
|
// kbt_Query
|
||||||
|
//
|
||||||
|
this.kbt_Query.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Query.Location = new System.Drawing.Point(339, 3);
|
||||||
|
this.kbt_Query.Name = "kbt_Query";
|
||||||
|
this.kbt_Query.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Query.TabIndex = 0;
|
||||||
|
this.kbt_Query.Tag = "show";
|
||||||
|
this.kbt_Query.Values.Text = "查询";
|
||||||
|
this.kbt_Query.Click += new System.EventHandler(this.kbt_Query_Click);
|
||||||
|
//
|
||||||
|
// kdtp_CreateEndTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateEndTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateEndTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateEndTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateEndTime.Location = new System.Drawing.Point(540, 43);
|
||||||
|
this.kdtp_CreateEndTime.Name = "kdtp_CreateEndTime";
|
||||||
|
this.kdtp_CreateEndTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateEndTime.Size = new System.Drawing.Size(246, 21);
|
||||||
|
this.kdtp_CreateEndTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kdtp_CreateStartTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateStartTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateStartTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateStartTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateStartTime.Location = new System.Drawing.Point(141, 43);
|
||||||
|
this.kdtp_CreateStartTime.Name = "kdtp_CreateStartTime";
|
||||||
|
this.kdtp_CreateStartTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateStartTime.Size = new System.Drawing.Size(246, 21);
|
||||||
|
this.kdtp_CreateStartTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kbt_Add
|
||||||
|
//
|
||||||
|
this.kbt_Add.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Add.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kbt_Add.Name = "kbt_Add";
|
||||||
|
this.kbt_Add.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Add.TabIndex = 0;
|
||||||
|
this.kbt_Add.Values.Text = "新增";
|
||||||
|
this.kbt_Add.Click += new System.EventHandler(this.kbt_Add_Click);
|
||||||
|
//
|
||||||
|
// kryptonLabel3
|
||||||
|
//
|
||||||
|
this.kryptonLabel3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel3.Location = new System.Drawing.Point(402, 3);
|
||||||
|
this.kryptonLabel3.Name = "kryptonLabel3";
|
||||||
|
this.kryptonLabel3.Size = new System.Drawing.Size(124, 30);
|
||||||
|
this.kryptonLabel3.TabIndex = 4;
|
||||||
|
this.kryptonLabel3.Values.Text = "板材名称:";
|
||||||
|
//
|
||||||
|
// tableLayoutPanel2
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.tableLayoutPanel2.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel2.ColumnCount = 5;
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 20F));
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Reset, 4, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Edit, 1, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Delete, 2, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Query, 3, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Add, 0, 0);
|
||||||
|
this.tableLayoutPanel2.Location = new System.Drawing.Point(234, 78);
|
||||||
|
this.tableLayoutPanel2.Name = "tableLayoutPanel2";
|
||||||
|
this.tableLayoutPanel2.RowCount = 1;
|
||||||
|
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||||
|
this.tableLayoutPanel2.Size = new System.Drawing.Size(561, 41);
|
||||||
|
this.tableLayoutPanel2.TabIndex = 4;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.kryptonGroupBox1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonGroupBox1.Name = "kryptonGroupBox1";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.tableLayoutPanel2);
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.tableLayoutPanel1);
|
||||||
|
this.kryptonGroupBox1.Size = new System.Drawing.Size(802, 129);
|
||||||
|
this.kryptonGroupBox1.TabIndex = 0;
|
||||||
|
this.kryptonGroupBox1.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// tableLayoutPanel1
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel1.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel1.ColumnCount = 4;
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 130F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 130F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateEndTime, 3, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateStartTime, 1, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel2, 0, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel5, 2, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_SheetTypeCode, 1, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel4, 0, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel3, 2, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_SheetTypeName, 3, 0);
|
||||||
|
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||||
|
this.tableLayoutPanel1.RowCount = 2;
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Size = new System.Drawing.Size(798, 72);
|
||||||
|
this.tableLayoutPanel1.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// dataGridView
|
||||||
|
//
|
||||||
|
this.dataGridView.AllowUserToAddRows = false;
|
||||||
|
this.dataGridView.AllowUserToDeleteRows = false;
|
||||||
|
this.dataGridView.AllowUserToResizeRows = false;
|
||||||
|
this.dataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
|
||||||
|
this.dataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
|
||||||
|
this.dataGridView.DataMember = "TestData";
|
||||||
|
this.dataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.dataGridView.GridStyles.Style = ComponentFactory.Krypton.Toolkit.DataGridViewStyle.Mixed;
|
||||||
|
this.dataGridView.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.dataGridView.MultiSelect = false;
|
||||||
|
this.dataGridView.Name = "dataGridView";
|
||||||
|
this.dataGridView.ReadOnly = true;
|
||||||
|
this.dataGridView.RowHeadersVisible = false;
|
||||||
|
this.dataGridView.RowHeadersWidth = 100;
|
||||||
|
this.dataGridView.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
|
||||||
|
this.dataGridView.Size = new System.Drawing.Size(798, 458);
|
||||||
|
this.dataGridView.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowOnly;
|
||||||
|
this.kryptonGroupBox2.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox2.CaptionStyle = ComponentFactory.Krypton.Toolkit.LabelStyle.NormalControl;
|
||||||
|
this.kryptonGroupBox2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonGroupBox2.Location = new System.Drawing.Point(0, 129);
|
||||||
|
this.kryptonGroupBox2.Name = "kryptonGroupBox2";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.dataGridView);
|
||||||
|
this.kryptonGroupBox2.Size = new System.Drawing.Size(802, 462);
|
||||||
|
this.kryptonGroupBox2.TabIndex = 5;
|
||||||
|
this.kryptonGroupBox2.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// kryptonPanel1
|
||||||
|
//
|
||||||
|
this.kryptonPanel1.Controls.Add(this.kryptonGroupBox2);
|
||||||
|
this.kryptonPanel1.Controls.Add(this.kryptonGroupBox1);
|
||||||
|
this.kryptonPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonPanel1.Name = "kryptonPanel1";
|
||||||
|
this.kryptonPanel1.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.kryptonPanel1.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// frmSheetType
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.Controls.Add(this.kryptonPanel1);
|
||||||
|
this.Name = "frmSheetType";
|
||||||
|
this.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.Load += new System.EventHandler(this.frmSheetType_Load);
|
||||||
|
this.tableLayoutPanel2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox1.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).EndInit();
|
||||||
|
this.kryptonGroupBox1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox2.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).EndInit();
|
||||||
|
this.kryptonGroupBox2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel1)).EndInit();
|
||||||
|
this.kryptonPanel1.ResumeLayout(false);
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel5;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_SheetTypeCode;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel4;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_SheetTypeName;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Reset;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Edit;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Delete;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Query;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateEndTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateStartTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Add;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel3;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox1;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridView dataGridView;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonPanel kryptonPanel1;
|
||||||
|
}
|
||||||
|
}
|
||||||
195
CleanMachineHMI/FrmUserControl/Base/frmSheetType.cs
Normal file
@@ -0,0 +1,195 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.frmChild;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using LeadDataBaseUtility;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
[FormType(EnumFormType.SheetType)]
|
||||||
|
public partial class frmSheetType : UserControl
|
||||||
|
{
|
||||||
|
public frmSheetType()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
_InfoLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
private DataTable _InfoLanguageTextList;
|
||||||
|
public delegate void dlgRefreshFrmHost();
|
||||||
|
public static dlgRefreshFrmHost RefreshFrmHost;
|
||||||
|
protected override CreateParams CreateParams
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
CreateParams cp = base.CreateParams;
|
||||||
|
cp.ExStyle |= 0x02000000;
|
||||||
|
return cp;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public void Init()
|
||||||
|
{
|
||||||
|
var sql = $@"select SHEET_TYPE_ID 序号,SHEET_TYPE_CODE 板材编码,SHEET_TYPE_NAME 板材名称,CREATE_TIME 创建时间 from BAS_SHEET_TYPE where DEL_FLAG=0";
|
||||||
|
if (!string.IsNullOrEmpty(ktb_SheetTypeCode.Text))
|
||||||
|
{
|
||||||
|
sql += $" AND SHEET_TYPE_CODE LIKE '%{ktb_SheetTypeCode.Text}%'";
|
||||||
|
}
|
||||||
|
if (!string.IsNullOrEmpty(ktb_SheetTypeName.Text))
|
||||||
|
{
|
||||||
|
sql += $" AND SHEET_TYPE_NAME LIKE '%{ktb_SheetTypeName.Text}%'";
|
||||||
|
}
|
||||||
|
if (kdtp_CreateStartTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND CREATE_TIME >= '{kdtp_CreateStartTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
if (kdtp_CreateEndTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND CREATE_TIME <= '{kdtp_CreateEndTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
|
||||||
|
dataGridView.Columns.Clear();
|
||||||
|
dataGridView.DataSource = dt;
|
||||||
|
dataGridView.SetDataViewColumnText(this.Name, GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
private void txt_GotFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.ShowInputPanel();
|
||||||
|
}
|
||||||
|
private void txt_LostFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.HideInputPanel();
|
||||||
|
}
|
||||||
|
private void InitControlEvent()
|
||||||
|
{
|
||||||
|
ktb_SheetTypeCode.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_SheetTypeCode.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
|
||||||
|
ktb_SheetTypeName.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_SheetTypeName.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
}
|
||||||
|
|
||||||
|
private void frmSheetType_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
InitControlEvent();
|
||||||
|
this.SetFormControlText(GlobalHelper.LanguageCode);
|
||||||
|
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
|
||||||
|
RefreshFrmHost = new dlgRefreshFrmHost(Init);
|
||||||
|
Init();
|
||||||
|
foreach (Control item in tableLayoutPanel2.Controls)
|
||||||
|
{
|
||||||
|
if (item.Tag == null)
|
||||||
|
{
|
||||||
|
DataRow[] drs = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{this.Name}' AND MENU_PID = '-1'");
|
||||||
|
DataRow[] drs1 = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{item.Name}' AND MENU_PID = '{drs[0]["MENU_ID"]}'");
|
||||||
|
if (drs1.Length > 0)
|
||||||
|
{
|
||||||
|
item.Enabled = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
item.Enabled = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kryptonGroupBox2.Focus();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("加载板材类型界面发生异常", "LoadSheetTypeExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Query_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
Init();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("查询板材类型数据发生异常", "QuerySheetTypeData") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Reset_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
ktb_SheetTypeCode.Text = "";
|
||||||
|
ktb_SheetTypeName.Text = "";
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Add_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
frmAddSheetType frm = new frmAddSheetType();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Edit_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (dataGridView.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
frmEditSheetType frm = new frmEditSheetType();
|
||||||
|
frm.SheetTypeId = dataGridView.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要编辑的板材类型数据行!", "SelectWantToEditRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Delete_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (dataGridView.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
DialogResult dr = KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("确定要删除所选的板材类型数据吗?", "DeleteInfo"), "Prompt", MessageBoxButtons.OKCancel, MessageBoxIcon.Question);
|
||||||
|
if (dr == DialogResult.OK)
|
||||||
|
{
|
||||||
|
string SheetTypeId = dataGridView.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
string sql = $@"DELETE FROM BAS_SHEET_TYPE WHERE SHEET_TYPE_ID = '{SheetTypeId}'";
|
||||||
|
int row = LeadDbHelperSQLite.ExecuteSql(sql);
|
||||||
|
if (row > 0)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除板材类型数据成功!", "DeleteSuccessInfo"));
|
||||||
|
RefreshFrmHost();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除板材类型数据失败!", "DeleteFailInfo"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要删除的板材类型数据行!", "SelectWantToDeleteRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除污染板材类型数据发生异常", "DeleteSheetTypeDataExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
120
CleanMachineHMI/FrmUserControl/Base/frmSheetType.resx
Normal file
@@ -0,0 +1,120 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
</root>
|
||||||
398
CleanMachineHMI/FrmUserControl/Base/frmUser.Designer.cs
generated
Normal file
@@ -0,0 +1,398 @@
|
|||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
partial class frmUser
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 必需的设计器变量。
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清理所有正在使用的资源。
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region 组件设计器生成的代码
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设计器支持所需的方法 - 不要修改
|
||||||
|
/// 使用代码编辑器修改此方法的内容。
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
|
this.dataGridViewTextBoxColumn3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
|
this.dataGridViewTextBoxColumn4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
|
this.dataGridViewTextBoxColumn2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
|
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kdtp_CreateEndTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kdtp_CreateStartTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kryptonLabel2 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel5 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kcmb_gender = new ComponentFactory.Krypton.Toolkit.KryptonComboBox();
|
||||||
|
this.ktb_userMsg = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kryptonLabel4 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel3 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kbt_Query = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Add = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Reset = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Edit = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kbt_Delete = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonGroupBox2 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.dataGridView = new ComponentFactory.Krypton.Toolkit.KryptonDataGridView();
|
||||||
|
this.kryptonGroupBox1 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.kryptonPanel6 = new ComponentFactory.Krypton.Toolkit.KryptonPanel();
|
||||||
|
this.tableLayoutPanel1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_gender)).BeginInit();
|
||||||
|
this.tableLayoutPanel2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox2.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox1.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel6)).BeginInit();
|
||||||
|
this.kryptonPanel6.SuspendLayout();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// dataGridViewTextBoxColumn1
|
||||||
|
//
|
||||||
|
this.dataGridViewTextBoxColumn1.HeaderText = "报警消息";
|
||||||
|
this.dataGridViewTextBoxColumn1.Name = "dataGridViewTextBoxColumn1";
|
||||||
|
this.dataGridViewTextBoxColumn1.ReadOnly = true;
|
||||||
|
//
|
||||||
|
// dataGridViewTextBoxColumn3
|
||||||
|
//
|
||||||
|
this.dataGridViewTextBoxColumn3.HeaderText = "报警名称";
|
||||||
|
this.dataGridViewTextBoxColumn3.Name = "dataGridViewTextBoxColumn3";
|
||||||
|
this.dataGridViewTextBoxColumn3.ReadOnly = true;
|
||||||
|
//
|
||||||
|
// dataGridViewTextBoxColumn4
|
||||||
|
//
|
||||||
|
this.dataGridViewTextBoxColumn4.HeaderText = "报警编码";
|
||||||
|
this.dataGridViewTextBoxColumn4.Name = "dataGridViewTextBoxColumn4";
|
||||||
|
this.dataGridViewTextBoxColumn4.ReadOnly = true;
|
||||||
|
//
|
||||||
|
// dataGridViewTextBoxColumn2
|
||||||
|
//
|
||||||
|
this.dataGridViewTextBoxColumn2.HeaderText = "报警类别";
|
||||||
|
this.dataGridViewTextBoxColumn2.Name = "dataGridViewTextBoxColumn2";
|
||||||
|
this.dataGridViewTextBoxColumn2.ReadOnly = true;
|
||||||
|
//
|
||||||
|
// tableLayoutPanel1
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel1.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel1.ColumnCount = 4;
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 120F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 60F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateEndTime, 3, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateStartTime, 1, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel2, 0, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel5, 2, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kcmb_gender, 3, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_userMsg, 1, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel4, 0, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel3, 2, 0);
|
||||||
|
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||||
|
this.tableLayoutPanel1.RowCount = 2;
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Size = new System.Drawing.Size(798, 72);
|
||||||
|
this.tableLayoutPanel1.TabIndex = 0;
|
||||||
|
//
|
||||||
|
// kdtp_CreateEndTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateEndTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateEndTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateEndTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateEndTime.Location = new System.Drawing.Point(520, 43);
|
||||||
|
this.kdtp_CreateEndTime.Name = "kdtp_CreateEndTime";
|
||||||
|
this.kdtp_CreateEndTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateEndTime.Size = new System.Drawing.Size(246, 21);
|
||||||
|
this.kdtp_CreateEndTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kdtp_CreateStartTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateStartTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateStartTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateStartTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateStartTime.Location = new System.Drawing.Point(151, 43);
|
||||||
|
this.kdtp_CreateStartTime.Name = "kdtp_CreateStartTime";
|
||||||
|
this.kdtp_CreateStartTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateStartTime.Size = new System.Drawing.Size(246, 21);
|
||||||
|
this.kdtp_CreateStartTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kryptonLabel2
|
||||||
|
//
|
||||||
|
this.kryptonLabel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel2.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kryptonLabel2.Name = "kryptonLabel2";
|
||||||
|
this.kryptonLabel2.Size = new System.Drawing.Size(114, 30);
|
||||||
|
this.kryptonLabel2.TabIndex = 4;
|
||||||
|
this.kryptonLabel2.Values.Text = "用户信息:";
|
||||||
|
//
|
||||||
|
// kryptonLabel5
|
||||||
|
//
|
||||||
|
this.kryptonLabel5.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kryptonLabel5.Location = new System.Drawing.Point(447, 44);
|
||||||
|
this.kryptonLabel5.Name = "kryptonLabel5";
|
||||||
|
this.kryptonLabel5.Size = new System.Drawing.Size(23, 20);
|
||||||
|
this.kryptonLabel5.TabIndex = 4;
|
||||||
|
this.kryptonLabel5.Values.Text = "至";
|
||||||
|
//
|
||||||
|
// kcmb_gender
|
||||||
|
//
|
||||||
|
this.kcmb_gender.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kcmb_gender.DropDownWidth = 121;
|
||||||
|
this.kcmb_gender.Items.AddRange(new object[] {
|
||||||
|
"请选择",
|
||||||
|
"男",
|
||||||
|
"女"});
|
||||||
|
this.kcmb_gender.Location = new System.Drawing.Point(520, 7);
|
||||||
|
this.kcmb_gender.Name = "kcmb_gender";
|
||||||
|
this.kcmb_gender.Size = new System.Drawing.Size(246, 21);
|
||||||
|
this.kcmb_gender.TabIndex = 6;
|
||||||
|
//
|
||||||
|
// ktb_userMsg
|
||||||
|
//
|
||||||
|
this.ktb_userMsg.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_userMsg.Location = new System.Drawing.Point(151, 6);
|
||||||
|
this.ktb_userMsg.Name = "ktb_userMsg";
|
||||||
|
this.ktb_userMsg.Size = new System.Drawing.Size(246, 23);
|
||||||
|
this.ktb_userMsg.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// kryptonLabel4
|
||||||
|
//
|
||||||
|
this.kryptonLabel4.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel4.Location = new System.Drawing.Point(3, 39);
|
||||||
|
this.kryptonLabel4.Name = "kryptonLabel4";
|
||||||
|
this.kryptonLabel4.Size = new System.Drawing.Size(114, 30);
|
||||||
|
this.kryptonLabel4.TabIndex = 4;
|
||||||
|
this.kryptonLabel4.Values.Text = "创建时间:";
|
||||||
|
//
|
||||||
|
// kryptonLabel3
|
||||||
|
//
|
||||||
|
this.kryptonLabel3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel3.Location = new System.Drawing.Point(432, 3);
|
||||||
|
this.kryptonLabel3.Name = "kryptonLabel3";
|
||||||
|
this.kryptonLabel3.Size = new System.Drawing.Size(54, 30);
|
||||||
|
this.kryptonLabel3.TabIndex = 4;
|
||||||
|
this.kryptonLabel3.Values.Text = "性别:";
|
||||||
|
//
|
||||||
|
// kbt_Query
|
||||||
|
//
|
||||||
|
this.kbt_Query.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Query.Location = new System.Drawing.Point(339, 3);
|
||||||
|
this.kbt_Query.Name = "kbt_Query";
|
||||||
|
this.kbt_Query.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Query.TabIndex = 0;
|
||||||
|
this.kbt_Query.Tag = "show";
|
||||||
|
this.kbt_Query.Values.Text = "查询";
|
||||||
|
this.kbt_Query.Click += new System.EventHandler(this.kbt_Query_Click);
|
||||||
|
//
|
||||||
|
// kbt_Add
|
||||||
|
//
|
||||||
|
this.kbt_Add.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Add.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kbt_Add.Name = "kbt_Add";
|
||||||
|
this.kbt_Add.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Add.TabIndex = 0;
|
||||||
|
this.kbt_Add.Values.Text = "新增";
|
||||||
|
this.kbt_Add.Click += new System.EventHandler(this.kbt_Add_Click);
|
||||||
|
//
|
||||||
|
// kbt_Reset
|
||||||
|
//
|
||||||
|
this.kbt_Reset.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Reset.Location = new System.Drawing.Point(451, 3);
|
||||||
|
this.kbt_Reset.Name = "kbt_Reset";
|
||||||
|
this.kbt_Reset.Size = new System.Drawing.Size(107, 35);
|
||||||
|
this.kbt_Reset.TabIndex = 0;
|
||||||
|
this.kbt_Reset.Tag = "show";
|
||||||
|
this.kbt_Reset.Values.Text = "重置条件";
|
||||||
|
this.kbt_Reset.Click += new System.EventHandler(this.kbt_Reset_Click);
|
||||||
|
//
|
||||||
|
// kbt_Edit
|
||||||
|
//
|
||||||
|
this.kbt_Edit.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Edit.Location = new System.Drawing.Point(115, 3);
|
||||||
|
this.kbt_Edit.Name = "kbt_Edit";
|
||||||
|
this.kbt_Edit.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Edit.TabIndex = 0;
|
||||||
|
this.kbt_Edit.Values.Text = "编辑";
|
||||||
|
this.kbt_Edit.Click += new System.EventHandler(this.kbt_Edit_Click);
|
||||||
|
//
|
||||||
|
// tableLayoutPanel2
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.tableLayoutPanel2.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel2.ColumnCount = 5;
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 20F));
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Reset, 4, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Edit, 1, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Delete, 2, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Query, 3, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Add, 0, 0);
|
||||||
|
this.tableLayoutPanel2.Location = new System.Drawing.Point(234, 78);
|
||||||
|
this.tableLayoutPanel2.Name = "tableLayoutPanel2";
|
||||||
|
this.tableLayoutPanel2.RowCount = 1;
|
||||||
|
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||||
|
this.tableLayoutPanel2.Size = new System.Drawing.Size(561, 41);
|
||||||
|
this.tableLayoutPanel2.TabIndex = 2;
|
||||||
|
//
|
||||||
|
// kbt_Delete
|
||||||
|
//
|
||||||
|
this.kbt_Delete.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Delete.Location = new System.Drawing.Point(227, 3);
|
||||||
|
this.kbt_Delete.Name = "kbt_Delete";
|
||||||
|
this.kbt_Delete.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Delete.TabIndex = 0;
|
||||||
|
this.kbt_Delete.Values.Text = "删除";
|
||||||
|
this.kbt_Delete.Click += new System.EventHandler(this.kbt_Delete_Click);
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.kryptonGroupBox2.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonGroupBox2.Name = "kryptonGroupBox2";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.tableLayoutPanel2);
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.tableLayoutPanel1);
|
||||||
|
this.kryptonGroupBox2.Size = new System.Drawing.Size(802, 129);
|
||||||
|
this.kryptonGroupBox2.TabIndex = 0;
|
||||||
|
this.kryptonGroupBox2.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// dataGridView
|
||||||
|
//
|
||||||
|
this.dataGridView.AllowUserToAddRows = false;
|
||||||
|
this.dataGridView.AllowUserToDeleteRows = false;
|
||||||
|
this.dataGridView.AllowUserToResizeRows = false;
|
||||||
|
this.dataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
|
||||||
|
this.dataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
|
||||||
|
this.dataGridView.DataMember = "TestData";
|
||||||
|
this.dataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.dataGridView.GridStyles.Style = ComponentFactory.Krypton.Toolkit.DataGridViewStyle.Mixed;
|
||||||
|
this.dataGridView.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.dataGridView.MultiSelect = false;
|
||||||
|
this.dataGridView.Name = "dataGridView";
|
||||||
|
this.dataGridView.ReadOnly = true;
|
||||||
|
this.dataGridView.RowHeadersVisible = false;
|
||||||
|
this.dataGridView.RowHeadersWidth = 100;
|
||||||
|
this.dataGridView.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
|
||||||
|
this.dataGridView.Size = new System.Drawing.Size(798, 458);
|
||||||
|
this.dataGridView.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowOnly;
|
||||||
|
this.kryptonGroupBox1.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox1.CaptionStyle = ComponentFactory.Krypton.Toolkit.LabelStyle.NormalControl;
|
||||||
|
this.kryptonGroupBox1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonGroupBox1.Location = new System.Drawing.Point(0, 129);
|
||||||
|
this.kryptonGroupBox1.Name = "kryptonGroupBox1";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.dataGridView);
|
||||||
|
this.kryptonGroupBox1.Size = new System.Drawing.Size(802, 462);
|
||||||
|
this.kryptonGroupBox1.TabIndex = 4;
|
||||||
|
this.kryptonGroupBox1.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// kryptonPanel6
|
||||||
|
//
|
||||||
|
this.kryptonPanel6.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
|
||||||
|
this.kryptonPanel6.Controls.Add(this.kryptonGroupBox1);
|
||||||
|
this.kryptonPanel6.Controls.Add(this.kryptonGroupBox2);
|
||||||
|
this.kryptonPanel6.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonPanel6.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonPanel6.Name = "kryptonPanel6";
|
||||||
|
this.kryptonPanel6.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.kryptonPanel6.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// frmUser
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.Controls.Add(this.kryptonPanel6);
|
||||||
|
this.Name = "frmUser";
|
||||||
|
this.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.Load += new System.EventHandler(this.frmUser_Load);
|
||||||
|
this.tableLayoutPanel1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_gender)).EndInit();
|
||||||
|
this.tableLayoutPanel2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox2.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).EndInit();
|
||||||
|
this.kryptonGroupBox2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox1.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).EndInit();
|
||||||
|
this.kryptonGroupBox1.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel6)).EndInit();
|
||||||
|
this.kryptonPanel6.ResumeLayout(false);
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn1;
|
||||||
|
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn3;
|
||||||
|
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn4;
|
||||||
|
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn2;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateEndTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateStartTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel5;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonComboBox kcmb_gender;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_userMsg;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel4;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel3;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Query;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Add;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Reset;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Edit;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Delete;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridView dataGridView;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonPanel kryptonPanel6;
|
||||||
|
}
|
||||||
|
}
|
||||||
200
CleanMachineHMI/FrmUserControl/Base/frmUser.cs
Normal file
@@ -0,0 +1,200 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.frmChild;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using LeadDataBaseUtility;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
[FormType(EnumFormType.User)]
|
||||||
|
public partial class frmUser : UserControl
|
||||||
|
{
|
||||||
|
public frmUser()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
_ComboBoxLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode, "KryptonComboBox");
|
||||||
|
_InfoLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
private DataTable _ComboBoxLanguageTextList;
|
||||||
|
private DataTable _InfoLanguageTextList;
|
||||||
|
public delegate void dlgRefreshFrmHost();
|
||||||
|
public static dlgRefreshFrmHost RefreshFrmHost;
|
||||||
|
|
||||||
|
public void Init()
|
||||||
|
{
|
||||||
|
var sql = $@"select USER_ID 序号,USER_CODE 用户编码,USER_NAME 用户名称,PASSWORD 密码,CASE GENDER WHEN 1 THEN 'man' ELSE 'woman' END 性别,CREATE_TIME 创建时间 from SYS_USER where DEL_FLAG = 0 ";
|
||||||
|
if (!string.IsNullOrEmpty(ktb_userMsg.Text))
|
||||||
|
{
|
||||||
|
sql += $" And (USER_CODE like '%{ktb_userMsg.Text}%' or USER_NAME like '%{ktb_userMsg.Text}%')";
|
||||||
|
}
|
||||||
|
if (kcmb_gender.SelectedIndex != 0)
|
||||||
|
{
|
||||||
|
sql += $" AND GENDER = '{kcmb_gender.SelectedIndex}'";
|
||||||
|
}
|
||||||
|
if (kdtp_CreateStartTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND CREATE_TIME >= '{kdtp_CreateStartTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
if (kdtp_CreateEndTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND CREATE_TIME <= '{kdtp_CreateEndTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
if (GlobalHelper.UserInfo.ROLE_GRADE != 100)
|
||||||
|
{
|
||||||
|
sql += $" AND USER_ID = '{GlobalHelper.UserInfo.USER_ID}'";
|
||||||
|
}
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
|
||||||
|
dataGridView.Columns.Clear();
|
||||||
|
dataGridView.DataSource = dt;
|
||||||
|
dataGridView.SetDataViewColumnText(this.Name, GlobalHelper.LanguageCode);
|
||||||
|
|
||||||
|
}
|
||||||
|
private void txt_GotFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.ShowInputPanel();
|
||||||
|
}
|
||||||
|
private void txt_LostFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.HideInputPanel();
|
||||||
|
}
|
||||||
|
private void InitControlEvent()
|
||||||
|
{
|
||||||
|
ktb_userMsg.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_userMsg.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void frmUser_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
InitControlEvent();
|
||||||
|
this.SetFormControlText(GlobalHelper.LanguageCode);
|
||||||
|
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
|
||||||
|
if (GlobalHelper.LanguageCode == "English")
|
||||||
|
{
|
||||||
|
kcmb_gender.Items.Clear();
|
||||||
|
foreach (DataRow item in _ComboBoxLanguageTextList.GetComBoboxItemArr(kcmb_gender.Name, "KryptonComboBox"))
|
||||||
|
{
|
||||||
|
kcmb_gender.Items.Add(item["CONTROL_NAME"].ToString());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kcmb_gender.SelectedIndex = 0;
|
||||||
|
RefreshFrmHost = new dlgRefreshFrmHost(Init);
|
||||||
|
Init();
|
||||||
|
foreach (Control item in tableLayoutPanel2.Controls)
|
||||||
|
{
|
||||||
|
if (item.Tag == null)
|
||||||
|
{
|
||||||
|
DataRow[] drs = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{this.Name}' AND MENU_PID = '-1'");
|
||||||
|
DataRow[] drs1 = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{item.Name}' AND MENU_PID = '{drs[0]["MENU_ID"]}'");
|
||||||
|
if (drs1.Length > 0)
|
||||||
|
{
|
||||||
|
item.Enabled = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
item.Enabled = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kryptonGroupBox2.Focus();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("加载用户信息界面发生异常", "LoadUserMsgExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Query_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
Init();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("查询用户信息数据发生异常", "QueryUserMsgData") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Reset_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
ktb_userMsg.Text = "";
|
||||||
|
kcmb_gender.SelectedIndex = 0;
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Add_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
frmAddUser frm = new frmAddUser();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Edit_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (dataGridView.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
frmEditUser frm = new frmEditUser();
|
||||||
|
frm.UserId = dataGridView.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要编辑的用户信息数据行!", "SelectWantToEditRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Delete_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (dataGridView.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
DialogResult dr = KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("确定要删除所选的用户信息吗?", "DeleteInfo"), "Prompt", MessageBoxButtons.OKCancel, MessageBoxIcon.Question);
|
||||||
|
if (dr == DialogResult.OK)
|
||||||
|
{
|
||||||
|
string UserId = dataGridView.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
string sql = $@"DELETE FROM SYS_USER WHERE USER_ID = '{UserId}'";
|
||||||
|
int row = LeadDbHelperSQLite.ExecuteSql(sql);
|
||||||
|
if (row > 0)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除用户数据成功!", "DeleteSuccessInfo"));
|
||||||
|
RefreshFrmHost();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除用户数据失败!", "DeleteFailInfo"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要删除的用户数据行!", "SelectWantToDeleteRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除用户信息数据发生异常", "DeleteUserMsgDataExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
132
CleanMachineHMI/FrmUserControl/Base/frmUser.resx
Normal file
@@ -0,0 +1,132 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn4.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
</root>
|
||||||
397
CleanMachineHMI/FrmUserControl/Base/frmWarning.Designer.cs
generated
Normal file
@@ -0,0 +1,397 @@
|
|||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
partial class frmWarning
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 必需的设计器变量。
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清理所有正在使用的资源。
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region 组件设计器生成的代码
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设计器支持所需的方法 - 不要修改
|
||||||
|
/// 使用代码编辑器修改此方法的内容。
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
this.dataGridView = new ComponentFactory.Krypton.Toolkit.KryptonDataGridView();
|
||||||
|
this.kryptonPanel6 = new ComponentFactory.Krypton.Toolkit.KryptonPanel();
|
||||||
|
this.kryptonGroupBox1 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.kryptonGroupBox2 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kbt_Reset = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Edit = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Delete = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Query = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Add = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kdtp_CreateEndTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kdtp_CreateStartTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kryptonLabel2 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel5 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.ktb_WarningMsg = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kryptonLabel4 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel3 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kcmb_WarningType = new ComponentFactory.Krypton.Toolkit.KryptonComboBox();
|
||||||
|
this.dataGridViewTextBoxColumn4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
|
this.dataGridViewTextBoxColumn3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
|
this.dataGridViewTextBoxColumn2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
|
this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel6)).BeginInit();
|
||||||
|
this.kryptonPanel6.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox1.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox2.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox2.SuspendLayout();
|
||||||
|
this.tableLayoutPanel2.SuspendLayout();
|
||||||
|
this.tableLayoutPanel1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_WarningType)).BeginInit();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// dataGridView
|
||||||
|
//
|
||||||
|
this.dataGridView.AllowUserToAddRows = false;
|
||||||
|
this.dataGridView.AllowUserToDeleteRows = false;
|
||||||
|
this.dataGridView.AllowUserToResizeRows = false;
|
||||||
|
this.dataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.AllCells;
|
||||||
|
this.dataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
|
||||||
|
this.dataGridView.DataMember = "TestData";
|
||||||
|
this.dataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.dataGridView.GridStyles.Style = ComponentFactory.Krypton.Toolkit.DataGridViewStyle.Mixed;
|
||||||
|
this.dataGridView.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.dataGridView.MultiSelect = false;
|
||||||
|
this.dataGridView.Name = "dataGridView";
|
||||||
|
this.dataGridView.ReadOnly = true;
|
||||||
|
this.dataGridView.RowHeadersVisible = false;
|
||||||
|
this.dataGridView.RowHeadersWidth = 100;
|
||||||
|
this.dataGridView.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
|
||||||
|
this.dataGridView.Size = new System.Drawing.Size(798, 459);
|
||||||
|
this.dataGridView.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// kryptonPanel6
|
||||||
|
//
|
||||||
|
this.kryptonPanel6.Controls.Add(this.kryptonGroupBox1);
|
||||||
|
this.kryptonPanel6.Controls.Add(this.kryptonGroupBox2);
|
||||||
|
this.kryptonPanel6.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonPanel6.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonPanel6.Name = "kryptonPanel6";
|
||||||
|
this.kryptonPanel6.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.kryptonPanel6.TabIndex = 4;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowOnly;
|
||||||
|
this.kryptonGroupBox1.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox1.CaptionStyle = ComponentFactory.Krypton.Toolkit.LabelStyle.NormalControl;
|
||||||
|
this.kryptonGroupBox1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonGroupBox1.Location = new System.Drawing.Point(0, 128);
|
||||||
|
this.kryptonGroupBox1.Name = "kryptonGroupBox1";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.dataGridView);
|
||||||
|
this.kryptonGroupBox1.Size = new System.Drawing.Size(802, 463);
|
||||||
|
this.kryptonGroupBox1.TabIndex = 7;
|
||||||
|
this.kryptonGroupBox1.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.kryptonGroupBox2.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonGroupBox2.Name = "kryptonGroupBox2";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.tableLayoutPanel2);
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.tableLayoutPanel1);
|
||||||
|
this.kryptonGroupBox2.Size = new System.Drawing.Size(802, 128);
|
||||||
|
this.kryptonGroupBox2.TabIndex = 0;
|
||||||
|
this.kryptonGroupBox2.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// tableLayoutPanel2
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.tableLayoutPanel2.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel2.ColumnCount = 5;
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 20F));
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Reset, 4, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Edit, 1, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Delete, 2, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Query, 3, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Add, 0, 0);
|
||||||
|
this.tableLayoutPanel2.Location = new System.Drawing.Point(234, 77);
|
||||||
|
this.tableLayoutPanel2.Name = "tableLayoutPanel2";
|
||||||
|
this.tableLayoutPanel2.RowCount = 1;
|
||||||
|
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||||
|
this.tableLayoutPanel2.Size = new System.Drawing.Size(561, 41);
|
||||||
|
this.tableLayoutPanel2.TabIndex = 6;
|
||||||
|
//
|
||||||
|
// kbt_Reset
|
||||||
|
//
|
||||||
|
this.kbt_Reset.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Reset.Location = new System.Drawing.Point(451, 3);
|
||||||
|
this.kbt_Reset.Name = "kbt_Reset";
|
||||||
|
this.kbt_Reset.Size = new System.Drawing.Size(107, 35);
|
||||||
|
this.kbt_Reset.TabIndex = 0;
|
||||||
|
this.kbt_Reset.Tag = "show";
|
||||||
|
this.kbt_Reset.Values.Text = "重置条件";
|
||||||
|
this.kbt_Reset.Click += new System.EventHandler(this.kbt_Reset_Click);
|
||||||
|
//
|
||||||
|
// kbt_Edit
|
||||||
|
//
|
||||||
|
this.kbt_Edit.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Edit.Location = new System.Drawing.Point(115, 3);
|
||||||
|
this.kbt_Edit.Name = "kbt_Edit";
|
||||||
|
this.kbt_Edit.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Edit.TabIndex = 0;
|
||||||
|
this.kbt_Edit.Values.Text = "编辑";
|
||||||
|
this.kbt_Edit.Click += new System.EventHandler(this.kbt_Edit_Click);
|
||||||
|
//
|
||||||
|
// kbt_Delete
|
||||||
|
//
|
||||||
|
this.kbt_Delete.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Delete.Location = new System.Drawing.Point(227, 3);
|
||||||
|
this.kbt_Delete.Name = "kbt_Delete";
|
||||||
|
this.kbt_Delete.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Delete.TabIndex = 0;
|
||||||
|
this.kbt_Delete.Values.Text = "删除";
|
||||||
|
this.kbt_Delete.Click += new System.EventHandler(this.kbt_Delete_Click);
|
||||||
|
//
|
||||||
|
// kbt_Query
|
||||||
|
//
|
||||||
|
this.kbt_Query.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Query.Location = new System.Drawing.Point(339, 3);
|
||||||
|
this.kbt_Query.Name = "kbt_Query";
|
||||||
|
this.kbt_Query.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Query.TabIndex = 0;
|
||||||
|
this.kbt_Query.Tag = "show";
|
||||||
|
this.kbt_Query.Values.Text = "查询";
|
||||||
|
this.kbt_Query.Click += new System.EventHandler(this.kbt_Query_Click);
|
||||||
|
//
|
||||||
|
// kbt_Add
|
||||||
|
//
|
||||||
|
this.kbt_Add.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Add.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kbt_Add.Name = "kbt_Add";
|
||||||
|
this.kbt_Add.Size = new System.Drawing.Size(106, 35);
|
||||||
|
this.kbt_Add.TabIndex = 0;
|
||||||
|
this.kbt_Add.Values.Text = "新增";
|
||||||
|
this.kbt_Add.Click += new System.EventHandler(this.kbt_Add_Click);
|
||||||
|
//
|
||||||
|
// tableLayoutPanel1
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel1.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel1.ColumnCount = 4;
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 120F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 100F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateEndTime, 3, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateStartTime, 1, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel2, 0, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel5, 2, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_WarningMsg, 1, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel4, 0, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel3, 2, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kcmb_WarningType, 3, 0);
|
||||||
|
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||||
|
this.tableLayoutPanel1.RowCount = 2;
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Size = new System.Drawing.Size(798, 72);
|
||||||
|
this.tableLayoutPanel1.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// kdtp_CreateEndTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateEndTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateEndTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateEndTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateEndTime.Location = new System.Drawing.Point(530, 43);
|
||||||
|
this.kdtp_CreateEndTime.Name = "kdtp_CreateEndTime";
|
||||||
|
this.kdtp_CreateEndTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateEndTime.Size = new System.Drawing.Size(246, 21);
|
||||||
|
this.kdtp_CreateEndTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kdtp_CreateStartTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateStartTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateStartTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateStartTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateStartTime.Location = new System.Drawing.Point(141, 43);
|
||||||
|
this.kdtp_CreateStartTime.Name = "kdtp_CreateStartTime";
|
||||||
|
this.kdtp_CreateStartTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateStartTime.Size = new System.Drawing.Size(246, 21);
|
||||||
|
this.kdtp_CreateStartTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kryptonLabel2
|
||||||
|
//
|
||||||
|
this.kryptonLabel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel2.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kryptonLabel2.Name = "kryptonLabel2";
|
||||||
|
this.kryptonLabel2.Size = new System.Drawing.Size(114, 30);
|
||||||
|
this.kryptonLabel2.TabIndex = 4;
|
||||||
|
this.kryptonLabel2.Values.Text = "报警信息:";
|
||||||
|
//
|
||||||
|
// kryptonLabel5
|
||||||
|
//
|
||||||
|
this.kryptonLabel5.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kryptonLabel5.Location = new System.Drawing.Point(447, 44);
|
||||||
|
this.kryptonLabel5.Name = "kryptonLabel5";
|
||||||
|
this.kryptonLabel5.Size = new System.Drawing.Size(23, 20);
|
||||||
|
this.kryptonLabel5.TabIndex = 4;
|
||||||
|
this.kryptonLabel5.Values.Text = "至";
|
||||||
|
//
|
||||||
|
// ktb_WarningMsg
|
||||||
|
//
|
||||||
|
this.ktb_WarningMsg.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_WarningMsg.Location = new System.Drawing.Point(141, 6);
|
||||||
|
this.ktb_WarningMsg.Name = "ktb_WarningMsg";
|
||||||
|
this.ktb_WarningMsg.Size = new System.Drawing.Size(246, 23);
|
||||||
|
this.ktb_WarningMsg.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// kryptonLabel4
|
||||||
|
//
|
||||||
|
this.kryptonLabel4.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel4.Location = new System.Drawing.Point(3, 39);
|
||||||
|
this.kryptonLabel4.Name = "kryptonLabel4";
|
||||||
|
this.kryptonLabel4.Size = new System.Drawing.Size(114, 30);
|
||||||
|
this.kryptonLabel4.TabIndex = 4;
|
||||||
|
this.kryptonLabel4.Values.Text = "创建时间:";
|
||||||
|
//
|
||||||
|
// kryptonLabel3
|
||||||
|
//
|
||||||
|
this.kryptonLabel3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel3.Location = new System.Drawing.Point(412, 3);
|
||||||
|
this.kryptonLabel3.Name = "kryptonLabel3";
|
||||||
|
this.kryptonLabel3.Size = new System.Drawing.Size(94, 30);
|
||||||
|
this.kryptonLabel3.TabIndex = 4;
|
||||||
|
this.kryptonLabel3.Values.Text = "报警类型:";
|
||||||
|
//
|
||||||
|
// kcmb_WarningType
|
||||||
|
//
|
||||||
|
this.kcmb_WarningType.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kcmb_WarningType.DropDownWidth = 246;
|
||||||
|
this.kcmb_WarningType.Items.AddRange(new object[] {
|
||||||
|
"请选择",
|
||||||
|
"清洁机报警",
|
||||||
|
"变频器报警"});
|
||||||
|
this.kcmb_WarningType.Location = new System.Drawing.Point(530, 7);
|
||||||
|
this.kcmb_WarningType.Name = "kcmb_WarningType";
|
||||||
|
this.kcmb_WarningType.Size = new System.Drawing.Size(246, 21);
|
||||||
|
this.kcmb_WarningType.TabIndex = 8;
|
||||||
|
//
|
||||||
|
// dataGridViewTextBoxColumn4
|
||||||
|
//
|
||||||
|
this.dataGridViewTextBoxColumn4.HeaderText = "报警编码";
|
||||||
|
this.dataGridViewTextBoxColumn4.Name = "dataGridViewTextBoxColumn4";
|
||||||
|
this.dataGridViewTextBoxColumn4.ReadOnly = true;
|
||||||
|
//
|
||||||
|
// dataGridViewTextBoxColumn3
|
||||||
|
//
|
||||||
|
this.dataGridViewTextBoxColumn3.HeaderText = "报警名称";
|
||||||
|
this.dataGridViewTextBoxColumn3.Name = "dataGridViewTextBoxColumn3";
|
||||||
|
this.dataGridViewTextBoxColumn3.ReadOnly = true;
|
||||||
|
//
|
||||||
|
// dataGridViewTextBoxColumn2
|
||||||
|
//
|
||||||
|
this.dataGridViewTextBoxColumn2.HeaderText = "报警类别";
|
||||||
|
this.dataGridViewTextBoxColumn2.Name = "dataGridViewTextBoxColumn2";
|
||||||
|
this.dataGridViewTextBoxColumn2.ReadOnly = true;
|
||||||
|
//
|
||||||
|
// dataGridViewTextBoxColumn1
|
||||||
|
//
|
||||||
|
this.dataGridViewTextBoxColumn1.HeaderText = "报警消息";
|
||||||
|
this.dataGridViewTextBoxColumn1.Name = "dataGridViewTextBoxColumn1";
|
||||||
|
this.dataGridViewTextBoxColumn1.ReadOnly = true;
|
||||||
|
//
|
||||||
|
// frmWarning
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.Controls.Add(this.kryptonPanel6);
|
||||||
|
this.Name = "frmWarning";
|
||||||
|
this.Size = new System.Drawing.Size(802, 591);
|
||||||
|
this.Load += new System.EventHandler(this.frmWarning_Load);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel6)).EndInit();
|
||||||
|
this.kryptonPanel6.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox1.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).EndInit();
|
||||||
|
this.kryptonGroupBox1.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox2.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).EndInit();
|
||||||
|
this.kryptonGroupBox2.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel2.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_WarningType)).EndInit();
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridView dataGridView;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonPanel kryptonPanel6;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox2;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Reset;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Edit;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Delete;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Query;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Add;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateEndTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateStartTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel5;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_WarningMsg;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel4;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel3;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonComboBox kcmb_WarningType;
|
||||||
|
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn4;
|
||||||
|
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn3;
|
||||||
|
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn2;
|
||||||
|
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn1;
|
||||||
|
}
|
||||||
|
}
|
||||||
208
CleanMachineHMI/FrmUserControl/Base/frmWarning.cs
Normal file
@@ -0,0 +1,208 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.frmChild;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using LeadDataBaseUtility;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
[FormType(EnumFormType.Warning)]
|
||||||
|
public partial class frmWarning : UserControl
|
||||||
|
{
|
||||||
|
public delegate void dlgRefreshFrmHost();
|
||||||
|
public static dlgRefreshFrmHost RefreshFrmHost;
|
||||||
|
|
||||||
|
public frmWarning()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
_ComboBoxLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode, "KryptonComboBox");
|
||||||
|
_InfoLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
private DataTable _ComboBoxLanguageTextList;
|
||||||
|
private DataTable _InfoLanguageTextList;
|
||||||
|
public void Init()
|
||||||
|
{
|
||||||
|
var sql = $@"select WARNING_ID 序号,WARNING_CODE 报警编码,WARNING_NAME 报警名称,PLC_ITEM_CODE 'PLC信息',CASE WARNING_TYPE WHEN '1' THEN 'Cleaning machine alarm' ELSE 'Frequency converter alarm' END '报警类型',WARNING_MESSAGE 报警描述,CREATE_TIME 创建时间 from BAS_WARNING where DEL_FLAG=0";
|
||||||
|
if (!string.IsNullOrEmpty(ktb_WarningMsg.Text))
|
||||||
|
{
|
||||||
|
sql += $" AND (WARNING_CODE like '%{ktb_WarningMsg.Text}%' OR WARNING_NAME like '%{ktb_WarningMsg.Text}%')";
|
||||||
|
}
|
||||||
|
if (kcmb_WarningType.SelectedIndex != 0)
|
||||||
|
{
|
||||||
|
sql += $" AND WARNING_TYPE = '{kcmb_WarningType.SelectedIndex}'";
|
||||||
|
}
|
||||||
|
if (kdtp_CreateStartTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND CREATE_TIME >= '{kdtp_CreateStartTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
if (kdtp_CreateEndTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND CREATE_TIME <= '{kdtp_CreateEndTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
|
||||||
|
dataGridView.Columns.Clear();
|
||||||
|
dataGridView.DataSource = dt;
|
||||||
|
dataGridView.SetDataViewColumnText(this.Name, GlobalHelper.LanguageCode);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override CreateParams CreateParams
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
CreateParams cp = base.CreateParams;
|
||||||
|
cp.ExStyle |= 0x02000000;
|
||||||
|
return cp;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
private void txt_GotFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.ShowInputPanel();
|
||||||
|
}
|
||||||
|
private void txt_LostFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.HideInputPanel();
|
||||||
|
}
|
||||||
|
private void InitControlEvent()
|
||||||
|
{
|
||||||
|
ktb_WarningMsg.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_WarningMsg.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void frmWarning_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
InitControlEvent();
|
||||||
|
this.SetFormControlText(GlobalHelper.LanguageCode);
|
||||||
|
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
|
||||||
|
if (GlobalHelper.LanguageCode == "English")
|
||||||
|
{
|
||||||
|
kcmb_WarningType.Items.Clear();
|
||||||
|
foreach (DataRow item in _ComboBoxLanguageTextList.GetComBoboxItemArr(kcmb_WarningType.Name, "KryptonComboBox"))
|
||||||
|
{
|
||||||
|
kcmb_WarningType.Items.Add(item["CONTROL_NAME"].ToString());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kcmb_WarningType.SelectedIndex = 0;
|
||||||
|
|
||||||
|
RefreshFrmHost = new dlgRefreshFrmHost(Init);
|
||||||
|
Init();
|
||||||
|
foreach (Control item in tableLayoutPanel2.Controls)
|
||||||
|
{
|
||||||
|
if (item.Tag == null)
|
||||||
|
{
|
||||||
|
DataRow[] drs = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{this.Name}' AND MENU_PID = '-1'");
|
||||||
|
DataRow[] drs1 = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{item.Name}' AND MENU_PID = '{drs[0]["MENU_ID"]}'");
|
||||||
|
if (drs1.Length > 0)
|
||||||
|
{
|
||||||
|
item.Enabled = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
item.Enabled = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kryptonGroupBox2.Focus();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("加载报警信息界面发生异常", "LoadWarningMsgExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Query_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
Init();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("查询报警信息数据发生异常", "QueryWarningMsgDataExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Reset_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
ktb_WarningMsg.Text = "";
|
||||||
|
kcmb_WarningType.SelectedIndex = 0;
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Add_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
frmAddWaringMsg frm = new frmAddWaringMsg();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Edit_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (dataGridView.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
frmEditWaringMsg frm = new frmEditWaringMsg();
|
||||||
|
frm.WarningId = dataGridView.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要编辑的报警信息数据行!", "SelectWantToEditRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Delete_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (dataGridView.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
DialogResult dr = KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("确定要删除所选的报警信息吗?", "DeleteInfo"), "Prompt", MessageBoxButtons.OKCancel, MessageBoxIcon.Question);
|
||||||
|
if (dr == DialogResult.OK)
|
||||||
|
{
|
||||||
|
string WarningId = dataGridView.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
string sql = $@"DELETE FROM BAS_WARNING WHERE WARNING_ID = '{WarningId}'";
|
||||||
|
int row = LeadDbHelperSQLite.ExecuteSql(sql);
|
||||||
|
if (row > 0)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除报警数据成功!", "DeleteSuccessInfo"));
|
||||||
|
RefreshFrmHost();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除报警数据失败!", "DeleteFailInfo"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要删除的报警数据行!", "SelectWantToDeleteRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除报警信息数据发生异常", "DeleteWarningMsgDataExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
135
CleanMachineHMI/FrmUserControl/Base/frmWarning.resx
Normal file
@@ -0,0 +1,135 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<metadata name="kryptonPanel6.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn4.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
</root>
|
||||||
203
CleanMachineHMI/FrmUserControl/frmCurrWorkingIrMsg.Designer.cs
generated
Normal file
@@ -0,0 +1,203 @@
|
|||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
partial class frmCurrWorkingIrMsg
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 必需的设计器变量。
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清理所有正在使用的资源。
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region 组件设计器生成的代码
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设计器支持所需的方法 - 不要修改
|
||||||
|
/// 使用代码编辑器修改此方法的内容。
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
this.components = new System.ComponentModel.Container();
|
||||||
|
this.kryptonDataGridView1 = new ComponentFactory.Krypton.Toolkit.KryptonDataGridView();
|
||||||
|
this.kryptonPanel1 = new ComponentFactory.Krypton.Toolkit.KryptonPanel();
|
||||||
|
this.kryptonGroupBox2 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.kryptonGroupBox1 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.kryptonButton1 = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonTextBox2 = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kryptonLabel2 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonTextBox1 = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kryptonLabel1 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.timer1 = new System.Windows.Forms.Timer(this.components);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonDataGridView1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel1)).BeginInit();
|
||||||
|
this.kryptonPanel1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox2.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox1.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox1.SuspendLayout();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// kryptonDataGridView1
|
||||||
|
//
|
||||||
|
this.kryptonDataGridView1.AllowUserToAddRows = false;
|
||||||
|
this.kryptonDataGridView1.AllowUserToDeleteRows = false;
|
||||||
|
this.kryptonDataGridView1.AllowUserToResizeRows = false;
|
||||||
|
this.kryptonDataGridView1.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.AllCells;
|
||||||
|
this.kryptonDataGridView1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
||||||
|
this.kryptonDataGridView1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonDataGridView1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonDataGridView1.MultiSelect = false;
|
||||||
|
this.kryptonDataGridView1.Name = "kryptonDataGridView1";
|
||||||
|
this.kryptonDataGridView1.RowTemplate.Height = 23;
|
||||||
|
this.kryptonDataGridView1.Size = new System.Drawing.Size(1020, 553);
|
||||||
|
this.kryptonDataGridView1.TabIndex = 0;
|
||||||
|
//
|
||||||
|
// kryptonPanel1
|
||||||
|
//
|
||||||
|
this.kryptonPanel1.Controls.Add(this.kryptonGroupBox2);
|
||||||
|
this.kryptonPanel1.Controls.Add(this.kryptonGroupBox1);
|
||||||
|
this.kryptonPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonPanel1.Name = "kryptonPanel1";
|
||||||
|
this.kryptonPanel1.Size = new System.Drawing.Size(1024, 672);
|
||||||
|
this.kryptonPanel1.TabIndex = 1;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonGroupBox2.Location = new System.Drawing.Point(0, 95);
|
||||||
|
this.kryptonGroupBox2.Name = "kryptonGroupBox2";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonDataGridView1);
|
||||||
|
this.kryptonGroupBox2.Size = new System.Drawing.Size(1024, 577);
|
||||||
|
this.kryptonGroupBox2.TabIndex = 1;
|
||||||
|
this.kryptonGroupBox2.Values.Heading = "Current IR Details:";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.kryptonGroupBox1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonGroupBox1.Name = "kryptonGroupBox1";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.kryptonButton1);
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.kryptonTextBox2);
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.kryptonLabel2);
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.kryptonTextBox1);
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.kryptonLabel1);
|
||||||
|
this.kryptonGroupBox1.Size = new System.Drawing.Size(1024, 95);
|
||||||
|
this.kryptonGroupBox1.TabIndex = 0;
|
||||||
|
this.kryptonGroupBox1.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// kryptonButton1
|
||||||
|
//
|
||||||
|
this.kryptonButton1.Location = new System.Drawing.Point(803, 33);
|
||||||
|
this.kryptonButton1.Name = "kryptonButton1";
|
||||||
|
this.kryptonButton1.Size = new System.Drawing.Size(122, 25);
|
||||||
|
this.kryptonButton1.TabIndex = 2;
|
||||||
|
this.kryptonButton1.Values.Text = "Clear current data";
|
||||||
|
this.kryptonButton1.Click += new System.EventHandler(this.kryptonButton1_Click);
|
||||||
|
//
|
||||||
|
// kryptonTextBox2
|
||||||
|
//
|
||||||
|
this.kryptonTextBox2.Location = new System.Drawing.Point(419, 53);
|
||||||
|
this.kryptonTextBox2.Name = "kryptonTextBox2";
|
||||||
|
this.kryptonTextBox2.ReadOnly = true;
|
||||||
|
this.kryptonTextBox2.Size = new System.Drawing.Size(301, 23);
|
||||||
|
this.kryptonTextBox2.StateCommon.Content.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.kryptonTextBox2.TabIndex = 1;
|
||||||
|
this.kryptonTextBox2.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
|
||||||
|
//
|
||||||
|
// kryptonLabel2
|
||||||
|
//
|
||||||
|
this.kryptonLabel2.Location = new System.Drawing.Point(169, 53);
|
||||||
|
this.kryptonLabel2.Name = "kryptonLabel2";
|
||||||
|
this.kryptonLabel2.RightToLeft = System.Windows.Forms.RightToLeft.No;
|
||||||
|
this.kryptonLabel2.Size = new System.Drawing.Size(244, 23);
|
||||||
|
this.kryptonLabel2.StateCommon.ShortText.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.kryptonLabel2.TabIndex = 0;
|
||||||
|
this.kryptonLabel2.Values.Text = "Current job IR information:";
|
||||||
|
//
|
||||||
|
// kryptonTextBox1
|
||||||
|
//
|
||||||
|
this.kryptonTextBox1.Location = new System.Drawing.Point(419, 12);
|
||||||
|
this.kryptonTextBox1.Name = "kryptonTextBox1";
|
||||||
|
this.kryptonTextBox1.ReadOnly = true;
|
||||||
|
this.kryptonTextBox1.Size = new System.Drawing.Size(301, 23);
|
||||||
|
this.kryptonTextBox1.StateCommon.Content.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.kryptonTextBox1.TabIndex = 1;
|
||||||
|
this.kryptonTextBox1.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
|
||||||
|
//
|
||||||
|
// kryptonLabel1
|
||||||
|
//
|
||||||
|
this.kryptonLabel1.Location = new System.Drawing.Point(236, 12);
|
||||||
|
this.kryptonLabel1.Name = "kryptonLabel1";
|
||||||
|
this.kryptonLabel1.RightToLeft = System.Windows.Forms.RightToLeft.No;
|
||||||
|
this.kryptonLabel1.Size = new System.Drawing.Size(177, 23);
|
||||||
|
this.kryptonLabel1.StateCommon.ShortText.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.kryptonLabel1.TabIndex = 0;
|
||||||
|
this.kryptonLabel1.Values.Text = "Current job pallet:";
|
||||||
|
//
|
||||||
|
// timer1
|
||||||
|
//
|
||||||
|
this.timer1.Interval = 1000;
|
||||||
|
this.timer1.Tick += new System.EventHandler(this.timer1_Tick);
|
||||||
|
//
|
||||||
|
// frmCurrWorkingIrMsg
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.Controls.Add(this.kryptonPanel1);
|
||||||
|
this.Name = "frmCurrWorkingIrMsg";
|
||||||
|
this.Size = new System.Drawing.Size(1024, 672);
|
||||||
|
this.Load += new System.EventHandler(this.frmCurrWorkingIrMsg_Load);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonDataGridView1)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel1)).EndInit();
|
||||||
|
this.kryptonPanel1.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox2.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).EndInit();
|
||||||
|
this.kryptonGroupBox2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox1.Panel.ResumeLayout(false);
|
||||||
|
this.kryptonGroupBox1.Panel.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).EndInit();
|
||||||
|
this.kryptonGroupBox1.ResumeLayout(false);
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridView kryptonDataGridView1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonPanel kryptonPanel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kryptonButton1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox kryptonTextBox2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox kryptonTextBox1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel1;
|
||||||
|
private System.Windows.Forms.Timer timer1;
|
||||||
|
}
|
||||||
|
}
|
||||||
115
CleanMachineHMI/FrmUserControl/frmCurrWorkingIrMsg.cs
Normal file
@@ -0,0 +1,115 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using LeadDataBaseUtility;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
[FormType(EnumFormType.CurrWorkingIR)]
|
||||||
|
public partial class frmCurrWorkingIrMsg : UserControl
|
||||||
|
{
|
||||||
|
public frmCurrWorkingIrMsg()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
}
|
||||||
|
public delegate void dlgRefreshFrmHost();
|
||||||
|
public static dlgRefreshFrmHost RefreshFrmHost;
|
||||||
|
private void RefreshData()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
this.SetFormControlText(GlobalHelper.LanguageCode);
|
||||||
|
string sql = $@"SELECT * FROM CM_WORKING_PALLET_DTL WHERE WORKING_DTL_STATUS = 0";
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
if (dt != null && dt.Rows.Count > 0)
|
||||||
|
{
|
||||||
|
string currIrMsg = dt.Rows[0]["IR_CODE"].ToString();
|
||||||
|
string currPalletMsg = dt.Rows[0]["WORKING_PALLET_CODE"].ToString();
|
||||||
|
string sql1 = $@"
|
||||||
|
SELECT
|
||||||
|
CLEAN_MODE_CODE '清洗方式编码',
|
||||||
|
CLEAN_MODE_NAME '清洗方式名称',
|
||||||
|
CONTAMINATION_TYPE_CODE '污染类型编码',
|
||||||
|
CONTAMINATION_TYPE_NAME '污染类型名称',
|
||||||
|
CONTAMINATION_DTL_CODE '污染明细编码',
|
||||||
|
CONTAMINATION_DTL_NAME '污染明细名称',
|
||||||
|
CURRENT_NUMBER '当前计数',
|
||||||
|
USER_CODE '操作员编码',
|
||||||
|
USER_NAME '操作员名称'
|
||||||
|
FROM
|
||||||
|
VW_WORKING_PALLET_MSG
|
||||||
|
WHERE
|
||||||
|
IR_CODE = '{currIrMsg}';
|
||||||
|
";
|
||||||
|
DataTable dt1 = LeadDbHelperSQLite.Query(sql1).Tables[0];
|
||||||
|
kryptonDataGridView1.DataSource = dt1;
|
||||||
|
kryptonTextBox1.Text = currPalletMsg;
|
||||||
|
kryptonTextBox2.Text = currIrMsg;
|
||||||
|
|
||||||
|
kryptonDataGridView1.SetDataViewColumnText(this.Name, GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
kryptonDataGridView1.DataSource = null;
|
||||||
|
kryptonTextBox1.Text = "";
|
||||||
|
kryptonTextBox2.Text = "";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
private void frmCurrWorkingIrMsg_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
RefreshFrmHost = new dlgRefreshFrmHost(RefreshData);
|
||||||
|
timer1.Enabled = true;
|
||||||
|
kryptonGroupBox1.Focus();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void timer1_Tick(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
RefreshData();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kryptonButton1_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
DialogResult dr = KryptonMessageBox.Show("Are you sure you want to clear the IR data for the current job? If you continue to reset the current job information, you will need to enter new IR and sheet information. please carefully operation!!!", "Prompt", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
|
||||||
|
if (dr == DialogResult.Yes)
|
||||||
|
{
|
||||||
|
string sqlUpdateWorkingPallet = $@"UPDATE CM_WORKING_PALLET SET WORKING_STATUS = 1,UPDATE_BY = '{GlobalHelper.UserInfo.USER_ID}',UPDATE_TIME = datetime('now', 'localtime'),DATA_VERSION = DATA_VERSION + 1 where WORKING_PALLET_CODE = '{kryptonTextBox1.Text.Trim()}';";
|
||||||
|
string sqlUpdateWorkingPalletDtl = $@"UPDATE CM_WORKING_PALLET_DTL SET WORKING_DTL_STATUS = 1,UPDATE_BY = '{GlobalHelper.UserInfo.USER_ID}',UPDATE_TIME = datetime('now', 'localtime'),DATA_VERSION = DATA_VERSION + 1 where WORKING_PALLET_CODE = '{kryptonTextBox1.Text.Trim()}';";
|
||||||
|
string sqlInsertZbkWorkingPallet = $@"INSERT INTO ZBK_WORKING_PALLET SELECT * FROM CM_WORKING_PALLET WHERE WORKING_STATUS = 1 and WORKING_PALLET_CODE in (select WORKING_PALLET_CODE from CM_WORKING_PALLET_DTL where WORKING_DTL_STATUS = 1 and IR_CODE = '{kryptonTextBox2.Text.Trim()}');";
|
||||||
|
string sqlInsertZbkWorkingPalletDtl = $@"INSERT INTO ZBK_WORKING_PALLET_DTL SELECT * FROM CM_WORKING_PALLET_DTL WHERE WORKING_DTL_STATUS = 1 and IR_CODE = '{kryptonTextBox2.Text.Trim()}';";
|
||||||
|
string sqlDeleteWorkingPallet = $@"delete from CM_WORKING_PALLET where WORKING_STATUS = 1 and WORKING_PALLET_CODE in (select WORKING_PALLET_CODE from CM_WORKING_PALLET_DTL where WORKING_DTL_STATUS = 1 and IR_CODE = '{kryptonTextBox2.Text.Trim()}');";
|
||||||
|
string sqlDeleteWorkingPalletDtl = $@"delete from CM_WORKING_PALLET_DTL where WORKING_DTL_STATUS = 1 and IR_CODE = '{kryptonTextBox2.Text.Trim()}';";
|
||||||
|
|
||||||
|
LeadDbHelperSQLite.ExecuteSql(sqlUpdateWorkingPallet);
|
||||||
|
LeadDbHelperSQLite.ExecuteSql(sqlUpdateWorkingPalletDtl);
|
||||||
|
LeadDbHelperSQLite.ExecuteSql(sqlInsertZbkWorkingPalletDtl);
|
||||||
|
LeadDbHelperSQLite.ExecuteSql(sqlInsertZbkWorkingPallet);
|
||||||
|
LeadDbHelperSQLite.ExecuteSql(sqlDeleteWorkingPallet);
|
||||||
|
LeadDbHelperSQLite.ExecuteSql(sqlDeleteWorkingPalletDtl);
|
||||||
|
frmMainDetail.RefreshCurrentWorkingDataFrmHost();
|
||||||
|
PlcOperationHelper.Instance.WritePlcItem("NozzleNum", "0", PlcItemTypeDesc.D);
|
||||||
|
KryptonMessageBox.Show("Cleared current working data successfully!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(ex.Message);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
123
CleanMachineHMI/FrmUserControl/frmCurrWorkingIrMsg.resx
Normal file
@@ -0,0 +1,123 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<metadata name="timer1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
|
<value>17, 17</value>
|
||||||
|
</metadata>
|
||||||
|
</root>
|
||||||
3381
CleanMachineHMI/FrmUserControl/frmIOMonitor.Designer.cs
generated
Normal file
123
CleanMachineHMI/FrmUserControl/frmIOMonitor.cs
Normal file
@@ -0,0 +1,123 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
//[FormType(EnumFormType.IoMonitor)]
|
||||||
|
public partial class frmIOMonitor : UserControl
|
||||||
|
{
|
||||||
|
public frmIOMonitor()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
_InfoLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode, "Label");
|
||||||
|
}
|
||||||
|
/// <summary>
|
||||||
|
/// 页面信息语言文本列表
|
||||||
|
/// </summary>
|
||||||
|
private DataTable _InfoLanguageTextList;
|
||||||
|
private void frmIOMonitorNew_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
initControl();
|
||||||
|
GlobalHelper.OnShowX_Y_Status += Show_X_Y_Status;
|
||||||
|
}
|
||||||
|
private void Show_X_Y_Status(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
BasPlcItemMd item = sender as BasPlcItemMd;
|
||||||
|
Invoke(new Action(() =>
|
||||||
|
{
|
||||||
|
if (item.PlcItemDataType == 2)
|
||||||
|
{
|
||||||
|
if (this.Controls.Find("cbt_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true).Length > 0)
|
||||||
|
{
|
||||||
|
CircleButton ctn = this.Controls.Find("cbt_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true)[0] as CircleButton;
|
||||||
|
if (string.IsNullOrEmpty(item.PlcItemValue))
|
||||||
|
{
|
||||||
|
ctn.BackColor = Color.FromArgb(191, 219, 255);
|
||||||
|
}
|
||||||
|
else if (bool.Parse(item.PlcItemValue.ToString()))
|
||||||
|
{
|
||||||
|
ctn.BackColor = Color.Lime;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
ctn.BackColor = Color.Red;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (this.Controls.Find("cbt_Y" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true).Length > 0)
|
||||||
|
{
|
||||||
|
CircleButton ctn = this.Controls.Find("cbt_Y" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true)[0] as CircleButton;
|
||||||
|
if (string.IsNullOrEmpty(item.PlcItemValue))
|
||||||
|
{
|
||||||
|
ctn.BackColor = Color.FromArgb(191, 219, 255);
|
||||||
|
}
|
||||||
|
else if (bool.Parse(item.PlcItemValue.ToString()))
|
||||||
|
{
|
||||||
|
ctn.BackColor = Color.Lime;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
ctn.BackColor = Color.Red;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}));
|
||||||
|
}
|
||||||
|
private void initControl()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (GlobalHelper.PlcItemMd_X_List != null && GlobalHelper.PlcItemMd_X_List.Count > 0)
|
||||||
|
{
|
||||||
|
List<BasPlcItemMd> tempLst = GlobalHelper.PlcItemMd_X_List.OrderBy(x => Convert.ToInt32(x.PlcItemPriAddress)).ToList();
|
||||||
|
foreach (BasPlcItemMd item in tempLst)
|
||||||
|
{
|
||||||
|
Invoke(new Action(() =>
|
||||||
|
{
|
||||||
|
if (this.Controls.Find("klb_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true).Length > 0)
|
||||||
|
{
|
||||||
|
KryptonLabel label1 = this.Controls.Find("klb_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true)[0] as KryptonLabel;
|
||||||
|
|
||||||
|
label1.Text = _InfoLanguageTextList.GetInfoText_1(item.PlcItemName.Replace("(I/O监控)", ""), item.PlcItemCode, "Label");
|
||||||
|
}
|
||||||
|
}));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (GlobalHelper.PlcItemMd_Y_List != null && GlobalHelper.PlcItemMd_Y_List.Count > 0)
|
||||||
|
{
|
||||||
|
List<BasPlcItemMd> tempLst = GlobalHelper.PlcItemMd_Y_List.OrderBy(x => Convert.ToInt32(x.PlcItemPriAddress)).ToList();
|
||||||
|
foreach (BasPlcItemMd item in tempLst)
|
||||||
|
{
|
||||||
|
Invoke(new Action(() =>
|
||||||
|
{
|
||||||
|
if (this.Controls.Find("klb_Y" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true).Length > 0)
|
||||||
|
{
|
||||||
|
KryptonLabel label1 = this.Controls.Find("klb_Y" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true)[0] as KryptonLabel;
|
||||||
|
|
||||||
|
label1.Text = _InfoLanguageTextList.GetInfoText_1(item.PlcItemName.Replace("(I/O监控)", ""), item.PlcItemCode, "Label");
|
||||||
|
}
|
||||||
|
}));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(ex.Message);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
120
CleanMachineHMI/FrmUserControl/frmIOMonitor.resx
Normal file
@@ -0,0 +1,120 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
</root>
|
||||||
3059
CleanMachineHMI/FrmUserControl/frmMainDetail.Designer.cs
generated
Normal file
3428
CleanMachineHMI/FrmUserControl/frmMainDetail.cs
Normal file
120
CleanMachineHMI/FrmUserControl/frmMainDetail.resx
Normal file
@@ -0,0 +1,120 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
</root>
|
||||||
214
CleanMachineHMI/FrmUserControl/frmMaintenance.Designer.cs
generated
Normal file
@@ -0,0 +1,214 @@
|
|||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
partial class frmMaintenance
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 必需的设计器变量。
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清理所有正在使用的资源。
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region 组件设计器生成的代码
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设计器支持所需的方法 - 不要修改
|
||||||
|
/// 使用代码编辑器修改此方法的内容。
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
this.kryptonGroupBox1 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.btn_logout = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.lbtitle = new System.Windows.Forms.Label();
|
||||||
|
this.kryptonGroupBox2 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.kryptonGroupBox4 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.kbtn_Pass_Yes = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonLabel55 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.lbwarning = new System.Windows.Forms.Label();
|
||||||
|
this.kryptonTextBox1 = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox1.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox2.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox4)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox4.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox4.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox4.SuspendLayout();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox1.CaptionStyle = ComponentFactory.Krypton.Toolkit.LabelStyle.TitleControl;
|
||||||
|
this.kryptonGroupBox1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.kryptonGroupBox1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonGroupBox1.Name = "kryptonGroupBox1";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.btn_logout);
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.lbtitle);
|
||||||
|
this.kryptonGroupBox1.Size = new System.Drawing.Size(1024, 95);
|
||||||
|
this.kryptonGroupBox1.TabIndex = 6;
|
||||||
|
this.kryptonGroupBox1.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// btn_logout
|
||||||
|
//
|
||||||
|
this.btn_logout.Location = new System.Drawing.Point(859, 15);
|
||||||
|
this.btn_logout.Name = "btn_logout";
|
||||||
|
this.btn_logout.Size = new System.Drawing.Size(101, 60);
|
||||||
|
this.btn_logout.StateCommon.Content.ShortText.Font = new System.Drawing.Font("新宋体", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.btn_logout.TabIndex = 18;
|
||||||
|
this.btn_logout.Values.Text = "EXIT";
|
||||||
|
this.btn_logout.Click += new System.EventHandler(this.btn_logout_Click);
|
||||||
|
//
|
||||||
|
// lbtitle
|
||||||
|
//
|
||||||
|
this.lbtitle.AutoSize = true;
|
||||||
|
this.lbtitle.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.lbtitle.Font = new System.Drawing.Font("宋体", 20F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.lbtitle.Location = new System.Drawing.Point(10, 29);
|
||||||
|
this.lbtitle.Name = "lbtitle";
|
||||||
|
this.lbtitle.Size = new System.Drawing.Size(552, 27);
|
||||||
|
this.lbtitle.TabIndex = 0;
|
||||||
|
this.lbtitle.Text = "The equipment is under maintenance !";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonGroupBox2.Location = new System.Drawing.Point(0, 95);
|
||||||
|
this.kryptonGroupBox2.Name = "kryptonGroupBox2";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonGroupBox4);
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.lbwarning);
|
||||||
|
this.kryptonGroupBox2.Size = new System.Drawing.Size(1024, 577);
|
||||||
|
this.kryptonGroupBox2.TabIndex = 7;
|
||||||
|
this.kryptonGroupBox2.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox4
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox4.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox4.Location = new System.Drawing.Point(58, 98);
|
||||||
|
this.kryptonGroupBox4.Name = "kryptonGroupBox4";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox4.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox4.Panel.Controls.Add(this.kryptonTextBox1);
|
||||||
|
this.kryptonGroupBox4.Panel.Controls.Add(this.kbtn_Pass_Yes);
|
||||||
|
this.kryptonGroupBox4.Panel.Controls.Add(this.kryptonLabel55);
|
||||||
|
this.kryptonGroupBox4.Size = new System.Drawing.Size(872, 278);
|
||||||
|
this.kryptonGroupBox4.TabIndex = 22;
|
||||||
|
this.kryptonGroupBox4.Values.Heading = "Maintaining";
|
||||||
|
//
|
||||||
|
// kbtn_Pass_Yes
|
||||||
|
//
|
||||||
|
this.kbtn_Pass_Yes.Location = new System.Drawing.Point(312, 192);
|
||||||
|
this.kbtn_Pass_Yes.Name = "kbtn_Pass_Yes";
|
||||||
|
this.kbtn_Pass_Yes.Size = new System.Drawing.Size(245, 40);
|
||||||
|
this.kbtn_Pass_Yes.StateCommon.Back.Color1 = System.Drawing.Color.Lime;
|
||||||
|
this.kbtn_Pass_Yes.StateCommon.Back.Color2 = System.Drawing.Color.Lime;
|
||||||
|
this.kbtn_Pass_Yes.StateCommon.Border.Color1 = System.Drawing.Color.Black;
|
||||||
|
this.kbtn_Pass_Yes.StateCommon.Border.DrawBorders = ((ComponentFactory.Krypton.Toolkit.PaletteDrawBorders)((((ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Top | ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Bottom)
|
||||||
|
| ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Left)
|
||||||
|
| ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Right)));
|
||||||
|
this.kbtn_Pass_Yes.StateCommon.Border.Width = 2;
|
||||||
|
this.kbtn_Pass_Yes.StateCommon.Content.ShortText.Font = new System.Drawing.Font("宋体", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.kbtn_Pass_Yes.TabIndex = 26;
|
||||||
|
this.kbtn_Pass_Yes.Values.Text = "Relieve Maintain";
|
||||||
|
this.kbtn_Pass_Yes.Click += new System.EventHandler(this.kbtn_Pass_Yes_Click);
|
||||||
|
//
|
||||||
|
// kryptonLabel55
|
||||||
|
//
|
||||||
|
this.kryptonLabel55.Location = new System.Drawing.Point(43, 41);
|
||||||
|
this.kryptonLabel55.Name = "kryptonLabel55";
|
||||||
|
this.kryptonLabel55.Size = new System.Drawing.Size(789, 35);
|
||||||
|
this.kryptonLabel55.StateCommon.ShortText.Color1 = System.Drawing.Color.Black;
|
||||||
|
this.kryptonLabel55.StateCommon.ShortText.Color2 = System.Drawing.Color.Black;
|
||||||
|
this.kryptonLabel55.StateCommon.ShortText.Font = new System.Drawing.Font("宋体", 21.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.kryptonLabel55.TabIndex = 25;
|
||||||
|
this.kryptonLabel55.Values.Text = "Please enter the Maintenance Unconfirmation Code ! ";
|
||||||
|
//
|
||||||
|
// lbwarning
|
||||||
|
//
|
||||||
|
this.lbwarning.AutoSize = true;
|
||||||
|
this.lbwarning.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.lbwarning.Font = new System.Drawing.Font("宋体", 15F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.lbwarning.Location = new System.Drawing.Point(11, 366);
|
||||||
|
this.lbwarning.Name = "lbwarning";
|
||||||
|
this.lbwarning.Size = new System.Drawing.Size(19, 20);
|
||||||
|
this.lbwarning.TabIndex = 0;
|
||||||
|
this.lbwarning.Text = " ";
|
||||||
|
//
|
||||||
|
// kryptonTextBox1
|
||||||
|
//
|
||||||
|
this.kryptonTextBox1.Location = new System.Drawing.Point(213, 117);
|
||||||
|
this.kryptonTextBox1.Name = "kryptonTextBox1";
|
||||||
|
this.kryptonTextBox1.Size = new System.Drawing.Size(433, 37);
|
||||||
|
this.kryptonTextBox1.StateCommon.Border.DrawBorders = ((ComponentFactory.Krypton.Toolkit.PaletteDrawBorders)((((ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Top | ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Bottom)
|
||||||
|
| ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Left)
|
||||||
|
| ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Right)));
|
||||||
|
this.kryptonTextBox1.StateCommon.Border.Width = 2;
|
||||||
|
this.kryptonTextBox1.StateCommon.Content.Color1 = System.Drawing.Color.Black;
|
||||||
|
this.kryptonTextBox1.StateCommon.Content.Font = new System.Drawing.Font("新宋体", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.kryptonTextBox1.TabIndex = 27;
|
||||||
|
this.kryptonTextBox1.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
|
||||||
|
//
|
||||||
|
// frmMaintenance
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.Controls.Add(this.kryptonGroupBox2);
|
||||||
|
this.Controls.Add(this.kryptonGroupBox1);
|
||||||
|
this.Name = "frmMaintenance";
|
||||||
|
this.Size = new System.Drawing.Size(1024, 672);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox1.Panel.ResumeLayout(false);
|
||||||
|
this.kryptonGroupBox1.Panel.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).EndInit();
|
||||||
|
this.kryptonGroupBox1.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox2.Panel.ResumeLayout(false);
|
||||||
|
this.kryptonGroupBox2.Panel.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).EndInit();
|
||||||
|
this.kryptonGroupBox2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox4.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox4.Panel.ResumeLayout(false);
|
||||||
|
this.kryptonGroupBox4.Panel.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox4)).EndInit();
|
||||||
|
this.kryptonGroupBox4.ResumeLayout(false);
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton btn_logout;
|
||||||
|
private System.Windows.Forms.Label lbtitle;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox4;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbtn_Pass_Yes;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel55;
|
||||||
|
private System.Windows.Forms.Label lbwarning;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox kryptonTextBox1;
|
||||||
|
}
|
||||||
|
}
|
||||||
76
CleanMachineHMI/FrmUserControl/frmMaintenance.cs
Normal file
@@ -0,0 +1,76 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using LeadDataBaseUtility;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
[FormType(EnumFormType.Maintenance)]
|
||||||
|
public partial class frmMaintenance : UserControl
|
||||||
|
{
|
||||||
|
public frmMaintenance()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbtn_Pass_Yes_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (string.IsNullOrEmpty(kryptonTextBox1.Text))
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show("The code cannot be empty !");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
string sqlParam = $@"SELECT * FROM SYS_PARAMETER";
|
||||||
|
DataTable dtParam = LeadDbHelperSQLite.Query(sqlParam).Tables[0];
|
||||||
|
if (dtParam != null && dtParam.Rows.Count > 0)
|
||||||
|
{
|
||||||
|
string maintainRelieveCode = dtParam.Select("PARAMETER_CODE = 'MaintainRelieveCode'")[0]["PARAMETER_VALUE"].ToString();
|
||||||
|
if (kryptonTextBox1.Text == maintainRelieveCode)
|
||||||
|
{
|
||||||
|
bool canOperate = Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("SelfCheckPassFlag", PlcItemTypeDesc.M));
|
||||||
|
//自检通过则切换至主界面,否则进入自检画面
|
||||||
|
if (canOperate)
|
||||||
|
{
|
||||||
|
frmMainNew.SwitchFrmMenu(EnumFormType.MainDetail, true);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
frmMainNew.SwitchFrmMenu(EnumFormType.MechineCheck, true);
|
||||||
|
}
|
||||||
|
string sqlUpdateParam = $@"update SYS_PARAMETER set PARAMETER_VALUE = '0' WHERE PARAMETER_CODE = 'MaintainFlag'";
|
||||||
|
LeadDbHelperSQLite.ExecuteSql(sqlUpdateParam);
|
||||||
|
string sqlUpdateRunTimeLen = $@"UPDATE SYS_PARAMETER set PARAMETER_VALUE = '0' WHERE PARAMETER_CODE = 'SysRuningTimeLen'";
|
||||||
|
LeadDbHelperSQLite.ExecuteSql(sqlUpdateRunTimeLen);
|
||||||
|
frmMainNew.RemoveMaintainingFlag();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show("Inputted maintenance uncode error !");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(ex.Message);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void btn_logout_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
GlobalHelper.LoginForm.Show();
|
||||||
|
GlobalHelper.MainFormNew.Hide();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
120
CleanMachineHMI/FrmUserControl/frmMaintenance.resx
Normal file
@@ -0,0 +1,120 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
</root>
|
||||||
1004
CleanMachineHMI/FrmUserControl/frmManual.Designer.cs
generated
Normal file
1736
CleanMachineHMI/FrmUserControl/frmManual.cs
Normal file
120
CleanMachineHMI/FrmUserControl/frmManual.resx
Normal file
@@ -0,0 +1,120 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
</root>
|
||||||
466
CleanMachineHMI/FrmUserControl/frmMechineCheck.Designer.cs
generated
Normal file
@@ -0,0 +1,466 @@
|
|||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
partial class frmMechineCheck
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 必需的设计器变量。
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清理所有正在使用的资源。
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region 组件设计器生成的代码
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设计器支持所需的方法 - 不要修改
|
||||||
|
/// 使用代码编辑器修改此方法的内容。
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
this.kryptonLabel2 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.cbt_Brush3StatusTran = new CleanMachineHMI.CircleButton();
|
||||||
|
this.swtbtn_brush1 = new CleanMachineHMI.LSwitchButton();
|
||||||
|
this.swtbtn_brush3 = new CleanMachineHMI.LSwitchButton();
|
||||||
|
this.kryptonLabel7 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.swtbtn_brush2 = new CleanMachineHMI.LSwitchButton();
|
||||||
|
this.cbt_Brush2StatusTran = new CleanMachineHMI.CircleButton();
|
||||||
|
this.cbt_Brush1StatusTran = new CleanMachineHMI.CircleButton();
|
||||||
|
this.kryptonGroupBox5 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.kryptonLabel1 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel4 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.cbt_RunStatusTran = new CleanMachineHMI.CircleButton();
|
||||||
|
this.lbwarning = new System.Windows.Forms.Label();
|
||||||
|
this.cbt_ResetSys = new CleanMachineHMI.CircleButton();
|
||||||
|
this.cbt_StartTran = new CleanMachineHMI.CircleButton();
|
||||||
|
this.kbtn_Pass_No = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbtn_Pass_Yes = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonLabel66 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel55 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonGroupBox4 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.kryptonGroupBox2 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.kryptonGroupBox3 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.btn_logout = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.lbtitle = new System.Windows.Forms.Label();
|
||||||
|
this.kryptonGroupBox1 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox5)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox5.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox5.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox5.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox4)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox4.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox4.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox4.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox2.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox3)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox3.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox3.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox3.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox1.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox1.SuspendLayout();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// kryptonLabel2
|
||||||
|
//
|
||||||
|
this.kryptonLabel2.Location = new System.Drawing.Point(43, 125);
|
||||||
|
this.kryptonLabel2.Name = "kryptonLabel2";
|
||||||
|
this.kryptonLabel2.Size = new System.Drawing.Size(69, 20);
|
||||||
|
this.kryptonLabel2.TabIndex = 29;
|
||||||
|
this.kryptonLabel2.Values.Text = "毛刷选择3";
|
||||||
|
//
|
||||||
|
// cbt_Brush3StatusTran
|
||||||
|
//
|
||||||
|
this.cbt_Brush3StatusTran.BackColor = System.Drawing.Color.Gray;
|
||||||
|
this.cbt_Brush3StatusTran.Location = new System.Drawing.Point(227, 120);
|
||||||
|
this.cbt_Brush3StatusTran.Name = "cbt_Brush3StatusTran";
|
||||||
|
this.cbt_Brush3StatusTran.Size = new System.Drawing.Size(30, 30);
|
||||||
|
this.cbt_Brush3StatusTran.TabIndex = 27;
|
||||||
|
this.cbt_Brush3StatusTran.UseVisualStyleBackColor = false;
|
||||||
|
//
|
||||||
|
// swtbtn_brush1
|
||||||
|
//
|
||||||
|
this.swtbtn_brush1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(191)))), ((int)(((byte)(219)))), ((int)(((byte)(225)))));
|
||||||
|
this.swtbtn_brush1.L_AnimateType = LEase.LEaseType.Quartic;
|
||||||
|
this.swtbtn_brush1.L_BarHight = 24;
|
||||||
|
this.swtbtn_brush1.L_CloseColor = System.Drawing.Color.Red;
|
||||||
|
this.swtbtn_brush1.L_DotColor = System.Drawing.Color.White;
|
||||||
|
this.swtbtn_brush1.L_DotHight = 20;
|
||||||
|
this.swtbtn_brush1.L_IsOpen = false;
|
||||||
|
this.swtbtn_brush1.L_Margin = 2;
|
||||||
|
this.swtbtn_brush1.L_OpenColor = System.Drawing.Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
|
||||||
|
this.swtbtn_brush1.Location = new System.Drawing.Point(129, 33);
|
||||||
|
this.swtbtn_brush1.Name = "swtbtn_brush1";
|
||||||
|
this.swtbtn_brush1.Size = new System.Drawing.Size(58, 25);
|
||||||
|
this.swtbtn_brush1.TabIndex = 23;
|
||||||
|
this.swtbtn_brush1.Text = "lSwitchButton1";
|
||||||
|
this.swtbtn_brush1.LSwitched += new CleanMachineHMI.LSwitchButton.LSwitchedEventHandler(this.swtbtn_brush1_LSwitched);
|
||||||
|
//
|
||||||
|
// swtbtn_brush3
|
||||||
|
//
|
||||||
|
this.swtbtn_brush3.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(191)))), ((int)(((byte)(219)))), ((int)(((byte)(225)))));
|
||||||
|
this.swtbtn_brush3.L_AnimateType = LEase.LEaseType.Quartic;
|
||||||
|
this.swtbtn_brush3.L_BarHight = 24;
|
||||||
|
this.swtbtn_brush3.L_CloseColor = System.Drawing.Color.Red;
|
||||||
|
this.swtbtn_brush3.L_DotColor = System.Drawing.Color.White;
|
||||||
|
this.swtbtn_brush3.L_DotHight = 20;
|
||||||
|
this.swtbtn_brush3.L_IsOpen = false;
|
||||||
|
this.swtbtn_brush3.L_Margin = 2;
|
||||||
|
this.swtbtn_brush3.L_OpenColor = System.Drawing.Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
|
||||||
|
this.swtbtn_brush3.Location = new System.Drawing.Point(129, 123);
|
||||||
|
this.swtbtn_brush3.Name = "swtbtn_brush3";
|
||||||
|
this.swtbtn_brush3.Size = new System.Drawing.Size(58, 25);
|
||||||
|
this.swtbtn_brush3.TabIndex = 28;
|
||||||
|
this.swtbtn_brush3.Text = "lSwitchButton3";
|
||||||
|
this.swtbtn_brush3.LSwitched += new CleanMachineHMI.LSwitchButton.LSwitchedEventHandler(this.swtbtn_brush3_LSwitched);
|
||||||
|
//
|
||||||
|
// kryptonLabel7
|
||||||
|
//
|
||||||
|
this.kryptonLabel7.Location = new System.Drawing.Point(43, 80);
|
||||||
|
this.kryptonLabel7.Name = "kryptonLabel7";
|
||||||
|
this.kryptonLabel7.Size = new System.Drawing.Size(69, 20);
|
||||||
|
this.kryptonLabel7.TabIndex = 26;
|
||||||
|
this.kryptonLabel7.Values.Text = "毛刷选择2";
|
||||||
|
//
|
||||||
|
// swtbtn_brush2
|
||||||
|
//
|
||||||
|
this.swtbtn_brush2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(191)))), ((int)(((byte)(219)))), ((int)(((byte)(225)))));
|
||||||
|
this.swtbtn_brush2.L_AnimateType = LEase.LEaseType.Quartic;
|
||||||
|
this.swtbtn_brush2.L_BarHight = 24;
|
||||||
|
this.swtbtn_brush2.L_CloseColor = System.Drawing.Color.Red;
|
||||||
|
this.swtbtn_brush2.L_DotColor = System.Drawing.Color.White;
|
||||||
|
this.swtbtn_brush2.L_DotHight = 20;
|
||||||
|
this.swtbtn_brush2.L_IsOpen = false;
|
||||||
|
this.swtbtn_brush2.L_Margin = 2;
|
||||||
|
this.swtbtn_brush2.L_OpenColor = System.Drawing.Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
|
||||||
|
this.swtbtn_brush2.Location = new System.Drawing.Point(129, 78);
|
||||||
|
this.swtbtn_brush2.Name = "swtbtn_brush2";
|
||||||
|
this.swtbtn_brush2.Size = new System.Drawing.Size(58, 25);
|
||||||
|
this.swtbtn_brush2.TabIndex = 25;
|
||||||
|
this.swtbtn_brush2.Text = "lSwitchButton2";
|
||||||
|
this.swtbtn_brush2.LSwitched += new CleanMachineHMI.LSwitchButton.LSwitchedEventHandler(this.swtbtn_brush2_LSwitched);
|
||||||
|
//
|
||||||
|
// cbt_Brush2StatusTran
|
||||||
|
//
|
||||||
|
this.cbt_Brush2StatusTran.BackColor = System.Drawing.Color.Gray;
|
||||||
|
this.cbt_Brush2StatusTran.Location = new System.Drawing.Point(227, 75);
|
||||||
|
this.cbt_Brush2StatusTran.Name = "cbt_Brush2StatusTran";
|
||||||
|
this.cbt_Brush2StatusTran.Size = new System.Drawing.Size(30, 30);
|
||||||
|
this.cbt_Brush2StatusTran.TabIndex = 24;
|
||||||
|
this.cbt_Brush2StatusTran.UseVisualStyleBackColor = false;
|
||||||
|
//
|
||||||
|
// cbt_Brush1StatusTran
|
||||||
|
//
|
||||||
|
this.cbt_Brush1StatusTran.BackColor = System.Drawing.Color.Gray;
|
||||||
|
this.cbt_Brush1StatusTran.Location = new System.Drawing.Point(227, 30);
|
||||||
|
this.cbt_Brush1StatusTran.Name = "cbt_Brush1StatusTran";
|
||||||
|
this.cbt_Brush1StatusTran.Size = new System.Drawing.Size(30, 30);
|
||||||
|
this.cbt_Brush1StatusTran.TabIndex = 10;
|
||||||
|
this.cbt_Brush1StatusTran.UseVisualStyleBackColor = false;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox5
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox5.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox5.Location = new System.Drawing.Point(500, 24);
|
||||||
|
this.kryptonGroupBox5.Name = "kryptonGroupBox5";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox5.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox5.Panel.Controls.Add(this.kryptonLabel2);
|
||||||
|
this.kryptonGroupBox5.Panel.Controls.Add(this.cbt_Brush3StatusTran);
|
||||||
|
this.kryptonGroupBox5.Panel.Controls.Add(this.swtbtn_brush1);
|
||||||
|
this.kryptonGroupBox5.Panel.Controls.Add(this.swtbtn_brush3);
|
||||||
|
this.kryptonGroupBox5.Panel.Controls.Add(this.kryptonLabel7);
|
||||||
|
this.kryptonGroupBox5.Panel.Controls.Add(this.swtbtn_brush2);
|
||||||
|
this.kryptonGroupBox5.Panel.Controls.Add(this.cbt_Brush2StatusTran);
|
||||||
|
this.kryptonGroupBox5.Panel.Controls.Add(this.kryptonLabel1);
|
||||||
|
this.kryptonGroupBox5.Panel.Controls.Add(this.cbt_Brush1StatusTran);
|
||||||
|
this.kryptonGroupBox5.Size = new System.Drawing.Size(288, 209);
|
||||||
|
this.kryptonGroupBox5.TabIndex = 1;
|
||||||
|
this.kryptonGroupBox5.Values.Heading = "清洁毛刷选择";
|
||||||
|
//
|
||||||
|
// kryptonLabel1
|
||||||
|
//
|
||||||
|
this.kryptonLabel1.Location = new System.Drawing.Point(43, 35);
|
||||||
|
this.kryptonLabel1.Name = "kryptonLabel1";
|
||||||
|
this.kryptonLabel1.Size = new System.Drawing.Size(69, 20);
|
||||||
|
this.kryptonLabel1.TabIndex = 23;
|
||||||
|
this.kryptonLabel1.Values.Text = "毛刷选择1";
|
||||||
|
//
|
||||||
|
// kryptonLabel4
|
||||||
|
//
|
||||||
|
this.kryptonLabel4.Location = new System.Drawing.Point(59, 44);
|
||||||
|
this.kryptonLabel4.Name = "kryptonLabel4";
|
||||||
|
this.kryptonLabel4.Size = new System.Drawing.Size(135, 20);
|
||||||
|
this.kryptonLabel4.TabIndex = 24;
|
||||||
|
this.kryptonLabel4.Values.Text = "System Running Status";
|
||||||
|
//
|
||||||
|
// cbt_RunStatusTran
|
||||||
|
//
|
||||||
|
this.cbt_RunStatusTran.BackColor = System.Drawing.Color.Gray;
|
||||||
|
this.cbt_RunStatusTran.Location = new System.Drawing.Point(200, 39);
|
||||||
|
this.cbt_RunStatusTran.Name = "cbt_RunStatusTran";
|
||||||
|
this.cbt_RunStatusTran.Size = new System.Drawing.Size(30, 30);
|
||||||
|
this.cbt_RunStatusTran.TabIndex = 13;
|
||||||
|
this.cbt_RunStatusTran.UseVisualStyleBackColor = false;
|
||||||
|
//
|
||||||
|
// lbwarning
|
||||||
|
//
|
||||||
|
this.lbwarning.AutoSize = true;
|
||||||
|
this.lbwarning.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.lbwarning.Font = new System.Drawing.Font("宋体", 15F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.lbwarning.Location = new System.Drawing.Point(11, 366);
|
||||||
|
this.lbwarning.Name = "lbwarning";
|
||||||
|
this.lbwarning.Size = new System.Drawing.Size(19, 20);
|
||||||
|
this.lbwarning.TabIndex = 0;
|
||||||
|
this.lbwarning.Text = " ";
|
||||||
|
//
|
||||||
|
// cbt_ResetSys
|
||||||
|
//
|
||||||
|
this.cbt_ResetSys.BackColor = System.Drawing.Color.DarkOrange;
|
||||||
|
this.cbt_ResetSys.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.cbt_ResetSys.ForeColor = System.Drawing.Color.White;
|
||||||
|
this.cbt_ResetSys.Location = new System.Drawing.Point(158, 81);
|
||||||
|
this.cbt_ResetSys.Name = "cbt_ResetSys";
|
||||||
|
this.cbt_ResetSys.Size = new System.Drawing.Size(60, 60);
|
||||||
|
this.cbt_ResetSys.TabIndex = 10;
|
||||||
|
this.cbt_ResetSys.Text = "RESET";
|
||||||
|
this.cbt_ResetSys.UseVisualStyleBackColor = false;
|
||||||
|
this.cbt_ResetSys.MouseDown += new System.Windows.Forms.MouseEventHandler(this.cbt_ResetSys_MouseDown);
|
||||||
|
this.cbt_ResetSys.MouseUp += new System.Windows.Forms.MouseEventHandler(this.cbt_ResetSys_MouseUp);
|
||||||
|
//
|
||||||
|
// cbt_StartTran
|
||||||
|
//
|
||||||
|
this.cbt_StartTran.BackColor = System.Drawing.Color.Lime;
|
||||||
|
this.cbt_StartTran.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.cbt_StartTran.Location = new System.Drawing.Point(74, 81);
|
||||||
|
this.cbt_StartTran.Name = "cbt_StartTran";
|
||||||
|
this.cbt_StartTran.Size = new System.Drawing.Size(60, 60);
|
||||||
|
this.cbt_StartTran.TabIndex = 12;
|
||||||
|
this.cbt_StartTran.Text = "START";
|
||||||
|
this.cbt_StartTran.UseVisualStyleBackColor = false;
|
||||||
|
this.cbt_StartTran.Click += new System.EventHandler(this.cbt_StartTran_Click_1);
|
||||||
|
//
|
||||||
|
// kbtn_Pass_No
|
||||||
|
//
|
||||||
|
this.kbtn_Pass_No.Location = new System.Drawing.Point(390, 101);
|
||||||
|
this.kbtn_Pass_No.Name = "kbtn_Pass_No";
|
||||||
|
this.kbtn_Pass_No.Size = new System.Drawing.Size(80, 80);
|
||||||
|
this.kbtn_Pass_No.StateCommon.Back.Color1 = System.Drawing.Color.Red;
|
||||||
|
this.kbtn_Pass_No.StateCommon.Back.Color2 = System.Drawing.Color.Red;
|
||||||
|
this.kbtn_Pass_No.StateCommon.Border.Color1 = System.Drawing.Color.Black;
|
||||||
|
this.kbtn_Pass_No.StateCommon.Border.DrawBorders = ((ComponentFactory.Krypton.Toolkit.PaletteDrawBorders)((((ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Top | ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Bottom)
|
||||||
|
| ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Left)
|
||||||
|
| ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Right)));
|
||||||
|
this.kbtn_Pass_No.StateCommon.Border.Width = 2;
|
||||||
|
this.kbtn_Pass_No.StateCommon.Content.ShortText.Font = new System.Drawing.Font("宋体", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.kbtn_Pass_No.TabIndex = 26;
|
||||||
|
this.kbtn_Pass_No.Values.Text = "No";
|
||||||
|
this.kbtn_Pass_No.Click += new System.EventHandler(this.kbtn_Pass_No_Click);
|
||||||
|
//
|
||||||
|
// kbtn_Pass_Yes
|
||||||
|
//
|
||||||
|
this.kbtn_Pass_Yes.Location = new System.Drawing.Point(107, 101);
|
||||||
|
this.kbtn_Pass_Yes.Name = "kbtn_Pass_Yes";
|
||||||
|
this.kbtn_Pass_Yes.Size = new System.Drawing.Size(80, 80);
|
||||||
|
this.kbtn_Pass_Yes.StateCommon.Back.Color1 = System.Drawing.Color.Lime;
|
||||||
|
this.kbtn_Pass_Yes.StateCommon.Back.Color2 = System.Drawing.Color.Lime;
|
||||||
|
this.kbtn_Pass_Yes.StateCommon.Border.Color1 = System.Drawing.Color.Black;
|
||||||
|
this.kbtn_Pass_Yes.StateCommon.Border.DrawBorders = ((ComponentFactory.Krypton.Toolkit.PaletteDrawBorders)((((ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Top | ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Bottom)
|
||||||
|
| ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Left)
|
||||||
|
| ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Right)));
|
||||||
|
this.kbtn_Pass_Yes.StateCommon.Border.Width = 2;
|
||||||
|
this.kbtn_Pass_Yes.StateCommon.Content.ShortText.Font = new System.Drawing.Font("宋体", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.kbtn_Pass_Yes.TabIndex = 26;
|
||||||
|
this.kbtn_Pass_Yes.Values.Text = "Yes";
|
||||||
|
this.kbtn_Pass_Yes.Click += new System.EventHandler(this.kbtn_Pass_Yes_Click);
|
||||||
|
//
|
||||||
|
// kryptonLabel66
|
||||||
|
//
|
||||||
|
this.kryptonLabel66.Location = new System.Drawing.Point(263, 105);
|
||||||
|
this.kryptonLabel66.Name = "kryptonLabel66";
|
||||||
|
this.kryptonLabel66.Size = new System.Drawing.Size(58, 26);
|
||||||
|
this.kryptonLabel66.StateCommon.ShortText.Color1 = System.Drawing.Color.Black;
|
||||||
|
this.kryptonLabel66.StateCommon.ShortText.Color2 = System.Drawing.Color.Black;
|
||||||
|
this.kryptonLabel66.StateCommon.ShortText.Font = new System.Drawing.Font("宋体", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.kryptonLabel66.TabIndex = 25;
|
||||||
|
this.kryptonLabel66.Values.Text = "PASS";
|
||||||
|
//
|
||||||
|
// kryptonLabel55
|
||||||
|
//
|
||||||
|
this.kryptonLabel55.Location = new System.Drawing.Point(42, 25);
|
||||||
|
this.kryptonLabel55.Name = "kryptonLabel55";
|
||||||
|
this.kryptonLabel55.Size = new System.Drawing.Size(485, 42);
|
||||||
|
this.kryptonLabel55.StateCommon.ShortText.Color1 = System.Drawing.Color.Black;
|
||||||
|
this.kryptonLabel55.StateCommon.ShortText.Color2 = System.Drawing.Color.Black;
|
||||||
|
this.kryptonLabel55.StateCommon.ShortText.Font = new System.Drawing.Font("宋体", 26.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.kryptonLabel55.TabIndex = 25;
|
||||||
|
this.kryptonLabel55.Values.Text = "Cleaning performance test";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox4
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox4.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox4.Location = new System.Drawing.Point(206, 239);
|
||||||
|
this.kryptonGroupBox4.Name = "kryptonGroupBox4";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox4.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox4.Panel.Controls.Add(this.kbtn_Pass_No);
|
||||||
|
this.kryptonGroupBox4.Panel.Controls.Add(this.kbtn_Pass_Yes);
|
||||||
|
this.kryptonGroupBox4.Panel.Controls.Add(this.kryptonLabel66);
|
||||||
|
this.kryptonGroupBox4.Panel.Controls.Add(this.kryptonLabel55);
|
||||||
|
this.kryptonGroupBox4.Size = new System.Drawing.Size(582, 235);
|
||||||
|
this.kryptonGroupBox4.TabIndex = 22;
|
||||||
|
this.kryptonGroupBox4.Values.Heading = "Machine Check Test Result";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonGroupBox2.Location = new System.Drawing.Point(0, 95);
|
||||||
|
this.kryptonGroupBox2.Name = "kryptonGroupBox2";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonGroupBox4);
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.lbwarning);
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonGroupBox3);
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonGroupBox5);
|
||||||
|
this.kryptonGroupBox2.Size = new System.Drawing.Size(1024, 577);
|
||||||
|
this.kryptonGroupBox2.TabIndex = 5;
|
||||||
|
this.kryptonGroupBox2.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox3
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox3.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox3.Location = new System.Drawing.Point(206, 23);
|
||||||
|
this.kryptonGroupBox3.Name = "kryptonGroupBox3";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox3.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox3.Panel.Controls.Add(this.kryptonLabel4);
|
||||||
|
this.kryptonGroupBox3.Panel.Controls.Add(this.cbt_RunStatusTran);
|
||||||
|
this.kryptonGroupBox3.Panel.Controls.Add(this.cbt_ResetSys);
|
||||||
|
this.kryptonGroupBox3.Panel.Controls.Add(this.cbt_StartTran);
|
||||||
|
this.kryptonGroupBox3.Size = new System.Drawing.Size(288, 210);
|
||||||
|
this.kryptonGroupBox3.TabIndex = 21;
|
||||||
|
this.kryptonGroupBox3.Values.Heading = "System Running";
|
||||||
|
//
|
||||||
|
// btn_logout
|
||||||
|
//
|
||||||
|
this.btn_logout.Location = new System.Drawing.Point(859, 15);
|
||||||
|
this.btn_logout.Name = "btn_logout";
|
||||||
|
this.btn_logout.Size = new System.Drawing.Size(101, 60);
|
||||||
|
this.btn_logout.TabIndex = 18;
|
||||||
|
this.btn_logout.Values.Text = "退出系统";
|
||||||
|
this.btn_logout.Click += new System.EventHandler(this.kryptonButton1_Click);
|
||||||
|
//
|
||||||
|
// lbtitle
|
||||||
|
//
|
||||||
|
this.lbtitle.AutoSize = true;
|
||||||
|
this.lbtitle.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.lbtitle.Font = new System.Drawing.Font("宋体", 20F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.lbtitle.Location = new System.Drawing.Point(10, 29);
|
||||||
|
this.lbtitle.Name = "lbtitle";
|
||||||
|
this.lbtitle.Size = new System.Drawing.Size(255, 27);
|
||||||
|
this.lbtitle.TabIndex = 0;
|
||||||
|
this.lbtitle.Text = "清洁机操作自检测试";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox1.CaptionStyle = ComponentFactory.Krypton.Toolkit.LabelStyle.TitleControl;
|
||||||
|
this.kryptonGroupBox1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.kryptonGroupBox1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonGroupBox1.Name = "kryptonGroupBox1";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.btn_logout);
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.lbtitle);
|
||||||
|
this.kryptonGroupBox1.Size = new System.Drawing.Size(1024, 95);
|
||||||
|
this.kryptonGroupBox1.TabIndex = 4;
|
||||||
|
this.kryptonGroupBox1.Values.Heading = "";
|
||||||
|
//
|
||||||
|
// frmMechineCheck
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.Controls.Add(this.kryptonGroupBox2);
|
||||||
|
this.Controls.Add(this.kryptonGroupBox1);
|
||||||
|
this.Name = "frmMechineCheck";
|
||||||
|
this.Size = new System.Drawing.Size(1024, 672);
|
||||||
|
this.Load += new System.EventHandler(this.frmMechineCheck_Load);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox5.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox5.Panel.ResumeLayout(false);
|
||||||
|
this.kryptonGroupBox5.Panel.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox5)).EndInit();
|
||||||
|
this.kryptonGroupBox5.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox4.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox4.Panel.ResumeLayout(false);
|
||||||
|
this.kryptonGroupBox4.Panel.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox4)).EndInit();
|
||||||
|
this.kryptonGroupBox4.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox2.Panel.ResumeLayout(false);
|
||||||
|
this.kryptonGroupBox2.Panel.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).EndInit();
|
||||||
|
this.kryptonGroupBox2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox3.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox3.Panel.ResumeLayout(false);
|
||||||
|
this.kryptonGroupBox3.Panel.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox3)).EndInit();
|
||||||
|
this.kryptonGroupBox3.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox1.Panel.ResumeLayout(false);
|
||||||
|
this.kryptonGroupBox1.Panel.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).EndInit();
|
||||||
|
this.kryptonGroupBox1.ResumeLayout(false);
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel2;
|
||||||
|
private CircleButton cbt_Brush3StatusTran;
|
||||||
|
private LSwitchButton swtbtn_brush1;
|
||||||
|
private LSwitchButton swtbtn_brush3;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel7;
|
||||||
|
private LSwitchButton swtbtn_brush2;
|
||||||
|
private CircleButton cbt_Brush2StatusTran;
|
||||||
|
private CircleButton cbt_Brush1StatusTran;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox5;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel4;
|
||||||
|
private CircleButton cbt_RunStatusTran;
|
||||||
|
private System.Windows.Forms.Label lbwarning;
|
||||||
|
private CircleButton cbt_ResetSys;
|
||||||
|
private CircleButton cbt_StartTran;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbtn_Pass_No;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbtn_Pass_Yes;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel66;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel55;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox4;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox3;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton btn_logout;
|
||||||
|
private System.Windows.Forms.Label lbtitle;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox1;
|
||||||
|
}
|
||||||
|
}
|
||||||
311
CleanMachineHMI/FrmUserControl/frmMechineCheck.cs
Normal file
@@ -0,0 +1,311 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
[FormType(EnumFormType.MechineCheck)]
|
||||||
|
public partial class frmMechineCheck : UserControl
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 页面信息语言文本列表
|
||||||
|
/// </summary>
|
||||||
|
private DataTable _InfoLanguageTextList;
|
||||||
|
public frmMechineCheck()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
_InfoLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
|
||||||
|
//注销退出
|
||||||
|
private void kryptonButton1_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
GlobalHelper.LoginForm.Show();
|
||||||
|
//GlobalHelper.MainForm.Hide();
|
||||||
|
GlobalHelper.MainFormNew.Hide();
|
||||||
|
}
|
||||||
|
private void swtbtn_brush1_LSwitched(object sender, LEventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (!PlcOperationHelper.Instance.isConn)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show("The PLC is disconnected and unable to operate the equipment.");
|
||||||
|
swtbtn_brush1.L_IsOpen = false;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
//选中状态,并且跟当前状态有差别则发送选中状态
|
||||||
|
if (swtbtn_brush1.L_IsOpen)
|
||||||
|
{
|
||||||
|
PlcOperationHelper.Instance.WritePlcItem("Hairbrush1Selection", "True", PlcItemTypeDesc.M);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
PlcOperationHelper.Instance.WritePlcItem("Hairbrush1Selection", "False", PlcItemTypeDesc.M);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
catch (Exception)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
private void swtbtn_brush2_LSwitched(object sender, LEventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (!PlcOperationHelper.Instance.isConn)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show("The PLC is disconnected and unable to operate the equipment.");
|
||||||
|
swtbtn_brush2.L_IsOpen = false;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
//选中状态,并且跟当前状态有差别则发送选中状态
|
||||||
|
if (swtbtn_brush2.L_IsOpen)
|
||||||
|
{
|
||||||
|
PlcOperationHelper.Instance.WritePlcItem("Hairbrush2Selection", "True", PlcItemTypeDesc.M);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
PlcOperationHelper.Instance.WritePlcItem("Hairbrush2Selection", "False", PlcItemTypeDesc.M);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
catch (Exception)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void cbt_ResetSys_MouseDown(object sender, MouseEventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (!Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("ResetSys", PlcItemTypeDesc.M)))
|
||||||
|
{
|
||||||
|
PlcOperationHelper.Instance.WritePlcItem("ResetSys", "True", PlcItemTypeDesc.M);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void cbt_ResetSys_MouseUp(object sender, MouseEventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
PlcOperationHelper.Instance.WritePlcItem("ResetSys", "False", PlcItemTypeDesc.M);
|
||||||
|
}
|
||||||
|
catch (Exception)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//初始化,同步内存监控点状态
|
||||||
|
private void frmMechineCheck_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
|
||||||
|
this.SetFormControlText(GlobalHelper.LanguageCode);
|
||||||
|
Thread th1 = new Thread(MainDtlRunTh);
|
||||||
|
th1.IsBackground = true;
|
||||||
|
th1.Start();
|
||||||
|
|
||||||
|
//毛刷1运行状态
|
||||||
|
if (Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("Hairbrush1Selection", PlcItemTypeDesc.M)))
|
||||||
|
{
|
||||||
|
swtbtn_brush1.L_IsOpen = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
swtbtn_brush1.L_IsOpen = false;
|
||||||
|
}
|
||||||
|
if (Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("Hairbrush2Selection", PlcItemTypeDesc.M)))
|
||||||
|
{
|
||||||
|
swtbtn_brush2.L_IsOpen = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
swtbtn_brush2.L_IsOpen = false;
|
||||||
|
}
|
||||||
|
//毛刷3启用状态
|
||||||
|
if (Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("Hairbrush3Selection", PlcItemTypeDesc.M)))
|
||||||
|
{
|
||||||
|
swtbtn_brush3.L_IsOpen = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
swtbtn_brush3.L_IsOpen = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
//同步运行状态
|
||||||
|
private void MainDtlRunTh()
|
||||||
|
{
|
||||||
|
while (GlobalHelper.SysThIsRunFlag)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
//系统运行状态
|
||||||
|
if (Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("SelfCheckFlag", PlcItemTypeDesc.M)))
|
||||||
|
{
|
||||||
|
Invoke(new Action(() => { cbt_RunStatusTran.BackColor = Color.Lime; }));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Invoke(new Action(() => { cbt_RunStatusTran.BackColor = Color.Gray; }));
|
||||||
|
}
|
||||||
|
|
||||||
|
//毛刷1运行状态
|
||||||
|
if (Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("Hairbrush1Selection", PlcItemTypeDesc.M)))
|
||||||
|
{
|
||||||
|
Invoke(new Action(() => { cbt_Brush1StatusTran.BackColor = Color.Lime; }));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Invoke(new Action(() => { cbt_Brush1StatusTran.BackColor = Color.Gray; }));
|
||||||
|
}
|
||||||
|
|
||||||
|
//毛刷2启用状态
|
||||||
|
|
||||||
|
if (Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("Hairbrush2Selection", PlcItemTypeDesc.M)))
|
||||||
|
{
|
||||||
|
Invoke(new Action(() => { cbt_Brush2StatusTran.BackColor = Color.Lime; }));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Invoke(new Action(() => { cbt_Brush2StatusTran.BackColor = Color.Gray; }));
|
||||||
|
}
|
||||||
|
//毛刷3启用状态
|
||||||
|
if (Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("Hairbrush3Selection", PlcItemTypeDesc.M)))
|
||||||
|
{
|
||||||
|
Invoke(new Action(() => { cbt_Brush3StatusTran.BackColor = Color.Lime; }));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Invoke(new Action(() => { cbt_Brush3StatusTran.BackColor = Color.Gray; }));
|
||||||
|
}
|
||||||
|
|
||||||
|
if (GlobalHelper.CanOperate)
|
||||||
|
{
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
catch
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
Thread.Sleep(50);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbtn_Pass_Yes_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
//自检结束后发送停止检测信号
|
||||||
|
PlcOperationHelper.Instance.WritePlcItem("SelfCheckFlag", "False", PlcItemTypeDesc.M);
|
||||||
|
//自检通过后,发送检测通过信号
|
||||||
|
PlcOperationHelper.Instance.WritePlcItem("SelfCheckPassFlag", "True", PlcItemTypeDesc.M);
|
||||||
|
//系统默认进入自动模式
|
||||||
|
PlcOperationHelper.Instance.WritePlcItem("ManualOrAuto", "False", PlcItemTypeDesc.M);
|
||||||
|
//GlobalHelper.MainForm.navigatorMain.SetNavPage(Domain.Enums.EnumFormType.MainDetail);
|
||||||
|
|
||||||
|
frmMainNew.SwitchFrmMenu(EnumFormType.MainDetail, true);
|
||||||
|
//frmMainNew.SwitchFrmMenu(EnumFormType.IoMonitor, false);
|
||||||
|
GlobalHelper.CanOperate = true;
|
||||||
|
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(ex.Message);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbtn_Pass_No_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
//自检结束后发送停止检测信号
|
||||||
|
PlcOperationHelper.Instance.WritePlcItem("SelfCheckFlag", "False", PlcItemTypeDesc.M);
|
||||||
|
//自检通过后,发送检测通过信号
|
||||||
|
PlcOperationHelper.Instance.WritePlcItem("SelfCheckPassFlag", "False", PlcItemTypeDesc.M);
|
||||||
|
//测试未通过,请检查并重新测试
|
||||||
|
GlobalHelper.CanOperate = false;
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("测试未通过,请检查设备并重新测试!!", "NoPassShowMsg"));
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(ex.Message);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void cbt_StartTran_Click_1(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (swtbtn_brush1.L_IsOpen || swtbtn_brush2.L_IsOpen || swtbtn_brush3.L_IsOpen)
|
||||||
|
{
|
||||||
|
if (!Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("SelfCheckFlag", PlcItemTypeDesc.M)))
|
||||||
|
{
|
||||||
|
PlcOperationHelper.Instance.WritePlcItem("SelfCheckFlag", "True", PlcItemTypeDesc.M);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show("Press Yes or No First !");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show("Brush Need to be Selected First!");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
catch (Exception)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void swtbtn_brush3_LSwitched(object sender, LEventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (!PlcOperationHelper.Instance.isConn)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show("The PLC is disconnected and unable to operate the equipment.");
|
||||||
|
swtbtn_brush3.L_IsOpen = false;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
//选中状态,并且跟当前状态有差别则发送选中状态
|
||||||
|
if (swtbtn_brush3.L_IsOpen)
|
||||||
|
{
|
||||||
|
PlcOperationHelper.Instance.WritePlcItem("Hairbrush3Selection", "True", PlcItemTypeDesc.M);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
PlcOperationHelper.Instance.WritePlcItem("Hairbrush3Selection", "False", PlcItemTypeDesc.M);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
catch (Exception)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
120
CleanMachineHMI/FrmUserControl/frmMechineCheck.resx
Normal file
@@ -0,0 +1,120 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
</root>
|
||||||
339
CleanMachineHMI/FrmUserControl/frmParamater.Designer.cs
generated
Normal file
@@ -0,0 +1,339 @@
|
|||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
partial class frmParamater
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 必需的设计器变量。
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清理所有正在使用的资源。
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region 组件设计器生成的代码
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设计器支持所需的方法 - 不要修改
|
||||||
|
/// 使用代码编辑器修改此方法的内容。
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
this.kryptonPanel2 = new ComponentFactory.Krypton.Toolkit.KryptonPanel();
|
||||||
|
this.kryptonGroupBox3 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.kryptonDataGridView1 = new ComponentFactory.Krypton.Toolkit.KryptonDataGridView();
|
||||||
|
this.kryptonGroupBox4 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.kryptonButton1 = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kbt_Reset = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Query = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Edit = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kdtp_CreateEndTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kdtp_CreateStartTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kryptonLabel2 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel5 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.ktb_ParamaterCode = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kryptonLabel4 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel3 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.ktb_ParamaterName = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel2)).BeginInit();
|
||||||
|
this.kryptonPanel2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox3)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox3.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox3.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox3.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonDataGridView1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox4)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox4.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox4.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox4.SuspendLayout();
|
||||||
|
this.tableLayoutPanel2.SuspendLayout();
|
||||||
|
this.tableLayoutPanel1.SuspendLayout();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// kryptonPanel2
|
||||||
|
//
|
||||||
|
this.kryptonPanel2.Controls.Add(this.kryptonGroupBox3);
|
||||||
|
this.kryptonPanel2.Controls.Add(this.kryptonGroupBox4);
|
||||||
|
this.kryptonPanel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonPanel2.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonPanel2.Name = "kryptonPanel2";
|
||||||
|
this.kryptonPanel2.Size = new System.Drawing.Size(1024, 672);
|
||||||
|
this.kryptonPanel2.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox3
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox3.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowOnly;
|
||||||
|
this.kryptonGroupBox3.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox3.CaptionStyle = ComponentFactory.Krypton.Toolkit.LabelStyle.NormalControl;
|
||||||
|
this.kryptonGroupBox3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonGroupBox3.Location = new System.Drawing.Point(0, 150);
|
||||||
|
this.kryptonGroupBox3.Name = "kryptonGroupBox3";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox3.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox3.Panel.Controls.Add(this.kryptonDataGridView1);
|
||||||
|
this.kryptonGroupBox3.Size = new System.Drawing.Size(1024, 522);
|
||||||
|
this.kryptonGroupBox3.TabIndex = 6;
|
||||||
|
this.kryptonGroupBox3.Values.Heading = "数据区:";
|
||||||
|
//
|
||||||
|
// kryptonDataGridView1
|
||||||
|
//
|
||||||
|
this.kryptonDataGridView1.AllowUserToAddRows = false;
|
||||||
|
this.kryptonDataGridView1.AllowUserToDeleteRows = false;
|
||||||
|
this.kryptonDataGridView1.AllowUserToResizeRows = false;
|
||||||
|
this.kryptonDataGridView1.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
|
||||||
|
this.kryptonDataGridView1.DataMember = "TestData";
|
||||||
|
this.kryptonDataGridView1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonDataGridView1.GridStyles.Style = ComponentFactory.Krypton.Toolkit.DataGridViewStyle.Mixed;
|
||||||
|
this.kryptonDataGridView1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonDataGridView1.MultiSelect = false;
|
||||||
|
this.kryptonDataGridView1.Name = "kryptonDataGridView1";
|
||||||
|
this.kryptonDataGridView1.ReadOnly = true;
|
||||||
|
this.kryptonDataGridView1.RowHeadersVisible = false;
|
||||||
|
this.kryptonDataGridView1.RowHeadersWidth = 100;
|
||||||
|
this.kryptonDataGridView1.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
|
||||||
|
this.kryptonDataGridView1.Size = new System.Drawing.Size(1020, 500);
|
||||||
|
this.kryptonDataGridView1.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox4
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox4.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox4.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.kryptonGroupBox4.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonGroupBox4.Name = "kryptonGroupBox4";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox4.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox4.Panel.Controls.Add(this.tableLayoutPanel2);
|
||||||
|
this.kryptonGroupBox4.Panel.Controls.Add(this.tableLayoutPanel1);
|
||||||
|
this.kryptonGroupBox4.Size = new System.Drawing.Size(1024, 150);
|
||||||
|
this.kryptonGroupBox4.TabIndex = 0;
|
||||||
|
this.kryptonGroupBox4.Values.Heading = "查询操作:";
|
||||||
|
//
|
||||||
|
// kryptonButton1
|
||||||
|
//
|
||||||
|
this.kryptonButton1.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kryptonButton1.Name = "kryptonButton1";
|
||||||
|
this.kryptonButton1.Size = new System.Drawing.Size(154, 35);
|
||||||
|
this.kryptonButton1.TabIndex = 7;
|
||||||
|
this.kryptonButton1.Values.Text = "出料运行方向切换";
|
||||||
|
this.kryptonButton1.Click += new System.EventHandler(this.kryptonButton1_Click);
|
||||||
|
//
|
||||||
|
// tableLayoutPanel2
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.tableLayoutPanel2.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel2.ColumnCount = 4;
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 160F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33444F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33444F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33112F));
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kryptonButton1, 0, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Reset, 3, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Query, 2, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Edit, 1, 0);
|
||||||
|
this.tableLayoutPanel2.Location = new System.Drawing.Point(605, 78);
|
||||||
|
this.tableLayoutPanel2.Name = "tableLayoutPanel2";
|
||||||
|
this.tableLayoutPanel2.RowCount = 1;
|
||||||
|
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||||
|
this.tableLayoutPanel2.Size = new System.Drawing.Size(415, 41);
|
||||||
|
this.tableLayoutPanel2.TabIndex = 6;
|
||||||
|
//
|
||||||
|
// kbt_Reset
|
||||||
|
//
|
||||||
|
this.kbt_Reset.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Reset.Location = new System.Drawing.Point(333, 3);
|
||||||
|
this.kbt_Reset.Name = "kbt_Reset";
|
||||||
|
this.kbt_Reset.Size = new System.Drawing.Size(79, 35);
|
||||||
|
this.kbt_Reset.TabIndex = 0;
|
||||||
|
this.kbt_Reset.Tag = "show";
|
||||||
|
this.kbt_Reset.Values.Text = "重置条件";
|
||||||
|
this.kbt_Reset.Click += new System.EventHandler(this.kbt_Reset_Click);
|
||||||
|
//
|
||||||
|
// kbt_Query
|
||||||
|
//
|
||||||
|
this.kbt_Query.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Query.Location = new System.Drawing.Point(248, 3);
|
||||||
|
this.kbt_Query.Name = "kbt_Query";
|
||||||
|
this.kbt_Query.Size = new System.Drawing.Size(79, 35);
|
||||||
|
this.kbt_Query.TabIndex = 0;
|
||||||
|
this.kbt_Query.Tag = "show";
|
||||||
|
this.kbt_Query.Values.Text = "查询";
|
||||||
|
this.kbt_Query.Click += new System.EventHandler(this.kbt_Query_Click);
|
||||||
|
//
|
||||||
|
// kbt_Edit
|
||||||
|
//
|
||||||
|
this.kbt_Edit.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Edit.Location = new System.Drawing.Point(163, 3);
|
||||||
|
this.kbt_Edit.Name = "kbt_Edit";
|
||||||
|
this.kbt_Edit.Size = new System.Drawing.Size(79, 35);
|
||||||
|
this.kbt_Edit.TabIndex = 0;
|
||||||
|
this.kbt_Edit.Values.Text = "编辑";
|
||||||
|
this.kbt_Edit.Click += new System.EventHandler(this.kbt_Edit_Click);
|
||||||
|
//
|
||||||
|
// tableLayoutPanel1
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel1.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel1.ColumnCount = 4;
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 120F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 120F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateEndTime, 3, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_CreateStartTime, 1, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel2, 0, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel5, 2, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_ParamaterCode, 1, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel4, 0, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel3, 2, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_ParamaterName, 3, 0);
|
||||||
|
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||||
|
this.tableLayoutPanel1.RowCount = 2;
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Size = new System.Drawing.Size(1020, 72);
|
||||||
|
this.tableLayoutPanel1.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// kdtp_CreateEndTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateEndTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateEndTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateEndTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateEndTime.Location = new System.Drawing.Point(702, 43);
|
||||||
|
this.kdtp_CreateEndTime.Name = "kdtp_CreateEndTime";
|
||||||
|
this.kdtp_CreateEndTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateEndTime.Size = new System.Drawing.Size(246, 21);
|
||||||
|
this.kdtp_CreateEndTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kdtp_CreateStartTime
|
||||||
|
//
|
||||||
|
this.kdtp_CreateStartTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_CreateStartTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_CreateStartTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_CreateStartTime.Location = new System.Drawing.Point(192, 43);
|
||||||
|
this.kdtp_CreateStartTime.Name = "kdtp_CreateStartTime";
|
||||||
|
this.kdtp_CreateStartTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_CreateStartTime.Size = new System.Drawing.Size(246, 21);
|
||||||
|
this.kdtp_CreateStartTime.TabIndex = 7;
|
||||||
|
//
|
||||||
|
// kryptonLabel2
|
||||||
|
//
|
||||||
|
this.kryptonLabel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel2.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kryptonLabel2.Name = "kryptonLabel2";
|
||||||
|
this.kryptonLabel2.Size = new System.Drawing.Size(114, 30);
|
||||||
|
this.kryptonLabel2.TabIndex = 4;
|
||||||
|
this.kryptonLabel2.Values.Text = "参数编码:";
|
||||||
|
//
|
||||||
|
// kryptonLabel5
|
||||||
|
//
|
||||||
|
this.kryptonLabel5.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kryptonLabel5.Location = new System.Drawing.Point(558, 44);
|
||||||
|
this.kryptonLabel5.Name = "kryptonLabel5";
|
||||||
|
this.kryptonLabel5.Size = new System.Drawing.Size(23, 20);
|
||||||
|
this.kryptonLabel5.TabIndex = 4;
|
||||||
|
this.kryptonLabel5.Values.Text = "至";
|
||||||
|
//
|
||||||
|
// ktb_ParamaterCode
|
||||||
|
//
|
||||||
|
this.ktb_ParamaterCode.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_ParamaterCode.Location = new System.Drawing.Point(192, 6);
|
||||||
|
this.ktb_ParamaterCode.Name = "ktb_ParamaterCode";
|
||||||
|
this.ktb_ParamaterCode.Size = new System.Drawing.Size(246, 23);
|
||||||
|
this.ktb_ParamaterCode.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// kryptonLabel4
|
||||||
|
//
|
||||||
|
this.kryptonLabel4.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel4.Location = new System.Drawing.Point(3, 39);
|
||||||
|
this.kryptonLabel4.Name = "kryptonLabel4";
|
||||||
|
this.kryptonLabel4.Size = new System.Drawing.Size(114, 30);
|
||||||
|
this.kryptonLabel4.TabIndex = 4;
|
||||||
|
this.kryptonLabel4.Values.Text = "创建时间:";
|
||||||
|
//
|
||||||
|
// kryptonLabel3
|
||||||
|
//
|
||||||
|
this.kryptonLabel3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel3.Location = new System.Drawing.Point(513, 3);
|
||||||
|
this.kryptonLabel3.Name = "kryptonLabel3";
|
||||||
|
this.kryptonLabel3.Size = new System.Drawing.Size(114, 30);
|
||||||
|
this.kryptonLabel3.TabIndex = 4;
|
||||||
|
this.kryptonLabel3.Values.Text = "参数名称:";
|
||||||
|
//
|
||||||
|
// ktb_ParamaterName
|
||||||
|
//
|
||||||
|
this.ktb_ParamaterName.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_ParamaterName.Location = new System.Drawing.Point(702, 6);
|
||||||
|
this.ktb_ParamaterName.Name = "ktb_ParamaterName";
|
||||||
|
this.ktb_ParamaterName.Size = new System.Drawing.Size(246, 23);
|
||||||
|
this.ktb_ParamaterName.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// frmParamater
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.Controls.Add(this.kryptonPanel2);
|
||||||
|
this.Name = "frmParamater";
|
||||||
|
this.Size = new System.Drawing.Size(1024, 672);
|
||||||
|
this.Load += new System.EventHandler(this.frmParamater_Load);
|
||||||
|
this.Click += new System.EventHandler(this.frmParamater_Load);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonPanel2)).EndInit();
|
||||||
|
this.kryptonPanel2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox3.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox3.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox3)).EndInit();
|
||||||
|
this.kryptonGroupBox3.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonDataGridView1)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox4.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox4.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox4)).EndInit();
|
||||||
|
this.kryptonGroupBox4.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel2.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.PerformLayout();
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonPanel kryptonPanel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox3;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridView kryptonDataGridView1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox4;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Reset;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Query;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Edit;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateEndTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_CreateStartTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel5;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_ParamaterCode;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel4;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel3;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_ParamaterName;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kryptonButton1;
|
||||||
|
}
|
||||||
|
}
|
||||||
161
CleanMachineHMI/FrmUserControl/frmParamater.cs
Normal file
@@ -0,0 +1,161 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.frmChild;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using LeadDataBaseUtility;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
[FormType(EnumFormType.Parameter)]
|
||||||
|
public partial class frmParamater : UserControl
|
||||||
|
{
|
||||||
|
private DataTable _InfoLanguageTextList;
|
||||||
|
public delegate void dlgRefreshFrmHost();
|
||||||
|
public static dlgRefreshFrmHost RefreshFrmHost;
|
||||||
|
|
||||||
|
public frmParamater()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
_InfoLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public void Init()
|
||||||
|
{
|
||||||
|
var sql = $@"select PARAMETER_ID 序号,PARAMETER_CODE 参数编码,PARAMETER_NAME 参数名称,PARAMETER_VALUE 参数值,CREATE_TIME 创建时间 from SYS_PARAMETER where USED_FLAG=1 and DEL_FLAG=0 ";
|
||||||
|
if (!string.IsNullOrEmpty(ktb_ParamaterCode.Text))
|
||||||
|
{
|
||||||
|
sql += $" AND PARAMETER_CODE LIKE '%{ktb_ParamaterCode.Text}%'";
|
||||||
|
}
|
||||||
|
if (!string.IsNullOrEmpty(ktb_ParamaterName.Text))
|
||||||
|
{
|
||||||
|
sql += $" AND PARAMETER_NAME LIKE '%{ktb_ParamaterName.Text}%'";
|
||||||
|
}
|
||||||
|
if (kdtp_CreateStartTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND CREATE_TIME >= '{kdtp_CreateStartTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
if (kdtp_CreateEndTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $" AND CREATE_TIME <= '{kdtp_CreateEndTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}'";
|
||||||
|
}
|
||||||
|
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
|
||||||
|
kryptonDataGridView1.Columns.Clear();
|
||||||
|
kryptonDataGridView1.DataSource = dt;
|
||||||
|
kryptonDataGridView1.SetDataViewColumnText(this.Name, GlobalHelper.LanguageCode);
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
private void txt_GotFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.ShowInputPanel();
|
||||||
|
}
|
||||||
|
private void txt_LostFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.HideInputPanel();
|
||||||
|
}
|
||||||
|
private void InitControlEvent()
|
||||||
|
{
|
||||||
|
ktb_ParamaterCode.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_ParamaterCode.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
|
||||||
|
ktb_ParamaterName.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_ParamaterName.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
}
|
||||||
|
|
||||||
|
private void frmParamater_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
InitControlEvent();
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
this.SetFormControlText(GlobalHelper.LanguageCode);
|
||||||
|
RefreshFrmHost = new dlgRefreshFrmHost(Init);
|
||||||
|
Init();
|
||||||
|
foreach (Control item in tableLayoutPanel2.Controls)
|
||||||
|
{
|
||||||
|
if (item.Tag == null)
|
||||||
|
{
|
||||||
|
DataRow[] drs = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{this.Name}' AND MENU_PID = '-1'");
|
||||||
|
DataRow[] drs1 = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{item.Name}' AND MENU_PID = '{drs[0]["MENU_ID"]}'");
|
||||||
|
if (drs1.Length > 0)
|
||||||
|
{
|
||||||
|
item.Enabled = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
item.Enabled = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kryptonGroupBox3.Focus();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("加载系统参数界面发生异常", "LoadSysParamaterExp") + $":【{ex.Message}】!");
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Query_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
Init();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("查询系统参数数据发生异常", "QuerySysParamaterData") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Reset_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
ktb_ParamaterCode.Text = "";
|
||||||
|
ktb_ParamaterName.Text = "";
|
||||||
|
kdtp_CreateStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_CreateEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_CreateStartTime.Checked = false;
|
||||||
|
kdtp_CreateEndTime.Checked = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Edit_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (kryptonDataGridView1.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
frmEditParamater frm = new frmEditParamater();
|
||||||
|
frm.ParamaterId = kryptonDataGridView1.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要编辑的参数信息数据行!", "SelectWantToEditRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kryptonButton1_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
//if (!PlcOperationHelper.Instance.isConn)
|
||||||
|
//{
|
||||||
|
// KryptonMessageBox.Show("The PLC is disconnected and unable to operate the equipment.");
|
||||||
|
// return;
|
||||||
|
//}
|
||||||
|
frmSwitchRunDirection frm = new frmSwitchRunDirection();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
120
CleanMachineHMI/FrmUserControl/frmParamater.resx
Normal file
@@ -0,0 +1,120 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
</root>
|
||||||
297
CleanMachineHMI/FrmUserControl/frmPlcAlarmLog.Designer.cs
generated
Normal file
@@ -0,0 +1,297 @@
|
|||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
partial class frmPlcAlarmLog
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 必需的设计器变量。
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清理所有正在使用的资源。
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region 组件设计器生成的代码
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设计器支持所需的方法 - 不要修改
|
||||||
|
/// 使用代码编辑器修改此方法的内容。
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
this.kryptonDataGridView1 = new ComponentFactory.Krypton.Toolkit.KryptonDataGridView();
|
||||||
|
this.kryptonGroupBox2 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kryptonLabel1 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel4 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.ktb_plcMsg = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kcmb_plcAlarmStatus = new ComponentFactory.Krypton.Toolkit.KryptonComboBox();
|
||||||
|
this.kryptonLabel2 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kcmb_plcAlarmHandleResult = new ComponentFactory.Krypton.Toolkit.KryptonComboBox();
|
||||||
|
this.kbt_Reset = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Query = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kbtn_UuivertorAlarmClear = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonGroupBox1 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonDataGridView1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox2.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox2.SuspendLayout();
|
||||||
|
this.tableLayoutPanel1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_plcAlarmStatus)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_plcAlarmHandleResult)).BeginInit();
|
||||||
|
this.tableLayoutPanel2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox1.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox1.SuspendLayout();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// kryptonDataGridView1
|
||||||
|
//
|
||||||
|
this.kryptonDataGridView1.AllowUserToAddRows = false;
|
||||||
|
this.kryptonDataGridView1.AllowUserToDeleteRows = false;
|
||||||
|
this.kryptonDataGridView1.AllowUserToResizeColumns = false;
|
||||||
|
this.kryptonDataGridView1.AllowUserToResizeRows = false;
|
||||||
|
this.kryptonDataGridView1.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.AllCells;
|
||||||
|
this.kryptonDataGridView1.ClipboardCopyMode = System.Windows.Forms.DataGridViewClipboardCopyMode.EnableWithoutHeaderText;
|
||||||
|
this.kryptonDataGridView1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonDataGridView1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonDataGridView1.MultiSelect = false;
|
||||||
|
this.kryptonDataGridView1.Name = "kryptonDataGridView1";
|
||||||
|
this.kryptonDataGridView1.RowTemplate.Height = 23;
|
||||||
|
this.kryptonDataGridView1.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
|
||||||
|
this.kryptonDataGridView1.Size = new System.Drawing.Size(1020, 522);
|
||||||
|
this.kryptonDataGridView1.TabIndex = 0;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonGroupBox2.Location = new System.Drawing.Point(0, 126);
|
||||||
|
this.kryptonGroupBox2.Name = "kryptonGroupBox2";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonDataGridView1);
|
||||||
|
this.kryptonGroupBox2.Size = new System.Drawing.Size(1024, 546);
|
||||||
|
this.kryptonGroupBox2.TabIndex = 5;
|
||||||
|
this.kryptonGroupBox2.Values.Heading = "数据区:";
|
||||||
|
//
|
||||||
|
// tableLayoutPanel1
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel1.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel1.ColumnCount = 6;
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 120F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 120F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 150F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 20F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 20F));
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel1, 0, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel4, 2, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_plcMsg, 1, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kcmb_plcAlarmStatus, 3, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel2, 4, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kcmb_plcAlarmHandleResult, 5, 0);
|
||||||
|
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||||
|
this.tableLayoutPanel1.RowCount = 1;
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||||
|
this.tableLayoutPanel1.Size = new System.Drawing.Size(1020, 38);
|
||||||
|
this.tableLayoutPanel1.TabIndex = 0;
|
||||||
|
//
|
||||||
|
// kryptonLabel1
|
||||||
|
//
|
||||||
|
this.kryptonLabel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel1.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kryptonLabel1.Name = "kryptonLabel1";
|
||||||
|
this.kryptonLabel1.Size = new System.Drawing.Size(114, 32);
|
||||||
|
this.kryptonLabel1.TabIndex = 1;
|
||||||
|
this.kryptonLabel1.Values.Text = "报警信息:";
|
||||||
|
//
|
||||||
|
// kryptonLabel4
|
||||||
|
//
|
||||||
|
this.kryptonLabel4.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel4.Location = new System.Drawing.Point(333, 3);
|
||||||
|
this.kryptonLabel4.Name = "kryptonLabel4";
|
||||||
|
this.kryptonLabel4.Size = new System.Drawing.Size(114, 32);
|
||||||
|
this.kryptonLabel4.TabIndex = 1;
|
||||||
|
this.kryptonLabel4.Values.Text = "报警状态:";
|
||||||
|
//
|
||||||
|
// ktb_plcMsg
|
||||||
|
//
|
||||||
|
this.ktb_plcMsg.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_plcMsg.Location = new System.Drawing.Point(132, 7);
|
||||||
|
this.ktb_plcMsg.Name = "ktb_plcMsg";
|
||||||
|
this.ktb_plcMsg.Size = new System.Drawing.Size(186, 23);
|
||||||
|
this.ktb_plcMsg.TabIndex = 2;
|
||||||
|
//
|
||||||
|
// kcmb_plcAlarmStatus
|
||||||
|
//
|
||||||
|
this.kcmb_plcAlarmStatus.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kcmb_plcAlarmStatus.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
|
this.kcmb_plcAlarmStatus.DropDownWidth = 248;
|
||||||
|
this.kcmb_plcAlarmStatus.Items.AddRange(new object[] {
|
||||||
|
"请选择",
|
||||||
|
"正在报警",
|
||||||
|
"报警结束"});
|
||||||
|
this.kcmb_plcAlarmStatus.Location = new System.Drawing.Point(462, 8);
|
||||||
|
this.kcmb_plcAlarmStatus.Name = "kcmb_plcAlarmStatus";
|
||||||
|
this.kcmb_plcAlarmStatus.Size = new System.Drawing.Size(186, 21);
|
||||||
|
this.kcmb_plcAlarmStatus.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// kryptonLabel2
|
||||||
|
//
|
||||||
|
this.kryptonLabel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel2.Location = new System.Drawing.Point(663, 3);
|
||||||
|
this.kryptonLabel2.Name = "kryptonLabel2";
|
||||||
|
this.kryptonLabel2.Size = new System.Drawing.Size(144, 32);
|
||||||
|
this.kryptonLabel2.TabIndex = 1;
|
||||||
|
this.kryptonLabel2.Values.Text = "报警处理结果:";
|
||||||
|
//
|
||||||
|
// kcmb_plcAlarmHandleResult
|
||||||
|
//
|
||||||
|
this.kcmb_plcAlarmHandleResult.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kcmb_plcAlarmHandleResult.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
|
this.kcmb_plcAlarmHandleResult.DropDownWidth = 248;
|
||||||
|
this.kcmb_plcAlarmHandleResult.Items.AddRange(new object[] {
|
||||||
|
"请选择",
|
||||||
|
"未处理",
|
||||||
|
"已处理"});
|
||||||
|
this.kcmb_plcAlarmHandleResult.Location = new System.Drawing.Point(821, 8);
|
||||||
|
this.kcmb_plcAlarmHandleResult.Name = "kcmb_plcAlarmHandleResult";
|
||||||
|
this.kcmb_plcAlarmHandleResult.Size = new System.Drawing.Size(187, 21);
|
||||||
|
this.kcmb_plcAlarmHandleResult.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// kbt_Reset
|
||||||
|
//
|
||||||
|
this.kbt_Reset.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Reset.Location = new System.Drawing.Point(285, 3);
|
||||||
|
this.kbt_Reset.Name = "kbt_Reset";
|
||||||
|
this.kbt_Reset.Size = new System.Drawing.Size(137, 35);
|
||||||
|
this.kbt_Reset.TabIndex = 0;
|
||||||
|
this.kbt_Reset.Tag = "show";
|
||||||
|
this.kbt_Reset.Values.Text = "重置条件";
|
||||||
|
this.kbt_Reset.Click += new System.EventHandler(this.kbt_Reset_Click);
|
||||||
|
//
|
||||||
|
// kbt_Query
|
||||||
|
//
|
||||||
|
this.kbt_Query.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Query.Location = new System.Drawing.Point(144, 3);
|
||||||
|
this.kbt_Query.Name = "kbt_Query";
|
||||||
|
this.kbt_Query.Size = new System.Drawing.Size(135, 35);
|
||||||
|
this.kbt_Query.TabIndex = 0;
|
||||||
|
this.kbt_Query.Tag = "show";
|
||||||
|
this.kbt_Query.Values.Text = "查询";
|
||||||
|
this.kbt_Query.Click += new System.EventHandler(this.kbt_Query_Click);
|
||||||
|
//
|
||||||
|
// tableLayoutPanel2
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.tableLayoutPanel2.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel2.ColumnCount = 3;
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbtn_UuivertorAlarmClear, 0, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Reset, 2, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Query, 1, 0);
|
||||||
|
this.tableLayoutPanel2.Location = new System.Drawing.Point(585, 49);
|
||||||
|
this.tableLayoutPanel2.Name = "tableLayoutPanel2";
|
||||||
|
this.tableLayoutPanel2.RowCount = 1;
|
||||||
|
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||||
|
this.tableLayoutPanel2.Size = new System.Drawing.Size(425, 41);
|
||||||
|
this.tableLayoutPanel2.TabIndex = 1;
|
||||||
|
//
|
||||||
|
// kbtn_UuivertorAlarmClear
|
||||||
|
//
|
||||||
|
this.kbtn_UuivertorAlarmClear.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbtn_UuivertorAlarmClear.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kbtn_UuivertorAlarmClear.Name = "kbtn_UuivertorAlarmClear";
|
||||||
|
this.kbtn_UuivertorAlarmClear.Size = new System.Drawing.Size(135, 35);
|
||||||
|
this.kbtn_UuivertorAlarmClear.TabIndex = 2;
|
||||||
|
this.kbtn_UuivertorAlarmClear.Values.Text = "变频器报警清除";
|
||||||
|
this.kbtn_UuivertorAlarmClear.MouseDown += new System.Windows.Forms.MouseEventHandler(this.kbtn_UuivertorAlarmClear_MouseDown);
|
||||||
|
this.kbtn_UuivertorAlarmClear.MouseUp += new System.Windows.Forms.MouseEventHandler(this.kbtn_UuivertorAlarmClear_MouseUp);
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.kryptonGroupBox1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonGroupBox1.Name = "kryptonGroupBox1";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.tableLayoutPanel2);
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.tableLayoutPanel1);
|
||||||
|
this.kryptonGroupBox1.Size = new System.Drawing.Size(1024, 126);
|
||||||
|
this.kryptonGroupBox1.TabIndex = 4;
|
||||||
|
this.kryptonGroupBox1.Values.Heading = "查询操作";
|
||||||
|
//
|
||||||
|
// frmPlcAlarmLog
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.Controls.Add(this.kryptonGroupBox2);
|
||||||
|
this.Controls.Add(this.kryptonGroupBox1);
|
||||||
|
this.Name = "frmPlcAlarmLog";
|
||||||
|
this.Size = new System.Drawing.Size(1024, 672);
|
||||||
|
this.Load += new System.EventHandler(this.frmPlcAlarmLog_Load);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonDataGridView1)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox2.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).EndInit();
|
||||||
|
this.kryptonGroupBox2.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_plcAlarmStatus)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_plcAlarmHandleResult)).EndInit();
|
||||||
|
this.tableLayoutPanel2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox1.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).EndInit();
|
||||||
|
this.kryptonGroupBox1.ResumeLayout(false);
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridView kryptonDataGridView1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox2;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel4;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_plcMsg;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonComboBox kcmb_plcAlarmStatus;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonComboBox kcmb_plcAlarmHandleResult;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Reset;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Query;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbtn_UuivertorAlarmClear;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox1;
|
||||||
|
}
|
||||||
|
}
|
||||||
272
CleanMachineHMI/FrmUserControl/frmPlcAlarmLog.cs
Normal file
@@ -0,0 +1,272 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using LeadDataBaseUtility;
|
||||||
|
using NX_LogUtility;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
[FormType(EnumFormType.PlcAlarmLog)]
|
||||||
|
public partial class frmPlcAlarmLog : UserControl
|
||||||
|
{
|
||||||
|
public frmPlcAlarmLog()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
_ComboBoxLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode, "KryptonComboBox");
|
||||||
|
_InfoLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
private DataTable _ComboBoxLanguageTextList;
|
||||||
|
private DataTable _InfoLanguageTextList;
|
||||||
|
|
||||||
|
public delegate void dlgRefreshFrmHost(bool isContainHisData);
|
||||||
|
public static dlgRefreshFrmHost RefreshFrmHost;
|
||||||
|
private void kbt_Query_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
RefreshPlcData(true);
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("加载报警数据界面发生异常", "LoadFrmPlcAlarmExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Reset_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
kcmb_plcAlarmStatus.SelectedIndex = 0;
|
||||||
|
kcmb_plcAlarmHandleResult.SelectedIndex = 0;
|
||||||
|
ktb_plcMsg.Text = "";
|
||||||
|
}
|
||||||
|
private void txt_GotFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.ShowInputPanel();
|
||||||
|
}
|
||||||
|
private void txt_LostFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.HideInputPanel();
|
||||||
|
}
|
||||||
|
private void InitControlEvent()
|
||||||
|
{
|
||||||
|
ktb_plcMsg.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_plcMsg.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
}
|
||||||
|
|
||||||
|
private void frmPlcAlarmLog_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
InitControlEvent();
|
||||||
|
this.SetFormControlText(GlobalHelper.LanguageCode);
|
||||||
|
kcmb_plcAlarmStatus.Items.Clear();
|
||||||
|
if (GlobalHelper.LanguageCode == "English")
|
||||||
|
{
|
||||||
|
foreach (DataRow item in _ComboBoxLanguageTextList.GetComBoboxItemArr(kcmb_plcAlarmStatus.Name, "KryptonComboBox"))
|
||||||
|
{
|
||||||
|
kcmb_plcAlarmStatus.Items.Add(item["CONTROL_NAME"].ToString());
|
||||||
|
}
|
||||||
|
kcmb_plcAlarmHandleResult.Items.Clear();
|
||||||
|
foreach (DataRow item in _ComboBoxLanguageTextList.GetComBoboxItemArr(kcmb_plcAlarmHandleResult.Name, "KryptonComboBox"))
|
||||||
|
{
|
||||||
|
kcmb_plcAlarmHandleResult.Items.Add(item["CONTROL_NAME"].ToString());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kcmb_plcAlarmStatus.SelectedIndex = 0;
|
||||||
|
kcmb_plcAlarmHandleResult.SelectedIndex = 0;
|
||||||
|
RefreshFrmHost = new dlgRefreshFrmHost(RefreshPlcData);
|
||||||
|
foreach (Control item in tableLayoutPanel2.Controls)
|
||||||
|
{
|
||||||
|
if (item.Tag == null)
|
||||||
|
{
|
||||||
|
DataRow[] drs = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{this.Name}' AND MENU_PID = '-1'");
|
||||||
|
DataRow[] drs1 = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{item.Name}' AND MENU_PID = '{drs[0]["MENU_ID"]}'");
|
||||||
|
if (drs1.Length > 0)
|
||||||
|
{
|
||||||
|
item.Enabled = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
item.Enabled = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kryptonGroupBox1.Focus();
|
||||||
|
}
|
||||||
|
private void RefreshPlcData(bool isContainHisData)
|
||||||
|
{
|
||||||
|
List<CM_WarningLogMd> tmpWarningLogList = new List<CM_WarningLogMd>();
|
||||||
|
tmpWarningLogList.AddRange(GlobalHelper.CmWarningLogMd_List);
|
||||||
|
if (isContainHisData)
|
||||||
|
{
|
||||||
|
string sql = $@"SELECT * FROM CM_WARNING_LOG";
|
||||||
|
DataTable dtHis = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
foreach (DataRow item in dtHis.Rows)
|
||||||
|
{
|
||||||
|
tmpWarningLogList.Add(new CM_WarningLogMd
|
||||||
|
{
|
||||||
|
WarningCode = item["WARNING_CODE"].ToString(),
|
||||||
|
WarningName = item["WARNING_NAME"].ToString(),
|
||||||
|
WarningType = item["WARNING_TYPE"].ToString(),
|
||||||
|
WarningMessage = item["WARNING_MESSAGE"].ToString(),
|
||||||
|
WarningTime = Convert.ToDateTime(item["WARNING_TIME"]),
|
||||||
|
PlcItemCode = item["PLC_ITEM_CODE"].ToString(),
|
||||||
|
WarningStatus = Convert.ToInt32(item["WARING_STATUS"]),
|
||||||
|
WarningHandleResult = Convert.ToInt32(item["WARNING_HANDLE_RESULT"]),
|
||||||
|
WarningHandleTime = Convert.ToDateTime(item["WARNING_HANDLE_TIME"]),
|
||||||
|
CreateBy = Convert.ToInt32(item["CREATE_BY"]),
|
||||||
|
CreateTime = Convert.ToDateTime(item["CREATE_TIME"]),
|
||||||
|
UpdateBy = Convert.ToInt32(item["UPDATE_BY"]),
|
||||||
|
UpdateTime = Convert.ToDateTime(item["UPDATE_TIME"]),
|
||||||
|
DataVersion = Convert.ToInt32(item["DATA_VERSION"]),
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (!string.IsNullOrEmpty(ktb_plcMsg.Text.Trim()))
|
||||||
|
{
|
||||||
|
tmpWarningLogList = tmpWarningLogList.FindAll(x => x.WarningCode.Contains(ktb_plcMsg.Text.Trim()) || x.WarningName.Contains(ktb_plcMsg.Text.Trim()));
|
||||||
|
}
|
||||||
|
if (tmpWarningLogList == null && tmpWarningLogList.Count > 0)
|
||||||
|
{
|
||||||
|
if (kcmb_plcAlarmStatus.SelectedIndex != 0)
|
||||||
|
{
|
||||||
|
tmpWarningLogList = tmpWarningLogList.FindAll(x => x.WarningStatus == (kcmb_plcAlarmStatus.SelectedIndex - 1));
|
||||||
|
}
|
||||||
|
if (tmpWarningLogList == null && tmpWarningLogList.Count > 0)
|
||||||
|
{
|
||||||
|
if (kcmb_plcAlarmHandleResult.SelectedIndex != 0)
|
||||||
|
{
|
||||||
|
tmpWarningLogList = tmpWarningLogList.FindAll(x => x.WarningHandleResult == (kcmb_plcAlarmHandleResult.SelectedIndex - 1));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (tmpWarningLogList != null && tmpWarningLogList.Count > 0)
|
||||||
|
{
|
||||||
|
tmpWarningLogList.OrderByDescending(x => x.WarningTime);
|
||||||
|
DataTable dt = new DataTable();
|
||||||
|
DataColumn dc1 = new DataColumn("序号", Type.GetType("System.Int32"));
|
||||||
|
DataColumn dc2 = new DataColumn("PLC变量地址", Type.GetType("System.String"));
|
||||||
|
DataColumn dc3 = new DataColumn("报警条码", Type.GetType("System.String"));
|
||||||
|
DataColumn dc4 = new DataColumn("报警内容", Type.GetType("System.String"));
|
||||||
|
DataColumn dc5 = new DataColumn("报警时间", Type.GetType("System.String"));
|
||||||
|
DataColumn dc6 = new DataColumn("报警状态", Type.GetType("System.String"));
|
||||||
|
DataColumn dc7 = new DataColumn("处理结果", Type.GetType("System.String"));
|
||||||
|
DataColumn dc8 = new DataColumn("处理时间", Type.GetType("System.String"));
|
||||||
|
DataColumn dc9 = new DataColumn("报警时长", Type.GetType("System.String"));
|
||||||
|
|
||||||
|
dt.Columns.Add(dc1);
|
||||||
|
dt.Columns.Add(dc2);
|
||||||
|
dt.Columns.Add(dc3);
|
||||||
|
dt.Columns.Add(dc4);
|
||||||
|
dt.Columns.Add(dc5);
|
||||||
|
dt.Columns.Add(dc6);
|
||||||
|
dt.Columns.Add(dc7);
|
||||||
|
dt.Columns.Add(dc8);
|
||||||
|
dt.Columns.Add(dc9);
|
||||||
|
int index = 1;
|
||||||
|
foreach (CM_WarningLogMd item in tmpWarningLogList)
|
||||||
|
{
|
||||||
|
DataRow dr = dt.NewRow();
|
||||||
|
dr["序号"] = index;
|
||||||
|
dr["PLC变量地址"] = item.PlcItemCode;
|
||||||
|
dr["报警条码"] = item.WarningCode;
|
||||||
|
dr["报警内容"] = item.WarningName;
|
||||||
|
dr["报警时间"] = item.WarningTime;
|
||||||
|
if (item.WarningStatus == 0)
|
||||||
|
{
|
||||||
|
//dr["报警状态"] = "正在报警";
|
||||||
|
dr["报警状态"] = "Occurrent Alarm";
|
||||||
|
dr["处理时间"] = "";
|
||||||
|
string dateDiff = null;
|
||||||
|
|
||||||
|
TimeSpan ts1 = new TimeSpan(item.WarningTime.Ticks);
|
||||||
|
TimeSpan ts2 = new TimeSpan(DateTime.Now.Ticks);
|
||||||
|
TimeSpan ts = ts1.Subtract(ts2).Duration();
|
||||||
|
dateDiff = ts.Days.ToString() + "天"
|
||||||
|
+ ts.Hours.ToString() + "小时"
|
||||||
|
+ ts.Minutes.ToString() + "分钟"
|
||||||
|
+ ts.Seconds.ToString() + "秒";
|
||||||
|
dr["报警时长"] = dateDiff;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
dr["报警状态"] = "Alarm Reset";
|
||||||
|
dr["处理时间"] = item.WarningHandleTime;
|
||||||
|
string dateDiff = null;
|
||||||
|
|
||||||
|
TimeSpan ts1 = new TimeSpan(item.WarningTime.Ticks);
|
||||||
|
TimeSpan ts2 = new TimeSpan(item.WarningHandleTime.Ticks);
|
||||||
|
TimeSpan ts = ts1.Subtract(ts2).Duration();
|
||||||
|
dateDiff = ts.Days.ToString() + "天"
|
||||||
|
+ ts.Hours.ToString() + "小时"
|
||||||
|
+ ts.Minutes.ToString() + "分钟"
|
||||||
|
+ ts.Seconds.ToString() + "秒"
|
||||||
|
+ ts.Milliseconds.ToString() + "毫秒";
|
||||||
|
dr["报警时长"] = dateDiff;
|
||||||
|
}
|
||||||
|
if (item.WarningHandleResult == 0)
|
||||||
|
{
|
||||||
|
//dr["处理结果"] = "未处理";
|
||||||
|
dr["处理结果"] = "Untreated";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
//dr["处理结果"] = "已处理";
|
||||||
|
dr["处理结果"] = "Handled";
|
||||||
|
}
|
||||||
|
dt.Rows.Add(dr);
|
||||||
|
index++;
|
||||||
|
}
|
||||||
|
dt.DefaultView.Sort = "报警时间 DESC";
|
||||||
|
dt = dt.DefaultView.ToTable();
|
||||||
|
kryptonDataGridView1.DataSource = dt;
|
||||||
|
kryptonDataGridView1.SetDataViewColumnText(this.Name, GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
kryptonDataGridView1.DataSource = null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbtn_UuivertorAlarmClear_MouseDown(object sender, MouseEventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (!PlcOperationHelper.Instance.isConn)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show("The PLC is disconnected and unable to operate the equipment.");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (PlcOperationHelper.Instance.WritePlcItem("FrequencyMacAlarmClear", "True", PlcItemTypeDesc.M))
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"用户:【{GlobalHelper.UserInfo.USER_NAME}】发送PLC变频器报警清除信号成功。", LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(ex.Message);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbtn_UuivertorAlarmClear_MouseUp(object sender, MouseEventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (PlcOperationHelper.Instance.WritePlcItem("FrequencyMacAlarmClear", "False", PlcItemTypeDesc.M))
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(ex.Message);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
120
CleanMachineHMI/FrmUserControl/frmPlcAlarmLog.resx
Normal file
@@ -0,0 +1,120 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
</root>
|
||||||
377
CleanMachineHMI/FrmUserControl/frmPlcItemConfig.Designer.cs
generated
Normal file
@@ -0,0 +1,377 @@
|
|||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
partial class frmPlcItemConfig
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 必需的设计器变量。
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清理所有正在使用的资源。
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region 组件设计器生成的代码
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设计器支持所需的方法 - 不要修改
|
||||||
|
/// 使用代码编辑器修改此方法的内容。
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
this.kryptonDataGridView1 = new ComponentFactory.Krypton.Toolkit.KryptonDataGridView();
|
||||||
|
this.kryptonGroupBox2 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.kryptonLabel1 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kryptonLabel2 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel3 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel4 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel5 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.ktb_plcMsg = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kcmb_plcItemType = new ComponentFactory.Krypton.Toolkit.KryptonComboBox();
|
||||||
|
this.kcmb_plcItemDateType = new ComponentFactory.Krypton.Toolkit.KryptonComboBox();
|
||||||
|
this.ktb_plcItemModbusAddress = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.ktb_plcItemPriAddress = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kbt_Add = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Reset = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Edit = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Delete = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kbt_Query = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonGroupBox1 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonDataGridView1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox2.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox2.SuspendLayout();
|
||||||
|
this.tableLayoutPanel1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_plcItemType)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_plcItemDateType)).BeginInit();
|
||||||
|
this.tableLayoutPanel2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox1.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox1.SuspendLayout();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// kryptonDataGridView1
|
||||||
|
//
|
||||||
|
this.kryptonDataGridView1.AllowUserToAddRows = false;
|
||||||
|
this.kryptonDataGridView1.AllowUserToDeleteRows = false;
|
||||||
|
this.kryptonDataGridView1.AllowUserToResizeColumns = false;
|
||||||
|
this.kryptonDataGridView1.AllowUserToResizeRows = false;
|
||||||
|
this.kryptonDataGridView1.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.AllCells;
|
||||||
|
this.kryptonDataGridView1.ClipboardCopyMode = System.Windows.Forms.DataGridViewClipboardCopyMode.EnableWithoutHeaderText;
|
||||||
|
this.kryptonDataGridView1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonDataGridView1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonDataGridView1.MultiSelect = false;
|
||||||
|
this.kryptonDataGridView1.Name = "kryptonDataGridView1";
|
||||||
|
this.kryptonDataGridView1.RowTemplate.Height = 23;
|
||||||
|
this.kryptonDataGridView1.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
|
||||||
|
this.kryptonDataGridView1.Size = new System.Drawing.Size(1020, 502);
|
||||||
|
this.kryptonDataGridView1.TabIndex = 0;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonGroupBox2.Location = new System.Drawing.Point(0, 146);
|
||||||
|
this.kryptonGroupBox2.Name = "kryptonGroupBox2";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonDataGridView1);
|
||||||
|
this.kryptonGroupBox2.Size = new System.Drawing.Size(1024, 526);
|
||||||
|
this.kryptonGroupBox2.TabIndex = 3;
|
||||||
|
this.kryptonGroupBox2.Values.Heading = "数据区:";
|
||||||
|
//
|
||||||
|
// kryptonLabel1
|
||||||
|
//
|
||||||
|
this.kryptonLabel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel1.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kryptonLabel1.Name = "kryptonLabel1";
|
||||||
|
this.kryptonLabel1.Size = new System.Drawing.Size(154, 27);
|
||||||
|
this.kryptonLabel1.TabIndex = 1;
|
||||||
|
this.kryptonLabel1.Values.Text = "PLC信息:";
|
||||||
|
//
|
||||||
|
// tableLayoutPanel1
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel1.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel1.ColumnCount = 6;
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 160F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 160F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 160F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel1, 0, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel2, 0, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel3, 2, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel4, 4, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel5, 2, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_plcMsg, 1, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kcmb_plcItemType, 3, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kcmb_plcItemDateType, 5, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_plcItemModbusAddress, 1, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_plcItemPriAddress, 3, 1);
|
||||||
|
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||||
|
this.tableLayoutPanel1.RowCount = 2;
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Size = new System.Drawing.Size(1020, 66);
|
||||||
|
this.tableLayoutPanel1.TabIndex = 0;
|
||||||
|
//
|
||||||
|
// kryptonLabel2
|
||||||
|
//
|
||||||
|
this.kryptonLabel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel2.Location = new System.Drawing.Point(3, 36);
|
||||||
|
this.kryptonLabel2.Name = "kryptonLabel2";
|
||||||
|
this.kryptonLabel2.Size = new System.Drawing.Size(154, 27);
|
||||||
|
this.kryptonLabel2.TabIndex = 1;
|
||||||
|
this.kryptonLabel2.Values.Text = "PLC变量Modbus地址:";
|
||||||
|
//
|
||||||
|
// kryptonLabel3
|
||||||
|
//
|
||||||
|
this.kryptonLabel3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel3.Location = new System.Drawing.Point(343, 3);
|
||||||
|
this.kryptonLabel3.Name = "kryptonLabel3";
|
||||||
|
this.kryptonLabel3.Size = new System.Drawing.Size(154, 27);
|
||||||
|
this.kryptonLabel3.TabIndex = 1;
|
||||||
|
this.kryptonLabel3.Values.Text = "PLC变量类型:";
|
||||||
|
//
|
||||||
|
// kryptonLabel4
|
||||||
|
//
|
||||||
|
this.kryptonLabel4.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel4.Location = new System.Drawing.Point(683, 3);
|
||||||
|
this.kryptonLabel4.Name = "kryptonLabel4";
|
||||||
|
this.kryptonLabel4.Size = new System.Drawing.Size(154, 27);
|
||||||
|
this.kryptonLabel4.TabIndex = 1;
|
||||||
|
this.kryptonLabel4.Values.Text = "PLC变量数据类型:";
|
||||||
|
//
|
||||||
|
// kryptonLabel5
|
||||||
|
//
|
||||||
|
this.kryptonLabel5.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel5.Location = new System.Drawing.Point(343, 36);
|
||||||
|
this.kryptonLabel5.Name = "kryptonLabel5";
|
||||||
|
this.kryptonLabel5.Size = new System.Drawing.Size(154, 27);
|
||||||
|
this.kryptonLabel5.TabIndex = 1;
|
||||||
|
this.kryptonLabel5.Values.Text = "PLC变量寄存器地址:";
|
||||||
|
//
|
||||||
|
// ktb_plcMsg
|
||||||
|
//
|
||||||
|
this.ktb_plcMsg.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_plcMsg.Location = new System.Drawing.Point(166, 5);
|
||||||
|
this.ktb_plcMsg.Name = "ktb_plcMsg";
|
||||||
|
this.ktb_plcMsg.Size = new System.Drawing.Size(168, 23);
|
||||||
|
this.ktb_plcMsg.TabIndex = 2;
|
||||||
|
//
|
||||||
|
// kcmb_plcItemType
|
||||||
|
//
|
||||||
|
this.kcmb_plcItemType.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kcmb_plcItemType.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
|
this.kcmb_plcItemType.DropDownWidth = 248;
|
||||||
|
this.kcmb_plcItemType.Items.AddRange(new object[] {
|
||||||
|
"请选择",
|
||||||
|
"写入变量",
|
||||||
|
"读取变量",
|
||||||
|
"可读可写"});
|
||||||
|
this.kcmb_plcItemType.Location = new System.Drawing.Point(506, 6);
|
||||||
|
this.kcmb_plcItemType.Name = "kcmb_plcItemType";
|
||||||
|
this.kcmb_plcItemType.Size = new System.Drawing.Size(168, 21);
|
||||||
|
this.kcmb_plcItemType.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// kcmb_plcItemDateType
|
||||||
|
//
|
||||||
|
this.kcmb_plcItemDateType.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kcmb_plcItemDateType.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
|
this.kcmb_plcItemDateType.DropDownWidth = 248;
|
||||||
|
this.kcmb_plcItemDateType.Items.AddRange(new object[] {
|
||||||
|
"请选择",
|
||||||
|
"M 布尔类型",
|
||||||
|
"D 整数类型",
|
||||||
|
"X 数据类型",
|
||||||
|
"Y 数据类型;"});
|
||||||
|
this.kcmb_plcItemDateType.Location = new System.Drawing.Point(845, 6);
|
||||||
|
this.kcmb_plcItemDateType.Name = "kcmb_plcItemDateType";
|
||||||
|
this.kcmb_plcItemDateType.Size = new System.Drawing.Size(170, 21);
|
||||||
|
this.kcmb_plcItemDateType.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// ktb_plcItemModbusAddress
|
||||||
|
//
|
||||||
|
this.ktb_plcItemModbusAddress.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_plcItemModbusAddress.Location = new System.Drawing.Point(166, 38);
|
||||||
|
this.ktb_plcItemModbusAddress.Name = "ktb_plcItemModbusAddress";
|
||||||
|
this.ktb_plcItemModbusAddress.Size = new System.Drawing.Size(168, 23);
|
||||||
|
this.ktb_plcItemModbusAddress.TabIndex = 2;
|
||||||
|
//
|
||||||
|
// ktb_plcItemPriAddress
|
||||||
|
//
|
||||||
|
this.ktb_plcItemPriAddress.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_plcItemPriAddress.Location = new System.Drawing.Point(506, 38);
|
||||||
|
this.ktb_plcItemPriAddress.Name = "ktb_plcItemPriAddress";
|
||||||
|
this.ktb_plcItemPriAddress.Size = new System.Drawing.Size(168, 23);
|
||||||
|
this.ktb_plcItemPriAddress.TabIndex = 2;
|
||||||
|
//
|
||||||
|
// kbt_Add
|
||||||
|
//
|
||||||
|
this.kbt_Add.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Add.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kbt_Add.Name = "kbt_Add";
|
||||||
|
this.kbt_Add.Size = new System.Drawing.Size(111, 35);
|
||||||
|
this.kbt_Add.TabIndex = 0;
|
||||||
|
this.kbt_Add.Values.Text = "新增";
|
||||||
|
this.kbt_Add.Click += new System.EventHandler(this.kbt_Add_Click);
|
||||||
|
//
|
||||||
|
// kbt_Reset
|
||||||
|
//
|
||||||
|
this.kbt_Reset.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Reset.Location = new System.Drawing.Point(471, 3);
|
||||||
|
this.kbt_Reset.Name = "kbt_Reset";
|
||||||
|
this.kbt_Reset.Size = new System.Drawing.Size(113, 35);
|
||||||
|
this.kbt_Reset.TabIndex = 0;
|
||||||
|
this.kbt_Reset.Tag = "show";
|
||||||
|
this.kbt_Reset.Values.Text = "重置条件";
|
||||||
|
this.kbt_Reset.Click += new System.EventHandler(this.kbt_Reset_Click);
|
||||||
|
//
|
||||||
|
// kbt_Edit
|
||||||
|
//
|
||||||
|
this.kbt_Edit.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Edit.Location = new System.Drawing.Point(120, 3);
|
||||||
|
this.kbt_Edit.Name = "kbt_Edit";
|
||||||
|
this.kbt_Edit.Size = new System.Drawing.Size(111, 35);
|
||||||
|
this.kbt_Edit.TabIndex = 0;
|
||||||
|
this.kbt_Edit.Values.Text = "编辑";
|
||||||
|
this.kbt_Edit.Click += new System.EventHandler(this.kbt_Edit_Click);
|
||||||
|
//
|
||||||
|
// kbt_Delete
|
||||||
|
//
|
||||||
|
this.kbt_Delete.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Delete.Location = new System.Drawing.Point(237, 3);
|
||||||
|
this.kbt_Delete.Name = "kbt_Delete";
|
||||||
|
this.kbt_Delete.Size = new System.Drawing.Size(111, 35);
|
||||||
|
this.kbt_Delete.TabIndex = 0;
|
||||||
|
this.kbt_Delete.Values.Text = "删除";
|
||||||
|
this.kbt_Delete.Click += new System.EventHandler(this.kbt_Delete_Click);
|
||||||
|
//
|
||||||
|
// tableLayoutPanel2
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.tableLayoutPanel2.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel2.ColumnCount = 5;
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 20F));
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Reset, 4, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Edit, 1, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Delete, 2, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Query, 3, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Add, 0, 0);
|
||||||
|
this.tableLayoutPanel2.Location = new System.Drawing.Point(423, 73);
|
||||||
|
this.tableLayoutPanel2.Name = "tableLayoutPanel2";
|
||||||
|
this.tableLayoutPanel2.RowCount = 1;
|
||||||
|
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||||
|
this.tableLayoutPanel2.Size = new System.Drawing.Size(587, 41);
|
||||||
|
this.tableLayoutPanel2.TabIndex = 1;
|
||||||
|
//
|
||||||
|
// kbt_Query
|
||||||
|
//
|
||||||
|
this.kbt_Query.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Query.Location = new System.Drawing.Point(354, 3);
|
||||||
|
this.kbt_Query.Name = "kbt_Query";
|
||||||
|
this.kbt_Query.Size = new System.Drawing.Size(111, 35);
|
||||||
|
this.kbt_Query.TabIndex = 0;
|
||||||
|
this.kbt_Query.Tag = "show";
|
||||||
|
this.kbt_Query.Values.Text = "查询";
|
||||||
|
this.kbt_Query.Click += new System.EventHandler(this.kbt_Query_Click);
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.kryptonGroupBox1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonGroupBox1.Name = "kryptonGroupBox1";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.tableLayoutPanel2);
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.tableLayoutPanel1);
|
||||||
|
this.kryptonGroupBox1.Size = new System.Drawing.Size(1024, 146);
|
||||||
|
this.kryptonGroupBox1.TabIndex = 2;
|
||||||
|
this.kryptonGroupBox1.Values.Heading = "查询操作";
|
||||||
|
//
|
||||||
|
// frmPlcItemConfig
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.Controls.Add(this.kryptonGroupBox2);
|
||||||
|
this.Controls.Add(this.kryptonGroupBox1);
|
||||||
|
this.Name = "frmPlcItemConfig";
|
||||||
|
this.Size = new System.Drawing.Size(1024, 672);
|
||||||
|
this.Load += new System.EventHandler(this.frmPlcItemConfig_Load);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonDataGridView1)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox2.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).EndInit();
|
||||||
|
this.kryptonGroupBox2.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_plcItemType)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_plcItemDateType)).EndInit();
|
||||||
|
this.tableLayoutPanel2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox1.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).EndInit();
|
||||||
|
this.kryptonGroupBox1.ResumeLayout(false);
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridView kryptonDataGridView1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel1;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel3;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel4;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel5;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_plcMsg;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonComboBox kcmb_plcItemType;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonComboBox kcmb_plcItemDateType;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_plcItemModbusAddress;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_plcItemPriAddress;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Add;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Reset;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Edit;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Delete;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Query;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox1;
|
||||||
|
}
|
||||||
|
}
|
||||||
334
CleanMachineHMI/FrmUserControl/frmPlcItemConfig.cs
Normal file
@@ -0,0 +1,334 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.frmChild;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using LeadDataBaseUtility;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
[FormType(EnumFormType.PlcItemConfig)]
|
||||||
|
public partial class frmPlcItemConfig : UserControl
|
||||||
|
{
|
||||||
|
public frmPlcItemConfig()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
_ComboBoxLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode, "KryptonComboBox");
|
||||||
|
_InfoLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
private DataTable _ComboBoxLanguageTextList;
|
||||||
|
private DataTable _InfoLanguageTextList;
|
||||||
|
public delegate void dlgRefreshFrmHost();
|
||||||
|
public static dlgRefreshFrmHost RefreshFrmHost;
|
||||||
|
private void txt_GotFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.ShowInputPanel();
|
||||||
|
}
|
||||||
|
private void txt_LostFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.HideInputPanel();
|
||||||
|
}
|
||||||
|
private void InitControlEvent()
|
||||||
|
{
|
||||||
|
ktb_plcMsg.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_plcMsg.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
|
||||||
|
ktb_plcItemModbusAddress.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_plcItemModbusAddress.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
|
||||||
|
ktb_plcItemPriAddress.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_plcItemPriAddress.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
}
|
||||||
|
private void frmPlcItemConfig_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
InitControlEvent();
|
||||||
|
this.SetFormControlText(GlobalHelper.LanguageCode);
|
||||||
|
if (GlobalHelper.LanguageCode == "English")
|
||||||
|
{
|
||||||
|
kcmb_plcItemType.Items.Clear();
|
||||||
|
foreach (DataRow item in _ComboBoxLanguageTextList.GetComBoboxItemArr(kcmb_plcItemType.Name, "KryptonComboBox"))
|
||||||
|
{
|
||||||
|
kcmb_plcItemType.Items.Add(item["CONTROL_NAME"].ToString());
|
||||||
|
}
|
||||||
|
kcmb_plcItemDateType.Items.Clear();
|
||||||
|
foreach (DataRow item in _ComboBoxLanguageTextList.GetComBoboxItemArr(kcmb_plcItemDateType.Name, "KryptonComboBox"))
|
||||||
|
{
|
||||||
|
kcmb_plcItemDateType.Items.Add(item["CONTROL_NAME"].ToString());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kcmb_plcItemType.SelectedIndex = 0;
|
||||||
|
kcmb_plcItemDateType.SelectedIndex = 0;
|
||||||
|
RefreshFrmHost = new dlgRefreshFrmHost(RefreshPlcData);
|
||||||
|
RefreshPlcData();
|
||||||
|
foreach (Control item in tableLayoutPanel2.Controls)
|
||||||
|
{
|
||||||
|
if (item.Tag == null)
|
||||||
|
{
|
||||||
|
DataRow[] drs = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{this.Name}' AND MENU_PID = '-1'");
|
||||||
|
DataRow[] drs1 = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{item.Name}' AND MENU_PID = '{drs[0]["MENU_ID"]}'");
|
||||||
|
if (drs1.Length > 0)
|
||||||
|
{
|
||||||
|
item.Enabled = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
item.Enabled = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kryptonGroupBox1.Focus();
|
||||||
|
}
|
||||||
|
private void RefreshPlcData()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
#region 已删除
|
||||||
|
//string sql = $@"
|
||||||
|
// SELECT
|
||||||
|
// PLC_ITEM_ID '序号',
|
||||||
|
// PLC_ITEM_CODE 'PLC变量编码',
|
||||||
|
// PLC_ITEM_NAME 'PLC变量名称',
|
||||||
|
// CASE PLC_ITEM_TYPE
|
||||||
|
// WHEN 0 THEN
|
||||||
|
// '写入变量'
|
||||||
|
// WHEN 1 THEN
|
||||||
|
// '读取变量'
|
||||||
|
// ELSE
|
||||||
|
// '可读可写'
|
||||||
|
// END 'PLC变量类型',
|
||||||
|
// CASE PLC_ITEM_DATA_TYPE
|
||||||
|
// WHEN 0 THEN
|
||||||
|
// 'M 布尔类型'
|
||||||
|
// WHEN 1 THEN
|
||||||
|
// 'D 整数类型'
|
||||||
|
// WHEN 2 THEN
|
||||||
|
// 'X 数据类型'
|
||||||
|
// WHEN 3 THEN
|
||||||
|
// 'Y 数据类型'
|
||||||
|
// ELSE
|
||||||
|
// '未知'
|
||||||
|
// END 'PLC变量数据类型',
|
||||||
|
// PLC_ITEM_PRI_ADDRESS 'PLC寄存器地址',
|
||||||
|
// PLC_ITEM_MODBUS_ADDRESS 'ModBus地址',
|
||||||
|
// PLC_ITEM_VALUE '当前值'
|
||||||
|
// FROM
|
||||||
|
// BAS_PLC_ITEM
|
||||||
|
// WHERE 1=1
|
||||||
|
// ";
|
||||||
|
//if (!string.IsNullOrEmpty(ktb_plcMsg.Text.Trim()))
|
||||||
|
//{
|
||||||
|
// sql += $" AND (PLC_ITEM_CODE LIKE '%{ktb_plcMsg.Text.Trim()}%' OR PLC_ITEM_NAME LIKE '%{ktb_plcMsg.Text.Trim()}%')";
|
||||||
|
//}
|
||||||
|
//if (kcmb_plcItemType.SelectedIndex != 0)
|
||||||
|
//{
|
||||||
|
// sql += $" AND PLC_ITEM_TYPE = '{kcmb_plcItemType.SelectedIndex -1}'";
|
||||||
|
//}
|
||||||
|
//if (kcmb_plcItemDateType.SelectedIndex != 0)
|
||||||
|
//{
|
||||||
|
// sql += $" AND PLC_ITEM_DATA_TYPE = '{kcmb_plcItemDateType.SelectedIndex - 1}'";
|
||||||
|
//}
|
||||||
|
//if (!string.IsNullOrEmpty(ktb_plcItemModbusAddress.Text.Trim()))
|
||||||
|
//{
|
||||||
|
// sql += $" AND PLC_ITEM_MODBUS_ADDRESS = '{ktb_plcItemModbusAddress.Text.Trim()}'";
|
||||||
|
//}
|
||||||
|
//if (!string.IsNullOrEmpty(ktb_plcItemPriAddress.Text.Trim()))
|
||||||
|
//{
|
||||||
|
// sql += $" AND PLC_ITEM_PRI_ADDRESS = '{ktb_plcItemPriAddress.Text.Trim()}'";
|
||||||
|
//}
|
||||||
|
//DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
List<BasPlcItemMd> tmpMdList;
|
||||||
|
if (!string.IsNullOrEmpty(ktb_plcMsg.Text.Trim()))
|
||||||
|
{
|
||||||
|
tmpMdList = GlobalHelper.PlcItemMdList.FindAll(x => x.PlcItemCode.Contains(ktb_plcMsg.Text.Trim()) || x.PlcItemName.Contains(ktb_plcMsg.Text.Trim()));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
tmpMdList = GlobalHelper.PlcItemMdList;
|
||||||
|
}
|
||||||
|
if (tmpMdList != null && tmpMdList.Count > 0)
|
||||||
|
{
|
||||||
|
if (kcmb_plcItemType.SelectedIndex != 0)
|
||||||
|
{
|
||||||
|
tmpMdList = tmpMdList.FindAll(x => x.PlcItemType == (kcmb_plcItemType.SelectedIndex - 1));
|
||||||
|
}
|
||||||
|
if (tmpMdList != null && tmpMdList.Count > 0)
|
||||||
|
{
|
||||||
|
if (kcmb_plcItemDateType.SelectedIndex != 0)
|
||||||
|
{
|
||||||
|
tmpMdList = tmpMdList.FindAll(x => x.PlcItemDataType == (kcmb_plcItemDateType.SelectedIndex - 1));
|
||||||
|
}
|
||||||
|
if (tmpMdList != null && tmpMdList.Count > 0)
|
||||||
|
{
|
||||||
|
if (!string.IsNullOrEmpty(ktb_plcItemModbusAddress.Text.Trim()))
|
||||||
|
{
|
||||||
|
tmpMdList = tmpMdList.FindAll(x => x.PlcItemModbusAddress == ktb_plcItemModbusAddress.Text.Trim());
|
||||||
|
}
|
||||||
|
if (tmpMdList != null && tmpMdList.Count > 0)
|
||||||
|
{
|
||||||
|
if (!string.IsNullOrEmpty(ktb_plcItemPriAddress.Text.Trim()))
|
||||||
|
{
|
||||||
|
tmpMdList = tmpMdList.FindAll(x => x.PlcItemPriAddress == ktb_plcItemPriAddress.Text.Trim());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
if (tmpMdList != null && tmpMdList.Count > 0)
|
||||||
|
{
|
||||||
|
DataTable dt = new DataTable();
|
||||||
|
DataColumn dc1 = new DataColumn("序号", Type.GetType("System.Int32"));
|
||||||
|
DataColumn dc2 = new DataColumn("PLC变量编码", Type.GetType("System.String"));
|
||||||
|
DataColumn dc3 = new DataColumn("PLC变量名称", Type.GetType("System.String"));
|
||||||
|
DataColumn dc8 = new DataColumn("当前值", Type.GetType("System.String"));
|
||||||
|
DataColumn dc4 = new DataColumn("PLC变量类型", Type.GetType("System.String"));
|
||||||
|
DataColumn dc5 = new DataColumn("PLC变量数据类型", Type.GetType("System.String"));
|
||||||
|
DataColumn dc6 = new DataColumn("PLC寄存器地址", Type.GetType("System.String"));
|
||||||
|
DataColumn dc7 = new DataColumn("ModBus地址", Type.GetType("System.String"));
|
||||||
|
|
||||||
|
dt.Columns.Add(dc1);
|
||||||
|
dt.Columns.Add(dc2);
|
||||||
|
dt.Columns.Add(dc3);
|
||||||
|
dt.Columns.Add(dc8);
|
||||||
|
dt.Columns.Add(dc4);
|
||||||
|
dt.Columns.Add(dc5);
|
||||||
|
dt.Columns.Add(dc6);
|
||||||
|
dt.Columns.Add(dc7);
|
||||||
|
foreach (BasPlcItemMd item in tmpMdList)
|
||||||
|
{
|
||||||
|
DataRow dr = dt.NewRow();
|
||||||
|
dr["序号"] = item.PlcItemId;
|
||||||
|
dr["PLC变量编码"] = item.PlcItemCode;
|
||||||
|
dr["PLC变量名称"] = item.PlcItemName;
|
||||||
|
if (item.PlcItemType == 0)
|
||||||
|
{
|
||||||
|
dr["PLC变量类型"] = "Can Write";
|
||||||
|
}
|
||||||
|
else if (item.PlcItemType == 1)
|
||||||
|
{
|
||||||
|
dr["PLC变量类型"] = "Can Read";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
dr["PLC变量类型"] = "Read and Write";
|
||||||
|
}
|
||||||
|
|
||||||
|
if (item.PlcItemDataType == 0)
|
||||||
|
{
|
||||||
|
dr["PLC变量数据类型"] = "M Type";
|
||||||
|
}
|
||||||
|
else if (item.PlcItemDataType == 1)
|
||||||
|
{
|
||||||
|
dr["PLC变量数据类型"] = "D Type";
|
||||||
|
}
|
||||||
|
else if (item.PlcItemDataType == 2)
|
||||||
|
{
|
||||||
|
dr["PLC变量数据类型"] = "X Type";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
dr["PLC变量数据类型"] = "Y Type";
|
||||||
|
}
|
||||||
|
dr["PLC寄存器地址"] = item.PlcItemPriAddress;
|
||||||
|
dr["ModBus地址"] = item.PlcItemModbusAddress;
|
||||||
|
dr["当前值"] = item.PlcItemValue;
|
||||||
|
dt.Rows.Add(dr);
|
||||||
|
}
|
||||||
|
kryptonDataGridView1.DataSource = dt;
|
||||||
|
kryptonDataGridView1.ClearSelection();
|
||||||
|
kryptonDataGridView1.SetDataViewColumnText(this.Name, GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
kryptonDataGridView1.DataSource = null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("加载PLC变量数据界面发生异常", "LoadFrmPlcItemExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
private void kbt_Query_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
RefreshPlcData();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Reset_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
ktb_plcMsg.Text = "";
|
||||||
|
ktb_plcItemModbusAddress.Text = "";
|
||||||
|
ktb_plcItemPriAddress.Text = "";
|
||||||
|
kcmb_plcItemDateType.SelectedIndex = 0;
|
||||||
|
kcmb_plcItemType.SelectedIndex = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Add_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
frmAddPlcItem frm = new frmAddPlcItem();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Edit_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (kryptonDataGridView1.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
frmEditPlcItem frm = new frmEditPlcItem();
|
||||||
|
frm.PlcItemId = kryptonDataGridView1.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
//KryptonMessageBox.Show("请选择要编辑的PLC变量数据行!");
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要编辑的PLC变量数据行!", "SelectWantToEditRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Delete_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if (kryptonDataGridView1.SelectedRows.Count > 0)
|
||||||
|
{
|
||||||
|
DialogResult dr = KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("确定要删除所选的PLC变量信息吗?", "DeleteInfo"), "Prompt", MessageBoxButtons.OKCancel, MessageBoxIcon.Question);
|
||||||
|
if (dr == DialogResult.OK)
|
||||||
|
{
|
||||||
|
string PlcItemId = kryptonDataGridView1.SelectedRows[0].Cells[0].Value.ToString();
|
||||||
|
string sql = $@"DELETE FROM BAS_PLC_ITEM WHERE PLC_ITEM_ID = '{PlcItemId}'";
|
||||||
|
int row = LeadDbHelperSQLite.ExecuteSql(sql);
|
||||||
|
if (row > 0)
|
||||||
|
{
|
||||||
|
//KryptonMessageBox.Show("删除PLC变量数据成功!");
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除PLC变量数据成功!", "DeleteSuccessInfo"));
|
||||||
|
RefreshFrmHost();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
//KryptonMessageBox.Show("删除PLC变量数据失败!");
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除PLC变量数据失败!", "DeleteFailInfo"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
//KryptonMessageBox.Show("请选择要删除的PLC变量数据行!");
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择要删除的PLC变量数据行!", "SelectWantToDeleteRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("删除PLC变量数据发生异常", "DeletePlcItemDataExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
120
CleanMachineHMI/FrmUserControl/frmPlcItemConfig.resx
Normal file
@@ -0,0 +1,120 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
</root>
|
||||||
475
CleanMachineHMI/FrmUserControl/frmPrinterMain.Designer.cs
generated
Normal file
@@ -0,0 +1,475 @@
|
|||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
partial class frmPrinterMain
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 必需的设计器变量。
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清理所有正在使用的资源。
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region 组件设计器生成的代码
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设计器支持所需的方法 - 不要修改
|
||||||
|
/// 使用代码编辑器修改此方法的内容。
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
|
||||||
|
this.kryptonDataGridView2 = new ComponentFactory.Krypton.Toolkit.KryptonDataGridView();
|
||||||
|
this.kryptonGroupBox1 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kbt_Reset = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbt_Query = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kryptonButton2 = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.kbtn_EditWorkingPalletData = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||||
|
this.kdtp_InputStartTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kryptonLabel3 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel1 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kryptonLabel4 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.ktb_palletMsg = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kryptonLabel2 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.kcmb_sheetType = new ComponentFactory.Krypton.Toolkit.KryptonComboBox();
|
||||||
|
this.kryptonLabel5 = new ComponentFactory.Krypton.Toolkit.KryptonLabel();
|
||||||
|
this.ktb_irMsg = new ComponentFactory.Krypton.Toolkit.KryptonTextBox();
|
||||||
|
this.kdtp_InputEndTime = new ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker();
|
||||||
|
this.kryptonGroupBox3 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.kryptonButton1 = new ComponentFactory.Krypton.Toolkit.KryptonButton();
|
||||||
|
this.创建时间 = new ComponentFactory.Krypton.Toolkit.KryptonDataGridViewTextBoxColumn();
|
||||||
|
this.创建人 = new ComponentFactory.Krypton.Toolkit.KryptonDataGridViewTextBoxColumn();
|
||||||
|
this.作业状态 = new ComponentFactory.Krypton.Toolkit.KryptonDataGridViewTextBoxColumn();
|
||||||
|
this.托盘号 = new ComponentFactory.Krypton.Toolkit.KryptonDataGridViewTextBoxColumn();
|
||||||
|
this.序号 = new ComponentFactory.Krypton.Toolkit.KryptonDataGridViewTextBoxColumn();
|
||||||
|
this.Column1 = new ComponentFactory.Krypton.Toolkit.KryptonDataGridViewCheckBoxColumn();
|
||||||
|
this.kryptonGroupBox2 = new ComponentFactory.Krypton.Toolkit.KryptonGroupBox();
|
||||||
|
this.kryptonDataGridView1 = new ComponentFactory.Krypton.Toolkit.KryptonDataGridView();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonDataGridView2)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox1.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox1.SuspendLayout();
|
||||||
|
this.tableLayoutPanel2.SuspendLayout();
|
||||||
|
this.tableLayoutPanel1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_sheetType)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox3)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox3.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox3.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox3.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).BeginInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).BeginInit();
|
||||||
|
this.kryptonGroupBox2.Panel.SuspendLayout();
|
||||||
|
this.kryptonGroupBox2.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonDataGridView1)).BeginInit();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// kryptonDataGridView2
|
||||||
|
//
|
||||||
|
this.kryptonDataGridView2.AllowUserToAddRows = false;
|
||||||
|
this.kryptonDataGridView2.AllowUserToDeleteRows = false;
|
||||||
|
this.kryptonDataGridView2.AllowUserToResizeColumns = false;
|
||||||
|
this.kryptonDataGridView2.AllowUserToResizeRows = false;
|
||||||
|
this.kryptonDataGridView2.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.DisplayedCells;
|
||||||
|
this.kryptonDataGridView2.ClipboardCopyMode = System.Windows.Forms.DataGridViewClipboardCopyMode.EnableWithoutHeaderText;
|
||||||
|
this.kryptonDataGridView2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonDataGridView2.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonDataGridView2.MultiSelect = false;
|
||||||
|
this.kryptonDataGridView2.Name = "kryptonDataGridView2";
|
||||||
|
this.kryptonDataGridView2.ReadOnly = true;
|
||||||
|
this.kryptonDataGridView2.RowTemplate.Height = 23;
|
||||||
|
this.kryptonDataGridView2.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
|
||||||
|
this.kryptonDataGridView2.Size = new System.Drawing.Size(1020, 364);
|
||||||
|
this.kryptonDataGridView2.TabIndex = 0;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.kryptonGroupBox1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonGroupBox1.Name = "kryptonGroupBox1";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox1.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.tableLayoutPanel2);
|
||||||
|
this.kryptonGroupBox1.Panel.Controls.Add(this.tableLayoutPanel1);
|
||||||
|
this.kryptonGroupBox1.Size = new System.Drawing.Size(1024, 118);
|
||||||
|
this.kryptonGroupBox1.TabIndex = 7;
|
||||||
|
this.kryptonGroupBox1.Values.Heading = "查询操作";
|
||||||
|
//
|
||||||
|
// tableLayoutPanel2
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.tableLayoutPanel2.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel2.ColumnCount = 4;
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F));
|
||||||
|
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F));
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Reset, 3, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbt_Query, 2, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kryptonButton2, 1, 0);
|
||||||
|
this.tableLayoutPanel2.Controls.Add(this.kbtn_EditWorkingPalletData, 0, 0);
|
||||||
|
this.tableLayoutPanel2.Location = new System.Drawing.Point(525, 58);
|
||||||
|
this.tableLayoutPanel2.Name = "tableLayoutPanel2";
|
||||||
|
this.tableLayoutPanel2.RowCount = 1;
|
||||||
|
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||||
|
this.tableLayoutPanel2.Size = new System.Drawing.Size(492, 33);
|
||||||
|
this.tableLayoutPanel2.TabIndex = 1;
|
||||||
|
//
|
||||||
|
// kbt_Reset
|
||||||
|
//
|
||||||
|
this.kbt_Reset.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Reset.Location = new System.Drawing.Point(372, 3);
|
||||||
|
this.kbt_Reset.Name = "kbt_Reset";
|
||||||
|
this.kbt_Reset.Size = new System.Drawing.Size(117, 27);
|
||||||
|
this.kbt_Reset.TabIndex = 0;
|
||||||
|
this.kbt_Reset.Tag = "show";
|
||||||
|
this.kbt_Reset.Values.Text = "重置条件";
|
||||||
|
this.kbt_Reset.Click += new System.EventHandler(this.kbt_Reset_Click);
|
||||||
|
//
|
||||||
|
// kbt_Query
|
||||||
|
//
|
||||||
|
this.kbt_Query.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbt_Query.Location = new System.Drawing.Point(249, 3);
|
||||||
|
this.kbt_Query.Name = "kbt_Query";
|
||||||
|
this.kbt_Query.Size = new System.Drawing.Size(117, 27);
|
||||||
|
this.kbt_Query.TabIndex = 0;
|
||||||
|
this.kbt_Query.Tag = "show";
|
||||||
|
this.kbt_Query.Values.Text = "查询";
|
||||||
|
this.kbt_Query.Click += new System.EventHandler(this.kbt_Query_Click);
|
||||||
|
//
|
||||||
|
// kryptonButton2
|
||||||
|
//
|
||||||
|
this.kryptonButton2.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kryptonButton2.Location = new System.Drawing.Point(126, 3);
|
||||||
|
this.kryptonButton2.Name = "kryptonButton2";
|
||||||
|
this.kryptonButton2.Size = new System.Drawing.Size(117, 27);
|
||||||
|
this.kryptonButton2.TabIndex = 0;
|
||||||
|
this.kryptonButton2.Values.Text = "补打IR单据";
|
||||||
|
this.kryptonButton2.Click += new System.EventHandler(this.kryptonButton2_Click);
|
||||||
|
//
|
||||||
|
// kbtn_EditWorkingPalletData
|
||||||
|
//
|
||||||
|
this.kbtn_EditWorkingPalletData.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kbtn_EditWorkingPalletData.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kbtn_EditWorkingPalletData.Name = "kbtn_EditWorkingPalletData";
|
||||||
|
this.kbtn_EditWorkingPalletData.Size = new System.Drawing.Size(117, 27);
|
||||||
|
this.kbtn_EditWorkingPalletData.TabIndex = 0;
|
||||||
|
this.kbtn_EditWorkingPalletData.Values.Text = "修改作业数据";
|
||||||
|
this.kbtn_EditWorkingPalletData.Click += new System.EventHandler(this.kbtn_EditWorkingPalletData_Click);
|
||||||
|
//
|
||||||
|
// tableLayoutPanel1
|
||||||
|
//
|
||||||
|
this.tableLayoutPanel1.BackColor = System.Drawing.Color.Transparent;
|
||||||
|
this.tableLayoutPanel1.ColumnCount = 6;
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 120F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 120F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 150F));
|
||||||
|
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_InputStartTime, 1, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel3, 0, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel1, 0, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel4, 2, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_palletMsg, 1, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel2, 4, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kcmb_sheetType, 5, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kryptonLabel5, 2, 1);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.ktb_irMsg, 3, 0);
|
||||||
|
this.tableLayoutPanel1.Controls.Add(this.kdtp_InputEndTime, 3, 1);
|
||||||
|
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||||
|
this.tableLayoutPanel1.RowCount = 2;
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||||
|
this.tableLayoutPanel1.Size = new System.Drawing.Size(1020, 55);
|
||||||
|
this.tableLayoutPanel1.TabIndex = 0;
|
||||||
|
//
|
||||||
|
// kdtp_InputStartTime
|
||||||
|
//
|
||||||
|
this.kdtp_InputStartTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_InputStartTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_InputStartTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_InputStartTime.Location = new System.Drawing.Point(132, 30);
|
||||||
|
this.kdtp_InputStartTime.Name = "kdtp_InputStartTime";
|
||||||
|
this.kdtp_InputStartTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_InputStartTime.Size = new System.Drawing.Size(186, 21);
|
||||||
|
this.kdtp_InputStartTime.TabIndex = 8;
|
||||||
|
//
|
||||||
|
// kryptonLabel3
|
||||||
|
//
|
||||||
|
this.kryptonLabel3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel3.Location = new System.Drawing.Point(3, 30);
|
||||||
|
this.kryptonLabel3.Name = "kryptonLabel3";
|
||||||
|
this.kryptonLabel3.Size = new System.Drawing.Size(114, 22);
|
||||||
|
this.kryptonLabel3.TabIndex = 1;
|
||||||
|
this.kryptonLabel3.Values.Text = "录入时间:";
|
||||||
|
//
|
||||||
|
// kryptonLabel1
|
||||||
|
//
|
||||||
|
this.kryptonLabel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel1.Location = new System.Drawing.Point(3, 3);
|
||||||
|
this.kryptonLabel1.Name = "kryptonLabel1";
|
||||||
|
this.kryptonLabel1.Size = new System.Drawing.Size(114, 21);
|
||||||
|
this.kryptonLabel1.TabIndex = 1;
|
||||||
|
this.kryptonLabel1.Values.Text = "托盘信息:";
|
||||||
|
//
|
||||||
|
// kryptonLabel4
|
||||||
|
//
|
||||||
|
this.kryptonLabel4.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel4.Location = new System.Drawing.Point(333, 3);
|
||||||
|
this.kryptonLabel4.Name = "kryptonLabel4";
|
||||||
|
this.kryptonLabel4.Size = new System.Drawing.Size(114, 21);
|
||||||
|
this.kryptonLabel4.TabIndex = 1;
|
||||||
|
this.kryptonLabel4.Values.Text = "IR信息:";
|
||||||
|
//
|
||||||
|
// ktb_palletMsg
|
||||||
|
//
|
||||||
|
this.ktb_palletMsg.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_palletMsg.Location = new System.Drawing.Point(132, 3);
|
||||||
|
this.ktb_palletMsg.Name = "ktb_palletMsg";
|
||||||
|
this.ktb_palletMsg.Size = new System.Drawing.Size(186, 23);
|
||||||
|
this.ktb_palletMsg.TabIndex = 2;
|
||||||
|
//
|
||||||
|
// kryptonLabel2
|
||||||
|
//
|
||||||
|
this.kryptonLabel2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonLabel2.Location = new System.Drawing.Point(663, 3);
|
||||||
|
this.kryptonLabel2.Name = "kryptonLabel2";
|
||||||
|
this.kryptonLabel2.Size = new System.Drawing.Size(144, 21);
|
||||||
|
this.kryptonLabel2.TabIndex = 1;
|
||||||
|
this.kryptonLabel2.Values.Text = "板材信息:";
|
||||||
|
//
|
||||||
|
// kcmb_sheetType
|
||||||
|
//
|
||||||
|
this.kcmb_sheetType.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kcmb_sheetType.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
|
this.kcmb_sheetType.DropDownWidth = 248;
|
||||||
|
this.kcmb_sheetType.Location = new System.Drawing.Point(821, 3);
|
||||||
|
this.kcmb_sheetType.Name = "kcmb_sheetType";
|
||||||
|
this.kcmb_sheetType.Size = new System.Drawing.Size(187, 21);
|
||||||
|
this.kcmb_sheetType.TabIndex = 3;
|
||||||
|
//
|
||||||
|
// kryptonLabel5
|
||||||
|
//
|
||||||
|
this.kryptonLabel5.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kryptonLabel5.Location = new System.Drawing.Point(378, 31);
|
||||||
|
this.kryptonLabel5.Name = "kryptonLabel5";
|
||||||
|
this.kryptonLabel5.Size = new System.Drawing.Size(23, 20);
|
||||||
|
this.kryptonLabel5.TabIndex = 1;
|
||||||
|
this.kryptonLabel5.Values.Text = "至";
|
||||||
|
//
|
||||||
|
// ktb_irMsg
|
||||||
|
//
|
||||||
|
this.ktb_irMsg.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.ktb_irMsg.Location = new System.Drawing.Point(462, 3);
|
||||||
|
this.ktb_irMsg.Name = "ktb_irMsg";
|
||||||
|
this.ktb_irMsg.Size = new System.Drawing.Size(186, 23);
|
||||||
|
this.ktb_irMsg.TabIndex = 2;
|
||||||
|
//
|
||||||
|
// kdtp_InputEndTime
|
||||||
|
//
|
||||||
|
this.kdtp_InputEndTime.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
|
this.kdtp_InputEndTime.CustomFormat = "yyyy-MM-dd HH:mm:ss";
|
||||||
|
this.kdtp_InputEndTime.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
||||||
|
this.kdtp_InputEndTime.Location = new System.Drawing.Point(462, 30);
|
||||||
|
this.kdtp_InputEndTime.Name = "kdtp_InputEndTime";
|
||||||
|
this.kdtp_InputEndTime.ShowCheckBox = true;
|
||||||
|
this.kdtp_InputEndTime.Size = new System.Drawing.Size(186, 21);
|
||||||
|
this.kdtp_InputEndTime.TabIndex = 8;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox3
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox3.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonGroupBox3.Location = new System.Drawing.Point(0, 284);
|
||||||
|
this.kryptonGroupBox3.Name = "kryptonGroupBox3";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox3.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox3.Panel.Controls.Add(this.kryptonDataGridView2);
|
||||||
|
this.kryptonGroupBox3.Size = new System.Drawing.Size(1024, 388);
|
||||||
|
this.kryptonGroupBox3.TabIndex = 9;
|
||||||
|
this.kryptonGroupBox3.Values.Heading = "托盘明细表数据:";
|
||||||
|
//
|
||||||
|
// kryptonButton1
|
||||||
|
//
|
||||||
|
this.kryptonButton1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Left)
|
||||||
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.kryptonButton1.Location = new System.Drawing.Point(728, 47);
|
||||||
|
this.kryptonButton1.Name = "kryptonButton1";
|
||||||
|
this.kryptonButton1.Size = new System.Drawing.Size(144, 19);
|
||||||
|
this.kryptonButton1.TabIndex = 0;
|
||||||
|
this.kryptonButton1.Values.Text = "重置条件";
|
||||||
|
//
|
||||||
|
// 创建时间
|
||||||
|
//
|
||||||
|
this.创建时间.HeaderText = "创建时间";
|
||||||
|
this.创建时间.Name = "创建时间";
|
||||||
|
this.创建时间.Width = 163;
|
||||||
|
//
|
||||||
|
// 创建人
|
||||||
|
//
|
||||||
|
this.创建人.HeaderText = "创建人";
|
||||||
|
this.创建人.Name = "创建人";
|
||||||
|
this.创建人.Width = 163;
|
||||||
|
//
|
||||||
|
// 作业状态
|
||||||
|
//
|
||||||
|
this.作业状态.HeaderText = "作业状态";
|
||||||
|
this.作业状态.Name = "作业状态";
|
||||||
|
this.作业状态.Width = 163;
|
||||||
|
//
|
||||||
|
// 托盘号
|
||||||
|
//
|
||||||
|
this.托盘号.HeaderText = "托盘号";
|
||||||
|
this.托盘号.Name = "托盘号";
|
||||||
|
this.托盘号.Width = 164;
|
||||||
|
//
|
||||||
|
// 序号
|
||||||
|
//
|
||||||
|
this.序号.HeaderText = "序号";
|
||||||
|
this.序号.Name = "序号";
|
||||||
|
this.序号.Width = 163;
|
||||||
|
//
|
||||||
|
// Column1
|
||||||
|
//
|
||||||
|
dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
|
||||||
|
dataGridViewCellStyle1.NullValue = false;
|
||||||
|
this.Column1.DefaultCellStyle = dataGridViewCellStyle1;
|
||||||
|
this.Column1.FalseValue = null;
|
||||||
|
this.Column1.HeaderText = "";
|
||||||
|
this.Column1.IndeterminateValue = null;
|
||||||
|
this.Column1.Name = "Column1";
|
||||||
|
this.Column1.TrueValue = null;
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.CaptionOverlap = 0D;
|
||||||
|
this.kryptonGroupBox2.Dock = System.Windows.Forms.DockStyle.Top;
|
||||||
|
this.kryptonGroupBox2.Location = new System.Drawing.Point(0, 118);
|
||||||
|
this.kryptonGroupBox2.Name = "kryptonGroupBox2";
|
||||||
|
//
|
||||||
|
// kryptonGroupBox2.Panel
|
||||||
|
//
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonDataGridView1);
|
||||||
|
this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonButton1);
|
||||||
|
this.kryptonGroupBox2.Size = new System.Drawing.Size(1024, 166);
|
||||||
|
this.kryptonGroupBox2.TabIndex = 8;
|
||||||
|
this.kryptonGroupBox2.Values.Heading = "托盘主表数据:";
|
||||||
|
//
|
||||||
|
// kryptonDataGridView1
|
||||||
|
//
|
||||||
|
this.kryptonDataGridView1.AllowUserToAddRows = false;
|
||||||
|
this.kryptonDataGridView1.AllowUserToDeleteRows = false;
|
||||||
|
this.kryptonDataGridView1.AllowUserToResizeColumns = false;
|
||||||
|
this.kryptonDataGridView1.AllowUserToResizeRows = false;
|
||||||
|
this.kryptonDataGridView1.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
|
||||||
|
this.kryptonDataGridView1.ClipboardCopyMode = System.Windows.Forms.DataGridViewClipboardCopyMode.EnableWithoutHeaderText;
|
||||||
|
this.kryptonDataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
|
||||||
|
this.Column1,
|
||||||
|
this.序号,
|
||||||
|
this.托盘号,
|
||||||
|
this.作业状态,
|
||||||
|
this.创建人,
|
||||||
|
this.创建时间});
|
||||||
|
this.kryptonDataGridView1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.kryptonDataGridView1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.kryptonDataGridView1.MultiSelect = false;
|
||||||
|
this.kryptonDataGridView1.Name = "kryptonDataGridView1";
|
||||||
|
this.kryptonDataGridView1.RowTemplate.Height = 23;
|
||||||
|
this.kryptonDataGridView1.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
|
||||||
|
this.kryptonDataGridView1.Size = new System.Drawing.Size(1020, 142);
|
||||||
|
this.kryptonDataGridView1.TabIndex = 0;
|
||||||
|
this.kryptonDataGridView1.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.kryptonDataGridView1_CellContentClick);
|
||||||
|
this.kryptonDataGridView1.SelectionChanged += new System.EventHandler(this.kryptonDataGridView1_SelectionChanged);
|
||||||
|
//
|
||||||
|
// frmPrinterMain
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.Controls.Add(this.kryptonGroupBox3);
|
||||||
|
this.Controls.Add(this.kryptonGroupBox2);
|
||||||
|
this.Controls.Add(this.kryptonGroupBox1);
|
||||||
|
this.Name = "frmPrinterMain";
|
||||||
|
this.Size = new System.Drawing.Size(1024, 672);
|
||||||
|
this.Load += new System.EventHandler(this.frmPrinterMain_Load);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonDataGridView2)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox1.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox1)).EndInit();
|
||||||
|
this.kryptonGroupBox1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel2.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.ResumeLayout(false);
|
||||||
|
this.tableLayoutPanel1.PerformLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kcmb_sheetType)).EndInit();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox3.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox3.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox3)).EndInit();
|
||||||
|
this.kryptonGroupBox3.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).EndInit();
|
||||||
|
this.kryptonGroupBox2.Panel.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).EndInit();
|
||||||
|
this.kryptonGroupBox2.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.kryptonDataGridView1)).EndInit();
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridView kryptonDataGridView2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox1;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Reset;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbt_Query;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kryptonButton2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kbtn_EditWorkingPalletData;
|
||||||
|
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_InputStartTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel3;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel4;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_palletMsg;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonComboBox kcmb_sheetType;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonLabel kryptonLabel5;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonTextBox ktb_irMsg;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDateTimePicker kdtp_InputEndTime;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox3;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonButton kryptonButton1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridViewTextBoxColumn 创建时间;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridViewTextBoxColumn 创建人;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridViewTextBoxColumn 作业状态;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridViewTextBoxColumn 托盘号;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridViewTextBoxColumn 序号;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridViewCheckBoxColumn Column1;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonGroupBox kryptonGroupBox2;
|
||||||
|
private ComponentFactory.Krypton.Toolkit.KryptonDataGridView kryptonDataGridView1;
|
||||||
|
}
|
||||||
|
}
|
||||||
704
CleanMachineHMI/FrmUserControl/frmPrinterMain.cs
Normal file
@@ -0,0 +1,704 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.frmChild;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using FastReport;
|
||||||
|
using LeadDataBaseUtility;
|
||||||
|
using NX_LogUtility;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Web.UI.WebControls;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.FrmUserControl
|
||||||
|
{
|
||||||
|
[FormType(EnumFormType.WorkingDataRecord)]
|
||||||
|
public partial class frmPrinterMain : UserControl
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 页面信息语言文本列表
|
||||||
|
/// </summary>
|
||||||
|
private DataTable _InfoLanguageTextList;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 模板地址
|
||||||
|
/// </summary>
|
||||||
|
private string _reportFolder = Application.StartupPath + "\\ReportMd\\";
|
||||||
|
public frmPrinterMain()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
_InfoLanguageTextList = this.GetInfoLanguageText(GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
public delegate void dlgRefreshFrmHost();
|
||||||
|
public static dlgRefreshFrmHost RefreshFrmHost;
|
||||||
|
private void InitDtlData(string palletCode)
|
||||||
|
{
|
||||||
|
string sql = $@"SELECT WORKING_PALLET_DTL_ID 序号,IR_CODE IR条码,SHEET_TYPE_NAME 板材信息,INPUT_TIME 录入时间,CLEAN_MODE_NAME 清洗方式,CONTAMINATION_TYPE_NAME 污染类型,CONTAMINATION_DTL_NAME 污染明细, CURRENT_NUMBER 当前计数,USER_NAME 操作用户 FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = '{palletCode}'";
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
if (dt != null && dt.Rows.Count > 0)
|
||||||
|
{
|
||||||
|
kryptonDataGridView2.DataSource = dt;
|
||||||
|
kryptonDataGridView2.SetDataViewColumnText(this.Name + "." + kryptonDataGridView2.Name, GlobalHelper.LanguageCode);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
kryptonDataGridView2.DataSource = null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
bool isSlectRow = false;
|
||||||
|
private void Init()
|
||||||
|
{
|
||||||
|
string sql = $@"
|
||||||
|
SELECT
|
||||||
|
WORKING_PALLET_ID 序号,
|
||||||
|
WORKING_PALLET_CODE 托盘号,
|
||||||
|
WORKING_STATUS 作业状态,
|
||||||
|
USER_NAME 创建人,
|
||||||
|
CREATE_TIME 创建时间
|
||||||
|
FROM
|
||||||
|
VW_WORKING_PALLET
|
||||||
|
WHERE 1=1
|
||||||
|
";
|
||||||
|
if (!string.IsNullOrEmpty(ktb_palletMsg.Text))
|
||||||
|
{
|
||||||
|
sql += $" AND WORKING_PALLET_CODE like '%{ktb_palletMsg.Text}%'";
|
||||||
|
}
|
||||||
|
if (!string.IsNullOrEmpty(ktb_irMsg.Text))
|
||||||
|
{
|
||||||
|
sql += $" AND WORKING_PALLET_CODE in (select DISTINCT WORKING_PALLET_CODE from VW_WORKING_PALLET_MSG where IR_CODE like '%{ktb_irMsg.Text}%')";
|
||||||
|
}
|
||||||
|
if (kcmb_sheetType.SelectedIndex != 0)
|
||||||
|
{
|
||||||
|
sql += $" AND WORKING_PALLET_CODE in (select DISTINCT WORKING_PALLET_CODE from VW_WORKING_PALLET_MSG where SHEET_TYPE_CODE = '{((ListItem)kcmb_sheetType.SelectedItem).Value}')";
|
||||||
|
}
|
||||||
|
if (kdtp_InputStartTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $"AND WORKING_PALLET_CODE in (select DISTINCT WORKING_PALLET_CODE from VW_WORKING_PALLET_MSG where INPUT_TIME >= '{kdtp_InputStartTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}')";
|
||||||
|
}
|
||||||
|
if (kdtp_InputEndTime.Checked)
|
||||||
|
{
|
||||||
|
sql += $"AND WORKING_PALLET_CODE in (select DISTINCT WORKING_PALLET_CODE from VW_WORKING_PALLET_MSG where INPUT_TIME <= '{kdtp_InputEndTime.Value.ToString("yyyy-MM-dd HH:mm:ss")}')";
|
||||||
|
}
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
if (dt != null && dt.Rows.Count > 0)
|
||||||
|
{
|
||||||
|
//kryptonDataGridView1.DataSource = dt;
|
||||||
|
kryptonDataGridView1.Rows.Clear();
|
||||||
|
isSlectRow = false;
|
||||||
|
foreach (DataRow item in dt.Rows)
|
||||||
|
{
|
||||||
|
int index = kryptonDataGridView1.Rows.Add();
|
||||||
|
kryptonDataGridView1.Rows[index].Cells[1].Value = item["序号"].ToString();
|
||||||
|
kryptonDataGridView1.Rows[index].Cells[2].Value = item["托盘号"].ToString();
|
||||||
|
kryptonDataGridView1.Rows[index].Cells[3].Value = item["作业状态"].ToString();
|
||||||
|
kryptonDataGridView1.Rows[index].Cells[4].Value = item["创建人"].ToString();
|
||||||
|
kryptonDataGridView1.Rows[index].Cells[5].Value = item["创建时间"].ToString();
|
||||||
|
}
|
||||||
|
kryptonDataGridView1.SetDataViewColumnText(this.Name + "." + kryptonDataGridView1.Name, GlobalHelper.LanguageCode);
|
||||||
|
isSlectRow = true;
|
||||||
|
kryptonDataGridView1_SelectionChanged(kryptonDataGridView1, new EventArgs());
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
kryptonDataGridView1.SetDataViewColumnText(this.Name + "." + kryptonDataGridView1.Name, GlobalHelper.LanguageCode);
|
||||||
|
kryptonDataGridView1.Rows.Clear();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void txt_GotFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.ShowInputPanel();
|
||||||
|
}
|
||||||
|
private void txt_LostFocus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
KeyboardAutoPopUp.HideInputPanel();
|
||||||
|
}
|
||||||
|
private void InitControlEvent()
|
||||||
|
{
|
||||||
|
ktb_irMsg.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_irMsg.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
|
||||||
|
ktb_palletMsg.GotFocus += new EventHandler(txt_GotFocus); //获取焦点前发生事件
|
||||||
|
ktb_palletMsg.LostFocus += new EventHandler(txt_LostFocus); //失去焦点后发生事件
|
||||||
|
}
|
||||||
|
private void frmPrinterMain_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
InitControlEvent();
|
||||||
|
this.SetFormControlText(GlobalHelper.LanguageCode);
|
||||||
|
string sqlQuerySheetType = $@"SELECT SHEET_TYPE_CODE,SHEET_TYPE_NAME FROM BAS_SHEET_TYPE WHERE USED_FLAG = 1 and DEL_FLAG = 0 ORDER BY SHEET_TYPE_ID";
|
||||||
|
DataTable dtQuerySheetType = LeadDbHelperSQLite.Query(sqlQuerySheetType).Tables[0];
|
||||||
|
if (dtQuerySheetType != null && dtQuerySheetType.Rows.Count > 0)
|
||||||
|
{
|
||||||
|
kcmb_sheetType.Items.Clear();
|
||||||
|
kcmb_sheetType.Items.Add(new ListItem
|
||||||
|
{
|
||||||
|
Value = "",
|
||||||
|
Text = "Please Select",
|
||||||
|
});
|
||||||
|
foreach (DataRow item in dtQuerySheetType.Rows)
|
||||||
|
{
|
||||||
|
kcmb_sheetType.Items.Add(new ListItem
|
||||||
|
{
|
||||||
|
Value = item["SHEET_TYPE_CODE"].ToString(),
|
||||||
|
Text = item["SHEET_TYPE_NAME"].ToString(),
|
||||||
|
});
|
||||||
|
}
|
||||||
|
kcmb_sheetType.SelectedIndex = 0;
|
||||||
|
}
|
||||||
|
kdtp_InputStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_InputEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_InputEndTime.Checked = false;
|
||||||
|
kdtp_InputStartTime.Checked = false;
|
||||||
|
new EnvironmentSettings().ReportSettings.ShowProgress = false;
|
||||||
|
RefreshFrmHost = new dlgRefreshFrmHost(Init);
|
||||||
|
Init();
|
||||||
|
foreach (Control item in tableLayoutPanel2.Controls)
|
||||||
|
{
|
||||||
|
if (item.Tag == null)
|
||||||
|
{
|
||||||
|
DataRow[] drs = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{this.Name}' AND MENU_PID = '-1'");
|
||||||
|
DataRow[] drs1 = GlobalHelper.RoleMenuPermission.Select($" MENU_URL = '{item.Name}' AND MENU_PID = '{drs[0]["MENU_ID"]}'");
|
||||||
|
if (drs1.Length > 0)
|
||||||
|
{
|
||||||
|
item.Enabled = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
item.Enabled = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kryptonGroupBox1.Focus();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("加载作业数据查询界面发生异常", "LoadQueryWorkingDataExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#region 打印测试代码
|
||||||
|
private void kryptonButton1_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
kryptonButton1.Enabled = false;
|
||||||
|
try
|
||||||
|
{
|
||||||
|
string sql = $@"
|
||||||
|
SELECT
|
||||||
|
*
|
||||||
|
FROM
|
||||||
|
VW_WORKING_PALLET_MSG
|
||||||
|
WHERE
|
||||||
|
WORKING_PALLET_CODE = 'e2f4294d698a412d84c382fc4bba01a3'
|
||||||
|
AND IR_CODE = '32211'
|
||||||
|
";
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
if (dt != null && dt.Rows.Count > 0)
|
||||||
|
{
|
||||||
|
|
||||||
|
string sql1 = $@"SELECT CONTAMINATION_DTL_CODE Kind,CURRENT_NUMBER Qty FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = 'e2f4294d698a412d84c382fc4bba01a3' AND IR_CODE = '32211' AND CONTAMINATION_TYPE_CODE = 'PhysicalContamination'";
|
||||||
|
DataTable dt1 = LeadDbHelperSQLite.Query(sql1).Tables[0].Copy();
|
||||||
|
dt1.TableName = "Table1";
|
||||||
|
string sql2 = $@"SELECT CONTAMINATION_DTL_CODE Kind,CURRENT_NUMBER Qty FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = 'e2f4294d698a412d84c382fc4bba01a3' AND IR_CODE = '32211' AND CONTAMINATION_TYPE_CODE = 'ChemicalContamination'";
|
||||||
|
DataTable dt2 = LeadDbHelperSQLite.Query(sql2).Tables[0].Copy();
|
||||||
|
dt2.TableName = "Table2";
|
||||||
|
string sql3 = $@"SELECT CONTAMINATION_DTL_CODE Kind,CURRENT_NUMBER Qty FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = 'e2f4294d698a412d84c382fc4bba01a3' AND IR_CODE = '32211' AND CONTAMINATION_TYPE_CODE = 'MicrobiologicalContamination'";
|
||||||
|
DataTable dt3 = LeadDbHelperSQLite.Query(sql3).Tables[0].Copy();
|
||||||
|
dt3.TableName = "Table3";
|
||||||
|
|
||||||
|
string sql4 = $@"
|
||||||
|
SELECT
|
||||||
|
C.SHEET_TYPE_CODE Sheets,
|
||||||
|
SUM(CASE CLEAN_MODE_CODE WHEN 'SortedCleaned' THEN Qty ELSE 0 END) SortedCleaned,
|
||||||
|
SUM(CASE CLEAN_MODE_CODE WHEN 'SpecialCleaning' THEN Qty ELSE 0 END) SpecialCleaning,
|
||||||
|
SUM(CASE CLEAN_MODE_CODE WHEN 'Scrap' THEN Qty ELSE 0 END) Scrap,
|
||||||
|
SUM(CASE CLEAN_MODE_CODE WHEN 'Others' THEN Qty ELSE 0 END) Others,
|
||||||
|
IFNULL(C.TotalQty, 0) TotalQty
|
||||||
|
FROM
|
||||||
|
(
|
||||||
|
SELECT
|
||||||
|
A.SHEET_TYPE_CODE,
|
||||||
|
B.CLEAN_MODE_CODE,
|
||||||
|
B.Qty,
|
||||||
|
C.TotalQty
|
||||||
|
FROM
|
||||||
|
BAS_SHEET_TYPE A LEFT JOIN
|
||||||
|
(
|
||||||
|
SELECT
|
||||||
|
SHEET_TYPE_CODE,
|
||||||
|
SUM(CURRENT_NUMBER) TotalQty
|
||||||
|
FROM
|
||||||
|
VW_WORKING_PALLET_MSG
|
||||||
|
WHERE
|
||||||
|
WORKING_PALLET_CODE = 'e2f4294d698a412d84c382fc4bba01a3'
|
||||||
|
AND IR_CODE = '32211'
|
||||||
|
GROUP BY SHEET_TYPE_CODE) C ON A.SHEET_TYPE_CODE = C.SHEET_TYPE_CODE
|
||||||
|
LEFT JOIN (
|
||||||
|
SELECT
|
||||||
|
SHEET_TYPE_CODE,
|
||||||
|
CLEAN_MODE_CODE,
|
||||||
|
SUM(CURRENT_NUMBER) Qty
|
||||||
|
FROM
|
||||||
|
VW_WORKING_PALLET_MSG
|
||||||
|
WHERE
|
||||||
|
WORKING_PALLET_CODE = 'e2f4294d698a412d84c382fc4bba01a3'
|
||||||
|
AND IR_CODE = '32211'
|
||||||
|
GROUP BY CLEAN_MODE_CODE,SHEET_TYPE_CODE
|
||||||
|
) B ON C.SHEET_TYPE_CODE = B.SHEET_TYPE_CODE
|
||||||
|
) C
|
||||||
|
GROUP BY C.SHEET_TYPE_CODE,C.TotalQty
|
||||||
|
";
|
||||||
|
|
||||||
|
DataTable dt4 = LeadDbHelperSQLite.Query(sql4).Tables[0].Copy();
|
||||||
|
dt4.TableName = "Table4";
|
||||||
|
|
||||||
|
string sql5 = $@"
|
||||||
|
SELECT
|
||||||
|
SUM (CURRENT_NUMBER) CleanedSheets,
|
||||||
|
date (INPUT_TIME) DateAndTime,
|
||||||
|
USER_NAME Operator
|
||||||
|
FROM
|
||||||
|
VW_WORKING_PALLET_MSG
|
||||||
|
WHERE
|
||||||
|
WORKING_PALLET_CODE = 'e2f4294d698a412d84c382fc4bba01a3'
|
||||||
|
AND IR_CODE = '32211'
|
||||||
|
GROUP BY
|
||||||
|
date (INPUT_TIME),
|
||||||
|
OPERATE_USER_ID,
|
||||||
|
USER_CODE,
|
||||||
|
USER_NAME
|
||||||
|
";
|
||||||
|
|
||||||
|
|
||||||
|
DataTable dt5 = LeadDbHelperSQLite.Query(sql5).Tables[0].Copy();
|
||||||
|
dt5.TableName = "Table5";
|
||||||
|
|
||||||
|
string userName = dt.Rows[0]["USER_NAME"].ToString();
|
||||||
|
DateTime dateMsg = Convert.ToDateTime(dt.Rows[0]["INPUT_TIME"]);
|
||||||
|
string IRNumber = dt.Rows[0]["IR_CODE"].ToString();
|
||||||
|
string MacCode = "CleanMac_01";
|
||||||
|
FastReport.Report report = new FastReport.Report();
|
||||||
|
string filename = _reportFolder + "CleanMac_IRMsg_PrintMd.frx";
|
||||||
|
DataSet dts = new DataSet();
|
||||||
|
dts.Tables.Add(dt1);
|
||||||
|
dts.Tables.Add(dt2);
|
||||||
|
dts.Tables.Add(dt3);
|
||||||
|
dts.Tables.Add(dt4);
|
||||||
|
dts.Tables.Add(dt5);
|
||||||
|
report.Load(filename);
|
||||||
|
report.RegisterData(dts);
|
||||||
|
report.SetParameterValue("Parm_CusName", userName);
|
||||||
|
report.SetParameterValue("Parm_MachineCode", MacCode);
|
||||||
|
report.SetParameterValue("Parm_IRNumber", IRNumber);
|
||||||
|
report.SetParameterValue("Parm_RecDate", dateMsg);
|
||||||
|
report.SetParameterValue("Parm_RecordName", userName);
|
||||||
|
report.Prepare();
|
||||||
|
report.PrintSettings.ShowDialog = false;
|
||||||
|
report.Print();
|
||||||
|
report.Clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
MessageBox.Show(ex.Message);
|
||||||
|
}
|
||||||
|
kryptonButton1.Enabled = true;
|
||||||
|
}
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private void kbt_Reset_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
ktb_irMsg.Text = "";
|
||||||
|
ktb_palletMsg.Text = "";
|
||||||
|
kcmb_sheetType.SelectedIndex = 0;
|
||||||
|
|
||||||
|
kdtp_InputStartTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 00:00:00"));
|
||||||
|
kdtp_InputEndTime.Value = DateTime.Parse(DateTime.Now.ToString("yyyy-MM-dd 23:59:59"));
|
||||||
|
kdtp_InputEndTime.Checked = false;
|
||||||
|
kdtp_InputStartTime.Checked = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbt_Query_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
kryptonDataGridView2.DataSource = null;
|
||||||
|
Init();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("查询作业托盘数据发生异常", "QueryWorkingPalletDataExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kryptonDataGridView1_CellContentClick(object sender, DataGridViewCellEventArgs e)
|
||||||
|
{
|
||||||
|
if (e.ColumnIndex == 0)
|
||||||
|
{
|
||||||
|
KryptonDataGridViewCheckBoxCell checkcell = (KryptonDataGridViewCheckBoxCell)kryptonDataGridView1.CurrentCell;
|
||||||
|
if (Convert.ToBoolean(checkcell.EditedFormattedValue))
|
||||||
|
{
|
||||||
|
foreach (DataGridViewRow item in kryptonDataGridView1.Rows)
|
||||||
|
{
|
||||||
|
if (!item.IsNewRow && item != kryptonDataGridView1.CurrentRow)
|
||||||
|
{
|
||||||
|
item.Cells[0].Value = false;
|
||||||
|
item.Cells[0].Style.BackColor = Color.White;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
kryptonDataGridView1.CurrentCell.Style.BackColor = Color.FromArgb(51, 153, 255);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
kryptonDataGridView1.CurrentCell.Style.BackColor = Color.White;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kryptonDataGridView1_DataError(object sender, DataGridViewDataErrorEventArgs e)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kryptonDataGridView1_SelectionChanged(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (kryptonDataGridView1.SelectedRows.Count > 0 && isSlectRow)
|
||||||
|
{
|
||||||
|
string palletCode = kryptonDataGridView1.SelectedRows[0].Cells[2].Value.ToString();
|
||||||
|
InitDtlData(palletCode);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kryptonButton2_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
int rowCheck = 0;
|
||||||
|
string palletCodeMsg = string.Empty;
|
||||||
|
foreach (DataGridViewRow item in kryptonDataGridView1.Rows)
|
||||||
|
{
|
||||||
|
KryptonDataGridViewCheckBoxCell checkcell = (KryptonDataGridViewCheckBoxCell)item.Cells[0];
|
||||||
|
if (Convert.ToBoolean(checkcell.EditedFormattedValue))
|
||||||
|
{
|
||||||
|
rowCheck++;
|
||||||
|
palletCodeMsg = item.Cells[2].Value.ToString();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (rowCheck > 0)
|
||||||
|
{
|
||||||
|
string sqlWorkingIrMsg = $@"SELECT DISTINCT IR_CODE FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = '{palletCodeMsg}'";
|
||||||
|
|
||||||
|
DataTable dt_workingIrMsg = LeadDbHelperSQLite.Query(sqlWorkingIrMsg).Tables[0];
|
||||||
|
if (dt_workingIrMsg != null && dt_workingIrMsg.Rows.Count > 0)
|
||||||
|
{
|
||||||
|
foreach (DataRow item in dt_workingIrMsg.Rows)
|
||||||
|
{
|
||||||
|
string workingIrCodeMsg = item["IR_CODE"].ToString();
|
||||||
|
PrintWorkedIrMsg(workingIrCodeMsg);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
//KryptonMessageBox.Show("请勾选要打印的托盘数据行!!");
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请勾选要打印的托盘数据行!", "SelectWantToPrintRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("打印作业托盘数据发生异常", "PrintWorkingPalletDataExp") + $":【{ex.Message}】!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
private void PrintWorkedIrMsg(string workingIrCodeMsg)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】手动打印开始。~~~~~~~~~~~~~~", LogTypeEum.Run);
|
||||||
|
string sql = $@"
|
||||||
|
SELECT
|
||||||
|
*
|
||||||
|
FROM
|
||||||
|
VW_WORKING_PALLET_MSG
|
||||||
|
WHERE
|
||||||
|
IR_CODE = '{workingIrCodeMsg}'
|
||||||
|
";
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
if (dt != null && dt.Rows.Count > 0)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印明细数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run);
|
||||||
|
|
||||||
|
string sqlGroup = $@"
|
||||||
|
SELECT
|
||||||
|
CONTAMINATION_TYPE_CODE,
|
||||||
|
CONTAMINATION_DTL_CODE,
|
||||||
|
SUM(CURRENT_NUMBER) CURRENT_NUMBER
|
||||||
|
FROM
|
||||||
|
VW_WORKING_PALLET_MSG
|
||||||
|
WHERE
|
||||||
|
IR_CODE = '{workingIrCodeMsg}'
|
||||||
|
GROUP BY
|
||||||
|
CONTAMINATION_TYPE_CODE,
|
||||||
|
CONTAMINATION_DTL_CODE
|
||||||
|
";
|
||||||
|
DataTable dtGroup = LeadDbHelperSQLite.Query(sqlGroup).Tables[0];
|
||||||
|
|
||||||
|
#region 物理污染
|
||||||
|
//string sql1 = $@"SELECT CONTAMINATION_DTL_CODE Kind,CURRENT_NUMBER Qty FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = '{woringPalletMsg}' AND IR_CODE = '{workingIrCodeMsg}' AND CONTAMINATION_TYPE_CODE = 'PhysicalContamination'";
|
||||||
|
//DataTable dt1 = LeadDbHelperSQLite.Query(sql1).Tables[0].Copy();
|
||||||
|
|
||||||
|
DataRow[] drs = dtGroup.Select(" CONTAMINATION_TYPE_CODE = 'PhysicalContamination'");
|
||||||
|
if (drs != null && drs.Length > 0)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】物理污染 明细数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】物理污染 明细数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
DataTable dt1 = new DataTable();
|
||||||
|
dt1.Columns.Add("Kind", typeof(string));
|
||||||
|
dt1.Columns.Add("Qty", typeof(string));
|
||||||
|
foreach (DataRow item in drs)
|
||||||
|
{
|
||||||
|
DataRow row = dt1.NewRow();
|
||||||
|
row["Kind"] = item["CONTAMINATION_DTL_CODE"].ToString();
|
||||||
|
row["Qty"] = item["CURRENT_NUMBER"].ToString();
|
||||||
|
dt1.Rows.Add(row);
|
||||||
|
}
|
||||||
|
dt1.TableName = "Table1";
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
#region 化学污染
|
||||||
|
//string sql2 = $@"SELECT CONTAMINATION_DTL_CODE Kind,CURRENT_NUMBER Qty FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = '{woringPalletMsg}' AND IR_CODE = '{workingIrCodeMsg}' AND CONTAMINATION_TYPE_CODE = 'ChemicalContamination'";
|
||||||
|
//DataTable dt2 = LeadDbHelperSQLite.Query(sql2).Tables[0].Copy();
|
||||||
|
drs = dtGroup.Select(" CONTAMINATION_TYPE_CODE = 'ChemicalContamination'");
|
||||||
|
if (drs != null && drs.Length > 0)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】化学污染 明细数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】化学污染 明细数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
DataTable dt2 = dt1.Clone();
|
||||||
|
foreach (DataRow item in drs)
|
||||||
|
{
|
||||||
|
DataRow row = dt2.NewRow();
|
||||||
|
row["Kind"] = item["CONTAMINATION_DTL_CODE"].ToString();
|
||||||
|
row["Qty"] = item["CURRENT_NUMBER"].ToString();
|
||||||
|
dt2.Rows.Add(row);
|
||||||
|
}
|
||||||
|
dt2.TableName = "Table2";
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
#region 微生物污染
|
||||||
|
//string sql3 = $@"SELECT CONTAMINATION_DTL_CODE Kind,CURRENT_NUMBER Qty FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = '{woringPalletMsg}' AND IR_CODE = '{workingIrCodeMsg}' AND CONTAMINATION_TYPE_CODE = 'MicrobiologicalContamination'";
|
||||||
|
//DataTable dt3 = LeadDbHelperSQLite.Query(sql3).Tables[0].Copy();
|
||||||
|
drs = dtGroup.Select(" CONTAMINATION_TYPE_CODE = 'MicrobiologicalContamination'");
|
||||||
|
if (drs != null && drs.Length > 0)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】微生物污染 明细数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】微生物污染 明细数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
DataTable dt3 = dt1.Clone();
|
||||||
|
foreach (DataRow item in drs)
|
||||||
|
{
|
||||||
|
DataRow row = dt3.NewRow();
|
||||||
|
row["Kind"] = item["CONTAMINATION_DTL_CODE"].ToString();
|
||||||
|
row["Qty"] = item["CURRENT_NUMBER"].ToString();
|
||||||
|
dt3.Rows.Add(row);
|
||||||
|
}
|
||||||
|
dt3.TableName = "Table3";
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
string sql4 = $@"
|
||||||
|
SELECT
|
||||||
|
C.SHEET_TYPE_CODE Sheets,
|
||||||
|
SUM(CASE CLEAN_MODE_CODE WHEN 'SortedCleaned' THEN Qty ELSE 0 END) SortedCleaned,
|
||||||
|
SUM(CASE CLEAN_MODE_CODE WHEN 'SpecialCleaning' THEN Qty ELSE 0 END) SpecialCleaning,
|
||||||
|
SUM(CASE CLEAN_MODE_CODE WHEN 'Scrap' THEN Qty ELSE 0 END) Scrap,
|
||||||
|
SUM(CASE CLEAN_MODE_CODE WHEN 'Others' THEN Qty ELSE 0 END) Others,
|
||||||
|
IFNULL(C.TotalQty, 0) TotalQty
|
||||||
|
FROM
|
||||||
|
(
|
||||||
|
SELECT
|
||||||
|
A.SHEET_TYPE_CODE,
|
||||||
|
B.CLEAN_MODE_CODE,
|
||||||
|
B.Qty,
|
||||||
|
C.TotalQty
|
||||||
|
FROM
|
||||||
|
BAS_SHEET_TYPE A LEFT JOIN
|
||||||
|
(
|
||||||
|
SELECT
|
||||||
|
SHEET_TYPE_CODE,
|
||||||
|
SUM(CURRENT_NUMBER) TotalQty
|
||||||
|
FROM
|
||||||
|
VW_WORKING_PALLET_MSG
|
||||||
|
WHERE
|
||||||
|
IR_CODE = '{workingIrCodeMsg}'
|
||||||
|
GROUP BY SHEET_TYPE_CODE) C ON A.SHEET_TYPE_CODE = C.SHEET_TYPE_CODE
|
||||||
|
LEFT JOIN (
|
||||||
|
SELECT
|
||||||
|
SHEET_TYPE_CODE,
|
||||||
|
CLEAN_MODE_CODE,
|
||||||
|
SUM(CURRENT_NUMBER) Qty
|
||||||
|
FROM
|
||||||
|
VW_WORKING_PALLET_MSG
|
||||||
|
WHERE
|
||||||
|
IR_CODE = '{workingIrCodeMsg}'
|
||||||
|
GROUP BY CLEAN_MODE_CODE,SHEET_TYPE_CODE
|
||||||
|
) B ON C.SHEET_TYPE_CODE = B.SHEET_TYPE_CODE
|
||||||
|
) C
|
||||||
|
GROUP BY C.SHEET_TYPE_CODE,C.TotalQty
|
||||||
|
";
|
||||||
|
DataTable dt4 = LeadDbHelperSQLite.Query(sql4).Tables[0].Copy();
|
||||||
|
if (dt4 != null && dt4.Rows.Count > 0)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】按照板材分类和清洗方式统计的数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】按照板材分类和清洗方式统计的数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
dt4.TableName = "Table4";
|
||||||
|
string sql5 = $@"
|
||||||
|
SELECT
|
||||||
|
SUM (CURRENT_NUMBER) CleanedSheets,
|
||||||
|
date (INPUT_TIME) DateAndTime,
|
||||||
|
USER_NAME Operator
|
||||||
|
FROM
|
||||||
|
VW_WORKING_PALLET_MSG
|
||||||
|
WHERE
|
||||||
|
IR_CODE = '{workingIrCodeMsg}'
|
||||||
|
GROUP BY
|
||||||
|
date (INPUT_TIME),
|
||||||
|
OPERATE_USER_ID,
|
||||||
|
USER_CODE,
|
||||||
|
USER_NAME
|
||||||
|
";
|
||||||
|
DataTable dt5 = LeadDbHelperSQLite.Query(sql5).Tables[0].Copy();
|
||||||
|
if (dt5 != null && dt5.Rows.Count > 0)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】操作员每日作业板材数量的数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】操作员每日作业板材数量的数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
dt5.TableName = "Table5";
|
||||||
|
string userName = dt.Rows[0]["USER_NAME"].ToString();
|
||||||
|
DateTime dateMsg = Convert.ToDateTime(dt.Rows[0]["INPUT_TIME"]);
|
||||||
|
string IRNumber = dt.Rows[0]["IR_CODE"].ToString();
|
||||||
|
string MacCode = GlobalHelper.ParameterList.Select(" PARAMETER_CODE = 'CleanMachineName'")[0]["PARAMETER_VALUE"].ToString();
|
||||||
|
|
||||||
|
string sqlCleanedNum = $@"
|
||||||
|
SELECT
|
||||||
|
SUM(CURRENT_NUMBER) CURRENT_NUMBER
|
||||||
|
FROM
|
||||||
|
VW_WORKING_PALLET_MSG
|
||||||
|
WHERE
|
||||||
|
IR_CODE = '{workingIrCodeMsg}'
|
||||||
|
AND CLEAN_MODE_CODE = 'SortedCleaned'
|
||||||
|
";
|
||||||
|
DataTable dtCleanedNum = LeadDbHelperSQLite.Query(sqlCleanedNum).Tables[0];
|
||||||
|
string cleanNum = dtCleanedNum.Rows[0][0].ToString();
|
||||||
|
|
||||||
|
string sqlPalletNum = $@"
|
||||||
|
SELECT
|
||||||
|
DISTINCT WORKING_PALLET_CODE
|
||||||
|
FROM
|
||||||
|
VW_WORKING_PALLET_MSG
|
||||||
|
WHERE
|
||||||
|
IR_CODE = '{workingIrCodeMsg}'
|
||||||
|
";
|
||||||
|
DataTable dtPalletNum = LeadDbHelperSQLite.Query(sqlPalletNum).Tables[0];
|
||||||
|
string palletNum = dtPalletNum.Rows.Count.ToString();
|
||||||
|
|
||||||
|
string sqlScrapNum = $@"
|
||||||
|
SELECT
|
||||||
|
SUM(CURRENT_NUMBER) CURRENT_NUMBER
|
||||||
|
FROM
|
||||||
|
VW_WORKING_PALLET_MSG
|
||||||
|
WHERE
|
||||||
|
IR_CODE = '{workingIrCodeMsg}'
|
||||||
|
AND CLEAN_MODE_CODE <> 'SortedCleaned'
|
||||||
|
";
|
||||||
|
DataTable dtScrapNum = LeadDbHelperSQLite.Query(sqlScrapNum).Tables[0];
|
||||||
|
string scrapNum = dtScrapNum.Rows[0][0].ToString();
|
||||||
|
|
||||||
|
DataSet dts = new DataSet();
|
||||||
|
dts.Tables.Add(dt1);
|
||||||
|
dts.Tables.Add(dt2);
|
||||||
|
dts.Tables.Add(dt3);
|
||||||
|
dts.Tables.Add(dt4);
|
||||||
|
dts.Tables.Add(dt5);
|
||||||
|
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印模板所需要的数据拼装完成!~~~~~~~~~~~~~~", LogTypeEum.Run);
|
||||||
|
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】开始加载打印控件类!~~~~~~~~~~~~~~", LogTypeEum.Run);
|
||||||
|
|
||||||
|
FastReport.Report report = new FastReport.Report();
|
||||||
|
string filename = _reportFolder + "CleanMac_IRMsg_PrintMd.frx";
|
||||||
|
report.Load(filename);
|
||||||
|
report.RegisterData(dts);
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印控件类加载完成,数据传入成功!~~~~~~~~~~~~~~", LogTypeEum.Run);
|
||||||
|
|
||||||
|
report.SetParameterValue("Parm_CusName", userName);
|
||||||
|
report.SetParameterValue("Parm_MachineCode", MacCode);
|
||||||
|
report.SetParameterValue("Parm_IRNumber", IRNumber);
|
||||||
|
report.SetParameterValue("Parm_RecDate", dateMsg);
|
||||||
|
report.SetParameterValue("Parm_RecordName", userName);
|
||||||
|
report.SetParameterValue("Parm_CleanedNum", cleanNum);
|
||||||
|
report.SetParameterValue("Parm_PalletNumber", palletNum);
|
||||||
|
report.SetParameterValue("Parm_ScrapNumber", scrapNum);
|
||||||
|
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印控件类所需参数设置成功,开始发送打印机数据!~~~~~~~~~~~~~~", LogTypeEum.Run);
|
||||||
|
report.Prepare();
|
||||||
|
report.PrintSettings.ShowDialog = false;
|
||||||
|
report.Print();
|
||||||
|
report.Clear();
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印控件类发送打印机数据成功!~~~~~~~~~~~~~~", LogTypeEum.Run);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印明细数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】手动打印结束。~~~~~~~~~~~~~~", LogTypeEum.Run);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void kbtn_EditWorkingPalletData_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
int rowCheck = 0;
|
||||||
|
string palletCodeMsg = string.Empty;
|
||||||
|
foreach (DataGridViewRow item in kryptonDataGridView1.Rows)
|
||||||
|
{
|
||||||
|
KryptonDataGridViewCheckBoxCell checkcell = (KryptonDataGridViewCheckBoxCell)item.Cells[0];
|
||||||
|
if (Convert.ToBoolean(checkcell.EditedFormattedValue))
|
||||||
|
{
|
||||||
|
rowCheck++;
|
||||||
|
palletCodeMsg = item.Cells[2].Value.ToString();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (rowCheck > 0)
|
||||||
|
{
|
||||||
|
frmEditWorkingPalletData frm = new frmEditWorkingPalletData();
|
||||||
|
frm.PalletCode = palletCodeMsg;
|
||||||
|
frm.ShowDialog();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
//KryptonMessageBox.Show("请勾选要编辑的作业托盘数据行!!");
|
||||||
|
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请勾选要编辑的作业托盘数据行!", "SelectWantToEditRow"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
123
CleanMachineHMI/FrmUserControl/frmPrinterMain.resx
Normal file
@@ -0,0 +1,123 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<metadata name="Column1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
</root>
|
||||||
18
CleanMachineHMI/Model/BasCleanTypeMsg.cs
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI
|
||||||
|
{
|
||||||
|
public class BasCleanTypeMsg
|
||||||
|
{
|
||||||
|
public string CLEAN_MODE_CODE { get; set; }
|
||||||
|
public string CLEAN_MODE_NAME { get; set; }
|
||||||
|
public string CONTAMINATION_TYPE_CODE { get; set; }
|
||||||
|
public string CONTAMINATION_TYPE_NAME { get; set; }
|
||||||
|
public string CONTAMINATION_DTL_CODE { get; set; }
|
||||||
|
public string CONTAMINATION_DTL_NAME { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
22
CleanMachineHMI/Model/BasPlcItemMd.cs
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI
|
||||||
|
{
|
||||||
|
public class BasPlcItemMd
|
||||||
|
{
|
||||||
|
public int PlcItemId { get; set; }
|
||||||
|
public string PlcItemCode { get; set; }
|
||||||
|
public string PlcItemName { get; set; }
|
||||||
|
public int PlcItemType { get; set; }
|
||||||
|
public int PlcItemDataType { get; set; }
|
||||||
|
public string PlcItemPriAddress { get; set; }
|
||||||
|
public string PlcItemModbusAddress { get; set; }
|
||||||
|
public string PlcItemDeviationAddress { get; set; }
|
||||||
|
public string PlcItemValue { get; set; }
|
||||||
|
public int PlcItemDataLen { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
17
CleanMachineHMI/Model/Bas_WarningMd.cs
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI
|
||||||
|
{
|
||||||
|
public class Bas_WarningMd
|
||||||
|
{
|
||||||
|
public string WarningCode { get; set; }
|
||||||
|
public string WarningName { get; set; }
|
||||||
|
public string PlcItemCode { get; set; }
|
||||||
|
public string WarningType { get; set; }
|
||||||
|
public string WarningMessage { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
29
CleanMachineHMI/Model/CM_WarningLogMd.cs
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI
|
||||||
|
{
|
||||||
|
public class CM_WarningLogMd
|
||||||
|
{
|
||||||
|
public string WarningCode { get; set; }
|
||||||
|
public string WarningName { get; set; }
|
||||||
|
public string WarningType { get; set; }
|
||||||
|
public string WarningMessage { get; set; }
|
||||||
|
public DateTime WarningTime { get; set; }
|
||||||
|
public string PlcItemCode { get; set; }
|
||||||
|
public int WarningStatus { get; set; }
|
||||||
|
public int WarningHandleResult { get; set; }
|
||||||
|
public DateTime WarningHandleTime { get; set; }
|
||||||
|
|
||||||
|
public int CreateBy { get; set; }
|
||||||
|
public DateTime CreateTime { get; set; }
|
||||||
|
|
||||||
|
public int UpdateBy { get; set; }
|
||||||
|
public DateTime UpdateTime { get; set; }
|
||||||
|
|
||||||
|
public int DataVersion { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
38
CleanMachineHMI/Program.cs
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.Domain.Models.ViewModels;
|
||||||
|
using CleanMachineHMI.forms;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Reflection;
|
||||||
|
using System.Threading;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI
|
||||||
|
{
|
||||||
|
static class Program
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 应用程序的主入口点。
|
||||||
|
/// </summary>
|
||||||
|
[STAThread]
|
||||||
|
static void Main()
|
||||||
|
{
|
||||||
|
bool canCreateNew;
|
||||||
|
Mutex m = new Mutex(true, "DRM1", out canCreateNew);
|
||||||
|
if (canCreateNew)
|
||||||
|
{
|
||||||
|
Application.EnableVisualStyles();
|
||||||
|
Application.SetCompatibleTextRenderingDefault(false);
|
||||||
|
GlobalHelper.LoadAllFormData();
|
||||||
|
Application.Run(GlobalHelper.LoginForm);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
KryptonMessageBox.Show("The program is running!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
36
CleanMachineHMI/Properties/AssemblyInfo.cs
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
using System.Reflection;
|
||||||
|
using System.Runtime.CompilerServices;
|
||||||
|
using System.Runtime.InteropServices;
|
||||||
|
|
||||||
|
// 有关程序集的一般信息由以下
|
||||||
|
// 控制。更改这些特性值可修改
|
||||||
|
// 与程序集关联的信息。
|
||||||
|
[assembly: AssemblyTitle("CleanMachineHMI")]
|
||||||
|
[assembly: AssemblyDescription("")]
|
||||||
|
[assembly: AssemblyConfiguration("")]
|
||||||
|
[assembly: AssemblyCompany("")]
|
||||||
|
[assembly: AssemblyProduct("CleanMachineHMI")]
|
||||||
|
[assembly: AssemblyCopyright("Copyright © 2020")]
|
||||||
|
[assembly: AssemblyTrademark("")]
|
||||||
|
[assembly: AssemblyCulture("")]
|
||||||
|
|
||||||
|
// 将 ComVisible 设置为 false 会使此程序集中的类型
|
||||||
|
//对 COM 组件不可见。如果需要从 COM 访问此程序集中的类型
|
||||||
|
//请将此类型的 ComVisible 特性设置为 true。
|
||||||
|
[assembly: ComVisible(false)]
|
||||||
|
|
||||||
|
// 如果此项目向 COM 公开,则下列 GUID 用于类型库的 ID
|
||||||
|
[assembly: Guid("9cf77369-b471-4476-9f42-779945113ea5")]
|
||||||
|
|
||||||
|
// 程序集的版本信息由下列四个值组成:
|
||||||
|
//
|
||||||
|
// 主版本
|
||||||
|
// 次版本
|
||||||
|
// 生成号
|
||||||
|
// 修订号
|
||||||
|
//
|
||||||
|
//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值
|
||||||
|
//通过使用 "*",如下所示:
|
||||||
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
|
[assembly: AssemblyVersion("1.0.0.35")]
|
||||||
|
[assembly: AssemblyFileVersion("1.0.0.35")]
|
||||||
123
CleanMachineHMI/Properties/Resources.Designer.cs
generated
Normal file
@@ -0,0 +1,123 @@
|
|||||||
|
//------------------------------------------------------------------------------
|
||||||
|
// <auto-generated>
|
||||||
|
// 此代码由工具生成。
|
||||||
|
// 运行时版本:4.0.30319.42000
|
||||||
|
//
|
||||||
|
// 对此文件的更改可能会导致不正确的行为,并且如果
|
||||||
|
// 重新生成代码,这些更改将会丢失。
|
||||||
|
// </auto-generated>
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.Properties {
|
||||||
|
using System;
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 一个强类型的资源类,用于查找本地化的字符串等。
|
||||||
|
/// </summary>
|
||||||
|
// 此类是由 StronglyTypedResourceBuilder
|
||||||
|
// 类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。
|
||||||
|
// 若要添加或移除成员,请编辑 .ResX 文件,然后重新运行 ResGen
|
||||||
|
// (以 /str 作为命令选项),或重新生成 VS 项目。
|
||||||
|
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "16.0.0.0")]
|
||||||
|
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||||
|
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||||
|
internal class Resources {
|
||||||
|
|
||||||
|
private static global::System.Resources.ResourceManager resourceMan;
|
||||||
|
|
||||||
|
private static global::System.Globalization.CultureInfo resourceCulture;
|
||||||
|
|
||||||
|
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
|
||||||
|
internal Resources() {
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 返回此类使用的缓存的 ResourceManager 实例。
|
||||||
|
/// </summary>
|
||||||
|
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||||
|
internal static global::System.Resources.ResourceManager ResourceManager {
|
||||||
|
get {
|
||||||
|
if (object.ReferenceEquals(resourceMan, null)) {
|
||||||
|
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("CleanMachineHMI.Properties.Resources", typeof(Resources).Assembly);
|
||||||
|
resourceMan = temp;
|
||||||
|
}
|
||||||
|
return resourceMan;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重写当前线程的 CurrentUICulture 属性,对
|
||||||
|
/// 使用此强类型资源类的所有资源查找执行重写。
|
||||||
|
/// </summary>
|
||||||
|
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||||
|
internal static global::System.Globalization.CultureInfo Culture {
|
||||||
|
get {
|
||||||
|
return resourceCulture;
|
||||||
|
}
|
||||||
|
set {
|
||||||
|
resourceCulture = value;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 查找 System.Drawing.Bitmap 类型的本地化资源。
|
||||||
|
/// </summary>
|
||||||
|
internal static System.Drawing.Bitmap add {
|
||||||
|
get {
|
||||||
|
object obj = ResourceManager.GetObject("add", resourceCulture);
|
||||||
|
return ((System.Drawing.Bitmap)(obj));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 查找 System.Drawing.Bitmap 类型的本地化资源。
|
||||||
|
/// </summary>
|
||||||
|
internal static System.Drawing.Bitmap conn {
|
||||||
|
get {
|
||||||
|
object obj = ResourceManager.GetObject("conn", resourceCulture);
|
||||||
|
return ((System.Drawing.Bitmap)(obj));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 查找 System.Drawing.Bitmap 类型的本地化资源。
|
||||||
|
/// </summary>
|
||||||
|
internal static System.Drawing.Bitmap 上升 {
|
||||||
|
get {
|
||||||
|
object obj = ResourceManager.GetObject("上升", resourceCulture);
|
||||||
|
return ((System.Drawing.Bitmap)(obj));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 查找 System.Drawing.Bitmap 类型的本地化资源。
|
||||||
|
/// </summary>
|
||||||
|
internal static System.Drawing.Bitmap 上升_1 {
|
||||||
|
get {
|
||||||
|
object obj = ResourceManager.GetObject("上升_1", resourceCulture);
|
||||||
|
return ((System.Drawing.Bitmap)(obj));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 查找 System.Drawing.Bitmap 类型的本地化资源。
|
||||||
|
/// </summary>
|
||||||
|
internal static System.Drawing.Bitmap 下降 {
|
||||||
|
get {
|
||||||
|
object obj = ResourceManager.GetObject("下降", resourceCulture);
|
||||||
|
return ((System.Drawing.Bitmap)(obj));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 查找 System.Drawing.Bitmap 类型的本地化资源。
|
||||||
|
/// </summary>
|
||||||
|
internal static System.Drawing.Bitmap 下降_1 {
|
||||||
|
get {
|
||||||
|
object obj = ResourceManager.GetObject("下降_1", resourceCulture);
|
||||||
|
return ((System.Drawing.Bitmap)(obj));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
139
CleanMachineHMI/Properties/Resources.resx
Normal file
@@ -0,0 +1,139 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||||
|
<data name="add" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||||
|
<value>..\Resources\add.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||||
|
</data>
|
||||||
|
<data name="conn" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||||
|
<value>..\Resources\conn.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||||
|
</data>
|
||||||
|
<data name="上升" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||||
|
<value>..\Resources\上升.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||||
|
</data>
|
||||||
|
<data name="上升_1" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||||
|
<value>..\Resources\上升_1.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||||
|
</data>
|
||||||
|
<data name="下降" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||||
|
<value>..\Resources\下降.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||||
|
</data>
|
||||||
|
<data name="下降_1" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||||
|
<value>..\Resources\下降_1.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||||
|
</data>
|
||||||
|
</root>
|
||||||
37
CleanMachineHMI/Properties/Settings.Designer.cs
generated
Normal file
@@ -0,0 +1,37 @@
|
|||||||
|
//------------------------------------------------------------------------------
|
||||||
|
// <auto-generated>
|
||||||
|
// 此代码由工具生成。
|
||||||
|
// 运行时版本:4.0.30319.42000
|
||||||
|
//
|
||||||
|
// 对此文件的更改可能会导致不正确的行为,并且如果
|
||||||
|
// 重新生成代码,这些更改将会丢失。
|
||||||
|
// </auto-generated>
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.Properties {
|
||||||
|
|
||||||
|
|
||||||
|
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||||
|
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "16.7.0.0")]
|
||||||
|
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
|
||||||
|
|
||||||
|
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
|
||||||
|
|
||||||
|
public static Settings Default {
|
||||||
|
get {
|
||||||
|
return defaultInstance;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
[global::System.Configuration.ApplicationScopedSettingAttribute()]
|
||||||
|
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||||
|
[global::System.Configuration.SpecialSettingAttribute(global::System.Configuration.SpecialSetting.ConnectionString)]
|
||||||
|
[global::System.Configuration.DefaultSettingValueAttribute("Data Source=.;Initial Catalog=NX_CLEAR_MAC_20200915;Persist Security Info=True;Us" +
|
||||||
|
"er ID=sa;Password=1q2w3e4r!@")]
|
||||||
|
public string NX_CLEAR_MAC_20200915ConnectionString {
|
||||||
|
get {
|
||||||
|
return ((string)(this["NX_CLEAR_MAC_20200915ConnectionString"]));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
14
CleanMachineHMI/Properties/Settings.settings
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
<?xml version='1.0' encoding='utf-8'?>
|
||||||
|
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)" GeneratedClassNamespace="CleanMachineHMI.Properties" GeneratedClassName="Settings">
|
||||||
|
<Profiles />
|
||||||
|
<Settings>
|
||||||
|
<Setting Name="NX_CLEAR_MAC_20200915ConnectionString" Type="(Connection string)" Scope="Application">
|
||||||
|
<DesignTimeValue Profile="(Default)"><?xml version="1.0" encoding="utf-16"?>
|
||||||
|
<SerializableConnectionString xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
|
||||||
|
<ConnectionString>Data Source=.;Initial Catalog=NX_CLEAR_MAC_20200915;Persist Security Info=True;User ID=sa;Password=1q2w3e4r!@</ConnectionString>
|
||||||
|
<ProviderName>System.Data.SqlClient</ProviderName>
|
||||||
|
</SerializableConnectionString></DesignTimeValue>
|
||||||
|
<Value Profile="(Default)">Data Source=.;Initial Catalog=NX_CLEAR_MAC_20200915;Persist Security Info=True;User ID=sa;Password=1q2w3e4r!@</Value>
|
||||||
|
</Setting>
|
||||||
|
</Settings>
|
||||||
|
</SettingsFile>
|
||||||
33
CleanMachineHMI/ReportMd/CleanMac_IRMsg_PrintMd.frd
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<Dictionary>
|
||||||
|
<TableDataSource Name="Table1" ReferenceName="Data.Table1" DataType="System.Int32" Enabled="true">
|
||||||
|
<Column Name="Kind" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="Qty" DataType="System.String" PropName="Column"/>
|
||||||
|
</TableDataSource>
|
||||||
|
<TableDataSource Name="Table2" ReferenceName="Data.Table2" DataType="System.Int32" Enabled="true">
|
||||||
|
<Column Name="Kind" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="Qty" DataType="System.String" PropName="Column"/>
|
||||||
|
</TableDataSource>
|
||||||
|
<TableDataSource Name="Table3" ReferenceName="Data.Table3" DataType="System.Int32" Enabled="true">
|
||||||
|
<Column Name="Kind" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="Qty" DataType="System.String" PropName="Column"/>
|
||||||
|
</TableDataSource>
|
||||||
|
<TableDataSource Name="Table4" ReferenceName="Data.Table4" DataType="System.Int32" Enabled="true">
|
||||||
|
<Column Name="Sheets" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="SortedCleaned" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="SpecialCleaning" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="Scrap" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="Others" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="TotalQty" DataType="System.String" PropName="Column"/>
|
||||||
|
</TableDataSource>
|
||||||
|
<TableDataSource Name="Table5" ReferenceName="Data.Table5" DataType="System.Int32" Enabled="true">
|
||||||
|
<Column Name="CleanedSheets" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="DateAndTime" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="Operator" DataType="System.String" PropName="Column"/>
|
||||||
|
</TableDataSource>
|
||||||
|
<Parameter Name="Parm_CusName" DataType="System.String"/>
|
||||||
|
<Parameter Name="Parm_MachineCode" DataType="System.String"/>
|
||||||
|
<Parameter Name="Parm_IRNumber" DataType="System.String"/>
|
||||||
|
<Parameter Name="Parm_RecDate" DataType="System.String"/>
|
||||||
|
<Parameter Name="Parm_RecordName" DataType="System.String"/>
|
||||||
|
</Dictionary>
|
||||||
365
CleanMachineHMI/ReportMd/CleanMac_IRMsg_PrintMd.frx
Normal file
@@ -0,0 +1,365 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<Report ScriptLanguage="CSharp" ReportInfo.Created="10/12/2020 11:31:31" ReportInfo.Modified="01/14/2021 15:15:33" ReportInfo.CreatorVersion="2014.4.8.0">
|
||||||
|
<ScriptText>using System;
|
||||||
|
using System.Collections;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Data;
|
||||||
|
using FastReport;
|
||||||
|
using FastReport.Data;
|
||||||
|
using FastReport.Dialog;
|
||||||
|
using FastReport.Barcode;
|
||||||
|
using FastReport.Table;
|
||||||
|
using FastReport.Utils;
|
||||||
|
|
||||||
|
namespace FastReport
|
||||||
|
{
|
||||||
|
public class ReportScript
|
||||||
|
{
|
||||||
|
|
||||||
|
private void Table1_ManualBuild(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
TableCell tab1=new TableCell();
|
||||||
|
tab1.HorzAlign=HorzAlign.Center;
|
||||||
|
tab1.VertAlign=VertAlign.Center;
|
||||||
|
tab1.FillColor=Color.LightGray;
|
||||||
|
tab1.Border.Lines=BorderLines.All;
|
||||||
|
tab1.Border.Color=Color.Black;
|
||||||
|
tab1.Font=new Font("宋体",9);
|
||||||
|
|
||||||
|
|
||||||
|
DataSourceBase data1 = Report.GetDataSource("Table1"); // 获取DataSet中表名为Table1的数据源
|
||||||
|
data1.Init(); // 初始化
|
||||||
|
|
||||||
|
Table1.PrintRow(0); // 控件Table1打印第0行
|
||||||
|
Table1.PrintColumns(); // 每打印一行,都要调用 PrintColumn或PrintColumns
|
||||||
|
int index = 0;
|
||||||
|
while(data1.HasMoreRows) // 打印重复循环的行
|
||||||
|
{
|
||||||
|
|
||||||
|
Table1.PrintRow(1);
|
||||||
|
Table1.PrintColumns();
|
||||||
|
|
||||||
|
if((++index)%2==0)
|
||||||
|
{
|
||||||
|
for(int i=0;i<Table1.ColumnCount;i++)
|
||||||
|
{
|
||||||
|
Table1.ResultTable.Rows[index][i].SetStyle(tab1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
data1.Next(); // 读取下一行
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Table6_ManualBuild(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
TableCell tab1=new TableCell();
|
||||||
|
tab1.HorzAlign=HorzAlign.Center;
|
||||||
|
tab1.VertAlign=VertAlign.Center;
|
||||||
|
tab1.FillColor=Color.LightGray;
|
||||||
|
tab1.Border.Lines=BorderLines.All;
|
||||||
|
tab1.Border.Color=Color.Black;
|
||||||
|
tab1.Font=new Font("宋体",9);
|
||||||
|
|
||||||
|
|
||||||
|
DataSourceBase data1 = Report.GetDataSource("Table2"); // 获取DataSet中表名为Table1的数据源
|
||||||
|
data1.Init(); // 初始化
|
||||||
|
|
||||||
|
Table6.PrintRow(0); // 控件Table1打印第0行
|
||||||
|
Table6.PrintColumns(); // 每打印一行,都要调用 PrintColumn或PrintColumns
|
||||||
|
int index = 0;
|
||||||
|
while(data1.HasMoreRows) // 打印重复循环的行
|
||||||
|
{
|
||||||
|
|
||||||
|
Table6.PrintRow(1);
|
||||||
|
Table6.PrintColumns();
|
||||||
|
|
||||||
|
if((++index)%2==0)
|
||||||
|
{
|
||||||
|
for(int i=0;i<Table6.ColumnCount;i++)
|
||||||
|
{
|
||||||
|
Table6.ResultTable.Rows[index][i].SetStyle(tab1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
data1.Next(); // 读取下一行
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Table7_ManualBuild(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
TableCell tab1=new TableCell();
|
||||||
|
tab1.HorzAlign=HorzAlign.Center;
|
||||||
|
tab1.VertAlign=VertAlign.Center;
|
||||||
|
tab1.FillColor=Color.LightGray;
|
||||||
|
tab1.Border.Lines=BorderLines.All;
|
||||||
|
tab1.Border.Color=Color.Black;
|
||||||
|
tab1.Font=new Font("宋体",9);
|
||||||
|
|
||||||
|
|
||||||
|
DataSourceBase data1 = Report.GetDataSource("Table3"); // 获取DataSet中表名为Table1的数据源
|
||||||
|
data1.Init(); // 初始化
|
||||||
|
|
||||||
|
Table7.PrintRow(0); // 控件Table1打印第0行
|
||||||
|
Table7.PrintColumns(); // 每打印一行,都要调用 PrintColumn或PrintColumns
|
||||||
|
int index = 0;
|
||||||
|
while(data1.HasMoreRows) // 打印重复循环的行
|
||||||
|
{
|
||||||
|
|
||||||
|
Table7.PrintRow(1);
|
||||||
|
Table7.PrintColumns();
|
||||||
|
|
||||||
|
if((++index)%2==0)
|
||||||
|
{
|
||||||
|
for(int i=0;i<Table7.ColumnCount;i++)
|
||||||
|
{
|
||||||
|
Table7.ResultTable.Rows[index][i].SetStyle(tab1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
data1.Next(); // 读取下一行
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Table4_ManualBuild(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
TableCell tab1=new TableCell();
|
||||||
|
tab1.HorzAlign=HorzAlign.Center;
|
||||||
|
tab1.VertAlign=VertAlign.Center;
|
||||||
|
tab1.FillColor=Color.LightGray;
|
||||||
|
tab1.Border.Lines=BorderLines.All;
|
||||||
|
tab1.Border.Color=Color.Black;
|
||||||
|
tab1.Font=new Font("宋体",9);
|
||||||
|
|
||||||
|
|
||||||
|
DataSourceBase data1 = Report.GetDataSource("Table5"); // 获取DataSet中表名为Table1的数据源
|
||||||
|
data1.Init(); // 初始化
|
||||||
|
|
||||||
|
Table4.PrintRow(0); // 控件Table1打印第0行
|
||||||
|
Table4.PrintColumns(); // 每打印一行,都要调用 PrintColumn或PrintColumns
|
||||||
|
int index = 0;
|
||||||
|
while(data1.HasMoreRows) // 打印重复循环的行
|
||||||
|
{
|
||||||
|
|
||||||
|
Table4.PrintRow(1);
|
||||||
|
Table4.PrintColumns();
|
||||||
|
|
||||||
|
if((++index)%2==0)
|
||||||
|
{
|
||||||
|
for(int i=0;i<Table4.ColumnCount;i++)
|
||||||
|
{
|
||||||
|
Table4.ResultTable.Rows[index][i].SetStyle(tab1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
data1.Next(); // 读取下一行
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Table5_ManualBuild(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
TableCell tab1=new TableCell();
|
||||||
|
tab1.HorzAlign=HorzAlign.Center;
|
||||||
|
tab1.VertAlign=VertAlign.Center;
|
||||||
|
tab1.FillColor=Color.LightGray;
|
||||||
|
tab1.Border.Lines=BorderLines.All;
|
||||||
|
tab1.Border.Color=Color.Black;
|
||||||
|
tab1.Font=new Font("宋体",9);
|
||||||
|
|
||||||
|
|
||||||
|
DataSourceBase data1 = Report.GetDataSource("Table4"); // 获取DataSet中表名为Table1的数据源
|
||||||
|
data1.Init(); // 初始化
|
||||||
|
|
||||||
|
Table5.PrintRow(0); // 控件Table1打印第0行
|
||||||
|
Table5.PrintColumns(); // 每打印一行,都要调用 PrintColumn或PrintColumns
|
||||||
|
int index = 0;
|
||||||
|
while(data1.HasMoreRows) // 打印重复循环的行
|
||||||
|
{
|
||||||
|
|
||||||
|
Table5.PrintRow(1);
|
||||||
|
Table5.PrintColumns();
|
||||||
|
|
||||||
|
if((++index)%2==0)
|
||||||
|
{
|
||||||
|
for(int i=0;i<Table5.ColumnCount;i++)
|
||||||
|
{
|
||||||
|
Table5.ResultTable.Rows[index][i].SetStyle(tab1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
data1.Next(); // 读取下一行
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</ScriptText>
|
||||||
|
<Dictionary>
|
||||||
|
<TableDataSource Name="Table1" ReferenceName="Data.Table1" DataType="System.Int32" Enabled="true">
|
||||||
|
<Column Name="Kind" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="Qty" DataType="System.String" PropName="Column"/>
|
||||||
|
</TableDataSource>
|
||||||
|
<TableDataSource Name="Table2" ReferenceName="Data.Table2" DataType="System.Int32" Enabled="true">
|
||||||
|
<Column Name="Kind" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="Qty" DataType="System.String" PropName="Column"/>
|
||||||
|
</TableDataSource>
|
||||||
|
<TableDataSource Name="Table3" ReferenceName="Data.Table3" DataType="System.Int32" Enabled="true">
|
||||||
|
<Column Name="Kind" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="Qty" DataType="System.String" PropName="Column"/>
|
||||||
|
</TableDataSource>
|
||||||
|
<TableDataSource Name="Table4" ReferenceName="Data.Table4" DataType="System.Int32" Enabled="true">
|
||||||
|
<Column Name="Sheets" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="SortedCleaned" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="SpecialCleaning" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="Scrap" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="Others" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="TotalQty" DataType="System.String" PropName="Column"/>
|
||||||
|
</TableDataSource>
|
||||||
|
<TableDataSource Name="Table5" ReferenceName="Data.Table5" DataType="System.Int32" Enabled="true">
|
||||||
|
<Column Name="CleanedSheets" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="DateAndTime" DataType="System.String" PropName="Column"/>
|
||||||
|
<Column Name="Operator" DataType="System.String" PropName="Column"/>
|
||||||
|
</TableDataSource>
|
||||||
|
<Parameter Name="Parm_CusName" DataType="System.String"/>
|
||||||
|
<Parameter Name="Parm_MachineCode" DataType="System.String"/>
|
||||||
|
<Parameter Name="Parm_IRNumber" DataType="System.String"/>
|
||||||
|
<Parameter Name="Parm_RecDate" DataType="System.String"/>
|
||||||
|
<Parameter Name="Parm_RecordName" DataType="System.String"/>
|
||||||
|
<Parameter Name="Parm_CleanedNum" DataType="System.String"/>
|
||||||
|
<Parameter Name="Parm_PalletNumber" DataType="System.String"/>
|
||||||
|
<Parameter Name="Parm_ScrapNumber" DataType="System.String"/>
|
||||||
|
</Dictionary>
|
||||||
|
<ReportPage Name="Page1" Landscape="true" PaperWidth="279" PaperHeight="210" LeftMargin="5" TopMargin="5" RightMargin="5" BottomMargin="5" FirstPageSource="15" OtherPagesSource="15" FinishPageEvent="、">
|
||||||
|
<ReportTitleBand Name="ReportTitle1" Width="1016.82" Height="208.9">
|
||||||
|
<TextObject Name="Text1" Left="283.5" Width="396.9" Height="37.8" Text="CP2 Control List CTPS" HorzAlign="Center" VertAlign="Center" Font="微软雅黑, 22pt, style=Bold"/>
|
||||||
|
<TextObject Name="Text2" Left="87.05" Top="67.15" Width="151.2" Height="18.9" Text="Customer Name:" HorzAlign="Right" VertAlign="Center" Font="微软雅黑, 10pt, style=Bold"/>
|
||||||
|
<TextObject Name="Text3" Left="559.55" Top="67.15" Width="141.75" Height="18.9" Text="Machine #:" HorzAlign="Right" VertAlign="Center" Font="微软雅黑, 10pt, style=Bold"/>
|
||||||
|
<TextObject Name="Text4" Left="245.7" Top="66.15" Width="160.65" Height="18.9" Text="[Parm_CusName]" HorzAlign="Center" VertAlign="Center" Font="微软雅黑, 10pt, style=Bold"/>
|
||||||
|
<TextObject Name="Text5" Left="708.75" Top="66.15" Width="198.45" Height="18.9" Text="[Parm_MachineCode]" HorzAlign="Center" VertAlign="Center" Font="微软雅黑, 12pt, style=Bold"/>
|
||||||
|
<LineObject Name="Line1" Left="236.25" Top="85.05" Width="170.1"/>
|
||||||
|
<LineObject Name="Line2" Left="699.3" Top="85.05" Width="207.9"/>
|
||||||
|
<TextObject Name="Text6" Left="87.05" Top="95.5" Width="151.2" Height="18.9" Text="IR Number:" HorzAlign="Right" VertAlign="Center" Font="微软雅黑, 10pt, style=Bold"/>
|
||||||
|
<TextObject Name="Text7" Left="559.55" Top="95.5" Width="141.75" Height="18.9" Text="Receiving Date:" HorzAlign="Right" VertAlign="Center" Font="微软雅黑, 10pt, style=Bold"/>
|
||||||
|
<TextObject Name="Text8" Left="708.75" Top="94.5" Width="198.45" Height="18.9" Text="[Parm_RecDate]" HorzAlign="Center" VertAlign="Center" Font="微软雅黑, 12pt, style=Bold"/>
|
||||||
|
<TextObject Name="Text9" Left="245.7" Top="94.5" Width="160.65" Height="18.9" Text="[Parm_IRNumber]" HorzAlign="Center" VertAlign="Center" Font="微软雅黑, 10pt, style=Bold"/>
|
||||||
|
<LineObject Name="Line3" Left="236.25" Top="113.4" Width="170.1"/>
|
||||||
|
<LineObject Name="Line4" Left="699.3" Top="113.4" Width="207.9"/>
|
||||||
|
<TextObject Name="Text11" Left="219.35" Top="190" Width="189" Height="18.9" Text="Chemical Contamination:" VertAlign="Center" Font="微软雅黑, 10pt"/>
|
||||||
|
<TextObject Name="Text10" Left="2" Top="190" Width="189" Height="18.9" Text="Physical Contamination:" VertAlign="Center" Font="微软雅黑, 10pt"/>
|
||||||
|
<TextObject Name="Text12" Left="436.7" Top="190" Width="226.8" Height="18.9" Text="Microbiological Contamination:" VertAlign="Center" Font="微软雅黑, 10pt"/>
|
||||||
|
<TextObject Name="Text21" Left="87.05" Top="123.85" Width="151.2" Height="18.9" Text="Cleaned Quantity:" HorzAlign="Right" VertAlign="Center" Font="微软雅黑, 10pt, style=Bold"/>
|
||||||
|
<TextObject Name="Text23" Left="708.75" Top="122.85" Width="198.45" Height="18.9" Text="[Parm_PalletNumber]" HorzAlign="Center" VertAlign="Center" Font="微软雅黑, 12pt, style=Bold"/>
|
||||||
|
<TextObject Name="Text24" Left="245.7" Top="122.85" Width="160.65" Height="18.9" Text="[Parm_CleanedNum]" HorzAlign="Center" VertAlign="Center" Font="微软雅黑, 10pt, style=Bold"/>
|
||||||
|
<LineObject Name="Line9" Left="236.25" Top="141.75" Width="170.1"/>
|
||||||
|
<LineObject Name="Line10" Left="699.3" Top="141.75" Width="207.9"/>
|
||||||
|
<TextObject Name="Text25" Left="559.55" Top="123.85" Width="141.75" Height="18.9" Text="Pallet Number:" HorzAlign="Right" VertAlign="Center" Font="微软雅黑, 10pt, style=Bold"/>
|
||||||
|
<TextObject Name="Text28" Left="87.05" Top="152.2" Width="151.2" Height="18.9" Text="Scrap Number:" HorzAlign="Right" VertAlign="Center" Font="微软雅黑, 10pt, style=Bold"/>
|
||||||
|
<TextObject Name="Text29" Left="245.7" Top="151.2" Width="160.65" Height="18.9" Text="[Parm_ScrapNumber]" HorzAlign="Center" VertAlign="Center" Font="微软雅黑, 10pt, style=Bold"/>
|
||||||
|
<LineObject Name="Line15" Left="236.25" Top="170.1" Width="170.1"/>
|
||||||
|
</ReportTitleBand>
|
||||||
|
<DataBand Name="Data1" Top="212.9" Width="1016.82" Height="67.15">
|
||||||
|
<TableObject Name="Table1" Width="207.87" Height="37.8" Border.Lines="All" ManualBuildEvent="Table1_ManualBuild">
|
||||||
|
<TableColumn Name="Column1" Width="127.56"/>
|
||||||
|
<TableColumn Name="Column2" Width="80.31"/>
|
||||||
|
<TableRow Name="Row1">
|
||||||
|
<TableCell Name="Cell1" Border.Lines="All" Text="Kind" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt, style=Bold"/>
|
||||||
|
<TableCell Name="Cell2" Border.Lines="All" Text="Qty" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt, style=Bold"/>
|
||||||
|
</TableRow>
|
||||||
|
<TableRow Name="Row2">
|
||||||
|
<TableCell Name="Cell6" Border.Lines="All" Text="[Table1.Kind]" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt"/>
|
||||||
|
<TableCell Name="Cell7" Border.Lines="All" Text="[Table1.Qty]" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt"/>
|
||||||
|
</TableRow>
|
||||||
|
</TableObject>
|
||||||
|
<TableObject Name="Table6" Left="217.35" Width="207.87" Height="37.8" Border.Lines="All" ManualBuildEvent="Table6_ManualBuild">
|
||||||
|
<TableColumn Name="Column16" Width="127.56"/>
|
||||||
|
<TableColumn Name="Column17" Width="80.31"/>
|
||||||
|
<TableRow Name="Row62">
|
||||||
|
<TableCell Name="Cell211" Border.Lines="All" Text="Kind" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt, style=Bold"/>
|
||||||
|
<TableCell Name="Cell212" Border.Lines="All" Text="Qty" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt, style=Bold"/>
|
||||||
|
</TableRow>
|
||||||
|
<TableRow Name="Row63">
|
||||||
|
<TableCell Name="Cell213" Border.Lines="All" Text="[Table2.Kind]" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt"/>
|
||||||
|
<TableCell Name="Cell214" Border.Lines="All" Text="[Table2.Qty]" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt"/>
|
||||||
|
</TableRow>
|
||||||
|
</TableObject>
|
||||||
|
<TableObject Name="Table7" Left="434.7" Width="207.87" Height="37.8" Border.Lines="All" ManualBuildEvent="Table7_ManualBuild">
|
||||||
|
<TableColumn Name="Column18" Width="127.56"/>
|
||||||
|
<TableColumn Name="Column19" Width="80.31"/>
|
||||||
|
<TableRow Name="Row68">
|
||||||
|
<TableCell Name="Cell223" Border.Lines="All" Text="Kind" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt, style=Bold"/>
|
||||||
|
<TableCell Name="Cell224" Border.Lines="All" Text="Qty" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt, style=Bold"/>
|
||||||
|
</TableRow>
|
||||||
|
<TableRow Name="Row69">
|
||||||
|
<TableCell Name="Cell225" Border.Lines="All" Text="[Table3.Kind]" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt"/>
|
||||||
|
<TableCell Name="Cell226" Border.Lines="All" Text="[Table3.Qty]" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt"/>
|
||||||
|
</TableRow>
|
||||||
|
</TableObject>
|
||||||
|
<TableObject Name="Table4" Left="652.05" Width="362.22" Height="66.15" Border.Lines="All" ManualBuildEvent="Table4_ManualBuild" ManualBuildAutoSpans="false">
|
||||||
|
<TableColumn Name="Column7" Width="96.06"/>
|
||||||
|
<TableColumn Name="Column8" Width="114.96"/>
|
||||||
|
<TableColumn Name="Column9" Width="151.2"/>
|
||||||
|
<TableRow Name="Row19" Height="47.25">
|
||||||
|
<TableCell Name="Cell49" Border.Lines="All" Text="Cleaned Sheets (quantity)" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt, style=Bold"/>
|
||||||
|
<TableCell Name="Cell50" Border.Lines="All" Text="Date & Time" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt, style=Bold"/>
|
||||||
|
<TableCell Name="Cell61" Border.Lines="All" Text="Signature Machine operator" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt, style=Bold"/>
|
||||||
|
</TableRow>
|
||||||
|
<TableRow Name="Row20">
|
||||||
|
<TableCell Name="Cell51" Border.Lines="All" Text="[Table5.CleanedSheets]" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt"/>
|
||||||
|
<TableCell Name="Cell52" Border.Lines="All" Text="[Table5.DateAndTime]" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt"/>
|
||||||
|
<TableCell Name="Cell62" Border.Lines="All" Text="[Table5.Operator]" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt"/>
|
||||||
|
</TableRow>
|
||||||
|
</TableObject>
|
||||||
|
<DataBand Name="Data2" Top="284.05" Width="1016.82" Height="85.05">
|
||||||
|
<TableObject Name="Table5" Left="9.45" Top="47.25" Width="623.82" Height="37.8" Border.Lines="All" ManualBuildEvent="Table5_ManualBuild">
|
||||||
|
<TableColumn Name="Column10" Width="138.57"/>
|
||||||
|
<TableColumn Name="Column11" Width="119.72"/>
|
||||||
|
<TableColumn Name="Column12" Width="133.9"/>
|
||||||
|
<TableColumn Name="Column13" Width="77.21"/>
|
||||||
|
<TableColumn Name="Column14" Width="77.21"/>
|
||||||
|
<TableColumn Name="Column15" Width="77.21"/>
|
||||||
|
<TableRow Name="Row51">
|
||||||
|
<TableCell Name="Cell145" Border.Lines="All" Text="Sheets" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt, style=Bold"/>
|
||||||
|
<TableCell Name="Cell146" Border.Lines="All" Text="Sorted/cleaned" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt, style=Bold"/>
|
||||||
|
<TableCell Name="Cell157" Border.Lines="All" Text="Special Cleaning" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt, style=Bold"/>
|
||||||
|
<TableCell Name="Cell163" Border.Lines="All" Text="Scrap" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt, style=Bold"/>
|
||||||
|
<TableCell Name="Cell169" Border.Lines="All" Text="Others" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt, style=Bold"/>
|
||||||
|
<TableCell Name="Cell175" Border.Lines="All" Text="Total" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt, style=Bold"/>
|
||||||
|
</TableRow>
|
||||||
|
<TableRow Name="Row52">
|
||||||
|
<TableCell Name="Cell147" Border.Lines="All" Text="[Table4.Sheets]" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt"/>
|
||||||
|
<TableCell Name="Cell148" Border.Lines="All" Text="[Table4.SortedCleaned]" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt"/>
|
||||||
|
<TableCell Name="Cell158" Border.Lines="All" Text="[Table4.SpecialCleaning]" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt"/>
|
||||||
|
<TableCell Name="Cell164" Border.Lines="All" Text="[Table4.Scrap]" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt"/>
|
||||||
|
<TableCell Name="Cell170" Border.Lines="All" Text="[Table4.Others]" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt"/>
|
||||||
|
<TableCell Name="Cell176" Border.Lines="All" Text="[Table4.TotalQty]" HorzAlign="Center" VertAlign="Center" Font="宋体, 9pt"/>
|
||||||
|
</TableRow>
|
||||||
|
</TableObject>
|
||||||
|
</DataBand>
|
||||||
|
</DataBand>
|
||||||
|
<ColumnFooterBand Name="ColumnFooter1" Top="373.1" Width="1016.82" Height="37.8">
|
||||||
|
<LineObject Name="Line5" Left="160.65" Top="28.35" Width="207.9"/>
|
||||||
|
<LineObject Name="Line6" Left="481.95" Top="28.35" Width="236.25"/>
|
||||||
|
<TextObject Name="Text13" Left="11.45" Top="10.45" Width="151.2" Height="18.9" Text="Record verified by:" VertAlign="Center" Font="微软雅黑, 10pt, style=Bold"/>
|
||||||
|
<TextObject Name="Text14" Left="427.25" Top="10.45" Width="56.7" Height="18.9" Text="Date:" VertAlign="Center" Font="微软雅黑, 10pt, style=Bold"/>
|
||||||
|
<TextObject Name="Text15" Left="491.4" Top="9.45" Width="217.35" Height="18.9" Text="[Date]" HorzAlign="Center" VertAlign="Center" Font="微软雅黑, 12pt, style=Bold"/>
|
||||||
|
<TextObject Name="Text17" Left="170.1" Top="9.45" Width="217.35" Height="18.9" Text="[Parm_RecordName]" HorzAlign="Center" VertAlign="Center" Font="微软雅黑, 12pt, style=Bold"/>
|
||||||
|
</ColumnFooterBand>
|
||||||
|
</ReportPage>
|
||||||
|
</Report>
|
||||||
BIN
CleanMachineHMI/Resources/Uninstall_Tool.ico
Normal file
|
After Width: | Height: | Size: 4.2 KiB |
BIN
CleanMachineHMI/Resources/add.png
Normal file
|
After Width: | Height: | Size: 206 B |
BIN
CleanMachineHMI/Resources/cleaner_128px_1238161_easyicon.net.ico
Normal file
|
After Width: | Height: | Size: 62 KiB |
BIN
CleanMachineHMI/Resources/cleaning_spray.ico
Normal file
|
After Width: | Height: | Size: 56 KiB |
BIN
CleanMachineHMI/Resources/conn.png
Normal file
|
After Width: | Height: | Size: 638 B |
BIN
CleanMachineHMI/Resources/favicon.ico
Normal file
|
After Width: | Height: | Size: 4.2 KiB |
BIN
CleanMachineHMI/Resources/上升.png
Normal file
|
After Width: | Height: | Size: 383 B |
BIN
CleanMachineHMI/Resources/上升_1.png
Normal file
|
After Width: | Height: | Size: 269 B |
BIN
CleanMachineHMI/Resources/下降.png
Normal file
|
After Width: | Height: | Size: 393 B |
BIN
CleanMachineHMI/Resources/下降_1.png
Normal file
|
After Width: | Height: | Size: 231 B |
BIN
CleanMachineHMI/Resources/客情维护.png
Normal file
|
After Width: | Height: | Size: 2.4 KiB |
BIN
CleanMachineHMI/Resources/报警 (1).png
Normal file
|
After Width: | Height: | Size: 2.3 KiB |
BIN
CleanMachineHMI/Resources/清洁员图片1.ico
Normal file
|
After Width: | Height: | Size: 3.9 KiB |
BIN
CleanMachineHMI/Resources/清洁员图片2.ico
Normal file
|
After Width: | Height: | Size: 62 KiB |
52
CleanMachineHMI/Utils/AppConfigHelper.cs
Normal file
@@ -0,0 +1,52 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Configuration;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.Utils
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 配置文件操作
|
||||||
|
/// </summary>
|
||||||
|
public static class AppConfigHelper
|
||||||
|
{
|
||||||
|
public static string Get(string key)
|
||||||
|
{
|
||||||
|
var config = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None);
|
||||||
|
return config.AppSettings.Settings[key].Value;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void Remove(string key)
|
||||||
|
{
|
||||||
|
var config = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None);
|
||||||
|
config.AppSettings.Settings.Remove(key);
|
||||||
|
config.Save(ConfigurationSaveMode.Modified);
|
||||||
|
ConfigurationManager.RefreshSection("appSettings");
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void Add(string key, string value)
|
||||||
|
{
|
||||||
|
var config = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None);
|
||||||
|
config.AppSettings.Settings.Add(key, value);
|
||||||
|
config.Save(ConfigurationSaveMode.Modified);
|
||||||
|
ConfigurationManager.RefreshSection("appSettings");
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void Update(string key, string value)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
Configuration config = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None);
|
||||||
|
config.AppSettings.Settings[key].Value = value;
|
||||||
|
config.Save(ConfigurationSaveMode.Modified);
|
||||||
|
ConfigurationManager.RefreshSection("appSettings");
|
||||||
|
}
|
||||||
|
catch (Exception)
|
||||||
|
{
|
||||||
|
Add(key, value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
25
CleanMachineHMI/Utils/CircleButton.cs
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI
|
||||||
|
{
|
||||||
|
[ToolboxItem(true)]
|
||||||
|
public class CircleButton : Button//继承按钮类 重新生成解决方案就能看见我啦
|
||||||
|
{
|
||||||
|
protected override void OnPaint(PaintEventArgs e)//重新设置控件的形状
|
||||||
|
{
|
||||||
|
base.OnPaint(e);//递归 每次重新都发生此方法,保证其形状为自定义形状
|
||||||
|
System.Drawing.Drawing2D.GraphicsPath path = new System.Drawing.Drawing2D.GraphicsPath();
|
||||||
|
path.AddEllipse(2, 2, this.Width - 6, this.Height - 6);
|
||||||
|
Graphics g = e.Graphics;
|
||||||
|
g.DrawEllipse(new Pen(Color.White, 0), 2, 2, Width - 6, Height - 6);
|
||||||
|
Region = new Region(path);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
22
CleanMachineHMI/Utils/FormTypeAttribute.cs
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.Utils
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 自定义窗体类型特性
|
||||||
|
/// </summary>
|
||||||
|
[AttributeUsage(AttributeTargets.Class)]
|
||||||
|
public class FormTypeAttribute : Attribute
|
||||||
|
{
|
||||||
|
public EnumFormType Value { get; set; }
|
||||||
|
public FormTypeAttribute(EnumFormType enumFormType)
|
||||||
|
{
|
||||||
|
this.Value = enumFormType;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
179
CleanMachineHMI/Utils/GlobalHelper.cs
Normal file
@@ -0,0 +1,179 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using CleanMachineHMI.Domain.Models.ViewModels;
|
||||||
|
using CleanMachineHMI.forms;
|
||||||
|
using CleanMachineHMI.frmChild;
|
||||||
|
using CleanMachineHMI.Utils;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Data;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Reflection;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 应用配置
|
||||||
|
/// </summary>
|
||||||
|
public static class GlobalHelper
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 主窗体_New
|
||||||
|
/// </summary>
|
||||||
|
public static frmMainNew MainFormNew{ get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 登陆窗体
|
||||||
|
/// </summary>
|
||||||
|
public static frmLogin LoginForm { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 基础信息窗体容器
|
||||||
|
/// </summary>
|
||||||
|
public static frmBase BaseForm { get; set; }
|
||||||
|
|
||||||
|
public static frmIoMonitorNew IoMonitor_2 { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 所有窗体模型
|
||||||
|
/// </summary>
|
||||||
|
public static List<FormModel<Type>> FrmModelList { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 语言编码
|
||||||
|
/// </summary>
|
||||||
|
public static string LanguageCode { get; set; } = AppConfigHelper.Get("LanguageCode");
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 用户信息
|
||||||
|
/// </summary>
|
||||||
|
public static UserInfo UserInfo { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 参数列表
|
||||||
|
/// </summary>
|
||||||
|
public static DataTable ParameterList { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 角色菜单权限数据
|
||||||
|
/// </summary>
|
||||||
|
public static DataTable RoleMenuPermission { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
public static List<BasPlcItemMd> PlcItemMdList { get; set; }
|
||||||
|
public static List<BasPlcItemMd> PlcItemMd_D_List { get; set; }
|
||||||
|
|
||||||
|
public static List<BasPlcItemMd> PlcItemMd_M_List { get; set; }
|
||||||
|
|
||||||
|
public static List<BasPlcItemMd> PlcItemMd_X_List { get; set; }
|
||||||
|
|
||||||
|
public static List<BasPlcItemMd> PlcItemMd_Y_List { get; set; }
|
||||||
|
|
||||||
|
public static List<Bas_WarningMd> BasWarningMd_List { get; set; }
|
||||||
|
|
||||||
|
public static List<CM_WarningLogMd> CmWarningLogMd_List { get; set; }
|
||||||
|
|
||||||
|
public static List<CM_WarningLogMd> CmWarningLogMd_List_1 { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 参数列表
|
||||||
|
/// </summary>
|
||||||
|
public static bool CanOperate { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// 系统是否运行
|
||||||
|
/// </summary>
|
||||||
|
public static bool SysThIsRunFlag { get; set; }
|
||||||
|
#region 委托事件
|
||||||
|
//定义一个委托类型的事件
|
||||||
|
public static event EventHandler<EventArgs> OnShowX_Y_Status;
|
||||||
|
public static bool eventLock = false;
|
||||||
|
public static void ShowX_Y_Status(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (!eventLock)
|
||||||
|
{
|
||||||
|
OnShowX_Y_Status?.Invoke(sender, e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//定义一个委托类型的事件
|
||||||
|
public static event EventHandler<EventArgs> OnShowSensorStatus;
|
||||||
|
public static void ShowSensorStatus(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (!eventLock)
|
||||||
|
{
|
||||||
|
OnShowSensorStatus?.Invoke(sender, e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//定义一个委托类型的事件
|
||||||
|
public static event EventHandler<EventArgs> OnShowMainFrmAlarmMsg;
|
||||||
|
public static bool eventAlarmLock = false;
|
||||||
|
public static void ShowMainFrmAlarmMsg(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (!eventAlarmLock)
|
||||||
|
{
|
||||||
|
OnShowMainFrmAlarmMsg?.Invoke(sender, e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public static frmPopupWarningMsg PopupWarningMsgForm { get; set; }
|
||||||
|
//定义一个委托类型的事件
|
||||||
|
public static event EventHandler<EventArgs> OnSyncFinishPalletData;
|
||||||
|
public static void SyncFinishPalletData(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
OnSyncFinishPalletData?.Invoke(sender, e);
|
||||||
|
}
|
||||||
|
#endregion
|
||||||
|
/// <summary>
|
||||||
|
/// 获取拖盘号
|
||||||
|
/// </summary>
|
||||||
|
/// <returns></returns>
|
||||||
|
public static string GetPalletCode()
|
||||||
|
{
|
||||||
|
string currDateStr = DateTime.Now.ToString("yyyyMMdd");
|
||||||
|
string PalletIndexPrefix = AppConfigHelper.Get("PalletIndexPrefix");
|
||||||
|
string PalletIndexDateMsg = AppConfigHelper.Get("PalletIndexDateMsg");
|
||||||
|
int PalletIndexLen = Convert.ToInt32(AppConfigHelper.Get("PalletIndexLen"));
|
||||||
|
int PalletIndexValue = Convert.ToInt32(AppConfigHelper.Get("PalletIndexValue"));
|
||||||
|
if (currDateStr == PalletIndexDateMsg)
|
||||||
|
{
|
||||||
|
PalletIndexValue++;
|
||||||
|
string tmpPalletCode = PalletIndexPrefix + currDateStr + PalletIndexValue.ToString().PadLeft(PalletIndexLen, '0');
|
||||||
|
AppConfigHelper.Update("PalletIndexValue", PalletIndexValue.ToString());
|
||||||
|
return tmpPalletCode;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
PalletIndexValue = 1;
|
||||||
|
string tmpPalletCode = PalletIndexPrefix + currDateStr + PalletIndexValue.ToString().PadLeft(PalletIndexLen, '0');
|
||||||
|
AppConfigHelper.Update("PalletIndexValue", PalletIndexValue.ToString());
|
||||||
|
AppConfigHelper.Update("PalletIndexDateMsg", currDateStr);
|
||||||
|
return tmpPalletCode;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/// <summary>
|
||||||
|
/// 根据自定义特性和窗体的绑定原理,
|
||||||
|
/// 自动加载所有的窗体数据。
|
||||||
|
/// </summary>
|
||||||
|
public static void LoadAllFormData()
|
||||||
|
{
|
||||||
|
var types = Assembly.GetExecutingAssembly().GetTypes().Where(x => x.GetCustomAttributes(typeof(FormTypeAttribute), false).Count() > 0);
|
||||||
|
FrmModelList = new List<FormModel<Type>>();
|
||||||
|
foreach (var item in types)
|
||||||
|
{
|
||||||
|
FormTypeAttribute tmpAttribute = (FormTypeAttribute)item.GetCustomAttribute(typeof(FormTypeAttribute));
|
||||||
|
FrmModelList.Add(new FormModel<Type>
|
||||||
|
{
|
||||||
|
//Form = (UserControl)Activator.CreateInstance(item),
|
||||||
|
Form = item,
|
||||||
|
FormType = tmpAttribute.Value
|
||||||
|
});
|
||||||
|
}
|
||||||
|
//MainForm = (frmMain)FrmModelList.Find(x => x.FormType == EnumFormType.Main).Form;
|
||||||
|
//MainFormNew = (frmMainNew)FrmModelList.Find(x => x.FormType == EnumFormType.Main).Form;
|
||||||
|
//LoginForm = (frmLogin)FrmModelList.Find(x => x.FormType == EnumFormType.Login).Form;
|
||||||
|
LoginForm = new frmLogin();
|
||||||
|
CanOperate = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
60
CleanMachineHMI/Utils/KeyboardAutoPopUp.cs
Normal file
@@ -0,0 +1,60 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Diagnostics;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Runtime.InteropServices;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI
|
||||||
|
{
|
||||||
|
public class KeyboardAutoPopUp
|
||||||
|
{
|
||||||
|
private const Int32 WM_SYSCOMMAND = 274;
|
||||||
|
private const UInt32 SC_CLOSE = 61536;
|
||||||
|
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Auto)]
|
||||||
|
private static extern bool PostMessage(IntPtr hWnd, int Msg, int wParam, int lParam);
|
||||||
|
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Auto)]
|
||||||
|
private static extern bool PostMessage(IntPtr hWnd, int Msg, uint wParam, uint lParam);
|
||||||
|
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Auto)]
|
||||||
|
private static extern bool PostMessage(IntPtr hWnd, uint Msg, IntPtr wParam, IntPtr lParam);
|
||||||
|
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Auto)]
|
||||||
|
private static extern IntPtr FindWindow(string lpClassName, string lpWindowName);
|
||||||
|
[DllImport("user32.dll", CharSet = CharSet.Auto, SetLastError = true)]
|
||||||
|
private static extern int RegisterWindowMessage(string lpString);
|
||||||
|
|
||||||
|
//显示屏幕键盘
|
||||||
|
public static int ShowInputPanel()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
dynamic file = "C:\\Program Files\\Common Files\\microsoft shared\\ink\\TabTip.exe";
|
||||||
|
if (!System.IO.File.Exists(file))
|
||||||
|
return -1;
|
||||||
|
Process.Start(file);
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
catch (Exception)
|
||||||
|
{
|
||||||
|
return 255;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//隐藏屏幕键盘
|
||||||
|
public static void HideInputPanel()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
IntPtr TouchhWnd = new IntPtr(0);
|
||||||
|
TouchhWnd = FindWindow("IPTip_Main_Window", null);
|
||||||
|
if (TouchhWnd == IntPtr.Zero)
|
||||||
|
return;
|
||||||
|
PostMessage(TouchhWnd, WM_SYSCOMMAND, SC_CLOSE, 0);
|
||||||
|
}
|
||||||
|
catch
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
68
CleanMachineHMI/Utils/LEnum.cs
Normal file
@@ -0,0 +1,68 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 方向
|
||||||
|
/// </summary>
|
||||||
|
public enum Orientation
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 水平方向(从左到右)
|
||||||
|
/// </summary>
|
||||||
|
Horizontal_LR,
|
||||||
|
/// <summary>
|
||||||
|
/// 水平方向(从右到左)
|
||||||
|
/// </summary>
|
||||||
|
Horizontal_RL,
|
||||||
|
/// <summary>
|
||||||
|
/// 垂直方向(从上到上)
|
||||||
|
/// </summary>
|
||||||
|
Vertical_BT,
|
||||||
|
/// <summary>
|
||||||
|
/// 垂直方向(从上到下)
|
||||||
|
/// </summary>
|
||||||
|
Vertical_TB
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 鼠标状态
|
||||||
|
/// </summary>
|
||||||
|
public enum MouseStatus
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 鼠标进入
|
||||||
|
/// </summary>
|
||||||
|
Enter,
|
||||||
|
/// <summary>
|
||||||
|
/// 鼠标离开
|
||||||
|
/// </summary>
|
||||||
|
Leave,
|
||||||
|
/// <summary>
|
||||||
|
/// 鼠标按下
|
||||||
|
/// </summary>
|
||||||
|
Down,
|
||||||
|
/// <summary>
|
||||||
|
/// 鼠标按下释放
|
||||||
|
/// </summary>
|
||||||
|
Up
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 滚动条方向
|
||||||
|
/// </summary>
|
||||||
|
public enum OrientationScrollBar
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 水平方向
|
||||||
|
/// </summary>
|
||||||
|
Horizontal,
|
||||||
|
/// <summary>
|
||||||
|
/// 垂直方向
|
||||||
|
/// </summary>
|
||||||
|
Vertical
|
||||||
|
}
|
||||||
|
}
|
||||||
52
CleanMachineHMI/Utils/LEventArgs.cs
Normal file
@@ -0,0 +1,52 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 事件数据
|
||||||
|
/// </summary>
|
||||||
|
public class LEventArgs:EventArgs
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 事件数据
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="value">值</param>
|
||||||
|
public LEventArgs(object value)
|
||||||
|
{
|
||||||
|
Value = value;
|
||||||
|
}
|
||||||
|
/// <summary>
|
||||||
|
/// 值
|
||||||
|
/// </summary>
|
||||||
|
public object Value { get; set; }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 滚动条事件数据
|
||||||
|
/// </summary>
|
||||||
|
public class LScrollEventArgs : EventArgs
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 滚动条事件数据
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="sliderPosition">滑块距顶部(垂直)/左侧(横向)位置</param>
|
||||||
|
/// <param name="showPosition">显示位置(正数)</param>
|
||||||
|
public LScrollEventArgs(float sliderPosition, float showPosition)
|
||||||
|
{
|
||||||
|
SliderPosition = sliderPosition;
|
||||||
|
ShowPosition = showPosition;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 滑块距顶部(垂直)/左侧(横向)位置
|
||||||
|
/// </summary>
|
||||||
|
public float SliderPosition { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// 显示位置(正数)
|
||||||
|
/// </summary>
|
||||||
|
public float ShowPosition { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
292
CleanMachineHMI/Utils/LSwitchButton.cs
Normal file
@@ -0,0 +1,292 @@
|
|||||||
|
/*
|
||||||
|
* 作者:Leslie Xin
|
||||||
|
* 邮箱:lesliexin@outlook.com
|
||||||
|
* 网站:www.lesliexin.com
|
||||||
|
*
|
||||||
|
* 版权所有,使用本代码需附上本段注释。
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Drawing.Drawing2D;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
using LEase;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI
|
||||||
|
{
|
||||||
|
|
||||||
|
[ToolboxItem(true)]
|
||||||
|
/// <summary>
|
||||||
|
/// 开关按钮
|
||||||
|
/// </summary>
|
||||||
|
[DefaultEvent("LSwitched")]
|
||||||
|
public class LSwitchButton:Control
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 开关按钮
|
||||||
|
/// </summary>
|
||||||
|
public LSwitchButton()
|
||||||
|
{
|
||||||
|
SetStyle(ControlStyles.AllPaintingInWmPaint, true);
|
||||||
|
SetStyle(ControlStyles.OptimizedDoubleBuffer, true);
|
||||||
|
CreateControl();
|
||||||
|
|
||||||
|
tTimer = new System.Windows.Forms.Timer();
|
||||||
|
tTimer.Interval = 10;
|
||||||
|
tTimer.Tick += TTimer_Tick;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#region Event
|
||||||
|
/// <summary>
|
||||||
|
/// 委托
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="sender"></param>
|
||||||
|
/// <param name="e"></param>
|
||||||
|
public delegate void LSwitchedEventHandler(object sender, LEventArgs e);
|
||||||
|
/// <summary>
|
||||||
|
/// 开关状态发生改变时引发的事件
|
||||||
|
/// </summary>
|
||||||
|
public event LSwitchedEventHandler LSwitched;
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
#region Property
|
||||||
|
|
||||||
|
private Color _CloseColor = Color.FromArgb(224, 224, 224);//浅灰
|
||||||
|
/// <summary>
|
||||||
|
/// “关”时背景色<para>默认:浅灰</para>
|
||||||
|
/// </summary>
|
||||||
|
[Category("DemoUI"), Description("“关”时背景色\r\n默认:浅灰")]
|
||||||
|
public Color L_CloseColor
|
||||||
|
{
|
||||||
|
get { return _CloseColor; }
|
||||||
|
set
|
||||||
|
{
|
||||||
|
_CloseColor = value;
|
||||||
|
Invalidate();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private Color _OpenColor = Color.FromArgb(128, 255, 128);//浅绿
|
||||||
|
/// <summary>
|
||||||
|
/// “开”时背景色<para>默认:浅绿</para>
|
||||||
|
/// </summary>
|
||||||
|
[Category("DemoUI"), Description("“开”时背景色\r\n默认:浅绿")]
|
||||||
|
public Color L_OpenColor
|
||||||
|
{
|
||||||
|
get { return _OpenColor; }
|
||||||
|
set
|
||||||
|
{
|
||||||
|
_OpenColor = value;
|
||||||
|
Invalidate();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private Color _DotColor = Color.White;
|
||||||
|
/// <summary>
|
||||||
|
/// 圆点颜色<para>默认:白色</para>
|
||||||
|
/// </summary>
|
||||||
|
[Category("DemoUI"), Description("圆点颜色\r\n默认:白色")]
|
||||||
|
public Color L_DotColor
|
||||||
|
{
|
||||||
|
get { return _DotColor; }
|
||||||
|
set
|
||||||
|
{
|
||||||
|
_DotColor = value;
|
||||||
|
Invalidate();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private int _DotHight = 20;
|
||||||
|
/// <summary>
|
||||||
|
/// 圆点高度(直径)<para>默认:20</para>
|
||||||
|
/// </summary>
|
||||||
|
[Category("DemoUI"), Description("圆点高度(直径)\r\n默认:20")]
|
||||||
|
public int L_DotHight
|
||||||
|
{
|
||||||
|
get { return _DotHight; }
|
||||||
|
set
|
||||||
|
{
|
||||||
|
_DotHight = value < 0 ? 0 : value;
|
||||||
|
Size =new Size(Width,Math.Max(_DotHight, _BarHight));
|
||||||
|
Invalidate();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private int _BarHight = 24;
|
||||||
|
/// <summary>
|
||||||
|
/// 背景条高度<para>默认:24</para>
|
||||||
|
/// </summary>
|
||||||
|
[Category("DemoUI"), Description("背景条高度\r\n默认:24")]
|
||||||
|
public int L_BarHight
|
||||||
|
{
|
||||||
|
get { return _BarHight; }
|
||||||
|
set
|
||||||
|
{
|
||||||
|
_BarHight = value < 0 ? 0 : value;
|
||||||
|
Size = new Size(Width, Math.Max(_DotHight, _BarHight));
|
||||||
|
Invalidate();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private bool _IsOpen = false;
|
||||||
|
/// <summary>
|
||||||
|
/// 开关状态是否是“开”<para>默认:false</para>
|
||||||
|
/// </summary>
|
||||||
|
[Category("DemoUI"), Description("开关状态是否是“开”\r\n默认:false")]
|
||||||
|
public bool L_IsOpen
|
||||||
|
{
|
||||||
|
get { return _IsOpen; }
|
||||||
|
set
|
||||||
|
{
|
||||||
|
_IsOpen = value;
|
||||||
|
Invalidate();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private int _Margin = 2;
|
||||||
|
/// <summary>
|
||||||
|
/// 圆点距左右两侧距离<para>默认:2</para>
|
||||||
|
/// </summary>
|
||||||
|
[Category("DemoUI"), Description("圆点距左右两侧距离\r\n默认:2")]
|
||||||
|
public int L_Margin
|
||||||
|
{
|
||||||
|
get { return _Margin; }
|
||||||
|
set
|
||||||
|
{
|
||||||
|
_Margin = value < 0 ? 0 : value; ;
|
||||||
|
Invalidate();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 动画效果<para>默认:Quartic</para>
|
||||||
|
/// </summary>
|
||||||
|
[Category("DemoUI"), Description("动画效果\r\n默认:Quartic")]
|
||||||
|
public LEaseType L_AnimateType { get; set; } = LEaseType.Quartic;
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
#region Private
|
||||||
|
Timer tTimer;
|
||||||
|
float fNowLocationBar, fNowLocationDot;
|
||||||
|
/// <summary>
|
||||||
|
/// 动画效果时长,毫秒
|
||||||
|
/// </summary>
|
||||||
|
int iDuration = 200;
|
||||||
|
int iNow;
|
||||||
|
bool bInAnimate = false;
|
||||||
|
float fRangeBar,fRangeDot;
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private void TTimer_Tick(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
bool b = (_IsOpen?(iNow>=0):(iNow<=iDuration));
|
||||||
|
if (b)
|
||||||
|
{
|
||||||
|
double d = 0;
|
||||||
|
switch (L_AnimateType)
|
||||||
|
{
|
||||||
|
case LEaseType.Back:
|
||||||
|
d = AnimateBase.Back(Convert.ToDouble(iNow) / iDuration, _IsOpen ? LEaseMode.EaseIn : LEaseMode.EaseOut);
|
||||||
|
break;
|
||||||
|
case LEaseType.Bounce:
|
||||||
|
d = AnimateBase.Bounce(Convert.ToDouble(iNow) / iDuration, _IsOpen ? LEaseMode.EaseIn : LEaseMode.EaseOut);
|
||||||
|
break;
|
||||||
|
case LEaseType.Circle:
|
||||||
|
d = AnimateBase.Circle(Convert.ToDouble(iNow) / iDuration, _IsOpen ? LEaseMode.EaseIn : LEaseMode.EaseOut);
|
||||||
|
break;
|
||||||
|
case LEaseType.Cubic:
|
||||||
|
d = AnimateBase.Cubic(Convert.ToDouble(iNow) / iDuration, _IsOpen ? LEaseMode.EaseIn : LEaseMode.EaseOut);
|
||||||
|
break;
|
||||||
|
case LEaseType.Elastic:
|
||||||
|
d = AnimateBase.Elastic(Convert.ToDouble(iNow) / iDuration, _IsOpen ? LEaseMode.EaseIn : LEaseMode.EaseOut);
|
||||||
|
break;
|
||||||
|
case LEaseType.Exponential:
|
||||||
|
d = AnimateBase.Exponential(Convert.ToDouble(iNow) / iDuration, _IsOpen ? LEaseMode.EaseIn : LEaseMode.EaseOut);
|
||||||
|
break;
|
||||||
|
case LEaseType.Quadratic:
|
||||||
|
d = AnimateBase.Quadratic(Convert.ToDouble(iNow) / iDuration, _IsOpen ? LEaseMode.EaseIn : LEaseMode.EaseOut);
|
||||||
|
break;
|
||||||
|
case LEaseType.Quartic:
|
||||||
|
d = AnimateBase.Quartic(Convert.ToDouble(iNow) / iDuration, _IsOpen ? LEaseMode.EaseIn : LEaseMode.EaseOut);
|
||||||
|
break;
|
||||||
|
case LEaseType.Quintic:
|
||||||
|
d = AnimateBase.Quintic(Convert.ToDouble(iNow) / iDuration, _IsOpen ? LEaseMode.EaseIn : LEaseMode.EaseOut);
|
||||||
|
break;
|
||||||
|
case LEaseType.Sine:
|
||||||
|
d = AnimateBase.Sine(Convert.ToDouble(iNow) / iDuration, _IsOpen ? LEaseMode.EaseIn : LEaseMode.EaseOut);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
fNowLocationBar = Convert.ToSingle(d * fRangeBar);
|
||||||
|
fNowLocationDot = Convert.ToSingle(d * fRangeDot)+_Margin;
|
||||||
|
iNow = _IsOpen ? (iNow-tTimer.Interval) : (iNow+tTimer.Interval);
|
||||||
|
Invalidate();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
tTimer.Stop();
|
||||||
|
bInAnimate = false;
|
||||||
|
LSwitched?.Invoke(this, new LEventArgs(_IsOpen));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void SetBoundsCore(int x, int y, int width, int height, BoundsSpecified specified)
|
||||||
|
{
|
||||||
|
//为达到较好的视觉效果,宽度至少要是高度的两倍
|
||||||
|
int iHeight = Math.Max(_DotHight,_BarHight);
|
||||||
|
int iWidth = Math.Max(iHeight * 2, width);
|
||||||
|
iHeight++;
|
||||||
|
fRangeBar = iWidth - _BarHight;
|
||||||
|
fRangeDot = iWidth - _DotHight- _Margin * 2;
|
||||||
|
base.SetBoundsCore(x, y, iWidth, iHeight, specified);
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
|
{
|
||||||
|
base.OnPaint(e);
|
||||||
|
e.Graphics.SmoothingMode = SmoothingMode.HighQuality;
|
||||||
|
|
||||||
|
Pen penBarBack = new Pen(_CloseColor, _BarHight);
|
||||||
|
Pen penBarFore = new Pen(_OpenColor, _BarHight);
|
||||||
|
penBarBack.StartCap = LineCap.Round;
|
||||||
|
penBarBack.EndCap = LineCap.Round;
|
||||||
|
penBarFore.StartCap = LineCap.Round;
|
||||||
|
penBarFore.EndCap = LineCap.Round;
|
||||||
|
|
||||||
|
float fCapHalfWidth = _BarHight / 2.0f;
|
||||||
|
float fLeftTop = Convert.ToSingle(Height - _DotHight) / 2.0f;
|
||||||
|
|
||||||
|
if (!bInAnimate)
|
||||||
|
{
|
||||||
|
fNowLocationBar = _IsOpen ? 0: fRangeBar;
|
||||||
|
fNowLocationDot = _IsOpen ? _Margin : (fRangeDot + _Margin);
|
||||||
|
}
|
||||||
|
|
||||||
|
//画背景
|
||||||
|
e.Graphics.DrawLine(penBarBack, fCapHalfWidth, Height / 2f, Width - fCapHalfWidth, Height / 2f);
|
||||||
|
//画前景
|
||||||
|
e.Graphics.DrawLine(penBarFore, fCapHalfWidth, Height / 2f, Width - fCapHalfWidth - fNowLocationBar, Height / 2f);
|
||||||
|
//画圆点
|
||||||
|
e.Graphics.FillEllipse(new SolidBrush(_DotColor),Width-_DotHight- fNowLocationDot, fLeftTop, _DotHight, _DotHight);
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void OnMouseDown(MouseEventArgs e)
|
||||||
|
{
|
||||||
|
base.OnMouseDown(e);
|
||||||
|
if (!bInAnimate)
|
||||||
|
{
|
||||||
|
bInAnimate = true;
|
||||||
|
_IsOpen = !_IsOpen;
|
||||||
|
iNow = _IsOpen ? iDuration : 0;
|
||||||
|
tTimer.Start();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
837
CleanMachineHMI/Utils/PlcOperationHelper.cs
Normal file
@@ -0,0 +1,837 @@
|
|||||||
|
using LeadDataBaseUtility;
|
||||||
|
using Modbus.Device;
|
||||||
|
using NX_LogUtility;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Configuration;
|
||||||
|
using System.Data;
|
||||||
|
using System.Diagnostics;
|
||||||
|
using System.IO.Ports;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI
|
||||||
|
{
|
||||||
|
public class PlcOperationHelper
|
||||||
|
{
|
||||||
|
#region 单例模式
|
||||||
|
/// <summary>
|
||||||
|
/// 单例模式对象
|
||||||
|
/// </summary>
|
||||||
|
private static PlcOperationHelper _instance = null;
|
||||||
|
private static object lockObj = new object();
|
||||||
|
/// <summary>
|
||||||
|
/// 单例模式方法
|
||||||
|
/// </summary>
|
||||||
|
public static PlcOperationHelper Instance
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
if (_instance == null)
|
||||||
|
{
|
||||||
|
lock (lockObj)
|
||||||
|
{
|
||||||
|
if (_instance == null)
|
||||||
|
{
|
||||||
|
_instance = new PlcOperationHelper();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return _instance;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
|
||||||
|
private bool _isConn = false;
|
||||||
|
|
||||||
|
|
||||||
|
public bool isConn
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
return this._isConn;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
set { this._isConn = value; }
|
||||||
|
}
|
||||||
|
private static IModbusMaster master;
|
||||||
|
private static SerialPort port;
|
||||||
|
|
||||||
|
public bool PlcInit()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
string portname = GlobalHelper.ParameterList.Select(" PARAMETER_CODE = 'PortName'")[0]["PARAMETER_VALUE"].ToString();
|
||||||
|
int baudrate = Convert.ToInt32(GlobalHelper.ParameterList.Select(" PARAMETER_CODE = 'BaudRate'")[0]["PARAMETER_VALUE"]);
|
||||||
|
int databits = Convert.ToInt32(GlobalHelper.ParameterList.Select(" PARAMETER_CODE = 'DataBits'")[0]["PARAMETER_VALUE"]);
|
||||||
|
StopBits stopbis = Convert.ToInt32(GlobalHelper.ParameterList.Select(" PARAMETER_CODE = 'StopBits'")[0]["PARAMETER_VALUE"]) == 0 ? StopBits.None : (Convert.ToInt32(GlobalHelper.ParameterList.Select(" PARAMETER_CODE = 'StopBits'")[0]["PARAMETER_VALUE"]) == 1 ? StopBits.One : StopBits.Two);
|
||||||
|
Parity paritymsg = Convert.ToInt32(GlobalHelper.ParameterList.Select(" PARAMETER_CODE = 'ParityMsg'")[0]["PARAMETER_VALUE"]) == 0 ? Parity.None : (Convert.ToInt32(GlobalHelper.ParameterList.Select(" PARAMETER_CODE = 'ParityMsg'")[0]["PARAMETER_VALUE"]) == 1 ? Parity.Odd : Parity.Even);
|
||||||
|
int modbusPattern = Convert.ToInt32(GlobalHelper.ParameterList.Select(" PARAMETER_CODE = 'ModbusPattern'")[0]["PARAMETER_VALUE"]);
|
||||||
|
port = new SerialPort(portname, baudrate, paritymsg, databits, stopbis);
|
||||||
|
if (modbusPattern == 0)
|
||||||
|
{
|
||||||
|
master = ModbusSerialMaster.CreateRtu(port);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
master = ModbusSerialMaster.CreateAscii(port);
|
||||||
|
}
|
||||||
|
port.Open();
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"初始化PLC连接时发生异常:【{ex.Message}】", LogTypeEum.Err);
|
||||||
|
isConn = false;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public void ClosePlcConn()
|
||||||
|
{
|
||||||
|
if (port.IsOpen)
|
||||||
|
{
|
||||||
|
port.Close();
|
||||||
|
master = null;
|
||||||
|
isConn = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public void RefreshPlcItem_M()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
bool[] readBytArr_M = master.ReadCoils(1, 2248, 50);
|
||||||
|
bool[] readBytArr_M1 = master.ReadCoils(1, 2048, 50);
|
||||||
|
if (readBytArr_M.Length > 0 && readBytArr_M1.Length > 0)
|
||||||
|
{
|
||||||
|
if (GlobalHelper.PlcItemMd_M_List != null && GlobalHelper.PlcItemMd_M_List.Count > 0)
|
||||||
|
{
|
||||||
|
foreach (BasPlcItemMd item in GlobalHelper.PlcItemMd_M_List)
|
||||||
|
{
|
||||||
|
if (Convert.ToInt32(item.PlcItemPriAddress) >= 200)
|
||||||
|
{
|
||||||
|
if (!string.IsNullOrEmpty(item.PlcItemDeviationAddress))
|
||||||
|
{
|
||||||
|
string PlcItemId = item.PlcItemId.ToString();
|
||||||
|
string plcdatatype = item.PlcItemDataType.ToString();
|
||||||
|
int plcItemDeviationAddress = Convert.ToInt32(item.PlcItemDeviationAddress);
|
||||||
|
item.PlcItemValue = readBytArr_M[plcItemDeviationAddress].ToString();
|
||||||
|
GlobalHelper.ShowSensorStatus(item, new EventArgs());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (!string.IsNullOrEmpty(item.PlcItemDeviationAddress))
|
||||||
|
{
|
||||||
|
string PlcItemId = item.PlcItemId.ToString();
|
||||||
|
string plcdatatype = item.PlcItemDataType.ToString();
|
||||||
|
int plcItemDeviationAddress = Convert.ToInt32(item.PlcItemDeviationAddress);
|
||||||
|
item.PlcItemValue = readBytArr_M1[plcItemDeviationAddress].ToString();
|
||||||
|
GlobalHelper.ShowSensorStatus(item, new EventArgs());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"读取M 类型PLC变量时发生异常:【{ex.Message}】", LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public void RefreshPlcItem_D()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
ushort[] tmpReadAlarmBytArr_D = master.ReadHoldingRegisters(1, 4106, 50);
|
||||||
|
ushort[] readBytArr_D = master.ReadHoldingRegisters(1, 4505, 50);
|
||||||
|
if (readBytArr_D.Length > 0 && tmpReadAlarmBytArr_D.Length > 0)
|
||||||
|
{
|
||||||
|
if (GlobalHelper.PlcItemMd_D_List != null && GlobalHelper.PlcItemMd_D_List.Count > 0)
|
||||||
|
{
|
||||||
|
foreach (BasPlcItemMd item in GlobalHelper.PlcItemMd_D_List)
|
||||||
|
{
|
||||||
|
if (!string.IsNullOrEmpty(item.PlcItemDeviationAddress))
|
||||||
|
{
|
||||||
|
|
||||||
|
string PlcItemId = item.PlcItemId.ToString();
|
||||||
|
string plcdatatype = item.PlcItemDataType.ToString();
|
||||||
|
int plcItemDeviationAddress = Convert.ToInt32(item.PlcItemDeviationAddress);
|
||||||
|
if (Convert.ToInt32(item.PlcItemPriAddress) < 409)
|
||||||
|
{
|
||||||
|
item.PlcItemValue = tmpReadAlarmBytArr_D[plcItemDeviationAddress].ToString();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (item.PlcItemDataLen == 2)
|
||||||
|
{
|
||||||
|
ushort[] tmp_1 = new ushort[] { readBytArr_D[plcItemDeviationAddress], readBytArr_D[plcItemDeviationAddress + 1] };
|
||||||
|
|
||||||
|
#region 方法一 :Short数组转换为int数据 20201014 孙亚龙
|
||||||
|
////低位 short 的字节数组。
|
||||||
|
//byte[] tmpByt_1 = BitConverter.GetBytes(readBytArr_D[plcItemDeviationAddress]);
|
||||||
|
////高位 short 的字节数组。
|
||||||
|
//byte[] tmpByt_2 = BitConverter.GetBytes(readBytArr_D[plcItemDeviationAddress + 1]);
|
||||||
|
////组合为int32的字节数组。
|
||||||
|
//byte[] tmpByt_3 = new byte[] { tmpByt_1[0], tmpByt_1[1], tmpByt_2[0], tmpByt_2[1] };
|
||||||
|
////readBytArr_D[plcItemDeviationAddress + 1] << 16 +
|
||||||
|
//item.PlcItemValue = BitConverter.ToUInt32(tmpByt_3, 0).ToString();
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
#region 方法二 :Short数组转换为int数据 20201014 孙亚龙
|
||||||
|
//相较而言 使用位移的算法效率更高一些。
|
||||||
|
item.PlcItemValue = ((readBytArr_D[plcItemDeviationAddress + 1] << 16) + readBytArr_D[plcItemDeviationAddress]).ToString();
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
item.PlcItemValue = readBytArr_D[plcItemDeviationAddress].ToString();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
HandleWaringLog(tmpReadAlarmBytArr_D);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"读取D 类型PLC变量时发生异常:【{ex.Message}】", LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//报警信息记录
|
||||||
|
private void HandleWaringLog(ushort[] tmpReadAlarmBytArr_D)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
int index = 10;
|
||||||
|
string priStr = "D";
|
||||||
|
string priWarnCode = "bit";
|
||||||
|
for (int i = 0; i < tmpReadAlarmBytArr_D.Length; i++)
|
||||||
|
{
|
||||||
|
if (i <= 1)
|
||||||
|
{//D10~D11 报警
|
||||||
|
char[] tmpCharArr = Convert.ToString(tmpReadAlarmBytArr_D[i], 2).PadLeft(16, '0').Reverse().ToArray();
|
||||||
|
for (int j = 0; j < tmpCharArr.Length; j++)
|
||||||
|
{
|
||||||
|
if (tmpCharArr[j] == '1')
|
||||||
|
{//当前报警
|
||||||
|
Bas_WarningMd tmpMd = GlobalHelper.BasWarningMd_List.Find(x => x.PlcItemCode == $"{priStr + (index + i)}" && x.WarningCode == $"{priWarnCode + j}" && x.WarningType == "1");
|
||||||
|
if (tmpMd != null)
|
||||||
|
{
|
||||||
|
CM_WarningLogMd warnLogTmp = GlobalHelper.CmWarningLogMd_List.Find(y => y.WarningStatus == 0 && y.WarningHandleResult == 0 && y.WarningCode == tmpMd.WarningCode && y.PlcItemCode == tmpMd.PlcItemCode);
|
||||||
|
if (warnLogTmp != null)
|
||||||
|
{//找到报警项,并增加版本
|
||||||
|
warnLogTmp.UpdateTime = DateTime.Now;
|
||||||
|
warnLogTmp.DataVersion += 1;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{//新报警增加记录
|
||||||
|
GlobalHelper.CmWarningLogMd_List.Add(new CM_WarningLogMd
|
||||||
|
{
|
||||||
|
WarningCode = tmpMd.WarningCode,
|
||||||
|
WarningName = tmpMd.WarningName,
|
||||||
|
WarningType = tmpMd.WarningType,
|
||||||
|
WarningMessage = tmpMd.WarningMessage,
|
||||||
|
WarningTime = DateTime.Now,
|
||||||
|
PlcItemCode = tmpMd.PlcItemCode,
|
||||||
|
WarningStatus = 0,
|
||||||
|
WarningHandleResult = 0,
|
||||||
|
CreateBy = 1,
|
||||||
|
CreateTime = DateTime.Now,
|
||||||
|
UpdateBy = 1,
|
||||||
|
UpdateTime = DateTime.Now,
|
||||||
|
DataVersion = 0,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#region 已删除
|
||||||
|
|
||||||
|
// string sql = $@"SELECT * FROM BAS_WARNING WHERE PLC_ITEM_CODE = '{priStr + (index + i)}' and WARNING_CODE = '{priWarnCode + i}' and WARNING_TYPE = '1'";
|
||||||
|
// DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
// if (dt != null && dt.Rows.Count > 0)
|
||||||
|
// {
|
||||||
|
// string sql1 = $@"
|
||||||
|
// INSERT INTO CM_WARNING_LOG (
|
||||||
|
// WARNING_CODE,
|
||||||
|
// WARNING_NAME,
|
||||||
|
// WARNING_TYPE,
|
||||||
|
// WARNING_MESSAGE,
|
||||||
|
// WARNING_TIME,
|
||||||
|
// PLC_ITEM_CODE,
|
||||||
|
// WARING_STATUS,
|
||||||
|
// WARNING_HANDLE_RESULT,
|
||||||
|
// CREATE_BY,
|
||||||
|
// CREATE_TIME,
|
||||||
|
// UPDATE_BY,
|
||||||
|
// UPDATE_TIME,
|
||||||
|
// DATA_VERSION
|
||||||
|
// )
|
||||||
|
// SELECT
|
||||||
|
// '{dt.Rows[0]["WARNING_CODE"]}',
|
||||||
|
// '{dt.Rows[0]["WARNING_NAME"]}',
|
||||||
|
// '{dt.Rows[0]["WARNING_TYPE"]}',
|
||||||
|
// '{dt.Rows[0]["WARNING_MESSAGE"]}',
|
||||||
|
// datetime('now', 'localtime'),
|
||||||
|
// '{dt.Rows[0]["PLC_ITEM_CODE"]}',
|
||||||
|
// 0,
|
||||||
|
// 0,
|
||||||
|
// 1,
|
||||||
|
// datetime('now', 'localtime'),
|
||||||
|
// 1,
|
||||||
|
// datetime('now', 'localtime'),
|
||||||
|
// 0
|
||||||
|
// WHERE NOT EXISTS (SELECT 1 FROM CM_WARNING_LOG WHERE WARING_STATUS = 0 and WARNING_HANDLE_RESULT = 0 and WARNING_CODE = '{dt.Rows[0]["WARNING_CODE"]}' and PLC_ITEM_CODE = '{dt.Rows[0]["PLC_ITEM_CODE"]}')
|
||||||
|
// ";
|
||||||
|
// LeadDbHelperSQLite.ExecuteSql(sql1);
|
||||||
|
|
||||||
|
// string sql2 = $@"
|
||||||
|
//UPDATE CM_WARNING_LOG set UPDATE_TIME = datetime('now', 'localtime'),DATA_VERSION = DATA_VERSION + 1
|
||||||
|
// WHERE EXISTS(SELECT 1 FROM CM_WARNING_LOG WHERE WARING_STATUS = 0 and WARNING_HANDLE_RESULT = 0 and WARNING_CODE = '{dt.Rows[0]["WARNING_CODE"]}' and PLC_ITEM_CODE = '{dt.Rows[0]["PLC_ITEM_CODE"]}') and WARING_STATUS = 0 and WARNING_HANDLE_RESULT = 0 and WARNING_CODE = '{dt.Rows[0]["WARNING_CODE"]}' and PLC_ITEM_CODE = '{dt.Rows[0]["PLC_ITEM_CODE"]}';
|
||||||
|
// ";
|
||||||
|
// LeadDbHelperSQLite.ExecuteSql(sql2);
|
||||||
|
// }
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{//当前报警项没有报警
|
||||||
|
Bas_WarningMd tmpMd = GlobalHelper.BasWarningMd_List.Find(x => x.PlcItemCode == $"{priStr + (index + i)}" && x.WarningCode == $"{priWarnCode + j}" && x.WarningType == "1");
|
||||||
|
if (tmpMd != null)
|
||||||
|
{//之前有报警,则结束当前报警项
|
||||||
|
CM_WarningLogMd warnLogTmp = GlobalHelper.CmWarningLogMd_List.Find(y => y.WarningStatus == 0 && y.WarningHandleResult == 0 && y.WarningCode == tmpMd.WarningCode && y.PlcItemCode == tmpMd.PlcItemCode);
|
||||||
|
if (warnLogTmp != null)
|
||||||
|
{
|
||||||
|
warnLogTmp.UpdateTime = DateTime.Now;
|
||||||
|
warnLogTmp.DataVersion += 1;
|
||||||
|
warnLogTmp.WarningStatus = 1;
|
||||||
|
warnLogTmp.WarningHandleResult = 1;
|
||||||
|
warnLogTmp.WarningHandleTime = DateTime.Now;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#region 已删除
|
||||||
|
//string sql = $@"SELECT * FROM BAS_WARNING WHERE PLC_ITEM_CODE = '{priStr + (index + i)}' and WARNING_CODE = '{priWarnCode + i}' and WARNING_TYPE = '1'";
|
||||||
|
//DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
//if (dt != null && dt.Rows.Count > 0)
|
||||||
|
//{
|
||||||
|
// string sql2 = $@"
|
||||||
|
// UPDATE CM_WARNING_LOG
|
||||||
|
// SET UPDATE_TIME = datetime('now', 'localtime'),
|
||||||
|
// DATA_VERSION = DATA_VERSION + 1,
|
||||||
|
// WARING_STATUS = 1,
|
||||||
|
// WARNING_HANDLE_RESULT = 1,
|
||||||
|
// WARNING_HANDLE_TIME = datetime('now', 'localtime')
|
||||||
|
// WHERE
|
||||||
|
// EXISTS ( SELECT 1 FROM CM_WARNING_LOG WHERE WARING_STATUS = 0 AND WARNING_HANDLE_RESULT = 0 AND WARNING_CODE = '{dt.Rows[0]["WARNING_CODE"]}' AND PLC_ITEM_CODE = '{dt.Rows[0]["PLC_ITEM_CODE"]}' )
|
||||||
|
// AND WARING_STATUS = 0
|
||||||
|
// AND WARNING_HANDLE_RESULT = 0
|
||||||
|
// AND WARNING_CODE = '{dt.Rows[0]["WARNING_CODE"]}'
|
||||||
|
// AND PLC_ITEM_CODE = '{dt.Rows[0]["PLC_ITEM_CODE"]}';
|
||||||
|
// ";
|
||||||
|
// LeadDbHelperSQLite.ExecuteSql(sql2);
|
||||||
|
//}
|
||||||
|
#endregion
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (i == 2)
|
||||||
|
{
|
||||||
|
//char[] tmpCharArr = Convert.ToString(tmpReadAlarmBytArr_D[i], 2).PadLeft(16, '0').Reverse().ToArray();
|
||||||
|
//if (tmpCharArr.Contains('1'))
|
||||||
|
//{
|
||||||
|
// List<Bas_WarningMd> warnLst = new List<Bas_WarningMd>();
|
||||||
|
// for (int j = 0; j < tmpCharArr.Length; j++)
|
||||||
|
// {
|
||||||
|
// if (tmpCharArr[j] == '1')
|
||||||
|
// {
|
||||||
|
// Bas_WarningMd tmpMd = GlobalHelper.BasWarningMd_List.Find(x => x.PlcItemCode == $"{priStr + (index + i)}" && x.WarningCode == $"{priWarnCode + j}" && x.WarningType == "1");
|
||||||
|
// if (tmpMd != null)
|
||||||
|
// {
|
||||||
|
// warnLst.Add(tmpMd);
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// GlobalHelper.ShowWarningMsg(warnLst, new EventArgs());
|
||||||
|
//}
|
||||||
|
}
|
||||||
|
else if (i >= 3 && i <= 9)
|
||||||
|
{//D13~D19报警
|
||||||
|
if (tmpReadAlarmBytArr_D[i] == 0)
|
||||||
|
{
|
||||||
|
CM_WarningLogMd warnLogTmp = GlobalHelper.CmWarningLogMd_List.Find(y => y.WarningStatus == 0 && y.WarningHandleResult == 0 && y.PlcItemCode == $"{priStr + (index + i)}");
|
||||||
|
if (warnLogTmp != null)
|
||||||
|
{
|
||||||
|
warnLogTmp.UpdateTime = DateTime.Now;
|
||||||
|
warnLogTmp.DataVersion += 1;
|
||||||
|
warnLogTmp.WarningStatus = 1;
|
||||||
|
warnLogTmp.WarningHandleResult = 1;
|
||||||
|
warnLogTmp.WarningHandleTime = DateTime.Now;
|
||||||
|
}
|
||||||
|
#region 已删除
|
||||||
|
//string sql2 = $@"
|
||||||
|
// UPDATE CM_WARNING_LOG
|
||||||
|
// SET UPDATE_TIME = datetime('now', 'localtime'),
|
||||||
|
// DATA_VERSION = DATA_VERSION + 1,
|
||||||
|
// WARING_STATUS = 1,
|
||||||
|
// WARNING_HANDLE_RESULT = 1,
|
||||||
|
// WARNING_HANDLE_TIME = datetime('now', 'localtime')
|
||||||
|
// WHERE
|
||||||
|
// EXISTS ( SELECT 1 FROM CM_WARNING_LOG WHERE WARING_STATUS = 0 AND WARNING_HANDLE_RESULT = 0 AND WARNING_CODE = '{i}' AND PLC_ITEM_CODE is NULL )
|
||||||
|
// AND WARING_STATUS = 0
|
||||||
|
// AND WARNING_HANDLE_RESULT = 0
|
||||||
|
// AND WARNING_CODE = 'i'
|
||||||
|
// AND PLC_ITEM_CODE is NULL;
|
||||||
|
// ";
|
||||||
|
//LeadDbHelperSQLite.ExecuteSql(sql2);
|
||||||
|
#endregion
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{//根据报警编码,获取报警信息,根据读取顺序编号,组成PlcItemCode
|
||||||
|
Bas_WarningMd tmpMd = GlobalHelper.BasWarningMd_List.Find(x => string.IsNullOrEmpty(x.PlcItemCode) && x.WarningCode == tmpReadAlarmBytArr_D[i].ToString() && x.WarningType == "2");
|
||||||
|
if (tmpMd != null)
|
||||||
|
{
|
||||||
|
CM_WarningLogMd warnLogTmp = GlobalHelper.CmWarningLogMd_List.Find(y => y.WarningStatus == 0 && y.WarningHandleResult == 0 && y.WarningCode == tmpMd.WarningCode && y.PlcItemCode == $"{priStr + (index + i)}");
|
||||||
|
if (warnLogTmp != null)
|
||||||
|
{
|
||||||
|
warnLogTmp.UpdateTime = DateTime.Now;
|
||||||
|
warnLogTmp.DataVersion += 1;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
GlobalHelper.CmWarningLogMd_List.Add(new CM_WarningLogMd
|
||||||
|
{
|
||||||
|
WarningCode = tmpMd.WarningCode,
|
||||||
|
WarningName = tmpMd.WarningName,
|
||||||
|
WarningType = tmpMd.WarningType,
|
||||||
|
WarningMessage = tmpMd.WarningMessage,
|
||||||
|
WarningTime = DateTime.Now,
|
||||||
|
PlcItemCode = $"{priStr + (index + i)}",
|
||||||
|
WarningStatus = 0,
|
||||||
|
WarningHandleResult = 0,
|
||||||
|
CreateBy = 1,
|
||||||
|
CreateTime = DateTime.Now,
|
||||||
|
UpdateBy = 1,
|
||||||
|
UpdateTime = DateTime.Now,
|
||||||
|
DataVersion = 0,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#region 已删除
|
||||||
|
|
||||||
|
// string sql = $@"SELECT * FROM BAS_WARNING WHERE PLC_ITEM_CODE is NULL and WARNING_CODE = '{i}' and WARNING_TYPE = '2'";
|
||||||
|
// DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
// if (dt != null && dt.Rows.Count > 0)
|
||||||
|
// {
|
||||||
|
// string sql1 = $@"
|
||||||
|
// INSERT INTO CM_WARNING_LOG (
|
||||||
|
// WARNING_CODE,
|
||||||
|
// WARNING_NAME,
|
||||||
|
// WARNING_TYPE,
|
||||||
|
// WARNING_MESSAGE,
|
||||||
|
// WARNING_TIME,
|
||||||
|
// PLC_ITEM_CODE,
|
||||||
|
// WARING_STATUS,
|
||||||
|
// WARNING_HANDLE_RESULT,
|
||||||
|
// CREATE_BY,
|
||||||
|
// CREATE_TIME,
|
||||||
|
// UPDATE_BY,
|
||||||
|
// UPDATE_TIME,
|
||||||
|
// DATA_VERSION
|
||||||
|
// )
|
||||||
|
// SELECT
|
||||||
|
// '{dt.Rows[0]["WARNING_CODE"]}',
|
||||||
|
// '{dt.Rows[0]["WARNING_NAME"]}',
|
||||||
|
// '{dt.Rows[0]["WARNING_TYPE"]}',
|
||||||
|
// '{dt.Rows[0]["WARNING_MESSAGE"]}',
|
||||||
|
// datetime('now', 'localtime'),
|
||||||
|
// '{dt.Rows[0]["PLC_ITEM_CODE"]}',
|
||||||
|
// 0,
|
||||||
|
// 0,
|
||||||
|
// 1,
|
||||||
|
// datetime('now', 'localtime'),
|
||||||
|
// 1,
|
||||||
|
// datetime('now', 'localtime'),
|
||||||
|
// 0
|
||||||
|
// WHERE NOT EXISTS (SELECT 1 FROM CM_WARNING_LOG WHERE WARING_STATUS = 0 and WARNING_HANDLE_RESULT = 0 and WARNING_CODE = '{dt.Rows[0]["WARNING_CODE"]}' and PLC_ITEM_CODE is NULL)
|
||||||
|
// ";
|
||||||
|
// LeadDbHelperSQLite.ExecuteSql(sql1);
|
||||||
|
// string sql2 = $@"
|
||||||
|
//UPDATE CM_WARNING_LOG set UPDATE_TIME = datetime('now', 'localtime'),DATA_VERSION = DATA_VERSION + 1
|
||||||
|
// WHERE EXISTS(SELECT 1 FROM CM_WARNING_LOG WHERE WARING_STATUS = 0 and WARNING_HANDLE_RESULT = 0 and WARNING_CODE = '{dt.Rows[0]["WARNING_CODE"]}' and PLC_ITEM_CODE is NULL) and WARING_STATUS = 0 and WARNING_HANDLE_RESULT = 0 and WARNING_CODE = '{dt.Rows[0]["WARNING_CODE"]}' and is NULL;
|
||||||
|
// ";
|
||||||
|
// LeadDbHelperSQLite.ExecuteSql(sql2);
|
||||||
|
// }
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (i > 9)
|
||||||
|
{
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
List<CM_WarningLogMd> tmpLst = GlobalHelper.CmWarningLogMd_List.FindAll(x => x.WarningHandleResult == 1 && x.WarningStatus == 1);
|
||||||
|
if (tmpLst.Count >= 10)
|
||||||
|
{
|
||||||
|
foreach (CM_WarningLogMd item in tmpLst)
|
||||||
|
{
|
||||||
|
string sql1 = $@"
|
||||||
|
INSERT INTO CM_WARNING_LOG (
|
||||||
|
WARNING_CODE,
|
||||||
|
WARNING_NAME,
|
||||||
|
WARNING_TYPE,
|
||||||
|
WARNING_MESSAGE,
|
||||||
|
WARNING_TIME,
|
||||||
|
PLC_ITEM_CODE,
|
||||||
|
WARING_STATUS,
|
||||||
|
WARNING_HANDLE_RESULT,
|
||||||
|
WARNING_HANDLE_TIME,
|
||||||
|
CREATE_BY,
|
||||||
|
CREATE_TIME,
|
||||||
|
UPDATE_BY,
|
||||||
|
UPDATE_TIME,
|
||||||
|
DATA_VERSION
|
||||||
|
)
|
||||||
|
VALUES (
|
||||||
|
'{item.WarningCode}',
|
||||||
|
'{item.WarningName}',
|
||||||
|
'{item.WarningType}',
|
||||||
|
'{item.WarningMessage}',
|
||||||
|
'{item.WarningTime.ToString("yyyy-MM-dd HH:mm:ss")}',
|
||||||
|
'{item.PlcItemCode}',
|
||||||
|
'{item.WarningStatus}',
|
||||||
|
'{item.WarningHandleResult}',
|
||||||
|
'{item.WarningHandleTime.ToString("yyyy-MM-dd HH:mm:ss")}',
|
||||||
|
'{item.CreateBy}',
|
||||||
|
'{item.CreateTime.ToString("yyyy-MM-dd HH:mm:ss")}',
|
||||||
|
'{item.UpdateBy}',
|
||||||
|
'{item.UpdateTime.ToString("yyyy-MM-dd HH:mm:ss")}',
|
||||||
|
'{item.DataVersion}'
|
||||||
|
);
|
||||||
|
";
|
||||||
|
LeadDbHelperSQLite.ExecuteSql(sql1);
|
||||||
|
}
|
||||||
|
GlobalHelper.CmWarningLogMd_List.RemoveAll(x => x.WarningHandleResult == 1 && x.WarningStatus == 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (GlobalHelper.CmWarningLogMd_List.FindAll(x => x.WarningHandleResult == 0 && x.WarningStatus == 0).Count > 0)
|
||||||
|
{
|
||||||
|
//frmMainNew.Show_ptb_Alarm(true);
|
||||||
|
GlobalHelper.ShowMainFrmAlarmMsg(true, EventArgs.Empty);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
//frmMainNew.Show_ptb_Alarm(false);
|
||||||
|
GlobalHelper.ShowMainFrmAlarmMsg(false, EventArgs.Empty);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"处理设备报警信息时发生异常:【{ex.Message}】", LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public void RefreshPlcItem_X()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
bool[] readBytArr_X = master.ReadInputs(1, 1024, 50);
|
||||||
|
if (readBytArr_X.Length > 0)
|
||||||
|
//if(true)
|
||||||
|
{
|
||||||
|
if (GlobalHelper.PlcItemMd_X_List != null && GlobalHelper.PlcItemMd_X_List.Count > 0)
|
||||||
|
{
|
||||||
|
foreach (BasPlcItemMd item in GlobalHelper.PlcItemMd_X_List)
|
||||||
|
{
|
||||||
|
if (!string.IsNullOrEmpty(item.PlcItemDeviationAddress))
|
||||||
|
{
|
||||||
|
string PlcItemId = item.PlcItemId.ToString();
|
||||||
|
string plcdatatype = item.PlcItemDataType.ToString();
|
||||||
|
int plcItemDeviationAddress = Convert.ToInt32(item.PlcItemDeviationAddress);
|
||||||
|
item.PlcItemValue = readBytArr_X[plcItemDeviationAddress].ToString();
|
||||||
|
|
||||||
|
//Random r = new Random();
|
||||||
|
//item.PlcItemValue = r.Next(0, 2) == 0 ? "False" : "True";
|
||||||
|
|
||||||
|
GlobalHelper.ShowX_Y_Status(item, new EventArgs());
|
||||||
|
GlobalHelper.ShowSensorStatus(item, new EventArgs());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"读取X 类型PLC变量时发生异常:【{ex.Message}】", LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public void RefreshPlcItem_Y()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
bool[] readBytArr_Y = master.ReadCoils(1, 1280, 50);
|
||||||
|
if (readBytArr_Y.Length > 0)
|
||||||
|
//if(true)
|
||||||
|
{
|
||||||
|
if (GlobalHelper.PlcItemMd_Y_List != null && GlobalHelper.PlcItemMd_Y_List.Count > 0)
|
||||||
|
{
|
||||||
|
foreach (BasPlcItemMd item in GlobalHelper.PlcItemMd_Y_List)
|
||||||
|
{
|
||||||
|
if (!string.IsNullOrEmpty(item.PlcItemDeviationAddress))
|
||||||
|
{
|
||||||
|
string PlcItemId = item.PlcItemId.ToString();
|
||||||
|
string plcdatatype = item.PlcItemDataType.ToString();
|
||||||
|
int plcItemDeviationAddress = Convert.ToInt32(item.PlcItemDeviationAddress);
|
||||||
|
item.PlcItemValue = readBytArr_Y[plcItemDeviationAddress].ToString();
|
||||||
|
|
||||||
|
//Random r = new Random();
|
||||||
|
//item.PlcItemValue = r.Next(0, 2) == 0 ? "False" : "True";
|
||||||
|
|
||||||
|
GlobalHelper.ShowX_Y_Status(item, new EventArgs());
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"读取Y 类型PLC变量时发生异常:【{ex.Message}】", LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public object ReadPlcItem(string plcItemCode, PlcItemTypeDesc itemType)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
object retObj;
|
||||||
|
switch (itemType)
|
||||||
|
{
|
||||||
|
case PlcItemTypeDesc.M:
|
||||||
|
BasPlcItemMd item_M = GlobalHelper.PlcItemMd_M_List.Find(x => x.PlcItemCode == plcItemCode);
|
||||||
|
if (item_M == null)
|
||||||
|
{
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
if (string.IsNullOrEmpty(item_M.PlcItemValue))
|
||||||
|
{
|
||||||
|
retObj = false;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
retObj = bool.Parse(item_M.PlcItemValue);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case PlcItemTypeDesc.D:
|
||||||
|
BasPlcItemMd item_D = GlobalHelper.PlcItemMd_D_List.Find(x => x.PlcItemCode == plcItemCode);
|
||||||
|
if (item_D == null)
|
||||||
|
{
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
if (string.IsNullOrEmpty(item_D.PlcItemValue))
|
||||||
|
{
|
||||||
|
retObj = 0;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
retObj = short.Parse(item_D.PlcItemValue);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case PlcItemTypeDesc.X:
|
||||||
|
BasPlcItemMd item_X = GlobalHelper.PlcItemMd_X_List.Find(x => x.PlcItemCode == plcItemCode);
|
||||||
|
if (item_X == null)
|
||||||
|
{
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
if (string.IsNullOrEmpty(item_X.PlcItemValue))
|
||||||
|
{
|
||||||
|
retObj = false;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
retObj = bool.Parse(item_X.PlcItemValue);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case PlcItemTypeDesc.Y:
|
||||||
|
BasPlcItemMd item_Y = GlobalHelper.PlcItemMd_Y_List.Find(x => x.PlcItemCode == plcItemCode);
|
||||||
|
if (item_Y == null)
|
||||||
|
{
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
if (string.IsNullOrEmpty(item_Y.PlcItemValue))
|
||||||
|
{
|
||||||
|
retObj = false;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
retObj = bool.Parse(item_Y.PlcItemValue);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
retObj = null;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
return retObj;
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"读取测试:【{plcItemCode}】", LogTypeEum.Err);
|
||||||
|
LogHelper.WriteLog($"读取【{itemType.ToString()}】类型PLC变量【{plcItemCode}】时发生异常:【{ex.Message}】", LogTypeEum.Err);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public bool WritePlcItem(string plcItemCode, string writeValue, PlcItemTypeDesc itemType)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
switch (itemType)
|
||||||
|
{
|
||||||
|
case PlcItemTypeDesc.M:
|
||||||
|
BasPlcItemMd item_M = GlobalHelper.PlcItemMd_M_List.Find(x => x.PlcItemCode == plcItemCode);
|
||||||
|
if (item_M == null)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
master.WriteSingleCoilAsync(1, Convert.ToUInt16(item_M.PlcItemModbusAddress), bool.Parse(writeValue));
|
||||||
|
return true;
|
||||||
|
case PlcItemTypeDesc.Y:
|
||||||
|
BasPlcItemMd item_Y = GlobalHelper.PlcItemMd_Y_List.Find(x => x.PlcItemCode == plcItemCode);
|
||||||
|
if (item_Y == null)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
master.WriteSingleCoilAsync(1, Convert.ToUInt16(item_Y.PlcItemModbusAddress), bool.Parse(writeValue));
|
||||||
|
return true;
|
||||||
|
case PlcItemTypeDesc.D:
|
||||||
|
BasPlcItemMd item_D = GlobalHelper.PlcItemMd_D_List.Find(x => x.PlcItemCode == plcItemCode);
|
||||||
|
if (item_D == null)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
master.WriteSingleRegisterAsync(1, Convert.ToUInt16(item_D.PlcItemModbusAddress), ushort.Parse(writeValue));
|
||||||
|
return true;
|
||||||
|
case PlcItemTypeDesc.X:
|
||||||
|
return false;
|
||||||
|
default:
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog($"写入【{itemType.ToString()}】类型PLC变量【{plcItemCode}】的值【{writeValue}】时发生异常:【{ex.Message}】", LogTypeEum.Err);
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
private int wcsToPlcHeartDataNew = 0;
|
||||||
|
private DateTime HeartbeatTime = new DateTime();
|
||||||
|
private int ReConnNum = 1;
|
||||||
|
public void HeartbeatDetection()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
int wcsToPlcHeartData = Convert.ToInt32(ReadPlcItem("PlcHeartbeatWriteData", PlcItemTypeDesc.D) == null ? 0 : ReadPlcItem("PlcHeartbeatWriteData", PlcItemTypeDesc.D));
|
||||||
|
int plcToWcsHeartData = Convert.ToInt32(ReadPlcItem("PlcHeartbeatReadData", PlcItemTypeDesc.D) == null ? 0 : ReadPlcItem("PlcHeartbeatReadData", PlcItemTypeDesc.D));
|
||||||
|
if (wcsToPlcHeartData == 0 && plcToWcsHeartData == 0)
|
||||||
|
{
|
||||||
|
WritePlcItem("PlcHeartbeatWriteData", "1", PlcItemTypeDesc.D);
|
||||||
|
wcsToPlcHeartDataNew = 1;
|
||||||
|
}
|
||||||
|
else if (wcsToPlcHeartDataNew == plcToWcsHeartData && plcToWcsHeartData != 0 && wcsToPlcHeartDataNew != 0)
|
||||||
|
{
|
||||||
|
if (plcToWcsHeartData >= 256)
|
||||||
|
{
|
||||||
|
wcsToPlcHeartDataNew = 1;
|
||||||
|
wcsToPlcHeartData = wcsToPlcHeartDataNew;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
wcsToPlcHeartData = wcsToPlcHeartDataNew + 1;
|
||||||
|
}
|
||||||
|
if (WritePlcItem("PlcHeartbeatWriteData", wcsToPlcHeartData.ToString(), PlcItemTypeDesc.D))
|
||||||
|
{
|
||||||
|
isConn = true;
|
||||||
|
HeartbeatTime = DateTime.Now;
|
||||||
|
wcsToPlcHeartDataNew = wcsToPlcHeartData;
|
||||||
|
frmMainNew.Show_Plc_Alarm("Serial port open success, PLC connect success!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (wcsToPlcHeartDataNew == 0 && plcToWcsHeartData != 0)
|
||||||
|
{
|
||||||
|
if (plcToWcsHeartData == wcsToPlcHeartData)
|
||||||
|
{
|
||||||
|
if (plcToWcsHeartData >= 256)
|
||||||
|
{
|
||||||
|
wcsToPlcHeartDataNew = 1;
|
||||||
|
wcsToPlcHeartData = wcsToPlcHeartDataNew;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
wcsToPlcHeartData = wcsToPlcHeartDataNew + 1;
|
||||||
|
}
|
||||||
|
if (WritePlcItem("PlcHeartbeatWriteData", wcsToPlcHeartData.ToString(), PlcItemTypeDesc.D))
|
||||||
|
{
|
||||||
|
isConn = true;
|
||||||
|
HeartbeatTime = DateTime.Now;
|
||||||
|
wcsToPlcHeartDataNew = wcsToPlcHeartData;
|
||||||
|
frmMainNew.Show_Plc_Alarm("Serial port open success, PLC connect success!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
WritePlcItem("PlcHeartbeatWriteData", wcsToPlcHeartDataNew.ToString(), PlcItemTypeDesc.D);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (DateTime.Now > HeartbeatTime.AddSeconds(5))//心跳超时
|
||||||
|
{
|
||||||
|
isConn = false;
|
||||||
|
//报警处理。
|
||||||
|
frmMainNew.Show_Plc_Alarm("PLC heartbeat data is abnormal, PLC loses connection!");
|
||||||
|
if (ReConnNum % 5 == 0)
|
||||||
|
{
|
||||||
|
ClosePlcConn();
|
||||||
|
PlcInit();
|
||||||
|
}
|
||||||
|
ReConnNum++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
public enum PlcItemTypeDesc
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// M 类型布尔变量
|
||||||
|
/// </summary>
|
||||||
|
M,
|
||||||
|
/// <summary>
|
||||||
|
/// D 类型整数变量
|
||||||
|
/// </summary>
|
||||||
|
D,
|
||||||
|
/// <summary>
|
||||||
|
/// X 类型布尔变量
|
||||||
|
/// </summary>
|
||||||
|
X,
|
||||||
|
/// <summary>
|
||||||
|
/// Y 类型布尔变量
|
||||||
|
/// </summary>
|
||||||
|
Y
|
||||||
|
}
|
||||||
|
}
|
||||||
434
CleanMachineHMI/Utils/frmUtil.cs
Normal file
@@ -0,0 +1,434 @@
|
|||||||
|
using CleanMachineHMI.Domain.Enums;
|
||||||
|
using ComponentFactory.Krypton.Navigator;
|
||||||
|
using ComponentFactory.Krypton.Toolkit;
|
||||||
|
using LeadDataBaseUtility;
|
||||||
|
using NX_LogUtility;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Data;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Runtime.CompilerServices;
|
||||||
|
using System.Security.Cryptography;
|
||||||
|
using System.Text;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace CleanMachineHMI.Utils
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 窗体工具
|
||||||
|
/// </summary>
|
||||||
|
public static class frmUtil
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 给一个字符串进行MD5加密
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="strText">待加密字符串</param>
|
||||||
|
/// <returns>加密后的字符串</returns>
|
||||||
|
public static string MD5Encrypt(string strText)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
MD5 md5 = MD5.Create();
|
||||||
|
byte[] buffer = Encoding.Default.GetBytes(strText);
|
||||||
|
byte[] md5buffer = md5.ComputeHash(buffer);
|
||||||
|
string str = null;
|
||||||
|
foreach (byte b in md5buffer)
|
||||||
|
{
|
||||||
|
str += b.ToString("x2");
|
||||||
|
}
|
||||||
|
return str;
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog(ex.Message, LogTypeEum.Err);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设置窗体容器
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="objFrm"></param>
|
||||||
|
/// <param name="parePage"></param>
|
||||||
|
public static void SetPageForm(this KryptonForm objFrm, KryptonPage panelPage)
|
||||||
|
{
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
objFrm.TopLevel = false;
|
||||||
|
objFrm.FormBorderStyle = FormBorderStyle.None;
|
||||||
|
objFrm.Dock = DockStyle.Fill;
|
||||||
|
objFrm.MinimizeBox = false;
|
||||||
|
objFrm.Parent = panelPage;
|
||||||
|
objFrm.Show();
|
||||||
|
objFrm.Refresh();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog(ex.Message, LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 界面刷新
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="kryptonNavigator"></param>
|
||||||
|
/// <param name="enumFormType"></param>
|
||||||
|
public static void SetNavPage(this KryptonNavigator kryptonNavigator, EnumFormType enumFormType)
|
||||||
|
{
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
Type frmType = GlobalHelper.FrmModelList.Where(s => s.FormType == enumFormType).FirstOrDefault().Form;
|
||||||
|
KryptonPage newPage;
|
||||||
|
if (!kryptonNavigator.Pages.Where(s => s.Name == enumFormType.ToString()).Any())
|
||||||
|
{
|
||||||
|
newPage = new KryptonPage { Text = "", Name = enumFormType.ToString(), };
|
||||||
|
kryptonNavigator.Pages.Add(newPage);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
newPage = kryptonNavigator.Pages.Where(s => s.Name == enumFormType.ToString()).FirstOrDefault();
|
||||||
|
}
|
||||||
|
|
||||||
|
kryptonNavigator.SelectedPage = newPage;
|
||||||
|
if (frmType.BaseType.Name == "UserControl")
|
||||||
|
{
|
||||||
|
var objFrm = (UserControl)Activator.CreateInstance(frmType);
|
||||||
|
objFrm.Dock = DockStyle.Fill;
|
||||||
|
objFrm.Parent = newPage;
|
||||||
|
objFrm.Show();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
var objFrm = (KryptonForm)Activator.CreateInstance(frmType);
|
||||||
|
objFrm.TopLevel = false;
|
||||||
|
objFrm.FormBorderStyle = FormBorderStyle.None;
|
||||||
|
objFrm.Dock = DockStyle.Fill;
|
||||||
|
objFrm.Parent = newPage;
|
||||||
|
objFrm.Show();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog(ex.Message, LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// object 选择返回值
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="obj"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
public static string GetObjToString(this object obj)
|
||||||
|
{
|
||||||
|
if (obj == null)
|
||||||
|
{
|
||||||
|
return string.Empty;
|
||||||
|
}
|
||||||
|
if (obj.ToString() == "")
|
||||||
|
{
|
||||||
|
return string.Empty;
|
||||||
|
}
|
||||||
|
return obj.ToString();
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设定窗体语言
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="form">窗体对象</param>
|
||||||
|
/// <param name="languageCode">语言编码</param>
|
||||||
|
public static void SetFormControlText(this Form form,string languageCode)
|
||||||
|
{
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
var sql = $@"SELECT * FROM SYS_LANGUAGE_CONTROL
|
||||||
|
WHERE USED_FLAG = 1 AND DEL_FLAG = 0
|
||||||
|
AND FORM_CODE='{form.Name}' AND LANGUAGE_CODE='{languageCode}' AND CONTROL_TYPE !='DataSource'";
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
ErgodicControlsText(form, dt);
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog(ex.Message, LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public static void SetFormControlText(this UserControl form, string languageCode)
|
||||||
|
{
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
var sql = $@"SELECT * FROM SYS_LANGUAGE_CONTROL
|
||||||
|
WHERE USED_FLAG = 1 AND DEL_FLAG = 0
|
||||||
|
AND FORM_CODE='{form.Name}' AND LANGUAGE_CODE='{languageCode}' AND CONTROL_TYPE !='DataSource'";
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
ErgodicControlsText(form, dt);
|
||||||
|
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog(ex.Message, LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/// <summary>
|
||||||
|
/// 设定数据视图列文本
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="dataGrid"></param>
|
||||||
|
/// <param name="formName"></param>
|
||||||
|
/// <param name="languageCode"></param>
|
||||||
|
public static void SetDataViewColumnText(this DataGridView dataGrid ,string formName, string languageCode)
|
||||||
|
{
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
|
||||||
|
var sql = $@"SELECT * FROM SYS_LANGUAGE_CONTROL
|
||||||
|
WHERE USED_FLAG = 1 AND DEL_FLAG = 0
|
||||||
|
AND FORM_CODE='{formName}' AND LANGUAGE_CODE='{languageCode}' AND CONTROL_TYPE ='DataSource'";
|
||||||
|
DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
ErgodicColumnsText(dataGrid, dt);
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog(ex.Message, LogTypeEum.Err);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设定数据视图列文本
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="dataGrid"></param>
|
||||||
|
/// <param name="formName"></param>
|
||||||
|
/// <param name="languageCode"></param>
|
||||||
|
public static DataTable GetInfoLanguageText(this Form form, string languageCode, string controlType = "Info")
|
||||||
|
{
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
|
||||||
|
var sql = $@"SELECT * FROM SYS_LANGUAGE_CONTROL
|
||||||
|
WHERE USED_FLAG = 1 AND DEL_FLAG = 0
|
||||||
|
AND (FORM_CODE='{form.Name}' OR IFNULL(FORM_CODE,'')='') AND LANGUAGE_CODE='{languageCode}' AND CONTROL_TYPE = '{controlType}' ORDER BY LANGUAGE_CONTROL_ID";
|
||||||
|
return LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog(ex.Message, LogTypeEum.Err);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public static DataTable GetInfoLanguageText(this UserControl form, string languageCode, string controlType = "Info")
|
||||||
|
{
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
|
||||||
|
var sql = $@"SELECT * FROM SYS_LANGUAGE_CONTROL
|
||||||
|
WHERE USED_FLAG = 1 AND DEL_FLAG = 0
|
||||||
|
AND (FORM_CODE='{form.Name}' OR IFNULL(FORM_CODE,'')='') AND LANGUAGE_CODE='{languageCode}' AND CONTROL_TYPE = '{controlType}' ORDER BY LANGUAGE_CONTROL_ID";
|
||||||
|
return LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog(ex.Message, LogTypeEum.Err);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public static DataTable GetInfoLanguageText_1(this Form form, string languageCode, string controlType = "Info")
|
||||||
|
{
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
var sql = $@"SELECT * FROM SYS_LANGUAGE_CONTROL
|
||||||
|
WHERE USED_FLAG = 1 AND DEL_FLAG = 0
|
||||||
|
AND (FORM_CODE='{form.Name}' OR IFNULL(FORM_CODE,'')='') AND LANGUAGE_CODE='{languageCode}' AND CONTROL_TYPE like '{controlType}' ORDER BY LANGUAGE_CONTROL_ID";
|
||||||
|
return LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog(ex.Message, LogTypeEum.Err);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public static DataTable GetInfoLanguageText_1(this UserControl form, string languageCode, string controlType = "Info")
|
||||||
|
{
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
var sql = $@"SELECT * FROM SYS_LANGUAGE_CONTROL
|
||||||
|
WHERE USED_FLAG = 1 AND DEL_FLAG = 0
|
||||||
|
AND (FORM_CODE='{form.Name}' OR IFNULL(FORM_CODE,'')='') AND LANGUAGE_CODE='{languageCode}' AND CONTROL_TYPE like '{controlType}' ORDER BY LANGUAGE_CONTROL_ID";
|
||||||
|
return LeadDbHelperSQLite.Query(sql).Tables[0];
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog(ex.Message, LogTypeEum.Err);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/// <summary>
|
||||||
|
/// 获取等于查询行
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="dataTable"></param>
|
||||||
|
/// <param name="key"></param>
|
||||||
|
/// <param name="value"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
public static DataRow[] GetEqualSelectRow(this DataTable dataTable,string key,string value)
|
||||||
|
{
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
var likeSql = $"`{key}` = '{value}'";
|
||||||
|
DataRow[] dataRow = dataTable.Select(likeSql);
|
||||||
|
return dataRow;
|
||||||
|
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog(ex.Message, LogTypeEum.Err);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 获取包含查询行
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="dataTable"></param>
|
||||||
|
/// <param name="key"></param>
|
||||||
|
/// <param name="value"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
public static DataRow[] GetContainSelectRow(this DataTable dataTable, string key, string value)
|
||||||
|
{
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
|
||||||
|
var likeSql = $"`{key}` like '%{value}%'";
|
||||||
|
DataRow[] dataRow = dataTable.Select(likeSql);
|
||||||
|
return dataRow;
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog(ex.Message, LogTypeEum.Err);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 获取信息文本
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="dataTable"></param>
|
||||||
|
/// <param name="key"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
public static string GetInfoText(this DataTable dataTable,string defaultValue,string key)
|
||||||
|
{
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
var likeSql = $"`CONTROL_CODE` = '{key}' and `CONTROL_TYPE` = 'Info'";
|
||||||
|
DataRow[] dataRow = dataTable.Select(likeSql);
|
||||||
|
if (dataRow == null || !dataRow.Any())
|
||||||
|
{
|
||||||
|
return defaultValue;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return dataRow[0]["CONTROL_NAME"].ToString();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog(ex.Message, LogTypeEum.Err);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public static string GetInfoText_1(this DataTable dataTable, string defaultValue, string key, string controlType)
|
||||||
|
{
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
var likeSql = $"`CONTROL_CODE` = '{key}' and `CONTROL_TYPE` = '{controlType}'";
|
||||||
|
DataRow[] dataRow = dataTable.Select(likeSql);
|
||||||
|
if (dataRow == null || !dataRow.Any())
|
||||||
|
{
|
||||||
|
return defaultValue;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return dataRow[0]["CONTROL_NAME"].ToString();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog(ex.Message, LogTypeEum.Err);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public static DataRow[] GetComBoboxItemArr(this DataTable dataTable, string key, string controlType)
|
||||||
|
{
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
var likeSql = $"`CONTROL_CODE` = '{key}' and `CONTROL_TYPE` = '{controlType}'";
|
||||||
|
DataRow[] dataRow = dataTable.Select(likeSql);
|
||||||
|
return dataRow;
|
||||||
|
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
LogHelper.WriteLog(ex.Message, LogTypeEum.Err);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/// <summary>
|
||||||
|
/// 遍历控制界面
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="container"></param>
|
||||||
|
/// <param name="dataTable"></param>
|
||||||
|
private static void ErgodicControlsText(Control container,DataTable dataTable)
|
||||||
|
{
|
||||||
|
for (int i = 0; i < dataTable.Rows.Count; i++)
|
||||||
|
{
|
||||||
|
Control[] tmpC = container.Controls.Find(dataTable.Rows[i]["CONTROL_CODE"].ToString(), true);
|
||||||
|
if (tmpC.Length>0)
|
||||||
|
{
|
||||||
|
if (tmpC[0] is KryptonGroupBox)
|
||||||
|
{
|
||||||
|
//Console.Write("模块名称"+ ((KryptonGroupBox)tmpC[0]).Values.Heading);
|
||||||
|
//Console.Write("\r\n");
|
||||||
|
((KryptonGroupBox)tmpC[0]).Values.Heading = dataTable.Rows[i]["CONTROL_NAME"].ToString();
|
||||||
|
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
//Console.Write("控件名称:"+ tmpC[0].Name+ ":控件中文名:" + tmpC[0].Text);
|
||||||
|
//Console.Write("\r\n");
|
||||||
|
tmpC[0].Text = dataTable.Rows[i]["CONTROL_NAME"].ToString();
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 遍历数据视图控件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="dataGrid"></param>
|
||||||
|
/// <param name="dataTable"></param>
|
||||||
|
private static void ErgodicColumnsText(DataGridView dataGrid, DataTable dataTable)
|
||||||
|
{
|
||||||
|
for(int k = 0; k < dataGrid.Columns.Count; k++)
|
||||||
|
{
|
||||||
|
for (int i = 0; i < dataTable.Rows.Count; i++)
|
||||||
|
{
|
||||||
|
if (dataGrid.Columns[k].Name == dataTable.Rows[i]["CONTROL_CODE"].ToString())
|
||||||
|
{
|
||||||
|
dataGrid.Columns[k].HeaderText = dataTable.Rows[i]["CONTROL_NAME"].ToString();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||