2 Commits

Author SHA1 Message Date
b3c1e10da6 reajustement workflow 2026-08-05 20:45:44 +01:00
b0e0caf3bb reajustement workflow
All checks were successful
CI - Build & Test (develop) / build-and-test (pull_request) Successful in 35s
2026-08-05 19:20:16 +01:00
2 changed files with 8 additions and 1 deletions

View File

@@ -51,6 +51,7 @@ public class ImpositionsTfu extends BaseEntity implements Serializable {
private String datePieceAdmin; private String datePieceAdmin;
@Enumerated(EnumType.STRING) @Enumerated(EnumType.STRING)
private StatusAvis statusAvis; private StatusAvis statusAvis;
@Formula(""" @Formula("""
( (
@@ -59,6 +60,7 @@ public class ImpositionsTfu extends BaseEntity implements Serializable {
WHERE d.impositions_tfu_id = id WHERE d.impositions_tfu_id = id
) )
""") """)
@Transient
private Integer nombreAvis; private Integer nombreAvis;
@Formula(""" @Formula("""
( (
@@ -68,6 +70,7 @@ public class ImpositionsTfu extends BaseEntity implements Serializable {
and (d.nature_impot='FNB' or d.nature_impot='FB') and (d.nature_impot='FNB' or d.nature_impot='FB')
) )
""") """)
@Transient
private Integer nombreAvisFnb; private Integer nombreAvisFnb;
@Formula(""" @Formula("""
( (
@@ -78,7 +81,9 @@ public class ImpositionsTfu extends BaseEntity implements Serializable {
and d.batiment_id is not null and d.batiment_id is not null
) )
""") """)
@Transient
private Integer nombreAvisBatiment; private Integer nombreAvisBatiment;
@Formula(""" @Formula("""
( (
SELECT COUNT(DISTINCT (d.annee, d.code_commune, d.personne_id)) SELECT COUNT(DISTINCT (d.annee, d.code_commune, d.personne_id))
@@ -88,6 +93,7 @@ public class ImpositionsTfu extends BaseEntity implements Serializable {
and d.unite_logement_id is not null and d.unite_logement_id is not null
) )
""") """)
@Transient
private Integer nombreAvisUniteLog; private Integer nombreAvisUniteLog;
@Column(columnDefinition = "TEXT") @Column(columnDefinition = "TEXT")

View File

@@ -137,9 +137,10 @@ public class UserServiceImpl implements UserService {
public UserPaylaodWeb updateUser(Long id, UserPaylaodWeb userPaylaodWeb) { public UserPaylaodWeb updateUser(Long id, UserPaylaodWeb userPaylaodWeb) {
if ((userRepository.findByUsername(userPaylaodWeb.getLogin()).isEmpty()) if ((userRepository.findByUsername(userPaylaodWeb.getLogin()).isEmpty())
|| (userRepository.findByEmail(userPaylaodWeb.getEmail()).isEmpty())) { && (userRepository.findByEmail(userPaylaodWeb.getEmail()).isEmpty())) {
throw new BadRequestException("Cet utilisateur n'existe pas."); throw new BadRequestException("Cet utilisateur n'existe pas.");
} }
if (userPaylaodWeb.getId() == null) { if (userPaylaodWeb.getId() == null) {
throw new BadRequestException("Cet utilisateur n'existe déjà."); throw new BadRequestException("Cet utilisateur n'existe déjà.");
} }