слияние
This commit is contained in:
commit
7262553726
@ -6,7 +6,6 @@ public class Materials
|
|||||||
public int Id { get; set; }
|
public int Id { get; set; }
|
||||||
public DateTime DateMaterials { get; set; }
|
public DateTime DateMaterials { get; set; }
|
||||||
public int Count { get; set; }
|
public int Count { get; set; }
|
||||||
|
|
||||||
public TypeMaterials Material { get; set; }
|
public TypeMaterials Material { get; set; }
|
||||||
|
|
||||||
public static Materials CreateEntity(int id, DateTime dateMaterials, int count, TypeMaterials typeMaterials)
|
public static Materials CreateEntity(int id, DateTime dateMaterials, int count, TypeMaterials typeMaterials)
|
||||||
|
@ -12,11 +12,11 @@ public class PrintingHouses
|
|||||||
|
|
||||||
public int MaterialsId { get; set; }
|
public int MaterialsId { get; set; }
|
||||||
|
|
||||||
public DateTime Date { get; set; }
|
public DateTime Date { get; set; }
|
||||||
|
|
||||||
public IEnumerable<PrintingHouseOrders> printingHouseOrder { get; set; } = [];
|
public IEnumerable<PrintingHouseOrders> printingHouseOrder { get; set; } = [];
|
||||||
|
|
||||||
public static PrintingHouses CreateEntity(int id, string title, string phone, string address,int materialsId, IEnumerable<PrintingHouseOrders> printingHouseOrders)
|
public static PrintingHouses CreateEntity(int id, string title, string phone, string address, int materialsId, IEnumerable<PrintingHouseOrders> printingHouseOrders)
|
||||||
{
|
{
|
||||||
|
|
||||||
return new PrintingHouses
|
return new PrintingHouses
|
||||||
@ -25,7 +25,7 @@ public class PrintingHouses
|
|||||||
Title = title,
|
Title = title,
|
||||||
Phone = phone,
|
Phone = phone,
|
||||||
Address = address,
|
Address = address,
|
||||||
MaterialsId=materialsId,
|
MaterialsId = materialsId,
|
||||||
Date = DateTime.Now,
|
Date = DateTime.Now,
|
||||||
printingHouseOrder = printingHouseOrders
|
printingHouseOrder = printingHouseOrders
|
||||||
};
|
};
|
||||||
|
44
Publication/Forms/FormCustomers.Designer.cs
generated
44
Publication/Forms/FormCustomers.Designer.cs
generated
@ -33,9 +33,9 @@
|
|||||||
buttonDelete = new Button();
|
buttonDelete = new Button();
|
||||||
buttonEdit = new Button();
|
buttonEdit = new Button();
|
||||||
buttonAdd = new Button();
|
buttonAdd = new Button();
|
||||||
dataGridView1 = new DataGridView();
|
dataGridView = new DataGridView();
|
||||||
panel1.SuspendLayout();
|
panel1.SuspendLayout();
|
||||||
((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit();
|
((System.ComponentModel.ISupportInitialize)dataGridView).BeginInit();
|
||||||
SuspendLayout();
|
SuspendLayout();
|
||||||
//
|
//
|
||||||
// panel1
|
// panel1
|
||||||
@ -82,38 +82,38 @@
|
|||||||
buttonAdd.UseVisualStyleBackColor = true;
|
buttonAdd.UseVisualStyleBackColor = true;
|
||||||
buttonAdd.Click += buttonAdd_Click;
|
buttonAdd.Click += buttonAdd_Click;
|
||||||
//
|
//
|
||||||
// dataGridView1
|
// dataGridView
|
||||||
//
|
//
|
||||||
dataGridView1.AllowUserToAddRows = false;
|
dataGridView.AllowUserToAddRows = false;
|
||||||
dataGridView1.AllowUserToDeleteRows = false;
|
dataGridView.AllowUserToDeleteRows = false;
|
||||||
dataGridView1.AllowUserToResizeColumns = false;
|
dataGridView.AllowUserToResizeColumns = false;
|
||||||
dataGridView1.AllowUserToResizeRows = false;
|
dataGridView.AllowUserToResizeRows = false;
|
||||||
dataGridView1.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.Fill;
|
dataGridView.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.Fill;
|
||||||
dataGridView1.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
dataGridView.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
||||||
dataGridView1.Dock = DockStyle.Fill;
|
dataGridView.Dock = DockStyle.Fill;
|
||||||
dataGridView1.Location = new Point(0, 0);
|
dataGridView.Location = new Point(0, 0);
|
||||||
dataGridView1.MultiSelect = false;
|
dataGridView.MultiSelect = false;
|
||||||
dataGridView1.Name = "dataGridView1";
|
dataGridView.Name = "dataGridView";
|
||||||
dataGridView1.ReadOnly = true;
|
dataGridView.ReadOnly = true;
|
||||||
dataGridView1.RowHeadersVisible = false;
|
dataGridView.RowHeadersVisible = false;
|
||||||
dataGridView1.RowHeadersWidth = 51;
|
dataGridView.RowHeadersWidth = 51;
|
||||||
dataGridView1.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
|
dataGridView.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
|
||||||
dataGridView1.Size = new Size(603, 450);
|
dataGridView.Size = new Size(603, 450);
|
||||||
dataGridView1.TabIndex = 1;
|
dataGridView.TabIndex = 1;
|
||||||
//
|
//
|
||||||
// FormCustomers
|
// FormCustomers
|
||||||
//
|
//
|
||||||
AutoScaleDimensions = new SizeF(8F, 20F);
|
AutoScaleDimensions = new SizeF(8F, 20F);
|
||||||
AutoScaleMode = AutoScaleMode.Font;
|
AutoScaleMode = AutoScaleMode.Font;
|
||||||
ClientSize = new Size(800, 450);
|
ClientSize = new Size(800, 450);
|
||||||
Controls.Add(dataGridView1);
|
Controls.Add(dataGridView);
|
||||||
Controls.Add(panel1);
|
Controls.Add(panel1);
|
||||||
Name = "FormCustomers";
|
Name = "FormCustomers";
|
||||||
StartPosition = FormStartPosition.CenterScreen;
|
StartPosition = FormStartPosition.CenterScreen;
|
||||||
Text = "Заказчики";
|
Text = "Заказчики";
|
||||||
Load += FormCustomers_Load;
|
Load += FormCustomers_Load;
|
||||||
panel1.ResumeLayout(false);
|
panel1.ResumeLayout(false);
|
||||||
((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit();
|
((System.ComponentModel.ISupportInitialize)dataGridView).EndInit();
|
||||||
ResumeLayout(false);
|
ResumeLayout(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -123,6 +123,6 @@
|
|||||||
private Button buttonDelete;
|
private Button buttonDelete;
|
||||||
private Button buttonEdit;
|
private Button buttonEdit;
|
||||||
private Button buttonAdd;
|
private Button buttonAdd;
|
||||||
private DataGridView dataGridView1;
|
private DataGridView dataGridView;
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -94,7 +94,7 @@ public partial class FormCustomers : Form
|
|||||||
private bool TryGetIdentifierFromSelectedRow(out int id)
|
private bool TryGetIdentifierFromSelectedRow(out int id)
|
||||||
{
|
{
|
||||||
id = 0;
|
id = 0;
|
||||||
if (dataGridView1.SelectedRows.Count < 1)
|
if (dataGridView.SelectedRows.Count < 1)
|
||||||
{
|
{
|
||||||
MessageBox.Show("Нет выбранной записи", "Ошибка",
|
MessageBox.Show("Нет выбранной записи", "Ошибка",
|
||||||
MessageBoxButtons.OK, MessageBoxIcon.Error);
|
MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||||
@ -102,9 +102,9 @@ public partial class FormCustomers : Form
|
|||||||
}
|
}
|
||||||
|
|
||||||
id =
|
id =
|
||||||
Convert.ToInt32(dataGridView1.SelectedRows[0].Cells["Id"].Value);
|
Convert.ToInt32(dataGridView.SelectedRows[0].Cells["Id"].Value);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void LoadList() => dataGridView1.DataSource = customerRepository.ReadCustomers();
|
private void LoadList() => dataGridView.DataSource = customerRepository.ReadCustomers();
|
||||||
}
|
}
|
||||||
|
File diff suppressed because it is too large
Load Diff
18
Publication/Forms/FormMaterial.Designer.cs
generated
18
Publication/Forms/FormMaterial.Designer.cs
generated
@ -31,7 +31,7 @@
|
|||||||
labelDateMaterials = new Label();
|
labelDateMaterials = new Label();
|
||||||
labelCount = new Label();
|
labelCount = new Label();
|
||||||
labelTypeMaterials = new Label();
|
labelTypeMaterials = new Label();
|
||||||
checkedListBox1 = new CheckedListBox();
|
checkedListBox = new CheckedListBox();
|
||||||
dateTimePickerDateMaterial = new DateTimePicker();
|
dateTimePickerDateMaterial = new DateTimePicker();
|
||||||
numericUpDownCount = new NumericUpDown();
|
numericUpDownCount = new NumericUpDown();
|
||||||
buttonSave = new Button();
|
buttonSave = new Button();
|
||||||
@ -66,13 +66,13 @@
|
|||||||
labelTypeMaterials.TabIndex = 2;
|
labelTypeMaterials.TabIndex = 2;
|
||||||
labelTypeMaterials.Text = "Тип материала";
|
labelTypeMaterials.Text = "Тип материала";
|
||||||
//
|
//
|
||||||
// checkedListBox1
|
// checkedListBox
|
||||||
//
|
//
|
||||||
checkedListBox1.FormattingEnabled = true;
|
checkedListBox.FormattingEnabled = true;
|
||||||
checkedListBox1.Location = new Point(168, 140);
|
checkedListBox.Location = new Point(168, 140);
|
||||||
checkedListBox1.Name = "checkedListBox1";
|
checkedListBox.Name = "checkedListBox";
|
||||||
checkedListBox1.Size = new Size(164, 114);
|
checkedListBox.Size = new Size(164, 114);
|
||||||
checkedListBox1.TabIndex = 3;
|
checkedListBox.TabIndex = 3;
|
||||||
//
|
//
|
||||||
// dateTimePickerDateMaterial
|
// dateTimePickerDateMaterial
|
||||||
//
|
//
|
||||||
@ -119,7 +119,7 @@
|
|||||||
Controls.Add(buttonSave);
|
Controls.Add(buttonSave);
|
||||||
Controls.Add(numericUpDownCount);
|
Controls.Add(numericUpDownCount);
|
||||||
Controls.Add(dateTimePickerDateMaterial);
|
Controls.Add(dateTimePickerDateMaterial);
|
||||||
Controls.Add(checkedListBox1);
|
Controls.Add(checkedListBox);
|
||||||
Controls.Add(labelTypeMaterials);
|
Controls.Add(labelTypeMaterials);
|
||||||
Controls.Add(labelCount);
|
Controls.Add(labelCount);
|
||||||
Controls.Add(labelDateMaterials);
|
Controls.Add(labelDateMaterials);
|
||||||
@ -136,7 +136,7 @@
|
|||||||
private Label labelDateMaterials;
|
private Label labelDateMaterials;
|
||||||
private Label labelCount;
|
private Label labelCount;
|
||||||
private Label labelTypeMaterials;
|
private Label labelTypeMaterials;
|
||||||
private CheckedListBox checkedListBox1;
|
private CheckedListBox checkedListBox;
|
||||||
private DateTimePicker dateTimePickerDateMaterial;
|
private DateTimePicker dateTimePickerDateMaterial;
|
||||||
private NumericUpDown numericUpDownCount;
|
private NumericUpDown numericUpDownCount;
|
||||||
private Button buttonSave;
|
private Button buttonSave;
|
||||||
|
@ -37,7 +37,7 @@ public partial class FormMaterial : Form
|
|||||||
if ((elem & material.Material) != 0)
|
if ((elem & material.Material) != 0)
|
||||||
{
|
{
|
||||||
|
|
||||||
checkedListBox1.SetItemChecked(checkedListBox1.Items.IndexOf(elem), true);
|
checkedListBox.SetItemChecked(checkedListBox.Items.IndexOf(elem), true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
MessageBox.Show(material.DateMaterials.ToString());
|
MessageBox.Show(material.DateMaterials.ToString());
|
||||||
@ -59,7 +59,7 @@ MessageBoxButtons.OK, MessageBoxIcon.Error);
|
|||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
foreach (var item in Enum.GetValues(typeof(TypeMaterials)))
|
foreach (var item in Enum.GetValues(typeof(TypeMaterials)))
|
||||||
{
|
{
|
||||||
checkedListBox1.Items.Add(item);
|
checkedListBox.Items.Add(item);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -97,7 +97,7 @@ MessageBoxButtons.OK, MessageBoxIcon.Error);
|
|||||||
private Materials CreateMaterials(int id)
|
private Materials CreateMaterials(int id)
|
||||||
{
|
{
|
||||||
TypeMaterials typeMaterials = TypeMaterials.None;
|
TypeMaterials typeMaterials = TypeMaterials.None;
|
||||||
foreach (var elem in checkedListBox1.CheckedItems)
|
foreach (var elem in checkedListBox.CheckedItems)
|
||||||
{
|
{
|
||||||
typeMaterials |= (TypeMaterials)elem;
|
typeMaterials |= (TypeMaterials)elem;
|
||||||
}
|
}
|
||||||
|
44
Publication/Forms/FormMaterials.Designer.cs
generated
44
Publication/Forms/FormMaterials.Designer.cs
generated
@ -33,9 +33,9 @@
|
|||||||
buttonDelete = new Button();
|
buttonDelete = new Button();
|
||||||
buttonEdit = new Button();
|
buttonEdit = new Button();
|
||||||
buttonAdd = new Button();
|
buttonAdd = new Button();
|
||||||
dataGridView1 = new DataGridView();
|
dataGridView = new DataGridView();
|
||||||
panel1.SuspendLayout();
|
panel1.SuspendLayout();
|
||||||
((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit();
|
((System.ComponentModel.ISupportInitialize)dataGridView).BeginInit();
|
||||||
SuspendLayout();
|
SuspendLayout();
|
||||||
//
|
//
|
||||||
// panel1
|
// panel1
|
||||||
@ -82,38 +82,38 @@
|
|||||||
buttonAdd.UseVisualStyleBackColor = true;
|
buttonAdd.UseVisualStyleBackColor = true;
|
||||||
buttonAdd.Click += buttonAdd_Click;
|
buttonAdd.Click += buttonAdd_Click;
|
||||||
//
|
//
|
||||||
// dataGridView1
|
// dataGridView
|
||||||
//
|
//
|
||||||
dataGridView1.AllowUserToAddRows = false;
|
dataGridView.AllowUserToAddRows = false;
|
||||||
dataGridView1.AllowUserToDeleteRows = false;
|
dataGridView.AllowUserToDeleteRows = false;
|
||||||
dataGridView1.AllowUserToResizeColumns = false;
|
dataGridView.AllowUserToResizeColumns = false;
|
||||||
dataGridView1.AllowUserToResizeRows = false;
|
dataGridView.AllowUserToResizeRows = false;
|
||||||
dataGridView1.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.Fill;
|
dataGridView.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.Fill;
|
||||||
dataGridView1.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
dataGridView.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
||||||
dataGridView1.Dock = DockStyle.Fill;
|
dataGridView.Dock = DockStyle.Fill;
|
||||||
dataGridView1.Location = new Point(0, 0);
|
dataGridView.Location = new Point(0, 0);
|
||||||
dataGridView1.MultiSelect = false;
|
dataGridView.MultiSelect = false;
|
||||||
dataGridView1.Name = "dataGridView1";
|
dataGridView.Name = "dataGridView";
|
||||||
dataGridView1.ReadOnly = true;
|
dataGridView.ReadOnly = true;
|
||||||
dataGridView1.RowHeadersVisible = false;
|
dataGridView.RowHeadersVisible = false;
|
||||||
dataGridView1.RowHeadersWidth = 51;
|
dataGridView.RowHeadersWidth = 51;
|
||||||
dataGridView1.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
|
dataGridView.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
|
||||||
dataGridView1.Size = new Size(603, 450);
|
dataGridView.Size = new Size(603, 450);
|
||||||
dataGridView1.TabIndex = 2;
|
dataGridView.TabIndex = 2;
|
||||||
//
|
//
|
||||||
// FormMaterials
|
// FormMaterials
|
||||||
//
|
//
|
||||||
AutoScaleDimensions = new SizeF(8F, 20F);
|
AutoScaleDimensions = new SizeF(8F, 20F);
|
||||||
AutoScaleMode = AutoScaleMode.Font;
|
AutoScaleMode = AutoScaleMode.Font;
|
||||||
ClientSize = new Size(800, 450);
|
ClientSize = new Size(800, 450);
|
||||||
Controls.Add(dataGridView1);
|
Controls.Add(dataGridView);
|
||||||
Controls.Add(panel1);
|
Controls.Add(panel1);
|
||||||
Name = "FormMaterials";
|
Name = "FormMaterials";
|
||||||
StartPosition = FormStartPosition.CenterScreen;
|
StartPosition = FormStartPosition.CenterScreen;
|
||||||
Text = "Материалы";
|
Text = "Материалы";
|
||||||
Load += FormMaterials_Load;
|
Load += FormMaterials_Load;
|
||||||
panel1.ResumeLayout(false);
|
panel1.ResumeLayout(false);
|
||||||
((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit();
|
((System.ComponentModel.ISupportInitialize)dataGridView).EndInit();
|
||||||
ResumeLayout(false);
|
ResumeLayout(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -123,6 +123,6 @@
|
|||||||
private Button buttonDelete;
|
private Button buttonDelete;
|
||||||
private Button buttonEdit;
|
private Button buttonEdit;
|
||||||
private Button buttonAdd;
|
private Button buttonAdd;
|
||||||
private DataGridView dataGridView1;
|
private DataGridView dataGridView;
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -40,7 +40,6 @@ public partial class FormMaterials : Form
|
|||||||
{
|
{
|
||||||
if (!TryGetIdentifierFromSelectedRow(out var findId))
|
if (!TryGetIdentifierFromSelectedRow(out var findId))
|
||||||
{
|
{
|
||||||
MessageBox.Show("Привет", "Привет");
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
try
|
try
|
||||||
@ -93,18 +92,18 @@ public partial class FormMaterials : Form
|
|||||||
private bool TryGetIdentifierFromSelectedRow(out int id)
|
private bool TryGetIdentifierFromSelectedRow(out int id)
|
||||||
{
|
{
|
||||||
id = 0;
|
id = 0;
|
||||||
if (dataGridView1.SelectedRows.Count < 1)
|
if (dataGridView.SelectedRows.Count < 1)
|
||||||
{
|
{
|
||||||
MessageBox.Show("Нет выбранной записи", "Ошибка",
|
MessageBox.Show("Нет выбранной записи", "Ошибка",
|
||||||
MessageBoxButtons.OK, MessageBoxIcon.Error);
|
MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
id =Convert.ToInt32(dataGridView1.SelectedRows[0].Cells["Id"].Value);
|
id =Convert.ToInt32(dataGridView.SelectedRows[0].Cells["Id"].Value);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void LoadList() => dataGridView1.DataSource = materialRepository.ReadMaterials();
|
private void LoadList() => dataGridView.DataSource = materialRepository.ReadMaterials();
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -2360,7 +2360,7 @@
|
|||||||
<data name="buttonEdit.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
<data name="buttonEdit.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
<value>
|
<value>
|
||||||
iVBORw0KGgoAAAANSUhEUgAAA+gAAAPoCAYAAABNo9TkAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAj
|
iVBORw0KGgoAAAANSUhEUgAAA+gAAAPoCAYAAABNo9TkAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAj
|
||||||
kgAAI5IBPeKSzAAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAALoxSURBVHhe7N13
|
kwAAI5MB76VwKAAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAALoxSURBVHhe7N13
|
||||||
gBTl/cfxn70nsZvEksQkliTG3nvBXqLGEnvvvfeuKIgiKtWOoFQbiIqI2LGj9OOOdvTeQeT5fZ/ZnWNu
|
gBTl/cfxn70nsZvEksQkliTG3nvBXqLGEnvvvfeuKIgiKtWOoFQbiIqI2LGj9OOOdvTeQeT5fZ/ZnWNu
|
||||||
73vH3s7u7Dwz7z9e2b3PbtgF7mZ4e2X/zxgDAAAAAA1a9uST64vdxRniHvHKr08++aWY5HniiTFiuPhx
|
73vH3s7u7Dwz7z9e2b3PbtgF7mZ4e2X/zxgDAAAAAA1a9uST64vdxRniHvHKr08++aWY5HniiTFiuPhx
|
||||||
6RNPfCUGiPdE+6UtWlwrmvzSosXm2q8NIEMdAQAAAMC0bLnOspYtz5EY/1iYIIny5Z54ooYEeW0tWngk
|
6RNPfCUGiPdE+6UtWlwrmvzSosXm2q8NIEMdAQAAAMC0bLnOspYtz5EY/1iYIIny5Z54ooYEeW0tWngk
|
||||||
|
44
Publication/Forms/FormOrders.Designer.cs
generated
44
Publication/Forms/FormOrders.Designer.cs
generated
@ -31,9 +31,9 @@
|
|||||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FormOrders));
|
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FormOrders));
|
||||||
panel1 = new Panel();
|
panel1 = new Panel();
|
||||||
buttonAdd = new Button();
|
buttonAdd = new Button();
|
||||||
dataGridView1 = new DataGridView();
|
dataGridView = new DataGridView();
|
||||||
panel1.SuspendLayout();
|
panel1.SuspendLayout();
|
||||||
((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit();
|
((System.ComponentModel.ISupportInitialize)dataGridView).BeginInit();
|
||||||
SuspendLayout();
|
SuspendLayout();
|
||||||
//
|
//
|
||||||
// panel1
|
// panel1
|
||||||
@ -56,38 +56,38 @@
|
|||||||
buttonAdd.UseVisualStyleBackColor = true;
|
buttonAdd.UseVisualStyleBackColor = true;
|
||||||
buttonAdd.Click += buttonAdd_Click;
|
buttonAdd.Click += buttonAdd_Click;
|
||||||
//
|
//
|
||||||
// dataGridView1
|
// dataGridView
|
||||||
//
|
//
|
||||||
dataGridView1.AllowUserToAddRows = false;
|
dataGridView.AllowUserToAddRows = false;
|
||||||
dataGridView1.AllowUserToDeleteRows = false;
|
dataGridView.AllowUserToDeleteRows = false;
|
||||||
dataGridView1.AllowUserToResizeColumns = false;
|
dataGridView.AllowUserToResizeColumns = false;
|
||||||
dataGridView1.AllowUserToResizeRows = false;
|
dataGridView.AllowUserToResizeRows = false;
|
||||||
dataGridView1.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.Fill;
|
dataGridView.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.Fill;
|
||||||
dataGridView1.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
dataGridView.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
||||||
dataGridView1.Dock = DockStyle.Fill;
|
dataGridView.Dock = DockStyle.Fill;
|
||||||
dataGridView1.Location = new Point(0, 0);
|
dataGridView.Location = new Point(0, 0);
|
||||||
dataGridView1.MultiSelect = false;
|
dataGridView.MultiSelect = false;
|
||||||
dataGridView1.Name = "dataGridView1";
|
dataGridView.Name = "dataGridView";
|
||||||
dataGridView1.ReadOnly = true;
|
dataGridView.ReadOnly = true;
|
||||||
dataGridView1.RowHeadersVisible = false;
|
dataGridView.RowHeadersVisible = false;
|
||||||
dataGridView1.RowHeadersWidth = 51;
|
dataGridView.RowHeadersWidth = 51;
|
||||||
dataGridView1.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
|
dataGridView.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
|
||||||
dataGridView1.Size = new Size(603, 450);
|
dataGridView.Size = new Size(603, 450);
|
||||||
dataGridView1.TabIndex = 3;
|
dataGridView.TabIndex = 3;
|
||||||
//
|
//
|
||||||
// FormOrders
|
// FormOrders
|
||||||
//
|
//
|
||||||
AutoScaleDimensions = new SizeF(8F, 20F);
|
AutoScaleDimensions = new SizeF(8F, 20F);
|
||||||
AutoScaleMode = AutoScaleMode.Font;
|
AutoScaleMode = AutoScaleMode.Font;
|
||||||
ClientSize = new Size(800, 450);
|
ClientSize = new Size(800, 450);
|
||||||
Controls.Add(dataGridView1);
|
Controls.Add(dataGridView);
|
||||||
Controls.Add(panel1);
|
Controls.Add(panel1);
|
||||||
Name = "FormOrders";
|
Name = "FormOrders";
|
||||||
StartPosition = FormStartPosition.CenterScreen;
|
StartPosition = FormStartPosition.CenterScreen;
|
||||||
Text = "Заказы";
|
Text = "Заказы";
|
||||||
Load += FormOrders_Load;
|
Load += FormOrders_Load;
|
||||||
panel1.ResumeLayout(false);
|
panel1.ResumeLayout(false);
|
||||||
((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit();
|
((System.ComponentModel.ISupportInitialize)dataGridView).EndInit();
|
||||||
ResumeLayout(false);
|
ResumeLayout(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -95,6 +95,6 @@
|
|||||||
|
|
||||||
private Panel panel1;
|
private Panel panel1;
|
||||||
private Button buttonAdd;
|
private Button buttonAdd;
|
||||||
private DataGridView dataGridView1;
|
private DataGridView dataGridView;
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -48,5 +48,5 @@ public partial class FormOrders : Form
|
|||||||
MessageBoxButtons.OK, MessageBoxIcon.Error);
|
MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
private void LoadList() => dataGridView1.DataSource = orderRepository.ReadOrders();
|
private void LoadList() => dataGridView.DataSource = orderRepository.ReadOrders();
|
||||||
}
|
}
|
||||||
|
46
Publication/Forms/FormPrintingHouses.Designer.cs
generated
46
Publication/Forms/FormPrintingHouses.Designer.cs
generated
@ -32,9 +32,9 @@
|
|||||||
panel1 = new Panel();
|
panel1 = new Panel();
|
||||||
buttonDelete = new Button();
|
buttonDelete = new Button();
|
||||||
buttonAdd = new Button();
|
buttonAdd = new Button();
|
||||||
dataGridView1 = new DataGridView();
|
dataGridView = new DataGridView();
|
||||||
panel1.SuspendLayout();
|
panel1.SuspendLayout();
|
||||||
((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit();
|
((System.ComponentModel.ISupportInitialize)dataGridView).BeginInit();
|
||||||
SuspendLayout();
|
SuspendLayout();
|
||||||
//
|
//
|
||||||
// panel1
|
// panel1
|
||||||
@ -69,38 +69,38 @@
|
|||||||
buttonAdd.UseVisualStyleBackColor = true;
|
buttonAdd.UseVisualStyleBackColor = true;
|
||||||
buttonAdd.Click += buttonAdd_Click;
|
buttonAdd.Click += buttonAdd_Click;
|
||||||
//
|
//
|
||||||
// dataGridView1
|
// dataGridView
|
||||||
//
|
//
|
||||||
dataGridView1.AllowUserToAddRows = false;
|
dataGridView.AllowUserToAddRows = false;
|
||||||
dataGridView1.AllowUserToDeleteRows = false;
|
dataGridView.AllowUserToDeleteRows = false;
|
||||||
dataGridView1.AllowUserToResizeColumns = false;
|
dataGridView.AllowUserToResizeColumns = false;
|
||||||
dataGridView1.AllowUserToResizeRows = false;
|
dataGridView.AllowUserToResizeRows = false;
|
||||||
dataGridView1.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.Fill;
|
dataGridView.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.Fill;
|
||||||
dataGridView1.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
dataGridView.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
||||||
dataGridView1.Dock = DockStyle.Fill;
|
dataGridView.Dock = DockStyle.Fill;
|
||||||
dataGridView1.Location = new Point(0, 0);
|
dataGridView.Location = new Point(0, 0);
|
||||||
dataGridView1.MultiSelect = false;
|
dataGridView.MultiSelect = false;
|
||||||
dataGridView1.Name = "dataGridView1";
|
dataGridView.Name = "dataGridView";
|
||||||
dataGridView1.ReadOnly = true;
|
dataGridView.ReadOnly = true;
|
||||||
dataGridView1.RowHeadersVisible = false;
|
dataGridView.RowHeadersVisible = false;
|
||||||
dataGridView1.RowHeadersWidth = 51;
|
dataGridView.RowHeadersWidth = 51;
|
||||||
dataGridView1.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
|
dataGridView.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
|
||||||
dataGridView1.Size = new Size(856, 450);
|
dataGridView.Size = new Size(603, 450);
|
||||||
dataGridView1.TabIndex = 3;
|
dataGridView.TabIndex = 3;
|
||||||
//
|
//
|
||||||
// FormPrintingHouses
|
// FormPrintingHouses
|
||||||
//
|
//
|
||||||
AutoScaleDimensions = new SizeF(8F, 20F);
|
AutoScaleDimensions = new SizeF(8F, 20F);
|
||||||
AutoScaleMode = AutoScaleMode.Font;
|
AutoScaleMode = AutoScaleMode.Font;
|
||||||
ClientSize = new Size(1053, 450);
|
ClientSize = new Size(800, 450);
|
||||||
Controls.Add(dataGridView1);
|
Controls.Add(dataGridView);
|
||||||
Controls.Add(panel1);
|
Controls.Add(panel1);
|
||||||
Name = "FormPrintingHouses";
|
Name = "FormPrintingHouses";
|
||||||
StartPosition = FormStartPosition.CenterScreen;
|
StartPosition = FormStartPosition.CenterScreen;
|
||||||
Text = "Печати";
|
Text = "Печати";
|
||||||
Load += FormPrintingHouses_Load;
|
Load += FormPrintingHouses_Load;
|
||||||
panel1.ResumeLayout(false);
|
panel1.ResumeLayout(false);
|
||||||
((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit();
|
((System.ComponentModel.ISupportInitialize)dataGridView).EndInit();
|
||||||
ResumeLayout(false);
|
ResumeLayout(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -109,6 +109,6 @@
|
|||||||
private Panel panel1;
|
private Panel panel1;
|
||||||
private Button buttonDelete;
|
private Button buttonDelete;
|
||||||
private Button buttonAdd;
|
private Button buttonAdd;
|
||||||
private DataGridView dataGridView1;
|
private DataGridView dataGridView;
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -75,7 +75,7 @@ public partial class FormPrintingHouses : Form
|
|||||||
private bool TryGetIdentifierFromSelectedRow(out int id)
|
private bool TryGetIdentifierFromSelectedRow(out int id)
|
||||||
{
|
{
|
||||||
id = 0;
|
id = 0;
|
||||||
if (dataGridView1.SelectedRows.Count < 1)
|
if (dataGridView.SelectedRows.Count < 1)
|
||||||
{
|
{
|
||||||
MessageBox.Show("Нет выбранной записи", "Ошибка",
|
MessageBox.Show("Нет выбранной записи", "Ошибка",
|
||||||
MessageBoxButtons.OK, MessageBoxIcon.Error);
|
MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||||
@ -83,9 +83,9 @@ public partial class FormPrintingHouses : Form
|
|||||||
}
|
}
|
||||||
|
|
||||||
id =
|
id =
|
||||||
Convert.ToInt32(dataGridView1.SelectedRows[0].Cells["Id"].Value);
|
Convert.ToInt32(dataGridView.SelectedRows[0].Cells["Id"].Value);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void LoadList() => dataGridView1.DataSource = printingHouseRepository.ReadPrintingHouses();
|
private void LoadList() => dataGridView.DataSource = printingHouseRepository.ReadPrintingHouses();
|
||||||
}
|
}
|
||||||
|
44
Publication/Forms/FormPublishingHouses.Designer.cs
generated
44
Publication/Forms/FormPublishingHouses.Designer.cs
generated
@ -33,9 +33,9 @@
|
|||||||
buttonDelete = new Button();
|
buttonDelete = new Button();
|
||||||
buttonEdit = new Button();
|
buttonEdit = new Button();
|
||||||
buttonAdd = new Button();
|
buttonAdd = new Button();
|
||||||
dataGridView1 = new DataGridView();
|
dataGridView = new DataGridView();
|
||||||
panel1.SuspendLayout();
|
panel1.SuspendLayout();
|
||||||
((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit();
|
((System.ComponentModel.ISupportInitialize)dataGridView).BeginInit();
|
||||||
SuspendLayout();
|
SuspendLayout();
|
||||||
//
|
//
|
||||||
// panel1
|
// panel1
|
||||||
@ -82,38 +82,38 @@
|
|||||||
buttonAdd.UseVisualStyleBackColor = true;
|
buttonAdd.UseVisualStyleBackColor = true;
|
||||||
buttonAdd.Click += buttonAdd_Click;
|
buttonAdd.Click += buttonAdd_Click;
|
||||||
//
|
//
|
||||||
// dataGridView1
|
// dataGridView
|
||||||
//
|
//
|
||||||
dataGridView1.AllowUserToAddRows = false;
|
dataGridView.AllowUserToAddRows = false;
|
||||||
dataGridView1.AllowUserToDeleteRows = false;
|
dataGridView.AllowUserToDeleteRows = false;
|
||||||
dataGridView1.AllowUserToResizeColumns = false;
|
dataGridView.AllowUserToResizeColumns = false;
|
||||||
dataGridView1.AllowUserToResizeRows = false;
|
dataGridView.AllowUserToResizeRows = false;
|
||||||
dataGridView1.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.Fill;
|
dataGridView.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.Fill;
|
||||||
dataGridView1.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
dataGridView.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
||||||
dataGridView1.Dock = DockStyle.Fill;
|
dataGridView.Dock = DockStyle.Fill;
|
||||||
dataGridView1.Location = new Point(0, 0);
|
dataGridView.Location = new Point(0, 0);
|
||||||
dataGridView1.MultiSelect = false;
|
dataGridView.MultiSelect = false;
|
||||||
dataGridView1.Name = "dataGridView1";
|
dataGridView.Name = "dataGridView";
|
||||||
dataGridView1.ReadOnly = true;
|
dataGridView.ReadOnly = true;
|
||||||
dataGridView1.RowHeadersVisible = false;
|
dataGridView.RowHeadersVisible = false;
|
||||||
dataGridView1.RowHeadersWidth = 51;
|
dataGridView.RowHeadersWidth = 51;
|
||||||
dataGridView1.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
|
dataGridView.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
|
||||||
dataGridView1.Size = new Size(603, 450);
|
dataGridView.Size = new Size(603, 450);
|
||||||
dataGridView1.TabIndex = 3;
|
dataGridView.TabIndex = 3;
|
||||||
//
|
//
|
||||||
// FormPublishingHouses
|
// FormPublishingHouses
|
||||||
//
|
//
|
||||||
AutoScaleDimensions = new SizeF(8F, 20F);
|
AutoScaleDimensions = new SizeF(8F, 20F);
|
||||||
AutoScaleMode = AutoScaleMode.Font;
|
AutoScaleMode = AutoScaleMode.Font;
|
||||||
ClientSize = new Size(800, 450);
|
ClientSize = new Size(800, 450);
|
||||||
Controls.Add(dataGridView1);
|
Controls.Add(dataGridView);
|
||||||
Controls.Add(panel1);
|
Controls.Add(panel1);
|
||||||
Name = "FormPublishingHouses";
|
Name = "FormPublishingHouses";
|
||||||
StartPosition = FormStartPosition.CenterScreen;
|
StartPosition = FormStartPosition.CenterScreen;
|
||||||
Text = "Издательства";
|
Text = "Издательства";
|
||||||
Load += FormPublishingHouses_Load;
|
Load += FormPublishingHouses_Load;
|
||||||
panel1.ResumeLayout(false);
|
panel1.ResumeLayout(false);
|
||||||
((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit();
|
((System.ComponentModel.ISupportInitialize)dataGridView).EndInit();
|
||||||
ResumeLayout(false);
|
ResumeLayout(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -123,6 +123,6 @@
|
|||||||
private Button buttonDelete;
|
private Button buttonDelete;
|
||||||
private Button buttonEdit;
|
private Button buttonEdit;
|
||||||
private Button buttonAdd;
|
private Button buttonAdd;
|
||||||
private DataGridView dataGridView1;
|
private DataGridView dataGridView;
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -95,7 +95,7 @@ public partial class FormPublishingHouses : Form
|
|||||||
private bool TryGetIdentifierFromSelectedRow(out int id)
|
private bool TryGetIdentifierFromSelectedRow(out int id)
|
||||||
{
|
{
|
||||||
id = 0;
|
id = 0;
|
||||||
if (dataGridView1.SelectedRows.Count < 1)
|
if (dataGridView.SelectedRows.Count < 1)
|
||||||
{
|
{
|
||||||
MessageBox.Show("Нет выбранной записи", "Ошибка",
|
MessageBox.Show("Нет выбранной записи", "Ошибка",
|
||||||
MessageBoxButtons.OK, MessageBoxIcon.Error);
|
MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||||
@ -103,9 +103,9 @@ public partial class FormPublishingHouses : Form
|
|||||||
}
|
}
|
||||||
|
|
||||||
id =
|
id =
|
||||||
Convert.ToInt32(dataGridView1.SelectedRows[0].Cells["Id"].Value);
|
Convert.ToInt32(dataGridView.SelectedRows[0].Cells["Id"].Value);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void LoadList() => dataGridView1.DataSource = publisingHouseRepository.ReadPublishingHouses();
|
private void LoadList() => dataGridView.DataSource = publisingHouseRepository.ReadPublishingHouses();
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user