├── WebApi ├── obj │ ├── Debug │ │ └── netcoreapp3.1 │ │ │ ├── WebApi.csproj.CopyComplete │ │ │ ├── WebApi.MvcApplicationPartsAssemblyInfo.cache │ │ │ ├── staticwebassets │ │ │ ├── WebApi.StaticWebAssets.Manifest.cache │ │ │ └── WebApi.StaticWebAssets.xml │ │ │ ├── WebApi.AssemblyInfoInputs.cache │ │ │ ├── WebApi.genruntimeconfig.cache │ │ │ ├── WebApi.RazorComponent.input.cache │ │ │ ├── WebApi.RazorTargetAssemblyInfo.cache │ │ │ ├── WebApi.csproj.CoreCompileInputs.cache │ │ │ ├── WebApi.dll │ │ │ ├── WebApi.exe │ │ │ ├── WebApi.pdb │ │ │ ├── WebApi.assets.cache │ │ │ ├── WebApi.csprojAssemblyReference.cache │ │ │ ├── .NETCoreApp,Version=v3.1.AssemblyAttributes.cs │ │ │ └── WebApi.AssemblyInfo.cs │ ├── WebApi.csproj.nuget.g.targets │ └── WebApi.csproj.nuget.g.props ├── bin │ └── Debug │ │ └── netcoreapp3.1 │ │ ├── Core.dll │ │ ├── Core.pdb │ │ ├── Autofac.dll │ │ ├── Business.dll │ │ ├── Business.pdb │ │ ├── Entities.dll │ │ ├── Entities.pdb │ │ ├── WebApi.dll │ │ ├── WebApi.exe │ │ ├── WebApi.pdb │ │ ├── DataAccess.dll │ │ ├── DataAccess.pdb │ │ ├── Castle.Core.dll │ │ ├── Newtonsoft.Json.dll │ │ ├── FluentValidation.dll │ │ ├── Microsoft.Bcl.HashCode.dll │ │ ├── System.Runtime.Caching.dll │ │ ├── Microsoft.Data.SqlClient.dll │ │ ├── Microsoft.Identity.Client.dll │ │ ├── Autofac.Extras.DynamicProxy.dll │ │ ├── Microsoft.Extensions.Logging.dll │ │ ├── Microsoft.Extensions.Options.dll │ │ ├── System.Collections.Immutable.dll │ │ ├── runtimes │ │ ├── win-x64 │ │ │ └── native │ │ │ │ └── sni.dll │ │ ├── win-x86 │ │ │ └── native │ │ │ │ └── sni.dll │ │ ├── win-arm64 │ │ │ └── native │ │ │ │ └── sni.dll │ │ ├── win │ │ │ └── lib │ │ │ │ ├── netcoreapp2.0 │ │ │ │ └── System.Runtime.Caching.dll │ │ │ │ ├── netcoreapp2.1 │ │ │ │ └── Microsoft.Data.SqlClient.dll │ │ │ │ └── netstandard2.0 │ │ │ │ └── System.Security.Cryptography.ProtectedData.dll │ │ └── unix │ │ │ └── lib │ │ │ ├── netcoreapp2.0 │ │ │ └── System.Runtime.Caching.dll │ │ │ └── netcoreapp2.1 │ │ │ └── Microsoft.Data.SqlClient.dll │ │ ├── Microsoft.Bcl.AsyncInterfaces.dll │ │ ├── Microsoft.EntityFrameworkCore.dll │ │ ├── Microsoft.IdentityModel.Tokens.dll │ │ ├── Microsoft.Extensions.Primitives.dll │ │ ├── Microsoft.IdentityModel.Logging.dll │ │ ├── Microsoft.IdentityModel.Protocols.dll │ │ ├── System.IdentityModel.Tokens.Jwt.dll │ │ ├── Microsoft.Extensions.Caching.Memory.dll │ │ ├── Microsoft.Extensions.Configuration.dll │ │ ├── System.Diagnostics.DiagnosticSource.dll │ │ ├── Autofac.Extensions.DependencyInjection.dll │ │ ├── Microsoft.IdentityModel.JsonWebTokens.dll │ │ ├── Microsoft.EntityFrameworkCore.Relational.dll │ │ ├── Microsoft.EntityFrameworkCore.SqlServer.dll │ │ ├── Microsoft.Extensions.DependencyInjection.dll │ │ ├── Microsoft.EntityFrameworkCore.Abstractions.dll │ │ ├── Microsoft.Extensions.Caching.Abstractions.dll │ │ ├── Microsoft.Extensions.Configuration.Binder.dll │ │ ├── Microsoft.Extensions.Logging.Abstractions.dll │ │ ├── System.Configuration.ConfigurationManager.dll │ │ ├── System.Security.Cryptography.ProtectedData.dll │ │ ├── Microsoft.AspNetCore.Authentication.JwtBearer.dll │ │ ├── Microsoft.Extensions.Configuration.Abstractions.dll │ │ ├── Microsoft.IdentityModel.Protocols.OpenIdConnect.dll │ │ ├── Microsoft.Extensions.DependencyInjection.Abstractions.dll │ │ ├── WebApi.runtimeconfig.dev.json │ │ ├── appsettings.Development.json │ │ ├── WebApi.runtimeconfig.json │ │ ├── appsettings.json │ │ └── Properties │ │ └── launchSettings.json ├── wwwroot │ └── images │ │ ├── 226017ad-ca96-43bf-b1a8-967ba49f1a1b.jpg │ │ ├── 8b329fe2-4e1a-48dc-8aa4-fb28ed2df70c.jpg │ │ └── bf40a279-d008-4c01-9983-d3dbcfa3099e.jpg ├── appsettings.Development.json ├── WeatherForecast.cs ├── WebApi.csproj.user ├── appsettings.json ├── WebApi.csproj ├── Properties │ └── launchSettings.json ├── Program.cs └── Controllers │ ├── WeatherForecastController.cs │ ├── UsersController.cs │ ├── AuthController.cs │ ├── CarImagesController.cs │ ├── CustomersController.cs │ ├── ColorsController.cs │ └── BrandsController.cs ├── Business ├── obj │ ├── Debug │ │ └── netstandard2.0 │ │ │ ├── Business.csproj.CopyComplete │ │ │ ├── Business.AssemblyInfoInputs.cache │ │ │ ├── Business.csproj.CoreCompileInputs.cache │ │ │ ├── Business.dll │ │ │ ├── Business.pdb │ │ │ ├── Business.assets.cache │ │ │ ├── Business.csprojAssemblyReference.cache │ │ │ ├── .NETStandard,Version=v2.0.AssemblyAttributes.cs │ │ │ └── Business.AssemblyInfo.cs │ ├── Business.csproj.nuget.g.targets │ └── Business.csproj.nuget.g.props ├── bin │ └── Debug │ │ └── netstandard2.0 │ │ ├── Core.dll │ │ ├── Core.pdb │ │ ├── Business.dll │ │ ├── Business.pdb │ │ ├── DataAccess.dll │ │ ├── DataAccess.pdb │ │ ├── Entities.dll │ │ └── Entities.pdb ├── Abstract │ ├── IPaymentService.cs │ ├── IColorService.cs │ ├── IBrandService.cs │ ├── IAuthService.cs │ ├── ICustomerService.cs │ ├── IUserService.cs │ ├── ICarImageService.cs │ ├── ICarService.cs │ └── IRentalService.cs ├── ValidationRules │ └── FluentValidation │ │ ├── ColorValidator.cs │ │ ├── BrandValidator.cs │ │ ├── CustomerValidator.cs │ │ ├── CarValidator.cs │ │ ├── CarImageValidator.cs │ │ ├── UserValidator.cs │ │ └── RentalValidator.cs ├── Constants │ ├── DefaultNameOrPath.cs │ └── Message.cs ├── Concrete │ ├── PaymentManager.cs │ ├── ColorManager.cs │ ├── CustomerManager.cs │ ├── BrandManager.cs │ ├── UserManager.cs │ ├── AuthMenager.cs │ └── AuthManager.cs ├── Business.csproj ├── BusinessAspects │ └── Autofac │ │ └── SecuredOperation.cs └── DependencyResolvers │ └── Autofac │ └── AutofacBusinessModule.cs ├── ConsoleUI ├── obj │ ├── Debug │ │ └── netcoreapp3.1 │ │ │ ├── ConsoleUI.csproj.CopyComplete │ │ │ ├── ConsoleUI.AssemblyInfoInputs.cache │ │ │ ├── ConsoleUI.genruntimeconfig.cache │ │ │ ├── ConsoleUI.csproj.CoreCompileInputs.cache │ │ │ ├── ConsoleUI.dll │ │ │ ├── ConsoleUI.exe │ │ │ ├── ConsoleUI.pdb │ │ │ ├── ConsoleUI.assets.cache │ │ │ ├── ConsoleUI.csprojAssemblyReference.cache │ │ │ ├── .NETCoreApp,Version=v3.1.AssemblyAttributes.cs │ │ │ └── ConsoleUI.AssemblyInfo.cs │ ├── ConsoleUI.csproj.nuget.g.targets │ └── ConsoleUI.csproj.nuget.g.props ├── bin │ └── Debug │ │ └── netcoreapp3.1 │ │ ├── Core.dll │ │ ├── Core.pdb │ │ ├── Autofac.dll │ │ ├── Business.dll │ │ ├── Business.pdb │ │ ├── ConsoleUI.dll │ │ ├── ConsoleUI.exe │ │ ├── ConsoleUI.pdb │ │ ├── DataAccess.dll │ │ ├── DataAccess.pdb │ │ ├── Entities.dll │ │ ├── Entities.pdb │ │ ├── Castle.Core.dll │ │ ├── Newtonsoft.Json.dll │ │ ├── FluentValidation.dll │ │ ├── Microsoft.Bcl.HashCode.dll │ │ ├── System.Runtime.Caching.dll │ │ ├── Microsoft.AspNetCore.Http.dll │ │ ├── Microsoft.Data.SqlClient.dll │ │ ├── Microsoft.Identity.Client.dll │ │ ├── Autofac.Extras.DynamicProxy.dll │ │ ├── Microsoft.Net.Http.Headers.dll │ │ ├── System.Security.Permissions.dll │ │ ├── runtimes │ │ ├── win-x64 │ │ │ └── native │ │ │ │ └── sni.dll │ │ ├── win-x86 │ │ │ └── native │ │ │ │ └── sni.dll │ │ ├── win-arm64 │ │ │ └── native │ │ │ │ └── sni.dll │ │ ├── unix │ │ │ └── lib │ │ │ │ ├── netcoreapp2.0 │ │ │ │ └── System.Runtime.Caching.dll │ │ │ │ └── netcoreapp2.1 │ │ │ │ └── Microsoft.Data.SqlClient.dll │ │ └── win │ │ │ └── lib │ │ │ ├── netcoreapp2.0 │ │ │ └── System.Runtime.Caching.dll │ │ │ ├── netcoreapp2.1 │ │ │ └── Microsoft.Data.SqlClient.dll │ │ │ └── netstandard2.0 │ │ │ └── System.Security.Cryptography.ProtectedData.dll │ │ ├── Microsoft.Bcl.AsyncInterfaces.dll │ │ ├── Microsoft.EntityFrameworkCore.dll │ │ ├── Microsoft.Extensions.Logging.dll │ │ ├── Microsoft.Extensions.Options.dll │ │ ├── Microsoft.IdentityModel.Tokens.dll │ │ ├── System.Collections.Immutable.dll │ │ ├── Microsoft.Extensions.ObjectPool.dll │ │ ├── Microsoft.Extensions.Primitives.dll │ │ ├── Microsoft.IdentityModel.Logging.dll │ │ ├── System.IdentityModel.Tokens.Jwt.dll │ │ ├── Microsoft.AspNetCore.Http.Features.dll │ │ ├── Microsoft.AspNetCore.WebUtilities.dll │ │ ├── Microsoft.Extensions.Caching.Memory.dll │ │ ├── Microsoft.Extensions.Configuration.dll │ │ ├── Microsoft.IdentityModel.Protocols.dll │ │ ├── System.Diagnostics.DiagnosticSource.dll │ │ ├── Microsoft.EntityFrameworkCore.Design.dll │ │ ├── Microsoft.IdentityModel.JsonWebTokens.dll │ │ ├── Autofac.Extensions.DependencyInjection.dll │ │ ├── Microsoft.AspNetCore.Http.Abstractions.dll │ │ ├── Microsoft.EntityFrameworkCore.Relational.dll │ │ ├── Microsoft.EntityFrameworkCore.SqlServer.dll │ │ ├── Microsoft.Extensions.DependencyInjection.dll │ │ ├── Microsoft.AspNetCore.Hosting.Abstractions.dll │ │ ├── Microsoft.EntityFrameworkCore.Abstractions.dll │ │ ├── Microsoft.Extensions.Caching.Abstractions.dll │ │ ├── Microsoft.Extensions.Configuration.Binder.dll │ │ ├── Microsoft.Extensions.Hosting.Abstractions.dll │ │ ├── Microsoft.Extensions.Logging.Abstractions.dll │ │ ├── System.Configuration.ConfigurationManager.dll │ │ ├── System.Security.Cryptography.ProtectedData.dll │ │ ├── Microsoft.Extensions.Configuration.Abstractions.dll │ │ ├── Microsoft.Extensions.FileProviders.Abstractions.dll │ │ ├── Microsoft.IdentityModel.Protocols.OpenIdConnect.dll │ │ ├── Microsoft.AspNetCore.Hosting.Server.Abstractions.dll │ │ ├── ConsoleUI.runtimeconfig.json │ │ ├── Microsoft.Extensions.DependencyInjection.Abstractions.dll │ │ └── ConsoleUI.runtimeconfig.dev.json └── ConsoleUI.csproj ├── Entities ├── obj │ ├── Debug │ │ └── netstandard2.0 │ │ │ ├── Entities.csproj.CopyComplete │ │ │ ├── Entities.AssemblyInfoInputs.cache │ │ │ ├── Entities.csproj.CoreCompileInputs.cache │ │ │ ├── Entities.dll │ │ │ ├── Entities.pdb │ │ │ ├── Entities.assets.cache │ │ │ ├── Entities.csprojAssemblyReference.cache │ │ │ ├── .NETStandard,Version=v2.0.AssemblyAttributes.cs │ │ │ ├── Entities.AssemblyInfo.cs │ │ │ └── Entities.csproj.FileListAbsolute.txt │ ├── Entities.csproj.nuget.g.targets │ └── Entities.csproj.nuget.g.props ├── bin │ └── Debug │ │ └── netstandard2.0 │ │ ├── Core.dll │ │ ├── Core.pdb │ │ ├── Entities.dll │ │ └── Entities.pdb ├── Concrete │ ├── Payment.cs │ ├── Brand.cs │ ├── Color.cs │ ├── Customer.cs │ ├── User.cs │ ├── Rental.cs │ ├── CarImage.cs │ └── Car.cs ├── Entities.csproj └── DTOs │ ├── RentalPaymentDto.cs │ ├── UserForLoginDto.cs │ ├── CarDetailAndImagesDto.cs │ ├── CarImagesOperationDto.cs │ ├── UserForRegisterDto.cs │ ├── CustomerDetailDto.cs │ ├── CarDetailDto.cs │ └── RentalDetailDto.cs ├── DataAccess ├── obj │ ├── Debug │ │ └── netstandard2.0 │ │ │ ├── DataAccess.csproj.CopyComplete │ │ │ ├── DataAccess.AssemblyInfoInputs.cache │ │ │ ├── DataAccess.csproj.CoreCompileInputs.cache │ │ │ ├── DataAccess.dll │ │ │ ├── DataAccess.pdb │ │ │ ├── DataAccess.assets.cache │ │ │ ├── DataAccess.csprojAssemblyReference.cache │ │ │ ├── .NETStandard,Version=v2.0.AssemblyAttributes.cs │ │ │ └── DataAccess.AssemblyInfo.cs │ ├── DataAccess.csproj.nuget.g.targets │ └── DataAccess.csproj.nuget.g.props ├── bin │ └── Debug │ │ └── netstandard2.0 │ │ ├── Core.dll │ │ ├── Core.pdb │ │ ├── Entities.dll │ │ ├── Entities.pdb │ │ ├── DataAccess.dll │ │ └── DataAccess.pdb ├── DataAccess.csproj.user ├── Abstract │ ├── ICarImageDal.cs │ ├── IColorDal.cs │ ├── IBrandDal.cs │ ├── IUserDal.cs │ ├── ICustomerDal.cs │ ├── IRentalDal.cs │ └── ICarDal.cs ├── Concrete │ ├── EntityFramework │ │ ├── Repository │ │ │ ├── EfCarImageDal.cs │ │ │ ├── EfColorDal.cs │ │ │ ├── EfBrandDal.cs │ │ │ ├── EfUserDal.cs │ │ │ ├── EfCustomerDal.cs │ │ │ └── EfRentalDal.cs │ │ └── Context │ │ │ └── RentACarContext.cs │ └── InMemory │ │ ├── InMemoryBrandDal.cs │ │ ├── InMemoryColorDal.cs │ │ └── InMemoryCarDal.cs └── DataAccess.csproj ├── Sql └── RentACar.sql ├── .vs └── ReCapProject │ ├── v16 │ └── .suo │ └── DesignTimeBuild │ └── .dtbcache.v2 ├── Core ├── obj │ ├── Debug │ │ └── netstandard2.0 │ │ │ ├── Core.AssemblyInfoInputs.cache │ │ │ ├── Core.csproj.CoreCompileInputs.cache │ │ │ ├── Core.dll │ │ │ ├── Core.pdb │ │ │ ├── Core.assets.cache │ │ │ ├── Core.csprojAssemblyReference.cache │ │ │ ├── .NETStandard,Version=v2.0.AssemblyAttributes.cs │ │ │ ├── Core.AssemblyInfo.cs │ │ │ └── Core.csproj.FileListAbsolute.txt │ ├── Core.csproj.nuget.g.targets │ └── Core.csproj.nuget.g.props ├── Entities │ ├── IDto.cs │ ├── Dtos │ │ ├── IDto.cs │ │ ├── UserForLoginDto.cs │ │ └── UserForRegisterDto.cs │ ├── IEntity.cs │ └── Concrete │ │ ├── OperationClaim.cs │ │ ├── UserOperationClaim.cs │ │ └── User.cs ├── bin │ └── Debug │ │ └── netstandard2.0 │ │ ├── Core.dll │ │ └── Core.pdb ├── Utilites │ ├── Results │ │ ├── Abstract │ │ │ ├── IDataResult.cs │ │ │ └── IResult.cs │ │ └── Concrete │ │ │ ├── ErrorResult.cs │ │ │ ├── SuccessResult.cs │ │ │ ├── Result.cs │ │ │ ├── DataResult.cs │ │ │ ├── ErrorDataResult.cs │ │ │ └── SuccessDataResult.cs │ ├── Security │ │ ├── JWT │ │ │ ├── AccessToken.cs │ │ │ ├── ITokenHelper.cs │ │ │ ├── TokenOptions.cs │ │ │ └── JwtHelper.cs │ │ ├── Encryption │ │ │ ├── SecurityKeyHelper.cs │ │ │ └── SigningCredentialsHelper.cs │ │ └── Hashing │ │ │ └── HashingHelper.cs │ ├── IoC │ │ ├── ICoreModule.cs │ │ └── ServiceTool.cs │ ├── Interceptors │ │ ├── MethodInterceptionBaseAttribute.cs │ │ ├── AspectInterceptorSelector.cs │ │ └── MethodInterception.cs │ ├── Business │ │ └── BusinessRules.cs │ └── FileProces │ │ ├── IFileProces.cs │ │ └── FileProces.cs ├── Extensions │ ├── ExceptionMiddlewareExtensions.cs │ ├── ErrorDetails.cs │ ├── ServiceCollectionExtensions.cs │ ├── ClaimsPrincipalExtensions.cs │ ├── ClaimExtensions.cs │ └── ExceptionMiddleware.cs ├── DataAccess │ ├── IEntityRepository.cs │ └── EntityFramework │ │ └── EfEntityRepositoryBase.cs ├── CrossCuttingConcerns │ ├── Caching │ │ ├── ICacheManager.cs │ │ └── Microsoft │ │ │ └── MemoryCacheManager.cs │ └── Validation │ │ └── ValidationTool.cs ├── DependencyResolvers │ └── CoreModule.cs ├── Aspects │ └── Autofac │ │ ├── Caching │ │ ├── CacheRemoveAspect.cs │ │ └── CacheAspect.cs │ │ ├── Transaction │ │ └── TransactionScopeAspect.cs │ │ ├── Performance │ │ └── PerformanceAspect.cs │ │ └── Validation │ │ └── ValidationAspect.cs └── Core.csproj └── README.md /WebApi/obj/Debug/netcoreapp3.1/WebApi.csproj.CopyComplete: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /Business/obj/Debug/netstandard2.0/Business.csproj.CopyComplete: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /ConsoleUI/obj/Debug/netcoreapp3.1/ConsoleUI.csproj.CopyComplete: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /Entities/obj/Debug/netstandard2.0/Entities.csproj.CopyComplete: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /DataAccess/obj/Debug/netstandard2.0/DataAccess.csproj.CopyComplete: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /WebApi/obj/Debug/netcoreapp3.1/WebApi.MvcApplicationPartsAssemblyInfo.cache: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /WebApi/obj/Debug/netcoreapp3.1/staticwebassets/WebApi.StaticWebAssets.Manifest.cache: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /Sql/RentACar.sql: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Sql/RentACar.sql -------------------------------------------------------------------------------- /.vs/ReCapProject/v16/.suo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/.vs/ReCapProject/v16/.suo -------------------------------------------------------------------------------- /Core/obj/Debug/netstandard2.0/Core.AssemblyInfoInputs.cache: -------------------------------------------------------------------------------- 1 | bb70b8d99ff9108d5c8f3ce9e50331d5e1228212 2 | -------------------------------------------------------------------------------- /WebApi/obj/Debug/netcoreapp3.1/WebApi.AssemblyInfoInputs.cache: -------------------------------------------------------------------------------- 1 | 8f845b9fb01b21f877d57dd497d4b62e0d036c22 2 | -------------------------------------------------------------------------------- /WebApi/obj/Debug/netcoreapp3.1/WebApi.genruntimeconfig.cache: -------------------------------------------------------------------------------- 1 | 86c8e15dd33445635927cfaf398408205fd11473 2 | -------------------------------------------------------------------------------- /WebApi/obj/Debug/netcoreapp3.1/staticwebassets/WebApi.StaticWebAssets.xml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /Business/obj/Debug/netstandard2.0/Business.AssemblyInfoInputs.cache: -------------------------------------------------------------------------------- 1 | 4faf343f83fe4ecc4cccc443e97716d83733f999 2 | -------------------------------------------------------------------------------- /ConsoleUI/obj/Debug/netcoreapp3.1/ConsoleUI.AssemblyInfoInputs.cache: -------------------------------------------------------------------------------- 1 | 7dd3e5e18f7a80fc6a80514fc5d7f280648f458b 2 | -------------------------------------------------------------------------------- /ConsoleUI/obj/Debug/netcoreapp3.1/ConsoleUI.genruntimeconfig.cache: -------------------------------------------------------------------------------- 1 | 86c8e15dd33445635927cfaf398408205fd11473 2 | -------------------------------------------------------------------------------- /Core/Entities/IDto.cs: -------------------------------------------------------------------------------- 1 | namespace Core.Entities 2 | { 3 | public class IDto 4 | { 5 | 6 | } 7 | } -------------------------------------------------------------------------------- /Core/obj/Debug/netstandard2.0/Core.csproj.CoreCompileInputs.cache: -------------------------------------------------------------------------------- 1 | e87500a8787654a335f14110582b0c24e1c59662 2 | -------------------------------------------------------------------------------- /Entities/obj/Debug/netstandard2.0/Entities.AssemblyInfoInputs.cache: -------------------------------------------------------------------------------- 1 | 6efefbace1bafaab5616b3f0e8985359045640cb 2 | -------------------------------------------------------------------------------- /WebApi/obj/Debug/netcoreapp3.1/WebApi.RazorComponent.input.cache: -------------------------------------------------------------------------------- 1 | b7cfbaf7c2601dd5f53283123e99823c32135905 2 | -------------------------------------------------------------------------------- /WebApi/obj/Debug/netcoreapp3.1/WebApi.RazorTargetAssemblyInfo.cache: -------------------------------------------------------------------------------- 1 | 4f9b9573d47bbe0b609dc5241376458b039c3d55 2 | -------------------------------------------------------------------------------- /WebApi/obj/Debug/netcoreapp3.1/WebApi.csproj.CoreCompileInputs.cache: -------------------------------------------------------------------------------- 1 | 6e6d633893b47e54e10686f89739ac7086243c55 2 | -------------------------------------------------------------------------------- /Business/obj/Debug/netstandard2.0/Business.csproj.CoreCompileInputs.cache: -------------------------------------------------------------------------------- 1 | 648657b4653f39963a088f73aca8fb47460037e4 2 | -------------------------------------------------------------------------------- /Core/Entities/Dtos/IDto.cs: -------------------------------------------------------------------------------- 1 | namespace Core.Entities 2 | { 3 | public class IDto 4 | { 5 | 6 | } 7 | } -------------------------------------------------------------------------------- /DataAccess/obj/Debug/netstandard2.0/DataAccess.AssemblyInfoInputs.cache: -------------------------------------------------------------------------------- 1 | 6d4e2c1d9f6ac45f776d2f2ae5ef73593c1376b9 2 | -------------------------------------------------------------------------------- /Entities/obj/Debug/netstandard2.0/Entities.csproj.CoreCompileInputs.cache: -------------------------------------------------------------------------------- 1 | 748292f4c594c4d41d56e680f04aa8df0aebf89d 2 | -------------------------------------------------------------------------------- /ConsoleUI/obj/Debug/netcoreapp3.1/ConsoleUI.csproj.CoreCompileInputs.cache: -------------------------------------------------------------------------------- 1 | d9aa80104a82a4674995ecc2fdd4b116d3005499 2 | -------------------------------------------------------------------------------- /DataAccess/obj/Debug/netstandard2.0/DataAccess.csproj.CoreCompileInputs.cache: -------------------------------------------------------------------------------- 1 | c977a24a9b505980e5029795553265bb788a156f 2 | -------------------------------------------------------------------------------- /Core/bin/Debug/netstandard2.0/Core.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Core/bin/Debug/netstandard2.0/Core.dll -------------------------------------------------------------------------------- /Core/bin/Debug/netstandard2.0/Core.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Core/bin/Debug/netstandard2.0/Core.pdb -------------------------------------------------------------------------------- /Core/obj/Debug/netstandard2.0/Core.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Core/obj/Debug/netstandard2.0/Core.dll -------------------------------------------------------------------------------- /Core/obj/Debug/netstandard2.0/Core.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Core/obj/Debug/netstandard2.0/Core.pdb -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Core.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Core.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Core.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Core.pdb -------------------------------------------------------------------------------- /Business/bin/Debug/netstandard2.0/Core.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Business/bin/Debug/netstandard2.0/Core.dll -------------------------------------------------------------------------------- /Business/bin/Debug/netstandard2.0/Core.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Business/bin/Debug/netstandard2.0/Core.pdb -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Core.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Core.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Core.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Core.pdb -------------------------------------------------------------------------------- /Entities/bin/Debug/netstandard2.0/Core.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Entities/bin/Debug/netstandard2.0/Core.dll -------------------------------------------------------------------------------- /Entities/bin/Debug/netstandard2.0/Core.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Entities/bin/Debug/netstandard2.0/Core.pdb -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Autofac.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Autofac.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Business.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Business.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Business.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Business.pdb -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Entities.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Entities.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Entities.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Entities.pdb -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/WebApi.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/WebApi.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/WebApi.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/WebApi.exe -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/WebApi.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/WebApi.pdb -------------------------------------------------------------------------------- /WebApi/obj/Debug/netcoreapp3.1/WebApi.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/obj/Debug/netcoreapp3.1/WebApi.dll -------------------------------------------------------------------------------- /WebApi/obj/Debug/netcoreapp3.1/WebApi.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/obj/Debug/netcoreapp3.1/WebApi.exe -------------------------------------------------------------------------------- /WebApi/obj/Debug/netcoreapp3.1/WebApi.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/obj/Debug/netcoreapp3.1/WebApi.pdb -------------------------------------------------------------------------------- /.vs/ReCapProject/DesignTimeBuild/.dtbcache.v2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/.vs/ReCapProject/DesignTimeBuild/.dtbcache.v2 -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Autofac.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Autofac.dll -------------------------------------------------------------------------------- /DataAccess/bin/Debug/netstandard2.0/Core.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/DataAccess/bin/Debug/netstandard2.0/Core.dll -------------------------------------------------------------------------------- /DataAccess/bin/Debug/netstandard2.0/Core.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/DataAccess/bin/Debug/netstandard2.0/Core.pdb -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/DataAccess.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/DataAccess.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/DataAccess.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/DataAccess.pdb -------------------------------------------------------------------------------- /Business/bin/Debug/netstandard2.0/Business.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Business/bin/Debug/netstandard2.0/Business.dll -------------------------------------------------------------------------------- /Business/bin/Debug/netstandard2.0/Business.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Business/bin/Debug/netstandard2.0/Business.pdb -------------------------------------------------------------------------------- /Business/bin/Debug/netstandard2.0/DataAccess.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Business/bin/Debug/netstandard2.0/DataAccess.dll -------------------------------------------------------------------------------- /Business/bin/Debug/netstandard2.0/DataAccess.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Business/bin/Debug/netstandard2.0/DataAccess.pdb -------------------------------------------------------------------------------- /Business/bin/Debug/netstandard2.0/Entities.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Business/bin/Debug/netstandard2.0/Entities.dll -------------------------------------------------------------------------------- /Business/bin/Debug/netstandard2.0/Entities.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Business/bin/Debug/netstandard2.0/Entities.pdb -------------------------------------------------------------------------------- /Business/obj/Debug/netstandard2.0/Business.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Business/obj/Debug/netstandard2.0/Business.dll -------------------------------------------------------------------------------- /Business/obj/Debug/netstandard2.0/Business.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Business/obj/Debug/netstandard2.0/Business.pdb -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Business.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Business.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Business.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Business.pdb -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/ConsoleUI.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/ConsoleUI.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/ConsoleUI.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/ConsoleUI.exe -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/ConsoleUI.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/ConsoleUI.pdb -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/DataAccess.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/DataAccess.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/DataAccess.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/DataAccess.pdb -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Entities.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Entities.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Entities.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Entities.pdb -------------------------------------------------------------------------------- /ConsoleUI/obj/Debug/netcoreapp3.1/ConsoleUI.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/obj/Debug/netcoreapp3.1/ConsoleUI.dll -------------------------------------------------------------------------------- /ConsoleUI/obj/Debug/netcoreapp3.1/ConsoleUI.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/obj/Debug/netcoreapp3.1/ConsoleUI.exe -------------------------------------------------------------------------------- /ConsoleUI/obj/Debug/netcoreapp3.1/ConsoleUI.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/obj/Debug/netcoreapp3.1/ConsoleUI.pdb -------------------------------------------------------------------------------- /Core/obj/Debug/netstandard2.0/Core.assets.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Core/obj/Debug/netstandard2.0/Core.assets.cache -------------------------------------------------------------------------------- /DataAccess/bin/Debug/netstandard2.0/Entities.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/DataAccess/bin/Debug/netstandard2.0/Entities.dll -------------------------------------------------------------------------------- /DataAccess/bin/Debug/netstandard2.0/Entities.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/DataAccess/bin/Debug/netstandard2.0/Entities.pdb -------------------------------------------------------------------------------- /Entities/bin/Debug/netstandard2.0/Entities.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Entities/bin/Debug/netstandard2.0/Entities.dll -------------------------------------------------------------------------------- /Entities/bin/Debug/netstandard2.0/Entities.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Entities/bin/Debug/netstandard2.0/Entities.pdb -------------------------------------------------------------------------------- /Entities/obj/Debug/netstandard2.0/Entities.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Entities/obj/Debug/netstandard2.0/Entities.dll -------------------------------------------------------------------------------- /Entities/obj/Debug/netstandard2.0/Entities.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Entities/obj/Debug/netstandard2.0/Entities.pdb -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Castle.Core.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Castle.Core.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Castle.Core.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Castle.Core.dll -------------------------------------------------------------------------------- /DataAccess/bin/Debug/netstandard2.0/DataAccess.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/DataAccess/bin/Debug/netstandard2.0/DataAccess.dll -------------------------------------------------------------------------------- /DataAccess/bin/Debug/netstandard2.0/DataAccess.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/DataAccess/bin/Debug/netstandard2.0/DataAccess.pdb -------------------------------------------------------------------------------- /DataAccess/obj/Debug/netstandard2.0/DataAccess.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/DataAccess/obj/Debug/netstandard2.0/DataAccess.dll -------------------------------------------------------------------------------- /DataAccess/obj/Debug/netstandard2.0/DataAccess.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/DataAccess/obj/Debug/netstandard2.0/DataAccess.pdb -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Newtonsoft.Json.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Newtonsoft.Json.dll -------------------------------------------------------------------------------- /WebApi/obj/Debug/netcoreapp3.1/WebApi.assets.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/obj/Debug/netcoreapp3.1/WebApi.assets.cache -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Newtonsoft.Json.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Newtonsoft.Json.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/FluentValidation.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/FluentValidation.dll -------------------------------------------------------------------------------- /Business/obj/Debug/netstandard2.0/Business.assets.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Business/obj/Debug/netstandard2.0/Business.assets.cache -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/FluentValidation.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/FluentValidation.dll -------------------------------------------------------------------------------- /Entities/obj/Debug/netstandard2.0/Entities.assets.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Entities/obj/Debug/netstandard2.0/Entities.assets.cache -------------------------------------------------------------------------------- /ConsoleUI/obj/Debug/netcoreapp3.1/ConsoleUI.assets.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/obj/Debug/netcoreapp3.1/ConsoleUI.assets.cache -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.Bcl.HashCode.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.Bcl.HashCode.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/System.Runtime.Caching.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/System.Runtime.Caching.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Bcl.HashCode.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Bcl.HashCode.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/System.Runtime.Caching.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/System.Runtime.Caching.dll -------------------------------------------------------------------------------- /DataAccess/obj/Debug/netstandard2.0/DataAccess.assets.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/DataAccess/obj/Debug/netstandard2.0/DataAccess.assets.cache -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.Data.SqlClient.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.Data.SqlClient.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.Identity.Client.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.Identity.Client.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.AspNetCore.Http.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.AspNetCore.Http.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Data.SqlClient.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Data.SqlClient.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Identity.Client.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Identity.Client.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Autofac.Extras.DynamicProxy.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Autofac.Extras.DynamicProxy.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Logging.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Logging.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Options.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Options.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/System.Collections.Immutable.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/System.Collections.Immutable.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/runtimes/win-x64/native/sni.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/runtimes/win-x64/native/sni.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/runtimes/win-x86/native/sni.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/runtimes/win-x86/native/sni.dll -------------------------------------------------------------------------------- /WebApi/wwwroot/images/226017ad-ca96-43bf-b1a8-967ba49f1a1b.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/wwwroot/images/226017ad-ca96-43bf-b1a8-967ba49f1a1b.jpg -------------------------------------------------------------------------------- /WebApi/wwwroot/images/8b329fe2-4e1a-48dc-8aa4-fb28ed2df70c.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/wwwroot/images/8b329fe2-4e1a-48dc-8aa4-fb28ed2df70c.jpg -------------------------------------------------------------------------------- /WebApi/wwwroot/images/bf40a279-d008-4c01-9983-d3dbcfa3099e.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/wwwroot/images/bf40a279-d008-4c01-9983-d3dbcfa3099e.jpg -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Autofac.Extras.DynamicProxy.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Autofac.Extras.DynamicProxy.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Net.Http.Headers.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Net.Http.Headers.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/System.Security.Permissions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/System.Security.Permissions.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/win-x64/native/sni.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/win-x64/native/sni.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/win-x86/native/sni.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/win-x86/native/sni.dll -------------------------------------------------------------------------------- /Core/obj/Debug/netstandard2.0/Core.csprojAssemblyReference.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Core/obj/Debug/netstandard2.0/Core.csprojAssemblyReference.cache -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.Bcl.AsyncInterfaces.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.Bcl.AsyncInterfaces.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Tokens.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Tokens.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/runtimes/win-arm64/native/sni.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/runtimes/win-arm64/native/sni.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Bcl.AsyncInterfaces.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Bcl.AsyncInterfaces.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Logging.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Logging.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Options.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Options.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Tokens.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Tokens.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/System.Collections.Immutable.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/System.Collections.Immutable.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/win-arm64/native/sni.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/win-arm64/native/sni.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Primitives.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Primitives.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Logging.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Logging.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Protocols.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Protocols.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/System.IdentityModel.Tokens.Jwt.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/System.IdentityModel.Tokens.Jwt.dll -------------------------------------------------------------------------------- /WebApi/obj/Debug/netcoreapp3.1/WebApi.csprojAssemblyReference.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/obj/Debug/netcoreapp3.1/WebApi.csprojAssemblyReference.cache -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.ObjectPool.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.ObjectPool.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Primitives.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Primitives.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Logging.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Logging.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/System.IdentityModel.Tokens.Jwt.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/System.IdentityModel.Tokens.Jwt.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Caching.Memory.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Caching.Memory.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Configuration.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Configuration.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/System.Diagnostics.DiagnosticSource.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/System.Diagnostics.DiagnosticSource.dll -------------------------------------------------------------------------------- /Business/obj/Debug/netstandard2.0/Business.csprojAssemblyReference.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Business/obj/Debug/netstandard2.0/Business.csprojAssemblyReference.cache -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.AspNetCore.Http.Features.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.AspNetCore.Http.Features.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.AspNetCore.WebUtilities.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.AspNetCore.WebUtilities.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Caching.Memory.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Caching.Memory.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Configuration.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Configuration.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Protocols.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Protocols.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/System.Diagnostics.DiagnosticSource.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/System.Diagnostics.DiagnosticSource.dll -------------------------------------------------------------------------------- /ConsoleUI/obj/Debug/netcoreapp3.1/ConsoleUI.csprojAssemblyReference.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/obj/Debug/netcoreapp3.1/ConsoleUI.csprojAssemblyReference.cache -------------------------------------------------------------------------------- /Entities/obj/Debug/netstandard2.0/Entities.csprojAssemblyReference.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/Entities/obj/Debug/netstandard2.0/Entities.csprojAssemblyReference.cache -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Autofac.Extensions.DependencyInjection.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Autofac.Extensions.DependencyInjection.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.JsonWebTokens.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.JsonWebTokens.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.Design.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.Design.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.JsonWebTokens.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.JsonWebTokens.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.Relational.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.Relational.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.SqlServer.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.SqlServer.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.DependencyInjection.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.DependencyInjection.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Autofac.Extensions.DependencyInjection.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Autofac.Extensions.DependencyInjection.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.AspNetCore.Http.Abstractions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.AspNetCore.Http.Abstractions.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.Relational.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.Relational.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.SqlServer.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.SqlServer.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.DependencyInjection.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.DependencyInjection.dll -------------------------------------------------------------------------------- /Core/Entities/IEntity.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Core.Entities 6 | { 7 | public interface IEntity 8 | { 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /DataAccess/obj/Debug/netstandard2.0/DataAccess.csprojAssemblyReference.cache: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/DataAccess/obj/Debug/netstandard2.0/DataAccess.csprojAssemblyReference.cache -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.Abstractions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.Abstractions.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Caching.Abstractions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Caching.Abstractions.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Configuration.Binder.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Configuration.Binder.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Logging.Abstractions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Logging.Abstractions.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/System.Configuration.ConfigurationManager.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/System.Configuration.ConfigurationManager.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/System.Security.Cryptography.ProtectedData.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/System.Security.Cryptography.ProtectedData.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.AspNetCore.Hosting.Abstractions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.AspNetCore.Hosting.Abstractions.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.Abstractions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.EntityFrameworkCore.Abstractions.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Caching.Abstractions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Caching.Abstractions.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Configuration.Binder.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Configuration.Binder.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Hosting.Abstractions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Hosting.Abstractions.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Logging.Abstractions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Logging.Abstractions.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/System.Configuration.ConfigurationManager.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/System.Configuration.ConfigurationManager.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/System.Security.Cryptography.ProtectedData.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/System.Security.Cryptography.ProtectedData.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.AspNetCore.Authentication.JwtBearer.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.AspNetCore.Authentication.JwtBearer.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Configuration.Abstractions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Configuration.Abstractions.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Protocols.OpenIdConnect.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Protocols.OpenIdConnect.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Configuration.Abstractions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.Configuration.Abstractions.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.FileProviders.Abstractions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.FileProviders.Abstractions.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Protocols.OpenIdConnect.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.IdentityModel.Protocols.OpenIdConnect.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.AspNetCore.Hosting.Server.Abstractions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.AspNetCore.Hosting.Server.Abstractions.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.DependencyInjection.Abstractions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/Microsoft.Extensions.DependencyInjection.Abstractions.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/runtimes/win/lib/netcoreapp2.0/System.Runtime.Caching.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/runtimes/win/lib/netcoreapp2.0/System.Runtime.Caching.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/runtimes/unix/lib/netcoreapp2.0/System.Runtime.Caching.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/runtimes/unix/lib/netcoreapp2.0/System.Runtime.Caching.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/runtimes/win/lib/netcoreapp2.1/Microsoft.Data.SqlClient.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/runtimes/win/lib/netcoreapp2.1/Microsoft.Data.SqlClient.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/ConsoleUI.runtimeconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "runtimeOptions": { 3 | "tfm": "netcoreapp3.1", 4 | "framework": { 5 | "name": "Microsoft.NETCore.App", 6 | "version": "3.1.0" 7 | } 8 | } 9 | } -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.DependencyInjection.Abstractions.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/Microsoft.Extensions.DependencyInjection.Abstractions.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/unix/lib/netcoreapp2.0/System.Runtime.Caching.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/unix/lib/netcoreapp2.0/System.Runtime.Caching.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/win/lib/netcoreapp2.0/System.Runtime.Caching.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/win/lib/netcoreapp2.0/System.Runtime.Caching.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/win/lib/netcoreapp2.1/Microsoft.Data.SqlClient.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/win/lib/netcoreapp2.1/Microsoft.Data.SqlClient.dll -------------------------------------------------------------------------------- /WebApi/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "LogLevel": { 4 | "Default": "Information", 5 | "Microsoft": "Warning", 6 | "Microsoft.Hosting.Lifetime": "Information" 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/runtimes/unix/lib/netcoreapp2.1/Microsoft.Data.SqlClient.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/runtimes/unix/lib/netcoreapp2.1/Microsoft.Data.SqlClient.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/unix/lib/netcoreapp2.1/Microsoft.Data.SqlClient.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/unix/lib/netcoreapp2.1/Microsoft.Data.SqlClient.dll -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/WebApi.runtimeconfig.dev.json: -------------------------------------------------------------------------------- 1 | { 2 | "runtimeOptions": { 3 | "additionalProbingPaths": [ 4 | "C:\\Users\\PC\\.dotnet\\store\\|arch|\\|tfm|", 5 | "C:\\Users\\PC\\.nuget\\packages" 6 | ] 7 | } 8 | } -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/ConsoleUI.runtimeconfig.dev.json: -------------------------------------------------------------------------------- 1 | { 2 | "runtimeOptions": { 3 | "additionalProbingPaths": [ 4 | "C:\\Users\\PC\\.dotnet\\store\\|arch|\\|tfm|", 5 | "C:\\Users\\PC\\.nuget\\packages" 6 | ] 7 | } 8 | } -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "LogLevel": { 4 | "Default": "Information", 5 | "Microsoft": "Warning", 6 | "Microsoft.Hosting.Lifetime": "Information" 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /DataAccess/DataAccess.csproj.user: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | false 5 | 6 | -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/runtimes/win/lib/netstandard2.0/System.Security.Cryptography.ProtectedData.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/WebApi/bin/Debug/netcoreapp3.1/runtimes/win/lib/netstandard2.0/System.Security.Cryptography.ProtectedData.dll -------------------------------------------------------------------------------- /ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/win/lib/netstandard2.0/System.Security.Cryptography.ProtectedData.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cemcicek/ReCapProject/HEAD/ConsoleUI/bin/Debug/netcoreapp3.1/runtimes/win/lib/netstandard2.0/System.Security.Cryptography.ProtectedData.dll -------------------------------------------------------------------------------- /ConsoleUI/obj/Debug/netcoreapp3.1/.NETCoreApp,Version=v3.1.AssemblyAttributes.cs: -------------------------------------------------------------------------------- 1 | // 2 | using System; 3 | using System.Reflection; 4 | [assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v3.1", FrameworkDisplayName = "")] 5 | -------------------------------------------------------------------------------- /Core/obj/Debug/netstandard2.0/.NETStandard,Version=v2.0.AssemblyAttributes.cs: -------------------------------------------------------------------------------- 1 | // 2 | using System; 3 | using System.Reflection; 4 | [assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETStandard,Version=v2.0", FrameworkDisplayName = "")] 5 | -------------------------------------------------------------------------------- /WebApi/obj/Debug/netcoreapp3.1/.NETCoreApp,Version=v3.1.AssemblyAttributes.cs: -------------------------------------------------------------------------------- 1 | // 2 | using System; 3 | using System.Reflection; 4 | [assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v3.1", FrameworkDisplayName = "")] 5 | -------------------------------------------------------------------------------- /Business/obj/Debug/netstandard2.0/.NETStandard,Version=v2.0.AssemblyAttributes.cs: -------------------------------------------------------------------------------- 1 | // 2 | using System; 3 | using System.Reflection; 4 | [assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETStandard,Version=v2.0", FrameworkDisplayName = "")] 5 | -------------------------------------------------------------------------------- /DataAccess/obj/Debug/netstandard2.0/.NETStandard,Version=v2.0.AssemblyAttributes.cs: -------------------------------------------------------------------------------- 1 | // 2 | using System; 3 | using System.Reflection; 4 | [assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETStandard,Version=v2.0", FrameworkDisplayName = "")] 5 | -------------------------------------------------------------------------------- /Entities/obj/Debug/netstandard2.0/.NETStandard,Version=v2.0.AssemblyAttributes.cs: -------------------------------------------------------------------------------- 1 | // 2 | using System; 3 | using System.Reflection; 4 | [assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETStandard,Version=v2.0", FrameworkDisplayName = "")] 5 | -------------------------------------------------------------------------------- /Core/Utilites/Results/Abstract/IDataResult.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Core.Utilites.Results.Abstract 6 | { 7 | public interface IDataResult:IResult 8 | { 9 | T Data { get; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Entities/Concrete/Payment.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Entities; 5 | 6 | namespace Entities.Concrete 7 | { 8 | public class Payment : IEntity 9 | { 10 | public decimal Amount { get; set; } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /Entities/Entities.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netstandard2.0 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /Core/Utilites/Results/Abstract/IResult.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Core.Utilites.Results.Abstract 6 | { 7 | public interface IResult 8 | { 9 | bool Success { get; } 10 | string Message { get; } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /DataAccess/Abstract/ICarImageDal.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.DataAccess; 5 | using Entities.Concrete; 6 | 7 | namespace DataAccess.Abstract 8 | { 9 | public interface ICarImageDal : IEntityRepository 10 | { 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /DataAccess/Abstract/IColorDal.cs: -------------------------------------------------------------------------------- 1 | using Core.DataAccess; 2 | using Entities.Concrete; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace DataAccess.Abstract 8 | { 9 | public interface IColorDal: IEntityRepository 10 | { 11 | 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/WebApi.runtimeconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "runtimeOptions": { 3 | "tfm": "netcoreapp3.1", 4 | "framework": { 5 | "name": "Microsoft.AspNetCore.App", 6 | "version": "3.1.0" 7 | }, 8 | "configProperties": { 9 | "System.GC.Server": true 10 | } 11 | } 12 | } -------------------------------------------------------------------------------- /DataAccess/Abstract/IBrandDal.cs: -------------------------------------------------------------------------------- 1 | using Core.DataAccess; 2 | using Entities.Concrete; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace DataAccess.Abstract 8 | { 9 | public interface IBrandDal : IEntityRepository 10 | { 11 | 12 | } 13 | 14 | } 15 | -------------------------------------------------------------------------------- /Core/Entities/Concrete/OperationClaim.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Core.Entities.Concrete 6 | { 7 | public class OperationClaim:IEntity 8 | { 9 | public int Id { get; set; } 10 | public string Name { get; set; } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /Core/Entities/Dtos/UserForLoginDto.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Core.Entities.Dtos 6 | { 7 | public class UserForLoginDto : IDto 8 | { 9 | public string Email { get; set; } 10 | public string Password { get; set; } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /Core/Utilites/Security/JWT/AccessToken.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Core.Utilites.Security.JWT 6 | { 7 | public class AccessToken 8 | { 9 | public string Token { get; set; } 10 | public DateTime Expiration { get; set; } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /Entities/Concrete/Brand.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Entities; 5 | 6 | namespace Entities.Concrete 7 | { 8 | public class Brand : IEntity 9 | { 10 | public int BrandId { get; set; } 11 | public string BrandName { get; set; } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /WebApi/obj/WebApi.csproj.nuget.g.targets: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 5 | 6 | -------------------------------------------------------------------------------- /ConsoleUI/obj/ConsoleUI.csproj.nuget.g.targets: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 5 | 6 | -------------------------------------------------------------------------------- /Core/Utilites/IoC/ICoreModule.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Microsoft.Extensions.DependencyInjection; 5 | 6 | namespace Core.Utilites.IoC 7 | { 8 | public interface ICoreModule 9 | { 10 | void Load(IServiceCollection serviceCollection); 11 | 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Entities/Concrete/Color.cs: -------------------------------------------------------------------------------- 1 | 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | using Core.Entities; 6 | 7 | namespace Entities.Concrete 8 | { 9 | public class Color : IEntity 10 | { 11 | public int ColorId { get; set; } 12 | public string ColorName { get; set; } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Entities/DTOs/RentalPaymentDto.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Entities.Concrete; 5 | 6 | namespace Entities.DTOs 7 | { 8 | public class RentalPaymentDto 9 | { 10 | public Rental Rental { get; set; } 11 | public Payment Payment { get; set; } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Entities/DTOs/UserForLoginDto.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Entities; 5 | 6 | namespace Entities.DTOs 7 | { 8 | public class UserForLoginDto : IDto 9 | { 10 | public string Email { get; set; } 11 | public string Password { get; set; } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Business/Abstract/IPaymentService.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Utilites.Results.Abstract; 5 | using Entities.Concrete; 6 | 7 | namespace Business.Abstract 8 | { 9 | public interface IPaymentService 10 | { 11 | IResult ReceivePayment(Payment payment); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /WebApi/WeatherForecast.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace WebApi 4 | { 5 | public class WeatherForecast 6 | { 7 | public DateTime Date { get; set; } 8 | 9 | public int TemperatureC { get; set; } 10 | 11 | public int TemperatureF => 32 + (int)(TemperatureC / 0.5556); 12 | 13 | public string Summary { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Core/Entities/Concrete/UserOperationClaim.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Core.Entities.Concrete 6 | { 7 | public class UserOperationClaim:IEntity 8 | { 9 | public int Id { get; set; } 10 | public int UserId { get; set; } 11 | public int OperationClaimId { get; set; } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Core/Utilites/Security/JWT/ITokenHelper.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Entities.Concrete; 5 | using Entities.Concrete; 6 | 7 | namespace Core.Utilites.Security.JWT 8 | { 9 | public interface ITokenHelper 10 | { 11 | AccessToken CreateToken(User user, List operationClaims); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /DataAccess/Abstract/IUserDal.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.DataAccess; 5 | using Core.Entities.Concrete; 6 | using Entities.Concrete; 7 | 8 | namespace DataAccess.Abstract 9 | { 10 | public interface IUserDal: IEntityRepository 11 | { 12 | List GetClaims(User user); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Entities/Concrete/Customer.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Entities; 5 | 6 | namespace Entities.Concrete 7 | { 8 | public class Customer: IEntity 9 | { 10 | public int Id { get; set; } 11 | public int UserId { get; set; } 12 | public string CompanyName { get; set; } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Entities/DTOs/CarDetailAndImagesDto.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Entities; 5 | using Entities.Concrete; 6 | 7 | namespace Entities.DTOs 8 | { 9 | public class CarDetailAndImagesDto:IDto 10 | { 11 | public CarDetailDto Car { get; set; } 12 | public List CarImages { get; set; } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /WebApi/WebApi.csproj.user: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | ApiControllerEmptyScaffolder 5 | root/Common/Api 6 | 7 | -------------------------------------------------------------------------------- /Core/Entities/Dtos/UserForRegisterDto.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Core.Entities.Dtos 6 | { 7 | public class UserForRegisterDto:IDto 8 | { 9 | public string FirstName { get; set; } 10 | public string LastName { get; set; } 11 | public string Email { get; set; } 12 | public string Password { get; set; } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /DataAccess/Abstract/ICustomerDal.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq.Expressions; 4 | using System.Text; 5 | using Core.DataAccess; 6 | using Entities.Concrete; 7 | using Entities.DTOs; 8 | 9 | namespace DataAccess.Abstract 10 | { 11 | public interface ICustomerDal : IEntityRepository 12 | { 13 | List GetCustomerDetailDto(); 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Entities/DTOs/CarImagesOperationDto.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Entities; 5 | using Microsoft.AspNetCore.Http; 6 | 7 | namespace Entities.DTOs 8 | { 9 | public class CarImagesOperationDto: IDto 10 | { 11 | public int Id { get; set; } 12 | public int CarId { get; set; } 13 | public List Images { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Core/Utilites/Results/Concrete/ErrorResult.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Core.Utilites.Results.Concrete 6 | { 7 | public class ErrorResult : Result 8 | { 9 | public ErrorResult(string message) : base(false, message) 10 | { 11 | 12 | } 13 | 14 | public ErrorResult() : base(false) 15 | { 16 | 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Core/Utilites/Security/JWT/TokenOptions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Core.Utilites.Security.JWT 6 | { 7 | public class TokenOptions 8 | { 9 | public string Audience { get; set; } 10 | public string Issuer { get; set; } 11 | public int AccessTokenExpiration { get; set; } 12 | public string SecurityKey { get; set; } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Core/Utilites/Results/Concrete/SuccessResult.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Core.Utilites.Results.Concrete 6 | { 7 | public class SuccessResult : Result 8 | { 9 | public SuccessResult(string message) : base(true, message) 10 | { 11 | 12 | } 13 | 14 | public SuccessResult() : base(true) 15 | { 16 | 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Entities/DTOs/UserForRegisterDto.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Entities; 5 | 6 | namespace Entities.DTOs 7 | { 8 | public class UserForRegisterDto:IDto 9 | { 10 | public string FirstName { get; set; } 11 | public string LastName { get; set; } 12 | public string Email { get; set; } 13 | public string Password { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Entities/DTOs/CustomerDetailDto.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Entities; 5 | 6 | namespace Entities.DTOs 7 | { 8 | public class CustomerDetailDto : IDto 9 | { 10 | public int CustomerId { get; set; } 11 | public string CompanyName { get; set; } 12 | public string FirstName { get; set; } 13 | public string LastName { get; set; } 14 | 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /DataAccess/Abstract/IRentalDal.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq.Expressions; 4 | using System.Text; 5 | using Core.DataAccess; 6 | using Entities.Concrete; 7 | using Entities.DTOs; 8 | 9 | namespace DataAccess.Abstract 10 | { 11 | public interface IRentalDal : IEntityRepository 12 | { 13 | List GetAllRentalDetails(Expression> filter = null); 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Business/ValidationRules/FluentValidation/ColorValidator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Entities.Concrete; 5 | using FluentValidation; 6 | 7 | namespace Business.ValidationRules.FluentValidation 8 | { 9 | public class ColorValidator :AbstractValidator 10 | { 11 | public ColorValidator() 12 | { 13 | RuleFor(c => c.ColorName).NotEmpty(); 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Entities/Concrete/User.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Entities; 5 | 6 | namespace Entities.Concrete 7 | { 8 | public class User : IEntity 9 | { 10 | public int Id { get; set; } 11 | public string FirstName { get; set; } 12 | public string LastName { get; set; } 13 | public string Email { get; set; } 14 | public string Password { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Business/ValidationRules/FluentValidation/BrandValidator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Entities.Concrete; 5 | using FluentValidation; 6 | 7 | namespace Business.ValidationRules.FluentValidation 8 | { 9 | public class BrandValidator: AbstractValidator 10 | { 11 | public BrandValidator() 12 | { 13 | RuleFor(b => b.BrandName).MinimumLength(2); 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Core/Extensions/ExceptionMiddlewareExtensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Microsoft.AspNetCore.Builder; 5 | 6 | namespace Core.Extensions 7 | { 8 | public static class ExceptionMiddlewareExtensions 9 | { 10 | public static void ConfigureCustomExceptionMiddleware(this IApplicationBuilder app) 11 | { 12 | app.UseMiddleware(); 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Entities/Concrete/Rental.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Entities; 5 | 6 | namespace Entities.Concrete 7 | { 8 | public class Rental : IEntity 9 | { 10 | public int Id { get; set; } 11 | public int CarId { get; set; } 12 | public int CustomerId { get; set; } 13 | public DateTime RentDate { get; set; } 14 | public DateTime? ReturnDate { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Business/ValidationRules/FluentValidation/CustomerValidator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Entities.Concrete; 5 | using FluentValidation; 6 | 7 | namespace Business.ValidationRules.FluentValidation 8 | { 9 | public class CustomerValidator:AbstractValidator 10 | { 11 | public CustomerValidator() 12 | { 13 | RuleFor(c => c.CompanyName).NotEmpty(); 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Core/Utilites/Security/Encryption/SecurityKeyHelper.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Microsoft.IdentityModel.Tokens; 5 | 6 | namespace Core.Utilites.Security.Encryption 7 | { 8 | public class SecurityKeyHelper 9 | { 10 | public static SecurityKey CreateSecurityKey(string securityKey) 11 | { 12 | return new SymmetricSecurityKey(Encoding.UTF8.GetBytes(securityKey)); 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /DataAccess/Abstract/ICarDal.cs: -------------------------------------------------------------------------------- 1 | using Core.DataAccess; 2 | using Entities.Concrete; 3 | using Entities.DTOs; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Linq.Expressions; 7 | using System.Text; 8 | 9 | namespace DataAccess.Abstract 10 | { 11 | public interface ICarDal : IEntityRepository 12 | { 13 | CarDetailDto GetCarDetail(int carId); 14 | List GetCarsDetail(Expression> filter = null); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /DataAccess/Concrete/EntityFramework/Repository/EfCarImageDal.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.DataAccess.EntityFramework; 5 | using DataAccess.Abstract; 6 | using DataAccess.Concrete.EntityFramework.Context; 7 | using Entities.Concrete; 8 | 9 | namespace DataAccess.Concrete.EntityFramework.Repository 10 | { 11 | public class EfCarImageDal: EfEntityRepositoryBase, ICarImageDal 12 | { 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Business/Abstract/IColorService.cs: -------------------------------------------------------------------------------- 1 | using Core.Utilites.Results.Abstract; 2 | using Entities.Concrete; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Business.Abstract 8 | { 9 | public interface IColorService 10 | { 11 | IResult Add(Color color); 12 | IResult Update(Color color); 13 | IResult Delete(Color color); 14 | IDataResult> GetAll(); 15 | 16 | IDataResult GetById(int id); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /WebApi/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "TokenOptions": { 3 | "Audience": "cemcicek@cemcicek.com", 4 | "Issuer": "cemcicek@cemcicek.com", 5 | "AccessTokenExpiration": 10, 6 | "SecurityKey": "mysecuritykeymysecuritykeymysecuritykey" 7 | }, 8 | "Logging": { 9 | "LogLevel": { 10 | "Default": "Information", 11 | "Microsoft": "Warning", 12 | "Microsoft.Hosting.Lifetime": "Information" 13 | } 14 | }, 15 | "AllowedHosts": "*" 16 | } -------------------------------------------------------------------------------- /Business/Abstract/IBrandService.cs: -------------------------------------------------------------------------------- 1 | using Core.Utilites.Results.Abstract; 2 | using Entities.Concrete; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Business.Abstract 8 | { 9 | public interface IBrandService 10 | { 11 | IResult Add(Brand brand); 12 | IResult Update(Brand brand); 13 | IResult Delete(Brand brand); 14 | IDataResult> GetAll(); 15 | 16 | IDataResult GetById(int id); 17 | 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Entities/Concrete/CarImage.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Entities; 5 | 6 | namespace Entities.Concrete 7 | { 8 | public class CarImage:IEntity 9 | { 10 | public CarImage() 11 | { 12 | Date = DateTime.Now; 13 | } 14 | public int Id { get; set; } 15 | public int CarId { get; set; } 16 | public string ImagePath { get; set; } 17 | public DateTime Date { get; set; } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Business/ValidationRules/FluentValidation/CarValidator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Entities.Concrete; 5 | using FluentValidation; 6 | 7 | namespace Business.ValidationRules.FluentValidation 8 | { 9 | public class CarValidator: AbstractValidator 10 | { 11 | public CarValidator() 12 | { 13 | RuleFor(c => c.DailyPrice).GreaterThan(0).WithMessage("Aracın günlük kira bedeli 0 dan büyük olmalıdır."); 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Core/Utilites/Security/Encryption/SigningCredentialsHelper.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Microsoft.IdentityModel.Tokens; 5 | 6 | namespace Core.Utilites.Security.Encryption 7 | { 8 | public class SigningCredentialsHelper 9 | { 10 | public static SigningCredentials CreateSigningCredentials(SecurityKey securityKey) 11 | { 12 | return new SigningCredentials(securityKey, SecurityAlgorithms.HmacSha512Signature); 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "TokenOptions": { 3 | "Audience": "cemcicek@cemcicek.com", 4 | "Issuer": "cemcicek@cemcicek.com", 5 | "AccessTokenExpiration": 10, 6 | "SecurityKey": "mysecuritykeymysecuritykeymysecuritykey" 7 | }, 8 | "Logging": { 9 | "LogLevel": { 10 | "Default": "Information", 11 | "Microsoft": "Warning", 12 | "Microsoft.Hosting.Lifetime": "Information" 13 | } 14 | }, 15 | "AllowedHosts": "*" 16 | } -------------------------------------------------------------------------------- /Entities/Concrete/Car.cs: -------------------------------------------------------------------------------- 1 | 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | using Core.Entities; 6 | 7 | namespace Entities.Concrete 8 | { 9 | public class Car : IEntity 10 | { 11 | public int CarId { get; set; } 12 | public int ModelYear { get; set; } 13 | public decimal DailyPrice { get; set; } 14 | public string Descriptions { get; set; } 15 | public int BrandId { get; set; } 16 | public int ColorId { get; set; } 17 | 18 | 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /Core/DataAccess/IEntityRepository.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq.Expressions; 4 | using System.Text; 5 | using Core.Entities; 6 | 7 | namespace Core.DataAccess 8 | { 9 | public interface IEntityRepository where T : class, IEntity, new() 10 | { 11 | void Add(T entity); 12 | void Update(T entity); 13 | void Delete(T entity); 14 | List GetAll(Expression> filter = null); 15 | T Get(Expression> filter); 16 | 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /Core/Utilites/IoC/ServiceTool.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Microsoft.Extensions.DependencyInjection; 5 | 6 | namespace Core.Utilites.IoC 7 | { 8 | public static class ServiceTool 9 | { 10 | public static IServiceProvider ServiceProvider { get; private set; } 11 | 12 | public static IServiceCollection Create(IServiceCollection services) 13 | { 14 | ServiceProvider = services.BuildServiceProvider(); 15 | return services; 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /Business/ValidationRules/FluentValidation/CarImageValidator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Entities.Concrete; 5 | using FluentValidation; 6 | 7 | namespace Business.ValidationRules.FluentValidation 8 | { 9 | public class CarImageValidator:AbstractValidator 10 | { 11 | public CarImageValidator() 12 | { 13 | RuleFor(c => c.CarId).NotEmpty(); 14 | RuleFor(c => c.Date).NotEmpty(); 15 | RuleFor(c => c.ImagePath).NotEmpty(); 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /Core/Entities/Concrete/User.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Entities; 5 | 6 | namespace Entities.Concrete 7 | { 8 | public class User : IEntity 9 | { 10 | public int Id { get; set; } 11 | public string FirstName { get; set; } 12 | public string LastName { get; set; } 13 | public string Email { get; set; } 14 | public byte[] PasswordHash { get; set; } 15 | public byte[] PasswordSalt { get; set; } 16 | public bool Status { get; set; } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /Core/CrossCuttingConcerns/Caching/ICacheManager.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Core.CrossCuttingConcerns.Caching 6 | { 7 | public interface ICacheManager 8 | { 9 | T Get(string key); 10 | object Get(string key); 11 | void Add(string key, object value, int duration); 12 | bool IsAdd(string key); 13 | void Remove(string key); 14 | 15 | // başı sonu önemli değil - örneğin içinde category olanları 16 | void RemoveByPattern(string pattern); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /Business/ValidationRules/FluentValidation/UserValidator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Entities.Concrete; 5 | using FluentValidation; 6 | 7 | namespace Business.ValidationRules.FluentValidation 8 | { 9 | public class UserValidator : AbstractValidator 10 | { 11 | public UserValidator() 12 | { 13 | RuleFor(u => u.FirstName).NotEmpty(); 14 | 15 | RuleFor(u => u.Email).NotEmpty(); 16 | RuleFor(u => u.Email).EmailAddress(); 17 | 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /DataAccess/Concrete/EntityFramework/Repository/EfColorDal.cs: -------------------------------------------------------------------------------- 1 | using Core.DataAccess.EntityFramework; 2 | using DataAccess.Abstract; 3 | using DataAccess.Concrete.EntityFramework.Context; 4 | using Entities.Concrete; 5 | using Microsoft.EntityFrameworkCore; 6 | using System; 7 | using System.Collections.Generic; 8 | using System.Linq; 9 | using System.Linq.Expressions; 10 | using System.Text; 11 | 12 | namespace DataAccess.Concrete.EntityFramework.Repository 13 | { 14 | public class EfColorDal : EfEntityRepositoryBase, IColorDal 15 | { 16 | 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /Core/Utilites/Interceptors/MethodInterceptionBaseAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Castle.DynamicProxy; 5 | 6 | namespace Core.Utilites.Interceptors 7 | { 8 | [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method, AllowMultiple = true, Inherited = true)] 9 | public abstract class MethodInterceptionBaseAttribute : Attribute, IInterceptor 10 | { 11 | public int Priority { get; set; } 12 | 13 | public virtual void Intercept(IInvocation invocation) 14 | { 15 | 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /DataAccess/Concrete/EntityFramework/Repository/EfBrandDal.cs: -------------------------------------------------------------------------------- 1 | using Core.DataAccess.EntityFramework; 2 | using DataAccess.Abstract; 3 | using DataAccess.Concrete.EntityFramework.Context; 4 | using Entities.Concrete; 5 | using System; 6 | using System.Collections.Generic; 7 | using System.Linq; 8 | using System.Linq.Expressions; 9 | using System.Text; 10 | 11 | using Microsoft.EntityFrameworkCore; 12 | 13 | namespace DataAccess.Concrete.EntityFramework.Repository 14 | { 15 | public class EfBrandDal : EfEntityRepositoryBase, IBrandDal 16 | { 17 | 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Business/ValidationRules/FluentValidation/RentalValidator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Entities.Concrete; 5 | using FluentValidation; 6 | 7 | namespace Business.ValidationRules.FluentValidation 8 | { 9 | public class RentalValidator:AbstractValidator 10 | { 11 | public RentalValidator() 12 | { 13 | RuleFor(rental => rental.CarId).NotEmpty(); 14 | RuleFor(rental => rental.CustomerId).NotEmpty(); 15 | RuleFor(rental => rental.RentDate).NotEmpty(); 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /Entities/DTOs/CarDetailDto.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core; 5 | using Core.Entities; 6 | 7 | namespace Entities.DTOs 8 | { 9 | public class CarDetailDto:IDto 10 | { 11 | public int CarId { get; set; } 12 | public int ModelYear { get; set; } 13 | public decimal DailyPrice { get; set; } 14 | public string Descriptions { get; set; } 15 | public string ColorName { get; set; } 16 | public string BrandName { get; set; } 17 | public bool Status { get; set; } 18 | 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /Core/Utilites/Results/Concrete/Result.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Utilites.Results.Abstract; 5 | 6 | namespace Core.Utilites.Results.Concrete 7 | { 8 | public class Result : IResult 9 | { 10 | public Result(bool success, string message) : this(success) 11 | { 12 | Message = message; 13 | } 14 | public Result(bool success) 15 | { 16 | Success = success; 17 | } 18 | public bool Success { get; } 19 | 20 | public string Message { get; } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /Business/Constants/DefaultNameOrPath.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using System.IO; 5 | 6 | namespace Business.Constants 7 | { 8 | public static class DefaultNameOrPath 9 | { 10 | public static string ImageDirectory = "images"; // Klasör adı 11 | public static string FileDirectory = "files"; // Klasör Adı 12 | public static string TestDirectory = "images/sub1/sub2/sub3/sub4/sub5/sub6/sub7/sub8/sub9"; // Test Path adı 13 | public static string NoImagePath = ImageDirectory + "/NoImage.jpg"; // Sabit resim yolu 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Core/Utilites/Results/Concrete/DataResult.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Utilites.Results.Abstract; 5 | 6 | namespace Core.Utilites.Results.Concrete 7 | { 8 | public class DataResult : Result, IDataResult 9 | { 10 | public DataResult(T data, bool success, string message) : base(success, message) 11 | { 12 | Data = data; 13 | } 14 | public DataResult(T data, bool success) : base(success) 15 | { 16 | Data = data; 17 | } 18 | 19 | public T Data { get; } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Business/Abstract/IAuthService.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Utilites.Results.Abstract; 5 | using Core.Utilites.Security.JWT; 6 | using Entities.Concrete; 7 | using Entities.DTOs; 8 | 9 | namespace Business.Abstract 10 | { 11 | public interface IAuthService 12 | { 13 | IDataResult Register(UserForRegisterDto userForRegisterDto); 14 | 15 | IDataResult Login(UserForLoginDto userForLoginDto); 16 | 17 | IResult UserExists(string email); 18 | 19 | IDataResult CreateAccessToken(User user); 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Core/Utilites/Business/BusinessRules.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Utilites.Results.Abstract; 5 | 6 | namespace Core.Utilites.Business 7 | { 8 | public class BusinessRules 9 | { 10 | public static IResult Run(params IResult[] logics) 11 | { 12 | foreach (var logic in logics) 13 | { 14 | if (!logic.Success) 15 | { 16 | // başarısızsa 17 | return logic; 18 | } 19 | 20 | } 21 | return null; 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /WebApi/WebApi.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netcoreapp3.1 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /Business/Abstract/ICustomerService.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Utilites.Results.Abstract; 5 | using Entities.Concrete; 6 | using Entities.DTOs; 7 | 8 | namespace Business.Abstract 9 | { 10 | public interface ICustomerService 11 | { 12 | IDataResult> GetAll(); 13 | 14 | IDataResult> GetCustomerDetails(); 15 | 16 | IDataResult Get(int id); 17 | 18 | IResult Add(Customer entity); 19 | 20 | IResult Update(Customer entity); 21 | 22 | IResult Delete(Customer entity); 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /ConsoleUI/ConsoleUI.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp3.1 6 | 7 | 8 | 9 | 10 | all 11 | runtime; build; native; contentfiles; analyzers; buildtransitive 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /Core/Extensions/ErrorDetails.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using FluentValidation.Results; 5 | using Newtonsoft.Json; 6 | 7 | namespace Core.Extensions 8 | { 9 | public class ErrorDetails 10 | { 11 | public string Message { get; set; } 12 | public int StatusCode { get; set; } 13 | public override string ToString() 14 | { 15 | return JsonConvert.SerializeObject(this); 16 | } 17 | } 18 | 19 | public class ValidationErrorDetails : ErrorDetails 20 | { 21 | public IEnumerable Errors { get; set; } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /Core/obj/Core.csproj.nuget.g.targets: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Business/obj/Business.csproj.nuget.g.targets: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Core/CrossCuttingConcerns/Validation/ValidationTool.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using FluentValidation; 5 | 6 | namespace Core.CrossCuttingConcerns.Validation 7 | { 8 | public static class ValidationTool 9 | { 10 | public static void Validate(IValidator validator, object entity) 11 | { 12 | var context = new ValidationContext(entity); 13 | var result = validator.Validate(context); 14 | if (!result.IsValid) 15 | { 16 | throw new ValidationException(result.Errors); 17 | } 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /Entities/obj/Entities.csproj.nuget.g.targets: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /DataAccess/obj/DataAccess.csproj.nuget.g.targets: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Core/Extensions/ServiceCollectionExtensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Utilites.IoC; 5 | using Microsoft.Extensions.DependencyInjection; 6 | 7 | namespace Core.Extensions 8 | { 9 | public static class ServiceCollectionExtensions 10 | { 11 | public static IServiceCollection AddDependencyResolvers(this IServiceCollection serviceCollection, ICoreModule[] modules) 12 | { 13 | foreach (var module in modules) 14 | { 15 | module.Load(serviceCollection); 16 | } 17 | return ServiceTool.Create(serviceCollection); 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /Business/Abstract/IUserService.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Entities.Concrete; 5 | using Core.Utilites.Results.Abstract; 6 | using Entities.Concrete; 7 | 8 | namespace Business.Abstract 9 | { 10 | public interface IUserService 11 | { 12 | IDataResult> GetClaims(User user); 13 | 14 | IDataResult> GetAll(); 15 | 16 | IDataResult Get(int id); 17 | 18 | IResult Add(User entity); 19 | 20 | IResult Update(User entity); 21 | 22 | IResult Delete(User entity); 23 | 24 | IDataResult GetByEmail(string email); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Business/Abstract/ICarImageService.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Utilites.Results.Abstract; 5 | using Entities.Concrete; 6 | using Entities.DTOs; 7 | 8 | namespace Business.Abstract 9 | { 10 | public interface ICarImageService 11 | { 12 | IDataResult> GetAll(); 13 | 14 | IDataResult Get(int id); 15 | 16 | IResult Add(CarImagesOperationDto carImagesOperationDto); 17 | 18 | IResult Update(CarImagesOperationDto carImagesOperationDto); 19 | 20 | IResult Delete(CarImage entity); 21 | 22 | IDataResult> GetAllByCarId(int carId); 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /Core/Utilites/Results/Concrete/ErrorDataResult.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Core.Utilites.Results.Concrete 6 | { 7 | public class ErrorDataResult : DataResult 8 | { 9 | public ErrorDataResult(T data, string message) : base(data, false, message) 10 | { 11 | 12 | } 13 | 14 | public ErrorDataResult(T data) : base(data, false) 15 | { 16 | 17 | } 18 | 19 | public ErrorDataResult(string message) : base(default, false, message) 20 | { 21 | 22 | } 23 | 24 | public ErrorDataResult() : base(default, false) 25 | { 26 | 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Business/Concrete/PaymentManager.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Business.Abstract; 5 | using Business.Constants; 6 | using Core.Utilites.Results.Abstract; 7 | using Core.Utilites.Results.Concrete; 8 | using Entities.Concrete; 9 | 10 | namespace Business.Concrete 11 | { 12 | public class PaymentManager : IPaymentService 13 | { 14 | public IResult ReceivePayment(Payment payment) 15 | { 16 | if (payment.Amount > 5000) 17 | { 18 | return new ErrorResult(Message.InsufficientBalance); 19 | } 20 | return new SuccessResult(Message.PaymentCompleted); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /Core/Utilites/Results/Concrete/SuccessDataResult.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Core.Utilites.Results.Concrete 6 | { 7 | public class SuccessDataResult : DataResult 8 | { 9 | public SuccessDataResult(T data, string message) : base(data, true, message) 10 | { 11 | 12 | } 13 | 14 | public SuccessDataResult(T data) : base(data, true) 15 | { 16 | 17 | } 18 | 19 | public SuccessDataResult(string message) : base(default, true, message) 20 | { 21 | 22 | } 23 | 24 | public SuccessDataResult() : base(default, true) 25 | { 26 | 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Core/Extensions/ClaimsPrincipalExtensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Security.Claims; 5 | using System.Text; 6 | 7 | namespace Core.Extensions 8 | { 9 | public static class ClaimsPrincipalExtensions 10 | { 11 | public static List Claims(this ClaimsPrincipal claimsPrincipal, string claimType) 12 | { 13 | var result = claimsPrincipal?.FindAll(claimType)?.Select(x => x.Value).ToList(); 14 | return result; 15 | } 16 | 17 | public static List ClaimRoles(this ClaimsPrincipal claimsPrincipal) 18 | { 19 | return claimsPrincipal?.Claims(ClaimTypes.Role); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /Business/Business.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netstandard2.0 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /Core/DependencyResolvers/CoreModule.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Diagnostics; 4 | using System.Text; 5 | using Core.CrossCuttingConcerns.Caching; 6 | using Core.CrossCuttingConcerns.Caching.Microsoft; 7 | using Core.Utilites.IoC; 8 | using Microsoft.AspNetCore.Http; 9 | using Microsoft.Extensions.DependencyInjection; 10 | 11 | namespace Core.DependencyResolvers 12 | { 13 | public class CoreModule : ICoreModule 14 | { 15 | public void Load(IServiceCollection serviceCollection) 16 | { 17 | serviceCollection.AddMemoryCache(); 18 | serviceCollection.AddSingleton(); 19 | serviceCollection.AddSingleton(); 20 | serviceCollection.AddSingleton(); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /Core/Aspects/Autofac/Caching/CacheRemoveAspect.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Castle.DynamicProxy; 5 | using Core.CrossCuttingConcerns.Caching; 6 | using Core.Utilites.Interceptors; 7 | using Core.Utilites.IoC; 8 | using Microsoft.Extensions.DependencyInjection; 9 | namespace Core.Aspects.Autofac.Caching 10 | { 11 | public class CacheRemoveAspect : MethodInterception 12 | { 13 | private string _pattern; 14 | private ICacheManager _cacheManager; 15 | 16 | public CacheRemoveAspect(string pattern) 17 | { 18 | _pattern = pattern; 19 | _cacheManager = ServiceTool.ServiceProvider.GetService(); 20 | } 21 | 22 | protected override void OnSuccess(IInvocation invocation) 23 | { 24 | _cacheManager.RemoveByPattern(_pattern); 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Business/Abstract/ICarService.cs: -------------------------------------------------------------------------------- 1 | using Core.Utilites.Results.Abstract; 2 | using Entities.Concrete; 3 | using Entities.DTOs; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Business.Abstract 9 | { 10 | public interface ICarService 11 | { 12 | IResult Add(Car car); 13 | IResult Update(Car car); 14 | IResult Delete(Car car); 15 | IDataResult> GetAll(); 16 | IDataResult GetById(int id); 17 | IDataResult> GetAllByColorId(int id); 18 | IDataResult> GetAllByBrandId(int id); 19 | IDataResult> GetByDailyPrice(decimal min, decimal max); 20 | 21 | IDataResult> GetCarsDetail(); 22 | IResult AddTransactionalTest(Car car); 23 | IDataResult GetCarDetailAndImagesDto(int carId); 24 | 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Business/Abstract/IRentalService.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Utilites.Results.Abstract; 5 | using Entities.Concrete; 6 | using Entities.DTOs; 7 | 8 | namespace Business.Abstract 9 | { 10 | public interface IRentalService 11 | { 12 | IDataResult> GetAll(); 13 | 14 | IDataResult Get(int id); 15 | 16 | IResult Add(Rental entity); 17 | 18 | IResult Update(Rental entity); 19 | 20 | IResult Delete(Rental entity); 21 | 22 | 23 | IResult DeliverTheCar(Rental rental); 24 | 25 | 26 | IDataResult> GetAllRentalDetails(); 27 | 28 | 29 | IDataResult> GetAllUndeliveredRentalDetails(); 30 | 31 | 32 | IDataResult> GetAllDeliveredRentalDetails(); 33 | } 34 | } 35 | 36 | -------------------------------------------------------------------------------- /Core/Utilites/Interceptors/AspectInterceptorSelector.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Reflection; 5 | using System.Text; 6 | using Castle.DynamicProxy; 7 | 8 | namespace Core.Utilites.Interceptors 9 | { 10 | public class AspectInterceptorSelector : IInterceptorSelector 11 | { 12 | public IInterceptor[] SelectInterceptors(Type type, MethodInfo method, IInterceptor[] interceptors) 13 | { 14 | var classAttributes = type.GetCustomAttributes 15 | (true).ToList(); 16 | var methodAttributes = type.GetMethod(method.Name) 17 | .GetCustomAttributes(true); 18 | classAttributes.AddRange(methodAttributes); 19 | 20 | return classAttributes.OrderBy(x => x.Priority).ToArray(); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # ReCapProject 2 | Araç kiralama projesinin Backend kısmıdır. Wep API destekli çalışır. Business, Data Access, Core, Entities katmanlarına sahip ve SOLID prensiplerine uygun şekilde yazılmıştır.
3 |

Kullanılan Back-End Teknolojileri

4 |
    5 |
  • Katmanlı Mimari
  • 6 |
  • Entity Framework Core
  • 7 |
  • Repository Design Pattern
  • 8 |
  • Json Web Token
  • 9 |
  • Autofac
  • 10 |
  • Fluent Validation
  • 11 |
  • Attribute, Autofac Interceptors
  • 12 |
  • LINQ
  • 13 |
  • WebApi
  • 14 |
15 |
16 |

Kullanılan Front-End Teknolojileri

17 |
    18 |
  • Angular
19 |
  • ReCapProject-Frontend--master' kısmından inceleyebilirsiniz
  • 20 | 21 |
    22 |

    Proje Bilgileri

    23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /Core/Aspects/Autofac/Transaction/TransactionScopeAspect.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using System.Transactions; 5 | using Castle.DynamicProxy; 6 | using Core.Utilites.Interceptors; 7 | 8 | namespace Core.Aspects.Autofac.Transaction 9 | { 10 | public class TransactionScopeAspect : MethodInterception 11 | { 12 | public override void Intercept(IInvocation invocation) 13 | { 14 | using (TransactionScope transactionScope = new TransactionScope()) 15 | { 16 | try 17 | { 18 | invocation.Proceed(); 19 | transactionScope.Complete(); 20 | } 21 | catch (System.Exception e) 22 | { 23 | transactionScope.Dispose(); 24 | throw; 25 | } 26 | } 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /WebApi/Properties/launchSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://json.schemastore.org/launchsettings.json", 3 | "iisSettings": { 4 | "windowsAuthentication": false, 5 | "anonymousAuthentication": true, 6 | "iisExpress": { 7 | "applicationUrl": "http://localhost:50403", 8 | "sslPort": 44372 9 | } 10 | }, 11 | "profiles": { 12 | "IIS Express": { 13 | "commandName": "IISExpress", 14 | "launchBrowser": true, 15 | "launchUrl": "weatherforecast", 16 | "environmentVariables": { 17 | "ASPNETCORE_ENVIRONMENT": "Development" 18 | } 19 | }, 20 | "WebApi": { 21 | "commandName": "Project", 22 | "launchBrowser": true, 23 | "launchUrl": "weatherforecast", 24 | "applicationUrl": "https://localhost:5001;http://localhost:5000", 25 | "environmentVariables": { 26 | "ASPNETCORE_ENVIRONMENT": "Development" 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /Entities/DTOs/RentalDetailDto.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Entities; 5 | 6 | namespace Entities.DTOs 7 | { 8 | public class RentalDetailDto : IDto 9 | { 10 | public int Id { get; set; } 11 | public DateTime RentDate { get; set; } 12 | public DateTime? ReturnDate { get; set; } 13 | 14 | //Customer Table 15 | public string CompanyName { get; set; } 16 | 17 | //User Table 18 | public string FirstName { get; set; } 19 | 20 | public string LastName { get; set; } 21 | 22 | //Brand Table 23 | public string BrandName { get; set; } 24 | 25 | //Color Table 26 | public string ColorName { get; set; } 27 | 28 | //Car Table 29 | public string CarDesctiption { get; set; } 30 | 31 | public int ModelYear { get; set; } 32 | public decimal DailyPrice { get; set; } 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /WebApi/bin/Debug/netcoreapp3.1/Properties/launchSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://json.schemastore.org/launchsettings.json", 3 | "iisSettings": { 4 | "windowsAuthentication": false, 5 | "anonymousAuthentication": true, 6 | "iisExpress": { 7 | "applicationUrl": "http://localhost:50403", 8 | "sslPort": 44372 9 | } 10 | }, 11 | "profiles": { 12 | "IIS Express": { 13 | "commandName": "IISExpress", 14 | "launchBrowser": true, 15 | "launchUrl": "weatherforecast", 16 | "environmentVariables": { 17 | "ASPNETCORE_ENVIRONMENT": "Development" 18 | } 19 | }, 20 | "WebApi": { 21 | "commandName": "Project", 22 | "launchBrowser": true, 23 | "launchUrl": "weatherforecast", 24 | "applicationUrl": "https://localhost:5001;http://localhost:5000", 25 | "environmentVariables": { 26 | "ASPNETCORE_ENVIRONMENT": "Development" 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /Core/Utilites/FileProces/IFileProces.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Core.Utilites.Results.Abstract; 5 | using Microsoft.AspNetCore.Http; 6 | 7 | namespace Core.Utilites.FileProces 8 | { 9 | public interface IFileProcess 10 | { 11 | /// 12 | /// Create File 13 | /// 14 | /// example 1: foldername

    example 2: foldername/subfoldername/.... [unlimited] 15 | /// IFromFile type 16 | /// IDataResult.Data = Path of the file created. 17 | IDataResult Upload(string directoryPath, IFormFile file); 18 | 19 | /// 20 | /// Delete File 21 | /// 22 | /// example 1: "foldername/filename" 23 | /// 24 | IResult Delete(string filePath); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Core/obj/Debug/netstandard2.0/Core.AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // Bu kod araç tarafından oluşturuldu. 4 | // Çalışma Zamanı Sürümü:4.0.30319.42000 5 | // 6 | // Bu dosyada yapılacak değişiklikler yanlış davranışa neden olabilir ve 7 | // kod yeniden oluşturulursa kaybolur. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | using System; 12 | using System.Reflection; 13 | 14 | [assembly: System.Reflection.AssemblyCompanyAttribute("Core")] 15 | [assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")] 16 | [assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] 17 | [assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] 18 | [assembly: System.Reflection.AssemblyProductAttribute("Core")] 19 | [assembly: System.Reflection.AssemblyTitleAttribute("Core")] 20 | [assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] 21 | 22 | // MSBuild WriteCodeFragment sınıfı tarafından oluşturuldu. 23 | 24 | -------------------------------------------------------------------------------- /DataAccess/DataAccess.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netstandard2.0 5 | 6 | 7 | 8 | 9 | 10 | all 11 | runtime; build; native; contentfiles; analyzers; buildtransitive 12 | 13 | 14 | 15 | all 16 | runtime; build; native; contentfiles; analyzers; buildtransitive 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /Core/Extensions/ClaimExtensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Security.Claims; 5 | using System.Text; 6 | using System.IdentityModel.Tokens.Jwt; 7 | namespace Core.Extensions 8 | { 9 | public static class ClaimExtensions 10 | { 11 | public static void AddEmail(this ICollection claims, string email) 12 | { 13 | claims.Add(new Claim(JwtRegisteredClaimNames.Email, email)); 14 | } 15 | 16 | public static void AddName(this ICollection claims, string name) 17 | { 18 | claims.Add(new Claim(ClaimTypes.Name, name)); 19 | } 20 | 21 | public static void AddNameIdentifier(this ICollection claims, string nameIdentifier) 22 | { 23 | claims.Add(new Claim(ClaimTypes.NameIdentifier, nameIdentifier)); 24 | } 25 | 26 | public static void AddRoles(this ICollection claims, string[] roles) 27 | { 28 | roles.ToList().ForEach(role => claims.Add(new Claim(ClaimTypes.Role, role))); 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /WebApi/obj/Debug/netcoreapp3.1/WebApi.AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // Bu kod araç tarafından oluşturuldu. 4 | // Çalışma Zamanı Sürümü:4.0.30319.42000 5 | // 6 | // Bu dosyada yapılacak değişiklikler yanlış davranışa neden olabilir ve 7 | // kod yeniden oluşturulursa kaybolur. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | using System; 12 | using System.Reflection; 13 | 14 | [assembly: System.Reflection.AssemblyCompanyAttribute("WebApi")] 15 | [assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")] 16 | [assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] 17 | [assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] 18 | [assembly: System.Reflection.AssemblyProductAttribute("WebApi")] 19 | [assembly: System.Reflection.AssemblyTitleAttribute("WebApi")] 20 | [assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] 21 | 22 | // MSBuild WriteCodeFragment sınıfı tarafından oluşturuldu. 23 | 24 | -------------------------------------------------------------------------------- /Business/obj/Debug/netstandard2.0/Business.AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // Bu kod araç tarafından oluşturuldu. 4 | // Çalışma Zamanı Sürümü:4.0.30319.42000 5 | // 6 | // Bu dosyada yapılacak değişiklikler yanlış davranışa neden olabilir ve 7 | // kod yeniden oluşturulursa kaybolur. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | using System; 12 | using System.Reflection; 13 | 14 | [assembly: System.Reflection.AssemblyCompanyAttribute("Business")] 15 | [assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")] 16 | [assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] 17 | [assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] 18 | [assembly: System.Reflection.AssemblyProductAttribute("Business")] 19 | [assembly: System.Reflection.AssemblyTitleAttribute("Business")] 20 | [assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] 21 | 22 | // MSBuild WriteCodeFragment sınıfı tarafından oluşturuldu. 23 | 24 | -------------------------------------------------------------------------------- /Entities/obj/Debug/netstandard2.0/Entities.AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // Bu kod araç tarafından oluşturuldu. 4 | // Çalışma Zamanı Sürümü:4.0.30319.42000 5 | // 6 | // Bu dosyada yapılacak değişiklikler yanlış davranışa neden olabilir ve 7 | // kod yeniden oluşturulursa kaybolur. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | using System; 12 | using System.Reflection; 13 | 14 | [assembly: System.Reflection.AssemblyCompanyAttribute("Entities")] 15 | [assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")] 16 | [assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] 17 | [assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] 18 | [assembly: System.Reflection.AssemblyProductAttribute("Entities")] 19 | [assembly: System.Reflection.AssemblyTitleAttribute("Entities")] 20 | [assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] 21 | 22 | // MSBuild WriteCodeFragment sınıfı tarafından oluşturuldu. 23 | 24 | -------------------------------------------------------------------------------- /ConsoleUI/obj/Debug/netcoreapp3.1/ConsoleUI.AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // Bu kod araç tarafından oluşturuldu. 4 | // Çalışma Zamanı Sürümü:4.0.30319.42000 5 | // 6 | // Bu dosyada yapılacak değişiklikler yanlış davranışa neden olabilir ve 7 | // kod yeniden oluşturulursa kaybolur. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | using System; 12 | using System.Reflection; 13 | 14 | [assembly: System.Reflection.AssemblyCompanyAttribute("ConsoleUI")] 15 | [assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")] 16 | [assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] 17 | [assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] 18 | [assembly: System.Reflection.AssemblyProductAttribute("ConsoleUI")] 19 | [assembly: System.Reflection.AssemblyTitleAttribute("ConsoleUI")] 20 | [assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] 21 | 22 | // MSBuild WriteCodeFragment sınıfı tarafından oluşturuldu. 23 | 24 | -------------------------------------------------------------------------------- /DataAccess/obj/Debug/netstandard2.0/DataAccess.AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // Bu kod araç tarafından oluşturuldu. 4 | // Çalışma Zamanı Sürümü:4.0.30319.42000 5 | // 6 | // Bu dosyada yapılacak değişiklikler yanlış davranışa neden olabilir ve 7 | // kod yeniden oluşturulursa kaybolur. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | using System; 12 | using System.Reflection; 13 | 14 | [assembly: System.Reflection.AssemblyCompanyAttribute("DataAccess")] 15 | [assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")] 16 | [assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] 17 | [assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] 18 | [assembly: System.Reflection.AssemblyProductAttribute("DataAccess")] 19 | [assembly: System.Reflection.AssemblyTitleAttribute("DataAccess")] 20 | [assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] 21 | 22 | // MSBuild WriteCodeFragment sınıfı tarafından oluşturuldu. 23 | 24 | -------------------------------------------------------------------------------- /Core/Core.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netstandard2.0 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /WebApi/Program.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using Autofac; 6 | using Autofac.Extensions.DependencyInjection; 7 | using Business.DependencyResolvers.Autofac; 8 | using Microsoft.AspNetCore.Hosting; 9 | using Microsoft.Extensions.Configuration; 10 | using Microsoft.Extensions.Hosting; 11 | using Microsoft.Extensions.Logging; 12 | 13 | namespace WebApi 14 | { 15 | public class Program 16 | { 17 | public static void Main(string[] args) 18 | { 19 | CreateHostBuilder(args).Build().Run(); 20 | } 21 | 22 | public static IHostBuilder CreateHostBuilder(string[] args) => 23 | Host.CreateDefaultBuilder(args) 24 | .UseServiceProviderFactory(new AutofacServiceProviderFactory()) 25 | .ConfigureContainer(builder => 26 | { 27 | builder.RegisterModule(new AutofacBusinessModule()); 28 | }) 29 | .ConfigureWebHostDefaults(webBuilder => 30 | { 31 | webBuilder.UseStartup(); 32 | }); 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /DataAccess/Concrete/EntityFramework/Context/RentACarContext.cs: -------------------------------------------------------------------------------- 1 | using Core.Entities.Concrete; 2 | using Entities.Concrete; 3 | using Microsoft.EntityFrameworkCore; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Linq.Expressions; 7 | using System.Text; 8 | 9 | namespace DataAccess.Concrete.EntityFramework.Context 10 | { 11 | public class RentACarContext : DbContext 12 | { 13 | protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder) 14 | { 15 | optionsBuilder.UseSqlServer(@"Server=(localdb)\mssqllocaldb; Database=RentACar; Trusted_Connection = true"); 16 | //base.OnConfiguring(optionsBuilder); 17 | } 18 | 19 | public DbSet Cars { get; set; } 20 | public DbSet Brands { get; set; } 21 | public DbSet Colors { get; set; } 22 | public DbSet Customers { get; set; } 23 | public DbSet Rentals { get; set; } 24 | public DbSet CarImages { get; set; } 25 | public DbSet Users { get; set; } 26 | public DbSet OperationClaims { get; set; } 27 | public DbSet UserOperationClaims { get; set; } 28 | 29 | } 30 | 31 | } 32 | -------------------------------------------------------------------------------- /Core/Aspects/Autofac/Performance/PerformanceAspect.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Diagnostics; 4 | using System.Text; 5 | using Castle.DynamicProxy; 6 | using Core.Utilites.Interceptors; 7 | using Core.Utilites.IoC; 8 | using Microsoft.Extensions.DependencyInjection; 9 | namespace Core.Aspects.Autofac.Performance 10 | { 11 | public class PerformanceAspect : MethodInterception 12 | { 13 | private int _interval; 14 | private Stopwatch _stopwatch; 15 | 16 | public PerformanceAspect(int interval) 17 | { 18 | _interval = interval; 19 | _stopwatch = ServiceTool.ServiceProvider.GetService(); 20 | } 21 | 22 | 23 | protected override void OnBefore(IInvocation invocation) 24 | { 25 | _stopwatch.Start(); 26 | } 27 | 28 | protected override void OnAfter(IInvocation invocation) 29 | { 30 | if (_stopwatch.Elapsed.TotalSeconds > _interval) 31 | { 32 | Debug.WriteLine($"Performance : {invocation.Method.DeclaringType.FullName}.{invocation.Method.Name}-->{_stopwatch.Elapsed.TotalSeconds}"); 33 | } 34 | _stopwatch.Reset(); 35 | } 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /Core/Utilites/Security/Hashing/HashingHelper.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Core.Utilites.Security.Hashing 6 | { 7 | public class HashingHelper 8 | { 9 | public static void CreatePasswordHash(string password, out byte[] passwordHash, out byte[] passwordSalt) 10 | { 11 | using (var hmac = new System.Security.Cryptography.HMACSHA512()) 12 | { 13 | passwordSalt = hmac.Key; 14 | passwordHash = hmac.ComputeHash(Encoding.UTF8.GetBytes(password)); 15 | } 16 | } 17 | 18 | public static bool VerifyPasswordHash(string password, byte[] passwordHash, byte[] passwordSalt) 19 | { 20 | using (var hmac = new System.Security.Cryptography.HMACSHA512(passwordSalt)) 21 | { 22 | var computedHash = hmac.ComputeHash(Encoding.UTF8.GetBytes(password)); 23 | for (int i = 0; i < computedHash.Length; i++) 24 | { 25 | if (computedHash[i] != passwordHash[i]) 26 | { 27 | return false; 28 | } 29 | } 30 | return true; 31 | } 32 | } 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /DataAccess/Concrete/EntityFramework/Repository/EfUserDal.cs: -------------------------------------------------------------------------------- 1 | using Core.DataAccess.EntityFramework; 2 | using Core.Entities.Concrete; 3 | using DataAccess.Abstract; 4 | using DataAccess.Concrete.EntityFramework.Context; 5 | using Entities.Concrete; 6 | using System.Collections.Generic; 7 | using System.Linq; 8 | 9 | namespace DataAccess.Concrete.EntityFramework 10 | { 11 | public class EfUserDal : EfEntityRepositoryBase, IUserDal 12 | { 13 | public List GetClaims(User user) 14 | { 15 | using (RentACarContext context = new RentACarContext()) 16 | { 17 | var result = from operationClaim in context.OperationClaims 18 | join userOperationClaim in context.UserOperationClaims 19 | on operationClaim.Id equals userOperationClaim.OperationClaimId 20 | where userOperationClaim.UserId == user.Id 21 | select new OperationClaim 22 | { 23 | Id = operationClaim.Id, 24 | Name = operationClaim.Name 25 | }; 26 | return result.ToList(); 27 | } 28 | } 29 | } 30 | } -------------------------------------------------------------------------------- /Business/BusinessAspects/Autofac/SecuredOperation.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.AspNetCore.Http; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | using Castle.DynamicProxy; 6 | using Microsoft.Extensions.DependencyInjection; 7 | using Business.Constants; 8 | using Core.Utilites.IoC; 9 | using Core.Extensions; 10 | using Core.Utilites.Interceptors; 11 | 12 | namespace Business.BusinessAspects.Autofac 13 | { 14 | //JWT 15 | public class SecuredOperation : MethodInterception 16 | { 17 | private string[] _roles; 18 | private IHttpContextAccessor _httpContextAccessor; 19 | 20 | public SecuredOperation(string roles) 21 | { 22 | _roles = roles.Split(','); 23 | _httpContextAccessor = ServiceTool.ServiceProvider.GetService(); 24 | 25 | } 26 | 27 | protected override void OnBefore(IInvocation invocation) 28 | { 29 | var roleClaims = _httpContextAccessor.HttpContext.User.ClaimRoles(); 30 | foreach (var role in _roles) 31 | { 32 | if (roleClaims.Contains(role)) 33 | { 34 | return; 35 | } 36 | } 37 | throw new Exception(Message.AuthorizationDenied); 38 | } 39 | } 40 | } -------------------------------------------------------------------------------- /WebApi/Controllers/WeatherForecastController.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using Microsoft.AspNetCore.Mvc; 6 | using Microsoft.Extensions.Logging; 7 | 8 | namespace WebApi.Controllers 9 | { 10 | [ApiController] 11 | [Route("[controller]")] 12 | public class WeatherForecastController : ControllerBase 13 | { 14 | private static readonly string[] Summaries = new[] 15 | { 16 | "Freezing", "Bracing", "Chilly", "Cool", "Mild", "Warm", "Balmy", "Hot", "Sweltering", "Scorching" 17 | }; 18 | 19 | private readonly ILogger _logger; 20 | 21 | public WeatherForecastController(ILogger logger) 22 | { 23 | _logger = logger; 24 | } 25 | 26 | [HttpGet] 27 | public IEnumerable Get() 28 | { 29 | var rng = new Random(); 30 | return Enumerable.Range(1, 5).Select(index => new WeatherForecast 31 | { 32 | Date = DateTime.Now.AddDays(index), 33 | TemperatureC = rng.Next(-20, 55), 34 | Summary = Summaries[rng.Next(Summaries.Length)] 35 | }) 36 | .ToArray(); 37 | } 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /Core/Utilites/Interceptors/MethodInterception.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Castle.DynamicProxy; 5 | 6 | namespace Core.Utilites.Interceptors 7 | { 8 | public abstract class MethodInterception : MethodInterceptionBaseAttribute 9 | { 10 | // invocation - business method 11 | protected virtual void OnBefore(IInvocation invocation) { } 12 | protected virtual void OnAfter(IInvocation invocation) { } 13 | protected virtual void OnException(IInvocation invocation, System.Exception e) { } 14 | protected virtual void OnSuccess(IInvocation invocation) { } 15 | public override void Intercept(IInvocation invocation) 16 | { 17 | var isSuccess = true; 18 | OnBefore(invocation); 19 | try 20 | { 21 | invocation.Proceed(); 22 | } 23 | catch (Exception e) 24 | { 25 | isSuccess = false; 26 | OnException(invocation, e); 27 | throw; 28 | } 29 | finally 30 | { 31 | if (isSuccess) 32 | { 33 | OnSuccess(invocation); 34 | } 35 | } 36 | OnAfter(invocation); 37 | } 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /Core/obj/Core.csproj.nuget.g.props: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | True 5 | NuGet 6 | $(MSBuildThisFileDirectory)project.assets.json 7 | $(UserProfile)\.nuget\packages\ 8 | C:\Users\PC\.nuget\packages\ 9 | PackageReference 10 | 5.7.0 11 | 12 | 13 | 14 | 15 | 16 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 17 | 18 | -------------------------------------------------------------------------------- /Core/Aspects/Autofac/Validation/ValidationAspect.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using Castle.DynamicProxy; 6 | using Core.CrossCuttingConcerns.Validation; 7 | using Core.Utilites.Interceptors; 8 | using FluentValidation; 9 | 10 | namespace Core.Aspects.Autofac.Validation 11 | { 12 | public class ValidationAspect : MethodInterception 13 | { 14 | private Type _validatorType; 15 | public ValidationAspect(Type validatorType) 16 | { 17 | // defensive coding - savunma 18 | if (!typeof(IValidator).IsAssignableFrom(validatorType)) 19 | { 20 | throw new System.Exception("Bu bir doğrulama sınıfı değil"); 21 | } 22 | 23 | _validatorType = validatorType; 24 | } 25 | protected override void OnBefore(IInvocation invocation) 26 | { 27 | var validator = (IValidator)Activator.CreateInstance(_validatorType); 28 | var entityType = _validatorType.BaseType.GetGenericArguments()[0]; 29 | var entities = invocation.Arguments.Where(t => t.GetType() == entityType); 30 | foreach (var entity in entities) 31 | { 32 | ValidationTool.Validate(validator, entity); 33 | } 34 | } 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /WebApi/obj/WebApi.csproj.nuget.g.props: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | True 5 | NuGet 6 | $(MSBuildThisFileDirectory)project.assets.json 7 | $(UserProfile)\.nuget\packages\ 8 | C:\Users\PC\.nuget\packages\ 9 | PackageReference 10 | 5.7.0 11 | 12 | 13 | 14 | 15 | 16 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 17 | 18 | -------------------------------------------------------------------------------- /Business/obj/Business.csproj.nuget.g.props: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | True 5 | NuGet 6 | $(MSBuildThisFileDirectory)project.assets.json 7 | $(UserProfile)\.nuget\packages\ 8 | C:\Users\PC\.nuget\packages\ 9 | PackageReference 10 | 5.7.0 11 | 12 | 13 | 14 | 15 | 16 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 17 | 18 | -------------------------------------------------------------------------------- /Entities/obj/Entities.csproj.nuget.g.props: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | True 5 | NuGet 6 | $(MSBuildThisFileDirectory)project.assets.json 7 | $(UserProfile)\.nuget\packages\ 8 | C:\Users\PC\.nuget\packages\ 9 | PackageReference 10 | 5.7.0 11 | 12 | 13 | 14 | 15 | 16 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 17 | 18 | -------------------------------------------------------------------------------- /DataAccess/Concrete/EntityFramework/Repository/EfCustomerDal.cs: -------------------------------------------------------------------------------- 1 | using Core.DataAccess.EntityFramework; 2 | using DataAccess.Abstract; 3 | using DataAccess.Concrete.EntityFramework.Context; 4 | using Entities.Concrete; 5 | using Entities.DTOs; 6 | using Microsoft.EntityFrameworkCore; 7 | using System; 8 | using System.Collections.Generic; 9 | using System.Linq; 10 | using System.Linq.Expressions; 11 | using System.Text; 12 | 13 | namespace DataAccess.Concrete.EntityFramework.Repository 14 | { 15 | public class EfCustomerDal : EfEntityRepositoryBase, ICustomerDal 16 | { 17 | public List GetCustomerDetailDto() 18 | { 19 | using (var context = new RentACarContext()) 20 | { 21 | var result = from customer in context.Customers 22 | join user in context.Users on customer.UserId equals user.Id 23 | select new CustomerDetailDto() 24 | { 25 | CustomerId = customer.Id, 26 | CompanyName = customer.CompanyName, 27 | FirstName = user.FirstName, 28 | LastName = user.LastName 29 | }; 30 | return result.ToList(); 31 | } 32 | } 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /Core/Aspects/Autofac/Caching/CacheAspect.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using Castle.DynamicProxy; 6 | using Core.CrossCuttingConcerns.Caching; 7 | using Core.Utilites.Interceptors; 8 | using Core.Utilites.IoC; 9 | using Microsoft.Extensions.DependencyInjection; 10 | 11 | namespace Core.Aspects.Autofac.Caching 12 | { 13 | public class CacheAspect : MethodInterception 14 | { 15 | private int _duration; 16 | private ICacheManager _cacheManager; 17 | 18 | public CacheAspect(int duration = 60) 19 | { 20 | _duration = duration; 21 | _cacheManager = ServiceTool.ServiceProvider.GetService(); 22 | } 23 | 24 | public override void Intercept(IInvocation invocation) 25 | { 26 | var methodName = string.Format($"{invocation.Method.ReflectedType.FullName}.{invocation.Method.Name}"); 27 | var arguments = invocation.Arguments.ToList(); 28 | var key = $"{methodName}({string.Join(",", arguments.Select(x => x?.ToString() ?? ""))})"; 29 | if (_cacheManager.IsAdd(key)) 30 | { 31 | invocation.ReturnValue = _cacheManager.Get(key); 32 | return; 33 | } 34 | invocation.Proceed(); 35 | _cacheManager.Add(key, invocation.ReturnValue, _duration); 36 | } 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /DataAccess/Concrete/InMemory/InMemoryBrandDal.cs: -------------------------------------------------------------------------------- 1 | using DataAccess.Abstract; 2 | using Entities.Concrete; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Linq; 6 | using System.Text; 7 | 8 | namespace DataAccess.Concrete.InMemory 9 | { 10 | //public class InMemoryBrandDal : IBrandDal 11 | public class InMemoryBrandDal 12 | { 13 | //List _brands; 14 | 15 | //public InMemoryBrandDal() 16 | //{ 17 | // _brands = new List() 18 | // { 19 | // new Brand(){ Id = 1, BrandName = "Mercedes"}, 20 | // new Brand(){ Id = 2, BrandName = "BMW"}, 21 | // new Brand(){ Id = 3, BrandName = "Volvo"}, 22 | // }; 23 | //} 24 | 25 | //public void Add(Brand entity) 26 | //{ 27 | // _brands.Add(entity); 28 | //} 29 | 30 | //public void Delete(int id) 31 | //{ 32 | // var brandToDelete = _brands.SingleOrDefault(b => b.Id == id); 33 | // _brands.Remove(brandToDelete); 34 | //} 35 | 36 | //public List GetAll() 37 | //{ 38 | // return _brands; 39 | //} 40 | 41 | //public void Update(Brand entity) 42 | //{ 43 | // var brandToUpdate = _brands.SingleOrDefault(b => b.Id == entity.Id); 44 | // brandToUpdate.BrandName = entity.BrandName; 45 | //} 46 | } 47 | } 48 | -------------------------------------------------------------------------------- /DataAccess/Concrete/InMemory/InMemoryColorDal.cs: -------------------------------------------------------------------------------- 1 | using DataAccess.Abstract; 2 | using Entities.Concrete; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Linq; 6 | using System.Text; 7 | 8 | namespace DataAccess.Concrete.InMemory 9 | { 10 | //public class InMemoryColorDal : IColorDal 11 | public class InMemoryColorDal 12 | { 13 | //List _colors; 14 | 15 | //public InMemoryColorDal() 16 | //{ 17 | // _colors = new List() 18 | // { 19 | // new Color(){ Id = 1, ColorName = "Siyah"}, 20 | // new Color(){ Id = 2, ColorName = "Beyaz"}, 21 | // new Color(){ Id = 3, ColorName = "Mavi"}, 22 | // }; 23 | //} 24 | 25 | //public void Add(Color entity) 26 | //{ 27 | // _colors.Add(entity); 28 | //} 29 | 30 | //public void Delete(int id) 31 | //{ 32 | // var colorToDelete = _colors.SingleOrDefault(b => b.Id == id); 33 | // _colors.Remove(colorToDelete); 34 | //} 35 | 36 | //public List GetAll() 37 | //{ 38 | // return _colors; 39 | //} 40 | 41 | //public void Update(Color entity) 42 | //{ 43 | // var colorToUpdate = _colors.SingleOrDefault(b => b.Id == entity.Id); 44 | // colorToUpdate.ColorName = entity.ColorName; 45 | //} 46 | } 47 | } 48 | -------------------------------------------------------------------------------- /Business/Concrete/ColorManager.cs: -------------------------------------------------------------------------------- 1 | using Business.Abstract; 2 | using Business.Constants; 3 | using Core.Utilites.Results.Abstract; 4 | using Core.Utilites.Results.Concrete; 5 | using DataAccess.Abstract; 6 | using Entities.Concrete; 7 | using System; 8 | using System.Collections.Generic; 9 | using System.Text; 10 | 11 | namespace Business.Concrete 12 | { 13 | public class ColorManager : IColorService 14 | { 15 | IColorDal _colorDal; 16 | 17 | public ColorManager(IColorDal brandDal) 18 | { 19 | _colorDal = brandDal; 20 | } 21 | 22 | public IResult Add(Color entity) 23 | { 24 | _colorDal.Add(entity); 25 | return new SuccessResult(Message.ColorAdded); 26 | } 27 | 28 | public IResult Delete(Color color) 29 | { 30 | _colorDal.Delete(color); 31 | return new SuccessResult(Message.ColorDeleted); 32 | } 33 | 34 | public IDataResult> GetAll() 35 | { 36 | return new SuccessDataResult>(_colorDal.GetAll()); 37 | 38 | } 39 | 40 | public IDataResult GetById(int id) 41 | { 42 | return new SuccessDataResult(_colorDal.Get(c => c.ColorId == id)); 43 | } 44 | 45 | public IResult Update(Color entity) 46 | { 47 | _colorDal.Update(entity); 48 | return new SuccessResult(Message.ColorUpdated); 49 | } 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /DataAccess/obj/DataAccess.csproj.nuget.g.props: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | True 5 | NuGet 6 | $(MSBuildThisFileDirectory)project.assets.json 7 | $(UserProfile)\.nuget\packages\ 8 | C:\Users\PC\.nuget\packages\ 9 | PackageReference 10 | 5.7.0 11 | 12 | 13 | 14 | 15 | 16 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 17 | 18 | 19 | C:\Users\PC\.nuget\packages\microsoft.entityframeworkcore.tools\3.1.11 20 | 21 | -------------------------------------------------------------------------------- /ConsoleUI/obj/ConsoleUI.csproj.nuget.g.props: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | True 5 | NuGet 6 | $(MSBuildThisFileDirectory)project.assets.json 7 | $(UserProfile)\.nuget\packages\ 8 | C:\Users\PC\.nuget\packages\ 9 | PackageReference 10 | 5.7.0 11 | 12 | 13 | 14 | 15 | 16 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath) 17 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /WebApi/Controllers/UsersController.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using Business.Abstract; 6 | using Entities.Concrete; 7 | using Microsoft.AspNetCore.Http; 8 | using Microsoft.AspNetCore.Mvc; 9 | 10 | namespace WebApi.Controllers 11 | { 12 | [Route("api/[controller]")] 13 | [ApiController] 14 | public class UsersController : ControllerBase 15 | { 16 | IUserService _userService; 17 | 18 | public UsersController(IUserService userService) 19 | { 20 | _userService = userService; 21 | } 22 | 23 | [HttpGet("getbyid")] 24 | public ActionResult GetById(int id) 25 | { 26 | var result = _userService.Get(id); 27 | if (result.Success) 28 | return Ok(result); 29 | return BadRequest(result); 30 | } 31 | 32 | [HttpGet("getall")] 33 | public ActionResult GetAll() 34 | { 35 | var result = _userService.GetAll(); 36 | if (result.Success) 37 | return Ok(result); 38 | return BadRequest(result); 39 | } 40 | 41 | [HttpPost("add")] 42 | public ActionResult Add(User user) 43 | { 44 | var result = _userService.Add(user); 45 | if (result.Success) 46 | return Ok(result); 47 | return BadRequest(result); 48 | } 49 | 50 | [HttpGet("getbymail")] 51 | public IActionResult GetByMail(string mail) 52 | { 53 | var result = _userService.GetByEmail(mail); 54 | if (result.Success) 55 | { 56 | return Ok(result); 57 | } 58 | return BadRequest(result); 59 | } 60 | } 61 | } 62 | -------------------------------------------------------------------------------- /WebApi/Controllers/AuthController.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using Business.Abstract; 6 | using Entities.DTOs; 7 | using Microsoft.AspNetCore.Http; 8 | using Microsoft.AspNetCore.Mvc; 9 | 10 | namespace WebApi.Controllers 11 | { 12 | [Route("api/[controller]")] 13 | [ApiController] 14 | public class AuthController : ControllerBase 15 | { 16 | IAuthService _authService; 17 | 18 | public AuthController(IAuthService authService) 19 | { 20 | _authService = authService; 21 | } 22 | 23 | [HttpPost("login")] 24 | public IActionResult Login(UserForLoginDto userForLoginDto) 25 | { 26 | var userToLogin = _authService.Login(userForLoginDto); 27 | if (!userToLogin.Success) 28 | { 29 | return BadRequest(userToLogin); 30 | } 31 | 32 | var result = _authService.CreateAccessToken(userToLogin.Data); 33 | if (result.Success) 34 | { 35 | return Ok(result); 36 | } 37 | return BadRequest(result); 38 | } 39 | 40 | [HttpPost("register")] 41 | public IActionResult Register(UserForRegisterDto userForRegisterDto) 42 | { 43 | var userExists = _authService.UserExists(userForRegisterDto.Email); 44 | if (!userExists.Success) 45 | { 46 | return BadRequest(userExists); 47 | } 48 | var registerResult = _authService.Register(userForRegisterDto); 49 | if (registerResult.Success) 50 | { 51 | return Ok(registerResult); 52 | } 53 | return BadRequest(registerResult); 54 | } 55 | } 56 | } 57 | 58 | -------------------------------------------------------------------------------- /Core/obj/Debug/netstandard2.0/Core.csproj.FileListAbsolute.txt: -------------------------------------------------------------------------------- 1 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Core\bin\Debug\netstandard2.0\Core.deps.json 2 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Core\bin\Debug\netstandard2.0\Core.dll 3 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Core\bin\Debug\netstandard2.0\Core.pdb 4 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Core\obj\Debug\netstandard2.0\Core.AssemblyInfoInputs.cache 5 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Core\obj\Debug\netstandard2.0\Core.AssemblyInfo.cs 6 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Core\obj\Debug\netstandard2.0\Core.dll 7 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Core\obj\Debug\netstandard2.0\Core.pdb 8 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Core\obj\Debug\netstandard2.0\Core.csprojAssemblyReference.cache 9 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Core\obj\Debug\netstandard2.0\Core.csproj.CoreCompileInputs.cache 10 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Core\bin\Debug\netstandard2.0\Core.deps.json 11 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Core\bin\Debug\netstandard2.0\Core.dll 12 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Core\bin\Debug\netstandard2.0\Core.pdb 13 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Core\obj\Debug\netstandard2.0\Core.csprojAssemblyReference.cache 14 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Core\obj\Debug\netstandard2.0\Core.AssemblyInfoInputs.cache 15 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Core\obj\Debug\netstandard2.0\Core.AssemblyInfo.cs 16 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Core\obj\Debug\netstandard2.0\Core.dll 17 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Core\obj\Debug\netstandard2.0\Core.pdb 18 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Core\obj\Debug\netstandard2.0\Core.csproj.CoreCompileInputs.cache 19 | -------------------------------------------------------------------------------- /WebApi/Controllers/CarImagesController.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using Business.Abstract; 6 | using Entities.Concrete; 7 | using Entities.DTOs; 8 | using Microsoft.AspNetCore.Http; 9 | using Microsoft.AspNetCore.Mvc; 10 | 11 | namespace WebApi.Controllers 12 | { 13 | [Route("api/[controller]")] 14 | [ApiController] 15 | public class CarImagesController : ControllerBase 16 | { 17 | ICarImageService _carImageService; 18 | 19 | [HttpPost("add")] 20 | [DisableRequestSizeLimit] 21 | public IActionResult Add([FromForm] CarImagesOperationDto carImagesOperationDto) 22 | { 23 | var result = _carImageService.Add(carImagesOperationDto); 24 | if (result.Success) 25 | return Ok(result); 26 | return BadRequest(result); 27 | } 28 | 29 | [HttpPost("update")] 30 | [DisableRequestSizeLimit] 31 | public IActionResult Update([FromForm] CarImagesOperationDto carImagesOperationDto) 32 | { 33 | var result = _carImageService.Update(carImagesOperationDto); 34 | if (result.Success) 35 | return Ok(result); 36 | return BadRequest(result); 37 | } 38 | 39 | [HttpPost("delete")] 40 | public IActionResult Delete(CarImage carImage) 41 | { 42 | return Ok(_carImageService.Delete(carImage)); 43 | } 44 | 45 | [HttpGet("get")] 46 | public IActionResult Get() 47 | { 48 | return Ok(_carImageService.GetAll()); 49 | } 50 | 51 | [HttpGet("getall")] 52 | public IActionResult GetAll() 53 | { 54 | return Ok(_carImageService.GetAll()); 55 | } 56 | 57 | [HttpGet("getallbycarid")] 58 | public IActionResult GetAllByCarId(int carId) 59 | { 60 | return Ok(_carImageService.GetAllByCarId(carId)); 61 | } 62 | } 63 | } 64 | 65 | -------------------------------------------------------------------------------- /Core/Extensions/ExceptionMiddleware.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Net; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using FluentValidation; 7 | using FluentValidation.Results; 8 | using Microsoft.AspNetCore.Http; 9 | 10 | namespace Core.Extensions 11 | { 12 | public class ExceptionMiddleware 13 | { 14 | private RequestDelegate _next; 15 | 16 | public ExceptionMiddleware(RequestDelegate next) 17 | { 18 | _next = next; 19 | } 20 | 21 | public async Task InvokeAsync(HttpContext httpContext) 22 | { 23 | try 24 | { 25 | await _next(httpContext); 26 | } 27 | catch (Exception e) 28 | { 29 | await HandleExceptionAsync(httpContext, e); 30 | } 31 | } 32 | 33 | private Task HandleExceptionAsync(HttpContext httpContext, Exception e) 34 | { 35 | httpContext.Response.ContentType = "application/json"; 36 | httpContext.Response.StatusCode = (int)HttpStatusCode.InternalServerError; 37 | 38 | string message = "Internal Server Error"; 39 | IEnumerable errors; 40 | if (e.GetType() == typeof(ValidationException)) 41 | { 42 | message = e.Message; 43 | errors = ((ValidationException)e).Errors; 44 | httpContext.Response.StatusCode = 400; 45 | 46 | return httpContext.Response.WriteAsync(new ValidationErrorDetails 47 | { 48 | StatusCode = 400, 49 | Message = message, 50 | Errors = errors 51 | }.ToString()); 52 | } 53 | 54 | return httpContext.Response.WriteAsync(new ErrorDetails 55 | { 56 | StatusCode = httpContext.Response.StatusCode, 57 | Message = message 58 | }.ToString()); 59 | } 60 | } 61 | } 62 | -------------------------------------------------------------------------------- /Core/DataAccess/EntityFramework/EfEntityRepositoryBase.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Linq.Expressions; 5 | using System.Text; 6 | using Core.Entities; 7 | using Microsoft.EntityFrameworkCore; 8 | 9 | namespace Core.DataAccess.EntityFramework 10 | { 11 | public class EfEntityRepositoryBase:IEntityRepository 12 | where TEntity: class, IEntity, new() 13 | where TContext : DbContext, new() 14 | { 15 | public void Add(TEntity entity) 16 | { 17 | using (TContext context = new TContext()) 18 | { 19 | var addedEntity = context.Entry(entity); 20 | addedEntity.State = EntityState.Added; 21 | context.SaveChanges(); 22 | } 23 | } 24 | 25 | public void Delete(TEntity entity) 26 | { 27 | using (TContext context = new TContext()) 28 | { 29 | var deletedCar = context.Entry(entity); 30 | deletedCar.State = EntityState.Deleted; 31 | context.SaveChanges(); 32 | } 33 | } 34 | 35 | public TEntity Get(Expression> filter) 36 | { 37 | using (TContext context = new TContext()) 38 | { 39 | return context.Set().SingleOrDefault(filter); 40 | } 41 | } 42 | 43 | public List GetAll(Expression> filter = null) 44 | { 45 | using (TContext context = new TContext()) 46 | { 47 | return filter == null ? context.Set().ToList() : context.Set().Where(filter).ToList(); 48 | } 49 | } 50 | 51 | public void Update(TEntity entity) 52 | { 53 | using (TContext context = new TContext()) 54 | { 55 | var updatedCar = context.Entry(entity); 56 | updatedCar.State = EntityState.Modified; 57 | context.SaveChanges(); 58 | } 59 | } 60 | } 61 | } 62 | -------------------------------------------------------------------------------- /Business/Concrete/CustomerManager.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Business.Abstract; 5 | using Business.Constants; 6 | using Core.Utilites.Results.Abstract; 7 | using Core.Utilites.Results.Concrete; 8 | using DataAccess.Abstract; 9 | using Entities.Concrete; 10 | using Entities.DTOs; 11 | 12 | namespace Business.Concrete 13 | { 14 | public class CustomerManager : ICustomerService 15 | { 16 | ICustomerDal _customerDal; 17 | 18 | public CustomerManager(ICustomerDal customerDal) 19 | { 20 | _customerDal = customerDal; 21 | } 22 | 23 | public IResult Add(Customer customer) 24 | { 25 | 26 | _customerDal.Add(customer); 27 | return new SuccessResult(Message.CustomerAdded); 28 | } 29 | 30 | public IResult Delete(Customer customer) 31 | { 32 | _customerDal.Delete(customer); 33 | return new SuccessResult(Message.CustomerDeleted); 34 | } 35 | 36 | public IDataResult Get(int id) 37 | { 38 | Customer customer = _customerDal.Get(p => p.Id == id); 39 | if (customer == null) 40 | { 41 | return new ErrorDataResult(Message.CustomerNameInvalid); 42 | } 43 | else 44 | { 45 | return new SuccessDataResult(customer, Message.CutomerListed); 46 | } 47 | } 48 | 49 | public IDataResult> GetAll() 50 | { 51 | return new SuccessDataResult>(_customerDal.GetAll(), Message.CarListed); 52 | } 53 | 54 | 55 | public IDataResult> GetCustomerDetails() 56 | { 57 | return new SuccessDataResult>(_customerDal.GetCustomerDetailDto(), Message.CutomerListed); 58 | } 59 | 60 | public IResult Update(Customer customer) 61 | { 62 | _customerDal.Update(customer); 63 | return new SuccessResult(Message.CustomerUpdated); 64 | } 65 | } 66 | } 67 | -------------------------------------------------------------------------------- /WebApi/Controllers/CustomersController.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using Business.Abstract; 6 | using Entities.Concrete; 7 | using Microsoft.AspNetCore.Http; 8 | using Microsoft.AspNetCore.Mvc; 9 | 10 | namespace WebApi.Controllers 11 | { 12 | [Route("api/[controller]")] 13 | [ApiController] 14 | public class CustomersController : ControllerBase 15 | { 16 | ICustomerService _customerService; 17 | 18 | public CustomersController(ICustomerService customerService) 19 | { 20 | _customerService = customerService; 21 | } 22 | 23 | [HttpGet("getbyid")] 24 | public ActionResult GetById(int id) 25 | { 26 | var result = _customerService.Get(id); 27 | if (result.Success) 28 | return Ok(result); 29 | return BadRequest(result); 30 | } 31 | 32 | [HttpGet("getall")] 33 | public ActionResult GetAll() 34 | { 35 | var result = _customerService.GetAll(); 36 | if (result.Success) 37 | return Ok(result); 38 | return BadRequest(result); 39 | } 40 | 41 | [HttpGet("getcustomerdetails")] 42 | public ActionResult GetCustomerDetails() 43 | { 44 | var result = _customerService.GetCustomerDetails(); 45 | if (result.Success) 46 | return Ok(result); 47 | return BadRequest(result); 48 | } 49 | 50 | [HttpPost("add")] 51 | public ActionResult Add(Customer customer) 52 | { 53 | var result = _customerService.Add(customer); 54 | if (result.Success) 55 | return Ok(result); 56 | return BadRequest(result); 57 | } 58 | 59 | [HttpPost("update")] 60 | public ActionResult Update(Customer customer) 61 | { 62 | var result = _customerService.Update(customer); 63 | if (result.Success) 64 | return Ok(result); 65 | return BadRequest(result); 66 | } 67 | } 68 | } 69 | 70 | -------------------------------------------------------------------------------- /Business/Concrete/BrandManager.cs: -------------------------------------------------------------------------------- 1 | using Business.Abstract; 2 | using Business.BusinessAspects.Autofac; 3 | using Business.Constants; 4 | using Business.ValidationRules.FluentValidation; 5 | using Core.Aspects.Autofac.Validation; 6 | using Core.Utilites.Results.Abstract; 7 | using Core.Utilites.Results.Concrete; 8 | using DataAccess.Abstract; 9 | using Entities.Concrete; 10 | using System; 11 | using System.Collections.Generic; 12 | using System.Text; 13 | 14 | namespace Business.Concrete 15 | { 16 | public class BrandManager : IBrandService 17 | { 18 | IBrandDal _brandDal; 19 | 20 | public BrandManager(IBrandDal brandDal) 21 | { 22 | _brandDal = brandDal; 23 | } 24 | [SecuredOperation("brand.add, admin")] 25 | [ValidationAspect(typeof(BrandValidator))] 26 | public IResult Add(Brand brand) 27 | { 28 | if(brand.BrandName.Length > 2) 29 | { 30 | _brandDal.Add(brand); 31 | return new SuccessResult(Message.BrandAdded); 32 | 33 | } 34 | else 35 | { 36 | return new ErrorResult(Message.BrandNameInvalid); 37 | 38 | } 39 | } 40 | 41 | public IResult Delete(Brand brand) 42 | { 43 | _brandDal.Delete(brand); 44 | return new SuccessResult(Message.BrandDeleted); 45 | 46 | } 47 | 48 | public IDataResult> GetAll() 49 | { 50 | return new SuccessDataResult>(_brandDal.GetAll()); 51 | } 52 | 53 | public IDataResult GetById(int id) 54 | { 55 | return new SuccessDataResult(_brandDal.Get(c => c.BrandId == id)); 56 | } 57 | 58 | public IResult Update(Brand brand) 59 | { 60 | if (brand.BrandName.Length >= 2) 61 | { 62 | _brandDal.Update(brand); 63 | return new SuccessResult(Message.BrandUpdated); 64 | 65 | } 66 | else 67 | { 68 | return new ErrorResult(Message.BrandNameInvalid); 69 | 70 | } 71 | 72 | } 73 | } 74 | } 75 | -------------------------------------------------------------------------------- /DataAccess/Concrete/EntityFramework/Repository/EfRentalDal.cs: -------------------------------------------------------------------------------- 1 | using Core.DataAccess.EntityFramework; 2 | using DataAccess.Abstract; 3 | using DataAccess.Concrete.EntityFramework.Context; 4 | using Entities.Concrete; 5 | using Entities.DTOs; 6 | using System; 7 | using System.Collections.Generic; 8 | using System.Linq; 9 | using System.Linq.Expressions; 10 | 11 | namespace DataAccess.Concrete.EntityFramework.Repository 12 | { 13 | public class EfRentalDal : EfEntityRepositoryBase, IRentalDal 14 | { 15 | public List GetAllRentalDetails(Expression> filter = null) 16 | { 17 | using (RentACarContext context = new RentACarContext()) 18 | { 19 | var result = 20 | from rental in filter == null ? context.Rentals : context.Rentals.Where(filter) 21 | join customer in context.Customers 22 | on rental.CustomerId equals customer.Id 23 | join user in context.Users 24 | on customer.UserId equals user.Id 25 | join car in context.Cars 26 | on rental.CarId equals car.CarId 27 | join brand in context.Brands 28 | on car.BrandId equals brand.BrandId 29 | join color in context.Colors 30 | on car.ColorId equals color.ColorId 31 | select new RentalDetailDto 32 | { 33 | RentDate = rental.RentDate, 34 | ReturnDate = rental.ReturnDate, 35 | Id = rental.Id, 36 | BrandName = brand.BrandName, 37 | CarDesctiption = car.Descriptions, 38 | ColorName = color.ColorName, 39 | CompanyName = customer.CompanyName, 40 | DailyPrice = car.DailyPrice, 41 | FirstName = user.FirstName, 42 | LastName = user.LastName, 43 | ModelYear = car.ModelYear 44 | }; 45 | return result.ToList(); 46 | } 47 | } 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /WebApi/Controllers/ColorsController.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using Business.Abstract; 6 | using Entities.Concrete; 7 | using Microsoft.AspNetCore.Http; 8 | using Microsoft.AspNetCore.Mvc; 9 | 10 | namespace WebApi.Controllers 11 | { 12 | [Route("api/[controller]")] 13 | [ApiController] 14 | public class ColorsController : ControllerBase 15 | { 16 | IColorService _colorService; 17 | 18 | public ColorsController(IColorService colorService) 19 | { 20 | _colorService = colorService; 21 | } 22 | 23 | [HttpGet("getall")] 24 | public IActionResult GetAll() 25 | { 26 | var result = _colorService.GetAll(); 27 | if (result.Success) 28 | { 29 | return Ok(result); 30 | } 31 | return BadRequest(result); 32 | } 33 | 34 | [HttpGet("getbyid")] 35 | public IActionResult GetById(int id) 36 | { 37 | var result = _colorService.GetById(id); 38 | if (result.Success) 39 | { 40 | return Ok(result); 41 | } 42 | return BadRequest(result); 43 | } 44 | 45 | [HttpPost("add")] 46 | public IActionResult Add(Color color) 47 | { 48 | var result = _colorService.Add(color); 49 | if (result.Success) 50 | { 51 | return Ok(result); 52 | } 53 | return BadRequest(result); 54 | } 55 | 56 | [HttpPost("update")] 57 | public IActionResult Update(Color color) 58 | { 59 | var result = _colorService.Update(color); 60 | if (result.Success) 61 | { 62 | return Ok(result); 63 | } 64 | return BadRequest(result); 65 | } 66 | 67 | [HttpPost("delete")] 68 | public IActionResult Delete(Color color) 69 | { 70 | var result = _colorService.Delete(color); 71 | if (result.Success) 72 | { 73 | return Ok(result); 74 | } 75 | return BadRequest(result); 76 | } 77 | } 78 | } 79 | -------------------------------------------------------------------------------- /WebApi/Controllers/BrandsController.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using Business.Abstract; 6 | using Entities.Concrete; 7 | using Microsoft.AspNetCore.Http; 8 | using Microsoft.AspNetCore.Mvc; 9 | 10 | namespace WebApi.Controllers 11 | { 12 | [Route("api/[controller]")] 13 | [ApiController] 14 | public class BrandsController : ControllerBase 15 | { 16 | IBrandService _brandService; 17 | 18 | public BrandsController(IBrandService brandService) 19 | { 20 | _brandService = brandService; 21 | } 22 | 23 | [HttpGet("getall")] 24 | public IActionResult GetAll() 25 | { 26 | var result = _brandService.GetAll(); 27 | if (result.Success) 28 | { 29 | return Ok(result); 30 | } 31 | return BadRequest(result); 32 | } 33 | 34 | [HttpGet("getbyid")] 35 | public IActionResult GetById(int id) 36 | { 37 | var result = _brandService.GetById(id); 38 | if (result.Success) 39 | { 40 | return Ok(result); 41 | } 42 | return BadRequest(result); 43 | } 44 | 45 | [HttpPost("add")] 46 | public IActionResult Add(Brand brand) 47 | { 48 | var result = _brandService.Add(brand); 49 | if (result.Success) 50 | { 51 | return Ok(result); 52 | } 53 | return BadRequest(result); 54 | 55 | } 56 | 57 | [HttpPost("update")] 58 | public IActionResult Update(Brand brand) 59 | { 60 | var result = _brandService.Update(brand); 61 | if (result.Success) 62 | { 63 | return Ok(result); 64 | } 65 | return BadRequest(result); 66 | 67 | } 68 | 69 | [HttpPost("delete")] 70 | public IActionResult Delete(Brand brand) 71 | { 72 | var result = _brandService.Delete(brand); 73 | if (result.Success) 74 | { 75 | return Ok(result); 76 | } 77 | return BadRequest(result); 78 | 79 | } 80 | } 81 | } 82 | -------------------------------------------------------------------------------- /Core/Utilites/FileProces/FileProces.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.IO; 4 | using System.Text; 5 | using Core.Utilites.Results.Abstract; 6 | using Core.Utilites.Results.Concrete; 7 | using Microsoft.AspNetCore.Hosting; 8 | using Microsoft.AspNetCore.Http; 9 | 10 | namespace Core.Utilites.FileProces 11 | { 12 | public class FileProcess : IFileProcess 13 | { 14 | private readonly IHostingEnvironment environment; 15 | 16 | public FileProcess(IHostingEnvironment environment) 17 | { 18 | this.environment = environment; 19 | } 20 | 21 | public IResult Delete(string filePath) 22 | { 23 | File.Delete(filePath); 24 | return new SuccessResult(); 25 | } 26 | 27 | public IDataResult Upload(string directoryPath, IFormFile file) 28 | { 29 | FolderControl(directoryPath); 30 | if (file != null && file.Length > 0) 31 | { 32 | string fileName = Guid.NewGuid().ToString("D") + Path.GetExtension(file.FileName).ToLower(); 33 | var filePath = Path.Combine(environment.WebRootPath, directoryPath, fileName); 34 | using (var stream = File.Create(filePath)) 35 | { 36 | file.CopyTo(stream); 37 | stream.Flush(); 38 | } 39 | 40 | return new SuccessDataResult(Path.Combine(directoryPath, fileName), ""); 41 | } 42 | return new ErrorDataResult(); 43 | } 44 | 45 | /// 46 | /// FolderControl 47 | /// 48 | /// example 1: foldername

    example 2: foldername/subfoldername/.... [unlimited] 49 | private void FolderControl(string directoryPath) 50 | { 51 | string[] directories = directoryPath.Split('/'); 52 | string checkPath = ""; 53 | 54 | foreach (var directory in directories) 55 | { 56 | checkPath += directory + "\\"; 57 | var path = Path.Combine(environment.WebRootPath, checkPath); 58 | if (!Directory.Exists(checkPath)) 59 | { 60 | Directory.CreateDirectory(path); 61 | } 62 | } 63 | } 64 | } 65 | } 66 | -------------------------------------------------------------------------------- /DataAccess/Concrete/InMemory/InMemoryCarDal.cs: -------------------------------------------------------------------------------- 1 | using DataAccess.Abstract; 2 | using Entities.Concrete; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Linq; 6 | using System.Text; 7 | 8 | namespace DataAccess.Concrete.InMemory 9 | { 10 | //public class InMemoryCarDal : ICarDal 11 | public class InMemoryCarDal 12 | { 13 | //List _cars; 14 | 15 | //public InMemoryCarDal() 16 | //{ 17 | // _cars = new List() 18 | // { 19 | // new Car{Id= 1, BrandId = 1, ColorId = 1, DailyPrice = 200, ModelYear = "2012", Descriptions = "Otomatik Dizel" }, 20 | // new Car{Id= 2, BrandId = 2, ColorId = 2, DailyPrice = 50, ModelYear = "2010", Descriptions = "Manuel Benzin" }, 21 | // new Car{Id= 3, BrandId = 2, ColorId = 1, DailyPrice = 100, ModelYear = "2019", Descriptions = "Manuel Dizel" }, 22 | // new Car{Id= 4, BrandId = 3, ColorId = 2, DailyPrice = 150, ModelYear = "2018", Descriptions = "Otomatik Benzin" }, 23 | // }; 24 | //} 25 | 26 | //public void Add(Car car) 27 | //{ 28 | // _cars.Add(car); 29 | //} 30 | 31 | //public void Delete(int id) 32 | //{ 33 | // Car carToDelete = _cars.SingleOrDefault(c => c.Id == id); 34 | // _cars.Remove(carToDelete); 35 | //} 36 | 37 | //public List GetAll() 38 | //{ 39 | // return _cars; 40 | //} 41 | 42 | //public List GetAllByBrand(int brandId) 43 | //{ 44 | // return _cars.Where(c => c.BrandId == brandId).ToList(); 45 | //} 46 | 47 | //public List GetAllByColor(int colorId) 48 | //{ 49 | // return _cars.Where(c => c.ColorId == colorId).ToList(); 50 | //} 51 | 52 | //public Car GetById(int id) 53 | //{ 54 | // return _cars.SingleOrDefault(c => c.Id == id); 55 | //} 56 | 57 | //public void Update(Car car) 58 | //{ 59 | // Car carToUpdate = _cars.SingleOrDefault(c => c.Id == car.Id); 60 | // carToUpdate.BrandId = car.BrandId; 61 | // carToUpdate.ColorId = car.ColorId; 62 | // carToUpdate.DailyPrice = car.DailyPrice; 63 | // carToUpdate.ModelYear = car.ModelYear; 64 | // carToUpdate.Descriptions = car.Descriptions; 65 | //} 66 | } 67 | } 68 | -------------------------------------------------------------------------------- /Business/DependencyResolvers/Autofac/AutofacBusinessModule.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Autofac; 5 | using Autofac.Extras.DynamicProxy; 6 | using Business.Abstract; 7 | using Business.Concrete; 8 | using Castle.DynamicProxy; 9 | using Core.Utilites.Interceptors; 10 | using Core.Utilites.Security.JWT; 11 | using DataAccess.Abstract; 12 | using DataAccess.Concrete.EntityFramework; 13 | using DataAccess.Concrete.EntityFramework.Repository; 14 | 15 | namespace Business.DependencyResolvers.Autofac 16 | { 17 | public class AutofacBusinessModule : Module 18 | { 19 | protected override void Load(ContainerBuilder builder) 20 | { 21 | builder.RegisterType().As().SingleInstance(); 22 | builder.RegisterType().As().SingleInstance(); 23 | 24 | builder.RegisterType().As().SingleInstance(); 25 | builder.RegisterType().As().SingleInstance(); 26 | 27 | builder.RegisterType().As().SingleInstance(); 28 | builder.RegisterType().As().SingleInstance(); 29 | 30 | builder.RegisterType().As().SingleInstance(); 31 | builder.RegisterType().As().SingleInstance(); 32 | 33 | builder.RegisterType().As().SingleInstance(); 34 | builder.RegisterType().As().SingleInstance(); 35 | 36 | builder.RegisterType().As(); 37 | builder.RegisterType().As(); 38 | 39 | builder.RegisterType().As(); 40 | builder.RegisterType().As(); 41 | 42 | builder.RegisterType().As().SingleInstance(); 43 | builder.RegisterType().As().SingleInstance(); 44 | 45 | var assembly = System.Reflection.Assembly.GetExecutingAssembly(); 46 | 47 | builder.RegisterAssemblyTypes(assembly).AsImplementedInterfaces() 48 | .EnableInterfaceInterceptors(new ProxyGenerationOptions() 49 | { 50 | Selector = new AspectInterceptorSelector() 51 | }).SingleInstance(); 52 | } 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /Entities/obj/Debug/netstandard2.0/Entities.csproj.FileListAbsolute.txt: -------------------------------------------------------------------------------- 1 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Entities\bin\Debug\netstandard2.0\Entities.deps.json 2 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Entities\bin\Debug\netstandard2.0\Entities.dll 3 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Entities\bin\Debug\netstandard2.0\Entities.pdb 4 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Entities\obj\Debug\netstandard2.0\Entities.csprojAssemblyReference.cache 5 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Entities\obj\Debug\netstandard2.0\Entities.AssemblyInfoInputs.cache 6 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Entities\obj\Debug\netstandard2.0\Entities.AssemblyInfo.cs 7 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Entities\obj\Debug\netstandard2.0\Entities.csproj.CoreCompileInputs.cache 8 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Entities\obj\Debug\netstandard2.0\Entities.dll 9 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Entities\obj\Debug\netstandard2.0\Entities.pdb 10 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Entities\bin\Debug\netstandard2.0\Core.dll 11 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Entities\bin\Debug\netstandard2.0\Core.pdb 12 | C:\Users\PC\Desktop\re-cap-project-with-csharp-main\Entities\obj\Debug\netstandard2.0\Entities.csproj.CopyComplete 13 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Entities\bin\Debug\netstandard2.0\Entities.deps.json 14 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Entities\bin\Debug\netstandard2.0\Entities.dll 15 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Entities\bin\Debug\netstandard2.0\Entities.pdb 16 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Entities\bin\Debug\netstandard2.0\Core.dll 17 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Entities\bin\Debug\netstandard2.0\Core.pdb 18 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Entities\obj\Debug\netstandard2.0\Entities.csprojAssemblyReference.cache 19 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Entities\obj\Debug\netstandard2.0\Entities.AssemblyInfoInputs.cache 20 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Entities\obj\Debug\netstandard2.0\Entities.AssemblyInfo.cs 21 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Entities\obj\Debug\netstandard2.0\Entities.csproj.CoreCompileInputs.cache 22 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Entities\obj\Debug\netstandard2.0\Entities.csproj.CopyComplete 23 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Entities\obj\Debug\netstandard2.0\Entities.dll 24 | C:\Users\PC\Desktop\C# Yazılımcı\ReCapProject\Entities\obj\Debug\netstandard2.0\Entities.pdb 25 | -------------------------------------------------------------------------------- /Core/CrossCuttingConcerns/Caching/Microsoft/MemoryCacheManager.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Text.RegularExpressions; 6 | using Core.Utilites.IoC; 7 | using Microsoft.Extensions.Caching.Memory; 8 | using Microsoft.Extensions.DependencyInjection; 9 | namespace Core.CrossCuttingConcerns.Caching.Microsoft 10 | { 11 | public class MemoryCacheManager : ICacheManager 12 | { 13 | 14 | 15 | // karşılığı CoreModule da 16 | IMemoryCache _memoryCache; 17 | 18 | public MemoryCacheManager() 19 | { 20 | 21 | _memoryCache = ServiceTool.ServiceProvider.GetService(); 22 | } 23 | 24 | public void Add(string key, object value, int duration) 25 | { 26 | _memoryCache.Set(key, value, TimeSpan.FromMinutes(duration)); 27 | } 28 | 29 | public T Get(string key) 30 | { 31 | return _memoryCache.Get(key); 32 | } 33 | 34 | public object Get(string key) 35 | { 36 | return _memoryCache.Get(key); 37 | } 38 | 39 | public bool IsAdd(string key) 40 | { 41 | // bellekte var mı 42 | // out _ değeri istemediğimizin karşılığı 43 | return _memoryCache.TryGetValue(key, out _); 44 | } 45 | 46 | public void Remove(string key) 47 | { 48 | _memoryCache.Remove(key); 49 | } 50 | 51 | public void RemoveByPattern(string pattern) 52 | { 53 | var cacheEntriesCollectionDefinition = typeof(MemoryCache).GetProperty("EntriesCollection", System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Instance); 54 | var cacheEntriesCollection = cacheEntriesCollectionDefinition.GetValue(_memoryCache) as dynamic; 55 | List cacheCollectionValues = new List(); 56 | 57 | foreach (var cacheItem in cacheEntriesCollection) 58 | { 59 | ICacheEntry cacheItemValue = cacheItem.GetType().GetProperty("Value").GetValue(cacheItem, null); 60 | cacheCollectionValues.Add(cacheItemValue); 61 | } 62 | 63 | var regex = new Regex(pattern, RegexOptions.Singleline | RegexOptions.Compiled | RegexOptions.IgnoreCase); 64 | var keysToRemove = cacheCollectionValues.Where(d => regex.IsMatch(d.Key.ToString())).Select(d => d.Key).ToList(); 65 | 66 | foreach (var key in keysToRemove) 67 | { 68 | _memoryCache.Remove(key); 69 | } 70 | } 71 | } 72 | } 73 | -------------------------------------------------------------------------------- /Business/Concrete/UserManager.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Business.Abstract; 5 | using Business.Constants; 6 | using Core.Entities.Concrete; 7 | using Core.Utilites.Results.Abstract; 8 | using Core.Utilites.Results.Concrete; 9 | using DataAccess.Abstract; 10 | using Entities.Concrete; 11 | 12 | namespace Business.Concrete 13 | { 14 | public class UserManager : IUserService 15 | { 16 | IUserDal _userDal; 17 | 18 | public UserManager(IUserDal userDal) 19 | { 20 | _userDal = userDal; 21 | } 22 | 23 | 24 | 25 | public IResult Delete(User entity) 26 | { 27 | _userDal.Delete(entity); 28 | return new SuccessResult(); 29 | } 30 | 31 | public IDataResult Get(int id) 32 | { 33 | 34 | return new SuccessDataResult(_userDal.Get(u => u.Id == id)); 35 | 36 | //User user = _userDal.Get(p => p.Id == id); 37 | //if (user == null) 38 | //{ 39 | // return new ErrorDataResult(Message.UserNotFound); 40 | //} 41 | //else 42 | //{ 43 | // return new SuccessDataResult(user); 44 | //} 45 | } 46 | 47 | public IDataResult> GetAll() 48 | { 49 | List users = _userDal.GetAll(); 50 | if (users.Count == 0) 51 | { 52 | return new ErrorDataResult>(Message.UserNotFound); 53 | } 54 | else 55 | { 56 | return new SuccessDataResult>(users); 57 | } 58 | } 59 | 60 | public IDataResult GetByEmail(string email) 61 | { 62 | User user = _userDal.Get(p => p.Email.ToLower() == email.ToLower()); 63 | if (user == null) 64 | { 65 | return new ErrorDataResult(Message.UserNotFound); 66 | } 67 | else 68 | { 69 | return new SuccessDataResult(user); 70 | } 71 | } 72 | 73 | public IDataResult> GetClaims(User user) 74 | { 75 | return new SuccessDataResult>(_userDal.GetClaims(user)); 76 | } 77 | 78 | 79 | 80 | public IResult Update(User entity) 81 | { 82 | _userDal.Update(entity); 83 | return new SuccessResult(); 84 | } 85 | 86 | public IResult Add(User entity) 87 | { 88 | _userDal.Add(entity); 89 | return new SuccessResult(Message.UserRegistered); 90 | } 91 | 92 | 93 | } 94 | } 95 | -------------------------------------------------------------------------------- /Business/Concrete/AuthMenager.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Business.Abstract; 5 | using Business.Constants; 6 | using Core.Entities.Dtos; 7 | using Core.Utilites.Results.Abstract; 8 | using Core.Utilites.Results.Concrete; 9 | using Core.Utilites.Security.Hashing; 10 | using Core.Utilites.Security.JWT; 11 | using Entities.Concrete; 12 | 13 | namespace Business.Concrete 14 | { 15 | public class AuthManager : IAuthService 16 | { 17 | IUserService _userService; 18 | ITokenHelper _tokenHelper; 19 | 20 | public AuthManager(IUserService userService, ITokenHelper tokenHelper) 21 | { 22 | _userService = userService; 23 | _tokenHelper = tokenHelper; 24 | } 25 | 26 | public IDataResult CreateAccessToken(User user) 27 | { 28 | var claims = _userService.GetClaims(user); 29 | var accessToken = _tokenHelper.CreateToken(user, claims.Data); 30 | return new SuccessDataResult(accessToken, Message.TokenCreated); 31 | } 32 | 33 | public IDataResult Login(UserForLoginDto userForLoginDto) 34 | { 35 | var userToCheck = _userService.GetByEmail(userForLoginDto.Email); 36 | if (userToCheck.Data == null) 37 | { 38 | return new ErrorDataResult(Message.UserNotFound); 39 | } 40 | if (!HashingHelper.VerifyPasswordHash(userForLoginDto.Password, userToCheck.Data.PasswordHash, userToCheck.Data.PasswordSalt)) 41 | { 42 | return new ErrorDataResult(Message.WrongPassword); 43 | } 44 | return new SuccessDataResult(userToCheck.Data, Message.SuccessfulLogin); 45 | } 46 | 47 | public IDataResult Register(UserForRegisterDto userForRegisterDto) 48 | { 49 | HashingHelper.CreatePasswordHash(userForRegisterDto.Password, out byte[] passwordHash, out byte[] passwordSalt); 50 | var user = new User 51 | { 52 | Email = userForRegisterDto.Email, 53 | FirstName = userForRegisterDto.FirstName, 54 | LastName = userForRegisterDto.LastName, 55 | PasswordHash = passwordHash, 56 | PasswordSalt = passwordSalt, 57 | Status = true 58 | }; 59 | _userService.Add(user); 60 | return new SuccessDataResult(user, Message.Registered); 61 | } 62 | 63 | public IResult UserExists(string email) 64 | { 65 | if (_userService.GetByEmail(email).Data != null) 66 | { 67 | return new ErrorResult(Message.UserAvailable); 68 | } 69 | return new SuccessResult(); 70 | } 71 | } 72 | } 73 | -------------------------------------------------------------------------------- /Core/Utilites/Security/JWT/JwtHelper.cs: -------------------------------------------------------------------------------- 1 | using Core.Entities.Concrete; 2 | using Core.Extensions; 3 | using Core.Utilites.Security.Encryption; 4 | using Entities.Concrete; 5 | using Microsoft.Extensions.Configuration; 6 | using Microsoft.IdentityModel.Tokens; 7 | using System; 8 | using System.Collections.Generic; 9 | using System.IdentityModel.Tokens.Jwt; 10 | using System.Linq; 11 | using System.Security.Claims; 12 | using System.Text; 13 | 14 | namespace Core.Utilites.Security.JWT 15 | { 16 | public class JwtHelper : ITokenHelper 17 | { 18 | public IConfiguration Configuration { get; } 19 | private TokenOptions _tokenOptions; 20 | private DateTime _accessTokenExpiration; 21 | 22 | public JwtHelper(IConfiguration configuration) 23 | { 24 | Configuration = configuration; 25 | _tokenOptions = Configuration.GetSection("TokenOptions").Get(); 26 | } 27 | 28 | public AccessToken CreateToken(User user, List operationClaims) 29 | { 30 | _accessTokenExpiration = DateTime.Now.AddMinutes(_tokenOptions.AccessTokenExpiration); 31 | var securityKey = SecurityKeyHelper.CreateSecurityKey(_tokenOptions.SecurityKey); 32 | var signingCredentials = SigningCredentialsHelper.CreateSigningCredentials(securityKey); 33 | var jwt = CreateJwtSecurityToken(_tokenOptions, user, signingCredentials, operationClaims); 34 | var jwtSecurityTokenHandler = new JwtSecurityTokenHandler(); 35 | var token = jwtSecurityTokenHandler.WriteToken(jwt); 36 | return new AccessToken 37 | { 38 | Token = token, 39 | Expiration = _accessTokenExpiration 40 | }; 41 | } 42 | 43 | public JwtSecurityToken CreateJwtSecurityToken(TokenOptions tokenOptions, User user, SigningCredentials signingCredentials, List operationClaims) 44 | { 45 | var jwt = new JwtSecurityToken( 46 | audience: tokenOptions.Audience, 47 | issuer: tokenOptions.Issuer, 48 | expires: _accessTokenExpiration, 49 | notBefore: DateTime.Now, 50 | claims: SetClaims(user, operationClaims), 51 | signingCredentials: signingCredentials 52 | ); 53 | return jwt; 54 | } 55 | 56 | private IEnumerable SetClaims(User user, List operationClaims) 57 | { 58 | var claims = new List(); 59 | claims.AddNameIdentifier(user.Id.ToString()); 60 | claims.AddEmail(user.Email); 61 | claims.AddName($"{user.FirstName} {user.LastName}"); 62 | claims.AddRoles(operationClaims.Select(c => c.Name).ToArray()); 63 | return claims; 64 | } 65 | } 66 | } 67 | -------------------------------------------------------------------------------- /Business/Constants/Message.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Business.Constants 6 | { 7 | public static class Message 8 | { 9 | public static string CarAdded = "Araç eklendi"; 10 | public static string CarNameInvalid = "Araç ismi geçersiz"; 11 | public static string CarListed = "Araçlar listelendi"; 12 | public static string MaintenanceTime = "Sistem Bakımda"; 13 | public static string CarUpdated = "Araç güncellendi"; 14 | public static string CarDeleted = "Araç silindi"; 15 | 16 | public static string BrandAdded = "Marka eklendi"; 17 | public static string BrandDeleted = "Marka silindi"; 18 | public static string BrandUpdated = "Marka güncellendi"; 19 | public static string BrandListed = "Markalar listelendi"; 20 | public static string BrandNameInvalid = "Marka ismi geçersiz"; 21 | 22 | public static string ColorAdded = "Renk eklendi"; 23 | public static string ColorDeleted = "Renk silindi"; 24 | public static string ColorUpdated = "Renk güncellendi"; 25 | public static string ColorListed = "Renkler listelendi"; 26 | public static string ColorNameInvalid = "Renk ismi geçersiz"; 27 | 28 | public static string RentalAdded = "Kiralama eklendi"; 29 | public static string RentalNameInvalid = "Kiralama geçersiz"; 30 | 31 | public static string CustomerAdded = "Müşteri eklendi"; 32 | public static string CustomerDeleted = "Müşteri silindi"; 33 | public static string CustomerUpdated = "Müşteri güncellendi"; 34 | public static string CutomerListed = "Müşteri Listesi"; 35 | public static string CustomerNameInvalid = "Müşteri geçersiz"; 36 | 37 | public static string FailAddedImageLimit = "En fazla 5 fotoğraf eklenebilir."; 38 | 39 | public static string AuthorizationDenied = "Yetkiniz yok"; 40 | 41 | public static string UserNotFound = "Kullanıcı bulunamadı"; 42 | public static string PasswordError = "Şifre hatalı"; 43 | public static string SuccessfulLogin = "Sisteme giriş başarılı"; 44 | public static string UserAlreadyExists = "Bu kullanıcı zaten mevcut"; 45 | public static string UserRegistered = "Kullanıcı başarıyla kaydedildi"; 46 | public static string AccessTokenCreated = "Access token başarıyla oluşturuldu"; 47 | 48 | 49 | public static string Registered = "Başarıyla kayıt olundu"; 50 | 51 | public static string WrongPassword = "Yanlış parola"; 52 | 53 | public static string UserAvailable = "Kullanıcı mevcut"; 54 | public static string TokenCreated = "Token oluşturuldu."; 55 | 56 | public static string InsufficientBalance = "Yetersiz bakiye"; 57 | public static string PaymentCompleted = "Ödeme yapıldı"; 58 | 59 | } 60 | } 61 | -------------------------------------------------------------------------------- /Business/Concrete/AuthManager.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Business.Abstract; 5 | using Business.Constants; 6 | using Core.Utilites.Results.Abstract; 7 | using Core.Utilites.Results.Concrete; 8 | using Core.Utilites.Security.Hashing; 9 | using Core.Utilites.Security.JWT; 10 | using Entities.Concrete; 11 | using Entities.DTOs; 12 | 13 | namespace Business.Concrete 14 | { 15 | public class AuthManager : IAuthService 16 | { 17 | private IUserService _userService; 18 | ITokenHelper _tokenHelper; 19 | 20 | public AuthManager(IUserService userService, ITokenHelper tokenHelper) 21 | { 22 | _userService = userService; 23 | _tokenHelper = tokenHelper; 24 | } 25 | 26 | public IDataResult CreateAccessToken(User user) 27 | { 28 | var claims = _userService.GetClaims(user).Data; 29 | var accessToken = _tokenHelper.CreateToken(user, claims); 30 | return new SuccessDataResult(accessToken, Message.TokenCreated); 31 | } 32 | 33 | public IDataResult Login(UserForLoginDto userForLoginDto) 34 | { 35 | var userToCheck = _userService.GetByEmail(userForLoginDto.Email); 36 | if (userToCheck.Data == null) 37 | { 38 | return new ErrorDataResult(Message.UserNotFound); 39 | } 40 | if (!HashingHelper.VerifyPasswordHash(userForLoginDto.Password, userToCheck.Data.PasswordHash, userToCheck.Data.PasswordSalt)) 41 | { 42 | return new ErrorDataResult(Message.WrongPassword); 43 | } 44 | return new SuccessDataResult(userToCheck.Data, Message.SuccessfulLogin); 45 | 46 | } 47 | 48 | public IDataResult Register(UserForRegisterDto userForRegisterDto) 49 | { 50 | HashingHelper.CreatePasswordHash(userForRegisterDto.Password, out byte[] passwordHash, out byte[] passwordSalt); 51 | var user = new User 52 | { 53 | Email = userForRegisterDto.Email, 54 | FirstName = userForRegisterDto.FirstName, 55 | LastName = userForRegisterDto.LastName, 56 | PasswordHash = passwordHash, 57 | PasswordSalt = passwordSalt, 58 | Status = true 59 | }; 60 | _userService.Add(user); 61 | return new SuccessDataResult(user, Message.Registered); 62 | 63 | 64 | } 65 | 66 | 67 | 68 | public IResult UserExists(string email) 69 | { 70 | if (_userService.GetByEmail(email).Data != null) 71 | { 72 | return new ErrorResult(Message.UserAvailable); 73 | } 74 | return new SuccessResult(); 75 | } 76 | 77 | 78 | 79 | 80 | } 81 | } 82 | --------------------------------------------------------------------------------