Nav fixed

main
Paul Schneider 1 year ago
parent 55623410ab
commit f14b44ecd0
7 changed files with 22 additions and 38 deletions

@ -4,11 +4,14 @@ namespace Yavsc
{ {
public class GoogleAuthSettings public class GoogleAuthSettings
{ {
public string ClientId { get; set; }
public string ClientSecret { get; set; }
public string ApiKey { get; set; } public string ApiKey { get; set; }
public string BrowserApiKey { get; set; } public string BrowserApiKey { get; set; }
public string GoogleServiceAccountJson { get; set; } public string GoogleServiceAccountJson { get; set; }
public string GoogleWebClientJson { get; set; } public string GoogleWebClientJson { get; set; }
} }
} }

@ -137,6 +137,8 @@ internal static class HostingExtensions
var siteSection = builder.Configuration.GetSection("Site"); var siteSection = builder.Configuration.GetSection("Site");
var smtpSection = builder.Configuration.GetSection("Smtp"); var smtpSection = builder.Configuration.GetSection("Smtp");
var paypalSection = builder.Configuration.GetSection("Authentication:PayPal"); var paypalSection = builder.Configuration.GetSection("Authentication:PayPal");
// OAuth2AppSettings
var googleAuthSettings = builder.Configuration.GetSection("Authentication:Google");
string? googleClientFile = builder.Configuration["Authentication:Google:GoogleWebClientJson"]; string? googleClientFile = builder.Configuration["Authentication:Google:GoogleWebClientJson"];
string? googleServiceAccountJsonFile = builder.Configuration["Authentication:Google:GoogleServiceAccountJson"]; string? googleServiceAccountJsonFile = builder.Configuration["Authentication:Google:GoogleServiceAccountJson"];
@ -157,6 +159,7 @@ internal static class HostingExtensions
services.Configure<SiteSettings>(siteSection); services.Configure<SiteSettings>(siteSection);
services.Configure<SmtpSettings>(smtpSection); services.Configure<SmtpSettings>(smtpSection);
services.Configure<PayPalSettings>(paypalSection); services.Configure<PayPalSettings>(paypalSection);
services.Configure<GoogleAuthSettings>(googleAuthSettings);
services.AddRazorPages(); services.AddRazorPages();
services.AddSignalR(o => services.AddSignalR(o =>

@ -27,6 +27,7 @@ using Google.Apis.Auth.OAuth2.Responses;
namespace Yavsc.Services namespace Yavsc.Services
{ {
using Microsoft.Extensions.Options;
using Yavsc.Models.Calendar; using Yavsc.Models.Calendar;
using Yavsc.Server.Helpers; using Yavsc.Server.Helpers;
using Yavsc.Server.Models.Calendar; using Yavsc.Server.Models.Calendar;
@ -46,10 +47,10 @@ namespace Yavsc.Services
readonly string _client_id; readonly string _client_id;
readonly string _client_secret; readonly string _client_secret;
public CalendarManager(ILoggerFactory loggerFactory) public CalendarManager(ILoggerFactory loggerFactory, IOptions<GoogleAuthSettings> googleAuthSettings)
{ {
_client_id = Config.GoogleWebClientConfiguration["web:cient_id"]; _client_id = googleAuthSettings.Value.ClientId;
_client_secret = Config.GoogleWebClientConfiguration["web:cient_secret"]; _client_secret = googleAuthSettings.Value.ClientSecret;
_logger = loggerFactory.CreateLogger<CalendarManager>(); _logger = loggerFactory.CreateLogger<CalendarManager>();
} }

@ -105,26 +105,10 @@
} }
<asciidoc> <asciidoc>
Hello Forgejo !!!
Je sais que j'ai un mauvais à priori sur "go", = Hey
mais là, bon,
le CI façon woodpecker, sous Debian, le serveur SEGFAULT, Hello !!!
dans la stack au "go" ... no comment.
donc pas de CI pour le moment,
mais je garde l'option Forgejo,
Le theme de couleur, il y est pas,
mais l'IHM, la fonction, l'´erogonomie y sont.
J'ai du ramer un peu pour installer ma version compilée, docker, j'en veux pas,
et sans lui, la procédure en place semble cassée.
À la place, j'ai identifié les dossiers à deployer, et tout semble ok :
https://forgejo.pschneider.fr/[Mon nouveau SI de tickets, je l´adopte, il fonctionne, les inscriptions sont ouvertes, et libres.]
</asciidoc> </asciidoc>

@ -38,7 +38,6 @@
&copy; 2024 - Yavsc - <a asp-area="" asp-controller="Home" asp-action="Privacy">Privacy</a> &copy; 2024 - Yavsc - <a asp-area="" asp-controller="Home" asp-action="Privacy">Privacy</a>
</div> </div>
</footer> </footer>
<script src="~/lib/bootstrap/dist/js/bootstrap.bundle.min.js"></script>
<script src="~/lib/jquery/dist/jquery.slim.min.js"></script> <script src="~/lib/jquery/dist/jquery.slim.min.js"></script>
<script src="~/lib/bootstrap/dist/js/bootstrap.bundle.min.js"></script> <script src="~/lib/bootstrap/dist/js/bootstrap.bundle.min.js"></script>
<script src="~/js/site.js" asp-append-version="true"></script> <script src="~/js/site.js" asp-append-version="true"></script>

@ -24,10 +24,10 @@
</li> </li>
@if (User.IsInRole(Constants.AdminGroupName)) { @if (User.IsInRole(Constants.AdminGroupName)) {
<li class="nav-item dropdown"> <li class="nav-item dropdown">
<a class="nav-link dropdown-toggle" href="#" id="dropdown04" data-bs-toggle="dropdown" aria-expanded="false"> <a class="nav-link dropdown-toggle" href="#" id="dropdown05" data-bs-toggle="dropdown" aria-expanded="false">
Administration Administration
</a> </a>
<ul class="dropdown-menu"> <ul class="dropdown-menu" aria-labelledby="dropdown05">
<li><a class="dropdown-item" asp-controller="Administration" asp-action="Index">Index</a></li> <li><a class="dropdown-item" asp-controller="Administration" asp-action="Index">Index</a></li>
<li><a class="dropdown-item" asp-controller="Activity" asp-action="Index">Activités</a></li> <li><a class="dropdown-item" asp-controller="Activity" asp-action="Index">Activités</a></li>
<li><a class="dropdown-item" asp-controller="CommandForms" asp-action="Index">Formulaires</a></li> <li><a class="dropdown-item" asp-controller="CommandForms" asp-action="Index">Formulaires</a></li>

@ -1,6 +1,6 @@
<nav class="navbar navbar-dark bg-dark" aria-label="Yavsc"> <nav class="navbar navbar-expand-sm navbar-dark bg-dark" aria-label="Yavsc">
<div class="container-fluid">
<a href="~/" class="navbar-brand"><img src="~/images/it/free-sofware.svg" class="icon-banner" alt="Lua"></a> <a href="~/" class="navbar-brand"><img src="~/images/it/free-sofware.svg" class="icon-banner" alt="Lua"></a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" <button class="navbar-toggler" type="button" data-bs-toggle="collapse"
@ -10,22 +10,16 @@
</button> </button>
<div class="collapse navbar-collapse" id="navbar"> <div class="collapse navbar-collapse" id="navbar">
<ul class="navbar-nav me-auto mb-2 mb-md-0"> <ul class="navbar-nav me-auto" >
<li class="nav-item"> <li class="nav-item"><a class="nav-link active" aria-current="page" href="/">Home</a></li>
<a class="nav-link active" aria-current="page" href="/">Home</a> <li class="nav-item"><a asp-controller="Blogspot" asp-action="Index" class="nav-link">@SR["Blogs"]</a></li>
</li>
<li class="nav-item">
<a asp-controller="Blogspot" asp-action="Index" class="nav-link">@SR["Blogs"]</a>
</li>
<li class="nav-item"><a asp-controller="Home" asp-action="Chat" class="nav-link">@SR["Chat"]</a></li> <li class="nav-item"><a asp-controller="Home" asp-action="Chat" class="nav-link">@SR["Chat"]</a></li>
<li class="nav-item"><a asp-controller="Home" asp-action="Contact" class="nav-link">@SR["Contact"]</a></li> <li class="nav-item"><a asp-controller="Home" asp-action="Contact" class="nav-link">@SR["Contact"]</a></li>
<li> <li class="nav-item"><a asp-controller="Home" asp-action="About" class="nav-link">@SR["About"]</a></li>
<a asp-controller="Home" asp-action="About" class="nav-link">@SR["About"]</a></li>
<partial name="_LoginPartial" /> <partial name="_LoginPartial" />
</ul> </ul>
</div> </div>
</div>
</nav> </nav>

Loading…