Ajout article v3

This commit is contained in:
jleroy
2024-04-24 12:14:46 +02:00
parent 79fc4ce674
commit 6dea07d370
10 changed files with 222 additions and 103 deletions

View File

@@ -19,7 +19,7 @@ public class WebSecurityConfig{
.requestMatchers("/", "/accueil").permitAll()
.requestMatchers("/accueil", "/login", "/inscription/**", "/searchArticle", "/article/**", "/change-language").permitAll()
.requestMatchers("/css/**", "/images/**", "/assets/**", "/img/**", "/js/**", "/assets/**").permitAll()
.requestMatchers("/profil/**", "/article/new/**", "/article/update", "/article/delete").authenticated()
.requestMatchers("/profil/**", "/article/new/**").authenticated()
.requestMatchers("/admin").hasRole("ADMIN")
.anyRequest().authenticated())
.formLogin((form) -> form.loginPage("/login").defaultSuccessUrl("/", true))