ПИбд-22 Боровков М В 1 лабораторная работа #1

Closed
bekodeg wants to merge 22 commits from labWork1 into main
7 changed files with 9 additions and 26 deletions
Showing only changes of commit e1abf80e62 - Show all commits

View File

@ -1,7 +1,6 @@
using SushiBarContracts.BindingModels;
using SushiBarContracts.BusinessLogicsContracts;
using Microsoft.Extensions.Logging;
using SushiView;
namespace SushiBar.Forms
{

View File

@ -159,14 +159,11 @@
private DataGridView dataGridView;
private MenuStrip menuStrip1;
private ToolStripMenuItem SushiToolStripMenuItem;
private Button buttonCreateOrder;
private Button buttonTakeOrderInWork;
private Button buttonOrderReady;
private Button buttonIssuedOrder;
private Button buttonRef;
private ToolStripMenuItem сушиToolStripMenuItem;
private ToolStripMenuItem компонентыToolStripMenuItem;
private ToolStripMenuItem ToolStripMenuItem;
private ToolStripMenuItem sushiToolStripMenuItem;
private ToolStripMenuItem componentsToolStripMenuItem;

View File

@ -2,7 +2,6 @@
using SushiBarBusinessLogic.BusinessLogics;
using SushiBarContracts.BindingModels;
using SushiBarContracts.BusinessLogicsContracts;
using SushiView;
using System.Windows.Forms;
namespace SushiBar.Forms

View File

@ -3,7 +3,6 @@ using SushiBarContracts.BindingModels;
using SushiBarContracts.BusinessLogicsContracts;
using SushiBarContracts.SearchModels;
using SushiBarDataModels.Models;
using SushiView;
namespace SushiBar.Forms
{

View File

@ -1,13 +1,6 @@
using Microsoft.Extensions.Logging;
using SushiBarContracts.BindingModels;
using SushiBarContracts.BusinessLogicsContracts;
using SushiView;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace SushiBar.Forms
{

View File

@ -1,20 +1,20 @@
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;
using NLog.Extensions.Logging;
using SushiBar.Forms;
using SushiBarBusinessLogic.BusinessLogics;
using SushiBarContracts.BusinessLogicsContracts;
using SushiBarContracts.StoragesContracts;
using SushiBarListImplement.Implements;
using SushiBar.Forms;
namespace SushiView
namespace SushiBar
{
internal static class Program
{
private static ServiceProvider? _serviceProvider;
public static ServiceProvider? ServiceProvider => _serviceProvider;
/// <summary>
/// The main entry point for the application.
/// The main entry point for the application.
/// </summary>
[STAThread]
static void Main()
@ -25,9 +25,6 @@ namespace SushiView
var services = new ServiceCollection();
ConfigureServices(services);
_serviceProvider = services.BuildServiceProvider();
ILogger logger = _serviceProvider.GetService<ILogger>();
Application.Run(_serviceProvider.GetRequiredService<FormMain>());
}
private static void ConfigureServices(ServiceCollection services)
@ -51,6 +48,7 @@ namespace SushiView
services.AddTransient<FormCreateOrder>();
services.AddTransient<FormSushi>();
services.AddTransient<FormSushiComponent>();
services.AddTransient<FormSushis>();
}
}
}

View File

@ -1,13 +1,11 @@
<?xml version="1.0" encoding="utf-8" ?>
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<nlog xmlns="http://www.nlog-project.org/schemas/NLog.xsd"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
autoReload="true" internalLogLevel="Info">
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
autoReload="true" internalLogLevel="Info">
<targets>
<target xsi:type="File" name="tofile" fileName="${basedir}/log-${shortdate}.log" />
<target xsi:type="File" name="tofile" fileName="carlog-${shortdate}.log" />
</targets>
<rules>
<logger name="*" minlevel="Debug" writeTo="tofile" />
</rules>