personal inventory : 날짜 선택하도록 lov 추가

This commit is contained in:
chikyun.kim
2018-09-19 09:35:08 +09:00
parent 2d4fe18264
commit 481d6bf78d
13 changed files with 453 additions and 295 deletions

View File

@@ -30,6 +30,7 @@
{
this.components = new System.ComponentModel.Container();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(fLineCode));
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
this.bn = new System.Windows.Forms.BindingNavigator(this.components);
this.bindingNavigatorAddNewItem = new System.Windows.Forms.ToolStripButton();
this.bs = new System.Windows.Forms.BindingSource(this.components);
@@ -45,22 +46,20 @@
this.bindingNavigatorMoveLastItem = new System.Windows.Forms.ToolStripButton();
this.bindingNavigatorSeparator2 = new System.Windows.Forms.ToolStripSeparator();
this.lineCodeBindingNavigatorSaveItem = new System.Windows.Forms.ToolStripButton();
this.lineCodeDataGridView = new System.Windows.Forms.DataGridView();
this.dv = new System.Windows.Forms.DataGridView();
this.ta = new Project.dsMSSQLTableAdapters.LineCodeTableAdapter();
this.tam = new Project.dsMSSQLTableAdapters.TableAdapterManager();
this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.except = new System.Windows.Forms.DataGridViewCheckBoxColumn();
this.dataGridViewTextBoxColumn5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn6 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn7 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.ta = new Project.dsMSSQLTableAdapters.LineCodeTableAdapter();
this.tam = new Project.dsMSSQLTableAdapters.TableAdapterManager();
((System.ComponentModel.ISupportInitialize)(this.bn)).BeginInit();
this.bn.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.bs)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.dsMSSQL)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.lineCodeDataGridView)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.dv)).BeginInit();
this.SuspendLayout();
//
// bn
@@ -69,6 +68,7 @@
this.bn.BindingSource = this.bs;
this.bn.CountItem = this.bindingNavigatorCountItem;
this.bn.DeleteItem = this.bindingNavigatorDeleteItem;
this.bn.Dock = System.Windows.Forms.DockStyle.Bottom;
this.bn.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.bindingNavigatorMoveFirstItem,
this.bindingNavigatorMovePreviousItem,
@@ -82,14 +82,14 @@
this.bindingNavigatorAddNewItem,
this.bindingNavigatorDeleteItem,
this.lineCodeBindingNavigatorSaveItem});
this.bn.Location = new System.Drawing.Point(0, 0);
this.bn.Location = new System.Drawing.Point(0, 392);
this.bn.MoveFirstItem = this.bindingNavigatorMoveFirstItem;
this.bn.MoveLastItem = this.bindingNavigatorMoveLastItem;
this.bn.MoveNextItem = this.bindingNavigatorMoveNextItem;
this.bn.MovePreviousItem = this.bindingNavigatorMovePreviousItem;
this.bn.Name = "bn";
this.bn.PositionItem = this.bindingNavigatorPositionItem;
this.bn.Size = new System.Drawing.Size(603, 25);
this.bn.Size = new System.Drawing.Size(588, 25);
this.bn.TabIndex = 0;
this.bn.Text = "bindingNavigator1";
//
@@ -197,32 +197,47 @@
this.lineCodeBindingNavigatorSaveItem.Text = "데이터 저장";
this.lineCodeBindingNavigatorSaveItem.Click += new System.EventHandler(this.lineCodeBindingNavigatorSaveItem_Click);
//
// lineCodeDataGridView
// dv
//
this.lineCodeDataGridView.AutoGenerateColumns = false;
this.lineCodeDataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.AllCells;
this.lineCodeDataGridView.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.lineCodeDataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.lineCodeDataGridView.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.dv.AllowUserToAddRows = false;
this.dv.AutoGenerateColumns = false;
this.dv.ColumnHeadersHeight = 30;
this.dv.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
this.dv.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.dataGridViewTextBoxColumn1,
this.dataGridViewTextBoxColumn2,
this.dataGridViewTextBoxColumn3,
this.dataGridViewTextBoxColumn4,
this.except,
this.dataGridViewTextBoxColumn5,
this.dataGridViewTextBoxColumn6,
this.dataGridViewTextBoxColumn7});
this.lineCodeDataGridView.DataSource = this.bs;
this.lineCodeDataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
this.lineCodeDataGridView.Location = new System.Drawing.Point(0, 25);
this.lineCodeDataGridView.Name = "lineCodeDataGridView";
this.lineCodeDataGridView.RowTemplate.Height = 23;
this.lineCodeDataGridView.Size = new System.Drawing.Size(603, 313);
this.lineCodeDataGridView.TabIndex = 1;
this.dataGridViewTextBoxColumn5});
this.dv.DataSource = this.bs;
this.dv.Dock = System.Windows.Forms.DockStyle.Fill;
this.dv.Location = new System.Drawing.Point(0, 0);
this.dv.Name = "dv";
this.dv.RowTemplate.Height = 23;
this.dv.Size = new System.Drawing.Size(588, 392);
this.dv.TabIndex = 1;
//
// ta
//
this.ta.ClearBeforeFill = true;
//
// tam
//
this.tam.BackupDataSetBeforeUpdate = false;
this.tam.InventoryTableAdapter = null;
this.tam.ItemsTableAdapter = null;
this.tam.LineCodeTableAdapter = this.ta;
this.tam.ProjectsTableAdapter = null;
this.tam.UpdateOrder = Project.dsMSSQLTableAdapters.TableAdapterManager.UpdateOrderOption.InsertUpdateDelete;
this.tam.UsersTableAdapter = null;
//
// dataGridViewTextBoxColumn1
//
this.dataGridViewTextBoxColumn1.DataPropertyName = "idx";
dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224)))));
this.dataGridViewTextBoxColumn1.DefaultCellStyle = dataGridViewCellStyle1;
this.dataGridViewTextBoxColumn1.HeaderText = "idx";
this.dataGridViewTextBoxColumn1.Name = "dataGridViewTextBoxColumn1";
this.dataGridViewTextBoxColumn1.ReadOnly = true;
@@ -263,40 +278,12 @@
this.dataGridViewTextBoxColumn5.Name = "dataGridViewTextBoxColumn5";
this.dataGridViewTextBoxColumn5.Width = 66;
//
// dataGridViewTextBoxColumn6
//
this.dataGridViewTextBoxColumn6.DataPropertyName = "wuid";
this.dataGridViewTextBoxColumn6.HeaderText = "wuid";
this.dataGridViewTextBoxColumn6.Name = "dataGridViewTextBoxColumn6";
this.dataGridViewTextBoxColumn6.Width = 57;
//
// dataGridViewTextBoxColumn7
//
this.dataGridViewTextBoxColumn7.DataPropertyName = "wdate";
this.dataGridViewTextBoxColumn7.HeaderText = "wdate";
this.dataGridViewTextBoxColumn7.Name = "dataGridViewTextBoxColumn7";
this.dataGridViewTextBoxColumn7.Width = 64;
//
// ta
//
this.ta.ClearBeforeFill = true;
//
// tam
//
this.tam.BackupDataSetBeforeUpdate = false;
this.tam.InventoryTableAdapter = null;
this.tam.ItemsTableAdapter = null;
this.tam.LineCodeTableAdapter = this.ta;
this.tam.ProjectsTableAdapter = null;
this.tam.UpdateOrder = Project.dsMSSQLTableAdapters.TableAdapterManager.UpdateOrderOption.InsertUpdateDelete;
this.tam.UsersTableAdapter = null;
//
// fLineCode
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(603, 338);
this.Controls.Add(this.lineCodeDataGridView);
this.ClientSize = new System.Drawing.Size(588, 417);
this.Controls.Add(this.dv);
this.Controls.Add(this.bn);
this.Name = "fLineCode";
this.Text = "fLineCode";
@@ -306,7 +293,7 @@
this.bn.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.bs)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.dsMSSQL)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.lineCodeDataGridView)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.dv)).EndInit();
this.ResumeLayout(false);
this.PerformLayout();
@@ -331,14 +318,12 @@
private System.Windows.Forms.ToolStripButton bindingNavigatorMoveLastItem;
private System.Windows.Forms.ToolStripSeparator bindingNavigatorSeparator2;
private System.Windows.Forms.ToolStripButton lineCodeBindingNavigatorSaveItem;
private System.Windows.Forms.DataGridView lineCodeDataGridView;
private System.Windows.Forms.DataGridView dv;
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn1;
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn2;
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn3;
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn4;
private System.Windows.Forms.DataGridViewCheckBoxColumn except;
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn5;
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn6;
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn7;
}
}

View File

@@ -14,6 +14,13 @@ namespace Project._Management
public fLineCode()
{
InitializeComponent();
this.FormClosed += fLineCode_FormClosed;
}
void fLineCode_FormClosed(object sender, FormClosedEventArgs e)
{
var form = this as Form;
FCOMMON.Util.SetFormStatus(ref form, this.Name, false);
}
private void lineCodeBindingNavigatorSaveItem_Click(object sender, EventArgs e)
@@ -26,10 +33,17 @@ namespace Project._Management
private void fLineCode_Load(object sender, EventArgs e)
{
// TODO: 이 코드는 데이터를 'dsMSSQL.LineCode' 테이블에 로드합니다. 필요한 경우 이 코드를 이동하거나 제거할 수 있습니다.
var form = this as Form;
FCOMMON.Util.SetFormStatus(ref form, this.Name, true);
this.Show();
Application.DoEvents();
this.ta.Fill(this.dsMSSQL.LineCode);
this.dsMSSQL.LineCode.TableNewRow += LineCode_TableNewRow;
}
void LineCode_TableNewRow(object sender, DataTableNewRowEventArgs e)