1 |
package org.tela_botanica.client.modeles.structure;
|
1 |
package org.tela_botanica.client.modeles.structure;
|
2 |
|
2 |
|
3 |
import java.util.HashMap;
|
3 |
import java.util.HashMap;
|
4 |
|
4 |
|
5 |
import org.tela_botanica.client.Mediateur;
|
5 |
import org.tela_botanica.client.Mediateur;
|
6 |
import org.tela_botanica.client.RegistreId;
|
6 |
import org.tela_botanica.client.RegistreId;
|
7 |
import org.tela_botanica.client.http.JsonRestRequestBuilder;
|
7 |
import org.tela_botanica.client.http.JsonRestRequestBuilder;
|
8 |
import org.tela_botanica.client.http.JsonRestRequestCallback;
|
8 |
import org.tela_botanica.client.http.JsonRestRequestCallback;
|
9 |
import org.tela_botanica.client.interfaces.Rafraichissable;
|
9 |
import org.tela_botanica.client.interfaces.Rafraichissable;
|
10 |
import org.tela_botanica.client.modeles.Information;
|
10 |
import org.tela_botanica.client.modeles.Information;
|
11 |
import org.tela_botanica.client.modeles.personne.PersonneListe;
|
11 |
import org.tela_botanica.client.modeles.personne.PersonneListe;
|
12 |
import org.tela_botanica.client.modeles.projet.ProjetListe;
|
12 |
import org.tela_botanica.client.modeles.projet.ProjetListe;
|
13 |
import org.tela_botanica.client.util.UtilDAO;
|
13 |
import org.tela_botanica.client.util.UtilDAO;
|
14 |
|
14 |
|
15 |
import com.extjs.gxt.ui.client.Registry;
|
15 |
import com.extjs.gxt.ui.client.Registry;
|
16 |
import com.google.gwt.core.client.GWT;
|
16 |
import com.google.gwt.core.client.GWT;
|
17 |
import com.google.gwt.http.client.URL;
|
17 |
import com.google.gwt.http.client.URL;
|
18 |
import com.google.gwt.json.client.JSONArray;
|
18 |
import com.google.gwt.json.client.JSONArray;
|
19 |
import com.google.gwt.json.client.JSONObject;
|
19 |
import com.google.gwt.json.client.JSONObject;
|
20 |
import com.google.gwt.json.client.JSONValue;
|
20 |
import com.google.gwt.json.client.JSONValue;
|
21 |
|
21 |
|
22 |
public class StructureAsyncDao {
|
22 |
public class StructureAsyncDao {
|
23 |
private static final String SERVICE_NOM = "CoelStructure";
|
23 |
private static final String SERVICE_NOM = "CoelStructure";
|
24 |
|
24 |
|
25 |
private String utilisateurId = null;
|
25 |
private String utilisateurId = null;
|
26 |
private Rafraichissable vueARafraichir = null;
|
26 |
private Rafraichissable vueARafraichir = null;
|
27 |
|
27 |
|
28 |
public StructureAsyncDao(Rafraichissable vue) {
|
28 |
public StructureAsyncDao(Rafraichissable vue) {
|
29 |
vueARafraichir = vue;
|
29 |
vueARafraichir = vue;
|
30 |
utilisateurId = ((Mediateur) Registry.get(RegistreId.MEDIATEUR)).getUtilisateurId();
|
30 |
utilisateurId = ((Mediateur) Registry.get(RegistreId.MEDIATEUR)).getUtilisateurId();
|
31 |
GWT.log("ID utilisateur :"+utilisateurId, null);
|
31 |
GWT.log("ID utilisateur :"+utilisateurId, null);
|
32 |
}
|
32 |
}
|
33 |
|
33 |
|
34 |
public void selectionner(final String projetId, final String structureId, final String nomStructure, final int pageCourante, final int nbElements) {
|
34 |
public void selectionner(final String projetId, final String structureId, final String nomStructure, final int pageCourante, final int nbElements) {
|
35 |
String[] parametres = {projetId, structureId, nomStructure};
|
35 |
String[] parametres = {projetId, structureId, nomStructure};
|
36 |
|
36 |
|
37 |
HashMap<String, String> restrictions = new HashMap<String, String>();
|
37 |
HashMap<String, String> restrictions = new HashMap<String, String>();
|
38 |
restrictions.put("start", String.valueOf(pageCourante*nbElements));
|
38 |
restrictions.put("start", String.valueOf(pageCourante*nbElements));
|
39 |
if (nbElements != -1) {
|
39 |
if (nbElements != -1) {
|
40 |
restrictions.put("limit", String.valueOf(nbElements));
|
40 |
restrictions.put("limit", String.valueOf(nbElements));
|
41 |
}
|
41 |
}
|
42 |
|
42 |
|
43 |
final JsonRestRequestBuilder rb = UtilDAO.construireRequete(SERVICE_NOM, parametres, restrictions);
|
43 |
final JsonRestRequestBuilder rb = UtilDAO.construireRequete(SERVICE_NOM, parametres, restrictions);
|
44 |
rb.envoyerRequete(null, new JsonRestRequestCallback() {
|
44 |
rb.envoyerRequete(null, new JsonRestRequestCallback() {
|
45 |
@Override
|
45 |
@Override
|
46 |
public void surReponse(JSONValue responseValue) {
|
46 |
public void surReponse(JSONValue responseValue) {
|
47 |
if (responseValue != null) {
|
47 |
if (responseValue != null) {
|
48 |
Information info = new Information("selection_structure");
|
48 |
Information info = new Information("selection_structure");
|
49 |
// Si la requête est un succès, reception d'un objet ou d'un tableau
|
49 |
// Si la requête est un succès, reception d'un objet ou d'un tableau
|
50 |
JSONArray responseArray = responseValue.isArray();
|
50 |
JSONArray responseArray = responseValue.isArray();
|
51 |
if (responseArray.get(1).isObject() != null) {
|
51 |
if (responseArray.get(1).isObject() != null) {
|
52 |
final JSONObject reponse = responseArray.get(1).isObject();
|
52 |
final JSONObject reponse = responseArray.get(1).isObject();
|
53 |
Structure structure = new Structure(reponse);
|
53 |
Structure structure = new Structure(reponse);
|
54 |
StructureConservation structureConservation = new StructureConservation(reponse);
|
54 |
StructureConservation structureConservation = new StructureConservation(reponse);
|
55 |
StructureValorisation structureValorisation = new StructureValorisation(reponse);
|
55 |
StructureValorisation structureValorisation = new StructureValorisation(reponse);
|
56 |
info.setDonnee(0, structure);
|
56 |
info.setDonnee(0, structure);
|
57 |
info.setDonnee(1, structureConservation);
|
57 |
info.setDonnee(1, structureConservation);
|
58 |
info.setDonnee(2, structureValorisation);
|
58 |
info.setDonnee(2, structureValorisation);
|
59 |
vueARafraichir.rafraichir(info);
|
59 |
vueARafraichir.rafraichir(info);
|
60 |
} else if (responseArray.get(1).isArray() != null) {
|
60 |
} else if (responseArray.get(1).isArray() != null) {
|
61 |
final JSONArray reponse = responseValue.isArray();
|
61 |
final JSONArray reponse = responseValue.isArray();
|
62 |
StructureListe structures; // = new StructureListe(reponse);
|
62 |
StructureListe structures; // = new StructureListe(reponse);
|
63 |
if (reponse.get(1).isObject() != null) {
|
63 |
if (reponse.get(1).isObject() != null) {
|
64 |
structures = new StructureListe(reponse.get(1).isArray());
|
64 |
structures = new StructureListe(reponse.get(1).isArray());
|
65 |
} else {
|
65 |
} else {
|
66 |
structures = new StructureListe(reponse.get(1).isArray(), reponse.get(0).isNumber(), vueARafraichir);
|
66 |
structures = new StructureListe(reponse.get(1).isArray(), reponse.get(0).isNumber(), vueARafraichir);
|
67 |
}
|
67 |
}
|
68 |
structures.setTaillePage(nbElements);
|
68 |
structures.setTaillePage(nbElements);
|
69 |
structures.setPageCourante(pageCourante);
|
69 |
structures.setPageCourante(pageCourante);
|
70 |
info.setDonnee(0, structures);
|
70 |
info.setDonnee(0, structures);
|
71 |
|
71 |
|
72 |
vueARafraichir.rafraichir(structures);
|
72 |
vueARafraichir.rafraichir(structures);
|
73 |
} else {
|
73 |
} else {
|
74 |
GWT.log(rb.getUrl()+"\n\tLa réponse n'est pas un objet ou un talbeau JSON et vaut : "+responseValue.toString(), null);
|
74 |
GWT.log(rb.getUrl()+"\n\tLa réponse n'est pas un objet ou un talbeau JSON et vaut : "+responseValue.toString(), null);
|
75 |
}
|
75 |
}
|
76 |
} else {
|
76 |
} else {
|
77 |
if (structureId == null) {
|
77 |
if (structureId == null) {
|
78 |
// Dans le cas, où nous demandons toutes les institutions et qu'il n'y en a pas, nous retournons un objet vide
|
78 |
// Dans le cas, où nous demandons toutes les institutions et qu'il n'y en a pas, nous retournons un objet vide
|
79 |
StructureListe structures = new StructureListe(0);
|
79 |
StructureListe structures = new StructureListe(0);
|
80 |
vueARafraichir.rafraichir(structures);
|
80 |
vueARafraichir.rafraichir(structures);
|
81 |
}
|
81 |
}
|
82 |
}
|
82 |
}
|
83 |
}
|
83 |
}
|
84 |
});
|
84 |
});
|
85 |
}
|
85 |
}
|
86 |
|
86 |
|
87 |
public void ajouter(final Structure str, StructureConservation conservation, StructureValorisation valorisation) {
|
87 |
public void ajouter(final Structure str, StructureConservation conservation, StructureValorisation valorisation) {
|
88 |
String postDonneesEncodees = construirePost(null, str, conservation, valorisation);
|
88 |
String postDonneesEncodees = construirePost(null, str, conservation, valorisation);
|
89 |
|
89 |
|
90 |
final JsonRestRequestBuilder rb = UtilDAO.construireRequetePost(SERVICE_NOM);
|
90 |
final JsonRestRequestBuilder rb = UtilDAO.construireRequetePost(SERVICE_NOM);
|
91 |
rb.envoyerRequete(postDonneesEncodees, new JsonRestRequestCallback() {
|
91 |
rb.envoyerRequete(postDonneesEncodees, new JsonRestRequestCallback() {
|
92 |
@Override
|
92 |
@Override
|
93 |
public void surReponse(JSONValue responseValue) {
|
93 |
public void surReponse(JSONValue responseValue) {
|
94 |
if (responseValue.isString() != null) {
|
94 |
if (responseValue.isString() != null) {
|
95 |
Information info = new Information("ajout_structure");
|
95 |
Information info = new Information("ajout_structure");
|
96 |
String structureIdOuMessage = responseValue.isString().stringValue();
|
96 |
String structureIdOuMessage = responseValue.isString().stringValue();
|
97 |
if (structureIdOuMessage.matches("^[0-9]+$")) {
|
97 |
if (structureIdOuMessage.matches("^[0-9]+$")) {
|
98 |
info.setDonnee(structureIdOuMessage);
|
98 |
info.setDonnee(structureIdOuMessage);
|
99 |
} else {
|
99 |
} else {
|
100 |
info.setMessage(structureIdOuMessage);
|
100 |
info.setMessage(structureIdOuMessage);
|
101 |
}
|
101 |
}
|
102 |
vueARafraichir.rafraichir(info);
|
102 |
vueARafraichir.rafraichir(info);
|
103 |
} else {
|
103 |
} else {
|
104 |
GWT.log(rb.getUrl()+"\n\tLa réponse n'est pas une chaine JSON.", null);
|
104 |
GWT.log(rb.getUrl()+"\n\tLa réponse n'est pas une chaine JSON.", null);
|
105 |
}
|
105 |
}
|
106 |
}
|
106 |
}
|
107 |
});
|
107 |
});
|
108 |
}
|
108 |
}
|
109 |
|
109 |
|
110 |
public void modifier(String structureId, Structure str, StructureConservation conservation, StructureValorisation valorisation) {
|
110 |
public void modifier(String structureId, Structure str, StructureConservation conservation, StructureValorisation valorisation) {
|
111 |
String postDonneesEncodees = construirePost(structureId, str, conservation, valorisation);
|
111 |
String postDonneesEncodees = construirePost(structureId, str, conservation, valorisation);
|
112 |
String[] parametres = {structureId};
|
112 |
String[] parametres = {structureId};
|
113 |
final JsonRestRequestBuilder rb = UtilDAO.construireRequetePost(SERVICE_NOM, parametres);
|
113 |
final JsonRestRequestBuilder rb = UtilDAO.construireRequetePost(SERVICE_NOM, parametres);
|
114 |
rb.envoyerRequete(postDonneesEncodees, new JsonRestRequestCallback() {
|
114 |
rb.envoyerRequete(postDonneesEncodees, new JsonRestRequestCallback() {
|
115 |
@Override
|
115 |
@Override
|
116 |
public void surReponse(JSONValue responseValue) {
|
116 |
public void surReponse(JSONValue responseValue) {
|
117 |
// Si la requête est un succès, reception d'une chaine
|
117 |
// Si la requête est un succès, reception d'une chaine
|
118 |
if (responseValue.isString() != null) {
|
118 |
if (responseValue.isString() != null) {
|
119 |
Information info = new Information("modif_structure");
|
119 |
Information info = new Information("modif_structure");
|
120 |
info.setMessage(responseValue.isString().stringValue());
|
120 |
info.setMessage(responseValue.isString().stringValue());
|
121 |
vueARafraichir.rafraichir(info);
|
121 |
vueARafraichir.rafraichir(info);
|
122 |
} else {
|
122 |
} else {
|
123 |
GWT.log(rb.getUrl()+"\n\tLa réponse n'est pas une chaine JSON.", null);
|
123 |
GWT.log(rb.getUrl()+"\n\tLa réponse n'est pas une chaine JSON.", null);
|
124 |
}
|
124 |
}
|
125 |
}
|
125 |
}
|
126 |
});
|
126 |
});
|
127 |
}
|
127 |
}
|
128 |
|
128 |
|
129 |
public void supprimer(String structuresId) {
|
129 |
public void supprimer(String structuresId) {
|
130 |
String[] parametres = {utilisateurId, structuresId};
|
130 |
String[] parametres = {utilisateurId, structuresId};
|
131 |
final JsonRestRequestBuilder rb = UtilDAO.construireRequetePost(SERVICE_NOM, parametres);
|
131 |
final JsonRestRequestBuilder rb = UtilDAO.construireRequetePost(SERVICE_NOM, parametres);
|
132 |
rb.envoyerRequeteSuppression(new JsonRestRequestCallback() {
|
132 |
rb.envoyerRequeteSuppression(new JsonRestRequestCallback() {
|
133 |
@Override
|
133 |
@Override
|
134 |
public void surReponse(JSONValue responseValue) {
|
134 |
public void surReponse(JSONValue responseValue) {
|
135 |
if (responseValue.isString() != null) {
|
135 |
if (responseValue.isString() != null) {
|
136 |
Information info = new Information("suppression_structure");
|
136 |
Information info = new Information("suppression_structure");
|
137 |
info.setMessage(responseValue.isString().stringValue());
|
137 |
info.setMessage(responseValue.isString().stringValue());
|
138 |
vueARafraichir.rafraichir(info);
|
138 |
vueARafraichir.rafraichir(info);
|
139 |
} else {
|
139 |
} else {
|
140 |
GWT.log(rb.getUrl()+"\n\tLa réponse n'est pas une chaine JSON.", null);
|
140 |
GWT.log(rb.getUrl()+"\n\tLa réponse n'est pas une chaine JSON.", null);
|
141 |
}
|
141 |
}
|
142 |
}
|
142 |
}
|
143 |
});
|
143 |
});
|
144 |
}
|
144 |
}
|
145 |
|
145 |
|
146 |
private String construirePost(String structureId, Structure str, StructureConservation conservation, StructureValorisation valorisation) {
|
146 |
private String construirePost(String structureId, Structure str, StructureConservation conservation, StructureValorisation valorisation) {
|
147 |
String postDonnees = "cmhl_ce_modifier_par=" + URL.encodeComponent(utilisateurId);
|
147 |
String postDonnees = "cmhl_ce_modifier_par=" + URL.encodeComponent(utilisateurId);
|
148 |
|
148 |
|
149 |
if (str != null) {
|
149 |
if (str != null) {
|
150 |
if (structureId != null) {
|
150 |
if (structureId != null) {
|
151 |
postDonnees += "&cs_id_structure=" + URL.encodeComponent(structureId);
|
151 |
postDonnees += "&cs_id_structure=" + URL.encodeComponent(structureId);
|
152 |
}
|
152 |
}
|
153 |
postDonnees += "&cpr_abreviation=" + URL.encodeComponent(((ProjetListe) Registry.get(RegistreId.PROJETS)).get(str.getIdProjet()).getAbreviation());
|
153 |
postDonnees += "&cpr_abreviation=" + URL.encodeComponent(((ProjetListe) Registry.get(RegistreId.PROJETS)).get(str.getIdProjet()).getAbreviation());
|
154 |
postDonnees += "&cs_ce_projet=" + URL.encodeComponent(str.getIdProjet()) +
|
154 |
postDonnees += "&cs_ce_projet=" + URL.encodeComponent(str.getIdProjet()) +
|
155 |
"&cs_ce_mere=" + URL.encodeComponent(str.getIdMere()) +
|
155 |
"&cs_ce_mere=" + URL.encodeComponent(str.getIdMere()) +
|
156 |
"&cs_guid=" + URL.encodeComponent(str.getGuid()) +
|
156 |
"&cs_guid=" + URL.encodeComponent(str.getGuid()) +
|
157 |
"&cs_truk_identifiant_alternatif=" + URL.encodeComponent(str.getIdAlternatif()) +
|
157 |
"&cs_truk_identifiant_alternatif=" + URL.encodeComponent(str.getIdAlternatif()) +
|
158 |
"&cs_nom=" + URL.encodeComponent(str.getNom()) +
|
158 |
"&cs_nom=" + URL.encodeComponent(str.getNom()) +
|
159 |
"&cs_truk_nom_alternatif=" + URL.encodeComponent(str.getNomAlternatif()) +
|
159 |
"&cs_truk_nom_alternatif=" + URL.encodeComponent(str.getNomAlternatif()) +
|
- |
|
160 |
"&cs_description=" + URL.encodeComponent(str.getDescription()) +
|
160 |
"&cs_ce_type=" + URL.encodeComponent(str.getType()) +
|
161 |
"&cs_ce_type=" + URL.encodeComponent(str.getType()) +
|
161 |
"&cs_ce_truk_type_prive=" + URL.encodeComponent(str.getTypePrive()) +
|
162 |
"&cs_ce_truk_type_prive=" + URL.encodeComponent(str.getTypePrive()) +
|
162 |
"&cs_ce_truk_type_public=" + URL.encodeComponent(str.getTypePublic()) +
|
163 |
"&cs_ce_truk_type_public=" + URL.encodeComponent(str.getTypePublic()) +
|
163 |
"&cs_adresse_01=" + URL.encodeComponent(str.getAdresse()) +
|
164 |
"&cs_adresse_01=" + URL.encodeComponent(str.getAdresse()) +
|
164 |
"&cs_adresse_02=" + URL.encodeComponent(str.getAdresseComplement()) +
|
165 |
"&cs_adresse_02=" + URL.encodeComponent(str.getAdresseComplement()) +
|
165 |
"&cs_date_fondation=" + URL.encodeComponent(str.getDateFondationFormatMysql()) +
|
166 |
"&cs_date_fondation=" + URL.encodeComponent(str.getDateFondationFormatMysql()) +
|
166 |
"&cs_code_postal=" + URL.encodeComponent(str.getCodePostal()) +
|
167 |
"&cs_code_postal=" + URL.encodeComponent(str.getCodePostal()) +
|
167 |
"&cs_ville=" + URL.encodeComponent(str.getVille()) +
|
168 |
"&cs_ville=" + URL.encodeComponent(str.getVille()) +
|
168 |
"&cs_ce_truk_region=" + URL.encodeComponent(str.get("ce_truk_region").toString()) +
|
169 |
"&cs_ce_truk_region=" + URL.encodeComponent(str.get("ce_truk_region").toString()) +
|
169 |
"&cs_ce_truk_pays=" + URL.encodeComponent(str.getPays()) +
|
170 |
"&cs_ce_truk_pays=" + URL.encodeComponent(str.getPays()) +
|
- |
|
171 |
"&cs_latitude=" + URL.encodeComponent(str.getLatitude()) +
|
- |
|
172 |
"&cs_longitude=" + URL.encodeComponent(str.getLongitude()) +
|
170 |
"&cs_truk_telephone=" + URL.encodeComponent(str.getTelephone()) +
|
173 |
"&cs_truk_telephone=" + URL.encodeComponent(str.getTelephone()) +
|
171 |
"&cs_truk_url=" + URL.encodeComponent(str.getUrl()) +
|
174 |
"&cs_truk_url=" + URL.encodeComponent(str.getUrl()) +
|
172 |
"&cs_nbre_personne=" + URL.encodeComponent(Integer.toString(str.getNbrePersonne())) +
|
175 |
"&cs_nbre_personne=" + URL.encodeComponent(Integer.toString(str.getNbrePersonne())) +
|
- |
|
176 |
"&cs_condition_acces=" + URL.encodeComponent(str.getConditionAcces())+
|
- |
|
177 |
"&cs_condition_usage=" + URL.encodeComponent(str.getConditionUsage())+
|
173 |
"&cs_courriel=" + URL.encodeComponent(str.getCourriel());
|
178 |
"&cs_courriel=" + URL.encodeComponent(str.getCourriel());
|
174 |
}
|
179 |
}
|
175 |
if (conservation != null) {
|
180 |
if (conservation != null) {
|
176 |
if (structureId != null) {
|
181 |
if (structureId != null) {
|
177 |
postDonnees += "&csc_id_structure=" + URL.encodeComponent(structureId);
|
182 |
postDonnees += "&csc_id_structure=" + URL.encodeComponent(structureId);
|
178 |
}
|
183 |
}
|
179 |
postDonnees += "&csc_mark_formation=" + URL.encodeComponent(conservation.getFormation()) +
|
184 |
postDonnees += "&csc_mark_formation=" + URL.encodeComponent(conservation.getFormation()) +
|
180 |
"&csc_formation=" + URL.encodeComponent(conservation.getFormationInfo()) +
|
185 |
"&csc_formation=" + URL.encodeComponent(conservation.getFormationInfo()) +
|
181 |
"&csc_mark_formation_interet=" + URL.encodeComponent(conservation.getFormationInteret()) +
|
186 |
"&csc_mark_formation_interet=" + URL.encodeComponent(conservation.getFormationInteret()) +
|
182 |
"&csc_truk_stockage_local=" + URL.encodeComponent(conservation.getStockageLocal()) +
|
187 |
"&csc_truk_stockage_local=" + URL.encodeComponent(conservation.getStockageLocal()) +
|
183 |
"&csc_truk_stockage_meuble=" + URL.encodeComponent(conservation.getStockageMeuble()) +
|
188 |
"&csc_truk_stockage_meuble=" + URL.encodeComponent(conservation.getStockageMeuble()) +
|
184 |
"&csc_truk_stockage_parametre=" + URL.encodeComponent(conservation.getStockageParametre()) +
|
189 |
"&csc_truk_stockage_parametre=" + URL.encodeComponent(conservation.getStockageParametre()) +
|
185 |
"&csc_mark_collection_commune=" + URL.encodeComponent(conservation.getCollectionCommune()) +
|
190 |
"&csc_mark_collection_commune=" + URL.encodeComponent(conservation.getCollectionCommune()) +
|
186 |
"&csc_truk_collection_autre=" + URL.encodeComponent(conservation.getCollectionAutre()) +
|
191 |
"&csc_truk_collection_autre=" + URL.encodeComponent(conservation.getCollectionAutre()) +
|
187 |
"&csc_mark_acces_controle=" + URL.encodeComponent(conservation.getAccesControle()) +
|
192 |
"&csc_mark_acces_controle=" + URL.encodeComponent(conservation.getAccesControle()) +
|
188 |
"&csc_mark_restauration=" + URL.encodeComponent(conservation.getRestauration()) +
|
193 |
"&csc_mark_restauration=" + URL.encodeComponent(conservation.getRestauration()) +
|
189 |
"&csc_truk_restauration_operation=" + URL.encodeComponent(conservation.getRestaurationOperation()) +
|
194 |
"&csc_truk_restauration_operation=" + URL.encodeComponent(conservation.getRestaurationOperation()) +
|
190 |
"&csc_ce_materiel_conservation=" + URL.encodeComponent(conservation.getMaterielConservation()) +
|
195 |
"&csc_ce_materiel_conservation=" + URL.encodeComponent(conservation.getMaterielConservation()) +
|
191 |
"&csc_truk_materiel_autre=" + URL.encodeComponent(conservation.getMaterielAutre()) +
|
196 |
"&csc_truk_materiel_autre=" + URL.encodeComponent(conservation.getMaterielAutre()) +
|
192 |
"&csc_mark_traitement=" + URL.encodeComponent(conservation.getTraitement()) +
|
197 |
"&csc_mark_traitement=" + URL.encodeComponent(conservation.getTraitement()) +
|
193 |
"&csc_truk_traitement=" + URL.encodeComponent(conservation.getTraitements()) +
|
198 |
"&csc_truk_traitement=" + URL.encodeComponent(conservation.getTraitements()) +
|
194 |
"&csc_mark_acquisition_collection=" + URL.encodeComponent(conservation.getAcquisitionCollection()) +
|
199 |
"&csc_mark_acquisition_collection=" + URL.encodeComponent(conservation.getAcquisitionCollection()) +
|
195 |
"&csc_mark_acquisition_echantillon=" + URL.encodeComponent(conservation.getAcquisitionEchantillon()) +
|
200 |
"&csc_mark_acquisition_echantillon=" + URL.encodeComponent(conservation.getAcquisitionEchantillon()) +
|
196 |
"&csc_mark_acquisition_traitement=" + URL.encodeComponent(conservation.getAcquisitionTraitement()) +
|
201 |
"&csc_mark_acquisition_traitement=" + URL.encodeComponent(conservation.getAcquisitionTraitement()) +
|
197 |
"&csc_truk_acquisition_traitement_poison=" + URL.encodeComponent(conservation.getAcquisitionTraitementPoison()) +
|
202 |
"&csc_truk_acquisition_traitement_poison=" + URL.encodeComponent(conservation.getAcquisitionTraitementPoison()) +
|
198 |
"&csc_truk_acquisition_traitement_insecte=" + URL.encodeComponent(conservation.getAcquisitionTraitementInsecte());
|
203 |
"&csc_truk_acquisition_traitement_insecte=" + URL.encodeComponent(conservation.getAcquisitionTraitementInsecte());
|
199 |
}
|
204 |
}
|
200 |
if (valorisation != null) {
|
205 |
if (valorisation != null) {
|
201 |
if (structureId != null) {
|
206 |
if (structureId != null) {
|
202 |
postDonnees += "&csv_id_structure=" + URL.encodeComponent(structureId);
|
207 |
postDonnees += "&csv_id_structure=" + URL.encodeComponent(structureId);
|
203 |
}
|
208 |
}
|
204 |
postDonnees += "&csv_mark_action=" + URL.encodeComponent(valorisation.getAction()) +
|
209 |
postDonnees += "&csv_mark_action=" + URL.encodeComponent(valorisation.getAction()) +
|
205 |
"&csv_truk_action=" + URL.encodeComponent(valorisation.getActionInfo()) +
|
210 |
"&csv_truk_action=" + URL.encodeComponent(valorisation.getActionInfo()) +
|
206 |
"&csv_publication=" + URL.encodeComponent(valorisation.getPublication()) +
|
211 |
"&csv_publication=" + URL.encodeComponent(valorisation.getPublication()) +
|
207 |
"&csv_collection_autre=" + URL.encodeComponent(valorisation.getCollectionAutre()) +
|
212 |
"&csv_collection_autre=" + URL.encodeComponent(valorisation.getCollectionAutre()) +
|
208 |
"&csv_mark_action_future=" + URL.encodeComponent(valorisation.getActionFuture()) +
|
213 |
"&csv_mark_action_future=" + URL.encodeComponent(valorisation.getActionFuture()) +
|
209 |
"&csv_action_future=" + URL.encodeComponent(valorisation.getActionFutureInfo()) +
|
214 |
"&csv_action_future=" + URL.encodeComponent(valorisation.getActionFutureInfo()) +
|
210 |
"&csv_mark_recherche=" + URL.encodeComponent(valorisation.getRecherche()) +
|
215 |
"&csv_mark_recherche=" + URL.encodeComponent(valorisation.getRecherche()) +
|
211 |
"&csv_truk_recherche_provenance=" + URL.encodeComponent(valorisation.getRechercheProvenance()) +
|
216 |
"&csv_truk_recherche_provenance=" + URL.encodeComponent(valorisation.getRechercheProvenance()) +
|
212 |
"&csv_truk_recherche_type=" + URL.encodeComponent(valorisation.getRechercheType()) +
|
217 |
"&csv_truk_recherche_type=" + URL.encodeComponent(valorisation.getRechercheType()) +
|
213 |
"&csv_mark_acces_ss_motif=" + URL.encodeComponent(valorisation.getAccesSansMotif()) +
|
218 |
"&csv_mark_acces_ss_motif=" + URL.encodeComponent(valorisation.getAccesSansMotif()) +
|
214 |
"&csv_acces_ss_motif=" + URL.encodeComponent(valorisation.getAccesSansMotifInfo()) +
|
219 |
"&csv_acces_ss_motif=" + URL.encodeComponent(valorisation.getAccesSansMotifInfo()) +
|
215 |
"&csv_mark_visite_avec_motif=" + URL.encodeComponent(valorisation.getVisiteAvecMotif()) +
|
220 |
"&csv_mark_visite_avec_motif=" + URL.encodeComponent(valorisation.getVisiteAvecMotif()) +
|
216 |
"&csv_visite_avec_motif=" + URL.encodeComponent(valorisation.getVisiteAvecMotifInfo());
|
221 |
"&csv_visite_avec_motif=" + URL.encodeComponent(valorisation.getVisiteAvecMotifInfo());
|
217 |
}
|
222 |
}
|
218 |
return postDonnees;
|
223 |
return postDonnees;
|
219 |
}
|
224 |
}
|
220 |
}
|
225 |
}
|