revu du controleur de la fiche enquete
This commit is contained in:
@@ -20,7 +20,6 @@ import java.util.List;
|
||||
@AllArgsConstructor
|
||||
@Where(clause = " deleted = false")
|
||||
public class Arrondissement extends BaseEntity implements Serializable {
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
private Long id;
|
||||
@@ -30,10 +29,10 @@ public class Arrondissement extends BaseEntity implements Serializable {
|
||||
private String latitude;
|
||||
@ManyToOne
|
||||
private Commune commune;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "arrondissement")
|
||||
private List<Quartier> quartiers;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "arrondissement")
|
||||
private List<Bloc> blocs;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "arrondissement")
|
||||
// private List<Quartier> quartiers;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "arrondissement")
|
||||
// private List<Bloc> blocs;
|
||||
}
|
||||
|
||||
@@ -30,11 +30,11 @@ public class Commune extends BaseEntity implements Serializable {
|
||||
private String latitude;
|
||||
@ManyToOne
|
||||
private Departement departement;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "commune")
|
||||
private List<Arrondissement> arrondissements;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "commune")
|
||||
private List<Personne> personnes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "commune")
|
||||
// private List<Arrondissement> arrondissements;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "commune")
|
||||
// private List<Personne> personnes;
|
||||
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@ public class Departement extends BaseEntity implements Serializable {
|
||||
private Long id;
|
||||
private String code;
|
||||
private String nom;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "departement")
|
||||
private List<Commune> communes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "departement")
|
||||
// private List<Commune> communes;
|
||||
}
|
||||
|
||||
@@ -33,7 +33,7 @@ public class Nationalite extends BaseEntity implements Serializable {
|
||||
private String code;
|
||||
private String indicatif;
|
||||
private String nationality;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "nationalite")
|
||||
private List<Personne> personnes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "nationalite")
|
||||
// private List<Personne> personnes;
|
||||
}
|
||||
|
||||
@@ -19,17 +19,16 @@ import java.io.Serializable;
|
||||
@AllArgsConstructor
|
||||
@Where(clause = " deleted = false")
|
||||
public class Quartier extends BaseEntity implements Serializable {
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
private Long id;
|
||||
private String code;
|
||||
private String nom;
|
||||
@JsonIgnore
|
||||
// @JsonIgnore
|
||||
@ManyToOne
|
||||
private Arrondissement arrondissement;
|
||||
@JsonIgnore
|
||||
@OneToOne(mappedBy = "quartier")
|
||||
private Bloc bloc;
|
||||
// @JsonIgnore
|
||||
// @OneToOne(mappedBy = "quartier")
|
||||
// private Bloc bloc;
|
||||
|
||||
}
|
||||
|
||||
@@ -20,7 +20,6 @@ import java.util.List;
|
||||
@AllArgsConstructor
|
||||
@Where(clause = " deleted = false")
|
||||
public class Secteur extends BaseEntity implements Serializable {
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
private Long id;
|
||||
@@ -30,7 +29,10 @@ public class Secteur extends BaseEntity implements Serializable {
|
||||
private User chefSecteur;
|
||||
@ManyToOne
|
||||
private Structure structure;
|
||||
@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.EAGER)
|
||||
@JoinColumn(name = "secteur_id")
|
||||
private List<SecteurDecoupage> secteurDecoupages;
|
||||
// @OneToMany(cascade = CascadeType.ALL, fetch = FetchType.EAGER)
|
||||
// @JoinColumn(name = "secteur_id")
|
||||
// private List<SecteurDecoupage> secteurDecoupages;
|
||||
|
||||
///Creer un payload pour la creation de secteur découpage
|
||||
/// ressource pour envoyer les découpage d'un secteur
|
||||
}
|
||||
|
||||
@@ -35,17 +35,15 @@ public class SecteurDecoupage extends BaseEntity implements Serializable {
|
||||
@JsonDeserialize(using = LocalDateDeserializer.class)
|
||||
private LocalDate dateFin;
|
||||
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private Secteur secteur;
|
||||
|
||||
@ManyToOne
|
||||
private Arrondissement arrondissement;
|
||||
@ManyToOne
|
||||
private Quartier quartier;
|
||||
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "secteurDecoupage")
|
||||
private List<Bloc> blocs;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "secteurDecoupage")
|
||||
// private List<Bloc> blocs;
|
||||
|
||||
}
|
||||
@@ -31,7 +31,6 @@ import java.util.List;
|
||||
"WHERE id = ?")
|
||||
@Where(clause = " deleted = false")
|
||||
public class ActeurConcerne extends BaseEntity implements Serializable {
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
private Long id;
|
||||
@@ -52,8 +51,10 @@ public class ActeurConcerne extends BaseEntity implements Serializable {
|
||||
private Enquete enquete;
|
||||
@Enumerated(EnumType.STRING)
|
||||
private RoleActeur roleActeur;
|
||||
@OneToMany(mappedBy = "acteurConcerne")
|
||||
private List<Piece> pieces;
|
||||
|
||||
// @OneToMany(mappedBy = "acteurConcerne")
|
||||
// private List<Piece> pieces;
|
||||
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private Tpe terminal;
|
||||
|
||||
@@ -60,7 +60,7 @@ public class Enquete extends BaseEntity implements Serializable {
|
||||
private Parcelle parcelle;
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private Bloc bloc; //représente un secteur d'enquetes
|
||||
private Bloc bloc;
|
||||
@ManyToOne
|
||||
private Campagne campagne;
|
||||
@ManyToOne
|
||||
|
||||
@@ -35,9 +35,9 @@ public class MembreGroupe extends BaseEntity implements Serializable {
|
||||
private TypeRepresentation typeRepresentation;
|
||||
@ManyToOne
|
||||
private PositionRepresentation positionRepresentation;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "membreGroupe")
|
||||
private Set<Upload> uploads;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "membreGroupe")
|
||||
// private Set<Upload> uploads;
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private Tpe terminal;
|
||||
|
||||
@@ -42,9 +42,9 @@ public class Parcelle extends BaseEntity implements Serializable {
|
||||
private String longitude;
|
||||
private String latitude;
|
||||
private String situationGeographique;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "parcelle")
|
||||
private List<Enquete> enquetes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "parcelle")
|
||||
// private List<Enquete> enquetes;
|
||||
// @ManyToOne
|
||||
// private SituationGeographique situationGeographique;
|
||||
@ManyToOne
|
||||
@@ -69,9 +69,9 @@ public class Parcelle extends BaseEntity implements Serializable {
|
||||
|
||||
|
||||
private Long idDerniereEnquete;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "parcelle")
|
||||
private List<Batiment> batiments;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "parcelle")
|
||||
// private List<Batiment> batiments;
|
||||
|
||||
// @ColumnDefault("0")
|
||||
// private int geomSrid;
|
||||
@@ -85,6 +85,4 @@ public class Parcelle extends BaseEntity implements Serializable {
|
||||
// @JsonDeserialize(contentUsing = GeometryDeserializer.class)
|
||||
// @Column(name = "geom_32631",columnDefinition = "geometry(MultiPolygon,32631)")
|
||||
// private Point geometry32631;
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -54,6 +54,7 @@ public class Piece extends BaseEntity implements Serializable {
|
||||
private SourceDroit sourceDroit;
|
||||
@ManyToOne
|
||||
private ModeAcquisition modeAcquisition;
|
||||
|
||||
@OneToMany(mappedBy = "piece")
|
||||
private List<Upload> uploads;
|
||||
|
||||
|
||||
@@ -31,9 +31,11 @@ public class Upload extends BaseEntity implements Serializable {
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private Piece piece;
|
||||
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private MembreGroupe membreGroupe;
|
||||
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private Tpe terminal;
|
||||
@@ -48,6 +50,7 @@ public class Upload extends BaseEntity implements Serializable {
|
||||
|
||||
@ManyToOne
|
||||
private EnqueteBatiment enqueteBatiment;
|
||||
|
||||
@ManyToOne
|
||||
private EnqueteUniteLogement enqueteUniteLogement;
|
||||
|
||||
|
||||
@@ -33,7 +33,6 @@ public class ModeAcquisition extends BaseEntity implements Serializable {
|
||||
private String libelle;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "modeAcquisition")
|
||||
//private List<SourceDroitExerce> sourceDroitExerces;
|
||||
private List<Piece> pieces;
|
||||
@ManyToMany
|
||||
@JoinTable(name = "modeAcquisition_typePersonne",
|
||||
|
||||
@@ -34,9 +34,10 @@ public class NatureDomaine extends BaseEntity implements Serializable {
|
||||
//@JsonIgnore
|
||||
@ManyToOne
|
||||
private TypeDomaine typeDomaine;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "natureDomaine")
|
||||
private List<Parcelle> parcelles;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "natureDomaine")
|
||||
// private List<Parcelle> parcelles;
|
||||
|
||||
@ManyToMany
|
||||
@JoinTable(name = "natureDomaine_typePersonne",
|
||||
joinColumns = @JoinColumn(name = "nature_domaine_id"),
|
||||
|
||||
@@ -47,9 +47,9 @@ public class Personne extends BaseEntity implements Serializable {
|
||||
private String adresse;
|
||||
@Enumerated(EnumType.STRING)
|
||||
private Categorie categorie;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "personne")
|
||||
private List<ActeurConcerne> acteurConcernes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "personne")
|
||||
// private List<ActeurConcerne> acteurConcernes;
|
||||
@ManyToOne
|
||||
private SituationMatrimoniale situationMatrimoniale;
|
||||
@ManyToOne
|
||||
@@ -60,9 +60,8 @@ public class Personne extends BaseEntity implements Serializable {
|
||||
private Profession profession;
|
||||
@ManyToOne
|
||||
private Commune commune;
|
||||
@OneToMany(mappedBy = "personne")
|
||||
private List<Piece> pieces;
|
||||
|
||||
// @OneToMany(mappedBy = "personne")
|
||||
// private List<Piece> pieces;
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private Tpe terminal;
|
||||
|
||||
@@ -31,10 +31,10 @@ public class PositionRepresentation extends BaseEntity implements Serializable {
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
private Long id;
|
||||
private String libelle;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "positionRepresentation")
|
||||
private List<ActeurConcerne> acteurConcernes;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "positionRepresentation")
|
||||
private List<MembreGroupe> membreGroupes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "positionRepresentation")
|
||||
// private List<ActeurConcerne> acteurConcernes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "positionRepresentation")
|
||||
// private List<MembreGroupe> membreGroupes;
|
||||
}
|
||||
|
||||
@@ -30,7 +30,7 @@ public class Profession extends BaseEntity implements Serializable {
|
||||
private Long id;
|
||||
private String code;
|
||||
private String libelle;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "profession")
|
||||
private List<Personne> personnes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "profession")
|
||||
// private List<Personne> personnes;
|
||||
}
|
||||
|
||||
@@ -29,7 +29,7 @@ public class SituationMatrimoniale extends BaseEntity implements Serializable {
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
private Long id;
|
||||
private String libelle;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "situationMatrimoniale")
|
||||
private List<Personne> personnes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "situationMatrimoniale")
|
||||
// private List<Personne> personnes;
|
||||
}
|
||||
|
||||
@@ -53,11 +53,11 @@ public class Structure extends BaseEntity implements Serializable {
|
||||
inverseJoinColumns = @JoinColumn(name = "arrondissement_id")
|
||||
)
|
||||
private Set<Arrondissement> arrondissements;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "structure")
|
||||
private List<User> agents;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "structure")
|
||||
private List<Bloc> blocs;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "structure")
|
||||
// private List<User> agents;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "structure")
|
||||
// private List<Bloc> blocs;
|
||||
|
||||
}
|
||||
|
||||
@@ -26,14 +26,13 @@ import java.util.List;
|
||||
"WHERE id = ?")
|
||||
@Where(clause = " deleted = false")
|
||||
public class TypeContestation extends BaseEntity implements Serializable {
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
private Long id;
|
||||
private String libelle;
|
||||
@ColumnDefault("true")
|
||||
private boolean droitPropriete;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "typeContestation")
|
||||
private List<ActeurConcerne> acteurConcernes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "typeContestation")
|
||||
// private List<ActeurConcerne> acteurConcernes;
|
||||
}
|
||||
|
||||
@@ -34,7 +34,7 @@ public class TypePersonne extends BaseEntity implements Serializable {
|
||||
private Categorie categorie;
|
||||
@Column(nullable = false, columnDefinition = "BOOLEAN DEFAULT false")
|
||||
private boolean groupeOuvert;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "typePersonne")
|
||||
private List<Personne> personnes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "typePersonne")
|
||||
// private List<Personne> personnes;
|
||||
}
|
||||
|
||||
@@ -33,11 +33,11 @@ public class TypeRepresentation extends BaseEntity implements Serializable {
|
||||
private String libelle;
|
||||
@Column(columnDefinition = "boolean default false")
|
||||
private boolean estUnique;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "typeRepresentation")
|
||||
private List<ActeurConcerne> acteurConcernes;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "typeRepresentation")
|
||||
private List<MembreGroupe> membreGroupes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "typeRepresentation")
|
||||
// private List<ActeurConcerne> acteurConcernes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "typeRepresentation")
|
||||
// private List<MembreGroupe> membreGroupes;
|
||||
|
||||
}
|
||||
|
||||
@@ -34,15 +34,16 @@ public class Batiment extends BaseEntity implements Serializable {
|
||||
@JsonFormat(pattern = "dd-MM-yyyy")
|
||||
@JsonDeserialize(using = LocalDateDeserializer.class)
|
||||
private LocalDate dateConstruction;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "batiment")
|
||||
private List<EnqueteBatiment> enqueteBatiments;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "batiment")
|
||||
// private List<EnqueteBatiment> enqueteBatiments;
|
||||
private Long idDerniereEnquete;
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private Parcelle parcelle;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "batiment")
|
||||
private List<UniteLogement> uniteLogements;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "batiment")
|
||||
// private List<UniteLogement> uniteLogements;
|
||||
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
|
||||
@@ -30,6 +30,7 @@ public class CaracteristiqueParcelle extends BaseEntity implements Serializable
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
private Long id;
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private Enquete enquete;
|
||||
@ManyToOne
|
||||
|
||||
@@ -63,11 +63,12 @@ public class EnqueteBatiment extends BaseEntity implements Serializable {
|
||||
private Personne personne;
|
||||
@ManyToOne
|
||||
private Batiment batiment;
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private Enquete enquete;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "enqueteBatiment")
|
||||
List<CaracteristiqueBatiment> caracteristiqueBatiments;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "enqueteBatiment")
|
||||
// List<CaracteristiqueBatiment> caracteristiqueBatiments;
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private Tpe terminal;
|
||||
|
||||
@@ -57,15 +57,16 @@ public class EnqueteUniteLogement extends BaseEntity implements Serializable {
|
||||
@JsonFormat(pattern = "dd-MM-yyyy")
|
||||
@JsonDeserialize(using = LocalDateDeserializer.class)
|
||||
private LocalDate dateFinExcemption;
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private Enquete enquete;
|
||||
@ManyToOne
|
||||
private UniteLogement uniteLogement;
|
||||
@OneToOne
|
||||
private Personne personne;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "enqueteUniteLogement")
|
||||
private List<CaracteristiqueUniteLogement> caracteristiqueUniteLogements;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "enqueteUniteLogement")
|
||||
// private List<CaracteristiqueUniteLogement> caracteristiqueUniteLogements;
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private Tpe terminal;
|
||||
|
||||
@@ -39,12 +39,12 @@ public class Campagne extends BaseEntity implements Serializable {
|
||||
private LocalDate dateFin;
|
||||
@Enumerated(EnumType.STRING)
|
||||
private TypeCampagne typeCampagne;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "campagne")
|
||||
private List<Equipe> equipes;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "campagne")
|
||||
private List<Enquete> enquetes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "campagne")
|
||||
// private List<Equipe> equipes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "campagne")
|
||||
// private List<Enquete> enquetes;
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -30,15 +30,16 @@ public class Caracteristique extends BaseEntity implements Serializable {
|
||||
private String code;
|
||||
private String libelle;
|
||||
private boolean actif;
|
||||
@Enumerated(EnumType.STRING)
|
||||
private TypeImmeuble typeImmeuble;
|
||||
@ManyToOne
|
||||
private TypeCaracteristique typeCaracteristique;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "caracteristique")
|
||||
private List<CaracteristiqueBatiment> caracteristiqueBatiments;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "caracteristique")
|
||||
private List<CaracteristiqueUniteLogement> caracteristiqueUniteLogements;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "caracteristique")
|
||||
// private List<CaracteristiqueBatiment> caracteristiqueBatiments;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "caracteristique")
|
||||
// private List<CaracteristiqueUniteLogement> caracteristiqueUniteLogements;
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private Tpe terminal;
|
||||
|
||||
@@ -38,7 +38,7 @@ public class Equipe extends BaseEntity implements Serializable {
|
||||
@JoinColumn(name = "equipe_id")
|
||||
private List<Participer> participers;
|
||||
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "equipe")
|
||||
private List<Enquete> enquetes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "equipe")
|
||||
// private List<Enquete> enquetes;
|
||||
}
|
||||
|
||||
@@ -35,6 +35,7 @@ public class Participer extends BaseEntity implements Serializable {
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private Equipe equipe;
|
||||
@JsonIgnore
|
||||
@ManyToOne
|
||||
private User user;
|
||||
}
|
||||
|
||||
@@ -29,9 +29,10 @@ public class TypeCaracteristique extends BaseEntity implements Serializable {
|
||||
private boolean actif;
|
||||
private boolean bati;
|
||||
private boolean nonBati;
|
||||
@Enumerated(EnumType.STRING)
|
||||
private TypeImmeuble typeImmeuble;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "typeCaracteristique")
|
||||
private List<Caracteristique> caracteristiques;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "typeCaracteristique")
|
||||
// private List<Caracteristique> caracteristiques;
|
||||
|
||||
}
|
||||
|
||||
@@ -54,15 +54,15 @@ public class User extends BaseEntity implements Serializable {
|
||||
private Set<Role> roles;
|
||||
@ManyToOne
|
||||
private Structure structure;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "user")
|
||||
private List<Enquete> enquetes;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "user")
|
||||
// private List<Enquete> enquetes;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "user")
|
||||
private List<Participer> participers;
|
||||
@JsonIgnore
|
||||
@OneToMany(mappedBy = "chefSecteur")
|
||||
private List<Secteur> secteurs;
|
||||
// @JsonIgnore
|
||||
// @OneToMany(mappedBy = "chefSecteur")
|
||||
// private List<Secteur> secteurs;
|
||||
|
||||
@Transient
|
||||
private Long idCampagneCourant;
|
||||
@@ -84,6 +84,7 @@ public class User extends BaseEntity implements Serializable {
|
||||
|
||||
|
||||
public Long getIdCampagneCourant() {
|
||||
if(participers!=null) {
|
||||
for (Participer p : participers) {
|
||||
if (p.getDateFin() == null) {
|
||||
if (p.getEquipe().getCampagne() != null) {
|
||||
@@ -91,10 +92,12 @@ public class User extends BaseEntity implements Serializable {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public Long getIdSecteurCourant() {
|
||||
if(participers!=null){
|
||||
for (Participer p : participers) {
|
||||
if (p.getDateFin() == null) {
|
||||
if(p.getEquipe().getSecteur()!=null) {
|
||||
@@ -102,6 +105,7 @@ public class User extends BaseEntity implements Serializable {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return null ;
|
||||
}
|
||||
|
||||
|
||||
@@ -79,7 +79,8 @@ public class SecteurServiceImpl implements SecteurService {
|
||||
sd.setId(sdp.getId());
|
||||
secteurDecoupageList.add(sd);
|
||||
}
|
||||
secteur.setSecteurDecoupages(secteurDecoupageList);
|
||||
//secteur.setSecteurDecoupages(secteurDecoupageList);
|
||||
//TODO
|
||||
secteur.setId(secteurPayload.getId());
|
||||
secteur.setCode(secteurPayload.getCode());
|
||||
secteur.setNom(secteurPayload.getNom());
|
||||
|
||||
@@ -385,39 +385,17 @@ public class EnqueteServiceImpl implements EnqueteService {
|
||||
if (optionalEnquete.isPresent()) {
|
||||
ficheEnquetesResponse = modelMapper.map(optionalEnquete.get(), FicheEnquetesResponse.class);
|
||||
}
|
||||
|
||||
List<FicheActeurConcerneResponse> ficheActeurConcerneResponses = new ArrayList<>();
|
||||
if (!acteurConcernes.isEmpty()) {
|
||||
acteurConcernes.stream().forEach(acteurConcerne -> ficheActeurConcerneResponses.add(modelMapper.map(acteurConcerne, FicheActeurConcerneResponse.class)));
|
||||
}
|
||||
|
||||
List<CaracteristiqueParcelle> caracteristiqueParcelles = caracteristiqueParcelleRepository.findAllByEnquete_Id(enqueteId);
|
||||
|
||||
List<FicheCaracteristiqueParcelleResponse> caracteristiqueParcelleResponses = new ArrayList<>();
|
||||
if (!caracteristiqueParcelles.isEmpty()) {
|
||||
caracteristiqueParcelles.stream().forEach(caracteristiqueParcelle -> caracteristiqueParcelleResponses.add(modelMapper.map(caracteristiqueParcelle, FicheCaracteristiqueParcelleResponse.class)));
|
||||
}
|
||||
|
||||
List<FicheEnqueteBatimentResponse> enqueteBatimentResponses = new ArrayList<>();
|
||||
|
||||
List<EnqueteBatiment> enqueteBatiments = enqueteBatimentRepository.findAllByEnquete_Id(enqueteId);
|
||||
if (!enqueteBatiments.isEmpty()) {
|
||||
enqueteBatiments.stream().forEach(enqueteBatiment -> enqueteBatimentResponses.add(modelMapper.map(enqueteBatiment, FicheEnqueteBatimentResponse.class)));
|
||||
}
|
||||
|
||||
List<FicheEnqueteUniteLogementResponse> enqueteUniteLogementResponses = new ArrayList<>();
|
||||
|
||||
List<EnqueteUniteLogement> enqueteUniteLogements = enqueteUniteLogementRepository.findAllByEnquete_Id(enqueteId);
|
||||
if (!enqueteUniteLogements.isEmpty()) {
|
||||
enqueteUniteLogements.stream().forEach(enqueteUniteLogement -> enqueteUniteLogementResponses.add(modelMapper.map(enqueteUniteLogement, FicheEnqueteUniteLogementResponse.class)));
|
||||
}
|
||||
|
||||
ficheEnquetesResponse.setCaracteristiquesParcelles(caracteristiqueParcelleResponses);
|
||||
ficheEnquetesResponse.setEnquetesBatiments(enqueteBatimentResponses);
|
||||
ficheEnquetesResponse.setEnquetesUniteLogements(enqueteUniteLogementResponses);
|
||||
|
||||
ficheEnquetesResponse.setCaracteristiquesParcelles(caracteristiqueParcelles);
|
||||
ficheEnquetesResponse.setEnquetesBatiments(enqueteBatiments);
|
||||
ficheEnquetesResponse.setEnquetesUniteLogements(enqueteUniteLogements);
|
||||
ficheEnqueteResponse.setEnquete(ficheEnquetesResponse);
|
||||
ficheEnqueteResponse.setActeurConcernes(ficheActeurConcerneResponses);
|
||||
ficheEnqueteResponse.setActeurConcernes(acteurConcernes);
|
||||
|
||||
return ficheEnqueteResponse;
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package io.gmss.fiscad.paylaods.response;
|
||||
|
||||
import io.gmss.fiscad.entities.infocad.metier.ActeurConcerne;
|
||||
import io.gmss.fiscad.paylaods.response.FicheResponse.FicheActeurConcerneResponse;
|
||||
import io.gmss.fiscad.paylaods.response.FicheResponse.FicheEnquetesResponse;
|
||||
import lombok.Data;
|
||||
@@ -16,6 +17,6 @@ public class FicheEnqueteResponse {
|
||||
//private List<ActeurConcerne> acteurConcernes;
|
||||
|
||||
private FicheEnquetesResponse enquete;
|
||||
private List<FicheActeurConcerneResponse> acteurConcernes;
|
||||
private List<ActeurConcerne> acteurConcernes;
|
||||
}
|
||||
|
||||
|
||||
@@ -8,6 +8,9 @@ import io.gmss.fiscad.entities.decoupage.Arrondissement;
|
||||
import io.gmss.fiscad.entities.infocad.metier.Parcelle;
|
||||
import io.gmss.fiscad.entities.infocad.parametre.Bloc;
|
||||
import io.gmss.fiscad.entities.infocad.parametre.NatureDomaine;
|
||||
import io.gmss.fiscad.entities.rfu.metier.CaracteristiqueParcelle;
|
||||
import io.gmss.fiscad.entities.rfu.metier.EnqueteBatiment;
|
||||
import io.gmss.fiscad.entities.rfu.metier.EnqueteUniteLogement;
|
||||
import io.gmss.fiscad.entities.rfu.parametre.Campagne;
|
||||
import io.gmss.fiscad.entities.rfu.parametre.Equipe;
|
||||
import io.gmss.fiscad.entities.user.User;
|
||||
@@ -49,7 +52,7 @@ public class FicheEnquetesResponse {
|
||||
@JsonFormat(pattern = "dd-MM-yyyy")
|
||||
@JsonDeserialize(using = LocalDateDeserializer.class)
|
||||
private LocalDate dateLitigeResolu;
|
||||
@JsonFormat
|
||||
@JsonIgnore
|
||||
private Bloc bloc;
|
||||
@JsonFormat(pattern = "dd-MM-yyyy")
|
||||
@JsonDeserialize(using = LocalDateDeserializer.class)
|
||||
@@ -115,16 +118,9 @@ public class FicheEnquetesResponse {
|
||||
@JsonDeserialize(using = LocalDateDeserializer.class)
|
||||
private LocalDate dateFinExcemption;
|
||||
|
||||
// public Long getTerminalId(){
|
||||
// if(this.terminal!=null){
|
||||
// return this.terminal.getId();
|
||||
// }else return null;
|
||||
// }
|
||||
|
||||
|
||||
private List<FicheCaracteristiqueParcelleResponse> caracteristiquesParcelles;
|
||||
private List<FicheEnqueteBatimentResponse> enquetesBatiments;
|
||||
private List<FicheEnqueteUniteLogementResponse> enquetesUniteLogements;
|
||||
private List<CaracteristiqueParcelle> caracteristiquesParcelles;
|
||||
private List<EnqueteBatiment> enquetesBatiments;
|
||||
private List<EnqueteUniteLogement> enquetesUniteLogements;
|
||||
|
||||
public String getNomPrenomEnqueteur() {
|
||||
if (this.user != null) {
|
||||
|
||||
Reference in New Issue
Block a user