Subversion Repositories eFlore/Applications.cel

Rev

Rev 21 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 21 Rev 32
Line 52... Line 52...
52
		
52
		
53
 
53
 
Line 54... Line -...
54
//		private void addElement(String nom_sel, String num_nom_sel, String nom_ret,
-
 
55
	//			String num_nom_ret, String num_taxon, String famille,final String loc, String id_location,String dat, String lieu, String sta,  String mil, String comment) {
54
//		private void addElement(String nom_sel, String num_nom_sel, String nom_ret,
-
 
55
	//			String num_nom_ret, String num_taxon, String famille,final String loc, String id_location,String dat, String lieu, String sta,  String mil, String comment) {
56
 
56
 
57
 
57
			RequestBuilder rb = new RequestBuilder(RequestBuilder.POST,oModele.getConfig().getServiceBaseUrl()+ "/Inventory/") ;
58
			HTTPRequest.asyncPost(oModele.getConfig().getServiceBaseUrl()+ "/Inventory/", "identifiant="
58
			String postData = "identifiant="
59
					+ utilisateur + "&nom_sel=" + URL.encodeComponent(obs.getNomSaisi()) + "&num_nom_sel=" + obs.getNumeroNomenclaturalSaisi()
59
				+ utilisateur + "&nom_sel=" + URL.encodeComponent(obs.getNomSaisi()) + "&num_nom_sel=" + obs.getNumeroNomenclaturalSaisi()
-
 
60
				+ "&nom_ret=" + URL.encodeComponent(obs.getNomRetenu()) + "&num_nom_ret=" + obs.getNumeroNomenclaturalRetenu()
-
 
61
				+ "&num_taxon=" + obs.getNumeroTaxonomique() + "&famille=" + URL.encodeComponent(obs.getFamille()) + "&location=" + URL.encodeComponent(obs.getLocalite()) + "&id_location=" + obs.getIdentifiantLocalite() + "&date_observation=" +  obs.getDate()
Line -... Line 62...
-
 
62
				+ "&lieudit="+ URL.encodeComponent(obs.getLieudit()) + "&station="+ URL.encodeComponent(obs.getLieudit()) +"&milieu="+ URL.encodeComponent(obs.getMilieu()) + "&commentaire="+ URL.encodeComponent(obs.getCommentaire()) ;
-
 
63
 
-
 
64
			try {
-
 
65
				
-
 
66
				rb.sendRequest(postData, new RequestCallback() {
-
 
67
 
-
 
68
					public void onError(Request request, Throwable exception) {
-
 
69
						// TODO Auto-generated method stub
60
					+ "&nom_ret=" + URL.encodeComponent(obs.getNomRetenu()) + "&num_nom_ret=" + obs.getNumeroNomenclaturalRetenu()
70
						
Line 61... Line -...
61
					+ "&num_taxon=" + obs.getNumeroTaxonomique() + "&famille=" + URL.encodeComponent(obs.getFamille()) + "&location=" + URL.encodeComponent(obs.getLocalite()) + "&id_location=" + obs.getIdentifiantLocalite() + "&date_observation=" +  obs.getDate()
-
 
62
					+ "&lieudit="+ URL.encodeComponent(obs.getLieudit()) + "&station="+ URL.encodeComponent(obs.getLieudit()) +"&milieu="+ URL.encodeComponent(obs.getMilieu()) + "&commentaire="+ URL.encodeComponent(obs.getCommentaire()),
71
					}
-
 
72
 
63
 
73
					public void onResponseReceived(Request request,
-
 
74
							Response response) {
-
 
75
						
64
			new ResponseTextHandler() {
76
						r.rafraichir(obs,true);
65
 
-
 
Line -... Line 77...
-
 
77
						
-
 
78
					}
-
 
79
					
-
 
80
					
Line 66... Line 81...
66
				public void onCompletion(String str) {
81
				}) ;
67
						r.rafraichir(obs,true);
82