Skip to content
Permalink
Browse files

préparation de l'intégration de la gestion des groupes/projets

pour les utilisateurs
- dernière phase (opérationnelle) avec l'ajout d'un module de gestion

- gestion de la session (expiration)
- restructuration des sources d'alignements (en particulier wikidata)
- intégration d'une gestion de profils avancée
- handle pour les groupes/domaines
  • Loading branch information...
miledrousset committed Aug 3, 2018
1 parent bc6c740 commit d34655df969e08024c1f8b19be4d5734863cb136
Showing with 7,922 additions and 5,588 deletions.
  1. BIN lib/SPARQL-JAVA.jar
  2. +20 −1 pom.xml
  3. +7 −5 src/main/java/mom/trd/ImageServlet.java
  4. +11 −11 src/main/java/mom/trd/opentheso/SelectedBeans/AutoCompletBean.java
  5. +9 −8 src/main/java/mom/trd/opentheso/SelectedBeans/Autorisation.java
  6. +0 −1 src/main/java/mom/trd/opentheso/SelectedBeans/Candidat.java
  7. +0 −715 src/main/java/mom/trd/opentheso/SelectedBeans/CurrentUser.java
  8. +15 −0 src/main/java/mom/trd/opentheso/SelectedBeans/CurrentUser2.java
  9. +59 −88 src/main/java/mom/trd/opentheso/SelectedBeans/DownloadBean.java
  10. +31 −18 src/main/java/mom/trd/opentheso/SelectedBeans/EditAlignementSourceBean.java
  11. +1 −1 src/main/java/mom/trd/opentheso/SelectedBeans/EditorView.java
  12. +34 −75 src/main/java/mom/trd/opentheso/SelectedBeans/FileBean.java
  13. +13 −9 src/main/java/mom/trd/opentheso/SelectedBeans/FileBean_progress.java
  14. +32 −20 src/main/java/mom/trd/opentheso/SelectedBeans/GpsBeans.java
  15. +8 −15 src/main/java/mom/trd/opentheso/SelectedBeans/LanguageBean.java
  16. +94 −22 src/main/java/mom/trd/opentheso/SelectedBeans/NewTreeBean.java
  17. +9 −8 src/main/java/mom/trd/opentheso/SelectedBeans/RoleOnThesoBean.java
  18. +7 −3 src/main/java/mom/trd/opentheso/SelectedBeans/SelectedCandidat.java
  19. +74 −64 src/main/java/mom/trd/opentheso/SelectedBeans/SelectedTerme.java
  20. +20 −44 src/main/java/mom/trd/opentheso/SelectedBeans/SelectedThesaurus.java
  21. +30 −13 src/main/java/mom/trd/opentheso/SelectedBeans/rdf4jFileBean.java
  22. +9 −5 src/main/java/mom/trd/opentheso/bdd/datas/ConceptGroup.java
  23. +14 −3 src/main/java/mom/trd/opentheso/bdd/helper/AlignmentHelper.java
  24. +54 −168 src/main/java/mom/trd/opentheso/bdd/helper/ConceptHelper.java
  25. +2 −2 src/main/java/mom/trd/opentheso/bdd/helper/CopyrightHelper.java
  26. +11 −5 src/main/java/mom/trd/opentheso/bdd/helper/ForgetPasswordHelper.java
  27. +505 −97 src/main/java/mom/trd/opentheso/bdd/helper/GroupHelper.java
  28. +1 −1 src/main/java/mom/trd/opentheso/bdd/helper/ImagesHelper.java
  29. +13 −6 src/main/java/mom/trd/opentheso/bdd/helper/SearchHelper.java
  30. +1 −1 src/main/java/mom/trd/opentheso/bdd/helper/UserHelper2.java
  31. +0 −3 src/main/java/mom/trd/opentheso/bdd/helper/nodes/NodeMetaData.java
  32. +76 −0 src/main/java/mom/trd/opentheso/core/alignment/AlignmentQuery.java
  33. +8 −7 src/main/java/mom/trd/opentheso/core/exports/old/WriteFileSKOS.java
  34. +8 −7 src/main/java/mom/trd/opentheso/core/exports/rdf4j/helper/ExportRdf4jHelper.java
  35. +1 −0 src/main/java/mom/trd/opentheso/core/imports/rdf4j/ReadRdf4j.java
  36. +7 −9 src/main/java/mom/trd/opentheso/filters/loginFilter.java
  37. +62 −0 src/main/java/mom/trd/opentheso/session/ViewExpiredExceptionHandler.java
  38. +26 −0 src/main/java/mom/trd/opentheso/session/ViewExpiredExceptionHandlerFactory.java
  39. +166 −0 src/main/java/mom/trd/opentheso/ws/ark/ArkClientRest.java
  40. +112 −0 src/main/java/mom/trd/opentheso/ws/ark/ArkHelper.java
  41. +358 −0 src/main/java/mom/trd/opentheso/ws/ark/NodeJson.java
  42. +228 −0 src/main/java/mom/trd/opentheso/ws/handle/HandleHelper.java
  43. +0 −1,886 src/main/resources/install/historique/opentheso_dist_4,3,6.sql.sql
  44. +2,813 −0 src/main/resources/install/historique/opentheso_dist_4.3.7.sql
  45. +13 −81 src/main/resources/install/initBDD.sql
  46. +154 −50 src/main/resources/install/maj_bdd_current.sql
  47. +1,193 −839 src/main/resources/install/opentheso_current.sql
  48. +11 −4 src/main/resources/language/site.properties
  49. +8 −1 src/main/resources/language/site_de.properties
  50. +8 −1 src/main/resources/language/site_en.properties
  51. +8 −1 src/main/resources/language/site_es.properties
  52. +8 −1 src/main/resources/language/site_it.properties
  53. +1 −1 src/main/resources/preferences.properties
  54. +4 −0 src/main/webapp/WEB-INF/faces-config.xml
  55. +3 −1 src/main/webapp/WEB-INF/web.xml
  56. +677 −0 src/main/webapp/Wikidata.json
  57. +2 −2 src/main/webapp/account.xhtml
  58. +1 −1 src/main/webapp/admin/reorganizing.xhtml
  59. +1 −1 src/main/webapp/conf.xhtml
  60. +0 −49 src/main/webapp/connection.xhtml
  61. +9 −7 src/main/webapp/contenuCentral/alignement/alignement.xhtml
  62. +9 −3 src/main/webapp/contenuCentral/contenuCentral.xhtml
  63. +6 −15 src/main/webapp/contenuCentral/googleMaps/googleMaps.xhtml
  64. +12 −10 src/main/webapp/contenuCentral/infoConcept/infoconcept.xhtml
  65. +3 −1 src/main/webapp/contenuCentral/notes/notes.xhtml
  66. +7 −3 src/main/webapp/contenuCentral/synonymes/synonymes.xhtml
  67. +4 −1 src/main/webapp/contenuCentral/termesAssocies/termesAssocies.xhtml
  68. +2 −1 src/main/webapp/contenuCentral/termesGeneriques/termesGeneriques.xhtml
  69. +2 −1 src/main/webapp/contenuCentral/termesSpecifiques/termesSpecifiques.xhtml
  70. +0 −158 src/main/webapp/copyright_pactols.xhtml
  71. +8 −6 src/main/webapp/css/style.css
  72. +21 −11 src/main/webapp/dialogs/Alignement/ajouterAutomatiqueEditDlg.xhtml
  73. +4 −3 src/main/webapp/dialogs/Alignement/ajouterAutomatique_suiteEditDlg.xhtml
  74. +47 −37 src/main/webapp/dialogs/Alignement/ajouterParLotEditDlg.xhtml
  75. +2 −2 src/main/webapp/dialogs/Alignement/finalizeDlg.xhtml
  76. +78 −0 src/main/webapp/dialogs/Alignement/settings/associateAlignement.xhtml
  77. +42 −31 src/main/webapp/dialogs/Alignement/{ → settings}/editAlignementSourceEditDlg.xhtml
  78. +1 −0 src/main/webapp/dialogs/bt/addTgDlg.xhtml
  79. +1 −0 src/main/webapp/dialogs/bt/addTgOtherGroupDlg.xhtml
  80. +0 −8 src/main/webapp/dialogs/candidat/editProposalDlg.xhtml
  81. +0 −137 src/main/webapp/dialogs/export/exportAdvancedSkosDlg.xhtml
  82. +1 −1 src/main/webapp/dialogs/export/exportAltLabel.xhtml
  83. +1 −14 src/main/webapp/dialogs/export/exportDlg.xhtml
  84. +0 −78 src/main/webapp/dialogs/export/exportJsonLdRdf4jDlg.xhtml
  85. +1 −9 src/main/webapp/dialogs/export/exportPdfDlg.xhtml
  86. +0 −79 src/main/webapp/dialogs/export/exportSkosDlg.xhtml
  87. +0 −79 src/main/webapp/dialogs/export/exportSkosRdf4jDlg.xhtml
  88. +0 −78 src/main/webapp/dialogs/export/exportTurtleRdf4jDlg.xhtml
  89. +1 −9 src/main/webapp/dialogs/export/exportTxtDlg.xhtml
  90. +0 −125 src/main/webapp/dialogs/export/exportTxtNotesDlg.xhtml
  91. +1 −1 src/main/webapp/dialogs/export/exportcsvDlg.xhtml
  92. +2 −2 src/main/webapp/dialogs/gps/finalizeGPSDlg.xhtml
  93. +16 −19 src/main/webapp/dialogs/gps/gpsAutomatiqueEditDlg.xhtml
  94. +3 −10 src/main/webapp/dialogs/gps/gpsAutomatique_suiteEditDlg.xhtml
  95. +2 −2 src/main/webapp/dialogs/gps/gpsParLotEditDlg.xhtml
  96. +2 −2 src/main/webapp/dialogs/gps/gpsParLot_suiteEditDlg.xhtml
  97. +1 −1 src/main/webapp/dialogs/group/addGroupDlg.xhtml
  98. +1 −1 src/main/webapp/dialogs/import/importDlg.xhtml
  99. +1 −1 src/main/webapp/dialogs/nt/addRelationNTDlg.xhtml
  100. +1 −1 src/main/webapp/dialogs/nt/ntEditDlg.xhtml
  101. +1 −1 src/main/webapp/dialogs/nt/specialntEditDlg.xhtml
  102. +1 −0 src/main/webapp/dialogs/termeAssocies/termeAssocieEditDlg.xhtml
  103. +1 −0 src/main/webapp/dialogs/termeAssocies/termeAssocieSpecialEditDlg.xhtml
  104. +5 −3 src/main/webapp/dialogs/termeSynonymes/termeSynonymesModifyEditDlg.xhtml
  105. +4 −4 src/main/webapp/edition.xhtml
  106. +3 −3 src/main/webapp/errorPages/error404.xhtml
  107. +3 −3 src/main/webapp/errorPages/error500.xhtml
  108. +19 −19 src/main/webapp/errorPages/timeOut.xhtml
  109. +12 −10 src/main/webapp/gestCandidat.xhtml
  110. +2 −2 src/main/webapp/gestionnaire/gestinnaireFin.xhtml
  111. +2 −1 src/main/webapp/includes.xhtml
  112. +8 −4 src/main/webapp/menuThesaurus.xhtml
  113. +1 −1 src/main/webapp/metadata_et_commenteries.xhtml
  114. +1 −1 src/main/webapp/opentheso.xhtml
  115. +3 −1 src/main/webapp/panelDroite/facette/facette.xhtml
  116. +3 −1 src/main/webapp/panelDroite/image/image.xhtml
  117. +5 −1 src/main/webapp/panelDroite/traduction/traduction.xhtml
  118. +7 −65 src/main/webapp/panelGauche/arbre/arbre.xhtml
  119. +3 −2 src/main/webapp/panelGauche/navigationRapide/navigationRapide.xhtml
  120. +2 −0 src/main/webapp/panelGauche/panelGauche.xhtml
  121. +2 −2 src/main/webapp/panelGauche/rechercheDirecte/rechercheDirecte.xhtml
  122. +3 −1 src/main/webapp/panelGauche/sousArbre/sousArbre.xhtml
  123. +4 −6 src/main/webapp/panelGauche/tabRecherche/tabRecherche.xhtml
  124. +1 −1 src/main/webapp/panelGauche/{tabResultatRecherche → tabRecherche}/tabResultatRecherche.xhtml
  125. +1 −1 src/main/webapp/profiles.xhtml
  126. +1 −1 src/main/webapp/statistic.xhtml
  127. +107 −0 src/test/java/alignement/wikidata/WikidataTest.java
  128. +370 −153 src/test/java/ark/rest/ArkRestTests.java
  129. +14 −0 src/test/java/ark/rest/HttpURLConnection.java
BIN +22.4 KB lib/SPARQL-JAVA.jar
Binary file not shown.
21 pom.xml
@@ -101,9 +101,21 @@
<groupId>com.sun.jersey</groupId>
<artifactId>jersey-client</artifactId>
<version>1.19.4</version>
<type>jar</type>
</dependency>
<dependency>
<groupId>javax.xml</groupId>
<artifactId>webservices-api</artifactId>
<version>2.0</version>
<scope>test</scope>
<type>jar</type>
</dependency>
<dependency>
<groupId>SPARQL-JAVA</groupId>
<artifactId>SPARQL-JAVA</artifactId>
<version>1.1</version>
<type>jar</type>
</dependency>
<dependency>
<groupId>javax</groupId>
<artifactId>javaee-web-api</artifactId>
@@ -123,7 +135,7 @@
<dependency>
<groupId>org.glassfish</groupId>
<artifactId>javax.json</artifactId>
<version>1.0.4</version>
<version>1.1.2</version>
</dependency>

<dependency>
@@ -333,6 +345,13 @@
<artifactId>qrgen</artifactId>
<version>1.4</version>
</dependency>


<dependency>
<groupId>org.openrdf.sesame</groupId>
<artifactId>sesame-queryparser-sparql</artifactId>
<version>4.1.2</version>
</dependency>

</dependencies>

@@ -10,14 +10,14 @@
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import mom.trd.opentheso.SelectedBeans.CurrentUser;
import mom.trd.opentheso.SelectedBeans.CurrentUser2;


@WebServlet("/pix/*")
public class ImageServlet extends HttpServlet {

@ManagedProperty(value = "#{user1}")
private CurrentUser user;
@ManagedProperty(value = "#{currentUser}")
private CurrentUser2 user;

/**
* Processes requests for both HTTP <code>GET</code> and <code>POST</code>
@@ -93,12 +93,14 @@ public String getServletInfo() {
return "Short description";
}// </editor-fold>

public CurrentUser getUser() {
public CurrentUser2 getUser() {
return user;
}

public void setUser(CurrentUser user) {
public void setUser(CurrentUser2 user) {
this.user = user;
}



}
@@ -404,7 +404,7 @@ public void newRelationNT() {
terme.getIdC(),
terme.getIdTheso(),
terme.getSelectedTermComp().getIdConcept(),
terme.getUser().getUser().getId())) {
terme.getUser().getUser().getIdUser())) {
FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(FacesMessage.SEVERITY_ERROR, langueBean.getMsg("error") + " :", langueBean.getMsg("error")));
return;
}
@@ -547,7 +547,7 @@ public boolean moveBranchToConcept() {

// permet de déplacer une branche simplement, en cas d'erreur, rien n'est écrit
if (!conceptHelper.moveBranch(ds,
terme.getIdC(), idOld, selectedAtt.getIdConcept(), terme.getIdTheso(), terme.getUser().getUser().getId())) {
terme.getIdC(), idOld, selectedAtt.getIdConcept(), terme.getIdTheso(), terme.getUser().getUser().getIdUser())) {
FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(langueBean.getMsg("error") + " :", langueBean.getMsg("error")));
return false;
}
@@ -587,7 +587,7 @@ public boolean moveBrancheFromDomainToConcept() {
selectedAtt.getIdConcept(),
terme.getIdDomaine(),
terme.getIdTheso(),
terme.getUser().getUser().getId())) {
terme.getUser().getUser().getIdUser())) {
FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(langueBean.getMsg("error") + " :", langueBean.getMsg("error")));
conn.rollback();
conn.close();
@@ -633,7 +633,7 @@ public boolean moveBrancheToTopTerm() {
// au concept la relation TT
if (!conceptHelper.moveBranchToMT(conn, terme.getIdC(),
idOld, terme.getIdDomaine(), terme.getIdTheso(),
terme.getUser().getUser().getId())) {
terme.getUser().getUser().getIdUser())) {
FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(langueBean.getMsg("error") + " :", langueBean.getMsg("error")));
conn.rollback();
conn.close();
@@ -685,7 +685,7 @@ public boolean moveBrancheToGroupOfOtherGroup() {
idOld, terme.getIdDomaine(), // ancien Group
selectedAtt.getIdGroup(), // nouveau Group
terme.getIdTheso(),
terme.getUser().getUser().getId())) {
terme.getUser().getUser().getIdUser())) {
FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(langueBean.getMsg("error") + " :", langueBean.getMsg("error")));
conn.rollback();
conn.close();
@@ -756,7 +756,7 @@ public boolean moveBrancheFromDomainToConceptOtherGroup() {
selectedAtt.getIdConcept(),
terme.getIdDomaine(),
terme.getIdTheso(),
terme.getUser().getUser().getId())) {
terme.getUser().getUser().getIdUser())) {
FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(langueBean.getMsg("error") + " :", langueBean.getMsg("error")));
conn.rollback();
conn.close();
@@ -831,7 +831,7 @@ public boolean moveBranchToConceptOtherGroup() {
idOld,
selectedAtt.getIdConcept(),
terme.getIdTheso(),
terme.getUser().getUser().getId())) {
terme.getUser().getUser().getIdUser())) {
FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(langueBean.getMsg("error") + " :", langueBean.getMsg("error")));
return false;
}
@@ -910,7 +910,7 @@ public boolean moveBranchFromOrphinToConcept() {
idOld,
selectedAtt.getIdConcept(),
terme.getIdTheso(),
terme.getUser().getUser().getId())) {
terme.getUser().getUser().getIdUser())) {
FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(langueBean.getMsg("error") + " :", langueBean.getMsg("error")));
return false;
}
@@ -944,7 +944,7 @@ public boolean moveBranchFromOrphinToConcept() {
}

OrphanHelper orphanHelper = new OrphanHelper();
if(!orphanHelper.deleteOrphanBranch2(conn, terme.getIdC(), terme.getIdTheso(), terme.getUser().getUser().getId())) {
if(!orphanHelper.deleteOrphanBranch2(conn, terme.getIdC(), terme.getIdTheso(), terme.getUser().getUser().getIdUser())) {
FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(langueBean.getMsg("error") + " :", langueBean.getMsg("error")));
conn.rollback();
conn.close();
@@ -993,7 +993,7 @@ public boolean moveBrancheFromOrphinToGroup() {
idOld, terme.getIdDomaine(), // ancien Group
selectedAtt.getIdGroup(), // nouveau Group
terme.getIdTheso(),
terme.getUser().getUser().getId())) {
terme.getUser().getUser().getIdUser())) {
FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(langueBean.getMsg("error") + " :", langueBean.getMsg("error")));
conn.rollback();
conn.close();
@@ -1022,7 +1022,7 @@ public boolean moveBrancheFromOrphinToGroup() {
}

OrphanHelper orphanHelper = new OrphanHelper();
if(!orphanHelper.deleteOrphanBranch2(conn, terme.getIdC(), terme.getIdTheso(), terme.getUser().getUser().getId())) {
if(!orphanHelper.deleteOrphanBranch2(conn, terme.getIdC(), terme.getIdTheso(), terme.getUser().getUser().getIdUser())) {
FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(langueBean.getMsg("error") + " :", langueBean.getMsg("error")));
conn.rollback();
conn.close();
@@ -24,8 +24,10 @@
public class Autorisation {
@ManagedProperty(value = "#{poolConnexion}")
private Connexion connect;
@ManagedProperty(value = "#{user1}")
private CurrentUser user;
@ManagedProperty(value = "#{currentUser}")
private CurrentUser2 currentUser;


private ArrayList<AutorisationStruct> listAutorisation=new ArrayList<>();
/**
* Creates a new instance of autorisation
@@ -37,7 +39,7 @@ public void actionButton(ActionEvent event){
}
public void init(){
AutorisationHelper ah=new AutorisationHelper();
listAutorisation=ah.getRights(connect.getPoolConnexion(),user.getUser().getId());
listAutorisation=ah.getRights(connect.getPoolConnexion(),currentUser.getUser().getIdUser());
}

public ArrayList<AutorisationStruct> getListAutorisation() {
@@ -56,13 +58,12 @@ public void setConnect(Connexion connect) {
this.connect = connect;
}

public CurrentUser getUser() {
return user;
public CurrentUser2 getCurrentUser() {
return currentUser;
}

public void setUser(CurrentUser user) {
this.user = user;
public void setCurrentUser(CurrentUser2 currentUser) {
this.currentUser = currentUser;
}


}
@@ -795,7 +795,6 @@ public boolean needchangerpass() throws SQLException {
public String fchangepass() throws SQLException {
boolean sort = false;
ForgetPasswordHelper forgetPassword = new ForgetPasswordHelper();
CurrentUser user = new CurrentUser();
if (newPass == null ? confirmPass != null : !newPass.equals(confirmPass)) {
sort = true;
FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(FacesMessage.SEVERITY_ERROR, langueBean.getMsg("error") + " :", langueBean.getMsg("user.error3")));

0 comments on commit d34655d

Please sign in to comment.
You can’t perform that action at this time.