diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..d19034c
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,810 @@
+# Created by https://www.toptal.com/developers/gitignore/api/dotnetcore,csharp,visualstudio,rider,jetbrains+all,windows,macos,linux,sonarqube
+# Edit at https://www.toptal.com/developers/gitignore?templates=dotnetcore,csharp,visualstudio,rider,jetbrains+all,windows,macos,linux,sonarqube
+
+### Csharp ###
+## Ignore Visual Studio temporary files, build results, and
+## files generated by popular Visual Studio add-ons.
+##
+## Get latest from https://github.com/github/gitignore/blob/main/VisualStudio.gitignore
+
+# User-specific files
+*.rsuser
+*.suo
+*.user
+*.userosscache
+*.sln.docstates
+
+# User-specific files (MonoDevelop/Xamarin Studio)
+*.userprefs
+
+# Mono auto generated files
+mono_crash.*
+
+# Build results
+[Dd]ebug/
+[Dd]ebugPublic/
+[Rr]elease/
+[Rr]eleases/
+x64/
+x86/
+[Ww][Ii][Nn]32/
+[Aa][Rr][Mm]/
+[Aa][Rr][Mm]64/
+bld/
+[Bb]in/
+[Oo]bj/
+[Ll]og/
+[Ll]ogs/
+
+# Visual Studio 2015/2017 cache/options directory
+.vs/
+# Uncomment if you have tasks that create the project's static files in wwwroot
+#wwwroot/
+
+# Visual Studio 2017 auto generated files
+Generated\ Files/
+
+# MSTest test Results
+[Tt]est[Rr]esult*/
+[Bb]uild[Ll]og.*
+
+# NUnit
+*.VisualState.xml
+TestResult.xml
+nunit-*.xml
+
+# Build Results of an ATL Project
+[Dd]ebugPS/
+[Rr]eleasePS/
+dlldata.c
+
+# Benchmark Results
+BenchmarkDotNet.Artifacts/
+
+# .NET Core
+project.lock.json
+project.fragment.lock.json
+artifacts/
+
+# ASP.NET Scaffolding
+ScaffoldingReadMe.txt
+
+# StyleCop
+StyleCopReport.xml
+
+# Files built by Visual Studio
+*_i.c
+*_p.c
+*_h.h
+*.ilk
+*.meta
+*.obj
+*.iobj
+*.pch
+*.pdb
+*.ipdb
+*.pgc
+*.pgd
+*.rsp
+*.sbr
+*.tlb
+*.tli
+*.tlh
+*.tmp
+*.tmp_proj
+*_wpftmp.csproj
+*.log
+*.tlog
+*.vspscc
+*.vssscc
+.builds
+*.pidb
+*.svclog
+*.scc
+
+# Chutzpah Test files
+_Chutzpah*
+
+# Visual C++ cache files
+ipch/
+*.aps
+*.ncb
+*.opendb
+*.opensdf
+*.sdf
+*.cachefile
+*.VC.db
+*.VC.VC.opendb
+
+# Visual Studio profiler
+*.psess
+*.vsp
+*.vspx
+*.sap
+
+# Visual Studio Trace Files
+*.e2e
+
+# TFS 2012 Local Workspace
+$tf/
+
+# Guidance Automation Toolkit
+*.gpState
+
+# ReSharper is a .NET coding add-in
+_ReSharper*/
+*.[Rr]e[Ss]harper
+*.DotSettings.user
+
+# TeamCity is a build add-in
+_TeamCity*
+
+# DotCover is a Code Coverage Tool
+*.dotCover
+
+# AxoCover is a Code Coverage Tool
+.axoCover/*
+!.axoCover/settings.json
+
+# Coverlet is a free, cross platform Code Coverage Tool
+coverage*.json
+coverage*.xml
+coverage*.info
+
+# Visual Studio code coverage results
+*.coverage
+*.coveragexml
+
+# NCrunch
+_NCrunch_*
+.*crunch*.local.xml
+nCrunchTemp_*
+
+# MightyMoose
+*.mm.*
+AutoTest.Net/
+
+# Web workbench (sass)
+.sass-cache/
+
+# Installshield output folder
+[Ee]xpress/
+
+# DocProject is a documentation generator add-in
+DocProject/buildhelp/
+DocProject/Help/*.HxT
+DocProject/Help/*.HxC
+DocProject/Help/*.hhc
+DocProject/Help/*.hhk
+DocProject/Help/*.hhp
+DocProject/Help/Html2
+DocProject/Help/html
+
+# Click-Once directory
+publish/
+
+# Publish Web Output
+*.[Pp]ublish.xml
+*.azurePubxml
+# Note: Comment the next line if you want to checkin your web deploy settings,
+# but database connection strings (with potential passwords) will be unencrypted
+*.pubxml
+*.publishproj
+
+# Microsoft Azure Web App publish settings. Comment the next line if you want to
+# checkin your Azure Web App publish settings, but sensitive information contained
+# in these scripts will be unencrypted
+PublishScripts/
+
+# NuGet Packages
+*.nupkg
+# NuGet Symbol Packages
+*.snupkg
+# The packages folder can be ignored because of Package Restore
+**/[Pp]ackages/*
+# except build/, which is used as an MSBuild target.
+!**/[Pp]ackages/build/
+# Uncomment if necessary however generally it will be regenerated when needed
+#!**/[Pp]ackages/repositories.config
+# NuGet v3's project.json files produces more ignorable files
+*.nuget.props
+*.nuget.targets
+
+# Microsoft Azure Build Output
+csx/
+*.build.csdef
+
+# Microsoft Azure Emulator
+ecf/
+rcf/
+
+# Windows Store app package directories and files
+AppPackages/
+BundleArtifacts/
+Package.StoreAssociation.xml
+_pkginfo.txt
+*.appx
+*.appxbundle
+*.appxupload
+
+# Visual Studio cache files
+# files ending in .cache can be ignored
+*.[Cc]ache
+# but keep track of directories ending in .cache
+!?*.[Cc]ache/
+
+# Others
+ClientBin/
+~$*
+*~
+*.dbmdl
+*.dbproj.schemaview
+*.jfm
+*.pfx
+*.publishsettings
+orleans.codegen.cs
+
+# Including strong name files can present a security risk
+# (https://github.com/github/gitignore/pull/2483#issue-259490424)
+#*.snk
+
+# Since there are multiple workflows, uncomment next line to ignore bower_components
+# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
+#bower_components/
+
+# RIA/Silverlight projects
+Generated_Code/
+
+# Backup & report files from converting an old project file
+# to a newer Visual Studio version. Backup files are not needed,
+# because we have git ;-)
+_UpgradeReport_Files/
+Backup*/
+UpgradeLog*.XML
+UpgradeLog*.htm
+ServiceFabricBackup/
+*.rptproj.bak
+
+# SQL Server files
+*.mdf
+*.ldf
+*.ndf
+
+# Business Intelligence projects
+*.rdl.data
+*.bim.layout
+*.bim_*.settings
+*.rptproj.rsuser
+*- [Bb]ackup.rdl
+*- [Bb]ackup ([0-9]).rdl
+*- [Bb]ackup ([0-9][0-9]).rdl
+
+# Microsoft Fakes
+FakesAssemblies/
+
+# GhostDoc plugin setting file
+*.GhostDoc.xml
+
+# Node.js Tools for Visual Studio
+.ntvs_analysis.dat
+node_modules/
+
+# Visual Studio 6 build log
+*.plg
+
+# Visual Studio 6 workspace options file
+*.opt
+
+# Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
+*.vbw
+
+# Visual Studio 6 auto-generated project file (contains which files were open etc.)
+*.vbp
+
+# Visual Studio 6 workspace and project file (working project files containing files to include in project)
+*.dsw
+*.dsp
+
+# Visual Studio 6 technical files
+
+# Visual Studio LightSwitch build output
+**/*.HTMLClient/GeneratedArtifacts
+**/*.DesktopClient/GeneratedArtifacts
+**/*.DesktopClient/ModelManifest.xml
+**/*.Server/GeneratedArtifacts
+**/*.Server/ModelManifest.xml
+_Pvt_Extensions
+
+# Paket dependency manager
+.paket/paket.exe
+paket-files/
+
+# FAKE - F# Make
+.fake/
+
+# CodeRush personal settings
+.cr/personal
+
+# Python Tools for Visual Studio (PTVS)
+__pycache__/
+*.pyc
+
+# Cake - Uncomment if you are using it
+# tools/**
+# !tools/packages.config
+
+# Tabs Studio
+*.tss
+
+# Telerik's JustMock configuration file
+*.jmconfig
+
+# BizTalk build output
+*.btp.cs
+*.btm.cs
+*.odx.cs
+*.xsd.cs
+
+# OpenCover UI analysis results
+OpenCover/
+
+# Azure Stream Analytics local run output
+ASALocalRun/
+
+# MSBuild Binary and Structured Log
+*.binlog
+
+# NVidia Nsight GPU debugger configuration file
+*.nvuser
+
+# MFractors (Xamarin productivity tool) working folder
+.mfractor/
+
+# Local History for Visual Studio
+.localhistory/
+
+# Visual Studio History (VSHistory) files
+.vshistory/
+
+# BeatPulse healthcheck temp database
+healthchecksdb
+
+# Backup folder for Package Reference Convert tool in Visual Studio 2017
+MigrationBackup/
+
+# Ionide (cross platform F# VS Code tools) working folder
+.ionide/
+
+# Fody - auto-generated XML schema
+FodyWeavers.xsd
+
+# VS Code files for those working on multiple tools
+.vscode/*
+!.vscode/settings.json
+!.vscode/tasks.json
+!.vscode/launch.json
+!.vscode/extensions.json
+*.code-workspace
+
+# Local History for Visual Studio Code
+.history/
+
+# Windows Installer files from build outputs
+*.cab
+*.msi
+*.msix
+*.msm
+*.msp
+
+# JetBrains Rider
+*.sln.iml
+
+### DotnetCore ###
+# .NET Core build folders
+bin/
+obj/
+
+# Common node modules locations
+/node_modules
+/wwwroot/node_modules
+
+### JetBrains+all ###
+# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio, WebStorm and Rider
+# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839
+
+# User-specific stuff
+.idea/**/workspace.xml
+.idea/**/tasks.xml
+.idea/**/usage.statistics.xml
+.idea/**/dictionaries
+.idea/**/shelf
+
+# AWS User-specific
+.idea/**/aws.xml
+
+# Generated files
+.idea/**/contentModel.xml
+
+# Sensitive or high-churn files
+.idea/**/dataSources/
+.idea/**/dataSources.ids
+.idea/**/dataSources.local.xml
+.idea/**/sqlDataSources.xml
+.idea/**/dynamic.xml
+.idea/**/uiDesigner.xml
+.idea/**/dbnavigator.xml
+
+# Gradle
+.idea/**/gradle.xml
+.idea/**/libraries
+
+# Gradle and Maven with auto-import
+# When using Gradle or Maven with auto-import, you should exclude module files,
+# since they will be recreated, and may cause churn. Uncomment if using
+# auto-import.
+# .idea/artifacts
+# .idea/compiler.xml
+# .idea/jarRepositories.xml
+# .idea/modules.xml
+# .idea/*.iml
+# .idea/modules
+# *.iml
+# *.ipr
+
+# CMake
+cmake-build-*/
+
+# Mongo Explorer plugin
+.idea/**/mongoSettings.xml
+
+# File-based project format
+*.iws
+
+# IntelliJ
+out/
+
+# mpeltonen/sbt-idea plugin
+.idea_modules/
+
+# JIRA plugin
+atlassian-ide-plugin.xml
+
+# Cursive Clojure plugin
+.idea/replstate.xml
+
+# SonarLint plugin
+.idea/sonarlint/
+
+# Crashlytics plugin (for Android Studio and IntelliJ)
+com_crashlytics_export_strings.xml
+crashlytics.properties
+crashlytics-build.properties
+fabric.properties
+
+# Editor-based Rest Client
+.idea/httpRequests
+
+# Android studio 3.1+ serialized cache file
+.idea/caches/build_file_checksums.ser
+
+### JetBrains+all Patch ###
+# Ignore everything but code style settings and run configurations
+# that are supposed to be shared within teams.
+
+.idea/*
+
+!.idea/codeStyles
+!.idea/runConfigurations
+
+### Linux ###
+
+# temporary files which can be created if a process still has a handle open of a deleted file
+.fuse_hidden*
+
+# KDE directory preferences
+.directory
+
+# Linux trash folder which might appear on any partition or disk
+.Trash-*
+
+# .nfs files are created when an open file is removed but is still being accessed
+.nfs*
+
+### macOS ###
+# General
+.DS_Store
+.AppleDouble
+.LSOverride
+
+# Icon must end with two \r
+Icon
+
+
+# Thumbnails
+._*
+
+# Files that might appear in the root of a volume
+.DocumentRevisions-V100
+.fseventsd
+.Spotlight-V100
+.TemporaryItems
+.Trashes
+.VolumeIcon.icns
+.com.apple.timemachine.donotpresent
+
+# Directories potentially created on remote AFP share
+.AppleDB
+.AppleDesktop
+Network Trash Folder
+Temporary Items
+.apdisk
+
+### macOS Patch ###
+# iCloud generated files
+*.icloud
+
+### Rider ###
+# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio, WebStorm and Rider
+# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839
+
+# User-specific stuff
+
+# AWS User-specific
+
+# Generated files
+
+# Sensitive or high-churn files
+
+# Gradle
+
+# Gradle and Maven with auto-import
+# When using Gradle or Maven with auto-import, you should exclude module files,
+# since they will be recreated, and may cause churn. Uncomment if using
+# auto-import.
+# .idea/artifacts
+# .idea/compiler.xml
+# .idea/jarRepositories.xml
+# .idea/modules.xml
+# .idea/*.iml
+# .idea/modules
+# *.iml
+# *.ipr
+
+# CMake
+
+# Mongo Explorer plugin
+
+# File-based project format
+
+# IntelliJ
+
+# mpeltonen/sbt-idea plugin
+
+# JIRA plugin
+
+# Cursive Clojure plugin
+
+# SonarLint plugin
+
+# Crashlytics plugin (for Android Studio and IntelliJ)
+
+# Editor-based Rest Client
+
+# Android studio 3.1+ serialized cache file
+
+### SonarQube ###
+# SonarQube ignore files.
+#
+# https://docs.sonarqube.org/display/SCAN/Analyzing+with+SonarQube+Scanner
+# Sonar Scanner working directories
+.sonar/
+.sonarqube/
+.scannerwork/
+
+# http://www.sonarlint.org/commandline/
+# SonarLint working directories, configuration files (including credentials)
+.sonarlint/
+
+### Windows ###
+# Windows thumbnail cache files
+Thumbs.db
+Thumbs.db:encryptable
+ehthumbs.db
+ehthumbs_vista.db
+
+# Dump file
+*.stackdump
+
+# Folder config file
+[Dd]esktop.ini
+
+# Recycle Bin used on file shares
+$RECYCLE.BIN/
+
+# Windows Installer files
+
+# Windows shortcuts
+*.lnk
+
+### VisualStudio ###
+
+# User-specific files
+
+# User-specific files (MonoDevelop/Xamarin Studio)
+
+# Mono auto generated files
+
+# Build results
+
+# Visual Studio 2015/2017 cache/options directory
+# Uncomment if you have tasks that create the project's static files in wwwroot
+
+# Visual Studio 2017 auto generated files
+
+# MSTest test Results
+
+# NUnit
+
+# Build Results of an ATL Project
+
+# Benchmark Results
+
+# .NET Core
+
+# ASP.NET Scaffolding
+
+# StyleCop
+
+# Files built by Visual Studio
+
+# Chutzpah Test files
+
+# Visual C++ cache files
+
+# Visual Studio profiler
+
+# Visual Studio Trace Files
+
+# TFS 2012 Local Workspace
+
+# Guidance Automation Toolkit
+
+# ReSharper is a .NET coding add-in
+
+# TeamCity is a build add-in
+
+# DotCover is a Code Coverage Tool
+
+# AxoCover is a Code Coverage Tool
+
+# Coverlet is a free, cross platform Code Coverage Tool
+
+# Visual Studio code coverage results
+
+# NCrunch
+
+# MightyMoose
+
+# Web workbench (sass)
+
+# Installshield output folder
+
+# DocProject is a documentation generator add-in
+
+# Click-Once directory
+
+# Publish Web Output
+# Note: Comment the next line if you want to checkin your web deploy settings,
+# but database connection strings (with potential passwords) will be unencrypted
+
+# Microsoft Azure Web App publish settings. Comment the next line if you want to
+# checkin your Azure Web App publish settings, but sensitive information contained
+# in these scripts will be unencrypted
+
+# NuGet Packages
+# NuGet Symbol Packages
+# The packages folder can be ignored because of Package Restore
+# except build/, which is used as an MSBuild target.
+# Uncomment if necessary however generally it will be regenerated when needed
+# NuGet v3's project.json files produces more ignorable files
+
+# Microsoft Azure Build Output
+
+# Microsoft Azure Emulator
+
+# Windows Store app package directories and files
+
+# Visual Studio cache files
+# files ending in .cache can be ignored
+# but keep track of directories ending in .cache
+
+# Others
+
+# Including strong name files can present a security risk
+# (https://github.com/github/gitignore/pull/2483#issue-259490424)
+
+# Since there are multiple workflows, uncomment next line to ignore bower_components
+# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
+
+# RIA/Silverlight projects
+
+# Backup & report files from converting an old project file
+# to a newer Visual Studio version. Backup files are not needed,
+# because we have git ;-)
+
+# SQL Server files
+
+# Business Intelligence projects
+
+# Microsoft Fakes
+
+# GhostDoc plugin setting file
+
+# Node.js Tools for Visual Studio
+
+# Visual Studio 6 build log
+
+# Visual Studio 6 workspace options file
+
+# Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
+
+# Visual Studio 6 auto-generated project file (contains which files were open etc.)
+
+# Visual Studio 6 workspace and project file (working project files containing files to include in project)
+
+# Visual Studio 6 technical files
+
+# Visual Studio LightSwitch build output
+
+# Paket dependency manager
+
+# FAKE - F# Make
+
+# CodeRush personal settings
+
+# Python Tools for Visual Studio (PTVS)
+
+# Cake - Uncomment if you are using it
+# tools/**
+# !tools/packages.config
+
+# Tabs Studio
+
+# Telerik's JustMock configuration file
+
+# BizTalk build output
+
+# OpenCover UI analysis results
+
+# Azure Stream Analytics local run output
+
+# MSBuild Binary and Structured Log
+
+# NVidia Nsight GPU debugger configuration file
+
+# MFractors (Xamarin productivity tool) working folder
+
+# Local History for Visual Studio
+
+# Visual Studio History (VSHistory) files
+
+# BeatPulse healthcheck temp database
+
+# Backup folder for Package Reference Convert tool in Visual Studio 2017
+
+# Ionide (cross platform F# VS Code tools) working folder
+
+# Fody - auto-generated XML schema
+
+# VS Code files for those working on multiple tools
+
+# Local History for Visual Studio Code
+
+# Windows Installer files from build outputs
+
+# JetBrains Rider
+
+### VisualStudio Patch ###
+# Additional files built by Visual Studio
+
+# End of https://www.toptal.com/developers/gitignore/api/dotnetcore,csharp,visualstudio,rider,jetbrains+all,windows,macos,linux,sonarqube
diff --git a/PyroFetes.sln b/PyroFetes.sln
new file mode 100644
index 0000000..2918820
--- /dev/null
+++ b/PyroFetes.sln
@@ -0,0 +1,16 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PyroFetes", "PyroFetes\PyroFetes.csproj", "{23E11090-EC39-414E-B2A7-FEF96FE729E3}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {23E11090-EC39-414E-B2A7-FEF96FE729E3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {23E11090-EC39-414E-B2A7-FEF96FE729E3}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {23E11090-EC39-414E-B2A7-FEF96FE729E3}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {23E11090-EC39-414E-B2A7-FEF96FE729E3}.Release|Any CPU.Build.0 = Release|Any CPU
+ EndGlobalSection
+EndGlobal
diff --git a/PyroFetes/.idea/.idea.PyroFetes/.idea/encodings.xml b/PyroFetes/.idea/.idea.PyroFetes/.idea/encodings.xml
new file mode 100644
index 0000000..df87cf9
--- /dev/null
+++ b/PyroFetes/.idea/.idea.PyroFetes/.idea/encodings.xml
@@ -0,0 +1,4 @@
+
+
+
+
\ No newline at end of file
diff --git a/PyroFetes/.idea/.idea.PyroFetes/.idea/indexLayout.xml b/PyroFetes/.idea/.idea.PyroFetes/.idea/indexLayout.xml
new file mode 100644
index 0000000..7b08163
--- /dev/null
+++ b/PyroFetes/.idea/.idea.PyroFetes/.idea/indexLayout.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/PyroFetes/.idea/.idea.PyroFetes/.idea/projectSettingsUpdater.xml b/PyroFetes/.idea/.idea.PyroFetes/.idea/projectSettingsUpdater.xml
new file mode 100644
index 0000000..ef20cb0
--- /dev/null
+++ b/PyroFetes/.idea/.idea.PyroFetes/.idea/projectSettingsUpdater.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/PyroFetes/.idea/.idea.PyroFetes/.idea/workspace.xml b/PyroFetes/.idea/.idea.PyroFetes/.idea/workspace.xml
new file mode 100644
index 0000000..1885d46
--- /dev/null
+++ b/PyroFetes/.idea/.idea.PyroFetes/.idea/workspace.xml
@@ -0,0 +1,66 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 1760014067675
+
+
+ 1760014067675
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/PyroFetes/DTO/Availability/Request/CreateAvailabilityDto.cs b/PyroFetes/DTO/Availability/Request/CreateAvailabilityDto.cs
new file mode 100644
index 0000000..f5c053c
--- /dev/null
+++ b/PyroFetes/DTO/Availability/Request/CreateAvailabilityDto.cs
@@ -0,0 +1,9 @@
+namespace PyroFetes.DTO.Availability.Request;
+
+public class CreateAvailabilityDto
+{
+ public DateOnly AvailabilityDate { get; set; }
+ public DateOnly DeliveryDate { get; set; }
+ public DateOnly ExpirationDate { get; set; }
+ public DateOnly RenewalDate { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/Availability/Request/GetAvailabilityRequest.cs b/PyroFetes/DTO/Availability/Request/GetAvailabilityRequest.cs
new file mode 100644
index 0000000..9b82857
--- /dev/null
+++ b/PyroFetes/DTO/Availability/Request/GetAvailabilityRequest.cs
@@ -0,0 +1,6 @@
+namespace PyroFetes.DTO.Availability.Request;
+
+public class GetAvailabilityRequest
+{
+ public int Id { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/Availability/Request/UpdateAvailabilityDto.cs b/PyroFetes/DTO/Availability/Request/UpdateAvailabilityDto.cs
new file mode 100644
index 0000000..3b6ab9e
--- /dev/null
+++ b/PyroFetes/DTO/Availability/Request/UpdateAvailabilityDto.cs
@@ -0,0 +1,10 @@
+namespace PyroFetes.DTO.Availability.Request;
+
+public class UpdateAvailabilityDto
+{
+ public int Id { get; set; }
+ public DateOnly AvailabilityDate { get; set; }
+ public DateOnly DeliveryDate { get; set; }
+ public DateOnly ExpirationDate { get; set; }
+ public DateOnly RenewalDate { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/Availability/Response/GetAvailabilityDto.cs b/PyroFetes/DTO/Availability/Response/GetAvailabilityDto.cs
new file mode 100644
index 0000000..ed40c91
--- /dev/null
+++ b/PyroFetes/DTO/Availability/Response/GetAvailabilityDto.cs
@@ -0,0 +1,10 @@
+namespace PyroFetes.DTO.Availability.Response;
+
+public class GetAvailabilityDto
+{
+ public int Id { get; set; }
+ public DateOnly AvailabilityDate { get; set; }
+ public DateOnly DeliveryDate { get; set; }
+ public DateOnly ExpirationDate { get; set; }
+ public DateOnly RenewalDate { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/Communication/Request/CreateCommunicationDto.cs b/PyroFetes/DTO/Communication/Request/CreateCommunicationDto.cs
new file mode 100644
index 0000000..cb8bbc2
--- /dev/null
+++ b/PyroFetes/DTO/Communication/Request/CreateCommunicationDto.cs
@@ -0,0 +1,6 @@
+namespace PyroFetes.DTO.Communication.Request;
+
+public class CreateCommunicationDto
+{
+
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/Communication/Request/GetCommunicationRequest.cs b/PyroFetes/DTO/Communication/Request/GetCommunicationRequest.cs
new file mode 100644
index 0000000..185f4d1
--- /dev/null
+++ b/PyroFetes/DTO/Communication/Request/GetCommunicationRequest.cs
@@ -0,0 +1,6 @@
+namespace PyroFetes.DTO.Communication.Request;
+
+public class GetCommunicationRequest
+{
+
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/Communication/Request/UpdateCommunicationDto.cs b/PyroFetes/DTO/Communication/Request/UpdateCommunicationDto.cs
new file mode 100644
index 0000000..8cb9fcf
--- /dev/null
+++ b/PyroFetes/DTO/Communication/Request/UpdateCommunicationDto.cs
@@ -0,0 +1,6 @@
+namespace PyroFetes.DTO.Communication.Request;
+
+public class UpdateCommunicationDto
+{
+
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/Communication/Response/GetCommunicationDto.cs b/PyroFetes/DTO/Communication/Response/GetCommunicationDto.cs
new file mode 100644
index 0000000..de0f97d
--- /dev/null
+++ b/PyroFetes/DTO/Communication/Response/GetCommunicationDto.cs
@@ -0,0 +1,8 @@
+namespace PyroFetes.DTO.Communication.Response;
+
+public class GetCommunicationRequest
+{
+ public string? Calling { get; set; }
+ public string? Email { get; set; }
+ public string? Meeting { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/Contact/Request/CreateContactDto.cs b/PyroFetes/DTO/Contact/Request/CreateContactDto.cs
new file mode 100644
index 0000000..f52343d
--- /dev/null
+++ b/PyroFetes/DTO/Contact/Request/CreateContactDto.cs
@@ -0,0 +1,11 @@
+namespace PyroFetes.DTO.Contact.Request;
+
+public class CreateContactDto
+{
+ public string? LastName { get; set; }
+ public string? FirstName { get; set; }
+ public string? PhoneNumber { get; set; }
+ public string? Email { get; set; }
+ public string? Address { get; set; }
+ public string? Role { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/Contact/Request/GetContactRequest.cs b/PyroFetes/DTO/Contact/Request/GetContactRequest.cs
new file mode 100644
index 0000000..d62aa5a
--- /dev/null
+++ b/PyroFetes/DTO/Contact/Request/GetContactRequest.cs
@@ -0,0 +1,6 @@
+namespace PyroFetes.DTO.Contact.Request;
+
+public class GetContactRequest
+{
+ public int Id { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/Contact/Request/UpdateContactDto.cs b/PyroFetes/DTO/Contact/Request/UpdateContactDto.cs
new file mode 100644
index 0000000..42ffd3d
--- /dev/null
+++ b/PyroFetes/DTO/Contact/Request/UpdateContactDto.cs
@@ -0,0 +1,12 @@
+namespace PyroFetes.DTO.Contact.Request;
+
+public class UpdateContactDto
+{
+ public int Id { get; set; }
+ public string? LastName { get; set; }
+ public string? FirstName { get; set; }
+ public string? PhoneNumber { get; set; }
+ public string? Email { get; set; }
+ public string? Address { get; set; }
+ public string? Role { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/Contact/Response/GetContactDto.cs b/PyroFetes/DTO/Contact/Response/GetContactDto.cs
new file mode 100644
index 0000000..38a25d8
--- /dev/null
+++ b/PyroFetes/DTO/Contact/Response/GetContactDto.cs
@@ -0,0 +1,12 @@
+namespace PyroFetes.DTO.Contact.Response;
+
+public class GetContactDto
+{
+ public int Id { get; set; }
+ public string? LastName { get; set; }
+ public string? FirstName { get; set; }
+ public string? PhoneNumber { get; set; }
+ public string? Email { get; set; }
+ public string? Address { get; set; }
+ public string? Role { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/ExperienceLevel/Request/CreateExperienceLevelDto.cs b/PyroFetes/DTO/ExperienceLevel/Request/CreateExperienceLevelDto.cs
new file mode 100644
index 0000000..9e40ea6
--- /dev/null
+++ b/PyroFetes/DTO/ExperienceLevel/Request/CreateExperienceLevelDto.cs
@@ -0,0 +1,6 @@
+namespace PyroFetes.DTO.ExperienceLevel.Request;
+
+public class CreateExperienceLevelDto
+{
+ public string? Label { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/ExperienceLevel/Request/GetExperienceLevelRequest.cs b/PyroFetes/DTO/ExperienceLevel/Request/GetExperienceLevelRequest.cs
new file mode 100644
index 0000000..a9991e5
--- /dev/null
+++ b/PyroFetes/DTO/ExperienceLevel/Request/GetExperienceLevelRequest.cs
@@ -0,0 +1,6 @@
+namespace PyroFetes.DTO.ExperienceLevel.Request;
+
+public class GetExperienceLevelRequest
+{
+ public int Id { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/ExperienceLevel/Request/UpdateExperienceLevelDto.cs b/PyroFetes/DTO/ExperienceLevel/Request/UpdateExperienceLevelDto.cs
new file mode 100644
index 0000000..e0e69bd
--- /dev/null
+++ b/PyroFetes/DTO/ExperienceLevel/Request/UpdateExperienceLevelDto.cs
@@ -0,0 +1,7 @@
+namespace PyroFetes.DTO.ExperienceLevel.Request;
+
+public class UpdateExperienceLevelDto
+{
+ public int Id { get; set; }
+ public string? Label { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/ExperienceLevel/Response/GetExperienceLevelDto.cs b/PyroFetes/DTO/ExperienceLevel/Response/GetExperienceLevelDto.cs
new file mode 100644
index 0000000..8a14d3d
--- /dev/null
+++ b/PyroFetes/DTO/ExperienceLevel/Response/GetExperienceLevelDto.cs
@@ -0,0 +1,7 @@
+namespace PyroFetes.DTO.ExperienceLevel.Response;
+
+public class GetExperienceLevelDto
+{
+ public int Id { get; set; }
+ public string? Label { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/HistoryOfApproval/Request/CreateHistoryOfApprovalDto.cs b/PyroFetes/DTO/HistoryOfApproval/Request/CreateHistoryOfApprovalDto.cs
new file mode 100644
index 0000000..ba5a33e
--- /dev/null
+++ b/PyroFetes/DTO/HistoryOfApproval/Request/CreateHistoryOfApprovalDto.cs
@@ -0,0 +1,7 @@
+namespace PyroFetes.DTO.HistoryOfApproval.Request;
+
+public class CreateHistoryOfApprovalDto
+{
+ public DateOnly DeliveryDate { get; set; }
+ public DateOnly ExpirationDate { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/HistoryOfApproval/Request/GetHistoryOfApprovalRequest.cs b/PyroFetes/DTO/HistoryOfApproval/Request/GetHistoryOfApprovalRequest.cs
new file mode 100644
index 0000000..b2e692f
--- /dev/null
+++ b/PyroFetes/DTO/HistoryOfApproval/Request/GetHistoryOfApprovalRequest.cs
@@ -0,0 +1,6 @@
+namespace PyroFetes.DTO.HistoryOfApproval.Request;
+
+public class GetHistoryOfApprovalRequest
+{
+ public int Id { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/HistoryOfApproval/Request/UpdateHistoryOfApprovalDto.cs b/PyroFetes/DTO/HistoryOfApproval/Request/UpdateHistoryOfApprovalDto.cs
new file mode 100644
index 0000000..cf8a30e
--- /dev/null
+++ b/PyroFetes/DTO/HistoryOfApproval/Request/UpdateHistoryOfApprovalDto.cs
@@ -0,0 +1,8 @@
+namespace PyroFetes.DTO.HistoryOfApproval.Request;
+
+public class UpdateHistoryOfApprovalDto
+{
+ public int Id { get; set; }
+ public DateOnly DeliveryDate { get; set; }
+ public DateOnly ExpirationDate { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/HistoryOfApproval/Response/GetHistoryOfApprovalDto.cs b/PyroFetes/DTO/HistoryOfApproval/Response/GetHistoryOfApprovalDto.cs
new file mode 100644
index 0000000..b216521
--- /dev/null
+++ b/PyroFetes/DTO/HistoryOfApproval/Response/GetHistoryOfApprovalDto.cs
@@ -0,0 +1,8 @@
+namespace PyroFetes.DTO.HistoryOfApproval.Response;
+
+public class GetHistoryOfApprovalDto
+{
+ public int Id { get; set; }
+ public DateOnly DeliveryDate { get; set; }
+ public DateOnly ExpirationDate { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/Staff/Request/CreateStaffDto.cs b/PyroFetes/DTO/Staff/Request/CreateStaffDto.cs
new file mode 100644
index 0000000..8fdbdf5
--- /dev/null
+++ b/PyroFetes/DTO/Staff/Request/CreateStaffDto.cs
@@ -0,0 +1,7 @@
+namespace PyroFetes.DTO.Staff.Request;
+
+public class CreateStaffDto
+{
+ public string? F4T2NumberApproval { get; set; }
+ public string? F4T2ExpirationDate { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/Staff/Request/GetStaffRequest.cs b/PyroFetes/DTO/Staff/Request/GetStaffRequest.cs
new file mode 100644
index 0000000..b8b1799
--- /dev/null
+++ b/PyroFetes/DTO/Staff/Request/GetStaffRequest.cs
@@ -0,0 +1,6 @@
+namespace PyroFetes.DTO.Staff.Request;
+
+public class GetStaffRequest
+{
+ public string? Label { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/Staff/Request/UpdateStaffDto.cs b/PyroFetes/DTO/Staff/Request/UpdateStaffDto.cs
new file mode 100644
index 0000000..82d0685
--- /dev/null
+++ b/PyroFetes/DTO/Staff/Request/UpdateStaffDto.cs
@@ -0,0 +1,8 @@
+namespace PyroFetes.DTO.Staff.Request;
+
+public class UpdateStaffDto
+{
+ public int Id { get; set; }
+ public string? F4T2NumberApproval { get; set; }
+ public string? F4T2ExpirationDate { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/DTO/Staff/Response/GetStaffDto.cs b/PyroFetes/DTO/Staff/Response/GetStaffDto.cs
new file mode 100644
index 0000000..0e64206
--- /dev/null
+++ b/PyroFetes/DTO/Staff/Response/GetStaffDto.cs
@@ -0,0 +1,6 @@
+namespace PyroFetes.DTO.Staff.Response;
+
+public class GetStaffDto
+{
+ public int Id { get; set; }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/Availability/CreateAvailabilityEndpoint.cs b/PyroFetes/Endpoints/Availability/CreateAvailabilityEndpoint.cs
new file mode 100644
index 0000000..73a41b8
--- /dev/null
+++ b/PyroFetes/Endpoints/Availability/CreateAvailabilityEndpoint.cs
@@ -0,0 +1,38 @@
+using FastEndpoints;
+using PyroFetes.DTO.Availability.Request;
+using PyroFetes.DTO.Availability.Response;
+
+namespace PyroFetes.Endpoints.Availability;
+
+public class CreateAvailabilityEndpoint(PyroFetesDbContext pyroFetesDbContext) : Endpoint
+{
+ public override void Configure()
+ {
+ Post("/api/availabilities");
+ AllowAnonymous();
+ }
+
+
+ public override async Task HandleAsync(CreateAvailabilityDto req, CancellationToken ct)
+ {
+ Models.Availability availability = new()
+ {
+ AvailabilityDate = req.AvailabilityDate,
+ DeliveryDate = req.DeliveryDate,
+ ExpirationDate = req.ExpirationDate,
+ RenewallDate = req.RenewalDate,
+ };
+ pyroFetesDbContext.Add(availability);
+ await pyroFetesDbContext.SaveChangesAsync(ct);
+
+ GetAvailabilityDto response = new()
+ {
+ AvailabilityDate = availability.AvailabilityDate,
+ DeliveryDate = availability.DeliveryDate,
+ ExpirationDate = availability.ExpirationDate,
+ RenewalDate = availability.RenewallDate
+ };
+
+ await Send.OkAsync(response, ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/Availability/DeleteAvailabilityEndpoint.cs b/PyroFetes/Endpoints/Availability/DeleteAvailabilityEndpoint.cs
new file mode 100644
index 0000000..17ce63b
--- /dev/null
+++ b/PyroFetes/Endpoints/Availability/DeleteAvailabilityEndpoint.cs
@@ -0,0 +1,30 @@
+using FastEndpoints;
+using Microsoft.EntityFrameworkCore;
+using PyroFetes.DTO.Availability.Request;
+using PyroFetes.DTO.Availability.Response;
+
+namespace PyroFetes.Endpoints.Availability;
+
+public class DeleteAvailabilityEndpoint(PyroFetesDbContext pyroFetesDbContext) : Endpoint
+{
+ public override void Configure()
+ {
+ Delete ("/api/availabilities/{@Id}", x => new { x.Id });
+ AllowAnonymous();
+ }
+
+ public override async Task HandleAsync(GetAvailabilityRequest req, CancellationToken ct)
+ {
+ Models.Availability? databaseAvailability = await pyroFetesDbContext.Availabilities.SingleOrDefaultAsync(x => x.Id == req.Id, cancellationToken: ct);
+
+ if (databaseAvailability == null)
+ {
+ await Send.NotFoundAsync(ct);
+ return;
+ }
+ pyroFetesDbContext.Availabilities.Remove(databaseAvailability);
+ await pyroFetesDbContext.SaveChangesAsync(ct);
+
+ await Send.NoContentAsync(ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/Availability/GetAllAvailabilitiesEndpoint.cs b/PyroFetes/Endpoints/Availability/GetAllAvailabilitiesEndpoint.cs
new file mode 100644
index 0000000..ce2a7eb
--- /dev/null
+++ b/PyroFetes/Endpoints/Availability/GetAllAvailabilitiesEndpoint.cs
@@ -0,0 +1,28 @@
+using FastEndpoints;
+using Microsoft.EntityFrameworkCore;
+using PyroFetes.DTO.Availability.Response;
+
+namespace PyroFetes.Endpoints.Availability;
+
+public class GetAllAvailabilityxuest(PyroFetesDbContext pyroFetesDbContext) : EndpointWithoutRequest>
+{
+ public override void Configure()
+ {
+ Get ("/api/availabilities");
+ AllowAnonymous();
+ }
+
+ public override async Task HandleAsync(CancellationToken ct)
+ {
+ List availabilities = await pyroFetesDbContext.Availabilities.Select(x => new GetAvailabilityDto()
+ {
+ Id = x.Id,
+ AvailabilityDate = x.AvailabilityDate,
+ DeliveryDate = x.DeliveryDate,
+ ExpirationDate = x.ExpirationDate,
+ RenewalDate = x.RenewallDate
+ }).ToListAsync(ct);
+
+ await Send.OkAsync(availabilities, ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/Availability/GetAvailabilityEndpoint.cs b/PyroFetes/Endpoints/Availability/GetAvailabilityEndpoint.cs
new file mode 100644
index 0000000..d0bf0b0
--- /dev/null
+++ b/PyroFetes/Endpoints/Availability/GetAvailabilityEndpoint.cs
@@ -0,0 +1,37 @@
+using FastEndpoints;
+using Microsoft.EntityFrameworkCore;
+using PyroFetes.DTO.Availability.Request;
+using PyroFetes.DTO.Availability.Response;
+
+namespace PyroFetes.Endpoints.Availability;
+
+public class GetAvailabilityEndpoint(PyroFetesDbContext pyroFetesDbContext) : Endpoint
+{
+ public override void Configure()
+ {
+ Get ("/api/availabilities/{@Id}", x => new { x.Id });
+ AllowAnonymous();
+ }
+
+ public override async Task HandleAsync(GetAvailabilityRequest database, CancellationToken ct)
+ {
+ Models.Availability? databaseAvailability = await pyroFetesDbContext.Availabilities.SingleOrDefaultAsync(x => x.Id == database.Id, cancellationToken: ct);
+
+ if (databaseAvailability == null)
+ {
+ await Send.NotFoundAsync(ct);
+ return;
+ }
+
+ GetAvailabilityDto dto = new()
+ {
+ Id = databaseAvailability.Id,
+ AvailabilityDate = databaseAvailability.AvailabilityDate,
+ DeliveryDate = databaseAvailability.DeliveryDate,
+ ExpirationDate = databaseAvailability.ExpirationDate,
+ RenewalDate = databaseAvailability.RenewallDate
+ };
+
+ await Send.OkAsync(dto, ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/Availability/UpdateAvailabilityEndpoint.cs b/PyroFetes/Endpoints/Availability/UpdateAvailabilityEndpoint.cs
new file mode 100644
index 0000000..7386014
--- /dev/null
+++ b/PyroFetes/Endpoints/Availability/UpdateAvailabilityEndpoint.cs
@@ -0,0 +1,45 @@
+using FastEndpoints;
+using Microsoft.EntityFrameworkCore;
+using PyroFetes.DTO.Availability.Request;
+using PyroFetes.DTO.Availability.Response;
+
+namespace PyroFetes.Endpoints.Availability;
+
+public class UpdateAvailabilityEndpoint(PyroFetesDbContext pyroFetesDbContext) : Endpoint
+{
+ public override void Configure()
+ {
+ Put ("/api/availabilities/{@Id}", x => new { x.Id });
+ AllowAnonymous();
+ }
+
+ public override async Task HandleAsync(UpdateAvailabilityDto req, CancellationToken ct)
+ {
+ Models.Availability? databaseAvailability = await pyroFetesDbContext.Availabilities.SingleOrDefaultAsync(x => x.Id == req.Id, cancellationToken: ct);
+
+ if (databaseAvailability == null)
+ {
+ await Send.NotFoundAsync(ct);
+ return;
+ }
+ else
+ {
+ databaseAvailability.AvailabilityDate = req.AvailabilityDate;
+ databaseAvailability.DeliveryDate = req.DeliveryDate;
+ databaseAvailability.ExpirationDate = req.ExpirationDate;
+ databaseAvailability.RenewallDate = req.RenewalDate;
+ }
+ await pyroFetesDbContext.SaveChangesAsync(ct);
+
+ GetAvailabilityDto dto = new()
+ {
+ Id = databaseAvailability.Id,
+ AvailabilityDate = req.AvailabilityDate,
+ DeliveryDate = req.DeliveryDate,
+ ExpirationDate = req.ExpirationDate,
+ RenewalDate = req.RenewalDate,
+ };
+
+ await Send.OkAsync(dto, ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/Contact/CreateContactEndpoint.cs b/PyroFetes/Endpoints/Contact/CreateContactEndpoint.cs
new file mode 100644
index 0000000..e0a65fc
--- /dev/null
+++ b/PyroFetes/Endpoints/Contact/CreateContactEndpoint.cs
@@ -0,0 +1,42 @@
+using FastEndpoints;
+using PyroFetes.DTO.Contact.Request;
+using PyroFetes.DTO.Contact.Response;
+
+namespace PyroFetes.Endpoints.Contact;
+
+public class CreateContactEndpoint(PyroFetesDbContext pyroFetesDbContext) : Endpoint
+{
+ public override void Configure()
+ {
+ Post("/api/contacts");
+ AllowAnonymous();
+ }
+
+
+ public override async Task HandleAsync(CreateContactDto req, CancellationToken ct)
+ {
+ Models.Contact contact = new()
+ {
+ LastName = req.LastName,
+ FirstName = req.FirstName,
+ PhoneNumber = req.PhoneNumber,
+ Email = req.Email,
+ Address = req.Address,
+ Role = req.Role,
+ };
+ pyroFetesDbContext.Add(contact);
+ await pyroFetesDbContext.SaveChangesAsync(ct);
+
+ GetContactDto response = new()
+ {
+ LastName = contact.LastName,
+ FirstName = contact.FirstName,
+ PhoneNumber = contact.PhoneNumber,
+ Email = contact.Email,
+ Address = contact.Address,
+ Role = contact.Role,
+ };
+
+ await Send.OkAsync(response, ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/Contact/DeleteContactEndpoint.cs b/PyroFetes/Endpoints/Contact/DeleteContactEndpoint.cs
new file mode 100644
index 0000000..51a965c
--- /dev/null
+++ b/PyroFetes/Endpoints/Contact/DeleteContactEndpoint.cs
@@ -0,0 +1,30 @@
+using FastEndpoints;
+using Microsoft.EntityFrameworkCore;
+using PyroFetes.DTO.Contact.Request;
+using PyroFetes.DTO.Contact.Response;
+
+namespace PyroFetes.Endpoints.Contact;
+
+public class DeleteContactEndpoint(PyroFetesDbContext pyroFetesDbContext) : Endpoint
+{
+ public override void Configure()
+ {
+ Delete ("/api/Contacts/{@Id}", x => new { x.Id });
+ AllowAnonymous();
+ }
+
+ public override async Task HandleAsync(GetContactRequest req, CancellationToken ct)
+ {
+ Models.Contact? databaseContact = await pyroFetesDbContext.Contacts.SingleOrDefaultAsync(x => x.Id == req.Id, cancellationToken: ct);
+
+ if (databaseContact == null)
+ {
+ await Send.NotFoundAsync(ct);
+ return;
+ }
+ pyroFetesDbContext.Contacts.Remove(databaseContact);
+ await pyroFetesDbContext.SaveChangesAsync(ct);
+
+ await Send.NoContentAsync(ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/Contact/GetAllContactsEndpoint.cs b/PyroFetes/Endpoints/Contact/GetAllContactsEndpoint.cs
new file mode 100644
index 0000000..e7339d9
--- /dev/null
+++ b/PyroFetes/Endpoints/Contact/GetAllContactsEndpoint.cs
@@ -0,0 +1,30 @@
+using FastEndpoints;
+using Microsoft.EntityFrameworkCore;
+using PyroFetes.DTO.Contact.Response;
+
+namespace PyroFetes.Endpoints.Contact;
+
+public class GetAllContactxuest(PyroFetesDbContext pyroFetesDbContext) : EndpointWithoutRequest>
+{
+ public override void Configure()
+ {
+ Get ("/api/contacts");
+ AllowAnonymous();
+ }
+
+ public override async Task HandleAsync(CancellationToken ct)
+ {
+ List contacts = await pyroFetesDbContext.Contacts.Select(x => new GetContactDto()
+ {
+ Id = x.Id,
+ LastName = x.LastName,
+ FirstName = x.FirstName,
+ PhoneNumber = x.PhoneNumber,
+ Email = x.Email,
+ Address = x.Address,
+ Role = x.Role,
+ }).ToListAsync(ct);
+
+ await Send.OkAsync(contacts, ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/Contact/GetContactEndpoint.cs b/PyroFetes/Endpoints/Contact/GetContactEndpoint.cs
new file mode 100644
index 0000000..04a4e5e
--- /dev/null
+++ b/PyroFetes/Endpoints/Contact/GetContactEndpoint.cs
@@ -0,0 +1,39 @@
+using FastEndpoints;
+using Microsoft.EntityFrameworkCore;
+using PyroFetes.DTO.Contact.Request;
+using PyroFetes.DTO.Contact.Response;
+
+namespace PyroFetes.Endpoints.Contact;
+
+public class GetContactEndpoint(PyroFetesDbContext pyroFetesDbContext) : Endpoint
+{
+ public override void Configure()
+ {
+ Get ("/api/contacts/{@Id}", x => new { x.Id });
+ AllowAnonymous();
+ }
+
+ public override async Task HandleAsync(GetContactRequest database, CancellationToken ct)
+ {
+ Models.Contact? databaseContact = await pyroFetesDbContext.Contacts.SingleOrDefaultAsync(x => x.Id == database.Id, cancellationToken: ct);
+
+ if (databaseContact == null)
+ {
+ await Send.NotFoundAsync(ct);
+ return;
+ }
+
+ GetContactDto dto = new()
+ {
+ Id = databaseContact.Id,
+ LastName = databaseContact.LastName,
+ FirstName = databaseContact.FirstName,
+ PhoneNumber = databaseContact.PhoneNumber,
+ Email = databaseContact.Email,
+ Address = databaseContact.Address,
+ Role = databaseContact.Role,
+ };
+
+ await Send.OkAsync(dto, ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/Contact/UpdateContactRequest.cs b/PyroFetes/Endpoints/Contact/UpdateContactRequest.cs
new file mode 100644
index 0000000..8fec9d1
--- /dev/null
+++ b/PyroFetes/Endpoints/Contact/UpdateContactRequest.cs
@@ -0,0 +1,49 @@
+using FastEndpoints;
+using Microsoft.EntityFrameworkCore;
+using PyroFetes.DTO.Contact.Request;
+using PyroFetes.DTO.Contact.Response;
+
+namespace PyroFetes.Endpoints.Contact;
+
+public class UpdateContactRequest(PyroFetesDbContext pyroFetesDbContext) : Endpoint
+{
+ public override void Configure()
+ {
+ Put ("/api/contacts/{@Id}", x => new { x.Id });
+ AllowAnonymous();
+ }
+
+ public override async Task HandleAsync(UpdateContactDto req, CancellationToken ct)
+ {
+ Models.Contact? databaseContact = await pyroFetesDbContext.Contacts.SingleOrDefaultAsync(x => x.Id == req.Id, cancellationToken: ct);
+
+ if (databaseContact == null)
+ {
+ await Send.NotFoundAsync(ct);
+ return;
+ }
+ else
+ {
+ databaseContact.LastName = req.LastName;
+ databaseContact.FirstName = req.FirstName;
+ databaseContact.PhoneNumber = req.PhoneNumber;
+ databaseContact.Email = req.Email;
+ databaseContact.Address = req.Address;
+ databaseContact.Role = req.Role;
+ }
+ await pyroFetesDbContext.SaveChangesAsync(ct);
+
+ GetContactDto dto = new()
+ {
+ Id = databaseContact.Id,
+ LastName = req.LastName,
+ FirstName = req.FirstName,
+ PhoneNumber = req.PhoneNumber,
+ Email = req.Email,
+ Address = req.Address,
+ Role = req.Role,
+ };
+
+ await Send.OkAsync(dto, ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/ExperienceLevel/CreateExperienceLevelEndpoint.cs b/PyroFetes/Endpoints/ExperienceLevel/CreateExperienceLevelEndpoint.cs
new file mode 100644
index 0000000..ef4ccc6
--- /dev/null
+++ b/PyroFetes/Endpoints/ExperienceLevel/CreateExperienceLevelEndpoint.cs
@@ -0,0 +1,34 @@
+
+using FastEndpoints;
+using PyroFetes.DTO.ExperienceLevel.Response;
+using PyroFetes.DTO.ExperienceLevel.Request;
+
+namespace PyroFetes.Endpoints.ExperienceLevel;
+
+public class CreateExperienceLevelEndpoint(PyroFetesDbContext pyroFetesDbContext) : Endpoint
+{
+ public override void Configure()
+ {
+ Post("/api/ExperienceLevels");
+ AllowAnonymous();
+ }
+
+ public override async Task HandleAsync(CreateExperienceLevelDto req, CancellationToken ct)
+ {
+ Models.ExperienceLevel experienceLevel = new()
+ {
+ Label = req.Label
+ };
+ pyroFetesDbContext.Add(experienceLevel);
+ await pyroFetesDbContext.SaveChangesAsync(ct);
+
+ GetExperienceLevelDto response = new()
+ {
+ Id = experienceLevel.Id,
+ Label = experienceLevel.Label,
+ };
+
+ await Send.OkAsync(response, ct);
+
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/ExperienceLevel/DeleteExerienceLevelEndpoint.cs b/PyroFetes/Endpoints/ExperienceLevel/DeleteExerienceLevelEndpoint.cs
new file mode 100644
index 0000000..5b5792d
--- /dev/null
+++ b/PyroFetes/Endpoints/ExperienceLevel/DeleteExerienceLevelEndpoint.cs
@@ -0,0 +1,30 @@
+using Microsoft.EntityFrameworkCore;
+using PyroFetes.DTO.ExperienceLevel.Request;
+using PyroFetes.DTO.ExperienceLevel.Response;
+using FastEndpoints;
+
+namespace PyroFetes.Endpoints.ExperienceLevel;
+
+public class DeleteExerienceLevelEndpoint(PyroFetesDbContext pyroFetesDbContext) : Endpoint
+{
+ public override void Configure()
+ {
+ Delete ("/api/ExperienceLevels/{@Id}", x => new { x.Id });
+ AllowAnonymous();
+ }
+
+ public override async Task HandleAsync(GetExperienceLevelRequest req, CancellationToken ct)
+ {
+ Models.ExperienceLevel? databaseExperienceLevel = await pyroFetesDbContext.ExperienceLevels.SingleOrDefaultAsync(x => x.Id == req.Id, cancellationToken: ct);
+
+ if (databaseExperienceLevel == null)
+ {
+ await Send.NotFoundAsync(ct);
+ return;
+ }
+ pyroFetesDbContext.ExperienceLevels.Remove(databaseExperienceLevel);
+ await pyroFetesDbContext.SaveChangesAsync(ct);
+
+ await Send.NoContentAsync(ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/ExperienceLevel/GetAllExperienceLevelsEndpoint.cs b/PyroFetes/Endpoints/ExperienceLevel/GetAllExperienceLevelsEndpoint.cs
new file mode 100644
index 0000000..449cfca
--- /dev/null
+++ b/PyroFetes/Endpoints/ExperienceLevel/GetAllExperienceLevelsEndpoint.cs
@@ -0,0 +1,24 @@
+using Microsoft.EntityFrameworkCore;
+using PyroFetes.DTO.ExperienceLevel.Response;
+
+namespace PyroFetes.Endpoints.ExperienceLevel;
+using FastEndpoints;
+
+public class GetAllExperienceLevelsEndpoint(PyroFetesDbContext pyroFetesDbContext) : EndpointWithoutRequest>
+{
+ public override void Configure()
+ {
+ Get ("/api/experienceLevels");
+ AllowAnonymous();
+ }
+
+ public override async Task HandleAsync(CancellationToken ct)
+ {
+ List experienceLevels= await pyroFetesDbContext.ExperienceLevels.Select(x => new GetExperienceLevelDto()
+ {
+ Id = x.Id,
+ }).ToListAsync(ct);
+
+ await Send.OkAsync(experienceLevels, ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/ExperienceLevel/GetExperienceLevelEndpoint.cs b/PyroFetes/Endpoints/ExperienceLevel/GetExperienceLevelEndpoint.cs
new file mode 100644
index 0000000..2123855
--- /dev/null
+++ b/PyroFetes/Endpoints/ExperienceLevel/GetExperienceLevelEndpoint.cs
@@ -0,0 +1,6 @@
+namespace PyroFetes.Endpoints.ExperienceLevel;
+
+public class GetExperienceLevelEndpoint
+{
+
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/ExperienceLevel/UpdateExperienceLevelEndpoint.cs b/PyroFetes/Endpoints/ExperienceLevel/UpdateExperienceLevelEndpoint.cs
new file mode 100644
index 0000000..d2aa8a2
--- /dev/null
+++ b/PyroFetes/Endpoints/ExperienceLevel/UpdateExperienceLevelEndpoint.cs
@@ -0,0 +1,6 @@
+namespace PyroFetes.Endpoints.ExperienceLevel;
+
+public class UpdateExperienceLevelEndpoint
+{
+
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/HistoryOfApproval/CreateHistoryOfApprovalEndpoint.cs b/PyroFetes/Endpoints/HistoryOfApproval/CreateHistoryOfApprovalEndpoint.cs
new file mode 100644
index 0000000..d5251ae
--- /dev/null
+++ b/PyroFetes/Endpoints/HistoryOfApproval/CreateHistoryOfApprovalEndpoint.cs
@@ -0,0 +1,36 @@
+using FastEndpoints;
+using PyroFetes.DTO.HistoryOfApproval.Request;
+using PyroFetes.DTO.HistoryOfApproval.Response;
+
+namespace PyroFetes.Endpoints.HistoryOfApproval;
+
+public class CreateHistoryOfApprovalEndpoint(PyroFetesDbContext pyroFetesDbContext) : Endpoint
+{
+ public override void Configure()
+ {
+ Post("/api/HistoryOfApprovals");
+ AllowAnonymous();
+ }
+
+
+ public override async Task HandleAsync(CreateHistoryOfApprovalDto req, CancellationToken ct)
+ {
+ Models.HistoryOfApproval historyOfApproval = new()
+ {
+ DeliveryDate = req.DeliveryDate,
+ ExpirationDate = req.ExpirationDate
+ };
+ pyroFetesDbContext.Add(historyOfApproval);
+ await pyroFetesDbContext.SaveChangesAsync(ct);
+
+ GetHistoryOfApprovalDto response = new()
+ {
+ Id = historyOfApproval.Id,
+ DeliveryDate = historyOfApproval.DeliveryDate,
+ ExpirationDate = historyOfApproval.ExpirationDate
+ };
+
+ await Send.OkAsync(response, ct);
+
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/HistoryOfApproval/DeleteHistoryOfApprovalEndpoint.cs b/PyroFetes/Endpoints/HistoryOfApproval/DeleteHistoryOfApprovalEndpoint.cs
new file mode 100644
index 0000000..0095177
--- /dev/null
+++ b/PyroFetes/Endpoints/HistoryOfApproval/DeleteHistoryOfApprovalEndpoint.cs
@@ -0,0 +1,30 @@
+using FastEndpoints;
+using Microsoft.EntityFrameworkCore;
+using PyroFetes.DTO.HistoryOfApproval.Request;
+using PyroFetes.DTO.HistoryOfApproval.Response;
+
+namespace PyroFetes.Endpoints.HistoryOfApproval;
+
+public class DeleteHistoryOfApprovalEndpoint(PyroFetesDbContext pyroFetesDbContext) : Endpoint
+{
+ public override void Configure()
+ {
+ Delete ("/api/HistoryOfApprovals/{@Id}", x => new { x.Id });
+ AllowAnonymous();
+ }
+
+ public override async Task HandleAsync(GetHistoryOfApprovalRequest req, CancellationToken ct)
+ {
+ Models.HistoryOfApproval? databaseHistoryOfApproval = await pyroFetesDbContext.HistoryOfApprovals.SingleOrDefaultAsync(x => x.Id == req.Id, cancellationToken: ct);
+
+ if (databaseHistoryOfApproval == null)
+ {
+ await Send.NotFoundAsync(ct);
+ return;
+ }
+ pyroFetesDbContext.HistoryOfApprovals.Remove(databaseHistoryOfApproval);
+ await pyroFetesDbContext.SaveChangesAsync(ct);
+
+ await Send.NoContentAsync(ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/HistoryOfApproval/GetAllHistoryOfApprovalEndpoint.cs b/PyroFetes/Endpoints/HistoryOfApproval/GetAllHistoryOfApprovalEndpoint.cs
new file mode 100644
index 0000000..cc0cd48
--- /dev/null
+++ b/PyroFetes/Endpoints/HistoryOfApproval/GetAllHistoryOfApprovalEndpoint.cs
@@ -0,0 +1,26 @@
+using FastEndpoints;
+using Microsoft.EntityFrameworkCore;
+using PyroFetes.DTO.HistoryOfApproval.Response;
+
+namespace PyroFetes.Endpoints.HistoryOfApproval;
+
+public class GetAllHistoryOfApprovalEndpoint(PyroFetesDbContext pyroFetesDbContext) : EndpointWithoutRequest>
+{
+ public override void Configure()
+ {
+ Get ("/api/HistoryOfApprovals");
+ AllowAnonymous();
+ }
+
+ public override async Task HandleAsync(CancellationToken ct)
+ {
+ List historyOfApprovals= await pyroFetesDbContext.HistoryOfApprovals.Select(x => new GetHistoryOfApprovalDto()
+ {
+ Id = x.Id,
+ DeliveryDate = x.DeliveryDate,
+ ExpirationDate = x.ExpirationDate,
+ }).ToListAsync(ct);
+
+ await Send.OkAsync(historyOfApprovals, ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/HistoryOfApproval/GetHistoryOfApprovalEndpoint.cs b/PyroFetes/Endpoints/HistoryOfApproval/GetHistoryOfApprovalEndpoint.cs
new file mode 100644
index 0000000..eb3f70c
--- /dev/null
+++ b/PyroFetes/Endpoints/HistoryOfApproval/GetHistoryOfApprovalEndpoint.cs
@@ -0,0 +1,35 @@
+using FastEndpoints;
+using Microsoft.EntityFrameworkCore;
+using PyroFetes.DTO.HistoryOfApproval.Request;
+using PyroFetes.DTO.HistoryOfApproval.Response;
+
+namespace PyroFetes.Endpoints.HistoryOfApproval;
+
+public class GetHistoryOfApprovalEndpoint(PyroFetesDbContext pyroFetesDbContext) : Endpoint
+{
+ public override void Configure()
+ {
+ Get ("/api/HistoryOfApprovals/{@Id}", x => new { x.Id });
+ AllowAnonymous();
+ }
+
+ public override async Task HandleAsync(GetHistoryOfApprovalRequest req, CancellationToken ct)
+ {
+ Models.HistoryOfApproval? databaseHistoryOfApproval = await pyroFetesDbContext.HistoryOfApprovals.SingleOrDefaultAsync(x => x.Id == req.Id, cancellationToken: ct);
+
+ if (databaseHistoryOfApproval == null)
+ {
+ await Send.NotFoundAsync(ct);
+ return;
+ }
+
+ GetHistoryOfApprovalDto dto = new()
+ {
+ Id = databaseHistoryOfApproval.Id,
+ DeliveryDate = databaseHistoryOfApproval.DeliveryDate,
+ ExpirationDate = databaseHistoryOfApproval.ExpirationDate
+ };
+
+ await Send.OkAsync(dto, ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Endpoints/HistoryOfApproval/UpdateHistoryOfApprovalEndpoint.cs b/PyroFetes/Endpoints/HistoryOfApproval/UpdateHistoryOfApprovalEndpoint.cs
new file mode 100644
index 0000000..e5c98e6
--- /dev/null
+++ b/PyroFetes/Endpoints/HistoryOfApproval/UpdateHistoryOfApprovalEndpoint.cs
@@ -0,0 +1,41 @@
+using FastEndpoints;
+using Microsoft.EntityFrameworkCore;
+using PyroFetes.DTO.HistoryOfApproval.Request;
+using PyroFetes.DTO.HistoryOfApproval.Response;
+
+namespace PyroFetes.Endpoints.HistoryOfApproval;
+
+public class UpdateHistoryOfApprovalEndpoint(PyroFetesDbContext pyroFetesDbContext) : Endpoint
+{
+ public override void Configure()
+ {
+ Put ("/api/HistoryOfApprovals/{@Id}", x => new { x.Id });
+ AllowAnonymous();
+ }
+
+ public override async Task HandleAsync(UpdateHistoryOfApprovalDto req, CancellationToken ct)
+ {
+ Models.HistoryOfApproval? databaseHistoryOfApproval = await pyroFetesDbContext.HistoryOfApprovals.SingleOrDefaultAsync(x => x.Id == req.Id, cancellationToken: ct);
+
+ if (databaseHistoryOfApproval == null)
+ {
+ await Send.NotFoundAsync(ct);
+ return;
+ }
+ else
+ {
+ databaseHistoryOfApproval.DeliveryDate = req.DeliveryDate;
+ databaseHistoryOfApproval.ExpirationDate = req.ExpirationDate;
+ }
+ await pyroFetesDbContext.SaveChangesAsync(ct);
+
+ GetHistoryOfApprovalDto dto = new()
+ {
+ Id = databaseHistoryOfApproval.Id,
+ DeliveryDate = req.DeliveryDate,
+ ExpirationDate = req.ExpirationDate
+ };
+
+ await Send.OkAsync(dto, ct);
+ }
+}
\ No newline at end of file
diff --git a/PyroFetes/Migrations/20251008103414_InitialDatabase.Designer.cs b/PyroFetes/Migrations/20251008103414_InitialDatabase.Designer.cs
new file mode 100644
index 0000000..8e971b2
--- /dev/null
+++ b/PyroFetes/Migrations/20251008103414_InitialDatabase.Designer.cs
@@ -0,0 +1,1951 @@
+//
+using System;
+using Microsoft.EntityFrameworkCore;
+using Microsoft.EntityFrameworkCore.Infrastructure;
+using Microsoft.EntityFrameworkCore.Metadata;
+using Microsoft.EntityFrameworkCore.Migrations;
+using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
+using PyroFetes;
+
+#nullable disable
+
+namespace PyroFetes.Migrations
+{
+ [DbContext(typeof(PyroFetesDbContext))]
+ [Migration("20251008103414_InitialDatabase")]
+ partial class InitialDatabase
+ {
+ ///
+ protected override void BuildTargetModel(ModelBuilder modelBuilder)
+ {
+#pragma warning disable 612, 618
+ modelBuilder
+ .HasAnnotation("ProductVersion", "8.0.20")
+ .HasAnnotation("Relational:MaxIdentifierLength", 128);
+
+ SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder);
+
+ modelBuilder.Entity("PyroFetes.Models.Availability", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("AvailabilityDate")
+ .HasColumnType("date");
+
+ b.Property("DeliveryDate")
+ .HasColumnType("date");
+
+ b.Property("ExpirationDate")
+ .HasColumnType("date");
+
+ b.Property("RenewallDate")
+ .HasColumnType("date");
+
+ b.HasKey("Id");
+
+ b.ToTable("Availabilities");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Brand", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Name")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("ProductId")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.HasIndex("ProductId");
+
+ b.ToTable("Brands");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.City", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Name")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("ZipCode")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.ToTable("City");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Classification", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Label")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.HasKey("Id");
+
+ b.ToTable("Classifications");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Color", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Label")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.HasKey("Id");
+
+ b.ToTable("Colors");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Communication", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Calling")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("ContactId")
+ .HasColumnType("int");
+
+ b.Property("Email")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("Meeting")
+ .IsRequired()
+ .HasMaxLength(300)
+ .HasColumnType("nvarchar(300)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("ContactId");
+
+ b.ToTable("Communications");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Contact", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Address")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("City")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("CustomerId")
+ .HasColumnType("int");
+
+ b.Property("Email")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("FirstName")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("LastName")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("PhoneNumber")
+ .IsRequired()
+ .HasMaxLength(30)
+ .HasColumnType("nvarchar(30)");
+
+ b.Property("Role")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("ZipCode")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CustomerId");
+
+ b.ToTable("Contacts");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ContactServiceProvider", b =>
+ {
+ b.Property("ContactId")
+ .HasColumnType("int");
+
+ b.Property("ServiceProviderId")
+ .HasColumnType("int");
+
+ b.HasKey("ContactId", "ServiceProviderId");
+
+ b.HasIndex("ServiceProviderId");
+
+ b.ToTable("ContactServiceProvider");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Contract", b =>
+ {
+ b.Property("ShowId")
+ .HasColumnType("int");
+
+ b.Property("ServiceProviderId")
+ .HasColumnType("int");
+
+ b.Property("TermsAndConditions")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.HasKey("ShowId", "ServiceProviderId");
+
+ b.HasIndex("ServiceProviderId");
+
+ b.ToTable("Contract");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Customer", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("CustomerTypeId")
+ .HasColumnType("int");
+
+ b.Property("Note")
+ .IsRequired()
+ .HasMaxLength(200)
+ .HasColumnType("nvarchar(200)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CustomerTypeId");
+
+ b.ToTable("Customers");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.CustomerType", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Label")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.HasKey("Id");
+
+ b.ToTable("CustomerTypes");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Deliverer", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Transporter")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.HasKey("Id");
+
+ b.ToTable("Deliverers");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.DeliveryNote", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("DelivererId")
+ .HasColumnType("int");
+
+ b.Property("EstimateDeliveryDate")
+ .HasColumnType("date");
+
+ b.Property("ExpeditionDate")
+ .HasColumnType("date");
+
+ b.Property("RealDeliveryDate")
+ .HasColumnType("date");
+
+ b.Property("TrackingNumber")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("DelivererId");
+
+ b.ToTable("DeliveryNotes");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Effect", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Label")
+ .IsRequired()
+ .HasMaxLength(200)
+ .HasColumnType("nvarchar(200)");
+
+ b.HasKey("Id");
+
+ b.ToTable("Effects");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ExperienceLevel", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Label")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("StaffId")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.HasIndex("StaffId");
+
+ b.ToTable("ExperienceLevels");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.HistoryOfApproval", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("DeliveryDate")
+ .HasColumnType("date");
+
+ b.Property("ExpirationDate")
+ .HasColumnType("date");
+
+ b.HasKey("Id");
+
+ b.ToTable("HistoryOfApprovals");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Material", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Name")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("Quantity")
+ .HasColumnType("int");
+
+ b.Property("WarehouseId")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.HasIndex("WarehouseId");
+
+ b.ToTable("Materials");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.MaterialWarehouse", b =>
+ {
+ b.Property("MaterialId")
+ .HasColumnType("int");
+
+ b.Property("WarehouseId")
+ .HasColumnType("int");
+
+ b.HasKey("MaterialId", "WarehouseId");
+
+ b.HasIndex("WarehouseId");
+
+ b.ToTable("MaterialWarehouse");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Movement", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Arrival")
+ .HasColumnType("datetime2");
+
+ b.Property("Date")
+ .HasColumnType("datetime2");
+
+ b.Property("DestinationWarehouseId")
+ .HasColumnType("int");
+
+ b.Property("Quantity")
+ .HasColumnType("int");
+
+ b.Property("SourceWarehouseId")
+ .HasColumnType("int");
+
+ b.Property("Start")
+ .HasColumnType("datetime2");
+
+ b.HasKey("Id");
+
+ b.HasIndex("DestinationWarehouseId");
+
+ b.HasIndex("SourceWarehouseId");
+
+ b.ToTable("Movements");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Price", b =>
+ {
+ b.Property("ProductId")
+ .HasColumnType("int");
+
+ b.Property("SupplierId")
+ .HasColumnType("int");
+
+ b.Property("SellingPrice")
+ .HasColumnType("decimal(18,2)");
+
+ b.HasKey("ProductId", "SupplierId");
+
+ b.HasIndex("SupplierId");
+
+ b.ToTable("Prices");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Product", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("ApprovalNumber")
+ .HasColumnType("int");
+
+ b.Property("Caliber")
+ .HasColumnType("decimal(18,2)");
+
+ b.Property("ClassificationId")
+ .HasColumnType("int");
+
+ b.Property("Duration")
+ .HasColumnType("decimal(18,2)");
+
+ b.Property("Image")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("Link")
+ .IsRequired()
+ .HasMaxLength(200)
+ .HasColumnType("nvarchar(200)");
+
+ b.Property("MinimalQuantity")
+ .HasColumnType("int");
+
+ b.Property("MovementId")
+ .HasColumnType("int");
+
+ b.Property("Name")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("Nec")
+ .HasColumnType("decimal(18,2)");
+
+ b.Property("ProductCategoryId")
+ .HasColumnType("int");
+
+ b.Property("References")
+ .HasColumnType("int");
+
+ b.Property("SellingPrice")
+ .HasColumnType("decimal(18,2)");
+
+ b.Property("Weight")
+ .HasColumnType("decimal(18,2)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("ClassificationId");
+
+ b.HasIndex("MovementId");
+
+ b.HasIndex("ProductCategoryId");
+
+ b.ToTable("Products");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ProductCategory", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Label")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.HasKey("Id");
+
+ b.ToTable("ProductCategories");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ProductColor", b =>
+ {
+ b.Property("ProductId")
+ .HasColumnType("int");
+
+ b.Property("ColorId")
+ .HasColumnType("int");
+
+ b.HasKey("ProductId", "ColorId");
+
+ b.HasIndex("ColorId");
+
+ b.ToTable("ProductColors");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ProductDelivery", b =>
+ {
+ b.Property("ProductId")
+ .HasColumnType("int");
+
+ b.Property("DeliveryNoteId")
+ .HasColumnType("int");
+
+ b.Property("Quantity")
+ .HasColumnType("int");
+
+ b.HasKey("ProductId", "DeliveryNoteId");
+
+ b.HasIndex("DeliveryNoteId");
+
+ b.ToTable("ProductDeliveries");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ProductEffect", b =>
+ {
+ b.Property("ProductId")
+ .HasColumnType("int");
+
+ b.Property("EffectId")
+ .HasColumnType("int");
+
+ b.HasKey("ProductId", "EffectId");
+
+ b.HasIndex("EffectId");
+
+ b.ToTable("ProductEffects");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ProductTimecode", b =>
+ {
+ b.Property("ProductId")
+ .HasColumnType("int");
+
+ b.Property("ShowId")
+ .HasColumnType("int");
+
+ b.Property("End")
+ .HasColumnType("decimal(18,2)");
+
+ b.Property("Start")
+ .HasColumnType("decimal(18,2)");
+
+ b.HasKey("ProductId", "ShowId");
+
+ b.HasIndex("ShowId");
+
+ b.ToTable("ProductTimecode");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ProviderContact", b =>
+ {
+ b.Property("ContactId")
+ .HasColumnType("int");
+
+ b.Property("ProviderId")
+ .HasColumnType("int");
+
+ b.HasKey("ContactId", "ProviderId");
+
+ b.HasIndex("ProviderId");
+
+ b.ToTable("ProviderContacts");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ProviderType", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Label")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.HasKey("Id");
+
+ b.ToTable("ProviderTypes");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.PurchaseOrder", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("PurchaseConditions")
+ .IsRequired()
+ .HasMaxLength(300)
+ .HasColumnType("nvarchar(300)");
+
+ b.HasKey("Id");
+
+ b.ToTable("PurchaseOrders");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.PurchaseProduct", b =>
+ {
+ b.Property("ProductId")
+ .HasColumnType("int");
+
+ b.Property("PurchaseOrderId")
+ .HasColumnType("int");
+
+ b.Property("Quantity")
+ .HasColumnType("int");
+
+ b.HasKey("ProductId", "PurchaseOrderId");
+
+ b.HasIndex("PurchaseOrderId");
+
+ b.ToTable("PurchaseProducts");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Quotation", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("ConditionsSale")
+ .IsRequired()
+ .HasMaxLength(300)
+ .HasColumnType("nvarchar(300)");
+
+ b.Property("CustomerId")
+ .HasColumnType("int");
+
+ b.Property("Message")
+ .IsRequired()
+ .HasMaxLength(200)
+ .HasColumnType("nvarchar(200)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CustomerId");
+
+ b.ToTable("Quotations");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.QuotationProduct", b =>
+ {
+ b.Property("ProductId")
+ .HasColumnType("int");
+
+ b.Property("QuotationId")
+ .HasColumnType("int");
+
+ b.Property("Quantity")
+ .HasColumnType("int");
+
+ b.HasKey("ProductId", "QuotationId");
+
+ b.HasIndex("QuotationId");
+
+ b.ToTable("QuotationProducts");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ServiceProvider", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Price")
+ .HasColumnType("decimal(18,2)");
+
+ b.Property("ProviderTypeId")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.HasIndex("ProviderTypeId");
+
+ b.ToTable("Providers");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Setting", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("ElectronicSignature")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.Property("Logo")
+ .IsRequired()
+ .HasColumnType("nvarchar(max)");
+
+ b.HasKey("Id");
+
+ b.ToTable("Settings");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Show", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("CityId")
+ .HasColumnType("int");
+
+ b.Property("Date")
+ .HasColumnType("date");
+
+ b.Property("Description")
+ .HasMaxLength(500)
+ .HasColumnType("nvarchar(500)");
+
+ b.Property("Name")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("Place")
+ .IsRequired()
+ .HasMaxLength(120)
+ .HasColumnType("nvarchar(120)");
+
+ b.Property("PyrotechnicImplementationPlan")
+ .IsRequired()
+ .HasMaxLength(500)
+ .HasColumnType("nvarchar(500)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("CityId");
+
+ b.ToTable("Shows");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ShowMaterial", b =>
+ {
+ b.Property("ShowId")
+ .HasColumnType("int");
+
+ b.Property("MaterialId")
+ .HasColumnType("int");
+
+ b.HasKey("ShowId", "MaterialId");
+
+ b.HasIndex("MaterialId");
+
+ b.ToTable("ShowMaterial");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ShowStaff", b =>
+ {
+ b.Property("StaffId")
+ .HasColumnType("int");
+
+ b.Property("ShowId")
+ .HasColumnType("int");
+
+ b.HasKey("StaffId", "ShowId");
+
+ b.HasIndex("ShowId");
+
+ b.ToTable("ShowStaff");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ShowTruck", b =>
+ {
+ b.Property("ShowId")
+ .HasColumnType("int");
+
+ b.Property("TruckId")
+ .HasColumnType("int");
+
+ b.HasKey("ShowId", "TruckId");
+
+ b.HasIndex("TruckId");
+
+ b.ToTable("ShowTruck");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Sound", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Artist")
+ .IsRequired()
+ .HasMaxLength(120)
+ .HasColumnType("nvarchar(120)");
+
+ b.Property("CreationDate")
+ .HasColumnType("datetime2");
+
+ b.Property("Duration")
+ .IsRequired()
+ .HasColumnType("int");
+
+ b.Property("Format")
+ .IsRequired()
+ .HasMaxLength(40)
+ .HasColumnType("nvarchar(40)");
+
+ b.Property("Kind")
+ .IsRequired()
+ .HasMaxLength(40)
+ .HasColumnType("nvarchar(40)");
+
+ b.Property("Name")
+ .IsRequired()
+ .HasMaxLength(120)
+ .HasColumnType("nvarchar(120)");
+
+ b.Property("SoundCategoryId")
+ .HasColumnType("int");
+
+ b.Property("Type")
+ .IsRequired()
+ .HasMaxLength(60)
+ .HasColumnType("nvarchar(60)");
+
+ b.HasKey("Id");
+
+ b.HasIndex("SoundCategoryId");
+
+ b.ToTable("Sounds");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.SoundCategory", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Name")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.HasKey("Id");
+
+ b.ToTable("SoundCategories");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.SoundTimecode", b =>
+ {
+ b.Property("ShowId")
+ .HasColumnType("int");
+
+ b.Property("SoundId")
+ .HasColumnType("int");
+
+ b.Property("End")
+ .HasColumnType("decimal(18,2)");
+
+ b.Property("Start")
+ .HasColumnType("decimal(18,2)");
+
+ b.HasKey("ShowId", "SoundId");
+
+ b.HasIndex("SoundId");
+
+ b.ToTable("SoundTimecodes");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Staff", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Email")
+ .IsRequired()
+ .HasMaxLength(120)
+ .HasColumnType("nvarchar(120)");
+
+ b.Property("F4T2ExpirationDate")
+ .HasColumnType("date");
+
+ b.Property("F4T2NumberApproval")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("FirstName")
+ .IsRequired()
+ .HasMaxLength(60)
+ .HasColumnType("nvarchar(60)");
+
+ b.Property("LastName")
+ .IsRequired()
+ .HasMaxLength(60)
+ .HasColumnType("nvarchar(60)");
+
+ b.Property("Profession")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.HasKey("Id");
+
+ b.ToTable("Staffs");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.StaffAvailability", b =>
+ {
+ b.Property("AvailabilityId")
+ .HasColumnType("int");
+
+ b.Property("StaffId")
+ .HasColumnType("int");
+
+ b.HasKey("AvailabilityId", "StaffId");
+
+ b.HasIndex("StaffId");
+
+ b.ToTable("StaffAvailabilities");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.StaffContact", b =>
+ {
+ b.Property("ContactId")
+ .HasColumnType("int");
+
+ b.Property("StaffId")
+ .HasColumnType("int");
+
+ b.HasKey("ContactId", "StaffId");
+
+ b.HasIndex("StaffId");
+
+ b.ToTable("StaffContacts");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.StaffHistoryOfApproval", b =>
+ {
+ b.Property("HistoryOfApprovalId")
+ .HasColumnType("int");
+
+ b.Property("StaffId")
+ .HasColumnType("int");
+
+ b.HasKey("HistoryOfApprovalId", "StaffId");
+
+ b.HasIndex("StaffId");
+
+ b.ToTable("StaffHistoryOfApprovals");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Supplier", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Address")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("City")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("DeliveryDelay")
+ .HasColumnType("int");
+
+ b.Property("Email")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("Name")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("Phone")
+ .IsRequired()
+ .HasMaxLength(30)
+ .HasColumnType("nvarchar(30)");
+
+ b.Property("ZipCode")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.ToTable("Suppliers");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Truck", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("MaxExplosiveCapacity")
+ .IsRequired()
+ .HasColumnType("float");
+
+ b.Property("Sizes")
+ .IsRequired()
+ .HasMaxLength(80)
+ .HasColumnType("nvarchar(80)");
+
+ b.Property("Status")
+ .IsRequired()
+ .HasMaxLength(40)
+ .HasColumnType("nvarchar(40)");
+
+ b.Property("Type")
+ .IsRequired()
+ .HasMaxLength(40)
+ .HasColumnType("nvarchar(40)");
+
+ b.HasKey("Id");
+
+ b.ToTable("Trucks");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.User", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Email")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("Fonction")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("Name")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("Password")
+ .IsRequired()
+ .HasMaxLength(50)
+ .HasColumnType("nvarchar(50)");
+
+ b.Property("Salt")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.HasKey("Id");
+
+ b.ToTable("Users");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Warehouse", b =>
+ {
+ b.Property("Id")
+ .ValueGeneratedOnAdd()
+ .HasColumnType("int");
+
+ SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Id"));
+
+ b.Property("Address")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("City")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("Current")
+ .HasColumnType("int");
+
+ b.Property("MaxWeight")
+ .HasColumnType("int");
+
+ b.Property("MinWeight")
+ .HasColumnType("int");
+
+ b.Property("Name")
+ .IsRequired()
+ .HasMaxLength(100)
+ .HasColumnType("nvarchar(100)");
+
+ b.Property("ZipCode")
+ .HasColumnType("int");
+
+ b.HasKey("Id");
+
+ b.ToTable("Warehouses");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.WarehouseProduct", b =>
+ {
+ b.Property("ProductId")
+ .HasColumnType("int");
+
+ b.Property("WarehouseId")
+ .HasColumnType("int");
+
+ b.Property("Quantity")
+ .HasColumnType("int");
+
+ b.HasKey("ProductId", "WarehouseId");
+
+ b.HasIndex("WarehouseId");
+
+ b.ToTable("WarehouseProducts");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Brand", b =>
+ {
+ b.HasOne("PyroFetes.Models.Product", "Product")
+ .WithMany("Brands")
+ .HasForeignKey("ProductId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Product");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Communication", b =>
+ {
+ b.HasOne("PyroFetes.Models.Contact", "Contact")
+ .WithMany("Communications")
+ .HasForeignKey("ContactId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Contact");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Contact", b =>
+ {
+ b.HasOne("PyroFetes.Models.Customer", "Customer")
+ .WithMany("Contacts")
+ .HasForeignKey("CustomerId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Customer");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ContactServiceProvider", b =>
+ {
+ b.HasOne("PyroFetes.Models.Contact", "Contact")
+ .WithMany("ContactServiceProviders")
+ .HasForeignKey("ContactId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.ServiceProvider", "ServiceProvider")
+ .WithMany("ContactServiceProviders")
+ .HasForeignKey("ServiceProviderId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Contact");
+
+ b.Navigation("ServiceProvider");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Contract", b =>
+ {
+ b.HasOne("PyroFetes.Models.ServiceProvider", "ServiceProvider")
+ .WithMany("Contracts")
+ .HasForeignKey("ServiceProviderId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Show", "Show")
+ .WithMany("Contracts")
+ .HasForeignKey("ShowId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("ServiceProvider");
+
+ b.Navigation("Show");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Customer", b =>
+ {
+ b.HasOne("PyroFetes.Models.CustomerType", "CustomerType")
+ .WithMany("Customers")
+ .HasForeignKey("CustomerTypeId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("CustomerType");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.DeliveryNote", b =>
+ {
+ b.HasOne("PyroFetes.Models.Deliverer", "Deliverer")
+ .WithMany("DeliveryNotes")
+ .HasForeignKey("DelivererId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Deliverer");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ExperienceLevel", b =>
+ {
+ b.HasOne("PyroFetes.Models.Staff", "Staff")
+ .WithMany("ExperienceLevels")
+ .HasForeignKey("StaffId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Staff");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Material", b =>
+ {
+ b.HasOne("PyroFetes.Models.Warehouse", "Warehouse")
+ .WithMany()
+ .HasForeignKey("WarehouseId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Warehouse");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.MaterialWarehouse", b =>
+ {
+ b.HasOne("PyroFetes.Models.Material", "Material")
+ .WithMany("MaterialWarehouses")
+ .HasForeignKey("MaterialId")
+ .OnDelete(DeleteBehavior.Restrict)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Warehouse", "Warehouse")
+ .WithMany("MaterialWarehouses")
+ .HasForeignKey("WarehouseId")
+ .OnDelete(DeleteBehavior.Restrict)
+ .IsRequired();
+
+ b.Navigation("Material");
+
+ b.Navigation("Warehouse");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Movement", b =>
+ {
+ b.HasOne("PyroFetes.Models.Warehouse", "DestinationWarehouse")
+ .WithMany("MovementsDestination")
+ .HasForeignKey("DestinationWarehouseId")
+ .OnDelete(DeleteBehavior.Restrict);
+
+ b.HasOne("PyroFetes.Models.Warehouse", "SourceWarehouse")
+ .WithMany("MovementsSource")
+ .HasForeignKey("SourceWarehouseId")
+ .OnDelete(DeleteBehavior.Restrict);
+
+ b.Navigation("DestinationWarehouse");
+
+ b.Navigation("SourceWarehouse");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Price", b =>
+ {
+ b.HasOne("PyroFetes.Models.Product", "Product")
+ .WithMany("Prices")
+ .HasForeignKey("ProductId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Supplier", "Supplier")
+ .WithMany("Prices")
+ .HasForeignKey("SupplierId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Product");
+
+ b.Navigation("Supplier");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Product", b =>
+ {
+ b.HasOne("PyroFetes.Models.Classification", "Classification")
+ .WithMany("Products")
+ .HasForeignKey("ClassificationId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Movement", "Movement")
+ .WithMany("Products")
+ .HasForeignKey("MovementId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.ProductCategory", "ProductCategory")
+ .WithMany("Products")
+ .HasForeignKey("ProductCategoryId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Classification");
+
+ b.Navigation("Movement");
+
+ b.Navigation("ProductCategory");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ProductColor", b =>
+ {
+ b.HasOne("PyroFetes.Models.Color", "Color")
+ .WithMany("ProductColors")
+ .HasForeignKey("ColorId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Product", "Product")
+ .WithMany("ProductColors")
+ .HasForeignKey("ProductId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Color");
+
+ b.Navigation("Product");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ProductDelivery", b =>
+ {
+ b.HasOne("PyroFetes.Models.DeliveryNote", "DeliveryNote")
+ .WithMany("ProductDeliveries")
+ .HasForeignKey("DeliveryNoteId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Product", "Product")
+ .WithMany("ProductDeliveries")
+ .HasForeignKey("ProductId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("DeliveryNote");
+
+ b.Navigation("Product");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ProductEffect", b =>
+ {
+ b.HasOne("PyroFetes.Models.Effect", "Effect")
+ .WithMany("ProductEffects")
+ .HasForeignKey("EffectId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Product", "Product")
+ .WithMany("ProductEffects")
+ .HasForeignKey("ProductId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Effect");
+
+ b.Navigation("Product");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ProductTimecode", b =>
+ {
+ b.HasOne("PyroFetes.Models.Product", "Product")
+ .WithMany("ProductTimecodes")
+ .HasForeignKey("ProductId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Show", "Show")
+ .WithMany("ProductTimecodes")
+ .HasForeignKey("ShowId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Product");
+
+ b.Navigation("Show");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ProviderContact", b =>
+ {
+ b.HasOne("PyroFetes.Models.Contact", "Contact")
+ .WithMany()
+ .HasForeignKey("ContactId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.ServiceProvider", "Provider")
+ .WithMany()
+ .HasForeignKey("ProviderId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Contact");
+
+ b.Navigation("Provider");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.PurchaseProduct", b =>
+ {
+ b.HasOne("PyroFetes.Models.Product", "Product")
+ .WithMany("PurchaseProducts")
+ .HasForeignKey("ProductId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.PurchaseOrder", "PurchaseOrder")
+ .WithMany("PurchaseProducts")
+ .HasForeignKey("PurchaseOrderId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Product");
+
+ b.Navigation("PurchaseOrder");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Quotation", b =>
+ {
+ b.HasOne("PyroFetes.Models.Customer", "Customer")
+ .WithMany("Quotations")
+ .HasForeignKey("CustomerId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Customer");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.QuotationProduct", b =>
+ {
+ b.HasOne("PyroFetes.Models.Product", "Product")
+ .WithMany("QuotationProducts")
+ .HasForeignKey("ProductId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Quotation", "Quotation")
+ .WithMany("QuotationProducts")
+ .HasForeignKey("QuotationId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Product");
+
+ b.Navigation("Quotation");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ServiceProvider", b =>
+ {
+ b.HasOne("PyroFetes.Models.ProviderType", "ProviderType")
+ .WithMany("ServiceProviders")
+ .HasForeignKey("ProviderTypeId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("ProviderType");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Show", b =>
+ {
+ b.HasOne("PyroFetes.Models.City", "City")
+ .WithMany("Shows")
+ .HasForeignKey("CityId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("City");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ShowMaterial", b =>
+ {
+ b.HasOne("PyroFetes.Models.Material", "Material")
+ .WithMany("ShowMaterials")
+ .HasForeignKey("MaterialId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Show", "Show")
+ .WithMany("ShowMaterials")
+ .HasForeignKey("ShowId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Material");
+
+ b.Navigation("Show");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ShowStaff", b =>
+ {
+ b.HasOne("PyroFetes.Models.Show", "Show")
+ .WithMany("ShowStaffs")
+ .HasForeignKey("ShowId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Staff", "Staff")
+ .WithMany("ShowStaffs")
+ .HasForeignKey("StaffId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Show");
+
+ b.Navigation("Staff");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ShowTruck", b =>
+ {
+ b.HasOne("PyroFetes.Models.Show", "Show")
+ .WithMany("ShowTrucks")
+ .HasForeignKey("ShowId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Truck", "Truck")
+ .WithMany("ShowTrucks")
+ .HasForeignKey("TruckId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Show");
+
+ b.Navigation("Truck");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Sound", b =>
+ {
+ b.HasOne("PyroFetes.Models.SoundCategory", "SoundCategory")
+ .WithMany("Sounds")
+ .HasForeignKey("SoundCategoryId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("SoundCategory");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.SoundTimecode", b =>
+ {
+ b.HasOne("PyroFetes.Models.Show", "Show")
+ .WithMany("SoundTimecodes")
+ .HasForeignKey("ShowId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Sound", "Sound")
+ .WithMany("SoundTimecodes")
+ .HasForeignKey("SoundId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Show");
+
+ b.Navigation("Sound");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.StaffAvailability", b =>
+ {
+ b.HasOne("PyroFetes.Models.Availability", "Availability")
+ .WithMany("StaffAvailabilities")
+ .HasForeignKey("AvailabilityId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Staff", "Staff")
+ .WithMany("StaffAvailabilities")
+ .HasForeignKey("StaffId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Availability");
+
+ b.Navigation("Staff");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.StaffContact", b =>
+ {
+ b.HasOne("PyroFetes.Models.Contact", "Contact")
+ .WithMany("StaffContacts")
+ .HasForeignKey("ContactId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Staff", "Staff")
+ .WithMany("StaffContacts")
+ .HasForeignKey("StaffId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Contact");
+
+ b.Navigation("Staff");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.StaffHistoryOfApproval", b =>
+ {
+ b.HasOne("PyroFetes.Models.HistoryOfApproval", "HistoryOfApproval")
+ .WithMany("StaffHistoryOfApprovals")
+ .HasForeignKey("HistoryOfApprovalId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Staff", "Staff")
+ .WithMany("StaffHistoryOfApprovals")
+ .HasForeignKey("StaffId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("HistoryOfApproval");
+
+ b.Navigation("Staff");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.WarehouseProduct", b =>
+ {
+ b.HasOne("PyroFetes.Models.Product", "Product")
+ .WithMany("WarehouseProducts")
+ .HasForeignKey("ProductId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.HasOne("PyroFetes.Models.Warehouse", "Warehouse")
+ .WithMany("WarehouseProducts")
+ .HasForeignKey("WarehouseId")
+ .OnDelete(DeleteBehavior.Cascade)
+ .IsRequired();
+
+ b.Navigation("Product");
+
+ b.Navigation("Warehouse");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Availability", b =>
+ {
+ b.Navigation("StaffAvailabilities");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.City", b =>
+ {
+ b.Navigation("Shows");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Classification", b =>
+ {
+ b.Navigation("Products");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Color", b =>
+ {
+ b.Navigation("ProductColors");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Contact", b =>
+ {
+ b.Navigation("Communications");
+
+ b.Navigation("ContactServiceProviders");
+
+ b.Navigation("StaffContacts");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Customer", b =>
+ {
+ b.Navigation("Contacts");
+
+ b.Navigation("Quotations");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.CustomerType", b =>
+ {
+ b.Navigation("Customers");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Deliverer", b =>
+ {
+ b.Navigation("DeliveryNotes");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.DeliveryNote", b =>
+ {
+ b.Navigation("ProductDeliveries");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Effect", b =>
+ {
+ b.Navigation("ProductEffects");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.HistoryOfApproval", b =>
+ {
+ b.Navigation("StaffHistoryOfApprovals");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Material", b =>
+ {
+ b.Navigation("MaterialWarehouses");
+
+ b.Navigation("ShowMaterials");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Movement", b =>
+ {
+ b.Navigation("Products");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Product", b =>
+ {
+ b.Navigation("Brands");
+
+ b.Navigation("Prices");
+
+ b.Navigation("ProductColors");
+
+ b.Navigation("ProductDeliveries");
+
+ b.Navigation("ProductEffects");
+
+ b.Navigation("ProductTimecodes");
+
+ b.Navigation("PurchaseProducts");
+
+ b.Navigation("QuotationProducts");
+
+ b.Navigation("WarehouseProducts");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ProductCategory", b =>
+ {
+ b.Navigation("Products");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ProviderType", b =>
+ {
+ b.Navigation("ServiceProviders");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.PurchaseOrder", b =>
+ {
+ b.Navigation("PurchaseProducts");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Quotation", b =>
+ {
+ b.Navigation("QuotationProducts");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.ServiceProvider", b =>
+ {
+ b.Navigation("ContactServiceProviders");
+
+ b.Navigation("Contracts");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Show", b =>
+ {
+ b.Navigation("Contracts");
+
+ b.Navigation("ProductTimecodes");
+
+ b.Navigation("ShowMaterials");
+
+ b.Navigation("ShowStaffs");
+
+ b.Navigation("ShowTrucks");
+
+ b.Navigation("SoundTimecodes");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Sound", b =>
+ {
+ b.Navigation("SoundTimecodes");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.SoundCategory", b =>
+ {
+ b.Navigation("Sounds");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Staff", b =>
+ {
+ b.Navigation("ExperienceLevels");
+
+ b.Navigation("ShowStaffs");
+
+ b.Navigation("StaffAvailabilities");
+
+ b.Navigation("StaffContacts");
+
+ b.Navigation("StaffHistoryOfApprovals");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Supplier", b =>
+ {
+ b.Navigation("Prices");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Truck", b =>
+ {
+ b.Navigation("ShowTrucks");
+ });
+
+ modelBuilder.Entity("PyroFetes.Models.Warehouse", b =>
+ {
+ b.Navigation("MaterialWarehouses");
+
+ b.Navigation("MovementsDestination");
+
+ b.Navigation("MovementsSource");
+
+ b.Navigation("WarehouseProducts");
+ });
+#pragma warning restore 612, 618
+ }
+ }
+}
diff --git a/PyroFetes/Migrations/20251008103414_InitialDatabase.cs b/PyroFetes/Migrations/20251008103414_InitialDatabase.cs
new file mode 100644
index 0000000..5c5dbc7
--- /dev/null
+++ b/PyroFetes/Migrations/20251008103414_InitialDatabase.cs
@@ -0,0 +1,1392 @@
+using System;
+using Microsoft.EntityFrameworkCore.Migrations;
+
+#nullable disable
+
+namespace PyroFetes.Migrations
+{
+ ///
+ public partial class InitialDatabase : Migration
+ {
+ ///
+ protected override void Up(MigrationBuilder migrationBuilder)
+ {
+ migrationBuilder.CreateTable(
+ name: "Availabilities",
+ columns: table => new
+ {
+ Id = table.Column(type: "int", nullable: false)
+ .Annotation("SqlServer:Identity", "1, 1"),
+ AvailabilityDate = table.Column(type: "date", nullable: false),
+ DeliveryDate = table.Column(type: "date", nullable: false),
+ ExpirationDate = table.Column(type: "date", nullable: false),
+ RenewallDate = table.Column(type: "date", nullable: false)
+ },
+ constraints: table =>
+ {
+ table.PrimaryKey("PK_Availabilities", x => x.Id);
+ });
+
+ migrationBuilder.CreateTable(
+ name: "City",
+ columns: table => new
+ {
+ Id = table.Column(type: "int", nullable: false)
+ .Annotation("SqlServer:Identity", "1, 1"),
+ Name = table.Column(type: "nvarchar(100)", maxLength: 100, nullable: false),
+ ZipCode = table.Column(type: "int", nullable: false)
+ },
+ constraints: table =>
+ {
+ table.PrimaryKey("PK_City", x => x.Id);
+ });
+
+ migrationBuilder.CreateTable(
+ name: "Classifications",
+ columns: table => new
+ {
+ Id = table.Column