Projet de stage 2021
615
.gitignore
vendored
Normal file
@ -0,0 +1,615 @@
|
||||
## 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/master/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
|
||||
|
||||
# Nuget personal access tokens and Credentials
|
||||
nuget.config
|
||||
|
||||
# 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 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/
|
||||
|
||||
# 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
|
||||
.idea/
|
||||
*.sln.iml
|
||||
|
||||
# The following command works for downloading when using Git for Windows:
|
||||
# curl -LOf http://gist.githubusercontent.com/kmorcinek/2710267/raw/.gitignore
|
||||
#
|
||||
# Download this file using PowerShell v3 under Windows with the following comand:
|
||||
# Invoke-WebRequest https://gist.githubusercontent.com/kmorcinek/2710267/raw/ -OutFile .gitignore
|
||||
#
|
||||
# or wget:
|
||||
# wget --no-check-certificate http://gist.githubusercontent.com/kmorcinek/2710267/raw/.gitignore
|
||||
|
||||
# User-specific files
|
||||
*.suo
|
||||
*.user
|
||||
*.sln.docstates
|
||||
|
||||
# Build results
|
||||
[Dd]ebug/
|
||||
[Rr]elease/
|
||||
x64/
|
||||
[Bb]in/
|
||||
[Oo]bj/
|
||||
# build folder is nowadays used for build scripts and should not be ignored
|
||||
#build/
|
||||
|
||||
# NuGet Packages
|
||||
*.nupkg
|
||||
# The packages folder can be ignored because of Package Restore
|
||||
**/packages/*
|
||||
# except build/, which is used as an MSBuild target.
|
||||
!**/packages/build/
|
||||
# Uncomment if necessary however generally it will be regenerated when needed
|
||||
#!**/packages/repositories.config
|
||||
|
||||
# MSTest test Results
|
||||
[Tt]est[Rr]esult*/
|
||||
[Bb]uild[Ll]og.*
|
||||
|
||||
*_i.c
|
||||
*_p.c
|
||||
*.ilk
|
||||
*.meta
|
||||
*.obj
|
||||
*.pch
|
||||
*.pdb
|
||||
*.pgc
|
||||
*.pgd
|
||||
*.rsp
|
||||
*.sbr
|
||||
*.tlb
|
||||
*.tli
|
||||
*.tlh
|
||||
*.tmp
|
||||
*.tmp_proj
|
||||
*.log
|
||||
*.vspscc
|
||||
*.vssscc
|
||||
.builds
|
||||
*.pidb
|
||||
*.log
|
||||
*.scc
|
||||
|
||||
# OS generated files #
|
||||
.DS_Store*
|
||||
|
||||
# Visual C++ cache files
|
||||
ipch/
|
||||
*.aps
|
||||
*.ncb
|
||||
*.opensdf
|
||||
*.sdf
|
||||
*.cachefile
|
||||
|
||||
# Visual Studio profiler
|
||||
*.psess
|
||||
*.vsp
|
||||
*.vspx
|
||||
|
||||
# Guidance Automation Toolkit
|
||||
*.gpState
|
||||
|
||||
# ReSharper is a .NET coding add-in
|
||||
_ReSharper*/
|
||||
*.[Rr]e[Ss]harper
|
||||
|
||||
# TeamCity is a build add-in
|
||||
_TeamCity*
|
||||
|
||||
# DotCover is a Code Coverage Tool
|
||||
*.dotCover
|
||||
|
||||
# NCrunch
|
||||
*.ncrunch*
|
||||
.*crunch*.local.xml
|
||||
|
||||
# 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
|
||||
*.Publish.xml
|
||||
|
||||
# Windows Azure Build Output
|
||||
csx
|
||||
*.build.csdef
|
||||
|
||||
# Windows Store app package directory
|
||||
AppPackages/
|
||||
|
||||
# Others
|
||||
*.Cache
|
||||
ClientBin/
|
||||
[Ss]tyle[Cc]op.*
|
||||
~$*
|
||||
*~
|
||||
*.dbmdl
|
||||
*.[Pp]ublish.xml
|
||||
*.pfx
|
||||
*.publishsettings
|
||||
modulesbin/
|
||||
tempbin/
|
||||
|
||||
# EPiServer Site file (VPP)
|
||||
AppData/
|
||||
|
||||
# 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
|
||||
|
||||
# vim
|
||||
*.txt~
|
||||
*.swp
|
||||
*.swo
|
||||
|
||||
# Temp files when opening LibreOffice on ubuntu
|
||||
.~lock.*
|
||||
|
||||
# svn
|
||||
.svn
|
||||
|
||||
# CVS - Source Control
|
||||
**/CVS/
|
||||
|
||||
# Remainings from resolving conflicts in Source Control
|
||||
*.orig
|
||||
|
||||
# SQL Server files
|
||||
**/App_Data/*.mdf
|
||||
**/App_Data/*.ldf
|
||||
**/App_Data/*.sdf
|
||||
|
||||
|
||||
#LightSwitch generated files
|
||||
GeneratedArtifacts/
|
||||
_Pvt_Extensions/
|
||||
ModelManifest.xml
|
||||
|
||||
# =========================
|
||||
# Windows detritus
|
||||
# =========================
|
||||
|
||||
# Windows image file caches
|
||||
Thumbs.db
|
||||
ehthumbs.db
|
||||
|
||||
# Folder config file
|
||||
Desktop.ini
|
||||
|
||||
# Recycle Bin used on file shares
|
||||
$RECYCLE.BIN/
|
||||
|
||||
# Mac desktop service store files
|
||||
.DS_Store
|
||||
|
||||
# SASS Compiler cache
|
||||
.sass-cache
|
||||
|
||||
# Visual Studio 2014 CTP
|
||||
**/*.sln.ide
|
||||
|
||||
# Visual Studio temp something
|
||||
.vs/
|
||||
|
||||
# dotnet stuff
|
||||
project.lock.json
|
||||
|
||||
# VS 2015+
|
||||
*.vc.vc.opendb
|
||||
*.vc.db
|
||||
|
||||
# Rider
|
||||
.idea/
|
||||
|
||||
# Visual Studio Code
|
||||
.vscode/
|
||||
|
||||
# Output folder used by Webpack or other FE stuff
|
||||
**/node_modules/*
|
||||
**/wwwroot/*
|
||||
|
||||
# SpecFlow specific
|
||||
*.feature.cs
|
||||
*.feature.xlsx.*
|
||||
*.Specs_*.html
|
||||
|
||||
#####
|
||||
# End of core ignore list, below put you custom 'per project' settings (patterns or path)
|
||||
#####
|
||||
|
||||
key4intranet.sln
|
52
README.md
Normal file
@ -0,0 +1,52 @@
|
||||
# Key4intranet
|
||||
|
||||
## Table des matières
|
||||
|
||||
1. [Description](#Description)
|
||||
2. [Pré-requis](#Pre-requis)
|
||||
3. [Guide d'instalation](#Guide)
|
||||
|
||||
## Description
|
||||
|
||||
Ce projet est un intranet qui permet le téléchargement de fichier avec un système d'authentification.
|
||||
|
||||
Il fonctionne avec les frameworks ASP .net Core 5.0 & Vue.js.
|
||||
|
||||
## Pre-requis
|
||||
|
||||
- Il faut que votre machine possède le framework [ASP .net Core 5.0](https://dotnet.microsoft.com/download/dotnet/5.0) d'installé.
|
||||
- Il faut que votre machine possède le [ASP .net Core runtime](https://dotnet.microsoft.com/download/dotnet/5.0/runtime) d'installé.
|
||||
- Il faut que votre machine possède [node.js](https://nodejs.org/en/download/) d'installé.
|
||||
- Il faut que votre machine possède [Vue.js CLI](https://v3.vuejs.org/guide/installation.html#cli) d'installé.
|
||||
- Il faut que votre machine possède le gestionnaire de version [git](https://git-scm.com/downloads) d'installé.
|
||||
|
||||
|
||||
# Guide
|
||||
|
||||
Vous devez, dans un premier temps, cloner le projet git en tapant dans une invite de commande ou un terminal : ```git clone git@bitbucket.org:key4team/intranet.git```
|
||||
|
||||
Une fois le projet cloné sur votre machine, vous aurez une arborescence similaire à ceci :
|
||||
|
||||
```
|
||||
.
|
||||
├───key4intranet.api
|
||||
└───API files
|
||||
├───key4intranet.auth
|
||||
└───Auth files
|
||||
├───key4intranet.front
|
||||
└───Front-end files
|
||||
└───key4intranet.library
|
||||
└───Document library files
|
||||
```
|
||||
|
||||
## Compilation back-end
|
||||
|
||||
Une fois dans votre projet api/auth, il faut que vous publiez la solution grâce à l'outil de publication graphique intégré à Visual studio. Une fois cette dernière compilée, vous devrez vous rendre dans ``~/key4intranet.api/bin/Release/net5.0/publish/`` et copier l'intégralité des fichiers vers le serveur où sera hébergé l'API.
|
||||
|
||||
## Compilation front-end
|
||||
|
||||
Une fois dans le répertoire ``key4intranet.front``, il suffit de lancer la commande ``npm run build`` pour lancer la compilation. Une fois celle ci terminée, il faut copier l'intégralité des fichiers vers le serveur qui hébergera le front. Ces fichiers, après compilation, seront stockés dans ``~/key4intranet.front/dist/``.
|
||||
|
||||
|
||||
|
||||
|
12
key4intranet.Api/.config/dotnet-tools.json
Normal file
@ -0,0 +1,12 @@
|
||||
{
|
||||
"version": 1,
|
||||
"isRoot": true,
|
||||
"tools": {
|
||||
"dotnet-ef": {
|
||||
"version": "5.0.7",
|
||||
"commands": [
|
||||
"dotnet-ef"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
614
key4intranet.Api/.gitignore
vendored
Normal file
@ -0,0 +1,614 @@
|
||||
## 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/master/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
|
||||
|
||||
# Nuget personal access tokens and Credentials
|
||||
nuget.config
|
||||
|
||||
# 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 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/
|
||||
|
||||
# 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
|
||||
.idea/
|
||||
*.sln.iml
|
||||
|
||||
# The following command works for downloading when using Git for Windows:
|
||||
# curl -LOf http://gist.githubusercontent.com/kmorcinek/2710267/raw/.gitignore
|
||||
#
|
||||
# Download this file using PowerShell v3 under Windows with the following comand:
|
||||
# Invoke-WebRequest https://gist.githubusercontent.com/kmorcinek/2710267/raw/ -OutFile .gitignore
|
||||
#
|
||||
# or wget:
|
||||
# wget --no-check-certificate http://gist.githubusercontent.com/kmorcinek/2710267/raw/.gitignore
|
||||
|
||||
# User-specific files
|
||||
*.suo
|
||||
*.user
|
||||
*.sln.docstates
|
||||
|
||||
# Build results
|
||||
[Dd]ebug/
|
||||
[Rr]elease/
|
||||
x64/
|
||||
[Bb]in/
|
||||
[Oo]bj/
|
||||
# build folder is nowadays used for build scripts and should not be ignored
|
||||
#build/
|
||||
|
||||
# NuGet Packages
|
||||
*.nupkg
|
||||
# The packages folder can be ignored because of Package Restore
|
||||
**/packages/*
|
||||
# except build/, which is used as an MSBuild target.
|
||||
!**/packages/build/
|
||||
# Uncomment if necessary however generally it will be regenerated when needed
|
||||
#!**/packages/repositories.config
|
||||
|
||||
# MSTest test Results
|
||||
[Tt]est[Rr]esult*/
|
||||
[Bb]uild[Ll]og.*
|
||||
|
||||
*_i.c
|
||||
*_p.c
|
||||
*.ilk
|
||||
*.meta
|
||||
*.obj
|
||||
*.pch
|
||||
*.pdb
|
||||
*.pgc
|
||||
*.pgd
|
||||
*.rsp
|
||||
*.sbr
|
||||
*.tlb
|
||||
*.tli
|
||||
*.tlh
|
||||
*.tmp
|
||||
*.tmp_proj
|
||||
*.log
|
||||
*.vspscc
|
||||
*.vssscc
|
||||
.builds
|
||||
*.pidb
|
||||
*.log
|
||||
*.scc
|
||||
|
||||
# OS generated files #
|
||||
.DS_Store*
|
||||
Icon?
|
||||
|
||||
# Visual C++ cache files
|
||||
ipch/
|
||||
*.aps
|
||||
*.ncb
|
||||
*.opensdf
|
||||
*.sdf
|
||||
*.cachefile
|
||||
|
||||
# Visual Studio profiler
|
||||
*.psess
|
||||
*.vsp
|
||||
*.vspx
|
||||
|
||||
# Guidance Automation Toolkit
|
||||
*.gpState
|
||||
|
||||
# ReSharper is a .NET coding add-in
|
||||
_ReSharper*/
|
||||
*.[Rr]e[Ss]harper
|
||||
|
||||
# TeamCity is a build add-in
|
||||
_TeamCity*
|
||||
|
||||
# DotCover is a Code Coverage Tool
|
||||
*.dotCover
|
||||
|
||||
# NCrunch
|
||||
*.ncrunch*
|
||||
.*crunch*.local.xml
|
||||
|
||||
# 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
|
||||
*.Publish.xml
|
||||
|
||||
# Windows Azure Build Output
|
||||
csx
|
||||
*.build.csdef
|
||||
|
||||
# Windows Store app package directory
|
||||
AppPackages/
|
||||
|
||||
# Others
|
||||
*.Cache
|
||||
ClientBin/
|
||||
[Ss]tyle[Cc]op.*
|
||||
~$*
|
||||
*~
|
||||
*.dbmdl
|
||||
*.[Pp]ublish.xml
|
||||
*.pfx
|
||||
*.publishsettings
|
||||
modulesbin/
|
||||
tempbin/
|
||||
|
||||
# EPiServer Site file (VPP)
|
||||
AppData/
|
||||
|
||||
# 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
|
||||
|
||||
# vim
|
||||
*.txt~
|
||||
*.swp
|
||||
*.swo
|
||||
|
||||
# Temp files when opening LibreOffice on ubuntu
|
||||
.~lock.*
|
||||
|
||||
# svn
|
||||
.svn
|
||||
|
||||
# CVS - Source Control
|
||||
**/CVS/
|
||||
|
||||
# Remainings from resolving conflicts in Source Control
|
||||
*.orig
|
||||
|
||||
# SQL Server files
|
||||
**/App_Data/*.mdf
|
||||
**/App_Data/*.ldf
|
||||
**/App_Data/*.sdf
|
||||
|
||||
|
||||
#LightSwitch generated files
|
||||
GeneratedArtifacts/
|
||||
_Pvt_Extensions/
|
||||
ModelManifest.xml
|
||||
|
||||
# =========================
|
||||
# Windows detritus
|
||||
# =========================
|
||||
|
||||
# Windows image file caches
|
||||
Thumbs.db
|
||||
ehthumbs.db
|
||||
|
||||
# Folder config file
|
||||
Desktop.ini
|
||||
|
||||
# Recycle Bin used on file shares
|
||||
$RECYCLE.BIN/
|
||||
|
||||
# Mac desktop service store files
|
||||
.DS_Store
|
||||
|
||||
# SASS Compiler cache
|
||||
.sass-cache
|
||||
|
||||
# Visual Studio 2014 CTP
|
||||
**/*.sln.ide
|
||||
|
||||
# Visual Studio temp something
|
||||
.vs/
|
||||
|
||||
# dotnet stuff
|
||||
project.lock.json
|
||||
|
||||
# VS 2015+
|
||||
*.vc.vc.opendb
|
||||
*.vc.db
|
||||
|
||||
# Rider
|
||||
.idea/
|
||||
|
||||
# Visual Studio Code
|
||||
.vscode/
|
||||
|
||||
# Output folder used by Webpack or other FE stuff
|
||||
**/node_modules/*
|
||||
**/wwwroot/*
|
||||
|
||||
# SpecFlow specific
|
||||
*.feature.cs
|
||||
*.feature.xlsx.*
|
||||
*.Specs_*.html
|
||||
|
||||
#####
|
||||
# End of core ignore list, below put you custom 'per project' settings (patterns or path)
|
||||
#####
|
58
key4intranet.Api/Controllers/AuthenticationController.cs
Normal file
@ -0,0 +1,58 @@
|
||||
using key4intranet.authentication.Models;
|
||||
using key4intranet.authentication.Service;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Identity;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using System;
|
||||
|
||||
namespace key4intranet.Api.Controllers
|
||||
{
|
||||
[ApiController]
|
||||
[Authorize]
|
||||
[Route("api/auth")]
|
||||
public class AuthenticationController : ControllerBase
|
||||
{
|
||||
private readonly ILogger<AuthenticationController> _logger;
|
||||
private readonly IAuthenticationService _authenticationService;
|
||||
|
||||
public AuthenticationController(ILogger<AuthenticationController> logger, IAuthenticationService authenticationService)
|
||||
{
|
||||
_logger = logger ?? throw new ArgumentNullException(nameof(logger));
|
||||
_authenticationService = authenticationService ?? throw new ArgumentNullException(nameof(authenticationService));
|
||||
}
|
||||
|
||||
[AllowAnonymous]
|
||||
[HttpPost]
|
||||
public IActionResult Authenticate([FromBody] PostUserModel model)
|
||||
{
|
||||
if (model == null) { return Unauthorized(); }
|
||||
if (string.IsNullOrWhiteSpace(model.User)) { return Unauthorized(); }
|
||||
if (string.IsNullOrWhiteSpace(model.Pass)) { return Unauthorized(); }
|
||||
|
||||
var user = _authenticationService.Authenticate(model);
|
||||
if (user == null) { return Unauthorized(); }
|
||||
|
||||
var returnUser = new ExposedUserModel
|
||||
{
|
||||
Id = user.Id,
|
||||
Name = user.Name,
|
||||
Roles = user.Roles,
|
||||
};
|
||||
|
||||
var token = _authenticationService.GetToken(user);
|
||||
if (string.IsNullOrWhiteSpace(token)) { return Unauthorized(); }
|
||||
|
||||
returnUser.Token = token;
|
||||
return Ok(returnUser);
|
||||
}
|
||||
|
||||
[HttpPost("encrypt")]
|
||||
public string EncryptPhrase([FromBody] string phrase)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(phrase)) { throw new ArgumentNullException(nameof(phrase)); }
|
||||
|
||||
return (new PasswordHasher<string>()).HashPassword(null, phrase);
|
||||
}
|
||||
}
|
||||
}
|
74
key4intranet.Api/Controllers/DownloadController.cs
Normal file
@ -0,0 +1,74 @@
|
||||
using key4.HttpExceptions;
|
||||
using key4intranet.Api.Docs;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.AspNetCore.StaticFiles;
|
||||
using Newtonsoft.Json;
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace key4intranet.Api.Controllers
|
||||
{
|
||||
|
||||
[ApiController]
|
||||
[Authorize]
|
||||
public class DownloadController : ControllerBase
|
||||
{
|
||||
private readonly IDocumentManager _documentManager;
|
||||
|
||||
public DownloadController(IDocumentManager documentManager)
|
||||
{
|
||||
_documentManager = documentManager ?? throw new ArgumentNullException(nameof(documentManager));
|
||||
}
|
||||
|
||||
[Route("api/download/id/{fileId}/")]
|
||||
public Task<ActionResult> SearchFile(String fileId)
|
||||
{
|
||||
if (_documentManager.dl.HasFile(fileId))
|
||||
{
|
||||
return DownloadFile(_documentManager.dl.GetDocumentFromLibrary(fileId));
|
||||
}
|
||||
else
|
||||
{
|
||||
throw new HttpNotFoundException("error - file not found in library");
|
||||
}
|
||||
}
|
||||
|
||||
[Route("api/download/getLibrary/")]
|
||||
public IActionResult getFilesFromLibraryToJSON()
|
||||
{
|
||||
_documentManager.KnowAllDocuments();
|
||||
return Ok(_documentManager.dl.GetAllDocuments());
|
||||
}
|
||||
|
||||
[Route("api/download/getLibrary/{group}/")]
|
||||
public IActionResult getFilesFromLibraryToJSONwithSpecificDepartment(String group)
|
||||
{
|
||||
_documentManager.KnowAllDocuments();
|
||||
return Ok(_documentManager.dl.GetAllDocumentsFromGroup(_documentManager.GetDepartement(group)));
|
||||
}
|
||||
|
||||
[HttpGet]
|
||||
private async Task<ActionResult> DownloadFile(Document d)
|
||||
{
|
||||
// validation and get the file
|
||||
|
||||
var filePath = d.getPath();
|
||||
if (!System.IO.File.Exists(filePath))
|
||||
{
|
||||
await System.IO.File.WriteAllTextAsync(filePath, d.fileName);
|
||||
}
|
||||
|
||||
var provider = new FileExtensionContentTypeProvider();
|
||||
if (!provider.TryGetContentType(filePath, out var contentType))
|
||||
{
|
||||
contentType = "application/octet-stream";
|
||||
}
|
||||
|
||||
var bytes = await System.IO.File.ReadAllBytesAsync(filePath);
|
||||
return File(bytes, contentType, Path.GetFileName(filePath));
|
||||
}
|
||||
|
||||
}
|
||||
}
|
26
key4intranet.Api/Controllers/EchoController.cs
Normal file
@ -0,0 +1,26 @@
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
|
||||
namespace key4intranet.Api.Controllers
|
||||
{
|
||||
[ApiController]
|
||||
[Authorize]
|
||||
[Route("api/echo")]
|
||||
public class EchoController : ControllerBase
|
||||
{
|
||||
[AllowAnonymous]
|
||||
[HttpGet]
|
||||
public IActionResult GetEcho()
|
||||
{
|
||||
return Ok($"echo { GetProjectName() }");
|
||||
}
|
||||
|
||||
[HttpGet("authorized")]
|
||||
public IActionResult GetAuthorizedEcho()
|
||||
{
|
||||
return Ok($"authorized echo { GetProjectName() }");
|
||||
}
|
||||
|
||||
private string GetProjectName() => this.GetType().Namespace.Split('.')[0];
|
||||
}
|
||||
}
|
15
key4intranet.Api/Docs/Departement.cs
Normal file
@ -0,0 +1,15 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace key4intranet.Api.Docs {
|
||||
public enum Departement {
|
||||
OPERATIONNEL,
|
||||
COMMERCIAL,
|
||||
ADMISTRATIF,
|
||||
DEV,
|
||||
DIRECTION,
|
||||
ERR //only for errors
|
||||
}
|
||||
}
|
44
key4intranet.Api/Docs/Document.cs
Normal file
@ -0,0 +1,44 @@
|
||||
using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Converters;
|
||||
using System;
|
||||
using System.IO;
|
||||
|
||||
namespace key4intranet.Api.Docs {
|
||||
|
||||
[Serializable]
|
||||
public class Document {
|
||||
|
||||
public String id {get;}
|
||||
[JsonIgnore]
|
||||
private FileInfo file; //for back-end usage
|
||||
public String fileName {get;} //for front-end usage
|
||||
public String extension {get;}
|
||||
[JsonConverter(typeof(StringEnumConverter))]
|
||||
public Departement group {get;}
|
||||
public int permissionLevel {get;}
|
||||
|
||||
public Document(String i_d, FileInfo f, Departement depart, int permission_level) {
|
||||
this.id = i_d;
|
||||
this.file = f;
|
||||
this.fileName = f.Name.Split(".")[0].Substring(6);
|
||||
this.extension = f.Extension.Substring(1);
|
||||
this.group = depart;
|
||||
this.permissionLevel = permission_level;
|
||||
}
|
||||
|
||||
public Document() {
|
||||
}
|
||||
|
||||
public String getId() {
|
||||
return this.id;
|
||||
}
|
||||
|
||||
public String getPath() {
|
||||
return this.file.FullName;
|
||||
}
|
||||
|
||||
public Departement getGroup() {
|
||||
return this.group;
|
||||
}
|
||||
}
|
||||
}
|
83
key4intranet.Api/Docs/DocumentLibrary.cs
Normal file
@ -0,0 +1,83 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace key4intranet.Api.Docs {
|
||||
public interface IDocumentLibrary{
|
||||
void resetLibrary();
|
||||
Document GetDocumentFromLibrary(String fileId);
|
||||
Boolean HasFile(String fileId);
|
||||
void addToLibrary(Document d);
|
||||
List<Document> GetAllDocuments();
|
||||
List<Document> GetAllDocumentsFromGroup(Departement departement);
|
||||
Boolean isEmpty();
|
||||
}
|
||||
|
||||
public class DocumentLibrary: IDocumentLibrary
|
||||
{
|
||||
private List<Document> library;
|
||||
|
||||
public DocumentLibrary() {
|
||||
library = new List<Document>();
|
||||
}
|
||||
|
||||
public void resetLibrary() {
|
||||
this.library.Clear();
|
||||
}
|
||||
|
||||
public Document GetDocumentFromLibrary(String fileId) {
|
||||
Document r;
|
||||
if(this.HasFile(fileId)) {
|
||||
int iterator = 0;
|
||||
int index = -1;
|
||||
foreach(Document d in library) {
|
||||
if(d.getId().ToUpper().Equals(fileId.ToUpper())) {
|
||||
index = iterator;
|
||||
}
|
||||
++iterator;
|
||||
}
|
||||
r = library[index];
|
||||
} else {
|
||||
r = new Document();
|
||||
}
|
||||
return r;
|
||||
}
|
||||
|
||||
public Boolean HasFile(String fileId) {
|
||||
Boolean r = false;
|
||||
foreach(Document d in library) {
|
||||
if(d.getId().ToUpper().Equals(fileId.ToUpper())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return r;
|
||||
}
|
||||
|
||||
public void addToLibrary(Document d) {
|
||||
library.Add(d);
|
||||
}
|
||||
|
||||
public List<Document> GetAllDocuments() {
|
||||
return this.library;
|
||||
}
|
||||
|
||||
public List<Document> GetAllDocumentsFromGroup(Departement departement) {
|
||||
List<Document> rl = new List<Document>();
|
||||
List<Document> library = this.GetAllDocuments();
|
||||
|
||||
foreach(Document doc in library) {
|
||||
if(doc.getGroup().Equals(departement)) {
|
||||
rl.Add(doc);
|
||||
}
|
||||
}
|
||||
|
||||
return rl;
|
||||
}
|
||||
|
||||
public Boolean isEmpty() {
|
||||
return (this.library.Count == 0);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
78
key4intranet.Api/Docs/DocumentManager.cs
Normal file
@ -0,0 +1,78 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
|
||||
namespace key4intranet.Api.Docs
|
||||
{
|
||||
public interface IDocumentManager
|
||||
{
|
||||
public DocumentLibrary dl { get; set; }
|
||||
public void KnowAllDocuments();
|
||||
public Departement GetDepartement(String file);
|
||||
}
|
||||
public class DocumentManager : IDocumentManager
|
||||
{
|
||||
private readonly IDocumentPathManager _documentPathManager;
|
||||
public DocumentLibrary dl { get; set; }
|
||||
|
||||
|
||||
public DocumentManager(IDocumentPathManager documentPathManager)
|
||||
{
|
||||
_documentPathManager = documentPathManager ?? throw new ArgumentNullException(nameof(documentPathManager));
|
||||
this.dl = new DocumentLibrary();
|
||||
KnowAllDocuments();
|
||||
}
|
||||
|
||||
public void KnowAllDocuments()
|
||||
{
|
||||
DirectoryInfo d = new DirectoryInfo(_documentPathManager.KnowFolder());
|
||||
List<FileInfo> files = new List<FileInfo>(d.GetFiles("*.*", SearchOption.AllDirectories));
|
||||
if (!dl.isEmpty())
|
||||
{
|
||||
dl.resetLibrary();
|
||||
}
|
||||
|
||||
foreach (FileInfo file in files)
|
||||
{
|
||||
if (!(file.Name.ToLower().Contains(".git")))
|
||||
{
|
||||
dl.addToLibrary(new Document(GenerateID(file.Name), file, GetDepartement(file.Name), 1));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public Departement GetDepartement(String file)
|
||||
{
|
||||
String check;
|
||||
if (file.Length >= 3)
|
||||
{
|
||||
check = file.Substring(0, 3).ToUpper();
|
||||
}
|
||||
else
|
||||
{
|
||||
check = "ERR";
|
||||
}
|
||||
switch (check)
|
||||
{
|
||||
case "OPE":
|
||||
return Departement.OPERATIONNEL;
|
||||
case "COM":
|
||||
return Departement.COMMERCIAL;
|
||||
case "ADM":
|
||||
return Departement.ADMISTRATIF;
|
||||
case "DEV":
|
||||
return Departement.DEV;
|
||||
case "DIR":
|
||||
return Departement.DIRECTION;
|
||||
default:
|
||||
return Departement.ERR;
|
||||
}
|
||||
}
|
||||
|
||||
private String GenerateID(String file)
|
||||
{
|
||||
return file.Substring(0, 3).ToUpper() + file.Substring(3, 3);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
41
key4intranet.Api/Docs/DocumentPathManager.cs
Normal file
@ -0,0 +1,41 @@
|
||||
using Microsoft.Extensions.Configuration;
|
||||
using System;
|
||||
|
||||
|
||||
namespace key4intranet.Api.Docs{
|
||||
public interface IDocumentPathManager
|
||||
{
|
||||
String BuildFullPathToFile(String fileName, String format);
|
||||
public String BuildFullPathToFile(String subFolderPath, String fileName, String format);
|
||||
public String KnowFolder();
|
||||
}
|
||||
|
||||
public class DocumentPathManager : IDocumentPathManager
|
||||
{
|
||||
|
||||
private readonly String sourceFolderPath;
|
||||
private readonly String ressourcesPath;
|
||||
|
||||
public DocumentPathManager(IConfiguration config)
|
||||
{
|
||||
sourceFolderPath = config.GetSection("Settings:sourceFolderPath").Value;
|
||||
ressourcesPath = config.GetSection("Settings:ressourcesPath").Value;
|
||||
}
|
||||
|
||||
private String BuildFileName(String fileName, String format) {
|
||||
return fileName + "." + format.ToLower();
|
||||
}
|
||||
|
||||
public String BuildFullPathToFile(String fileName, String format) {
|
||||
return BuildFullPathToFile("", fileName, format);
|
||||
}
|
||||
|
||||
public String BuildFullPathToFile(String subFolderPath, String fileName, String format) {
|
||||
return sourceFolderPath + ressourcesPath + subFolderPath + BuildFileName(fileName, format);
|
||||
}
|
||||
|
||||
public String KnowFolder() {
|
||||
return sourceFolderPath + ressourcesPath;
|
||||
}
|
||||
}
|
||||
}
|
24
key4intranet.Api/Program.cs
Normal file
@ -0,0 +1,24 @@
|
||||
using Microsoft.AspNetCore.Hosting;
|
||||
using Microsoft.Extensions.Hosting;
|
||||
|
||||
|
||||
namespace key4intranet.Api
|
||||
{
|
||||
public class Program
|
||||
{
|
||||
|
||||
public static void Main(string[] args)
|
||||
{
|
||||
CreateHostBuilder(args).Build().Run();
|
||||
}
|
||||
|
||||
public static IHostBuilder CreateHostBuilder(string[] args) =>
|
||||
Host.CreateDefaultBuilder(args)
|
||||
.ConfigureWebHostDefaults(webBuilder =>
|
||||
{
|
||||
webBuilder.UseStartup<Startup>();
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
}
|
31
key4intranet.Api/Properties/launchSettings.json
Normal file
@ -0,0 +1,31 @@
|
||||
{
|
||||
"$schema": "http://json.schemastore.org/launchsettings.json",
|
||||
"iisSettings": {
|
||||
"windowsAuthentication": false,
|
||||
"anonymousAuthentication": true,
|
||||
"iisExpress": {
|
||||
"applicationUrl": "http://localhost:56455",
|
||||
"sslPort": 44385
|
||||
}
|
||||
},
|
||||
"profiles": {
|
||||
"IIS Express": {
|
||||
"commandName": "IISExpress",
|
||||
"launchBrowser": true,
|
||||
"launchUrl": "api/echo",
|
||||
"environmentVariables": {
|
||||
"ASPNETCORE_ENVIRONMENT": "Development"
|
||||
}
|
||||
},
|
||||
"key4intranet.Api": {
|
||||
"commandName": "Project",
|
||||
"dotnetRunMessages": "true",
|
||||
"launchBrowser": true,
|
||||
"launchUrl": "api/echo",
|
||||
"applicationUrl": "https://localhost:5001;http://localhost:5000",
|
||||
"environmentVariables": {
|
||||
"ASPNETCORE_ENVIRONMENT": "Development"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
54
key4intranet.Api/Startup.cs
Normal file
@ -0,0 +1,54 @@
|
||||
using Microsoft.AspNetCore.Builder;
|
||||
using Microsoft.AspNetCore.Hosting;
|
||||
using Microsoft.Extensions.Configuration;
|
||||
using key4intranet.authentication;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.Extensions.Hosting;
|
||||
using key4.AspNetCore.ExceptionHandler.Middleware;
|
||||
using key4intranet.Api.Docs;
|
||||
|
||||
namespace key4intranet.Api {
|
||||
public class Startup {
|
||||
|
||||
public Startup(IConfiguration configuration) {
|
||||
Configuration = configuration;
|
||||
}
|
||||
|
||||
public IConfiguration Configuration {
|
||||
get;
|
||||
}
|
||||
|
||||
// This method gets called by the runtime. Use this method to add services to the container.
|
||||
public void ConfigureServices(IServiceCollection services) {
|
||||
services.AddControllers();
|
||||
|
||||
services.AddAuthenticationServicesCollection();
|
||||
|
||||
services.AddScoped<IDocumentPathManager, DocumentPathManager>();
|
||||
services.AddScoped<IDocumentManager, DocumentManager>();
|
||||
}
|
||||
|
||||
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
|
||||
public void Configure(IApplicationBuilder app, IWebHostEnvironment env) {
|
||||
if(env.IsDevelopment()) {
|
||||
app.UseDeveloperExceptionPage();
|
||||
}
|
||||
app.UseApiExceptionHandler();
|
||||
app.UseHttpsRedirection();
|
||||
|
||||
app.UseRouting();
|
||||
|
||||
app.UseCors(x => x
|
||||
.AllowAnyOrigin()
|
||||
.AllowAnyMethod()
|
||||
.AllowAnyHeader());
|
||||
|
||||
app.UseAuthentication();
|
||||
app.UseAuthorization();
|
||||
|
||||
app.UseEndpoints(endpoints => {
|
||||
endpoints.MapControllers();
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
9
key4intranet.Api/appsettings.Development.json
Normal file
@ -0,0 +1,9 @@
|
||||
{
|
||||
"Logging": {
|
||||
"LogLevel": {
|
||||
"Default": "Information",
|
||||
"Microsoft": "Warning",
|
||||
"Microsoft.Hosting.Lifetime": "Information"
|
||||
}
|
||||
}
|
||||
}
|
26
key4intranet.Api/appsettings.json
Normal file
@ -0,0 +1,26 @@
|
||||
{
|
||||
"Logging": {
|
||||
"LogLevel": {
|
||||
"Default": "Information",
|
||||
"Microsoft": "Warning",
|
||||
"Microsoft.Hosting.Lifetime": "Information"
|
||||
}
|
||||
},
|
||||
"Settings": {
|
||||
"sourceFolderPath": "localhost\\key4intranet",
|
||||
"ressourcesPath": "\\key4intranet.library\\"
|
||||
},
|
||||
"Authentication": {
|
||||
"JwtIssuer": "api.key4intranet.key4events.com",
|
||||
"Entities": [
|
||||
{
|
||||
"Id": "30ea838e-8e26-4bda-9eec-71d06b2ae1bb",
|
||||
"Mail": "dev@itzpompom.fr",
|
||||
"Pass": "AQAAAAEAACcQAAAAEI/jgRnG93m/EROa8A5pt6JF8kSMEngLokdkV2DO/1mTNBXytIR1+NwrUD/J/VgpMQ==",
|
||||
"Name": "PomPom",
|
||||
"Roles": [ "KEY4ADMIN" ]
|
||||
}
|
||||
]
|
||||
},
|
||||
"AllowedHosts": "*"
|
||||
}
|
17
key4intranet.Api/key4intranet.Api.csproj
Normal file
@ -0,0 +1,17 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk.Web">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net5.0</TargetFramework>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="key4.AspNetCore.ExceptionHandler" Version="5.0.0" />
|
||||
<PackageReference Include="Key4.AspNetCore.HttpExceptions" Version="5.0.0" />
|
||||
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\key4intranet.authentication\key4intranet.authentication.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
452
key4intranet.authentication/.gitignore
vendored
Normal file
@ -0,0 +1,452 @@
|
||||
# These are some examples of commonly ignored file patterns.
|
||||
# You should customize this list as applicable to your project.
|
||||
# Learn more about .gitignore:
|
||||
# https://www.atlassian.com/git/tutorials/saving-changes/gitignore
|
||||
|
||||
/.vs/
|
||||
/.vs/*
|
||||
|
||||
# Node artifact files
|
||||
node_modules/
|
||||
dist/
|
||||
|
||||
# Compiled Java class files
|
||||
*.class
|
||||
|
||||
# Compiled Python bytecode
|
||||
*.py[cod]
|
||||
|
||||
# Log files
|
||||
*.log
|
||||
|
||||
# Package files
|
||||
*.jar
|
||||
|
||||
# Maven
|
||||
target/
|
||||
dist/
|
||||
|
||||
# JetBrains IDE
|
||||
.idea/
|
||||
|
||||
# Unit test reports
|
||||
TEST*.xml
|
||||
|
||||
# Generated by MacOS
|
||||
.DS_Store
|
||||
|
||||
# Generated by Windows
|
||||
Thumbs.db
|
||||
|
||||
# Applications
|
||||
*.app
|
||||
*.exe
|
||||
*.war
|
||||
|
||||
# Large media files
|
||||
*.mp4
|
||||
*.tiff
|
||||
*.avi
|
||||
*.flv
|
||||
*.mov
|
||||
*.wmv
|
||||
|
||||
# Library files
|
||||
|
||||
*.pdf
|
||||
*.doc
|
||||
*.docx
|
||||
*.cache
|
||||
|
||||
# Api cache
|
||||
key4intranet.Api/obj/*
|
||||
|
||||
## 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/master/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
|
||||
|
||||
# Nuget personal access tokens and Credentials
|
||||
nuget.config
|
||||
|
||||
# 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 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/
|
||||
|
||||
# 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
|
||||
.idea/
|
||||
*.sln.iml
|
||||
|
41
key4intranet.authentication/DependanciesCollection.cs
Normal file
@ -0,0 +1,41 @@
|
||||
using key4intranet.authentication.Providers.Jwt;
|
||||
using key4intranet.authentication.Service;
|
||||
using Microsoft.AspNetCore.Authentication.JwtBearer;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.IdentityModel.Tokens;
|
||||
using System;
|
||||
|
||||
namespace key4intranet.authentication
|
||||
{
|
||||
public static class DependanciesCollection
|
||||
{
|
||||
public static IServiceCollection AddAuthenticationServicesCollection(this IServiceCollection services)
|
||||
{
|
||||
services.AddScoped<IAuthenticationService, AuthenticationService>();
|
||||
|
||||
// Configure Authentication
|
||||
services.AddAuthentication(x =>
|
||||
{
|
||||
x.DefaultAuthenticateScheme = JwtBearerDefaults.AuthenticationScheme;
|
||||
x.DefaultChallengeScheme = JwtBearerDefaults.AuthenticationScheme;
|
||||
})
|
||||
// Configure JWT
|
||||
.AddJwtBearer(x =>
|
||||
{
|
||||
x.RequireHttpsMetadata = false;
|
||||
x.SaveToken = true;
|
||||
x.TokenValidationParameters = new TokenValidationParameters
|
||||
{
|
||||
ClockSkew = TimeSpan.Zero,
|
||||
ValidateIssuerSigningKey = true,
|
||||
IssuerSigningKey = new SymmetricSecurityKey(JwtTokenProvider.SignatureKey),
|
||||
ValidateIssuer = true,
|
||||
ValidIssuer = JwtTokenProvider.Issuer,
|
||||
ValidateAudience = false
|
||||
};
|
||||
});
|
||||
|
||||
return services;
|
||||
}
|
||||
}
|
||||
}
|
14
key4intranet.authentication/Models/ExposedUserModel.cs
Normal file
@ -0,0 +1,14 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace key4intranet.authentication.Models
|
||||
{
|
||||
public class ExposedUserModel
|
||||
{
|
||||
public string Id { get; set; }
|
||||
public string Name { get; set; }
|
||||
public List<string> Roles { get; set; }
|
||||
public string Token { get; set; }
|
||||
}
|
||||
}
|
8
key4intranet.authentication/Models/PostUserModel.cs
Normal file
@ -0,0 +1,8 @@
|
||||
namespace key4intranet.authentication.Models
|
||||
{
|
||||
public class PostUserModel
|
||||
{
|
||||
public string User { get; set; }
|
||||
public string Pass { get; set; }
|
||||
}
|
||||
}
|
13
key4intranet.authentication/Models/StoredUserModel.cs
Normal file
@ -0,0 +1,13 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace key4intranet.authentication.Models
|
||||
{
|
||||
public class StoredUserModel
|
||||
{
|
||||
public string Id { get; set; }
|
||||
public string Mail { get; set; }
|
||||
public string Pass { get; set; }
|
||||
public string Name { get; set; }
|
||||
public List<string> Roles { get; set; }
|
||||
}
|
||||
}
|
35
key4intranet.authentication/Providers/ITokenProvider.cs
Normal file
@ -0,0 +1,35 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace key4intranet.authentication.Providers
|
||||
{
|
||||
public interface ITokenProvider
|
||||
{
|
||||
/// <summary>
|
||||
/// Create a token with list of private claim
|
||||
/// </summary>
|
||||
/// <param name="claims">claims</param>
|
||||
/// <returns>encrypt token</returns>
|
||||
string CreateToken(IDictionary<string, object> claims);
|
||||
/// <summary>
|
||||
/// Create a token with list claims, there be public or private
|
||||
/// </summary>
|
||||
/// <param name="privateClaims">Private claims</param>
|
||||
/// <param name="publicClaims">Public claims</param>
|
||||
/// <returns>Encrypt token</returns>
|
||||
string CreateToken(IDictionary<string, object> privateClaims, IDictionary<string, object> publicClaims);
|
||||
/// <summary>
|
||||
/// Get claims from token
|
||||
/// </summary>
|
||||
/// <param name="token">token</param>
|
||||
/// <returns>List of claims</returns>
|
||||
IDictionary<string, object> ReadClaims(string token);
|
||||
/// <summary>
|
||||
/// Is token valide
|
||||
/// </summary>
|
||||
/// <param name="token">token</param>
|
||||
/// <returns>true is token is valid</returns>
|
||||
Boolean ValidateToken(string token);
|
||||
}
|
||||
}
|
101
key4intranet.authentication/Providers/Jwt/JwtTokenProvider.cs
Normal file
@ -0,0 +1,101 @@
|
||||
using Microsoft.IdentityModel.Tokens;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IdentityModel.Tokens.Jwt;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Security.Claims;
|
||||
using System.Text;
|
||||
|
||||
namespace key4intranet.authentication.Providers.Jwt
|
||||
{
|
||||
public class JwtTokenProvider : ITokenProvider
|
||||
{
|
||||
public static byte[] SignatureKey { get; } = Encoding.ASCII.GetBytes(Guid.NewGuid().ToString());
|
||||
public static string Issuer { get; set; } = "https://api.key4intranet.key4events.com";
|
||||
|
||||
/// <summary>
|
||||
/// Create a JWT with private and public claims
|
||||
/// </summary>
|
||||
/// <param name="privateClaims">private claims</param>
|
||||
/// <param name="publicClaims">public claims</param>
|
||||
/// <returns>token</returns>
|
||||
public string CreateToken(IDictionary<string, object> privateClaims, IDictionary<string, object> publicClaims)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Create a JWT with list of private claim
|
||||
/// </summary>
|
||||
/// <param name="claims">claims</param>
|
||||
/// <returns>encrypt token</returns>
|
||||
public string CreateToken(IDictionary<string, object> claims)
|
||||
{
|
||||
//private claims can't not be empty
|
||||
if (claims == null || claims.Count == 0)
|
||||
throw new IOException($"private claims can't be null or empty.");
|
||||
|
||||
var tokenDescriptor = (new SecurityTokenDescriptor()
|
||||
{
|
||||
Issuer = Issuer,
|
||||
Expires = DateTime.UtcNow.AddMinutes(120),
|
||||
SigningCredentials = new SigningCredentials(new SymmetricSecurityKey(SignatureKey), SecurityAlgorithms.HmacSha256Signature),
|
||||
Subject = new ClaimsIdentity()
|
||||
});
|
||||
|
||||
// Registrered claims
|
||||
foreach (var item in claims)
|
||||
{
|
||||
// identifier
|
||||
if (new List<string>() { "name", "id" }.Contains(item.Key.ToLower())) tokenDescriptor.Subject.AddClaim(new Claim(ClaimTypes.Name, item.Value.ToString()));
|
||||
// roles
|
||||
else if (new List<string>() { "role", "roles" }.Contains(item.Key.ToLower()))
|
||||
if (item.Value is IEnumerable<string> roles)
|
||||
foreach (string role in roles)
|
||||
tokenDescriptor.Subject.AddClaim(new Claim(ClaimTypes.Role, role));
|
||||
else
|
||||
tokenDescriptor.Subject.AddClaim(new Claim(ClaimTypes.Role, item.Value.ToString()));
|
||||
// issuer
|
||||
else if (new List<string>() { "iss", "issuer" }.Contains(item.Key.ToLower())) tokenDescriptor.Issuer = item.Value.ToString();
|
||||
//audience
|
||||
else if (new List<string>() { "aud", "audience" }.Contains(item.Key.ToLower())) tokenDescriptor.Audience = item.Value.ToString();
|
||||
|
||||
}
|
||||
|
||||
|
||||
var handler = new JwtSecurityTokenHandler();
|
||||
var token = handler.CreateToken(tokenDescriptor);
|
||||
|
||||
return handler.WriteToken(token);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Get claims from token
|
||||
/// </summary>
|
||||
/// <param name="token">token</param>
|
||||
/// <returns>List of claims</returns>
|
||||
public IDictionary<string, object> ReadClaims(string token)
|
||||
{
|
||||
if (token == null)
|
||||
throw new ArgumentNullException("Token is null.");
|
||||
|
||||
var handler = new JwtSecurityTokenHandler();
|
||||
if (!handler.CanReadToken(token))
|
||||
throw new ArgumentException("Can't read token.");
|
||||
|
||||
var jwtToken = handler.ReadJwtToken(token);
|
||||
return (IDictionary<string, object>)jwtToken.Claims.ToDictionary(c => c.Type, c => (object)c.Value);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// For JWT => Bearer extention will validate token
|
||||
/// </summary>
|
||||
/// <param name="token">jwt token</param>
|
||||
/// <returns>true if valid</returns>
|
||||
public bool ValidateToken(string token)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
50
key4intranet.authentication/Service/AuthenticationService.cs
Normal file
@ -0,0 +1,50 @@
|
||||
using key4intranet.authentication.Models;
|
||||
using Microsoft.AspNetCore.Identity;
|
||||
using Microsoft.Extensions.Configuration;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace key4intranet.authentication.Service
|
||||
{
|
||||
public interface IAuthenticationService
|
||||
{
|
||||
StoredUserModel Authenticate(PostUserModel login);
|
||||
string GetToken(StoredUserModel user);
|
||||
}
|
||||
|
||||
public class AuthenticationService : IAuthenticationService
|
||||
{
|
||||
private readonly ILogger<AuthenticationService> _logger;
|
||||
private readonly List<StoredUserModel> _users;
|
||||
|
||||
public AuthenticationService(ILogger<AuthenticationService> logger, IConfiguration configuration)
|
||||
{
|
||||
_logger = logger ?? throw new ArgumentNullException(nameof(logger));
|
||||
_users = configuration.GetSection("Authentication:Entities").Get<List<StoredUserModel>>() ?? throw new ArgumentNullException("ConfigUserList");
|
||||
}
|
||||
|
||||
public StoredUserModel Authenticate(PostUserModel login)
|
||||
{
|
||||
var user = _users.Find(u => u.Mail == login.User);
|
||||
if (user != null && CheckPassword(login, user))
|
||||
{
|
||||
return user;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public string GetToken(StoredUserModel user)
|
||||
{
|
||||
_ = user ?? throw new ArgumentNullException(nameof(user));
|
||||
var provider = new TokenProviderService().GetTokenProvider(TokenProviderService.TokenType.JWT);
|
||||
return provider.CreateToken(new Dictionary<string, object>() { { "ID", user.Mail }, { "Roles", user.Roles } });
|
||||
|
||||
}
|
||||
|
||||
private bool CheckPassword(PostUserModel submitUser, StoredUserModel storedUser)
|
||||
{
|
||||
return (new PasswordHasher<string>()).VerifyHashedPassword(null, storedUser.Pass, submitUser.Pass) == PasswordVerificationResult.Success;
|
||||
}
|
||||
}
|
||||
}
|
25
key4intranet.authentication/Service/TokenProviderService.cs
Normal file
@ -0,0 +1,25 @@
|
||||
using key4intranet.authentication.Providers;
|
||||
using key4intranet.authentication.Providers.Jwt;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace key4intranet.authentication.Service
|
||||
{
|
||||
public class TokenProviderService
|
||||
{
|
||||
public enum TokenType
|
||||
{
|
||||
JWT
|
||||
}
|
||||
|
||||
public ITokenProvider GetTokenProvider(TokenType type)
|
||||
{
|
||||
return type switch
|
||||
{
|
||||
TokenType.JWT => (ITokenProvider)new JwtTokenProvider(),
|
||||
_ => null,
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,11 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net5.0</TargetFramework>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.AspNetCore.Authentication.JwtBearer" Version="5.0.5" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
1
key4intranet.front/.env
Normal file
@ -0,0 +1 @@
|
||||
VUE_APP_API_URL_BASE=http://localhost:8090/
|
1
key4intranet.front/.env.development
Normal file
@ -0,0 +1 @@
|
||||
VUE_APP_API_URL_BASE=https://localhost:44385/
|
23
key4intranet.front/.gitignore
vendored
Normal file
@ -0,0 +1,23 @@
|
||||
.DS_Store
|
||||
node_modules
|
||||
/dist
|
||||
|
||||
|
||||
# local env files
|
||||
.env.local
|
||||
.env.*.local
|
||||
|
||||
# Log files
|
||||
npm-debug.log*
|
||||
yarn-debug.log*
|
||||
yarn-error.log*
|
||||
pnpm-debug.log*
|
||||
|
||||
# Editor directories and files
|
||||
.idea
|
||||
.vscode
|
||||
*.suo
|
||||
*.ntvs*
|
||||
*.njsproj
|
||||
*.sln
|
||||
*.sw?
|
24
key4intranet.front/README.md
Normal file
@ -0,0 +1,24 @@
|
||||
# key4intranet.front
|
||||
|
||||
## Project setup
|
||||
```
|
||||
npm install
|
||||
```
|
||||
|
||||
### Compiles and hot-reloads for development
|
||||
```
|
||||
npm run serve
|
||||
```
|
||||
|
||||
### Compiles and minifies for production
|
||||
```
|
||||
npm run build
|
||||
```
|
||||
|
||||
### Lints and fixes files
|
||||
```
|
||||
npm run lint
|
||||
```
|
||||
|
||||
### Customize configuration
|
||||
See [Configuration Reference](https://cli.vuejs.org/config/).
|
5
key4intranet.front/babel.config.js
Normal file
@ -0,0 +1,5 @@
|
||||
module.exports = {
|
||||
"presets": [
|
||||
"@vue/cli-plugin-babel/preset"
|
||||
]
|
||||
}
|
12323
key4intranet.front/package-lock.json
generated
Normal file
62
key4intranet.front/package.json
Normal file
@ -0,0 +1,62 @@
|
||||
{
|
||||
"name": "key4intranet.front",
|
||||
"version": "0.1.0",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"serve": "vue-cli-service serve",
|
||||
"build": "vue-cli-service build",
|
||||
"lint": "vue-cli-service lint"
|
||||
},
|
||||
"dependencies": {
|
||||
"@fortawesome/fontawesome-svg-core": "^1.2.35",
|
||||
"@fortawesome/free-solid-svg-icons": "^5.15.3",
|
||||
"bootstrap-vue": "^2.17.3",
|
||||
"core-js": "^3.6.5",
|
||||
"js-file-download": "^0.4.12",
|
||||
"react": "^17.0.2",
|
||||
"vue": "^2.6.12",
|
||||
"vue-meta": "^2.4.0",
|
||||
"vue-router": "^3.2.0",
|
||||
"vuex": "^3.4.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/polyfill": "^7.11.5",
|
||||
"@vue/cli-plugin-babel": "~4.5.0",
|
||||
"@vue/cli-plugin-eslint": "~4.5.0",
|
||||
"@vue/cli-plugin-router": "^4.5.12",
|
||||
"@vue/cli-plugin-vuex": "^4.5.12",
|
||||
"@vue/cli-service": "~4.5.0",
|
||||
"axios": "^0.21.1",
|
||||
"babel-eslint": "^10.1.0",
|
||||
"bootstrap": "^4.5.2",
|
||||
"eslint": "^6.7.2",
|
||||
"eslint-plugin-vue": "^6.2.2",
|
||||
"mutationobserver-shim": "^0.3.7",
|
||||
"popper.js": "^1.16.1",
|
||||
"portal-vue": "^2.1.7",
|
||||
"sass": "^1.26.11",
|
||||
"sass-loader": "^10.0.2",
|
||||
"vue-cli-plugin-axios": "0.0.4",
|
||||
"vue-cli-plugin-bootstrap-vue": "^0.7.0",
|
||||
"vue-template-compiler": "^2.6.11"
|
||||
},
|
||||
"eslintConfig": {
|
||||
"root": true,
|
||||
"env": {
|
||||
"node": true
|
||||
},
|
||||
"extends": [
|
||||
"plugin:vue/essential",
|
||||
"eslint:recommended"
|
||||
],
|
||||
"parserOptions": {
|
||||
"parser": "babel-eslint"
|
||||
},
|
||||
"rules": {}
|
||||
},
|
||||
"browserslist": [
|
||||
"> 1%",
|
||||
"last 2 versions",
|
||||
"not dead"
|
||||
]
|
||||
}
|
320
key4intranet.front/public/assets/css/additionalStyles.css
Normal file
@ -0,0 +1,320 @@
|
||||
i.sidebarIcons {
|
||||
/* class created to use and style font awesome's icons same as k4's svg library (../images/sprites.svg) */
|
||||
position: absolute;
|
||||
left: 24px;
|
||||
font-size: 30px;
|
||||
transition: all 0.15s ease;
|
||||
display: inline-block;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
div#title {
|
||||
/*apply a little wide spece at the bottom of the div with the "title" id*/
|
||||
margin: 0px 0px 20px 0px;
|
||||
}
|
||||
|
||||
|
||||
/*For reduced menu*/
|
||||
|
||||
i.ifhidden {
|
||||
color: transparent;
|
||||
transition: all 0.15s ease;
|
||||
}
|
||||
|
||||
@media (min-width: 992px) {
|
||||
/*For active buttons on the menus*/
|
||||
body.esp-cl.reduced-menu-left nav.menu-left a#active i {
|
||||
color: #fff !important;
|
||||
}
|
||||
/*For inactive buttons on the menus*/
|
||||
body.esp-cl.reduced-menu-left nav.menu-left a.text-original i,
|
||||
body.esp-cl.reduced-menu-left nav.menu-left a.text-truncate i {
|
||||
color: #2c4698 !important;
|
||||
}
|
||||
/*For inactive buttons on the menus*/
|
||||
body.esp-cl.reduced-menu-left nav.menu-left a.text-original i.ifhidden,
|
||||
body.esp-cl.reduced-menu-left nav.menu-left a.text-truncate i.ifhidden {
|
||||
color: #2c4698 !important;
|
||||
transition: all 0.15s ease;
|
||||
}
|
||||
/*When the menu is reduced, it replace the arrow by another fa-icon*/
|
||||
body.esp-cl.reduced-menu-left nav.menu-left a.text-original i.little,
|
||||
body.esp-cl.reduced-menu-left nav.menu-left a.text-truncate i.little {
|
||||
display: none;
|
||||
}
|
||||
body.esp-cl.reduced-menu-left nav.menu-left ul li a {
|
||||
max-width: 80px;
|
||||
padding: 1.45rem;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*end of reduced menu*/
|
||||
|
||||
|
||||
/*for tiles*/
|
||||
|
||||
h3.section {
|
||||
font-weight: bolder;
|
||||
}
|
||||
|
||||
h3.section,
|
||||
h5.section {
|
||||
color: #fff;
|
||||
display: grid;
|
||||
place-items: center;
|
||||
}
|
||||
|
||||
i.section {
|
||||
color: #fff;
|
||||
display: grid;
|
||||
place-items: center;
|
||||
font-size: 100px;
|
||||
transition: all 0.15s ease;
|
||||
margin-top: 10px;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
.sectionLine {
|
||||
position: relative;
|
||||
padding-bottom: 10px;
|
||||
}
|
||||
|
||||
.sectionLine::after {
|
||||
display: grid;
|
||||
position: absolute;
|
||||
place-items: center;
|
||||
content: '';
|
||||
z-index: 1;
|
||||
bottom: 0;
|
||||
width: 70%;
|
||||
height: 2px;
|
||||
background-color: rgba(255, 255, 255, 0.3);
|
||||
}
|
||||
|
||||
p.section {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
|
||||
/*end of tiles*/
|
||||
|
||||
|
||||
/*for sub-menu*/
|
||||
|
||||
a.active#active {
|
||||
color: #0000ff !important;
|
||||
}
|
||||
|
||||
li.submenu,
|
||||
a.submenu {
|
||||
max-height: 30px;
|
||||
}
|
||||
|
||||
body.esp-cl nav.menu-left ul li.submenu a:not(.bg-gradient)::before a.submenu:hover {
|
||||
max-height: 30px;
|
||||
}
|
||||
|
||||
body.esp-cl nav.menu-left ul li.submenu a:not(.bg-gradient):hover::before {
|
||||
width: 100%;
|
||||
max-height: 30px;
|
||||
margin-top: 14px;
|
||||
}
|
||||
|
||||
body.esp-cl nav.menu-left ul li.submenu a:not(.bg-gradient)::before {
|
||||
width: 100%;
|
||||
max-height: 30px;
|
||||
margin-top: 14px;
|
||||
box-shadow: 0 16px 30px rgb(0 0 0 / 0%) !important;
|
||||
}
|
||||
|
||||
body.esp-cl nav.menu-left ul li.submenu2 a:not(.bg-gradient)::before {
|
||||
/*for 2 lines*/
|
||||
width: 100%;
|
||||
max-height: 55px;
|
||||
margin-top: 14px;
|
||||
box-shadow: 0 16px 30px rgb(0 0 0 / 0%) !important;
|
||||
}
|
||||
|
||||
|
||||
/*end of sub-menu*/
|
||||
|
||||
|
||||
/*for boxes on each pages*/
|
||||
|
||||
@media (min-width: 1660px) {
|
||||
/*2 triple sections*/
|
||||
body.esp-cl ul.tiles li.onlineLarge {
|
||||
flex: 0 0 50%;
|
||||
max-width: 50%;
|
||||
}
|
||||
body.esp-cl ul.tiles li.onsiteLarge {
|
||||
flex: 0 0 50%;
|
||||
max-width: 50%;
|
||||
}
|
||||
body.esp-cl ul.tiles li.onlineSoftware {
|
||||
/*Software pages*/
|
||||
flex: 0 0 20%;
|
||||
max-width: 20%;
|
||||
}
|
||||
body.esp-cl ul.tiles li.onsiteSoftware {
|
||||
flex: 0 0 80%;
|
||||
max-width: 80%;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-width: 1660px) {
|
||||
/*One single section*/
|
||||
body.esp-cl ul.tiles li.onlineSolo {
|
||||
flex: 0 0 100%;
|
||||
max-width: 100%;
|
||||
}
|
||||
body.esp-cl ul.tiles li.onsiteSolo {
|
||||
flex: 0 0 100%;
|
||||
max-width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*end of boxex*/
|
||||
|
||||
|
||||
/*tools & logo*/
|
||||
|
||||
div#logoContainer {
|
||||
display: grid;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
div.sectionLogo {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
img.toolsLogo {
|
||||
width: 200px;
|
||||
transition: all 0.25s ease;
|
||||
border-radius: 10%;
|
||||
margin: 20px 20px 20px 20px;
|
||||
opacity: 0.9;
|
||||
}
|
||||
|
||||
img.toolsLogo:hover {
|
||||
transform: scale(1.15);
|
||||
transition: all 0.25s ease;
|
||||
border-radius: 10%;
|
||||
margin: 15px 15px 15px 15px;
|
||||
box-shadow: 0 0 10px 5px rgba(11, 60, 110, 0.5);
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
div.logoContainer {
|
||||
color: #0b3c6e;
|
||||
}
|
||||
|
||||
div.logoContainer span {
|
||||
position: absolute;
|
||||
margin-top: 6.5rem;
|
||||
margin-left: -9%;
|
||||
padding: .3rem;
|
||||
text-align: center;
|
||||
color: #000;
|
||||
box-shadow: 10px 10px 5px rgba(136, 136, 136, 0.336);
|
||||
border: 1px;
|
||||
border-radius: 15px;
|
||||
background: radial-gradient(0px 0px, rgba(255, 255, 255, 1), rgba(255, 255, 255, 0.7));
|
||||
transform: scale(0) rotate(-15deg);
|
||||
transition: all .3s;
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
div.logoContainer:hover span,
|
||||
div.logoContainer:focus span {
|
||||
transform: scale(1);
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
a.softwareLink {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
|
||||
/*end of tools and logo*/
|
||||
|
||||
|
||||
/*For /tools/softwareName.html */
|
||||
|
||||
img.softwareLogo {
|
||||
border-radius: 10%;
|
||||
}
|
||||
|
||||
@media (min-width: 1701px) {
|
||||
/*One single section*/
|
||||
img.softwareLogo {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 1700px) {
|
||||
/*One single section*/
|
||||
img.softwareLogo {
|
||||
width: 20%;
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 1440px) {
|
||||
/*One single section*/
|
||||
img.softwareLogo {
|
||||
width: 20%;
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 990px) {
|
||||
/*One single section*/
|
||||
img.softwareLogo {
|
||||
width: 20%;
|
||||
}
|
||||
}
|
||||
|
||||
h3.software,
|
||||
h5.software {
|
||||
color: #000;
|
||||
}
|
||||
|
||||
.softwareLine {
|
||||
position: relative;
|
||||
padding-bottom: 10px;
|
||||
}
|
||||
|
||||
.softwareLine::after {
|
||||
display: grid;
|
||||
position: absolute;
|
||||
place-items: center;
|
||||
content: '';
|
||||
z-index: 1;
|
||||
bottom: 0;
|
||||
width: 90%;
|
||||
height: 2px;
|
||||
background-color: rgba(34, 34, 34, 0.3);
|
||||
}
|
||||
|
||||
|
||||
/* End of /tools/softwareName.html */
|
||||
|
||||
|
||||
/* for profile type in <header> */
|
||||
|
||||
img.namePP {
|
||||
width: 28px;
|
||||
margin-right: 5px;
|
||||
border-radius: 50%;
|
||||
}
|
||||
|
||||
span#WorkerName {
|
||||
color: #2f85b3 !important;
|
||||
}
|
||||
|
||||
|
||||
/* end for profile type in <header> */
|
652
key4intranet.front/public/assets/css/bootstrap-select.key4.css
vendored
Normal file
@ -0,0 +1,652 @@
|
||||
@charset "UTF-8";
|
||||
@keyframes bs-notify-fadeOut {
|
||||
0% {
|
||||
opacity: 0.9;
|
||||
}
|
||||
100% {
|
||||
opacity: 0;
|
||||
}
|
||||
}
|
||||
|
||||
select.bs-select-hidden,
|
||||
.bootstrap-select>select.bs-select-hidden,
|
||||
select.selectpicker {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.bootstrap-select {
|
||||
width: 220px \0;
|
||||
/*IE9 and below*/
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.bootstrap-select>.dropdown-toggle {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
text-align: right;
|
||||
white-space: nowrap;
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.bootstrap-select>.dropdown-toggle:after {
|
||||
margin-top: -1px;
|
||||
}
|
||||
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder:hover,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder:focus,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder:active {
|
||||
color: #999;
|
||||
}
|
||||
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-primary,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-primary:hover,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-primary:focus,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-primary:active,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-secondary,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-secondary:hover,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-secondary:focus,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-secondary:active,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-success,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-success:hover,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-success:focus,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-success:active,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-danger,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-danger:hover,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-danger:focus,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-danger:active,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-info,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-info:hover,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-info:focus,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-info:active,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-dark,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-dark:hover,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-dark:focus,
|
||||
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-dark:active {
|
||||
color: rgba(255, 255, 255, 0.5);
|
||||
}
|
||||
|
||||
.bootstrap-select>select {
|
||||
position: absolute !important;
|
||||
bottom: 0;
|
||||
left: 50%;
|
||||
display: block !important;
|
||||
width: 0.5px !important;
|
||||
height: 100% !important;
|
||||
padding: 0 !important;
|
||||
opacity: 0 !important;
|
||||
border: none;
|
||||
z-index: 0 !important;
|
||||
}
|
||||
|
||||
.bootstrap-select>select.mobile-device {
|
||||
top: 0;
|
||||
left: 0;
|
||||
display: block !important;
|
||||
width: 100% !important;
|
||||
z-index: 2 !important;
|
||||
}
|
||||
|
||||
.has-error .bootstrap-select .dropdown-toggle,
|
||||
.error .bootstrap-select .dropdown-toggle,
|
||||
.bootstrap-select.is-invalid .dropdown-toggle,
|
||||
.was-validated .bootstrap-select select:invalid+.dropdown-toggle {
|
||||
border-color: #b94a48;
|
||||
}
|
||||
|
||||
.bootstrap-select.is-valid .dropdown-toggle,
|
||||
.was-validated .bootstrap-select select:valid+.dropdown-toggle {
|
||||
border-color: #28a745;
|
||||
}
|
||||
|
||||
.bootstrap-select.fit-width {
|
||||
width: auto !important;
|
||||
}
|
||||
|
||||
.bootstrap-select:not([class*="col-"]):not([class*="form-control"]):not(.input-group-btn) {
|
||||
width: 220px;
|
||||
}
|
||||
|
||||
.bootstrap-select>select.mobile-device:focus+.dropdown-toggle,
|
||||
.bootstrap-select .dropdown-toggle:focus {
|
||||
outline: thin dotted #333333 !important;
|
||||
outline: 5px auto -webkit-focus-ring-color !important;
|
||||
outline-offset: -2px;
|
||||
}
|
||||
|
||||
.bootstrap-select.form-control {
|
||||
margin-bottom: 0;
|
||||
padding: 0;
|
||||
border: none;
|
||||
height: auto;
|
||||
}
|
||||
|
||||
:not(.input-group)>.bootstrap-select.form-control:not([class*="col-"]) {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.bootstrap-select.form-control.input-group-btn {
|
||||
float: none;
|
||||
z-index: auto;
|
||||
}
|
||||
|
||||
.form-inline .bootstrap-select,
|
||||
.form-inline .bootstrap-select.form-control:not([class*="col-"]) {
|
||||
width: auto;
|
||||
}
|
||||
|
||||
.bootstrap-select:not(.input-group-btn),
|
||||
.bootstrap-select[class*="col-"] {
|
||||
float: none;
|
||||
display: inline-block;
|
||||
margin-left: 0;
|
||||
}
|
||||
|
||||
.bootstrap-select.dropdown-menu-right,
|
||||
.bootstrap-select[class*="col-"].dropdown-menu-right,
|
||||
.row .bootstrap-select[class*="col-"].dropdown-menu-right {
|
||||
float: right;
|
||||
}
|
||||
|
||||
.form-inline .bootstrap-select,
|
||||
.form-horizontal .bootstrap-select,
|
||||
.form-group .bootstrap-select {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.form-group-lg .bootstrap-select.form-control,
|
||||
.form-group-sm .bootstrap-select.form-control {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.form-group-lg .bootstrap-select.form-control .dropdown-toggle,
|
||||
.form-group-sm .bootstrap-select.form-control .dropdown-toggle {
|
||||
height: 100%;
|
||||
font-size: inherit;
|
||||
line-height: inherit;
|
||||
border-radius: inherit;
|
||||
}
|
||||
|
||||
.bootstrap-select.form-control-sm .dropdown-toggle,
|
||||
.bootstrap-select.form-control-lg .dropdown-toggle {
|
||||
font-size: inherit;
|
||||
line-height: inherit;
|
||||
border-radius: inherit;
|
||||
}
|
||||
|
||||
.bootstrap-select.form-control-sm .dropdown-toggle {
|
||||
padding: 0.25rem 0.5rem;
|
||||
}
|
||||
|
||||
.bootstrap-select.form-control-lg .dropdown-toggle {
|
||||
padding: 0.5rem 1rem;
|
||||
}
|
||||
|
||||
.form-inline .bootstrap-select .form-control {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.bootstrap-select.disabled,
|
||||
.bootstrap-select>.disabled {
|
||||
cursor: not-allowed;
|
||||
}
|
||||
|
||||
.bootstrap-select.disabled:focus,
|
||||
.bootstrap-select>.disabled:focus {
|
||||
outline: none !important;
|
||||
}
|
||||
|
||||
.bootstrap-select.bs-container {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
height: 0 !important;
|
||||
padding: 0 !important;
|
||||
}
|
||||
|
||||
.bootstrap-select.bs-container .dropdown-menu {
|
||||
z-index: 1060;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-toggle .filter-option {
|
||||
position: static;
|
||||
top: 0;
|
||||
left: 0;
|
||||
float: left;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
text-align: left;
|
||||
overflow: hidden;
|
||||
flex: 0 1 auto;
|
||||
}
|
||||
|
||||
.bs3.bootstrap-select .dropdown-toggle .filter-option {
|
||||
padding-right: inherit;
|
||||
}
|
||||
|
||||
.input-group .bs3-has-addon.bootstrap-select .dropdown-toggle .filter-option {
|
||||
position: absolute;
|
||||
padding-top: inherit;
|
||||
padding-bottom: inherit;
|
||||
padding-left: inherit;
|
||||
float: none;
|
||||
}
|
||||
|
||||
.input-group .bs3-has-addon.bootstrap-select .dropdown-toggle .filter-option .filter-option-inner {
|
||||
padding-right: inherit;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-toggle .filter-option-inner-inner {
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-toggle .filter-expand {
|
||||
width: 0 !important;
|
||||
float: left;
|
||||
opacity: 0 !important;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-toggle .caret {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
right: 12px;
|
||||
margin-top: -2px;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.input-group .bootstrap-select.form-control .dropdown-toggle {
|
||||
border-radius: inherit;
|
||||
}
|
||||
|
||||
.bootstrap-select[class*="col-"] .dropdown-toggle {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu {
|
||||
min-width: 100%;
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu>.inner:focus {
|
||||
outline: none !important;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu.inner {
|
||||
position: static;
|
||||
float: none;
|
||||
border: 0;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
border-radius: 0;
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu li {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu li.active small {
|
||||
color: rgba(255, 255, 255, 0.5) !important;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu li.disabled a {
|
||||
cursor: not-allowed;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu li a {
|
||||
cursor: pointer;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu li a.opt {
|
||||
position: relative;
|
||||
padding-left: 2.25em;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu li a span.check-mark {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu li a span.text {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu li small {
|
||||
padding-left: 0.5em;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu .notify {
|
||||
position: absolute;
|
||||
bottom: 5px;
|
||||
width: 96%;
|
||||
margin: 0 2%;
|
||||
min-height: 26px;
|
||||
padding: 3px 5px;
|
||||
background: whitesmoke;
|
||||
border: 1px solid #e3e3e3;
|
||||
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05);
|
||||
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05);
|
||||
pointer-events: none;
|
||||
opacity: 0.9;
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu .notify.fadeOut {
|
||||
animation: 300ms linear 750ms forwards bs-notify-fadeOut;
|
||||
}
|
||||
|
||||
.bootstrap-select .no-results {
|
||||
padding: 3px;
|
||||
background: #f5f5f5;
|
||||
margin: 0 5px;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.bootstrap-select.fit-width .dropdown-toggle .filter-option {
|
||||
position: static;
|
||||
display: inline;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.bootstrap-select.fit-width .dropdown-toggle .filter-option-inner,
|
||||
.bootstrap-select.fit-width .dropdown-toggle .filter-option-inner-inner {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
.bootstrap-select.fit-width .dropdown-toggle .bs-caret:before {
|
||||
content: '\00a0';
|
||||
}
|
||||
|
||||
.bootstrap-select.fit-width .dropdown-toggle .caret {
|
||||
position: static;
|
||||
top: auto;
|
||||
margin-top: -1px;
|
||||
}
|
||||
|
||||
.bootstrap-select.show-tick .dropdown-menu .selected span.check-mark {
|
||||
position: absolute;
|
||||
display: inline-block;
|
||||
right: 15px;
|
||||
top: 5px;
|
||||
}
|
||||
|
||||
.bootstrap-select.show-tick .dropdown-menu li a span.text {
|
||||
margin-right: 34px;
|
||||
}
|
||||
|
||||
.bootstrap-select .bs-ok-default:after {
|
||||
content: '';
|
||||
display: block;
|
||||
width: 0.5em;
|
||||
height: 1em;
|
||||
border-style: solid;
|
||||
border-width: 0 0.26em 0.26em 0;
|
||||
transform: rotate(45deg);
|
||||
}
|
||||
|
||||
.bootstrap-select.show-menu-arrow.open>.dropdown-toggle,
|
||||
.bootstrap-select.show-menu-arrow.show>.dropdown-toggle {
|
||||
z-index: 1061;
|
||||
}
|
||||
|
||||
.bootstrap-select.show-menu-arrow .dropdown-toggle .filter-option:before {
|
||||
content: '';
|
||||
border-left: 7px solid transparent;
|
||||
border-right: 7px solid transparent;
|
||||
border-bottom: 7px solid rgba(204, 204, 204, 0.2);
|
||||
position: absolute;
|
||||
bottom: -4px;
|
||||
left: 9px;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.bootstrap-select.show-menu-arrow .dropdown-toggle .filter-option:after {
|
||||
content: '';
|
||||
border-left: 6px solid transparent;
|
||||
border-right: 6px solid transparent;
|
||||
border-bottom: 6px solid white;
|
||||
position: absolute;
|
||||
bottom: -4px;
|
||||
left: 10px;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.bootstrap-select.show-menu-arrow.dropup .dropdown-toggle .filter-option:before {
|
||||
bottom: auto;
|
||||
top: -4px;
|
||||
border-top: 7px solid rgba(204, 204, 204, 0.2);
|
||||
border-bottom: 0;
|
||||
}
|
||||
|
||||
.bootstrap-select.show-menu-arrow.dropup .dropdown-toggle .filter-option:after {
|
||||
bottom: auto;
|
||||
top: -4px;
|
||||
border-top: 6px solid white;
|
||||
border-bottom: 0;
|
||||
}
|
||||
|
||||
.bootstrap-select.show-menu-arrow.pull-right .dropdown-toggle .filter-option:before {
|
||||
right: 12px;
|
||||
left: auto;
|
||||
}
|
||||
|
||||
.bootstrap-select.show-menu-arrow.pull-right .dropdown-toggle .filter-option:after {
|
||||
right: 13px;
|
||||
left: auto;
|
||||
}
|
||||
|
||||
.bootstrap-select.show-menu-arrow.open>.dropdown-toggle .filter-option:before,
|
||||
.bootstrap-select.show-menu-arrow.open>.dropdown-toggle .filter-option:after,
|
||||
.bootstrap-select.show-menu-arrow.show>.dropdown-toggle .filter-option:before,
|
||||
.bootstrap-select.show-menu-arrow.show>.dropdown-toggle .filter-option:after {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.bs-searchbox,
|
||||
.bs-actionsbox,
|
||||
.bs-donebutton {
|
||||
padding: 4px 8px;
|
||||
}
|
||||
|
||||
.bs-actionsbox {
|
||||
width: 100%;
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.bs-actionsbox .btn-group button {
|
||||
width: 50%;
|
||||
}
|
||||
|
||||
.bs-donebutton {
|
||||
float: left;
|
||||
width: 100%;
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.bs-donebutton .btn-group button {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.bs-searchbox+.bs-actionsbox {
|
||||
padding: 0 8px 4px;
|
||||
}
|
||||
|
||||
.bs-searchbox .form-control {
|
||||
margin-bottom: 0;
|
||||
width: 100%;
|
||||
float: none;
|
||||
}
|
||||
|
||||
.bs-searchbox::after {
|
||||
display: block;
|
||||
position: absolute;
|
||||
content: '\f002';
|
||||
top: 16px;
|
||||
right: 12px;
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
text-align: center;
|
||||
font-family: 'Font Awesome 5 Pro';
|
||||
font-weight: 400;
|
||||
font-size: 1.3rem;
|
||||
opacity: .25;
|
||||
}
|
||||
|
||||
select.bs-select {
|
||||
max-width: 100%;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.bootstrap-select {
|
||||
height: auto !important;
|
||||
padding-right: 0 !important;
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
.bootstrap-select.is-invalid,
|
||||
.bootstrap-select.is-valid {
|
||||
background-position: right calc(2.4em + 0.1875rem) center !important;
|
||||
background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem) !important;
|
||||
}
|
||||
|
||||
.input-group .bootstrap-select.is-invalid,
|
||||
.input-group .bootstrap-select.is-valid {
|
||||
background-position: right calc(4em + 0.1875rem) center !important;
|
||||
}
|
||||
|
||||
.bootstrap-select.is-invalid.custom-select-sm,
|
||||
.bootstrap-select.is-valid.custom-select-sm {
|
||||
background-size: calc(0.5em + 0.375rem) calc(0.5em + 0.375rem) !important;
|
||||
}
|
||||
|
||||
.input-group .bootstrap-select.is-invalid.custom-select-sm,
|
||||
.input-group .bootstrap-select.is-valid.custom-select-sm {
|
||||
background-position: right calc(3.4em + 0.1875rem) center !important;
|
||||
}
|
||||
|
||||
.bootstrap-select.is-invalid.custom-select-lg,
|
||||
.bootstrap-select.is-valid.custom-select-lg {
|
||||
background-size: calc(1em + 0.375rem) calc(1em + 0.375rem) !important;
|
||||
}
|
||||
|
||||
.input-group .bootstrap-select.is-invalid.custom-select-lg,
|
||||
.input-group .bootstrap-select.is-valid.custom-select-lg {
|
||||
background-position: right calc(4.4em + 0.1875rem) center !important;
|
||||
}
|
||||
|
||||
.bootstrap-select.is-invalid .dropdown-toggle,
|
||||
.bootstrap-select.is-valid .dropdown-toggle {
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
.bootstrap-select+a {
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.bootstrap-select>select.mobile-device:focus+.dropdown-toggle,
|
||||
.bootstrap-select .dropdown-toggle:focus {
|
||||
outline: 0 !important;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.bootstrap-select>.dropdown-toggle::after {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.bootstrap-select>.dropdown-toggle .filter-option-inner-inner {
|
||||
max-height: 1.6rem;
|
||||
white-space: pre-wrap;
|
||||
}
|
||||
|
||||
.bootstrap-select.custom-select-sm>.dropdown-toggle {
|
||||
font-size: .855rem !important;
|
||||
line-height: 1.6rem;
|
||||
}
|
||||
|
||||
.bootstrap-select.custom-select-lg>.dropdown-toggle {
|
||||
font-size: 1.15rem !important;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu {
|
||||
z-index: 10000;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu li a {
|
||||
max-width: 95vw;
|
||||
padding: .35rem 1.5rem;
|
||||
white-space: initial;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu li a .icon {
|
||||
width: 24px;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu li a .text {
|
||||
color: black !important;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu li a:active .text {
|
||||
color: white !important;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu li.selected a,
|
||||
.bootstrap-select .dropdown-menu li.selected a .text,
|
||||
.bootstrap-select .dropdown-menu li.active a,
|
||||
.bootstrap-select .dropdown-menu li.active a .text {
|
||||
color: white !important;
|
||||
}
|
||||
|
||||
.bootstrap-select .dropdown-menu li.disabled {
|
||||
opacity: .6;
|
||||
}
|
||||
|
||||
.bootstrap-select.custom-select-sm,
|
||||
.bootstrap-select.custom-select-lg {
|
||||
height: inherit;
|
||||
padding: inherit;
|
||||
font-size: inherit;
|
||||
}
|
||||
|
||||
.bootstrap-select.custom-select-sm .custom-select {
|
||||
height: calc(1.5em + .8rem + 2px);
|
||||
padding-top: .4rem;
|
||||
padding-bottom: .4rem;
|
||||
padding-left: 1.05rem;
|
||||
font-size: .8em;
|
||||
}
|
||||
|
||||
.bootstrap-select.custom-select-sm .dropdown-menu {
|
||||
font-size: .855rem;
|
||||
}
|
||||
|
||||
.bootstrap-select.custom-select-lg .custom-select {
|
||||
height: calc(2.5em + .56rem + 2px);
|
||||
padding-top: .28rem;
|
||||
padding-bottom: .28rem;
|
||||
padding-left: 1.7rem;
|
||||
font-size: 1.15em;
|
||||
}
|
||||
|
||||
.bootstrap-select.disabled .dropdown-toggle,
|
||||
.bootstrap-select>.disabled .dropdown-toggle {
|
||||
color: #6c757d;
|
||||
background-color: #e9ecef;
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
.bootstrap-select[class*="col-"] {
|
||||
padding-left: 0;
|
||||
padding-right: 0;
|
||||
}
|
11260
key4intranet.front/public/assets/css/bootstrap.key4.css
vendored
Normal file
154
key4intranet.front/public/assets/css/flickity.css
Normal file
@ -0,0 +1,154 @@
|
||||
/*! Flickity v2.2.1
|
||||
https://flickity.metafizzy.co
|
||||
---------------------------------------------- */
|
||||
|
||||
.flickity-enabled {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.flickity-enabled:focus {
|
||||
outline: none;
|
||||
}
|
||||
|
||||
.flickity-viewport {
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.flickity-slider {
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
|
||||
/* draggable */
|
||||
|
||||
.flickity-enabled.is-draggable {
|
||||
-webkit-tap-highlight-color: transparent;
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.flickity-enabled.is-draggable .flickity-viewport {
|
||||
cursor: move;
|
||||
cursor: -webkit-grab;
|
||||
cursor: grab;
|
||||
}
|
||||
|
||||
.flickity-enabled.is-draggable .flickity-viewport.is-pointer-down {
|
||||
cursor: -webkit-grabbing;
|
||||
cursor: grabbing;
|
||||
}
|
||||
|
||||
|
||||
/* ---- flickity-button ---- */
|
||||
|
||||
.flickity-button {
|
||||
position: absolute;
|
||||
background: hsla(0, 0%, 100%, 0.75);
|
||||
border: none;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.flickity-button:hover {
|
||||
background: white;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.flickity-button:focus {
|
||||
outline: none;
|
||||
box-shadow: 0 0 0 5px #19F;
|
||||
}
|
||||
|
||||
.flickity-button:active {
|
||||
opacity: 0.6;
|
||||
}
|
||||
|
||||
.flickity-button:disabled {
|
||||
opacity: 0.3;
|
||||
cursor: auto;
|
||||
/* prevent disabled button from capturing pointer up event. #716 */
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.flickity-button-icon {
|
||||
fill: currentColor;
|
||||
}
|
||||
|
||||
|
||||
/* ---- previous/next buttons ---- */
|
||||
|
||||
.flickity-prev-next-button {
|
||||
top: 50%;
|
||||
width: 44px;
|
||||
height: 44px;
|
||||
border-radius: 50%;
|
||||
/* vertically center */
|
||||
transform: translateY(-50%);
|
||||
}
|
||||
|
||||
.flickity-prev-next-button.previous {
|
||||
left: 10px;
|
||||
}
|
||||
|
||||
.flickity-prev-next-button.next {
|
||||
right: 10px;
|
||||
}
|
||||
|
||||
|
||||
/* right to left */
|
||||
|
||||
.flickity-rtl .flickity-prev-next-button.previous {
|
||||
left: auto;
|
||||
right: 10px;
|
||||
}
|
||||
|
||||
.flickity-rtl .flickity-prev-next-button.next {
|
||||
right: auto;
|
||||
left: 10px;
|
||||
}
|
||||
|
||||
.flickity-prev-next-button .flickity-button-icon {
|
||||
position: absolute;
|
||||
left: 20%;
|
||||
top: 20%;
|
||||
width: 60%;
|
||||
height: 60%;
|
||||
}
|
||||
|
||||
|
||||
/* ---- page dots ---- */
|
||||
|
||||
.flickity-page-dots {
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
bottom: -25px;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
list-style: none;
|
||||
text-align: center;
|
||||
line-height: 1;
|
||||
}
|
||||
|
||||
.flickity-rtl .flickity-page-dots {
|
||||
direction: rtl;
|
||||
}
|
||||
|
||||
.flickity-page-dots .dot {
|
||||
display: inline-block;
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
margin: 0 8px;
|
||||
background: #333;
|
||||
border-radius: 50%;
|
||||
opacity: 0.25;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.flickity-page-dots .dot.is-selected {
|
||||
opacity: 1;
|
||||
}
|
16970
key4intranet.front/public/assets/css/fontawesome.key4.css
Normal file
9749
key4intranet.front/public/assets/css/key4.css
Normal file
15299
key4intranet.front/public/assets/fonts/font-awesome/fa-duotone-900.svg
Normal file
After Width: | Height: | Size: 2.5 MiB |
12397
key4intranet.front/public/assets/fonts/font-awesome/fa-light-300.svg
Normal file
After Width: | Height: | Size: 2.3 MiB |
11299
key4intranet.front/public/assets/fonts/font-awesome/fa-regular-400.svg
Normal file
After Width: | Height: | Size: 2.1 MiB |
9634
key4intranet.front/public/assets/fonts/font-awesome/fa-solid-900.svg
Normal file
After Width: | Height: | Size: 1.7 MiB |
BIN
key4intranet.front/public/assets/icons/doc.ico
Normal file
After Width: | Height: | Size: 26 KiB |
BIN
key4intranet.front/public/assets/icons/docx.ico
Normal file
After Width: | Height: | Size: 26 KiB |
BIN
key4intranet.front/public/assets/icons/gif.ico
Normal file
After Width: | Height: | Size: 19 KiB |
BIN
key4intranet.front/public/assets/icons/ico.ico
Normal file
After Width: | Height: | Size: 19 KiB |
BIN
key4intranet.front/public/assets/icons/jpeg.ico
Normal file
After Width: | Height: | Size: 19 KiB |
BIN
key4intranet.front/public/assets/icons/jpg.ico
Normal file
After Width: | Height: | Size: 19 KiB |
BIN
key4intranet.front/public/assets/icons/odc.ico
Normal file
After Width: | Height: | Size: 21 KiB |
BIN
key4intranet.front/public/assets/icons/odt.ico
Normal file
After Width: | Height: | Size: 20 KiB |
BIN
key4intranet.front/public/assets/icons/pdf.ico
Normal file
After Width: | Height: | Size: 27 KiB |
BIN
key4intranet.front/public/assets/icons/png.ico
Normal file
After Width: | Height: | Size: 19 KiB |
BIN
key4intranet.front/public/assets/icons/ppt.ico
Normal file
After Width: | Height: | Size: 23 KiB |
BIN
key4intranet.front/public/assets/icons/pptx.ico
Normal file
After Width: | Height: | Size: 23 KiB |
BIN
key4intranet.front/public/assets/icons/svg.ico
Normal file
After Width: | Height: | Size: 19 KiB |
BIN
key4intranet.front/public/assets/icons/txt.ico
Normal file
After Width: | Height: | Size: 6.1 KiB |
BIN
key4intranet.front/public/assets/icons/xls.ico
Normal file
After Width: | Height: | Size: 21 KiB |
BIN
key4intranet.front/public/assets/icons/xlsx.ico
Normal file
After Width: | Height: | Size: 21 KiB |
BIN
key4intranet.front/public/assets/icons/zip.ico
Normal file
After Width: | Height: | Size: 23 KiB |
2
key4intranet.front/public/assets/images/error.svg
Normal file
After Width: | Height: | Size: 41 KiB |
BIN
key4intranet.front/public/assets/images/flags.png
Normal file
After Width: | Height: | Size: 20 KiB |
BIN
key4intranet.front/public/assets/images/flags@2x.png
Normal file
After Width: | Height: | Size: 52 KiB |
After Width: | Height: | Size: 52 KiB |
1
key4intranet.front/public/assets/images/logo_loader.svg
Normal file
After Width: | Height: | Size: 16 KiB |