55 lines
1.5 KiB
C#
55 lines
1.5 KiB
C#
using MySqlX.XDevAPI.Relational;
|
|
using PaymentLogs.Domain;
|
|
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 PaymentLogs
|
|
{
|
|
public partial class DataForm : Form
|
|
{
|
|
public DataForm()
|
|
{
|
|
InitializeComponent();
|
|
|
|
}
|
|
|
|
private void Form1_Load(object sender, EventArgs e)
|
|
{
|
|
|
|
dataGridView1.Columns.Add("id", "Номер");
|
|
dataGridView1.Columns.Add("fcs", "ФИО");
|
|
dataGridView1.Columns.Add("course", "Курс");
|
|
dataGridView1.Columns.Add("course_price", "Цена");
|
|
dataGridView1.Columns.Add("debt", "Долг");
|
|
/* BindingList<Payment> list1 = new BindingList<Payment>();
|
|
dataGridView1.DataSource = list1;*/
|
|
foreach (Payment payment in Program.PaymentRepository.All())
|
|
{
|
|
dataGridView1.Rows.Add(payment.Id.ToString(), payment.FCs, Program.CourseRepository.ById(payment.CourseId).Name, payment.CoursePrice.ToString(), payment.Debt.ToString());
|
|
}
|
|
}
|
|
|
|
private void toolStripSplitButton1_ButtonClick(object sender, EventArgs e)
|
|
{
|
|
|
|
}
|
|
|
|
private void toolStripButton3_Click(object sender, EventArgs e)
|
|
{
|
|
|
|
}
|
|
|
|
private void dataGridView1_CellContentClick(object sender, DataGridViewCellEventArgs e)
|
|
{
|
|
|
|
}
|
|
}
|
|
}
|