diff --git a/.vs/WinformGeneralDeveloperFrame/v16/.suo b/.vs/WinformGeneralDeveloperFrame/v16/.suo index c32e5b0..c963997 100644 Binary files a/.vs/WinformGeneralDeveloperFrame/v16/.suo and b/.vs/WinformGeneralDeveloperFrame/v16/.suo differ diff --git a/WinformGeneralDeveloperFrame.Start/App.config b/WinformGeneralDeveloperFrame.Start/App.config new file mode 100644 index 0000000..76fe7b1 --- /dev/null +++ b/WinformGeneralDeveloperFrame.Start/App.config @@ -0,0 +1,67 @@ + + + + +
+ + +
+ + + + + System + + + + + + Skin/Office 2010 Blue + + + + + + + + + + + + + + + + + + True + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/WinformGeneralDeveloperFrame.Start/Program.cs b/WinformGeneralDeveloperFrame.Start/Program.cs new file mode 100644 index 0000000..42eaf7b --- /dev/null +++ b/WinformGeneralDeveloperFrame.Start/Program.cs @@ -0,0 +1,27 @@ +using DevExpress.Skins; +using DevExpress.UserSkins; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Windows.Forms; +using DevExpress.LookAndFeel; + +namespace WinformGeneralDeveloperFrame.Start +{ + static class Program + { + /// + /// The main entry point for the application. + /// + [STAThread] + static void Main() + { + DevExpress.Skins.SkinManager.EnableFormSkins(); + UserLookAndFeel.Default.SetSkinStyle("Office 2010 Blue"); + BonusSkins.Register(); + Application.EnableVisualStyles(); + Application.SetCompatibleTextRenderingDefault(false); + Application.Run(new MainForm()); + } + } +} \ No newline at end of file diff --git a/WinformGeneralDeveloperFrame.Start/Properties/AssemblyInfo.cs b/WinformGeneralDeveloperFrame.Start/Properties/AssemblyInfo.cs new file mode 100644 index 0000000..274f0bf --- /dev/null +++ b/WinformGeneralDeveloperFrame.Start/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +// 有关程序集的一般信息由以下 +// 控制。更改这些特性值可修改 +// 与程序集关联的信息。 +[assembly: AssemblyTitle("WinformGeneralDeveloperFrame.Start")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("WinformGeneralDeveloperFrame.Start")] +[assembly: AssemblyCopyright("Copyright © 2021")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// 将 ComVisible 设置为 false 会使此程序集中的类型 +//对 COM 组件不可见。如果需要从 COM 访问此程序集中的类型 +//请将此类型的 ComVisible 特性设置为 true。 +[assembly: ComVisible(false)] + +// 如果此项目向 COM 公开,则下列 GUID 用于类型库的 ID +[assembly: Guid("ab69d376-acc7-4d9c-b5ea-b8c3e5b64103")] + +// 程序集的版本信息由下列四个值组成: +// +// 主版本 +// 次版本 +// 生成号 +// 修订号 +// +//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值 +//通过使用 "*",如下所示: +// [assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/WinformGeneralDeveloperFrame.Start/WinformGeneralDeveloperFrame.Start.csproj b/WinformGeneralDeveloperFrame.Start/WinformGeneralDeveloperFrame.Start.csproj new file mode 100644 index 0000000..c6d819b --- /dev/null +++ b/WinformGeneralDeveloperFrame.Start/WinformGeneralDeveloperFrame.Start.csproj @@ -0,0 +1,79 @@ + + + + + Debug + AnyCPU + {AB69D376-ACC7-4D9C-B5EA-B8C3E5B64103} + WinExe + Properties + WinformGeneralDeveloperFrame.Start + WinformGeneralDeveloperFrame.Start + v4.8 + 512 + true + + + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + + + + False + ..\..\..\..\..\Program Files (x86)\DevExpress 19.2\Components\Bin\Framework\DevExpress.BonusSkins.v19.2.dll + + + + + ..\packages\EntityFramework.6.2.0\lib\net45\EntityFramework.dll + + + ..\packages\EntityFramework.6.2.0\lib\net45\EntityFramework.SqlServer.dll + + + + + + + + + + + + + + + + + + + {6f2b061d-6116-45a4-9649-49ae4981c496} + WinformGeneralDeveloperFrame.Commons + + + {fccdaf3a-fc3e-4f85-b794-2aaa299fbc45} + WinformGeneralDeveloperFrame + + + + + + + + \ No newline at end of file diff --git a/WinformGeneralDeveloperFrame.Start/packages.config b/WinformGeneralDeveloperFrame.Start/packages.config new file mode 100644 index 0000000..f1df1d6 --- /dev/null +++ b/WinformGeneralDeveloperFrame.Start/packages.config @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/WinformGeneralDeveloperFrame.sln b/WinformGeneralDeveloperFrame.sln index c47b684..745242a 100644 --- a/WinformGeneralDeveloperFrame.sln +++ b/WinformGeneralDeveloperFrame.sln @@ -7,6 +7,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WinformGeneralDeveloperFram EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WinformGeneralDeveloperFrame.Commons", "WinformGeneralDeveloperFrame.Commons\WinformGeneralDeveloperFrame.Commons.csproj", "{6F2B061D-6116-45A4-9649-49AE4981C496}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WinformGeneralDeveloperFrame.Start", "WinformGeneralDeveloperFrame.Start\WinformGeneralDeveloperFrame.Start.csproj", "{AB69D376-ACC7-4D9C-B5EA-B8C3E5B64103}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -21,6 +23,10 @@ Global {6F2B061D-6116-45A4-9649-49AE4981C496}.Debug|Any CPU.Build.0 = Debug|Any CPU {6F2B061D-6116-45A4-9649-49AE4981C496}.Release|Any CPU.ActiveCfg = Release|Any CPU {6F2B061D-6116-45A4-9649-49AE4981C496}.Release|Any CPU.Build.0 = Release|Any CPU + {AB69D376-ACC7-4D9C-B5EA-B8C3E5B64103}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {AB69D376-ACC7-4D9C-B5EA-B8C3E5B64103}.Debug|Any CPU.Build.0 = Debug|Any CPU + {AB69D376-ACC7-4D9C-B5EA-B8C3E5B64103}.Release|Any CPU.ActiveCfg = Release|Any CPU + {AB69D376-ACC7-4D9C-B5EA-B8C3E5B64103}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/WinformGeneralDeveloperFrame/BaseForm.Designer.cs b/WinformGeneralDeveloperFrame/BaseForm.Designer.cs new file mode 100644 index 0000000..814edb5 --- /dev/null +++ b/WinformGeneralDeveloperFrame/BaseForm.Designer.cs @@ -0,0 +1,46 @@ + +namespace WinformGeneralDeveloperFrame +{ + partial class BaseForm + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Component Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.SuspendLayout(); + // + // BaseForm + // + this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.Name = "BaseForm"; + this.Size = new System.Drawing.Size(668, 450); + this.ResumeLayout(false); + + } + + #endregion + } +} diff --git a/WinformGeneralDeveloperFrame/BaseForm.cs b/WinformGeneralDeveloperFrame/BaseForm.cs new file mode 100644 index 0000000..29e0567 --- /dev/null +++ b/WinformGeneralDeveloperFrame/BaseForm.cs @@ -0,0 +1,21 @@ +using DevExpress.XtraEditors; +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 WinformGeneralDeveloperFrame +{ + public partial class BaseForm : DevExpress.XtraEditors.XtraUserControl + { + public BaseForm() + { + InitializeComponent(); + } + } +} diff --git a/WinformGeneralDeveloperFrame/BaseForm.resx b/WinformGeneralDeveloperFrame/BaseForm.resx new file mode 100644 index 0000000..1af7de1 --- /dev/null +++ b/WinformGeneralDeveloperFrame/BaseForm.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/WinformGeneralDeveloperFrame/ChildWinManagement.cs b/WinformGeneralDeveloperFrame/ChildWinManagement.cs index 7736ae3..49e2677 100644 --- a/WinformGeneralDeveloperFrame/ChildWinManagement.cs +++ b/WinformGeneralDeveloperFrame/ChildWinManagement.cs @@ -57,7 +57,7 @@ namespace WinformGeneralDeveloperFrame form.Activate(); return form; } - public static Form LoadShowForm(Form mainDialog, Type formType,string caption) + public static Form LoadShowForm(Form mainDialog, Type formType,string caption,int formId) { bool flag = false; @@ -76,10 +76,13 @@ namespace WinformGeneralDeveloperFrame { form = (Form)Activator.CreateInstance(formType); form.MdiParent = mainDialog; - form.Show(); + } FrmShowForm frmShowForm=form as FrmShowForm; frmShowForm.Text = caption; + frmShowForm.formId = formId; + frmShowForm.Init(); + frmShowForm.Show(); MainForm manForm= mainDialog as MainForm; frmShowForm.mainform = manForm; form.BringToFront(); diff --git a/WinformGeneralDeveloperFrame/Form/FrmsysDictData.cs b/WinformGeneralDeveloperFrame/Form/FrmsysDictData.cs index d2cbea5..9eff153 100644 --- a/WinformGeneralDeveloperFrame/Form/FrmsysDictData.cs +++ b/WinformGeneralDeveloperFrame/Form/FrmsysDictData.cs @@ -22,23 +22,18 @@ namespace MES.Form } private void FrmsysDictData_Load(object sender, EventArgs e) { - - InitFrom(xtraTabControl1,grdList,grdListView,new LayoutControlGroup[]{layoutControlGroup1},new sysDictDataInfo()); + + InitFrom(xtraTabControl1,grdList,grdListView,new LayoutControlGroup[]{layoutControlGroup1},new sysDictDataInfo()); } private void Init() { - - - - - txtdictTypeID.Properties.DataSource = GetDataTableUtils.SqlTable("字典类型"); - repositoryItemTreeListtxtdictTypeID.DataSource= GetDataTableUtils.SqlTable("字典类型"); - txtcreatorId.Properties.DataSource = GetDataTableUtils.SqlTable("用户"); - repositoryItemtxtcreatorId.DataSource= GetDataTableUtils.SqlTable("用户"); - txteditorId.Properties.DataSource = GetDataTableUtils.SqlTable("用户"); - repositoryItemtxteditorId.DataSource= GetDataTableUtils.SqlTable("用户"); - - } + txtdictTypeID.Properties.DataSource = GetDataTableUtils.SqlTable("字典类型"); + repositoryItemTreeListtxtdictTypeID.DataSource= GetDataTableUtils.SqlTable("字典类型"); + txtcreatorId.Properties.DataSource = GetDataTableUtils.SqlTable("用户"); + repositoryItemtxtcreatorId.DataSource= GetDataTableUtils.SqlTable("用户"); + txteditorId.Properties.DataSource = GetDataTableUtils.SqlTable("用户"); + repositoryItemtxteditorId.DataSource= GetDataTableUtils.SqlTable("用户"); + } public override bool SaveFunction() { try diff --git a/WinformGeneralDeveloperFrame/Form/FrmsysDictData.designer.cs b/WinformGeneralDeveloperFrame/Form/FrmsysDictData.designer.cs index 2ba9488..41ef5fd 100644 --- a/WinformGeneralDeveloperFrame/Form/FrmsysDictData.designer.cs +++ b/WinformGeneralDeveloperFrame/Form/FrmsysDictData.designer.cs @@ -33,123 +33,286 @@ namespace MES.Form /// private void InitializeComponent() { - this.gridColumn1 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn2 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn3 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn4 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn5 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn6 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn7 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn8 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn9 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn10 = new DevExpress.XtraGrid.Columns.GridColumn(); - + this.gridColumn1 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.gridColumn2 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.repositoryItemTreeListtxtdictTypeID = new DevExpress.XtraEditors.Repository.RepositoryItemTreeListLookUpEdit(); + this.repositoryItemTreeListtxtdictTypeIDTreeList = new DevExpress.XtraTreeList.TreeList(); + this.gridColumn3 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.gridColumn4 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.gridColumn5 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.gridColumn6 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.gridColumn7 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.repositoryItemtxtcreatorId = new DevExpress.XtraEditors.Repository.RepositoryItemLookUpEdit(); + this.gridColumn8 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.gridColumn9 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.repositoryItemtxteditorId = new DevExpress.XtraEditors.Repository.RepositoryItemLookUpEdit(); + this.gridColumn10 = new DevExpress.XtraGrid.Columns.GridColumn(); this.xtraTabControl1 = new DevExpress.XtraTab.XtraTabControl(); this.tabDataList = new DevExpress.XtraTab.XtraTabPage(); - this.tabDataDetail = new DevExpress.XtraTab.XtraTabPage(); this.grdList = new DevExpress.XtraGrid.GridControl(); this.grdListView = new DevExpress.XtraGrid.Views.Grid.GridView(); + this.tabDataDetail = new DevExpress.XtraTab.XtraTabPage(); this.panelControl2 = new DevExpress.XtraEditors.PanelControl(); this.layoutControl1 = new DevExpress.XtraLayout.LayoutControl(); - this.layoutControlGroup1 = new DevExpress.XtraLayout.LayoutControlGroup(); - - - ////////////////////// - this.txtid=new DevExpress.XtraEditors.TextEdit(); - this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem(); - this.txtdictTypeIDTreeList = new DevExpress.XtraTreeList.TreeList(); - this.repositoryItemTreeListtxtdictTypeID = new DevExpress.XtraEditors.Repository.RepositoryItemTreeListLookUpEdit(); - this.repositoryItemTreeListtxtdictTypeIDTreeList = new DevExpress.XtraTreeList.TreeList(); - this.txtdictTypeID=new DevExpress.XtraEditors.TreeListLookUpEdit(); - this.layoutControlItem2 = new DevExpress.XtraLayout.LayoutControlItem(); - ////////////////////// - this.txtcode=new DevExpress.XtraEditors.TextEdit(); - this.layoutControlItem3 = new DevExpress.XtraLayout.LayoutControlItem(); - ////////////////////// - this.txtvalue=new DevExpress.XtraEditors.TextEdit(); - this.layoutControlItem4 = new DevExpress.XtraLayout.LayoutControlItem(); - ////////////////////// - this.txtremark=new DevExpress.XtraEditors.TextEdit(); - this.layoutControlItem5 = new DevExpress.XtraLayout.LayoutControlItem(); - ////////////////////// - this.txtsort=new DevExpress.XtraEditors.TextEdit(); - this.layoutControlItem6 = new DevExpress.XtraLayout.LayoutControlItem(); - this.repositoryItemtxtcreatorId = new DevExpress.XtraEditors.Repository.RepositoryItemLookUpEdit(); - - this.txtcreatorId=new DevExpress.XtraEditors.LookUpEdit(); - this.layoutControlItem7 = new DevExpress.XtraLayout.LayoutControlItem(); - ////////////////////// - this.txtcreateTime=new DevExpress.XtraEditors.DateEdit(); - this.layoutControlItem8 = new DevExpress.XtraLayout.LayoutControlItem(); - this.repositoryItemtxteditorId = new DevExpress.XtraEditors.Repository.RepositoryItemLookUpEdit(); - - this.txteditorId=new DevExpress.XtraEditors.LookUpEdit(); - this.layoutControlItem9 = new DevExpress.XtraLayout.LayoutControlItem(); - ////////////////////// - this.txteditTime=new DevExpress.XtraEditors.DateEdit(); - this.layoutControlItem10 = new DevExpress.XtraLayout.LayoutControlItem(); - - - ((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit(); - - this.layoutControl1.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).BeginInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtid.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtdictTypeIDTreeList)).BeginInit(); + this.layoutControlGroup1 = new DevExpress.XtraLayout.LayoutControlGroup(); + this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txtid = new DevExpress.XtraEditors.TextEdit(); + this.layoutControlItem2 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txtdictTypeID = new DevExpress.XtraEditors.TreeListLookUpEdit(); + this.txtdictTypeIDTreeList = new DevExpress.XtraTreeList.TreeList(); + this.layoutControlItem3 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txtcode = new DevExpress.XtraEditors.TextEdit(); + this.layoutControlItem4 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txtvalue = new DevExpress.XtraEditors.TextEdit(); + this.layoutControlItem5 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txtremark = new DevExpress.XtraEditors.TextEdit(); + this.layoutControlItem6 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txtsort = new DevExpress.XtraEditors.TextEdit(); + this.layoutControlItem7 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txtcreatorId = new DevExpress.XtraEditors.LookUpEdit(); + this.layoutControlItem8 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txtcreateTime = new DevExpress.XtraEditors.DateEdit(); + this.layoutControlItem9 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txteditorId = new DevExpress.XtraEditors.LookUpEdit(); + this.layoutControlItem10 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txteditTime = new DevExpress.XtraEditors.DateEdit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemTreeListtxtdictTypeID)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemTreeListtxtdictTypeIDTreeList)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtdictTypeID.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).BeginInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtcode.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).BeginInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtvalue.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).BeginInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtremark.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).BeginInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtsort.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemtxtcreatorId)).BeginInit(); - - ((System.ComponentModel.ISupportInitialize)(this.txtcreatorId.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties.CalendarTimeProperties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemtxteditorId)).BeginInit(); - - ((System.ComponentModel.ISupportInitialize)(this.txteditorId.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties.CalendarTimeProperties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem10)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.xtraTabControl1)).BeginInit(); this.xtraTabControl1.SuspendLayout(); this.tabDataList.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.grdList)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.grdListView)).BeginInit(); this.tabDataDetail.SuspendLayout(); - + ((System.ComponentModel.ISupportInitialize)(this.panelControl2)).BeginInit(); + this.panelControl2.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit(); + this.layoutControl1.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtid.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtdictTypeID.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtdictTypeIDTreeList)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtcode.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtvalue.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtremark.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtsort.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtcreatorId.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties.CalendarTimeProperties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txteditorId.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem10)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties.CalendarTimeProperties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties)).BeginInit(); this.SuspendLayout(); - + // + // gridColumn1 + // + this.gridColumn1.Caption = "id"; + this.gridColumn1.FieldName = "id"; + this.gridColumn1.Name = "gridColumn1"; + // + // gridColumn2 + // + this.gridColumn2.Caption = "类型"; + this.gridColumn2.ColumnEdit = this.repositoryItemTreeListtxtdictTypeID; + this.gridColumn2.FieldName = "dictTypeID"; + this.gridColumn2.Name = "gridColumn2"; + this.gridColumn2.Visible = true; + this.gridColumn2.VisibleIndex = 0; + this.gridColumn2.Width = 201; + // + // repositoryItemTreeListtxtdictTypeID + // + this.repositoryItemTreeListtxtdictTypeID.AutoHeight = false; + this.repositoryItemTreeListtxtdictTypeID.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); + this.repositoryItemTreeListtxtdictTypeID.DisplayMember = "Name"; + this.repositoryItemTreeListtxtdictTypeID.Name = "repositoryItemTreeListtxtdictTypeID"; + this.repositoryItemTreeListtxtdictTypeID.TreeList = this.repositoryItemTreeListtxtdictTypeIDTreeList; + this.repositoryItemTreeListtxtdictTypeID.ValueMember = "ID"; + // + // repositoryItemTreeListtxtdictTypeIDTreeList + // + this.repositoryItemTreeListtxtdictTypeIDTreeList.Location = new System.Drawing.Point(0, 0); + this.repositoryItemTreeListtxtdictTypeIDTreeList.Name = "repositoryItemTreeListtxtdictTypeIDTreeList"; + this.repositoryItemTreeListtxtdictTypeIDTreeList.OptionsView.ShowIndentAsRowStyle = true; + this.repositoryItemTreeListtxtdictTypeIDTreeList.ParentFieldName = "PID"; + this.repositoryItemTreeListtxtdictTypeIDTreeList.Size = new System.Drawing.Size(400, 200); + this.repositoryItemTreeListtxtdictTypeIDTreeList.TabIndex = 0; + // + // gridColumn3 + // + this.gridColumn3.Caption = "编码"; + this.gridColumn3.FieldName = "code"; + this.gridColumn3.Name = "gridColumn3"; + this.gridColumn3.Visible = true; + this.gridColumn3.VisibleIndex = 1; + this.gridColumn3.Width = 201; + // + // gridColumn4 + // + this.gridColumn4.Caption = "值"; + this.gridColumn4.FieldName = "value"; + this.gridColumn4.Name = "gridColumn4"; + this.gridColumn4.Visible = true; + this.gridColumn4.VisibleIndex = 2; + this.gridColumn4.Width = 201; + // + // gridColumn5 + // + this.gridColumn5.Caption = "备注"; + this.gridColumn5.FieldName = "remark"; + this.gridColumn5.Name = "gridColumn5"; + this.gridColumn5.Visible = true; + this.gridColumn5.VisibleIndex = 3; + this.gridColumn5.Width = 201; + // + // gridColumn6 + // + this.gridColumn6.Caption = "排序"; + this.gridColumn6.FieldName = "sort"; + this.gridColumn6.Name = "gridColumn6"; + this.gridColumn6.Visible = true; + this.gridColumn6.VisibleIndex = 4; + this.gridColumn6.Width = 201; + // + // gridColumn7 + // + this.gridColumn7.Caption = "创建人"; + this.gridColumn7.ColumnEdit = this.repositoryItemtxtcreatorId; + this.gridColumn7.FieldName = "creatorId"; + this.gridColumn7.Name = "gridColumn7"; + this.gridColumn7.Visible = true; + this.gridColumn7.VisibleIndex = 5; + this.gridColumn7.Width = 201; + // + // repositoryItemtxtcreatorId + // + this.repositoryItemtxtcreatorId.AutoHeight = false; + this.repositoryItemtxtcreatorId.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); + this.repositoryItemtxtcreatorId.DisplayMember = "Name"; + this.repositoryItemtxtcreatorId.Name = "repositoryItemtxtcreatorId"; + this.repositoryItemtxtcreatorId.ValueMember = "ID"; + // + // gridColumn8 + // + this.gridColumn8.Caption = "创建时间"; + this.gridColumn8.DisplayFormat.FormatString = "G"; + this.gridColumn8.DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; + this.gridColumn8.FieldName = "createTime"; + this.gridColumn8.Name = "gridColumn8"; + this.gridColumn8.Visible = true; + this.gridColumn8.VisibleIndex = 6; + this.gridColumn8.Width = 201; + // + // gridColumn9 + // + this.gridColumn9.Caption = "编辑人"; + this.gridColumn9.ColumnEdit = this.repositoryItemtxteditorId; + this.gridColumn9.FieldName = "editorId"; + this.gridColumn9.Name = "gridColumn9"; + this.gridColumn9.Visible = true; + this.gridColumn9.VisibleIndex = 7; + this.gridColumn9.Width = 201; + // + // repositoryItemtxteditorId + // + this.repositoryItemtxteditorId.AutoHeight = false; + this.repositoryItemtxteditorId.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); + this.repositoryItemtxteditorId.DisplayMember = "Name"; + this.repositoryItemtxteditorId.Name = "repositoryItemtxteditorId"; + this.repositoryItemtxteditorId.ValueMember = "ID"; + // + // gridColumn10 + // + this.gridColumn10.Caption = "编辑时间"; + this.gridColumn10.DisplayFormat.FormatString = "G"; + this.gridColumn10.DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; + this.gridColumn10.FieldName = "editTime"; + this.gridColumn10.Name = "gridColumn10"; + this.gridColumn10.Visible = true; + this.gridColumn10.VisibleIndex = 8; + this.gridColumn10.Width = 201; + // + // xtraTabControl1 + // + this.xtraTabControl1.Dock = System.Windows.Forms.DockStyle.Fill; + this.xtraTabControl1.Location = new System.Drawing.Point(0, 34); + this.xtraTabControl1.Name = "xtraTabControl1"; + this.xtraTabControl1.SelectedTabPage = this.tabDataList; + this.xtraTabControl1.Size = new System.Drawing.Size(1300, 766); + this.xtraTabControl1.TabIndex = 1; + this.xtraTabControl1.TabPages.AddRange(new DevExpress.XtraTab.XtraTabPage[] { + this.tabDataList, + this.tabDataDetail}); + // + // tabDataList + // + this.tabDataList.Controls.Add(this.grdList); + this.tabDataList.Name = "tabDataList"; + this.tabDataList.Size = new System.Drawing.Size(1294, 737); + this.tabDataList.Text = "数据列表"; + // + // grdList + // + this.grdList.Dock = System.Windows.Forms.DockStyle.Fill; + this.grdList.Location = new System.Drawing.Point(0, 0); + this.grdList.MainView = this.grdListView; + this.grdList.Name = "grdList"; + this.grdList.Size = new System.Drawing.Size(1294, 737); + this.grdList.TabIndex = 0; + this.grdList.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] { + this.grdListView}); + // + // grdListView + // + this.grdListView.Columns.AddRange(new DevExpress.XtraGrid.Columns.GridColumn[] { + this.gridColumn1, + this.gridColumn2, + this.gridColumn3, + this.gridColumn4, + this.gridColumn5, + this.gridColumn6, + this.gridColumn7, + this.gridColumn8, + this.gridColumn9, + this.gridColumn10}); + this.grdListView.GridControl = this.grdList; + this.grdListView.Name = "grdListView"; + this.grdListView.OptionsBehavior.Editable = false; + this.grdListView.OptionsView.ColumnAutoWidth = false; + // + // tabDataDetail + // + this.tabDataDetail.Controls.Add(this.panelControl2); + this.tabDataDetail.Name = "tabDataDetail"; + this.tabDataDetail.Size = new System.Drawing.Size(579, 407); + this.tabDataDetail.Text = "数据编辑"; + // + // panelControl2 + // + this.panelControl2.Controls.Add(this.layoutControl1); + this.panelControl2.Dock = System.Windows.Forms.DockStyle.Fill; + this.panelControl2.Location = new System.Drawing.Point(0, 0); + this.panelControl2.Name = "panelControl2"; + this.panelControl2.Size = new System.Drawing.Size(579, 407); + this.panelControl2.TabIndex = 0; + // // layoutControl1 - // - - this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill; - this.layoutControl1.Location = new System.Drawing.Point(12, 8); - this.layoutControl1.Name = "layoutControl1"; - this.layoutControl1.Root = this.layoutControlGroup1; - layoutControl1.AutoScroll=true; - this.layoutControl1.Size = new System.Drawing.Size(605, 363); - this.layoutControl1.TabIndex = 6; - this.layoutControl1.Text = "layoutControl1"; - + // this.layoutControl1.Controls.Add(this.txtid); this.layoutControl1.Controls.Add(this.txtdictTypeID); this.layoutControl1.Controls.Add(this.txtcode); @@ -160,22 +323,32 @@ namespace MES.Form this.layoutControl1.Controls.Add(this.txtcreateTime); this.layoutControl1.Controls.Add(this.txteditorId); this.layoutControl1.Controls.Add(this.txteditTime); -//TextEdit -//DateEdit -//SimpleButton -//CheckEdit -//MemoEdit -//PictureEdit -//LookUpEdit -//ComboBoxEdit + this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill; + this.layoutControl1.Location = new System.Drawing.Point(2, 2); + this.layoutControl1.Name = "layoutControl1"; + this.layoutControl1.Root = this.layoutControlGroup1; + this.layoutControl1.Size = new System.Drawing.Size(575, 403); + this.layoutControl1.TabIndex = 6; + this.layoutControl1.Text = "layoutControl1"; // - // txt${ColumnInfo.Name.Alias.ToCapit()} + // layoutControlGroup1 // - this.txtid.Location = new System.Drawing.Point(112, 12); - this.txtid.Name = "txtid"; - this.txtid.Size = new System.Drawing.Size(481, 20); - this.txtid.StyleController = this.layoutControl1; - this.txtid.TabIndex = 1; + this.layoutControlGroup1.CustomizationFormText = "layoutControlGroup1"; + this.layoutControlGroup1.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True; + this.layoutControlGroup1.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] { + this.layoutControlItem1, + this.layoutControlItem2, + this.layoutControlItem3, + this.layoutControlItem4, + this.layoutControlItem5, + this.layoutControlItem6, + this.layoutControlItem7, + this.layoutControlItem8, + this.layoutControlItem9, + this.layoutControlItem10}); + this.layoutControlGroup1.Name = "layoutControlGroup1"; + this.layoutControlGroup1.Size = new System.Drawing.Size(575, 403); + this.layoutControlGroup1.TextVisible = false; // // layoutControlItem1 // @@ -183,34 +356,17 @@ namespace MES.Form this.layoutControlItem1.CustomizationFormText = "id"; this.layoutControlItem1.Location = new System.Drawing.Point(0, 0); this.layoutControlItem1.Name = "layoutControlItem1"; - this.layoutControlItem1.Size = new System.Drawing.Size(585, 24); + this.layoutControlItem1.Size = new System.Drawing.Size(555, 24); this.layoutControlItem1.Text = "id"; - this.layoutControlItem1.TextSize = new System.Drawing.Size(96, 14); - + this.layoutControlItem1.TextSize = new System.Drawing.Size(48, 14); // - // treeListLookUpEdit1 + // txtid // - this.txtdictTypeID.EditValue = ""; - this.txtdictTypeID.Location = new System.Drawing.Point(120, 84); - this.txtdictTypeID.Name = "txtdictTypeID"; - this.txtdictTypeID.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { - new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.txtdictTypeID.Properties.DisplayMember = "Name"; - this.txtdictTypeID.Properties.TreeList = this.txtdictTypeIDTreeList; - this.txtdictTypeID.Properties.ValueMember = "ID"; - this.txtdictTypeID.Size = new System.Drawing.Size(932, 20); - this.txtdictTypeID.StyleController = this.layoutControl1; - this.txtdictTypeID.TabIndex = 2; - // - // treeListLookUpEdit1TreeList - // - this.txtdictTypeIDTreeList.Location = new System.Drawing.Point(0, 0); - this.txtdictTypeIDTreeList.Name = "txtdictTypeIDTreeList"; - this.txtdictTypeIDTreeList.OptionsView.ShowIndentAsRowStyle = true; - this.txtdictTypeIDTreeList.ParentFieldName = "PID"; - this.txtdictTypeIDTreeList.Size = new System.Drawing.Size(400, 200); - this.txtdictTypeIDTreeList.TabIndex = 0; - + this.txtid.Location = new System.Drawing.Point(63, 12); + this.txtid.Name = "txtid"; + this.txtid.Size = new System.Drawing.Size(500, 20); + this.txtid.StyleController = this.layoutControl1; + this.txtid.TabIndex = 1; // // layoutControlItem2 // @@ -218,18 +374,32 @@ namespace MES.Form this.layoutControlItem2.CustomizationFormText = "类型"; this.layoutControlItem2.Location = new System.Drawing.Point(0, 24); this.layoutControlItem2.Name = "layoutControlItem2"; - this.layoutControlItem2.Size = new System.Drawing.Size(585, 24); + this.layoutControlItem2.Size = new System.Drawing.Size(555, 24); this.layoutControlItem2.Text = "类型"; - this.layoutControlItem2.TextSize = new System.Drawing.Size(96, 14); - + this.layoutControlItem2.TextSize = new System.Drawing.Size(48, 14); // - // txt${ColumnInfo.Name.Alias.ToCapit()} + // txtdictTypeID // - this.txtcode.Location = new System.Drawing.Point(112, 60); - this.txtcode.Name = "txtcode"; - this.txtcode.Size = new System.Drawing.Size(481, 20); - this.txtcode.StyleController = this.layoutControl1; - this.txtcode.TabIndex = 3; + this.txtdictTypeID.EditValue = ""; + this.txtdictTypeID.Location = new System.Drawing.Point(63, 36); + this.txtdictTypeID.Name = "txtdictTypeID"; + this.txtdictTypeID.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); + this.txtdictTypeID.Properties.DisplayMember = "Name"; + this.txtdictTypeID.Properties.TreeList = this.txtdictTypeIDTreeList; + this.txtdictTypeID.Properties.ValueMember = "ID"; + this.txtdictTypeID.Size = new System.Drawing.Size(500, 20); + this.txtdictTypeID.StyleController = this.layoutControl1; + this.txtdictTypeID.TabIndex = 2; + // + // txtdictTypeIDTreeList + // + this.txtdictTypeIDTreeList.Location = new System.Drawing.Point(0, 0); + this.txtdictTypeIDTreeList.Name = "txtdictTypeIDTreeList"; + this.txtdictTypeIDTreeList.OptionsView.ShowIndentAsRowStyle = true; + this.txtdictTypeIDTreeList.ParentFieldName = "PID"; + this.txtdictTypeIDTreeList.Size = new System.Drawing.Size(400, 200); + this.txtdictTypeIDTreeList.TabIndex = 0; // // layoutControlItem3 // @@ -237,18 +407,17 @@ namespace MES.Form this.layoutControlItem3.CustomizationFormText = "编码"; this.layoutControlItem3.Location = new System.Drawing.Point(0, 48); this.layoutControlItem3.Name = "layoutControlItem3"; - this.layoutControlItem3.Size = new System.Drawing.Size(585, 24); + this.layoutControlItem3.Size = new System.Drawing.Size(555, 24); this.layoutControlItem3.Text = "编码"; - this.layoutControlItem3.TextSize = new System.Drawing.Size(96, 14); - + this.layoutControlItem3.TextSize = new System.Drawing.Size(48, 14); // - // txt${ColumnInfo.Name.Alias.ToCapit()} + // txtcode // - this.txtvalue.Location = new System.Drawing.Point(112, 84); - this.txtvalue.Name = "txtvalue"; - this.txtvalue.Size = new System.Drawing.Size(481, 20); - this.txtvalue.StyleController = this.layoutControl1; - this.txtvalue.TabIndex = 4; + this.txtcode.Location = new System.Drawing.Point(63, 60); + this.txtcode.Name = "txtcode"; + this.txtcode.Size = new System.Drawing.Size(500, 20); + this.txtcode.StyleController = this.layoutControl1; + this.txtcode.TabIndex = 3; // // layoutControlItem4 // @@ -256,18 +425,17 @@ namespace MES.Form this.layoutControlItem4.CustomizationFormText = "值"; this.layoutControlItem4.Location = new System.Drawing.Point(0, 72); this.layoutControlItem4.Name = "layoutControlItem4"; - this.layoutControlItem4.Size = new System.Drawing.Size(585, 24); + this.layoutControlItem4.Size = new System.Drawing.Size(555, 24); this.layoutControlItem4.Text = "值"; - this.layoutControlItem4.TextSize = new System.Drawing.Size(96, 14); - + this.layoutControlItem4.TextSize = new System.Drawing.Size(48, 14); // - // txt${ColumnInfo.Name.Alias.ToCapit()} + // txtvalue // - this.txtremark.Location = new System.Drawing.Point(112, 108); - this.txtremark.Name = "txtremark"; - this.txtremark.Size = new System.Drawing.Size(481, 20); - this.txtremark.StyleController = this.layoutControl1; - this.txtremark.TabIndex = 5; + this.txtvalue.Location = new System.Drawing.Point(63, 84); + this.txtvalue.Name = "txtvalue"; + this.txtvalue.Size = new System.Drawing.Size(500, 20); + this.txtvalue.StyleController = this.layoutControl1; + this.txtvalue.TabIndex = 4; // // layoutControlItem5 // @@ -275,18 +443,17 @@ namespace MES.Form this.layoutControlItem5.CustomizationFormText = "备注"; this.layoutControlItem5.Location = new System.Drawing.Point(0, 96); this.layoutControlItem5.Name = "layoutControlItem5"; - this.layoutControlItem5.Size = new System.Drawing.Size(585, 24); + this.layoutControlItem5.Size = new System.Drawing.Size(555, 24); this.layoutControlItem5.Text = "备注"; - this.layoutControlItem5.TextSize = new System.Drawing.Size(96, 14); - + this.layoutControlItem5.TextSize = new System.Drawing.Size(48, 14); // - // txt${ColumnInfo.Name.Alias.ToCapit()} + // txtremark // - this.txtsort.Location = new System.Drawing.Point(112, 132); - this.txtsort.Name = "txtsort"; - this.txtsort.Size = new System.Drawing.Size(481, 20); - this.txtsort.StyleController = this.layoutControl1; - this.txtsort.TabIndex = 6; + this.txtremark.Location = new System.Drawing.Point(63, 108); + this.txtremark.Name = "txtremark"; + this.txtremark.Size = new System.Drawing.Size(500, 20); + this.txtremark.StyleController = this.layoutControl1; + this.txtremark.TabIndex = 5; // // layoutControlItem6 // @@ -294,26 +461,17 @@ namespace MES.Form this.layoutControlItem6.CustomizationFormText = "排序"; this.layoutControlItem6.Location = new System.Drawing.Point(0, 120); this.layoutControlItem6.Name = "layoutControlItem6"; - this.layoutControlItem6.Size = new System.Drawing.Size(585, 24); + this.layoutControlItem6.Size = new System.Drawing.Size(555, 24); this.layoutControlItem6.Text = "排序"; - this.layoutControlItem6.TextSize = new System.Drawing.Size(96, 14); - + this.layoutControlItem6.TextSize = new System.Drawing.Size(48, 14); // - // lookUpEdit1 + // txtsort // - this.txtcreatorId.Location = new System.Drawing.Point(120, 60); - this.txtcreatorId.Name = "txtcreatorId"; - this.txtcreatorId.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { - new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.txtcreatorId.Properties.DisplayMember = "Name"; - this.txtcreatorId.Properties.PopupFilterMode = DevExpress.XtraEditors.PopupFilterMode.Contains; - this.txtcreatorId.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.Standard; - this.txtcreatorId.Properties.ValueMember = "ID"; - this.txtcreatorId.Size = new System.Drawing.Size(932, 20); - this.txtcreatorId.StyleController = this.layoutControl1; - this.txtcreatorId.TabIndex = 7; - this.txtcreatorId.EditValue = ""; - + this.txtsort.Location = new System.Drawing.Point(63, 132); + this.txtsort.Name = "txtsort"; + this.txtsort.Size = new System.Drawing.Size(500, 20); + this.txtsort.StyleController = this.layoutControl1; + this.txtsort.TabIndex = 6; // // layoutControlItem7 // @@ -321,26 +479,24 @@ namespace MES.Form this.layoutControlItem7.CustomizationFormText = "创建人"; this.layoutControlItem7.Location = new System.Drawing.Point(0, 144); this.layoutControlItem7.Name = "layoutControlItem7"; - this.layoutControlItem7.Size = new System.Drawing.Size(585, 24); + this.layoutControlItem7.Size = new System.Drawing.Size(555, 24); this.layoutControlItem7.Text = "创建人"; - this.layoutControlItem7.TextSize = new System.Drawing.Size(96, 14); - + this.layoutControlItem7.TextSize = new System.Drawing.Size(48, 14); // - // txt${ColumnInfo.Name.Alias.ToCapit()} + // txtcreatorId // - this.txtcreateTime.EditValue = null; - this.txtcreateTime.ImeMode = System.Windows.Forms.ImeMode.Off; - this.txtcreateTime.Location = new System.Drawing.Point(112, 180); - this.txtcreateTime.Name = "txtcreateTime"; - this.txtcreateTime.Properties.DisplayFormat.FormatString = "G"; - this.txtcreateTime.Properties.DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; - this.txtcreateTime.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + this.txtcreatorId.EditValue = ""; + this.txtcreatorId.Location = new System.Drawing.Point(63, 156); + this.txtcreatorId.Name = "txtcreatorId"; + this.txtcreatorId.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.txtcreateTime.Properties.VistaTimeProperties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { - new DevExpress.XtraEditors.Controls.EditorButton()}); - this.txtcreateTime.Size = new System.Drawing.Size(481, 20); - this.txtcreateTime.StyleController = this.layoutControl1; - this.txtcreateTime.TabIndex = 8; + this.txtcreatorId.Properties.DisplayMember = "Name"; + this.txtcreatorId.Properties.PopupFilterMode = DevExpress.XtraEditors.PopupFilterMode.Contains; + this.txtcreatorId.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.Standard; + this.txtcreatorId.Properties.ValueMember = "ID"; + this.txtcreatorId.Size = new System.Drawing.Size(500, 20); + this.txtcreatorId.StyleController = this.layoutControl1; + this.txtcreatorId.TabIndex = 7; // // layoutControlItem8 // @@ -348,26 +504,25 @@ namespace MES.Form this.layoutControlItem8.CustomizationFormText = "创建时间"; this.layoutControlItem8.Location = new System.Drawing.Point(0, 168); this.layoutControlItem8.Name = "layoutControlItem8"; - this.layoutControlItem8.Size = new System.Drawing.Size(585, 24); + this.layoutControlItem8.Size = new System.Drawing.Size(555, 24); this.layoutControlItem8.Text = "创建时间"; - this.layoutControlItem8.TextSize = new System.Drawing.Size(96, 14); - + this.layoutControlItem8.TextSize = new System.Drawing.Size(48, 14); // - // lookUpEdit1 + // txtcreateTime // - this.txteditorId.Location = new System.Drawing.Point(120, 60); - this.txteditorId.Name = "txteditorId"; - this.txteditorId.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + this.txtcreateTime.EditValue = null; + this.txtcreateTime.ImeMode = System.Windows.Forms.ImeMode.Off; + this.txtcreateTime.Location = new System.Drawing.Point(63, 180); + this.txtcreateTime.Name = "txtcreateTime"; + this.txtcreateTime.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.txteditorId.Properties.DisplayMember = "Name"; - this.txteditorId.Properties.PopupFilterMode = DevExpress.XtraEditors.PopupFilterMode.Contains; - this.txteditorId.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.Standard; - this.txteditorId.Properties.ValueMember = "ID"; - this.txteditorId.Size = new System.Drawing.Size(932, 20); - this.txteditorId.StyleController = this.layoutControl1; - this.txteditorId.TabIndex = 9; - this.txteditorId.EditValue = ""; - + this.txtcreateTime.Properties.CalendarTimeProperties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + new DevExpress.XtraEditors.Controls.EditorButton()}); + this.txtcreateTime.Properties.DisplayFormat.FormatString = "G"; + this.txtcreateTime.Properties.DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; + this.txtcreateTime.Size = new System.Drawing.Size(500, 20); + this.txtcreateTime.StyleController = this.layoutControl1; + this.txtcreateTime.TabIndex = 8; // // layoutControlItem9 // @@ -375,26 +530,24 @@ namespace MES.Form this.layoutControlItem9.CustomizationFormText = "编辑人"; this.layoutControlItem9.Location = new System.Drawing.Point(0, 192); this.layoutControlItem9.Name = "layoutControlItem9"; - this.layoutControlItem9.Size = new System.Drawing.Size(585, 24); + this.layoutControlItem9.Size = new System.Drawing.Size(555, 24); this.layoutControlItem9.Text = "编辑人"; - this.layoutControlItem9.TextSize = new System.Drawing.Size(96, 14); - + this.layoutControlItem9.TextSize = new System.Drawing.Size(48, 14); // - // txt${ColumnInfo.Name.Alias.ToCapit()} + // txteditorId // - this.txteditTime.EditValue = null; - this.txteditTime.ImeMode = System.Windows.Forms.ImeMode.Off; - this.txteditTime.Location = new System.Drawing.Point(112, 228); - this.txteditTime.Name = "txteditTime"; - this.txteditTime.Properties.DisplayFormat.FormatString = "G"; - this.txteditTime.Properties.DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; - this.txteditTime.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + this.txteditorId.EditValue = ""; + this.txteditorId.Location = new System.Drawing.Point(63, 204); + this.txteditorId.Name = "txteditorId"; + this.txteditorId.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.txteditTime.Properties.VistaTimeProperties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { - new DevExpress.XtraEditors.Controls.EditorButton()}); - this.txteditTime.Size = new System.Drawing.Size(481, 20); - this.txteditTime.StyleController = this.layoutControl1; - this.txteditTime.TabIndex = 10; + this.txteditorId.Properties.DisplayMember = "Name"; + this.txteditorId.Properties.PopupFilterMode = DevExpress.XtraEditors.PopupFilterMode.Contains; + this.txteditorId.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.Standard; + this.txteditorId.Properties.ValueMember = "ID"; + this.txteditorId.Size = new System.Drawing.Size(500, 20); + this.txteditorId.StyleController = this.layoutControl1; + this.txteditorId.TabIndex = 9; // // layoutControlItem10 // @@ -402,258 +555,74 @@ namespace MES.Form this.layoutControlItem10.CustomizationFormText = "editTime"; this.layoutControlItem10.Location = new System.Drawing.Point(0, 216); this.layoutControlItem10.Name = "layoutControlItem10"; - this.layoutControlItem10.Size = new System.Drawing.Size(585, 24); + this.layoutControlItem10.Size = new System.Drawing.Size(555, 167); this.layoutControlItem10.Text = "editTime"; - this.layoutControlItem10.TextSize = new System.Drawing.Size(96, 14); - - + this.layoutControlItem10.TextSize = new System.Drawing.Size(48, 14); // - // layoutControlGroup1 + // txteditTime // - this.layoutControlGroup1.CustomizationFormText = "layoutControlGroup1"; - this.layoutControlGroup1.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True; - this.layoutControlGroup1.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] { - this.layoutControlItem1 - ,this.layoutControlItem2 - ,this.layoutControlItem3 - ,this.layoutControlItem4 - ,this.layoutControlItem5 - ,this.layoutControlItem6 - ,this.layoutControlItem7 - ,this.layoutControlItem8 - ,this.layoutControlItem9 - ,this.layoutControlItem10 - }); - this.layoutControlGroup1.Location = new System.Drawing.Point(0, 0); - this.layoutControlGroup1.Name = "layoutControlGroup1"; - this.layoutControlGroup1.Size = new System.Drawing.Size(605, 363); - this.layoutControlGroup1.Text = "layoutControlGroup1"; - this.layoutControlGroup1.TextVisible = false; - - - // - // xtraTabControl1 - // - this.xtraTabControl1.Dock = System.Windows.Forms.DockStyle.Fill; - this.xtraTabControl1.Location = new System.Drawing.Point(0, 34); - this.xtraTabControl1.Name = "xtraTabControl1"; - this.xtraTabControl1.SelectedTabPage = this.tabDataList; - this.xtraTabControl1.Size = new System.Drawing.Size(585, 436); - this.xtraTabControl1.TabIndex = 1; - this.xtraTabControl1.TabPages.AddRange(new DevExpress.XtraTab.XtraTabPage[] { - this.tabDataList, - this.tabDataDetail}); - // - // tabDataList - // - this.tabDataList.Controls.Add(this.grdList); - this.tabDataList.Name = "tabDataList"; - this.tabDataList.Size = new System.Drawing.Size(579, 407); - this.tabDataList.Text = "数据列表"; - // - // tabDataDetail - // - this.tabDataDetail.Controls.Add(this.panelControl2); - this.tabDataDetail.Name = "tabDataDetail"; - this.tabDataDetail.Size = new System.Drawing.Size(579, 407); - this.tabDataDetail.Text = "数据编辑"; - // - // grdList - // - this.grdList.Dock = System.Windows.Forms.DockStyle.Fill; - this.grdList.Location = new System.Drawing.Point(0, 0); - this.grdList.MainView = this.grdListView; - this.grdList.Name = "grdList"; - this.grdList.Size = new System.Drawing.Size(579, 407); - this.grdList.TabIndex = 0; - this.grdList.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] { - this.grdListView}); - // - // grdListView - // - this.grdListView.Columns.AddRange(new DevExpress.XtraGrid.Columns.GridColumn[] { - this.gridColumn1, - this.gridColumn2, - this.gridColumn3, - this.gridColumn4, - this.gridColumn5, - this.gridColumn6, - this.gridColumn7, - this.gridColumn8, - this.gridColumn9, - this.gridColumn10, - }); - this.grdListView.OptionsBehavior.Editable = false; - this.grdListView.GridControl = this.grdList; - this.grdListView.Name = "grdListView"; - this.grdListView.OptionsView.ColumnAutoWidth=false; - this.grdListView.BestFitColumns(); - // - // panelControl2 - // - this.panelControl2.Controls.Add(this.layoutControl1); - this.panelControl2.Dock = System.Windows.Forms.DockStyle.Fill; - this.panelControl2.Location = new System.Drawing.Point(0, 0); - this.panelControl2.Name = "panelControl2"; - this.panelControl2.Size = new System.Drawing.Size(579, 407); - this.panelControl2.TabIndex = 0; - - //////////////////////////////// - (this.gridColumn1).Caption = "id"; - (this.gridColumn1).Name = "gridColumn1"; - (this.gridColumn1).FieldName = "id"; - // repositoryItemTreeListLookUpEdit1 - // - (this.gridColumn2).ColumnEdit = this.repositoryItemTreeListtxtdictTypeID; - this.repositoryItemTreeListtxtdictTypeID.AutoHeight = false; - this.repositoryItemTreeListtxtdictTypeID.DisplayMember = "Name"; - this.repositoryItemTreeListtxtdictTypeID.ValueMember = "ID"; - this.repositoryItemTreeListtxtdictTypeID.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + this.txteditTime.EditValue = null; + this.txteditTime.ImeMode = System.Windows.Forms.ImeMode.Off; + this.txteditTime.Location = new System.Drawing.Point(63, 228); + this.txteditTime.Name = "txteditTime"; + this.txteditTime.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.repositoryItemTreeListtxtdictTypeID.Name = "repositoryItemTreeListtxtdictTypeID"; - this.repositoryItemTreeListtxtdictTypeID.TreeList = this.repositoryItemTreeListtxtdictTypeIDTreeList; + this.txteditTime.Properties.CalendarTimeProperties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + new DevExpress.XtraEditors.Controls.EditorButton()}); + this.txteditTime.Properties.DisplayFormat.FormatString = "G"; + this.txteditTime.Properties.DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; + this.txteditTime.Size = new System.Drawing.Size(500, 20); + this.txteditTime.StyleController = this.layoutControl1; + this.txteditTime.TabIndex = 10; // - // repositoryItemTreeListLookUpEdit1TreeList - // - this.repositoryItemTreeListtxtdictTypeIDTreeList.Location = new System.Drawing.Point(0, 0); - this.repositoryItemTreeListtxtdictTypeIDTreeList.ParentFieldName = "PID"; - this.repositoryItemTreeListtxtdictTypeIDTreeList.Name = "repositoryItemTreeListtxtdictTypeIDTreeList"; - this.repositoryItemTreeListtxtdictTypeIDTreeList.OptionsView.ShowIndentAsRowStyle = true; - this.repositoryItemTreeListtxtdictTypeIDTreeList.Size = new System.Drawing.Size(400, 200); - this.repositoryItemTreeListtxtdictTypeIDTreeList.TabIndex = 0; - (this.gridColumn2).Caption = "类型"; - (this.gridColumn2).Name = "gridColumn2"; - (this.gridColumn2).FieldName = "dictTypeID"; - (this.gridColumn2).Visible = true; - (this.gridColumn2).VisibleIndex = 2; - - //////////////////////////////// - (this.gridColumn3).Caption = "编码"; - (this.gridColumn3).Name = "gridColumn3"; - (this.gridColumn3).FieldName = "code"; - (this.gridColumn3).Visible = true; - (this.gridColumn3).VisibleIndex = 3; - - //////////////////////////////// - (this.gridColumn4).Caption = "值"; - (this.gridColumn4).Name = "gridColumn4"; - (this.gridColumn4).FieldName = "value"; - (this.gridColumn4).Visible = true; - (this.gridColumn4).VisibleIndex = 4; - - //////////////////////////////// - (this.gridColumn5).Caption = "备注"; - (this.gridColumn5).Name = "gridColumn5"; - (this.gridColumn5).FieldName = "remark"; - (this.gridColumn5).Visible = true; - (this.gridColumn5).VisibleIndex = 5; - - //////////////////////////////// - (this.gridColumn6).Caption = "排序"; - (this.gridColumn6).Name = "gridColumn6"; - (this.gridColumn6).FieldName = "sort"; - (this.gridColumn6).Visible = true; - (this.gridColumn6).VisibleIndex = 6; - - (this.gridColumn7).ColumnEdit = this.repositoryItemtxtcreatorId; - this.repositoryItemtxtcreatorId.AutoHeight = false; - this.repositoryItemtxtcreatorId.DisplayMember = "Name"; - this.repositoryItemtxtcreatorId.ValueMember = "ID"; - this.repositoryItemtxtcreatorId.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { - new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.repositoryItemtxtcreatorId.Name = "repositoryItemtxtcreatorId"; - (this.gridColumn7).Caption = "创建人"; - (this.gridColumn7).Name = "gridColumn7"; - (this.gridColumn7).FieldName = "creatorId"; - (this.gridColumn7).Visible = true; - (this.gridColumn7).VisibleIndex = 7; - - (this.gridColumn8).DisplayFormat.FormatString = "G"; - (this.gridColumn8).DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; - (this.gridColumn8).Caption = "创建时间"; - (this.gridColumn8).Name = "gridColumn8"; - (this.gridColumn8).FieldName = "createTime"; - (this.gridColumn8).Visible = true; - (this.gridColumn8).VisibleIndex = 8; - - (this.gridColumn9).ColumnEdit = this.repositoryItemtxteditorId; - this.repositoryItemtxteditorId.AutoHeight = false; - this.repositoryItemtxteditorId.DisplayMember = "Name"; - this.repositoryItemtxteditorId.ValueMember = "ID"; - this.repositoryItemtxteditorId.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { - new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.repositoryItemtxteditorId.Name = "repositoryItemtxteditorId"; - (this.gridColumn9).Caption = "编辑人"; - (this.gridColumn9).Name = "gridColumn9"; - (this.gridColumn9).FieldName = "editorId"; - (this.gridColumn9).Visible = true; - (this.gridColumn9).VisibleIndex = 9; - - (this.gridColumn10).DisplayFormat.FormatString = "G"; - (this.gridColumn10).DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; - (this.gridColumn10).Caption = "editTime"; - (this.gridColumn10).Name = "gridColumn10"; - (this.gridColumn10).FieldName = "editTime"; - (this.gridColumn10).Visible = true; - (this.gridColumn10).VisibleIndex = 10; - - - // - // XtraForm1 + // FrmsysDictData // this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.ClientSize = new System.Drawing.Size(1300, 800); this.Controls.Add(this.xtraTabControl1); this.Name = "FrmsysDictData"; - this.Text = "FrmsysDictData"; + this.Text = "参数维护"; this.Load += new System.EventHandler(this.FrmsysDictData_Load); this.Controls.SetChildIndex(this.xtraTabControl1, 0); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtid.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtdictTypeIDTreeList)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemTreeListtxtdictTypeID)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemTreeListtxtdictTypeIDTreeList)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtdictTypeID.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).EndInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtcode.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).EndInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtvalue.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).EndInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtremark.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).EndInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtsort.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemtxtcreatorId)).EndInit(); - - ((System.ComponentModel.ISupportInitialize)(this.txtcreatorId.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties.CalendarTimeProperties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemtxteditorId)).EndInit(); - - ((System.ComponentModel.ISupportInitialize)(this.txteditorId.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties.CalendarTimeProperties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem10)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.xtraTabControl1)).EndInit(); this.xtraTabControl1.ResumeLayout(false); this.tabDataList.ResumeLayout(false); - this.tabDataDetail.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.grdList)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.grdListView)).EndInit(); + this.tabDataDetail.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.panelControl2)).EndInit(); + this.panelControl2.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).EndInit(); this.layoutControl1.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).EndInit(); - + ((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtid.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtdictTypeID.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtdictTypeIDTreeList)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtcode.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtvalue.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtremark.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtsort.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtcreatorId.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties.CalendarTimeProperties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txteditorId.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem10)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties.CalendarTimeProperties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties)).EndInit(); this.ResumeLayout(false); } diff --git a/WinformGeneralDeveloperFrame/Form/FrmsysDictData.resx b/WinformGeneralDeveloperFrame/Form/FrmsysDictData.resx new file mode 100644 index 0000000..1af7de1 --- /dev/null +++ b/WinformGeneralDeveloperFrame/Form/FrmsysDictData.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/WinformGeneralDeveloperFrame/Form/FrmsysDictType.cs b/WinformGeneralDeveloperFrame/Form/FrmsysDictType.cs index 05d7b3a..83645a8 100644 --- a/WinformGeneralDeveloperFrame/Form/FrmsysDictType.cs +++ b/WinformGeneralDeveloperFrame/Form/FrmsysDictType.cs @@ -22,21 +22,16 @@ namespace MES.Form } private void FrmsysDictType_Load(object sender, EventArgs e) { - - InitFrom(xtraTabControl1,grdList,grdListView,new LayoutControlGroup[]{layoutControlGroup1},new sysDictTypeInfo()); + InitFrom(xtraTabControl1,grdList,grdListView,new LayoutControlGroup[]{layoutControlGroup1},new sysDictTypeInfo()); } private void Init() { - - - - - txtpid.Properties.DataSource = GetDataTableUtils.SqlTable("字典类型"); - repositoryItemTreeListtxtpid.DataSource= GetDataTableUtils.SqlTable("字典类型"); - txtcreatorId.Properties.DataSource = GetDataTableUtils.SqlTable("用户"); - repositoryItemtxtcreatorId.DataSource= GetDataTableUtils.SqlTable("用户"); - txteditorId.Properties.DataSource = GetDataTableUtils.SqlTable("用户"); - repositoryItemtxteditorId.DataSource= GetDataTableUtils.SqlTable("用户"); + txtpid.Properties.DataSource = GetDataTableUtils.SqlTable("字典类型"); + repositoryItemTreeListtxtpid.DataSource= GetDataTableUtils.SqlTable("字典类型"); + txtcreatorId.Properties.DataSource = GetDataTableUtils.SqlTable("用户"); + repositoryItemtxtcreatorId.DataSource= GetDataTableUtils.SqlTable("用户"); + txteditorId.Properties.DataSource = GetDataTableUtils.SqlTable("用户"); + repositoryItemtxteditorId.DataSource= GetDataTableUtils.SqlTable("用户"); } public override bool SaveFunction() @@ -64,9 +59,9 @@ namespace MES.Form grdList.DataSource=con.sysDictTypeInfo.ToList(); } Init(); - } - - public override bool CheckInput() + } + + public override bool CheckInput() { if(string.IsNullOrEmpty(txtname.EditValue.ToString())) { diff --git a/WinformGeneralDeveloperFrame/Form/FrmsysDictType.designer.cs b/WinformGeneralDeveloperFrame/Form/FrmsysDictType.designer.cs index 7468b96..4f15088 100644 --- a/WinformGeneralDeveloperFrame/Form/FrmsysDictType.designer.cs +++ b/WinformGeneralDeveloperFrame/Form/FrmsysDictType.designer.cs @@ -33,376 +33,205 @@ namespace MES.Form /// private void InitializeComponent() { - this.gridColumn1 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn2 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn3 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn4 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn5 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn6 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn7 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn8 = new DevExpress.XtraGrid.Columns.GridColumn(); - this.gridColumn9 = new DevExpress.XtraGrid.Columns.GridColumn(); - + this.gridColumn1 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.gridColumn2 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.repositoryItemTreeListtxtpid = new DevExpress.XtraEditors.Repository.RepositoryItemTreeListLookUpEdit(); + this.repositoryItemTreeListtxtpidTreeList = new DevExpress.XtraTreeList.TreeList(); + this.gridColumn3 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.gridColumn4 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.gridColumn5 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.repositoryItemtxtcreatorId = new DevExpress.XtraEditors.Repository.RepositoryItemLookUpEdit(); + this.gridColumn6 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.gridColumn7 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.repositoryItemtxteditorId = new DevExpress.XtraEditors.Repository.RepositoryItemLookUpEdit(); + this.gridColumn8 = new DevExpress.XtraGrid.Columns.GridColumn(); + this.gridColumn9 = new DevExpress.XtraGrid.Columns.GridColumn(); this.xtraTabControl1 = new DevExpress.XtraTab.XtraTabControl(); this.tabDataList = new DevExpress.XtraTab.XtraTabPage(); - this.tabDataDetail = new DevExpress.XtraTab.XtraTabPage(); this.grdList = new DevExpress.XtraGrid.GridControl(); this.grdListView = new DevExpress.XtraGrid.Views.Grid.GridView(); + this.tabDataDetail = new DevExpress.XtraTab.XtraTabPage(); this.panelControl2 = new DevExpress.XtraEditors.PanelControl(); this.layoutControl1 = new DevExpress.XtraLayout.LayoutControl(); - this.layoutControlGroup1 = new DevExpress.XtraLayout.LayoutControlGroup(); - - - ////////////////////// - this.txtid=new DevExpress.XtraEditors.TextEdit(); - this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem(); - this.txtpidTreeList = new DevExpress.XtraTreeList.TreeList(); - this.repositoryItemTreeListtxtpid = new DevExpress.XtraEditors.Repository.RepositoryItemTreeListLookUpEdit(); - this.repositoryItemTreeListtxtpidTreeList = new DevExpress.XtraTreeList.TreeList(); - this.txtpid=new DevExpress.XtraEditors.TreeListLookUpEdit(); - this.layoutControlItem2 = new DevExpress.XtraLayout.LayoutControlItem(); - ////////////////////// - this.txtname=new DevExpress.XtraEditors.TextEdit(); - this.layoutControlItem3 = new DevExpress.XtraLayout.LayoutControlItem(); - ////////////////////// - this.txtsort=new DevExpress.XtraEditors.TextEdit(); - this.layoutControlItem4 = new DevExpress.XtraLayout.LayoutControlItem(); - this.repositoryItemtxtcreatorId = new DevExpress.XtraEditors.Repository.RepositoryItemLookUpEdit(); - - this.txtcreatorId=new DevExpress.XtraEditors.LookUpEdit(); - this.layoutControlItem5 = new DevExpress.XtraLayout.LayoutControlItem(); - ////////////////////// - this.txtcreateTime=new DevExpress.XtraEditors.DateEdit(); - this.layoutControlItem6 = new DevExpress.XtraLayout.LayoutControlItem(); - this.repositoryItemtxteditorId = new DevExpress.XtraEditors.Repository.RepositoryItemLookUpEdit(); - - this.txteditorId=new DevExpress.XtraEditors.LookUpEdit(); - this.layoutControlItem7 = new DevExpress.XtraLayout.LayoutControlItem(); - ////////////////////// - this.txteditTime=new DevExpress.XtraEditors.DateEdit(); - this.layoutControlItem8 = new DevExpress.XtraLayout.LayoutControlItem(); - ////////////////////// - this.txtremark=new DevExpress.XtraEditors.TextEdit(); - this.layoutControlItem9 = new DevExpress.XtraLayout.LayoutControlItem(); - - - ((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit(); - - this.layoutControl1.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).BeginInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtid.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtpidTreeList)).BeginInit(); + this.layoutControlGroup1 = new DevExpress.XtraLayout.LayoutControlGroup(); + this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txtid = new DevExpress.XtraEditors.TextEdit(); + this.layoutControlItem2 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txtpid = new DevExpress.XtraEditors.TreeListLookUpEdit(); + this.txtpidTreeList = new DevExpress.XtraTreeList.TreeList(); + this.layoutControlItem3 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txtname = new DevExpress.XtraEditors.TextEdit(); + this.layoutControlItem4 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txtsort = new DevExpress.XtraEditors.TextEdit(); + this.layoutControlItem5 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txtcreatorId = new DevExpress.XtraEditors.LookUpEdit(); + this.layoutControlItem6 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txtcreateTime = new DevExpress.XtraEditors.DateEdit(); + this.layoutControlItem7 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txteditorId = new DevExpress.XtraEditors.LookUpEdit(); + this.layoutControlItem8 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txteditTime = new DevExpress.XtraEditors.DateEdit(); + this.layoutControlItem9 = new DevExpress.XtraLayout.LayoutControlItem(); + this.txtremark = new DevExpress.XtraEditors.TextEdit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemTreeListtxtpid)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemTreeListtxtpidTreeList)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtpid.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).BeginInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtname.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).BeginInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtsort.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemtxtcreatorId)).BeginInit(); - - ((System.ComponentModel.ISupportInitialize)(this.txtcreatorId.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties.CalendarTimeProperties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemtxteditorId)).BeginInit(); - - ((System.ComponentModel.ISupportInitialize)(this.txteditorId.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties.CalendarTimeProperties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).BeginInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtremark.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.xtraTabControl1)).BeginInit(); this.xtraTabControl1.SuspendLayout(); this.tabDataList.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.grdList)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.grdListView)).BeginInit(); this.tabDataDetail.SuspendLayout(); - + ((System.ComponentModel.ISupportInitialize)(this.panelControl2)).BeginInit(); + this.panelControl2.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit(); + this.layoutControl1.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtid.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtpid.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtpidTreeList)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtname.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtsort.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtcreatorId.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties.CalendarTimeProperties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txteditorId.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties.CalendarTimeProperties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtremark.Properties)).BeginInit(); this.SuspendLayout(); - - // layoutControl1 - // - - this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill; - this.layoutControl1.Location = new System.Drawing.Point(12, 8); - this.layoutControl1.Name = "layoutControl1"; - this.layoutControl1.Root = this.layoutControlGroup1; - layoutControl1.AutoScroll=true; - this.layoutControl1.Size = new System.Drawing.Size(605, 363); - this.layoutControl1.TabIndex = 6; - this.layoutControl1.Text = "layoutControl1"; - - this.layoutControl1.Controls.Add(this.txtid); - this.layoutControl1.Controls.Add(this.txtpid); - this.layoutControl1.Controls.Add(this.txtname); - this.layoutControl1.Controls.Add(this.txtsort); - this.layoutControl1.Controls.Add(this.txtcreatorId); - this.layoutControl1.Controls.Add(this.txtcreateTime); - this.layoutControl1.Controls.Add(this.txteditorId); - this.layoutControl1.Controls.Add(this.txteditTime); - this.layoutControl1.Controls.Add(this.txtremark); -//TextEdit -//DateEdit -//SimpleButton -//CheckEdit -//MemoEdit -//PictureEdit -//LookUpEdit -//ComboBoxEdit // - // txt${ColumnInfo.Name.Alias.ToCapit()} + // gridColumn1 // - this.txtid.Location = new System.Drawing.Point(112, 12); - this.txtid.Name = "txtid"; - this.txtid.Size = new System.Drawing.Size(481, 20); - this.txtid.StyleController = this.layoutControl1; - this.txtid.TabIndex = 1; + this.gridColumn1.Caption = "id"; + this.gridColumn1.FieldName = "id"; + this.gridColumn1.Name = "gridColumn1"; // - // layoutControlItem1 + // gridColumn2 // - this.layoutControlItem1.Control = this.txtid; - this.layoutControlItem1.CustomizationFormText = "id"; - this.layoutControlItem1.Location = new System.Drawing.Point(0, 0); - this.layoutControlItem1.Name = "layoutControlItem1"; - this.layoutControlItem1.Size = new System.Drawing.Size(585, 24); - this.layoutControlItem1.Text = "id"; - this.layoutControlItem1.TextSize = new System.Drawing.Size(96, 14); - + this.gridColumn2.Caption = "父类型"; + this.gridColumn2.ColumnEdit = this.repositoryItemTreeListtxtpid; + this.gridColumn2.FieldName = "pid"; + this.gridColumn2.Name = "gridColumn2"; + this.gridColumn2.Visible = true; + this.gridColumn2.VisibleIndex = 0; + this.gridColumn2.Width = 201; // - // treeListLookUpEdit1 + // repositoryItemTreeListtxtpid // - this.txtpid.EditValue = ""; - this.txtpid.Location = new System.Drawing.Point(120, 84); - this.txtpid.Name = "txtpid"; - this.txtpid.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + this.repositoryItemTreeListtxtpid.AutoHeight = false; + this.repositoryItemTreeListtxtpid.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.txtpid.Properties.DisplayMember = "Name"; - this.txtpid.Properties.TreeList = this.txtpidTreeList; - this.txtpid.Properties.ValueMember = "ID"; - this.txtpid.Size = new System.Drawing.Size(932, 20); - this.txtpid.StyleController = this.layoutControl1; - this.txtpid.TabIndex = 2; - // - // treeListLookUpEdit1TreeList + this.repositoryItemTreeListtxtpid.DisplayMember = "Name"; + this.repositoryItemTreeListtxtpid.Name = "repositoryItemTreeListtxtpid"; + this.repositoryItemTreeListtxtpid.TreeList = this.repositoryItemTreeListtxtpidTreeList; + this.repositoryItemTreeListtxtpid.ValueMember = "ID"; // - this.txtpidTreeList.Location = new System.Drawing.Point(0, 0); - this.txtpidTreeList.Name = "txtpidTreeList"; - this.txtpidTreeList.OptionsView.ShowIndentAsRowStyle = true; - this.txtpidTreeList.ParentFieldName = "PID"; - this.txtpidTreeList.Size = new System.Drawing.Size(400, 200); - this.txtpidTreeList.TabIndex = 0; - + // repositoryItemTreeListtxtpidTreeList // - // layoutControlItem2 + this.repositoryItemTreeListtxtpidTreeList.Location = new System.Drawing.Point(0, 0); + this.repositoryItemTreeListtxtpidTreeList.Name = "repositoryItemTreeListtxtpidTreeList"; + this.repositoryItemTreeListtxtpidTreeList.OptionsView.ShowIndentAsRowStyle = true; + this.repositoryItemTreeListtxtpidTreeList.ParentFieldName = "PID"; + this.repositoryItemTreeListtxtpidTreeList.Size = new System.Drawing.Size(400, 200); + this.repositoryItemTreeListtxtpidTreeList.TabIndex = 0; // - this.layoutControlItem2.Control = this.txtpid; - this.layoutControlItem2.CustomizationFormText = "父类型"; - this.layoutControlItem2.Location = new System.Drawing.Point(0, 24); - this.layoutControlItem2.Name = "layoutControlItem2"; - this.layoutControlItem2.Size = new System.Drawing.Size(585, 24); - this.layoutControlItem2.Text = "父类型"; - this.layoutControlItem2.TextSize = new System.Drawing.Size(96, 14); - + // gridColumn3 // - // txt${ColumnInfo.Name.Alias.ToCapit()} + this.gridColumn3.Caption = "名称"; + this.gridColumn3.FieldName = "name"; + this.gridColumn3.Name = "gridColumn3"; + this.gridColumn3.Visible = true; + this.gridColumn3.VisibleIndex = 1; + this.gridColumn3.Width = 201; // - this.txtname.Location = new System.Drawing.Point(112, 60); - this.txtname.Name = "txtname"; - this.txtname.Size = new System.Drawing.Size(481, 20); - this.txtname.StyleController = this.layoutControl1; - this.txtname.TabIndex = 3; + // gridColumn4 // - // layoutControlItem3 + this.gridColumn4.Caption = "排序"; + this.gridColumn4.FieldName = "sort"; + this.gridColumn4.Name = "gridColumn4"; + this.gridColumn4.Visible = true; + this.gridColumn4.VisibleIndex = 2; + this.gridColumn4.Width = 201; // - this.layoutControlItem3.Control = this.txtname; - this.layoutControlItem3.CustomizationFormText = "名称"; - this.layoutControlItem3.Location = new System.Drawing.Point(0, 48); - this.layoutControlItem3.Name = "layoutControlItem3"; - this.layoutControlItem3.Size = new System.Drawing.Size(585, 24); - this.layoutControlItem3.Text = "名称"; - this.layoutControlItem3.TextSize = new System.Drawing.Size(96, 14); - + // gridColumn5 // - // txt${ColumnInfo.Name.Alias.ToCapit()} + this.gridColumn5.Caption = "创建人"; + this.gridColumn5.ColumnEdit = this.repositoryItemtxtcreatorId; + this.gridColumn5.FieldName = "creatorId"; + this.gridColumn5.Name = "gridColumn5"; + this.gridColumn5.Visible = true; + this.gridColumn5.VisibleIndex = 3; + this.gridColumn5.Width = 201; // - this.txtsort.Location = new System.Drawing.Point(112, 84); - this.txtsort.Name = "txtsort"; - this.txtsort.Size = new System.Drawing.Size(481, 20); - this.txtsort.StyleController = this.layoutControl1; - this.txtsort.TabIndex = 4; + // repositoryItemtxtcreatorId // - // layoutControlItem4 - // - this.layoutControlItem4.Control = this.txtsort; - this.layoutControlItem4.CustomizationFormText = "排序"; - this.layoutControlItem4.Location = new System.Drawing.Point(0, 72); - this.layoutControlItem4.Name = "layoutControlItem4"; - this.layoutControlItem4.Size = new System.Drawing.Size(585, 24); - this.layoutControlItem4.Text = "排序"; - this.layoutControlItem4.TextSize = new System.Drawing.Size(96, 14); - - // - // lookUpEdit1 - // - this.txtcreatorId.Location = new System.Drawing.Point(120, 60); - this.txtcreatorId.Name = "txtcreatorId"; - this.txtcreatorId.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + this.repositoryItemtxtcreatorId.AutoHeight = false; + this.repositoryItemtxtcreatorId.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.txtcreatorId.Properties.DisplayMember = "Name"; - this.txtcreatorId.Properties.PopupFilterMode = DevExpress.XtraEditors.PopupFilterMode.Contains; - this.txtcreatorId.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.Standard; - this.txtcreatorId.Properties.ValueMember = "ID"; - this.txtcreatorId.Size = new System.Drawing.Size(932, 20); - this.txtcreatorId.StyleController = this.layoutControl1; - this.txtcreatorId.TabIndex = 5; - this.txtcreatorId.EditValue = ""; - + this.repositoryItemtxtcreatorId.DisplayMember = "Name"; + this.repositoryItemtxtcreatorId.Name = "repositoryItemtxtcreatorId"; + this.repositoryItemtxtcreatorId.ValueMember = "ID"; // - // layoutControlItem5 + // gridColumn6 // - this.layoutControlItem5.Control = this.txtcreatorId; - this.layoutControlItem5.CustomizationFormText = "创建人"; - this.layoutControlItem5.Location = new System.Drawing.Point(0, 96); - this.layoutControlItem5.Name = "layoutControlItem5"; - this.layoutControlItem5.Size = new System.Drawing.Size(585, 24); - this.layoutControlItem5.Text = "创建人"; - this.layoutControlItem5.TextSize = new System.Drawing.Size(96, 14); - + this.gridColumn6.Caption = "创建时间"; + this.gridColumn6.DisplayFormat.FormatString = "G"; + this.gridColumn6.DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; + this.gridColumn6.FieldName = "createTime"; + this.gridColumn6.Name = "gridColumn6"; + this.gridColumn6.Visible = true; + this.gridColumn6.VisibleIndex = 4; + this.gridColumn6.Width = 201; // - // txt${ColumnInfo.Name.Alias.ToCapit()} + // gridColumn7 // - this.txtcreateTime.EditValue = null; - this.txtcreateTime.ImeMode = System.Windows.Forms.ImeMode.Off; - this.txtcreateTime.Location = new System.Drawing.Point(112, 132); - this.txtcreateTime.Name = "txtcreateTime"; - this.txtcreateTime.Properties.DisplayFormat.FormatString = "G"; - this.txtcreateTime.Properties.DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; - this.txtcreateTime.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + this.gridColumn7.Caption = "编辑人"; + this.gridColumn7.ColumnEdit = this.repositoryItemtxteditorId; + this.gridColumn7.FieldName = "editorId"; + this.gridColumn7.Name = "gridColumn7"; + this.gridColumn7.Visible = true; + this.gridColumn7.VisibleIndex = 5; + this.gridColumn7.Width = 201; + // + // repositoryItemtxteditorId + // + this.repositoryItemtxteditorId.AutoHeight = false; + this.repositoryItemtxteditorId.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.txtcreateTime.Properties.VistaTimeProperties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { - new DevExpress.XtraEditors.Controls.EditorButton()}); - this.txtcreateTime.Size = new System.Drawing.Size(481, 20); - this.txtcreateTime.StyleController = this.layoutControl1; - this.txtcreateTime.TabIndex = 6; + this.repositoryItemtxteditorId.DisplayMember = "Name"; + this.repositoryItemtxteditorId.Name = "repositoryItemtxteditorId"; + this.repositoryItemtxteditorId.ValueMember = "ID"; // - // layoutControlItem6 + // gridColumn8 // - this.layoutControlItem6.Control = this.txtcreateTime; - this.layoutControlItem6.CustomizationFormText = "创建时间"; - this.layoutControlItem6.Location = new System.Drawing.Point(0, 120); - this.layoutControlItem6.Name = "layoutControlItem6"; - this.layoutControlItem6.Size = new System.Drawing.Size(585, 24); - this.layoutControlItem6.Text = "创建时间"; - this.layoutControlItem6.TextSize = new System.Drawing.Size(96, 14); - + this.gridColumn8.Caption = "编辑时间"; + this.gridColumn8.DisplayFormat.FormatString = "G"; + this.gridColumn8.DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; + this.gridColumn8.FieldName = "editTime"; + this.gridColumn8.Name = "gridColumn8"; + this.gridColumn8.Visible = true; + this.gridColumn8.VisibleIndex = 6; + this.gridColumn8.Width = 201; // - // lookUpEdit1 + // gridColumn9 // - this.txteditorId.Location = new System.Drawing.Point(120, 60); - this.txteditorId.Name = "txteditorId"; - this.txteditorId.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { - new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.txteditorId.Properties.DisplayMember = "Name"; - this.txteditorId.Properties.PopupFilterMode = DevExpress.XtraEditors.PopupFilterMode.Contains; - this.txteditorId.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.Standard; - this.txteditorId.Properties.ValueMember = "ID"; - this.txteditorId.Size = new System.Drawing.Size(932, 20); - this.txteditorId.StyleController = this.layoutControl1; - this.txteditorId.TabIndex = 7; - this.txteditorId.EditValue = ""; - - // - // layoutControlItem7 - // - this.layoutControlItem7.Control = this.txteditorId; - this.layoutControlItem7.CustomizationFormText = "编辑人"; - this.layoutControlItem7.Location = new System.Drawing.Point(0, 144); - this.layoutControlItem7.Name = "layoutControlItem7"; - this.layoutControlItem7.Size = new System.Drawing.Size(585, 24); - this.layoutControlItem7.Text = "编辑人"; - this.layoutControlItem7.TextSize = new System.Drawing.Size(96, 14); - - // - // txt${ColumnInfo.Name.Alias.ToCapit()} - // - this.txteditTime.EditValue = null; - this.txteditTime.ImeMode = System.Windows.Forms.ImeMode.Off; - this.txteditTime.Location = new System.Drawing.Point(112, 180); - this.txteditTime.Name = "txteditTime"; - this.txteditTime.Properties.DisplayFormat.FormatString = "G"; - this.txteditTime.Properties.DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; - this.txteditTime.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { - new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.txteditTime.Properties.VistaTimeProperties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { - new DevExpress.XtraEditors.Controls.EditorButton()}); - this.txteditTime.Size = new System.Drawing.Size(481, 20); - this.txteditTime.StyleController = this.layoutControl1; - this.txteditTime.TabIndex = 8; - // - // layoutControlItem8 - // - this.layoutControlItem8.Control = this.txteditTime; - this.layoutControlItem8.CustomizationFormText = "编辑时间"; - this.layoutControlItem8.Location = new System.Drawing.Point(0, 168); - this.layoutControlItem8.Name = "layoutControlItem8"; - this.layoutControlItem8.Size = new System.Drawing.Size(585, 24); - this.layoutControlItem8.Text = "编辑时间"; - this.layoutControlItem8.TextSize = new System.Drawing.Size(96, 14); - - // - // txt${ColumnInfo.Name.Alias.ToCapit()} - // - this.txtremark.Location = new System.Drawing.Point(112, 204); - this.txtremark.Name = "txtremark"; - this.txtremark.Size = new System.Drawing.Size(481, 20); - this.txtremark.StyleController = this.layoutControl1; - this.txtremark.TabIndex = 9; - // - // layoutControlItem9 - // - this.layoutControlItem9.Control = this.txtremark; - this.layoutControlItem9.CustomizationFormText = "备注"; - this.layoutControlItem9.Location = new System.Drawing.Point(0, 192); - this.layoutControlItem9.Name = "layoutControlItem9"; - this.layoutControlItem9.Size = new System.Drawing.Size(585, 24); - this.layoutControlItem9.Text = "备注"; - this.layoutControlItem9.TextSize = new System.Drawing.Size(96, 14); - - - // - // layoutControlGroup1 - // - this.layoutControlGroup1.CustomizationFormText = "layoutControlGroup1"; - this.layoutControlGroup1.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True; - this.layoutControlGroup1.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] { - this.layoutControlItem1 - ,this.layoutControlItem2 - ,this.layoutControlItem3 - ,this.layoutControlItem4 - ,this.layoutControlItem5 - ,this.layoutControlItem6 - ,this.layoutControlItem7 - ,this.layoutControlItem8 - ,this.layoutControlItem9 - }); - this.layoutControlGroup1.Location = new System.Drawing.Point(0, 0); - this.layoutControlGroup1.Name = "layoutControlGroup1"; - this.layoutControlGroup1.Size = new System.Drawing.Size(605, 363); - this.layoutControlGroup1.Text = "layoutControlGroup1"; - this.layoutControlGroup1.TextVisible = false; - - + this.gridColumn9.Caption = "备注"; + this.gridColumn9.FieldName = "remark"; + this.gridColumn9.Name = "gridColumn9"; + this.gridColumn9.Visible = true; + this.gridColumn9.VisibleIndex = 7; + this.gridColumn9.Width = 201; // // xtraTabControl1 // @@ -410,7 +239,7 @@ namespace MES.Form this.xtraTabControl1.Location = new System.Drawing.Point(0, 34); this.xtraTabControl1.Name = "xtraTabControl1"; this.xtraTabControl1.SelectedTabPage = this.tabDataList; - this.xtraTabControl1.Size = new System.Drawing.Size(585, 436); + this.xtraTabControl1.Size = new System.Drawing.Size(1300, 766); this.xtraTabControl1.TabIndex = 1; this.xtraTabControl1.TabPages.AddRange(new DevExpress.XtraTab.XtraTabPage[] { this.tabDataList, @@ -420,45 +249,43 @@ namespace MES.Form // this.tabDataList.Controls.Add(this.grdList); this.tabDataList.Name = "tabDataList"; - this.tabDataList.Size = new System.Drawing.Size(579, 407); + this.tabDataList.Size = new System.Drawing.Size(1294, 737); this.tabDataList.Text = "数据列表"; // - // tabDataDetail - // - this.tabDataDetail.Controls.Add(this.panelControl2); - this.tabDataDetail.Name = "tabDataDetail"; - this.tabDataDetail.Size = new System.Drawing.Size(579, 407); - this.tabDataDetail.Text = "数据编辑"; - // // grdList // this.grdList.Dock = System.Windows.Forms.DockStyle.Fill; this.grdList.Location = new System.Drawing.Point(0, 0); this.grdList.MainView = this.grdListView; this.grdList.Name = "grdList"; - this.grdList.Size = new System.Drawing.Size(579, 407); + this.grdList.Size = new System.Drawing.Size(1294, 737); this.grdList.TabIndex = 0; this.grdList.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] { this.grdListView}); // // grdListView // - this.grdListView.Columns.AddRange(new DevExpress.XtraGrid.Columns.GridColumn[] { - this.gridColumn1, - this.gridColumn2, - this.gridColumn3, - this.gridColumn4, - this.gridColumn5, - this.gridColumn6, - this.gridColumn7, - this.gridColumn8, - this.gridColumn9, - }); - this.grdListView.OptionsBehavior.Editable = false; + this.grdListView.Columns.AddRange(new DevExpress.XtraGrid.Columns.GridColumn[] { + this.gridColumn1, + this.gridColumn2, + this.gridColumn3, + this.gridColumn4, + this.gridColumn5, + this.gridColumn6, + this.gridColumn7, + this.gridColumn8, + this.gridColumn9}); this.grdListView.GridControl = this.grdList; this.grdListView.Name = "grdListView"; - this.grdListView.OptionsView.ColumnAutoWidth=false; - this.grdListView.BestFitColumns(); + this.grdListView.OptionsBehavior.Editable = false; + this.grdListView.OptionsView.ColumnAutoWidth = false; + // + // tabDataDetail + // + this.tabDataDetail.Controls.Add(this.panelControl2); + this.tabDataDetail.Name = "tabDataDetail"; + this.tabDataDetail.Size = new System.Drawing.Size(579, 407); + this.tabDataDetail.Text = "数据编辑"; // // panelControl2 // @@ -468,153 +295,297 @@ namespace MES.Form this.panelControl2.Name = "panelControl2"; this.panelControl2.Size = new System.Drawing.Size(579, 407); this.panelControl2.TabIndex = 0; - - //////////////////////////////// - (this.gridColumn1).Caption = "id"; - (this.gridColumn1).Name = "gridColumn1"; - (this.gridColumn1).FieldName = "id"; - // repositoryItemTreeListLookUpEdit1 // - (this.gridColumn2).ColumnEdit = this.repositoryItemTreeListtxtpid; - this.repositoryItemTreeListtxtpid.AutoHeight = false; - this.repositoryItemTreeListtxtpid.DisplayMember = "Name"; - this.repositoryItemTreeListtxtpid.ValueMember = "ID"; - this.repositoryItemTreeListtxtpid.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + // layoutControl1 + // + this.layoutControl1.Controls.Add(this.txtid); + this.layoutControl1.Controls.Add(this.txtpid); + this.layoutControl1.Controls.Add(this.txtname); + this.layoutControl1.Controls.Add(this.txtsort); + this.layoutControl1.Controls.Add(this.txtcreatorId); + this.layoutControl1.Controls.Add(this.txtcreateTime); + this.layoutControl1.Controls.Add(this.txteditorId); + this.layoutControl1.Controls.Add(this.txteditTime); + this.layoutControl1.Controls.Add(this.txtremark); + this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill; + this.layoutControl1.Location = new System.Drawing.Point(2, 2); + this.layoutControl1.Name = "layoutControl1"; + this.layoutControl1.Root = this.layoutControlGroup1; + this.layoutControl1.Size = new System.Drawing.Size(575, 403); + this.layoutControl1.TabIndex = 6; + this.layoutControl1.Text = "layoutControl1"; + // + // layoutControlGroup1 + // + this.layoutControlGroup1.CustomizationFormText = "layoutControlGroup1"; + this.layoutControlGroup1.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True; + this.layoutControlGroup1.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] { + this.layoutControlItem1, + this.layoutControlItem2, + this.layoutControlItem3, + this.layoutControlItem4, + this.layoutControlItem5, + this.layoutControlItem6, + this.layoutControlItem7, + this.layoutControlItem8, + this.layoutControlItem9}); + this.layoutControlGroup1.Name = "layoutControlGroup1"; + this.layoutControlGroup1.Size = new System.Drawing.Size(575, 403); + this.layoutControlGroup1.TextVisible = false; + // + // layoutControlItem1 + // + this.layoutControlItem1.Control = this.txtid; + this.layoutControlItem1.CustomizationFormText = "id"; + this.layoutControlItem1.Location = new System.Drawing.Point(0, 0); + this.layoutControlItem1.Name = "layoutControlItem1"; + this.layoutControlItem1.Size = new System.Drawing.Size(555, 24); + this.layoutControlItem1.Text = "id"; + this.layoutControlItem1.TextSize = new System.Drawing.Size(48, 14); + // + // txtid + // + this.txtid.Location = new System.Drawing.Point(63, 12); + this.txtid.Name = "txtid"; + this.txtid.Size = new System.Drawing.Size(500, 20); + this.txtid.StyleController = this.layoutControl1; + this.txtid.TabIndex = 1; + // + // layoutControlItem2 + // + this.layoutControlItem2.Control = this.txtpid; + this.layoutControlItem2.CustomizationFormText = "父类型"; + this.layoutControlItem2.Location = new System.Drawing.Point(0, 24); + this.layoutControlItem2.Name = "layoutControlItem2"; + this.layoutControlItem2.Size = new System.Drawing.Size(555, 24); + this.layoutControlItem2.Text = "父类型"; + this.layoutControlItem2.TextSize = new System.Drawing.Size(48, 14); + // + // txtpid + // + this.txtpid.EditValue = ""; + this.txtpid.Location = new System.Drawing.Point(63, 36); + this.txtpid.Name = "txtpid"; + this.txtpid.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.repositoryItemTreeListtxtpid.Name = "repositoryItemTreeListtxtpid"; - this.repositoryItemTreeListtxtpid.TreeList = this.repositoryItemTreeListtxtpidTreeList; + this.txtpid.Properties.DisplayMember = "Name"; + this.txtpid.Properties.TreeList = this.txtpidTreeList; + this.txtpid.Properties.ValueMember = "ID"; + this.txtpid.Size = new System.Drawing.Size(500, 20); + this.txtpid.StyleController = this.layoutControl1; + this.txtpid.TabIndex = 2; // - // repositoryItemTreeListLookUpEdit1TreeList + // txtpidTreeList // - this.repositoryItemTreeListtxtpidTreeList.Location = new System.Drawing.Point(0, 0); - this.repositoryItemTreeListtxtpidTreeList.ParentFieldName = "PID"; - this.repositoryItemTreeListtxtpidTreeList.Name = "repositoryItemTreeListtxtpidTreeList"; - this.repositoryItemTreeListtxtpidTreeList.OptionsView.ShowIndentAsRowStyle = true; - this.repositoryItemTreeListtxtpidTreeList.Size = new System.Drawing.Size(400, 200); - this.repositoryItemTreeListtxtpidTreeList.TabIndex = 0; - (this.gridColumn2).Caption = "父类型"; - (this.gridColumn2).Name = "gridColumn2"; - (this.gridColumn2).FieldName = "pid"; - (this.gridColumn2).Visible = true; - (this.gridColumn2).VisibleIndex = 2; - - //////////////////////////////// - (this.gridColumn3).Caption = "名称"; - (this.gridColumn3).Name = "gridColumn3"; - (this.gridColumn3).FieldName = "name"; - (this.gridColumn3).Visible = true; - (this.gridColumn3).VisibleIndex = 3; - - //////////////////////////////// - (this.gridColumn4).Caption = "排序"; - (this.gridColumn4).Name = "gridColumn4"; - (this.gridColumn4).FieldName = "sort"; - (this.gridColumn4).Visible = true; - (this.gridColumn4).VisibleIndex = 4; - - (this.gridColumn5).ColumnEdit = this.repositoryItemtxtcreatorId; - this.repositoryItemtxtcreatorId.AutoHeight = false; - this.repositoryItemtxtcreatorId.DisplayMember = "Name"; - this.repositoryItemtxtcreatorId.ValueMember = "ID"; - this.repositoryItemtxtcreatorId.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + this.txtpidTreeList.Location = new System.Drawing.Point(0, 0); + this.txtpidTreeList.Name = "txtpidTreeList"; + this.txtpidTreeList.OptionsView.ShowIndentAsRowStyle = true; + this.txtpidTreeList.ParentFieldName = "PID"; + this.txtpidTreeList.Size = new System.Drawing.Size(400, 200); + this.txtpidTreeList.TabIndex = 0; + // + // layoutControlItem3 + // + this.layoutControlItem3.Control = this.txtname; + this.layoutControlItem3.CustomizationFormText = "名称"; + this.layoutControlItem3.Location = new System.Drawing.Point(0, 48); + this.layoutControlItem3.Name = "layoutControlItem3"; + this.layoutControlItem3.Size = new System.Drawing.Size(555, 24); + this.layoutControlItem3.Text = "名称"; + this.layoutControlItem3.TextSize = new System.Drawing.Size(48, 14); + // + // txtname + // + this.txtname.Location = new System.Drawing.Point(63, 60); + this.txtname.Name = "txtname"; + this.txtname.Size = new System.Drawing.Size(500, 20); + this.txtname.StyleController = this.layoutControl1; + this.txtname.TabIndex = 3; + // + // layoutControlItem4 + // + this.layoutControlItem4.Control = this.txtsort; + this.layoutControlItem4.CustomizationFormText = "排序"; + this.layoutControlItem4.Location = new System.Drawing.Point(0, 72); + this.layoutControlItem4.Name = "layoutControlItem4"; + this.layoutControlItem4.Size = new System.Drawing.Size(555, 24); + this.layoutControlItem4.Text = "排序"; + this.layoutControlItem4.TextSize = new System.Drawing.Size(48, 14); + // + // txtsort + // + this.txtsort.Location = new System.Drawing.Point(63, 84); + this.txtsort.Name = "txtsort"; + this.txtsort.Size = new System.Drawing.Size(500, 20); + this.txtsort.StyleController = this.layoutControl1; + this.txtsort.TabIndex = 4; + // + // layoutControlItem5 + // + this.layoutControlItem5.Control = this.txtcreatorId; + this.layoutControlItem5.CustomizationFormText = "创建人"; + this.layoutControlItem5.Location = new System.Drawing.Point(0, 96); + this.layoutControlItem5.Name = "layoutControlItem5"; + this.layoutControlItem5.Size = new System.Drawing.Size(555, 24); + this.layoutControlItem5.Text = "创建人"; + this.layoutControlItem5.TextSize = new System.Drawing.Size(48, 14); + // + // txtcreatorId + // + this.txtcreatorId.EditValue = ""; + this.txtcreatorId.Location = new System.Drawing.Point(63, 108); + this.txtcreatorId.Name = "txtcreatorId"; + this.txtcreatorId.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.repositoryItemtxtcreatorId.Name = "repositoryItemtxtcreatorId"; - (this.gridColumn5).Caption = "创建人"; - (this.gridColumn5).Name = "gridColumn5"; - (this.gridColumn5).FieldName = "creatorId"; - (this.gridColumn5).Visible = true; - (this.gridColumn5).VisibleIndex = 5; - - (this.gridColumn6).DisplayFormat.FormatString = "G"; - (this.gridColumn6).DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; - (this.gridColumn6).Caption = "创建时间"; - (this.gridColumn6).Name = "gridColumn6"; - (this.gridColumn6).FieldName = "createTime"; - (this.gridColumn6).Visible = true; - (this.gridColumn6).VisibleIndex = 6; - - (this.gridColumn7).ColumnEdit = this.repositoryItemtxteditorId; - this.repositoryItemtxteditorId.AutoHeight = false; - this.repositoryItemtxteditorId.DisplayMember = "Name"; - this.repositoryItemtxteditorId.ValueMember = "ID"; - this.repositoryItemtxteditorId.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { - new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); - this.repositoryItemtxteditorId.Name = "repositoryItemtxteditorId"; - (this.gridColumn7).Caption = "编辑人"; - (this.gridColumn7).Name = "gridColumn7"; - (this.gridColumn7).FieldName = "editorId"; - (this.gridColumn7).Visible = true; - (this.gridColumn7).VisibleIndex = 7; - - (this.gridColumn8).DisplayFormat.FormatString = "G"; - (this.gridColumn8).DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; - (this.gridColumn8).Caption = "编辑时间"; - (this.gridColumn8).Name = "gridColumn8"; - (this.gridColumn8).FieldName = "editTime"; - (this.gridColumn8).Visible = true; - (this.gridColumn8).VisibleIndex = 8; - - //////////////////////////////// - (this.gridColumn9).Caption = "备注"; - (this.gridColumn9).Name = "gridColumn9"; - (this.gridColumn9).FieldName = "remark"; - (this.gridColumn9).Visible = true; - (this.gridColumn9).VisibleIndex = 9; - - + this.txtcreatorId.Properties.DisplayMember = "Name"; + this.txtcreatorId.Properties.PopupFilterMode = DevExpress.XtraEditors.PopupFilterMode.Contains; + this.txtcreatorId.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.Standard; + this.txtcreatorId.Properties.ValueMember = "ID"; + this.txtcreatorId.Size = new System.Drawing.Size(500, 20); + this.txtcreatorId.StyleController = this.layoutControl1; + this.txtcreatorId.TabIndex = 5; // - // XtraForm1 + // layoutControlItem6 + // + this.layoutControlItem6.Control = this.txtcreateTime; + this.layoutControlItem6.CustomizationFormText = "创建时间"; + this.layoutControlItem6.Location = new System.Drawing.Point(0, 120); + this.layoutControlItem6.Name = "layoutControlItem6"; + this.layoutControlItem6.Size = new System.Drawing.Size(555, 24); + this.layoutControlItem6.Text = "创建时间"; + this.layoutControlItem6.TextSize = new System.Drawing.Size(48, 14); + // + // txtcreateTime + // + this.txtcreateTime.EditValue = null; + this.txtcreateTime.ImeMode = System.Windows.Forms.ImeMode.Off; + this.txtcreateTime.Location = new System.Drawing.Point(63, 132); + this.txtcreateTime.Name = "txtcreateTime"; + this.txtcreateTime.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); + this.txtcreateTime.Properties.CalendarTimeProperties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + new DevExpress.XtraEditors.Controls.EditorButton()}); + this.txtcreateTime.Properties.DisplayFormat.FormatString = "G"; + this.txtcreateTime.Properties.DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; + this.txtcreateTime.Size = new System.Drawing.Size(500, 20); + this.txtcreateTime.StyleController = this.layoutControl1; + this.txtcreateTime.TabIndex = 6; + // + // layoutControlItem7 + // + this.layoutControlItem7.Control = this.txteditorId; + this.layoutControlItem7.CustomizationFormText = "编辑人"; + this.layoutControlItem7.Location = new System.Drawing.Point(0, 144); + this.layoutControlItem7.Name = "layoutControlItem7"; + this.layoutControlItem7.Size = new System.Drawing.Size(555, 24); + this.layoutControlItem7.Text = "编辑人"; + this.layoutControlItem7.TextSize = new System.Drawing.Size(48, 14); + // + // txteditorId + // + this.txteditorId.EditValue = ""; + this.txteditorId.Location = new System.Drawing.Point(63, 156); + this.txteditorId.Name = "txteditorId"; + this.txteditorId.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); + this.txteditorId.Properties.DisplayMember = "Name"; + this.txteditorId.Properties.PopupFilterMode = DevExpress.XtraEditors.PopupFilterMode.Contains; + this.txteditorId.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.Standard; + this.txteditorId.Properties.ValueMember = "ID"; + this.txteditorId.Size = new System.Drawing.Size(500, 20); + this.txteditorId.StyleController = this.layoutControl1; + this.txteditorId.TabIndex = 7; + // + // layoutControlItem8 + // + this.layoutControlItem8.Control = this.txteditTime; + this.layoutControlItem8.CustomizationFormText = "编辑时间"; + this.layoutControlItem8.Location = new System.Drawing.Point(0, 168); + this.layoutControlItem8.Name = "layoutControlItem8"; + this.layoutControlItem8.Size = new System.Drawing.Size(555, 24); + this.layoutControlItem8.Text = "编辑时间"; + this.layoutControlItem8.TextSize = new System.Drawing.Size(48, 14); + // + // txteditTime + // + this.txteditTime.EditValue = null; + this.txteditTime.ImeMode = System.Windows.Forms.ImeMode.Off; + this.txteditTime.Location = new System.Drawing.Point(63, 180); + this.txteditTime.Name = "txteditTime"; + this.txteditTime.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)}); + this.txteditTime.Properties.CalendarTimeProperties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { + new DevExpress.XtraEditors.Controls.EditorButton()}); + this.txteditTime.Properties.DisplayFormat.FormatString = "G"; + this.txteditTime.Properties.DisplayFormat.FormatType = DevExpress.Utils.FormatType.DateTime; + this.txteditTime.Size = new System.Drawing.Size(500, 20); + this.txteditTime.StyleController = this.layoutControl1; + this.txteditTime.TabIndex = 8; + // + // layoutControlItem9 + // + this.layoutControlItem9.Control = this.txtremark; + this.layoutControlItem9.CustomizationFormText = "备注"; + this.layoutControlItem9.Location = new System.Drawing.Point(0, 192); + this.layoutControlItem9.Name = "layoutControlItem9"; + this.layoutControlItem9.Size = new System.Drawing.Size(555, 191); + this.layoutControlItem9.Text = "备注"; + this.layoutControlItem9.TextSize = new System.Drawing.Size(48, 14); + // + // txtremark + // + this.txtremark.Location = new System.Drawing.Point(63, 204); + this.txtremark.Name = "txtremark"; + this.txtremark.Size = new System.Drawing.Size(500, 20); + this.txtremark.StyleController = this.layoutControl1; + this.txtremark.TabIndex = 9; + // + // FrmsysDictType // this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.ClientSize = new System.Drawing.Size(1300, 800); this.Controls.Add(this.xtraTabControl1); this.Name = "FrmsysDictType"; - this.Text = "FrmsysDictType"; + this.Text = "参数类型维护"; this.Load += new System.EventHandler(this.FrmsysDictType_Load); this.Controls.SetChildIndex(this.xtraTabControl1, 0); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtid.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtpidTreeList)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemTreeListtxtpid)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemTreeListtxtpidTreeList)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtpid.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).EndInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtname.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).EndInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtsort.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemtxtcreatorId)).EndInit(); - - ((System.ComponentModel.ISupportInitialize)(this.txtcreatorId.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties.CalendarTimeProperties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemtxteditorId)).EndInit(); - - ((System.ComponentModel.ISupportInitialize)(this.txteditorId.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties.CalendarTimeProperties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).EndInit(); - ///////////////////////// - ((System.ComponentModel.ISupportInitialize)(this.txtremark.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.xtraTabControl1)).EndInit(); this.xtraTabControl1.ResumeLayout(false); this.tabDataList.ResumeLayout(false); - this.tabDataDetail.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.grdList)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.grdListView)).EndInit(); + this.tabDataDetail.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.panelControl2)).EndInit(); + this.panelControl2.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).EndInit(); this.layoutControl1.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).EndInit(); - + ((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtid.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtpid.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtpidTreeList)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtname.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtsort.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtcreatorId.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties.CalendarTimeProperties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtcreateTime.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txteditorId.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties.CalendarTimeProperties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txteditTime.Properties)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.txtremark.Properties)).EndInit(); this.ResumeLayout(false); } diff --git a/WinformGeneralDeveloperFrame/Form/FrmsysMenu.cs b/WinformGeneralDeveloperFrame/Form/FrmsysMenu.cs index 2170f35..dd9de48 100644 --- a/WinformGeneralDeveloperFrame/Form/FrmsysMenu.cs +++ b/WinformGeneralDeveloperFrame/Form/FrmsysMenu.cs @@ -15,7 +15,8 @@ using MES.Entity; namespace MES.Form { - public partial class FrmsysMenu : FrmBaseForm + + public partial class FrmsysMenu : FrmBaseForm { private Dictionary fieldDictionary = new Dictionary(); public FrmsysMenu() @@ -26,6 +27,7 @@ namespace MES.Form private void FrmsysMenu_Load(object sender, EventArgs e) { InitFrom(xtraTabControl1,grdList,grdListView,new LayoutControlGroup[]{layoutControlGroup1},new sysMenuInfo()); + InitSearchDicData(); } public override void InitgrdListDataSource() @@ -34,7 +36,6 @@ namespace MES.Form { grdList.DataSource = con.sysMenuInfo.ToList(); } - Init(); } @@ -47,11 +48,12 @@ namespace MES.Form repositoryItemtxtcreatorId.DataSource= GetDataTableUtils.SqlTable("用户"); txteditorId.Properties.DataSource = GetDataTableUtils.SqlTable("用户"); repositoryItemtxteditorId.DataSource = GetDataTableUtils.SqlTable("用户"); - - fieldDictionary.Add("菜单名称","name"); + } + private void InitSearchDicData() + { + fieldDictionary.Add("菜单名称", "name"); fieldDictionary.Add("创建时间", "createTime"); } - private void simpleButton1_Click(object sender, EventArgs e) { string file = GetIconPath(); @@ -119,7 +121,14 @@ namespace MES.Form string sql = frm.sql; using (var db = new MESDB()) { - grdList.DataSource=db.sysMenuInfo.SqlQuery($"select * from sysMenu where {sql}").ToList(); + if (string.IsNullOrEmpty(sql)) + { + grdList.DataSource = db.sysMenuInfo.SqlQuery("select * from sysMenu").ToList(); + } + else + { + grdList.DataSource = db.sysMenuInfo.SqlQuery($"select * from sysMenu where {sql}").ToList(); + } } } } diff --git a/WinformGeneralDeveloperFrame/Form/FrmsysMenu.designer.cs b/WinformGeneralDeveloperFrame/Form/FrmsysMenu.designer.cs index aa7a638..c02350c 100644 --- a/WinformGeneralDeveloperFrame/Form/FrmsysMenu.designer.cs +++ b/WinformGeneralDeveloperFrame/Form/FrmsysMenu.designer.cs @@ -344,6 +344,8 @@ namespace MES.Form this.grdListView.Name = "grdListView"; this.grdListView.OptionsBehavior.Editable = false; this.grdListView.OptionsView.ColumnAutoWidth = false; + this.grdListView.SortInfo.AddRange(new DevExpress.XtraGrid.Columns.GridColumnSortInfo[] { + new DevExpress.XtraGrid.Columns.GridColumnSortInfo(this.gridColumn7, DevExpress.Data.ColumnSortOrder.Ascending)}); // // tabDataDetail // diff --git a/WinformGeneralDeveloperFrame/Form/FrmsysUser.cs b/WinformGeneralDeveloperFrame/Form/FrmsysUser.cs index 3cac715..7ee99f7 100644 --- a/WinformGeneralDeveloperFrame/Form/FrmsysUser.cs +++ b/WinformGeneralDeveloperFrame/Form/FrmsysUser.cs @@ -23,15 +23,12 @@ namespace MES.Form } private void FrmsysUser_Load(object sender, EventArgs e) { - Init(); + InitFrom(xtraTabControl1, grdList, grdListView, new LayoutControlGroup[] { layoutControlGroup1 }, new sysUserInfo()); } private void Init() { - - - txtdeptId.Properties.DataSource = GetDataTableUtils.SqlTable("部门"); repositoryItemtxtdeptId.DataSource = GetDataTableUtils.SqlTable("部门"); txtcreatorId.Properties.DataSource = GetDataTableUtils.SqlTable("用户"); @@ -39,40 +36,8 @@ namespace MES.Form txteditorId.Properties.DataSource = GetDataTableUtils.SqlTable("用户"); repositoryItemtxteditorId.DataSource = GetDataTableUtils.SqlTable("用户"); + } - - - //////////////////////////////////////////////////////// - - //////////////////////////////////////////////////////// - - //////////////////////////////////////////////////////// - - //////////////////////////////////////////////////////// - - //////////////////////////////////////////////////////// - - //////////////////////////////////////////////////////// - - txtdeptId.Properties.DataSource = GetDataTableUtils.SqlTable("部门"); - repositoryItemtxtdeptId.DataSource = GetDataTableUtils.SqlTable("部门"); - - - //////////////////////////////////////////////////////// - - txtcreatorId.Properties.DataSource = GetDataTableUtils.SqlTable("用户"); - repositoryItemtxtcreatorId.DataSource = GetDataTableUtils.SqlTable("用户"); - - - //////////////////////////////////////////////////////// - - txteditorId.Properties.DataSource = GetDataTableUtils.SqlTable("用户"); - repositoryItemtxteditorId.DataSource = GetDataTableUtils.SqlTable("用户"); - - - //////////////////////////////////////////////////////// - - } public override bool SaveFunction() { try @@ -97,6 +62,7 @@ namespace MES.Form { grdList.DataSource = con.sysUserInfo.ToList(); } + Init(); } public override bool CheckInput() diff --git a/WinformGeneralDeveloperFrame/FrmSearch.cs b/WinformGeneralDeveloperFrame/FrmSearch.cs index 5fd9c17..3209c64 100644 --- a/WinformGeneralDeveloperFrame/FrmSearch.cs +++ b/WinformGeneralDeveloperFrame/FrmSearch.cs @@ -24,7 +24,10 @@ namespace WinformGeneralDeveloperFrame private void btnok_Click(object sender, EventArgs e) { - sql = txtSql.Text.Substring(0,txtSql.Text.Length-txtrelation.Text.Length); + if (!string.IsNullOrEmpty(txtSql.Text)) + { + sql = txtSql.Text.Substring(0, txtSql.Text.Length - txtrelation.Text.Length); + } this.DialogResult = DialogResult.OK; } diff --git a/WinformGeneralDeveloperFrame/FrmShowForm.Designer.cs b/WinformGeneralDeveloperFrame/FrmShowForm.Designer.cs index 431a07b..364af78 100644 --- a/WinformGeneralDeveloperFrame/FrmShowForm.Designer.cs +++ b/WinformGeneralDeveloperFrame/FrmShowForm.Designer.cs @@ -31,14 +31,7 @@ namespace WinformGeneralDeveloperFrame { this.panelControl1 = new DevExpress.XtraEditors.PanelControl(); this.labelControl1 = new DevExpress.XtraEditors.LabelControl(); - this.simpleButton8 = new DevExpress.XtraEditors.SimpleButton(); - this.simpleButton7 = new DevExpress.XtraEditors.SimpleButton(); - this.simpleButton6 = new DevExpress.XtraEditors.SimpleButton(); - this.simpleButton5 = new DevExpress.XtraEditors.SimpleButton(); - this.simpleButton4 = new DevExpress.XtraEditors.SimpleButton(); - this.simpleButton3 = new DevExpress.XtraEditors.SimpleButton(); - this.simpleButton2 = new DevExpress.XtraEditors.SimpleButton(); - this.simpleButton1 = new DevExpress.XtraEditors.SimpleButton(); + this.flowLayoutPanel1 = new System.Windows.Forms.FlowLayoutPanel(); ((System.ComponentModel.ISupportInitialize)(this.panelControl1)).BeginInit(); this.panelControl1.SuspendLayout(); this.SuspendLayout(); @@ -60,110 +53,24 @@ namespace WinformGeneralDeveloperFrame this.labelControl1.Size = new System.Drawing.Size(0, 14); this.labelControl1.TabIndex = 0; // - // simpleButton8 + // flowLayoutPanel1 // - this.simpleButton8.ImageOptions.Image = global::WinformGeneralDeveloperFrame.Properties.Resources.pagesetup_32x32; - this.simpleButton8.ImageOptions.Location = DevExpress.XtraEditors.ImageLocation.TopCenter; - this.simpleButton8.Location = new System.Drawing.Point(564, 34); - this.simpleButton8.Name = "simpleButton8"; - this.simpleButton8.Size = new System.Drawing.Size(87, 74); - this.simpleButton8.TabIndex = 8; - this.simpleButton8.Text = "参数类型维护"; - this.simpleButton8.Click += new System.EventHandler(this.simpleButton8_Click); - // - // simpleButton7 - // - this.simpleButton7.ImageOptions.Image = global::WinformGeneralDeveloperFrame.Properties.Resources.build_32x32; - this.simpleButton7.ImageOptions.Location = DevExpress.XtraEditors.ImageLocation.TopCenter; - this.simpleButton7.Location = new System.Drawing.Point(657, 34); - this.simpleButton7.Name = "simpleButton7"; - this.simpleButton7.Size = new System.Drawing.Size(87, 74); - this.simpleButton7.TabIndex = 7; - this.simpleButton7.Text = "参数维护"; - this.simpleButton7.Click += new System.EventHandler(this.simpleButton7_Click); - // - // simpleButton6 - // - this.simpleButton6.ImageOptions.Image = global::WinformGeneralDeveloperFrame.Properties.Resources.team_32x32; - this.simpleButton6.ImageOptions.Location = DevExpress.XtraEditors.ImageLocation.TopCenter; - this.simpleButton6.Location = new System.Drawing.Point(471, 34); - this.simpleButton6.Name = "simpleButton6"; - this.simpleButton6.Size = new System.Drawing.Size(87, 74); - this.simpleButton6.TabIndex = 6; - this.simpleButton6.Text = "用户维护"; - this.simpleButton6.Click += new System.EventHandler(this.simpleButton6_Click); - // - // simpleButton5 - // - this.simpleButton5.ImageOptions.Image = global::WinformGeneralDeveloperFrame.Properties.Resources.folderpanel_32x32; - this.simpleButton5.ImageOptions.Location = DevExpress.XtraEditors.ImageLocation.TopCenter; - this.simpleButton5.Location = new System.Drawing.Point(378, 34); - this.simpleButton5.Name = "simpleButton5"; - this.simpleButton5.Size = new System.Drawing.Size(87, 74); - this.simpleButton5.TabIndex = 5; - this.simpleButton5.Text = "菜单维护"; - this.simpleButton5.Click += new System.EventHandler(this.simpleButton5_Click); - // - // simpleButton4 - // - this.simpleButton4.ImageOptions.Image = global::WinformGeneralDeveloperFrame.Properties.Resources.boreport_32x32; - this.simpleButton4.ImageOptions.Location = DevExpress.XtraEditors.ImageLocation.TopCenter; - this.simpleButton4.Location = new System.Drawing.Point(285, 34); - this.simpleButton4.Name = "simpleButton4"; - this.simpleButton4.Size = new System.Drawing.Size(87, 74); - this.simpleButton4.TabIndex = 4; - this.simpleButton4.Text = "代码生成"; - this.simpleButton4.Click += new System.EventHandler(this.simpleButton4_Click); - // - // simpleButton3 - // - this.simpleButton3.ImageOptions.Image = global::WinformGeneralDeveloperFrame.Properties.Resources.database_32x32; - this.simpleButton3.ImageOptions.Location = DevExpress.XtraEditors.ImageLocation.TopCenter; - this.simpleButton3.Location = new System.Drawing.Point(192, 34); - this.simpleButton3.Name = "simpleButton3"; - this.simpleButton3.Size = new System.Drawing.Size(87, 74); - this.simpleButton3.TabIndex = 3; - this.simpleButton3.Text = "创建数据源"; - this.simpleButton3.Click += new System.EventHandler(this.simpleButton3_Click); - // - // simpleButton2 - // - this.simpleButton2.ImageOptions.Image = global::WinformGeneralDeveloperFrame.Properties.Resources.selectdata_32x32; - this.simpleButton2.ImageOptions.Location = DevExpress.XtraEditors.ImageLocation.TopCenter; - this.simpleButton2.Location = new System.Drawing.Point(99, 34); - this.simpleButton2.Name = "simpleButton2"; - this.simpleButton2.Size = new System.Drawing.Size(87, 74); - this.simpleButton2.TabIndex = 2; - this.simpleButton2.Text = "创建数据集"; - this.simpleButton2.Click += new System.EventHandler(this.simpleButton2_Click); - // - // simpleButton1 - // - this.simpleButton1.ImageOptions.Image = global::WinformGeneralDeveloperFrame.Properties.Resources.bocustomer_32x32; - this.simpleButton1.ImageOptions.Location = DevExpress.XtraEditors.ImageLocation.TopCenter; - this.simpleButton1.Location = new System.Drawing.Point(6, 34); - this.simpleButton1.Name = "simpleButton1"; - this.simpleButton1.Size = new System.Drawing.Size(87, 74); - this.simpleButton1.TabIndex = 1; - this.simpleButton1.Text = "测试"; - this.simpleButton1.Click += new System.EventHandler(this.simpleButton1_Click); + this.flowLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill; + this.flowLayoutPanel1.Location = new System.Drawing.Point(0, 28); + this.flowLayoutPanel1.Name = "flowLayoutPanel1"; + this.flowLayoutPanel1.Size = new System.Drawing.Size(954, 588); + this.flowLayoutPanel1.TabIndex = 1; // // FrmShowForm // this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.ClientSize = new System.Drawing.Size(954, 616); - this.Controls.Add(this.simpleButton8); - this.Controls.Add(this.simpleButton7); - this.Controls.Add(this.simpleButton6); - this.Controls.Add(this.simpleButton5); - this.Controls.Add(this.simpleButton4); - this.Controls.Add(this.simpleButton3); - this.Controls.Add(this.simpleButton2); - this.Controls.Add(this.simpleButton1); + this.Controls.Add(this.flowLayoutPanel1); this.Controls.Add(this.panelControl1); this.Name = "FrmShowForm"; this.Text = "ShowForm"; + this.Load += new System.EventHandler(this.FrmShowForm_Load); ((System.ComponentModel.ISupportInitialize)(this.panelControl1)).EndInit(); this.panelControl1.ResumeLayout(false); this.panelControl1.PerformLayout(); @@ -175,13 +82,6 @@ namespace WinformGeneralDeveloperFrame private DevExpress.XtraEditors.PanelControl panelControl1; private DevExpress.XtraEditors.LabelControl labelControl1; - private DevExpress.XtraEditors.SimpleButton simpleButton1; - private DevExpress.XtraEditors.SimpleButton simpleButton2; - private DevExpress.XtraEditors.SimpleButton simpleButton3; - private DevExpress.XtraEditors.SimpleButton simpleButton4; - private DevExpress.XtraEditors.SimpleButton simpleButton5; - private DevExpress.XtraEditors.SimpleButton simpleButton6; - private DevExpress.XtraEditors.SimpleButton simpleButton7; - private DevExpress.XtraEditors.SimpleButton simpleButton8; + private System.Windows.Forms.FlowLayoutPanel flowLayoutPanel1; } } \ No newline at end of file diff --git a/WinformGeneralDeveloperFrame/FrmShowForm.cs b/WinformGeneralDeveloperFrame/FrmShowForm.cs index 9b43991..67e50f5 100644 --- a/WinformGeneralDeveloperFrame/FrmShowForm.cs +++ b/WinformGeneralDeveloperFrame/FrmShowForm.cs @@ -4,17 +4,22 @@ using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; +using System.IO; using System.Linq; +using System.Reflection; using System.Text; using System.Threading.Tasks; using System.Windows.Forms; using MES.Form; +using MES; +using WinformGeneralDeveloperFrame.Commons; namespace WinformGeneralDeveloperFrame { public partial class FrmShowForm : DevExpress.XtraEditors.XtraForm { public MainForm mainform; + public int formId; public FrmShowForm() { InitializeComponent(); @@ -62,5 +67,55 @@ namespace WinformGeneralDeveloperFrame { ChildWinManagement.LoadMdiForm(mainform, typeof(FrmsysDictData)); } + + private void FrmShowForm_Load(object sender, EventArgs e) + { + + } + + public void Init() + { + flowLayoutPanel1.Controls.Clear(); + using (var db = new MESDB()) + { + var data = db.sysMenuInfo.Where(p => p.pid == formId).ToList(); + + foreach (var item in data) + { + SimpleButton btn = new SimpleButton(); + btn.Name = "btn" + item.id; + btn.Size = new System.Drawing.Size(90, 75); + btn.Text = item.name; + btn.Click += (o, args) => + { + try + { + string[] itemArray = item.winformType.Split(new char[] {',', ';'}); + + string type = itemArray[0].Trim(); + string filePath = itemArray[1].Trim(); //必须是相对路径 + + //判断是否配置了显示模式,默认窗体为Show非模式显示 + string showDialog = (itemArray.Length > 2) ? itemArray[2].ToLower() : ""; + bool isShowDialog = (showDialog == "1") || (showDialog == "dialog"); + + string dllFullPath = Path.Combine(Application.StartupPath, filePath); + Assembly tempAssembly = System.Reflection.Assembly.LoadFrom(dllFullPath); + if (tempAssembly != null) + { + Type objType = tempAssembly.GetType(type); + ChildWinManagement.LoadMdiForm(mainform, objType); + } + } + catch (Exception ex) + { + ex.Message.ShowError(); + } + }; + flowLayoutPanel1.Controls.Add(btn); + } + } + } + } } \ No newline at end of file diff --git a/WinformGeneralDeveloperFrame/FrmsysDataBase.cs b/WinformGeneralDeveloperFrame/FrmsysDataBase.cs index b250786..6bf90a2 100644 --- a/WinformGeneralDeveloperFrame/FrmsysDataBase.cs +++ b/WinformGeneralDeveloperFrame/FrmsysDataBase.cs @@ -86,7 +86,7 @@ namespace MES.Form { con.sysDataBase.AddOrUpdate(dbEntity); con.SaveChanges(); - "ɹ".ShowWarning(); + "ɹ".ShowTips(); using (var db = new DB()) { grdList.DataSource = db.sysDataBase.ToList(); diff --git a/WinformGeneralDeveloperFrame/FrmsysDataBase.designer.cs b/WinformGeneralDeveloperFrame/FrmsysDataBase.designer.cs index 8d0ad1c..e142c13 100644 --- a/WinformGeneralDeveloperFrame/FrmsysDataBase.designer.cs +++ b/WinformGeneralDeveloperFrame/FrmsysDataBase.designer.cs @@ -152,10 +152,10 @@ namespace MES.Form // xtraTabControl1 // this.xtraTabControl1.Dock = System.Windows.Forms.DockStyle.Fill; - this.xtraTabControl1.Location = new System.Drawing.Point(0, 34); + this.xtraTabControl1.Location = new System.Drawing.Point(0, 0); this.xtraTabControl1.Name = "xtraTabControl1"; this.xtraTabControl1.SelectedTabPage = this.tabDataList; - this.xtraTabControl1.Size = new System.Drawing.Size(1300, 766); + this.xtraTabControl1.Size = new System.Drawing.Size(1300, 800); this.xtraTabControl1.TabIndex = 1; this.xtraTabControl1.TabPages.AddRange(new DevExpress.XtraTab.XtraTabPage[] { this.tabDataList, @@ -165,7 +165,7 @@ namespace MES.Form // this.tabDataList.Controls.Add(this.grdList); this.tabDataList.Name = "tabDataList"; - this.tabDataList.Size = new System.Drawing.Size(1294, 737); + this.tabDataList.Size = new System.Drawing.Size(1294, 771); this.tabDataList.Text = "数据列表"; // // grdList @@ -174,7 +174,7 @@ namespace MES.Form this.grdList.Location = new System.Drawing.Point(0, 0); this.grdList.MainView = this.grdListView; this.grdList.Name = "grdList"; - this.grdList.Size = new System.Drawing.Size(1294, 737); + this.grdList.Size = new System.Drawing.Size(1294, 771); this.grdList.TabIndex = 0; this.grdList.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] { this.grdListView}); @@ -198,7 +198,7 @@ namespace MES.Form // this.tabDataDetail.Controls.Add(this.panelControl2); this.tabDataDetail.Name = "tabDataDetail"; - this.tabDataDetail.Size = new System.Drawing.Size(1294, 737); + this.tabDataDetail.Size = new System.Drawing.Size(1294, 771); this.tabDataDetail.Text = "数据编辑"; // // panelControl2 @@ -207,7 +207,7 @@ namespace MES.Form this.panelControl2.Dock = System.Windows.Forms.DockStyle.Fill; this.panelControl2.Location = new System.Drawing.Point(0, 0); this.panelControl2.Name = "panelControl2"; - this.panelControl2.Size = new System.Drawing.Size(1294, 737); + this.panelControl2.Size = new System.Drawing.Size(1294, 771); this.panelControl2.TabIndex = 0; // // layoutControl1 @@ -225,7 +225,7 @@ namespace MES.Form this.layoutControl1.Location = new System.Drawing.Point(2, 2); this.layoutControl1.Name = "layoutControl1"; this.layoutControl1.Root = this.Root; - this.layoutControl1.Size = new System.Drawing.Size(1290, 733); + this.layoutControl1.Size = new System.Drawing.Size(1290, 767); this.layoutControl1.TabIndex = 0; this.layoutControl1.Text = "layoutControl1"; // @@ -325,7 +325,7 @@ namespace MES.Form this.layoutControlItem7, this.layoutControlItem8}); this.Root.Name = "Root"; - this.Root.Size = new System.Drawing.Size(1290, 733); + this.Root.Size = new System.Drawing.Size(1290, 767); this.Root.TextVisible = false; // // layoutControlItem1 @@ -388,7 +388,7 @@ namespace MES.Form this.emptySpaceItem1.AllowHotTrack = false; this.emptySpaceItem1.Location = new System.Drawing.Point(0, 170); this.emptySpaceItem1.Name = "emptySpaceItem1"; - this.emptySpaceItem1.Size = new System.Drawing.Size(1270, 543); + this.emptySpaceItem1.Size = new System.Drawing.Size(1270, 577); this.emptySpaceItem1.TextSize = new System.Drawing.Size(0, 0); // // layoutControlItem9 @@ -436,7 +436,6 @@ namespace MES.Form this.Name = "FrmsysDataBase"; this.Text = "数据源"; this.Load += new System.EventHandler(this.FrmsysDataBase_Load); - this.Controls.SetChildIndex(this.xtraTabControl1, 0); ((System.ComponentModel.ISupportInitialize)(this.xtraTabControl1)).EndInit(); this.xtraTabControl1.ResumeLayout(false); this.tabDataList.ResumeLayout(false); diff --git a/WinformGeneralDeveloperFrame/MainForm.Designer.cs b/WinformGeneralDeveloperFrame/MainForm.Designer.cs index a413fe5..0c242cf 100644 --- a/WinformGeneralDeveloperFrame/MainForm.Designer.cs +++ b/WinformGeneralDeveloperFrame/MainForm.Designer.cs @@ -37,21 +37,17 @@ namespace WinformGeneralDeveloperFrame this.barEditItem1 = new DevExpress.XtraBars.BarEditItem(); this.repositoryItemTimeEdit1 = new DevExpress.XtraEditors.Repository.RepositoryItemTimeEdit(); this.bsi_Date = new DevExpress.XtraBars.BarStaticItem(); + this.barListItem1 = new DevExpress.XtraBars.BarListItem(); + this.barUserName = new DevExpress.XtraBars.BarStaticItem(); + this.barStaticItem3 = new DevExpress.XtraBars.BarStaticItem(); this.ribbonPage1 = new DevExpress.XtraBars.Ribbon.RibbonPage(); this.ribbonPageGroup1 = new DevExpress.XtraBars.Ribbon.RibbonPageGroup(); this.ribbonStatusBar1 = new DevExpress.XtraBars.Ribbon.RibbonStatusBar(); this.xtraTabbedMdiManager1 = new DevExpress.XtraTabbedMdi.XtraTabbedMdiManager(this.components); this.navBarControl1 = new DevExpress.XtraNavBar.NavBarControl(); - this.navBarGroup1 = new DevExpress.XtraNavBar.NavBarGroup(); - this.navBarItem2 = new DevExpress.XtraNavBar.NavBarItem(); - this.navBarItem3 = new DevExpress.XtraNavBar.NavBarItem(); - this.navBarItem1 = new DevExpress.XtraNavBar.NavBarItem(); this.timer1 = new System.Windows.Forms.Timer(this.components); - this.barListItem1 = new DevExpress.XtraBars.BarListItem(); this.bsi_UserName = new DevExpress.XtraBars.BarStaticItem(); this.barStaticItem1 = new DevExpress.XtraBars.BarStaticItem(); - this.barUserName = new DevExpress.XtraBars.BarStaticItem(); - this.barStaticItem3 = new DevExpress.XtraBars.BarStaticItem(); ((System.ComponentModel.ISupportInitialize)(this.ribbonControl1)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.repositoryItemTimeEdit1)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.xtraTabbedMdiManager1)).BeginInit(); @@ -121,6 +117,27 @@ namespace WinformGeneralDeveloperFrame this.bsi_Date.Name = "bsi_Date"; this.bsi_Date.PaintStyle = DevExpress.XtraBars.BarItemPaintStyle.CaptionGlyph; // + // barListItem1 + // + this.barListItem1.Caption = "barListItem1"; + this.barListItem1.Id = 5; + this.barListItem1.Name = "barListItem1"; + // + // barUserName + // + this.barUserName.Caption = "用户名:admin"; + this.barUserName.Id = 6; + this.barUserName.ImageOptions.Image = global::WinformGeneralDeveloperFrame.Properties.Resources.bocustomer_16x16; + this.barUserName.ImageOptions.LargeImage = global::WinformGeneralDeveloperFrame.Properties.Resources.bocustomer_32x321; + this.barUserName.Name = "barUserName"; + this.barUserName.PaintStyle = DevExpress.XtraBars.BarItemPaintStyle.CaptionGlyph; + // + // barStaticItem3 + // + this.barStaticItem3.Caption = "barStaticItem3"; + this.barStaticItem3.Id = 7; + this.barStaticItem3.Name = "barStaticItem3"; + // // ribbonPage1 // this.ribbonPage1.Groups.AddRange(new DevExpress.XtraBars.Ribbon.RibbonPageGroup[] { @@ -148,15 +165,8 @@ namespace WinformGeneralDeveloperFrame // // navBarControl1 // - this.navBarControl1.ActiveGroup = this.navBarGroup1; this.navBarControl1.BorderStyle = DevExpress.XtraEditors.Controls.BorderStyles.HotFlat; this.navBarControl1.Dock = System.Windows.Forms.DockStyle.Left; - this.navBarControl1.Groups.AddRange(new DevExpress.XtraNavBar.NavBarGroup[] { - this.navBarGroup1}); - this.navBarControl1.Items.AddRange(new DevExpress.XtraNavBar.NavBarItem[] { - this.navBarItem1, - this.navBarItem2, - this.navBarItem3}); this.navBarControl1.Location = new System.Drawing.Point(0, 148); this.navBarControl1.Name = "navBarControl1"; this.navBarControl1.OptionsNavPane.ExpandedWidth = 184; @@ -166,50 +176,19 @@ namespace WinformGeneralDeveloperFrame this.navBarControl1.Text = "navBarControl1"; this.navBarControl1.View = new DevExpress.XtraNavBar.ViewInfo.StandardSkinNavigationPaneViewInfoRegistrator("Blue"); // - // navBarGroup1 - // - this.navBarGroup1.Caption = "系统管理"; - this.navBarGroup1.Expanded = true; - this.navBarGroup1.ItemLinks.AddRange(new DevExpress.XtraNavBar.NavBarItemLink[] { - new DevExpress.XtraNavBar.NavBarItemLink(this.navBarItem2), - new DevExpress.XtraNavBar.NavBarItemLink(this.navBarItem3), - new DevExpress.XtraNavBar.NavBarItemLink(this.navBarItem1)}); - this.navBarGroup1.Name = "navBarGroup1"; - // - // navBarItem2 - // - this.navBarItem2.Caption = "权限维护"; - this.navBarItem2.Name = "navBarItem2"; - // - // navBarItem3 - // - this.navBarItem3.Caption = "系统维护"; - this.navBarItem3.Name = "navBarItem3"; - // - // navBarItem1 - // - this.navBarItem1.Caption = "数据集维护"; - this.navBarItem1.Name = "navBarItem1"; - this.navBarItem1.LinkClicked += new DevExpress.XtraNavBar.NavBarLinkEventHandler(this.navBarItem1_LinkClicked); - // // timer1 // this.timer1.Enabled = true; this.timer1.Interval = 1000; this.timer1.Tick += new System.EventHandler(this.timer1_Tick); // - // barListItem1 - // - this.barListItem1.Caption = "barListItem1"; - this.barListItem1.Id = 5; - this.barListItem1.Name = "barListItem1"; - // // bsi_UserName // this.bsi_UserName.Caption = "用戶名: 管理員"; this.bsi_UserName.Id = 29; this.bsi_UserName.ImageOptions.Image = ((System.Drawing.Image)(resources.GetObject("bsi_UserName.ImageOptions.Image"))); this.bsi_UserName.Name = "bsi_UserName"; + this.bsi_UserName.PaintStyle = DevExpress.XtraBars.BarItemPaintStyle.CaptionGlyph; // // barStaticItem1 // @@ -217,20 +196,7 @@ namespace WinformGeneralDeveloperFrame this.barStaticItem1.Id = 29; this.barStaticItem1.ImageOptions.Image = ((System.Drawing.Image)(resources.GetObject("barStaticItem1.ImageOptions.Image"))); this.barStaticItem1.Name = "barStaticItem1"; - // - // barUserName - // - this.barUserName.Caption = "用户名:admin"; - this.barUserName.Id = 6; - this.barUserName.ImageOptions.Image = global::WinformGeneralDeveloperFrame.Properties.Resources.bocustomer_16x16; - this.barUserName.ImageOptions.LargeImage = global::WinformGeneralDeveloperFrame.Properties.Resources.bocustomer_32x321; - this.barUserName.Name = "barUserName"; - // - // barStaticItem3 - // - this.barStaticItem3.Caption = "barStaticItem3"; - this.barStaticItem3.Id = 7; - this.barStaticItem3.Name = "barStaticItem3"; + this.barStaticItem1.PaintStyle = DevExpress.XtraBars.BarItemPaintStyle.CaptionGlyph; // // MainForm // @@ -270,10 +236,6 @@ namespace WinformGeneralDeveloperFrame private DevExpress.XtraEditors.Repository.RepositoryItemTimeEdit repositoryItemTimeEdit1; private DevExpress.XtraBars.BarStaticItem bsi_Date; private System.Windows.Forms.Timer timer1; - private DevExpress.XtraNavBar.NavBarGroup navBarGroup1; - private DevExpress.XtraNavBar.NavBarItem navBarItem1; - private DevExpress.XtraNavBar.NavBarItem navBarItem2; - private DevExpress.XtraNavBar.NavBarItem navBarItem3; private DevExpress.XtraBars.BarListItem barListItem1; private DevExpress.XtraBars.BarStaticItem barUserName; private DevExpress.XtraBars.BarStaticItem barStaticItem3; diff --git a/WinformGeneralDeveloperFrame/MainForm.cs b/WinformGeneralDeveloperFrame/MainForm.cs index 386abe5..eb309ca 100644 --- a/WinformGeneralDeveloperFrame/MainForm.cs +++ b/WinformGeneralDeveloperFrame/MainForm.cs @@ -8,7 +8,9 @@ using System.Text; using System.Windows.Forms; using DevExpress.XtraBars.Helpers; using DevExpress.XtraNavBar; +using DevExpress.XtraSplashScreen; using MES; +using MES.Entity; using MES.Form; using WinformGeneralDeveloperFrame.Commons; @@ -34,7 +36,7 @@ namespace WinformGeneralDeveloperFrame { AppInfo.LoginUserInfo=db.sysUserInfo.ToList().First(); } - + Init(); barUserName.Caption = $"用户名:{AppInfo.LoginUserInfo.username}"; } @@ -45,10 +47,49 @@ namespace WinformGeneralDeveloperFrame bsi_Date.Caption = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"); } - private void navBarItem1_LinkClicked(object sender, DevExpress.XtraNavBar.NavBarLinkEventArgs e) + private void navBarItem1_LinkClicked(object sender, NavBarLinkEventArgs e) { NavBarItem navBarItem =sender as NavBarItem; - ChildWinManagement.LoadShowForm(this, typeof(FrmShowForm), navBarItem.Caption); + ChildWinManagement.LoadShowForm(this, typeof(FrmShowForm), navBarItem.Caption,1); } + + private void Init() + { + NarBarInit(); + } + + private void NarBarInit() + { + navBarControl1.Items.Clear(); + List menusList = new List(); + using (var db = new MESDB()) + { + menusList=db.sysMenuInfo.ToList(); + } + + foreach (var item in menusList) + { + if (item.pid == 0) + { + NavBarGroup gNavBarGroup = new NavBarGroup(item.name); + foreach (var itemInfo in menusList) + { + if (itemInfo.pid == item.id) + { + NavBarItem navBarItem = new NavBarItem(itemInfo.name); + navBarItem.LinkClicked += (sender, args) => + { + NavBarItem nav = sender as NavBarItem; + ChildWinManagement.LoadShowForm(this, typeof(FrmShowForm), nav.Caption, itemInfo.id); + }; + NavBarItemLink navBarItemLink = new NavBarItemLink(navBarItem); + gNavBarGroup.ItemLinks.Add(navBarItemLink); + } + } + navBarControl1.Groups.Add(gNavBarGroup); + } + } + } + } } diff --git a/WinformGeneralDeveloperFrame/Program.cs b/WinformGeneralDeveloperFrame/Program.cs index 199c1c2..00a5e8a 100644 --- a/WinformGeneralDeveloperFrame/Program.cs +++ b/WinformGeneralDeveloperFrame/Program.cs @@ -18,7 +18,7 @@ namespace WinformGeneralDeveloperFrame { DevExpress.Skins.SkinManager.EnableFormSkins(); UserLookAndFeel.Default.SetSkinStyle("Office 2010 Blue"); - + BonusSkins.Register(); Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); Application.Run(new MainForm()); diff --git a/WinformGeneralDeveloperFrame/Template/Winform/Form.vm b/WinformGeneralDeveloperFrame/Template/Winform/Form.vm index a1f5dbf..534ae44 100644 --- a/WinformGeneralDeveloperFrame/Template/Winform/Form.vm +++ b/WinformGeneralDeveloperFrame/Template/Winform/Form.vm @@ -23,9 +23,14 @@ namespace ${NameSpace}.Form } private void Frm${tableName}_Load(object sender, EventArgs e) { - + InitFrom(xtraTabControl1,grdList,grdListView,new LayoutControlGroup[]{layoutControlGroup1},new ${tableName}Info()); + InitSearchDicData(); } + /// + /// 数据源初始化 + /// + /// private void Init() { @@ -58,13 +63,25 @@ namespace ${NameSpace}.Form #end #end #end + + + } + /// + /// 搜索字段 + /// + /// + private void InitSearchDicData() + { #foreach($info in $EntityList) #if(${info.isSearch}) fieldDictionary.Add("${info.controlLabelName}","${info.dataBaseFieldName"); #end #end - - } + } + /// + /// 保存 + /// + /// public override bool SaveFunction() { try @@ -91,7 +108,10 @@ namespace ${NameSpace}.Form } Init(); } - + /// + /// 字段为空校验 + /// + /// public override bool CheckInput() { #foreach($info in $EntityList) @@ -106,6 +126,10 @@ namespace ${NameSpace}.Form #end return true; } + /// + /// 删除 + /// + /// public override bool DelFunction() { try @@ -124,5 +148,28 @@ namespace ${NameSpace}.Form } return true; } + /// + /// 搜索 + /// + /// + public override void SearchFunction() + { + FrmSearch frm = new FrmSearch(fieldDictionary); + if (frm.ShowDialog()==DialogResult.OK) + { + string sql = frm.sql; + using (var db = new ${NameSpace}DB()) + { + if (string.IsNullOrEmpty(sql)) + { + grdList.DataSource = db.${tableName}Info.SqlQuery("select * from ${tableName}").ToList(); + } + else + { + grdList.DataSource = db.${tableName}Info.SqlQuery($"select * from ${tableName} where {sql}").ToList(); + } + } + } + } } } \ No newline at end of file diff --git a/WinformGeneralDeveloperFrame/WinformGeneralDeveloperFrame.csproj b/WinformGeneralDeveloperFrame/WinformGeneralDeveloperFrame.csproj index eb6cb16..88d7275 100644 --- a/WinformGeneralDeveloperFrame/WinformGeneralDeveloperFrame.csproj +++ b/WinformGeneralDeveloperFrame/WinformGeneralDeveloperFrame.csproj @@ -5,7 +5,7 @@ 8.0.30703 2.0 {FCCDAF3A-FC3E-4F85-B794-2AAA299FBC45} - Exe + Library Properties WinformGeneralDeveloperFrame WinformGeneralDeveloperFrame @@ -120,6 +120,12 @@ + + UserControl + + + BaseForm.cs + @@ -226,6 +232,12 @@ XtraForm1.cs + + BaseForm.cs + + + FrmsysDictData.cs + FrmsysDictType.cs diff --git a/WinformGeneralDeveloperFrame/XtraForm1.cs b/WinformGeneralDeveloperFrame/XtraForm1.cs index 7fc62e9..c4c5dea 100644 --- a/WinformGeneralDeveloperFrame/XtraForm1.cs +++ b/WinformGeneralDeveloperFrame/XtraForm1.cs @@ -33,24 +33,24 @@ namespace WinformGeneralDeveloperFrame private void XtraForm1_Load(object sender, EventArgs e) { - using (var db =new Model1()) - { - grdList.DataSource = db.T_ACL_Menu.ToList(); - treeListLookUpEdit1.Properties.DataSource = GetDataTableUtils.SqlTable(""); - lookUpEdit1.Properties.DataSource = db.T_ACL_Menu.Select(p => new {p.Name, p.ID}).ToList(); - repositoryItemTreeListLookUpEdit1TreeList.DataSource = db.T_ACL_Menu.Select(p => new { p.Name, p.ID, p.PID }).ToList(); - repositoryItemTreeListLookUpEdit1.DataSource= db.T_ACL_Menu.Select(p => new { p.Name, p.ID, p.PID }).ToList(); - repositoryItemLookUpEdit1.DataSource= db.T_ACL_Menu.Select(p => new { p.Name, p.ID }).ToList(); - repositoryItemSearchLookUpEdit1.DataSource=db.T_ACL_Menu.Select(p => new { p.Name, p.ID }).ToList(); - searchLookUpEdit1.Properties.DataSource= db.T_ACL_Menu.Select(p => new { p.Name, p.ID }).ToList(); - checkedComboBoxEdit1.EditValue = "新增,复核"; - checkedComboBoxEdit1.Properties.DataSource= GetDataTableUtils.SqlTable("菜单tree"); - //comboBoxEdit1.Properties.Items.Add(db.T_ACL_Menu.Select(p => new { p.Name }).ToList()); - foreach (DataRow info in GetDataTableUtils.SqlTable("菜单tree").Rows) - { - comboBoxEdit1.Properties.Items.Add(info.ItemArray[2].ToString()); - } - } + //using (var db =new Model1()) + //{ + // grdList.DataSource = db.T_ACL_Menu.ToList(); + // treeListLookUpEdit1.Properties.DataSource = GetDataTableUtils.SqlTable(""); + // lookUpEdit1.Properties.DataSource = db.T_ACL_Menu.Select(p => new {p.Name, p.ID}).ToList(); + // repositoryItemTreeListLookUpEdit1TreeList.DataSource = db.T_ACL_Menu.Select(p => new { p.Name, p.ID, p.PID }).ToList(); + // repositoryItemTreeListLookUpEdit1.DataSource= db.T_ACL_Menu.Select(p => new { p.Name, p.ID, p.PID }).ToList(); + // repositoryItemLookUpEdit1.DataSource= db.T_ACL_Menu.Select(p => new { p.Name, p.ID }).ToList(); + // repositoryItemSearchLookUpEdit1.DataSource=db.T_ACL_Menu.Select(p => new { p.Name, p.ID }).ToList(); + // searchLookUpEdit1.Properties.DataSource= db.T_ACL_Menu.Select(p => new { p.Name, p.ID }).ToList(); + // checkedComboBoxEdit1.EditValue = "新增,复核"; + // checkedComboBoxEdit1.Properties.DataSource= GetDataTableUtils.SqlTable("菜单tree"); + // //comboBoxEdit1.Properties.Items.Add(db.T_ACL_Menu.Select(p => new { p.Name }).ToList()); + // foreach (DataRow info in GetDataTableUtils.SqlTable("菜单tree").Rows) + // { + // comboBoxEdit1.Properties.Items.Add(info.ItemArray[2].ToString()); + // } + //} //InitFrom(xtraTabControl1,grdList,grdListView,new LayoutControlGroup[]{Root},ne); }