28 lines
687 B
C#
28 lines
687 B
C#
using CarServiceContracts.BusinessLogicsContracts;
|
|
using Microsoft.Extensions.Logging;
|
|
|
|
namespace CarServiceView
|
|
{
|
|
public partial class FormRegistrationWorker : Form
|
|
{
|
|
private readonly ILogger _logger;
|
|
private readonly IWorkerLogic _workerLogic;
|
|
public FormRegistrationWorker(ILogger<FormRegistrationWorker> logger, IWorkerLogic workerLogic)
|
|
{
|
|
_logger = logger;
|
|
_workerLogic = workerLogic;
|
|
InitializeComponent();
|
|
}
|
|
private void buttonRegister_Click(object sender, EventArgs e)
|
|
{
|
|
_workerLogic.Create(new()
|
|
{
|
|
Login = textBoxLogin.Text,
|
|
Password = textBoxPassword.Text,
|
|
Name = textBoxName.Text,
|
|
Surname= textBoxSurname.Text
|
|
});
|
|
}
|
|
}
|
|
}
|