init
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
using System.Configuration;
|
||||
using Kreta.Client.Eugyintezes.Configuration;
|
||||
using Kreta.Core.FileService;
|
||||
using Kreta.Core.FileService.Configuration;
|
||||
using Kreta.Eugyintezes.BusinessLogic.Interface.Services;
|
||||
using Kreta.Eugyintezes.BusinessLogic.Services;
|
||||
using SimpleInjector;
|
||||
|
||||
namespace Kreta.Eugyintezes.BusinessLogic.Infrastructure
|
||||
{
|
||||
public static class DependencyInjection
|
||||
{
|
||||
public static void RegisterTypes(Container container)
|
||||
{
|
||||
container.Register<ITorzsadatService, TorzsadatService>(Lifestyle.Scoped);
|
||||
container.Register<IFileServiceConfiguration>(() => (FileServiceConfiguration)ConfigurationManager.GetSection(nameof(FileServiceConfiguration)), Lifestyle.Singleton);
|
||||
container.Register<IFileService, FileService>(Lifestyle.Singleton);
|
||||
container.Register<IEugyintezesClientConfiguration>(() => (EugyintezesClientConfiguration)ConfigurationManager.GetSection(nameof(EugyintezesClientConfiguration)), Lifestyle.Singleton);
|
||||
}
|
||||
}
|
||||
}
|
@@ -0,0 +1,110 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProjectGuid>{D9BA1291-C6A3-481E-94FF-22A38BD522C8}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>Kreta.Eugyintezes.BusinessLogic</RootNamespace>
|
||||
<AssemblyName>Kreta.Eugyintezes.BusinessLogic</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<TargetFrameworkProfile />
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
||||
<HintPath>..\..\..\packages\Newtonsoft.Json.12.0.3\lib\net45\Newtonsoft.Json.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="RestSharp, Version=105.2.3.0, Culture=neutral, processorArchitecture=MSIL">
|
||||
<HintPath>..\..\..\packages\RestSharp.105.2.3\lib\net46\RestSharp.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="SimpleInjector, Version=4.0.11.0, Culture=neutral, PublicKeyToken=984cb50dea722e99, processorArchitecture=MSIL">
|
||||
<HintPath>..\..\..\packages\SimpleInjector.4.0.11\lib\net45\SimpleInjector.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="..\..\..\Tools\SharedAssemblyInfo.cs">
|
||||
<Link>Properties\SharedAssemblyInfo.cs</Link>
|
||||
</Compile>
|
||||
<Compile Include="Infrastructure\DependencyInjection.cs" />
|
||||
<Compile Include="Models\NebuloEUgySaveResponseModel.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="Service.cs" />
|
||||
<Compile Include="Services\TorzsadatService.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\..\Framework\Kreta.Framework.csproj">
|
||||
<Project>{320EF478-7155-441D-B1E9-47EC3E57FB45}</Project>
|
||||
<Name>Kreta.Framework</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\..\..\Kreta.BusinessLogic\Kreta.BusinessLogic.csproj">
|
||||
<Project>{8876FE0D-841E-422D-A5A0-59239CD98482}</Project>
|
||||
<Name>Kreta.BusinessLogic</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\..\..\Kreta.Client\Kreta.Client.csproj">
|
||||
<Project>{4b28e52b-b531-403c-a827-2cc178ff8a4f}</Project>
|
||||
<Name>Kreta.Client</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\..\..\Kreta.Core\Kreta.Core.csproj">
|
||||
<Project>{57418d3e-caf1-482c-9b18-85d147abd495}</Project>
|
||||
<Name>Kreta.Core</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\..\..\Kreta.DataAccessInterfaceGenerated\Kreta.DataAccess.Interfaces.csproj">
|
||||
<Project>{68318C3F-0779-4755-848E-B270F6BAC40B}</Project>
|
||||
<Name>Kreta.DataAccess.Interfaces</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\..\..\Kreta.DataAccessManual\Kreta.DataAccessManual.csproj">
|
||||
<Project>{3212F2BF-6883-48B4-9F7D-0DFF4C826221}</Project>
|
||||
<Name>Kreta.DataAccessManual</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\..\..\Kreta.Enums\Kreta.Enums.csproj">
|
||||
<Project>{1D5E0AC2-DFAB-4D32-9AD1-B5788A7D06BD}</Project>
|
||||
<Name>Kreta.Enums</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\..\..\Kreta.Resources\Kreta.Resources.csproj">
|
||||
<Project>{DFCB4D33-B599-42B2-98C6-B60FD220DB0C}</Project>
|
||||
<Name>Kreta.Resources</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\Kreta.eUgyintezes.BusinessLogic.Interface\Kreta.Eugyintezes.BusinessLogic.Interface.csproj">
|
||||
<Project>{35E59B3A-A3FE-4536-A573-DE06D94B1C61}</Project>
|
||||
<Name>Kreta.Eugyintezes.BusinessLogic.Interface</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\Kreta.eUgyintezes.Domain\Kreta.Eugyintezes.Domain.csproj">
|
||||
<Project>{2B2F2FB3-A8AE-4C90-850E-251FF484176D}</Project>
|
||||
<Name>Kreta.Eugyintezes.Domain</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\Kreta.eUgyintezes.Infrastructure\Kreta.Eugyintezes.Infrastructure.csproj">
|
||||
<Project>{414666cb-4ad8-43f8-b26c-19570bce866e}</Project>
|
||||
<Name>Kreta.Eugyintezes.Infrastructure</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="app.config" />
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
</Project>
|
@@ -0,0 +1,12 @@
|
||||
using System;
|
||||
|
||||
namespace Kreta.Eugyintezes.BusinessLogic.Models
|
||||
{
|
||||
public class NebuloEUgySaveResponseModel
|
||||
{
|
||||
public string OktatasiAzonosito { get; set; }
|
||||
public DateTime SzuletesiDatum { get; set; }
|
||||
public string Statusz { get; set; }
|
||||
public string MuveletStatusz { get; set; }
|
||||
}
|
||||
}
|
@@ -0,0 +1 @@
|
||||
|
@@ -0,0 +1,55 @@
|
||||
using System;
|
||||
using Kreta.DataAccessManual;
|
||||
using Kreta.Eugyintezes.BusinessLogic.Interface;
|
||||
|
||||
namespace Kreta.Eugyintezes.BusinessLogic
|
||||
{
|
||||
internal class Service
|
||||
{
|
||||
protected IServiceContext ServiceContext { get; }
|
||||
|
||||
private int tanevId;
|
||||
private int intezmenyId;
|
||||
|
||||
protected int TanevId
|
||||
{
|
||||
get
|
||||
{
|
||||
if (tanevId <= 0)
|
||||
{
|
||||
tanevId = GetTanevId();
|
||||
}
|
||||
|
||||
return tanevId;
|
||||
}
|
||||
}
|
||||
|
||||
protected int IntezmenyId
|
||||
{
|
||||
get
|
||||
{
|
||||
if (intezmenyId <= 0)
|
||||
{
|
||||
intezmenyId = GetIntezmenyId();
|
||||
}
|
||||
|
||||
return intezmenyId;
|
||||
}
|
||||
}
|
||||
|
||||
private int GetTanevId()
|
||||
{
|
||||
return Dal.MobileConnection.Run(ServiceContext.IntezmenyAzonosito, null, h => h.TanevDal().GetAktivTanevId());
|
||||
}
|
||||
private int GetIntezmenyId()
|
||||
{
|
||||
var azonosito = ServiceContext.IntezmenyAzonosito;
|
||||
return Dal.MobileConnection.Run(ServiceContext.IntezmenyAzonosito, null, h => h.IntezmenyDal().GetIntezmenyIdByAzonosito(azonosito).Value);
|
||||
}
|
||||
|
||||
public Service(IServiceContext serviceContext)
|
||||
{
|
||||
this.ServiceContext = serviceContext ?? throw new ArgumentNullException(nameof(serviceContext));
|
||||
}
|
||||
}
|
||||
}
|
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,63 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-12.0.0.0" newVersion="12.0.0.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Microsoft.IdentityModel.Logging" publicKeyToken="31bf3856ad364e35" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.2.1.0" newVersion="5.2.1.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="SimpleInjector" publicKeyToken="984cb50dea722e99" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Microsoft.Owin" publicKeyToken="31bf3856ad364e35" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-3.1.0.0" newVersion="3.1.0.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Microsoft.Extensions.Configuration.Abstractions" publicKeyToken="adb9793829ddae60" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-2.0.1.0" newVersion="2.0.1.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Microsoft.Extensions.FileProviders.Abstractions" publicKeyToken="adb9793829ddae60" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-2.0.0.0" newVersion="2.0.0.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Microsoft.Extensions.Configuration.FileExtensions" publicKeyToken="adb9793829ddae60" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-2.0.0.0" newVersion="2.0.0.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Microsoft.Extensions.FileProviders.Physical" publicKeyToken="adb9793829ddae60" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-2.0.0.0" newVersion="2.0.0.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Microsoft.Extensions.Configuration" publicKeyToken="adb9793829ddae60" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-2.0.0.0" newVersion="2.0.0.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="System.IdentityModel.Tokens.Jwt" publicKeyToken="31bf3856ad364e35" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-6.5.1.0" newVersion="6.5.1.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Microsoft.IdentityModel.Tokens" publicKeyToken="31bf3856ad364e35" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-6.5.1.0" newVersion="6.5.1.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="CacheManager.Core" publicKeyToken="5b450b4fb65c4cdb" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-1.2.0.0" newVersion="1.2.0.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="System.Runtime.CompilerServices.Unsafe" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-4.0.4.0" newVersion="4.0.4.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="System.Web.Http" publicKeyToken="31bf3856ad364e35" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-5.2.6.0" newVersion="5.2.6.0" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.8" /></startup></configuration>
|
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="Meziantou.Analyzer" version="1.0.688" targetFramework="net48" developmentDependency="true" />
|
||||
<package id="Newtonsoft.Json" version="12.0.3" targetFramework="net48" />
|
||||
<package id="RestSharp" version="105.2.3" targetFramework="net48" />
|
||||
<package id="SimpleInjector" version="4.0.11" targetFramework="net48" />
|
||||
</packages>
|
Reference in New Issue
Block a user