Subversion Repositories eFlore/Archives.cel-v1

Rev

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

Rev 11 Rev 12
Line 61... Line 61...
61
 
61
 
Line 62... Line 62...
62
		public final Button gotoPrev = new Button("<", this);
62
		public final Button gotoPrev = new Button("<", this);
Line -... Line 63...
-
 
63
 
63
 
64
		public final Button gotoEnd = new Button(">>", this);
Line 64... Line 65...
64
		public final Button gotoEnd = new Button(">>", this);
65
		
-
 
66
		 
-
 
67
		public final HTML status = new HTML();
65
 
68
		
66
		public final HTML status = new HTML();
69
 
67
		
70
		public NavBar() {
Line 68... Line 71...
68
 
71
			
Line 95... Line 98...
95
			
98
			
Line -... Line 99...
-
 
99
			
96
			
100
			
Line -... Line 101...
-
 
101
			VerticalPanel actions = new VerticalPanel();
-
 
102
			
-
 
103
			
-
 
104
			HorizontalPanel actionButton = new HorizontalPanel();
-
 
105
			
-
 
106
			HTML addButton = new HTML("Nouvelle observation");
-
 
107
			addButton.setStyleName("html_button");
-
 
108
		    addButton.addClickListener(
-
 
109
		    
-
 
110
		    		new ClickListener() {
-
 
111
		    			
-
 
112
		    			public void onClick(Widget w) {
-
 
113
		    				 openEntryPanel();
-
 
114
		    			}
-
 
115
		    			
-
 
116
		    		}
-
 
117
		    
-
 
118
		    
97
			
119
		    );
98
			VerticalPanel actions = new VerticalPanel();
120
 
99
			
121
			
100
			HorizontalPanel actionButton = new HorizontalPanel();
122
		    actionButton.add(addButton);
101
			
123
			
Line 118... Line 140...
118
			actionButton.setSpacing(5);
140
			actionButton.setSpacing(5);
Line 119... Line 141...
119
 
141
 
Line -... Line 142...
-
 
142
			actions.add(actionButton);
-
 
143
 
-
 
144
			
-
 
145
			HorizontalPanel selections = new HorizontalPanel();
-
 
146
			
-
 
147
			selections.setSpacing(3);
-
 
148
			
-
 
149
 
-
 
150
			selections.add(new HTML("Sélection : "));
-
 
151
			
-
 
152
			Label allLabel = new Label("Tous");
-
 
153
			Label separatorLabel = new Label(",");
-
 
154
			Label noneLabel = new Label("Aucun");
-
 
155
			
-
 
156
			allLabel.setStyleName("selection_label");
-
 
157
			noneLabel.setStyleName("selection_label");
-
 
158
			
-
 
159
			selections.add(allLabel);
-
 
160
			allLabel.addClickListener(
-
 
161
				    	new ClickListener() {
-
 
162
				    		public void onClick(Widget sender) {
-
 
163
				    			selectAll();
-
 
164
				    		}
-
 
165
				     	}
-
 
166
			);		
-
 
167
			
-
 
168
			selections.add(separatorLabel);
-
 
169
			
-
 
170
			selections.add(noneLabel);
-
 
171
			noneLabel.addClickListener(
-
 
172
				    	new ClickListener() {
-
 
173
				    		public void onClick(Widget sender) {
-
 
174
				    			deselectAll();
-
 
175
				    		}
-
 
176
				     	}
-
 
177
			);		
-
 
178
			
-
 
179
 
-
 
180
			actionButton.add(selections);
-
 
181
			
120
			actions.add(actionButton);
182
 
Line -... Line 183...
-
 
183
			
-
 
184
 
-
 
185
			bar.add(actions, DockPanel.WEST);
-
 
186
 
-
 
187
			
-
 
188
		
-
 
189
			
-
 
190
			
121
 
191
		}
Line -... Line 192...
-
 
192
		
-
 
193
		  
122
 
194
		private void openEntryPanel() {
123
			bar.add(actions, DockPanel.WEST);
195
 
124
 
196
		             mediator.onEntryClick();
125
			
197
 
126
			
198
		}
Line 176... Line 248...
176
 
248
 
Line 177... Line 249...
177
	private NavBar navBar=null;
249
	private NavBar navBar=null;
Line 178... Line -...
178
	
-
 
179
	private Mediator mediator = null;
-
 
180
	
-
 
181
	// Optimization
-
 
182
	int sizeChecked=0;
-
 
183
	int itemDeleted=0;
-
 
184
	
-
 
185
	
-
 
186
	// Données alimentant la saisie : texte et valeur localité, texte et valeur communes
-
 
187
	
-
 
188
 	private String nameText=null;
-
 
189
 	private String nameValue=null;
-
 
190
 	private String locationText=null;
-
 
191
 	private String locationValue=null;
-
 
192
 
250
	
-
 
251
	private Mediator mediator = null;
Line 193... Line 252...
193
 	// 
252
 
Line 194... Line 253...
194
 	
253
	private String location = "all";
Line 213... Line 272...
213
 
272
 
214
		header.setCellSpacing(0);
273
		header.setCellSpacing(0);
215
		header.setCellPadding(2);
274
		header.setCellPadding(2);
Line 216... Line 275...
216
		header.setWidth("100%");
275
		header.setWidth("100%");
Line 217... Line 276...
217
 
276
 
218
		header.setStyleName("taxon-ListHeader");
277
		header.setStyleName("inventoryItem-ListHeader");
219
 
278
 
220
		header.setText(0, 0, "");
279
		header.setText(0, 0, "");
221
		header.setText(0, 1, "Nom saisi");
280
		header.setHTML(0, 1, "Plante observée");
222
		header.setText(0, 2, "Nom retenu");
281
		header.setHTML(0, 2, "Référence retenue");
223
		header.setHTML(0, 3, "Code<br>Nomenclatural");
282
		header.setHTML(0, 3, "R&eacute;f&eacute;rence<br>Nomenclaturale");
Line 224... Line 283...
224
		header.setHTML(0, 4, "Code<br>Taxonomique");
283
		header.setHTML(0, 4, "R&eacute;f&eacute;rence<br>Taxonomique");
225
		header.setText(0, 5, "Famille");
284
		header.setText(0, 5, "Famille");
226
		header.setText(0, 6, "Localisation");
285
		header.setText(0, 6, "Commune");
227
 
286
 
Line 242... Line 301...
242
 
301
 
Line 243... Line 302...
243
		// Mise en forme barre navigation
302
		// Mise en forme barre navigation
Line 244... Line 303...
244
 
303
 
Line 245... Line 304...
245
		navBar.setWidth("100%");
304
		navBar.setWidth("100%");
246
 
305
 
247
		table.setStyleName("taxon-List");
306
		table.setStyleName("inventoryItem-List");
Line 248... Line -...
248
 
-
 
249
		panel.add(navBar);
-
 
250
		panel.add(header);
-
 
251
		panel.add(table);
-
 
Line 252... Line -...
252
 
-
 
253
		HorizontalPanel selections = new HorizontalPanel();
-
 
254
		
307
 
255
		selections.setSpacing(3);
308
		panel.add(navBar);
256
		
-
 
Line 257... Line -...
257
 
-
 
258
		selections.add(new HTML("S&eacute;lection : "));
-
 
Line 259... Line 309...
259
		
309
		panel.add(header);
260
		Label allLabel = new Label("Tous");
-
 
261
		Label separatorLabel = new Label(",");
-
 
262
		Label noneLabel = new Label("Aucun");
-
 
263
		
-
 
264
		allLabel.setStyleName("selection_label");
-
 
265
		noneLabel.setStyleName("selection_label");
-
 
266
		
-
 
Line 267... Line -...
267
		selections.add(allLabel);
-
 
Line 268... Line -...
268
		allLabel.addClickListener(
-
 
269
			    	new ClickListener() {
-
 
270
			    		public void onClick(Widget sender) {
-
 
271
			    			selectAll();
-
 
272
			    		}
-
 
273
			     	}
-
 
274
		);		
310
		panel.add(table);
275
		
-
 
276
		selections.add(separatorLabel);
-
 
277
		
-
 
278
		selections.add(noneLabel);
-
 
Line 279... Line -...
279
		noneLabel.addClickListener(
-
 
280
			    	new ClickListener() {
-
 
281
			    		public void onClick(Widget sender) {
-
 
Line 282... Line -...
282
			    			deselectAll();
-
 
Line 283... Line -...
283
			    		}
-
 
Line 284... Line 311...
284
			     	}
311
 
285
		);		
312
				
286
		
313
		//updateCount();
287
 
314
		// update()
Line 305... Line 332...
305
	 * @return void
332
	 * @return void
306
	 */
333
	 */
307
	public void onValidate(SourcesAutoCompleteAsyncTextBoxEvents sender,
334
	public void onValidate(SourcesAutoCompleteAsyncTextBoxEvents sender,
308
			  String str, String value) {
335
			  String str, String value) {
Line 309... Line -...
309
	
-
 
Line 310... Line 336...
310
	// Le nom de plante est requis 
336
	
311
		
337
 
312
	 if (mediator.getNameAssistant().getText().compareTo("")==0) {
338
	mediator.onAddInventoryItem();
Line 313... Line -...
313
		 return;
-
 
314
	 }
-
 
Line 315... Line 339...
315
 
339
		
316
		nameText=(mediator.getNameAssistant()).getText();
-
 
Line 317... Line -...
317
		nameValue=(mediator.getNameAssistant()).getValue();
-
 
-
 
340
	}
318
	
341
	
319
		locationText=(mediator.getLocationAssistant()).getText();
342
	
320
		locationValue=(mediator.getLocationAssistant()).getValue();
343
	public void addelement() {
321
	 
-
 
Line 322... Line 344...
322
		 // Suppresion indication departementale (on pourrait faire mieux !!)
344
	
Line 323... Line 345...
323
		 int pos=locationText.indexOf(" (" );
345
	
Line 339... Line 361...
339
				table.getFlexCellFormatter()
361
				table.getFlexCellFormatter()
340
						.setWidth(row, 1, "31%");*/
362
						.setWidth(row, 1, "31%");*/
Line 341... Line 363...
341
				
363
				
Line 342... Line 364...
342
				// Recherche complement d'information
364
				// Recherche complement d'information
Line 343... Line 365...
343
		
365
		
344
				if (nameValue !=null) {
366
				if (inventoryItem.getNomenclaturalNumber() !=null) {
Line 345... Line 367...
345
		
367
		
Line 346... Line 368...
346
					HTTPRequest.asyncGet(serviceBaseUrl + "/NameValid/" + nameValue,
368
					HTTPRequest.asyncGet(serviceBaseUrl + "/NameValid/" + inventoryItem.getNomenclaturalNumber(),
347
							new ResponseTextHandler() {
369
							new ResponseTextHandler() {
Line 348... Line 370...
348
		
370
		
349
								public void onCompletion(String strcomplete) {
371
								public void onCompletion(String strcomplete) {
350
		
372
		
351
									JSONValue jsonValue = JSONParser.parse(strcomplete);
373
									JSONValue jsonValue = JSONParser.parse(strcomplete);
352
									JSONArray jsonArray;
374
									JSONArray jsonArray;
353
		
375
		
354
									if ((jsonArray = jsonValue.isArray()) != null) {
376
									if ((jsonArray = jsonValue.isArray()) != null) {
355
										// Nom retenu, Num Nomen nom retenu, Num Taxon,
377
										// Nom retenu, Num Nomen nom retenu, Num Taxon,
356
										// Famille
378
										// Famille
357
										addElement(nameText, nameValue,
379
										addElement(inventoryItem.getName(), inventoryItem.getNomenclaturalNumber(),
358
												((JSONString) jsonArray.get(0))
380
												((JSONString) jsonArray.get(0))
359
														.stringValue(),
381
														.stringValue(),
360
												((JSONString) jsonArray.get(1))
382
												((JSONString) jsonArray.get(1))
361
														.stringValue(),
383
														.stringValue(),
362
												((JSONString) jsonArray.get(2))
384
												((JSONString) jsonArray.get(2))
Line 363... Line 385...
363
														.stringValue(),
385
														.stringValue(),
364
												((JSONString) jsonArray.get(3))
386
												((JSONString) jsonArray.get(3))
365
														.stringValue(),
387
														.stringValue(),
366
														locationText,locationValue);
388
														inventoryItem.getLocation(),inventoryItem.getLocation_id(),inventoryItem.getDate(),inventoryItem.getComplementlocation(),inventoryItem.getComment());
367
									}
389
									}
368
								}
390
								}
Line -... Line 391...
-
 
391
		
-
 
392
							});
-
 
393
				}
369
		
394
				// Saisie libre
370
							});
395
				else {
Line 371... Line 396...
371
				}
396
					addElement(inventoryItem.getName(), " ", " ", " ", " ", " ",inventoryItem.getLocation(),inventoryItem.getLocation_id(),inventoryItem.getDate(),inventoryItem.getComplementlocation(),inventoryItem.getComment());
372
				// Saisie libre
397
				}
373
				else {
398
			
Line 392... Line 417...
392
	 *            numero taxonomique
417
	 *            numero taxonomique
393
	 * @param famille :
418
	 * @param famille :
394
	 *            famille
419
	 *            famille
395
	 */
420
	 */
Line 396... Line 421...
396
 
421
 
397
	public void addElement(String nom_sel, String num_nom_sel, String nom_ret,
422
	private void addElement(String nom_sel, String num_nom_sel, String nom_ret,
Line 398... Line 423...
398
			String num_nom_ret, String num_taxon, String famille,final String loc, String id_location) {
423
			String num_nom_ret, String num_taxon, String famille,final String loc, String id_location,String dat, String complementLocation, String comment) {
Line 399... Line 424...
399
 
424
 
400
		// Calcul du nouveau numéro d'ordre
425
		// Calcul du nouveau numéro d'ordre
401
 
426
 
402
		count++;
427
		count++;
403
		HTTPRequest.asyncPost(serviceBaseUrl + "/Inventory/", "identifiant="
428
		HTTPRequest.asyncPost(serviceBaseUrl + "/Inventory/", "identifiant="
-
 
429
				+ user + "&nom_sel=" + nom_sel + "&num_nom_sel=" + num_nom_sel
Line 404... Line 430...
404
				+ user + "&nom_sel=" + nom_sel + "&num_nom_sel=" + num_nom_sel
430
				+ "&nom_ret=" + nom_ret + "&num_nom_ret=" + num_nom_ret
Line 405... Line 431...
405
				+ "&nom_ret=" + nom_ret + "&num_nom_ret=" + num_nom_ret
431
				+ "&num_taxon=" + num_taxon + "&famille=" + famille + "&location=" + loc + "&id_location=" + id_location + "&date_observation=" + dat
406
				+ "&num_taxon=" + num_taxon + "&famille=" + famille + "&location=" + loc + "&id_location=" + id_location,
432
				+ "&station="+ complementLocation + "&commentaire="+ comment,
-
 
433
 
-
 
434
		new ResponseTextHandler() {
-
 
435
 
407
 
436
			public void onCompletion(String str) {
408
		new ResponseTextHandler() {
437
					location=loc;
409
 
438
					if (location.compareTo("")==0) {
410
			public void onCompletion(String str) {
439
						location="000null";
Line 423... Line 452...
423
 
452
 
424
		setStatusDisabled();
453
		setStatusDisabled();
425
		boolean checked = false;
454
		boolean checked = false;
Line -... Line 455...
-
 
455
		Vector parseChecked = new Vector();
426
		Vector parseChecked = new Vector();
456
 
427
 
457
		// TODO : optimiser
-
 
458
		// Lifo ...
428
		// Lifo ...
459
		for (int i = table.getRowCount() - 1; i >= 0; i--) {
429
		for (int i = table.getRowCount() - 1; i >= 0; i--) {
460
			 if (table.getWidget(i, 0)!=null) {
430
			if (((CheckBox) table.getWidget(i, 0)).isChecked()) {
461
				 if (((CheckBox) table.getWidget(i, 0)).isChecked()) {
431
				checked = true;
462
					 checked = true;
432
				// Numero ordre
463
					 // Numero ordre
433
				parseChecked.add(table.getText(i, 7));
464
					 parseChecked.add(table.getText(i, 7));
434
				count--;
465
					 count--;
-
 
466
				 }
435
			}
467
			 }
436
		}
-
 
437
		sizeChecked=parseChecked.size();
468
		}
438
		itemDeleted=0;
469
		StringBuffer ids=new StringBuffer();
-
 
470
		for (Iterator it = parseChecked.iterator(); it.hasNext();) {
-
 
471
			ids.append((String)it.next());
439
		for (Iterator it = parseChecked.iterator(); it.hasNext();) {
472
			if (it.hasNext()) ids.append(",");
440
			itemDeleted++;
473
		}
Line 441... Line 474...
441
			HTTPRequest.asyncPost(serviceBaseUrl + "/Inventory/" + user
474
		HTTPRequest.asyncPost(serviceBaseUrl + "/Inventory/" + user
442
						+ "/" + (String) it.next(), "action=DELETE",
475
						+ "/" + ids.toString(), "action=DELETE",
443
						
-
 
444
						new ResponseTextHandler() {
-
 
445
							public void onCompletion(String str) {
476
						
446
								// Optimisation : on ne lance la suppression qu'a la fin
477
						new ResponseTextHandler() {
447
								    if (itemDeleted==sizeChecked) { 
-
 
448
										updateCount();
478
							public void onCompletion(String str) {
Line 449... Line -...
449
								    }
-
 
450
							}
479
										updateCount();
451
						});
480
							}
452
 
481
						});
453
		}
482
 
Line 461... Line 490...
461
	 * 
490
	 * 
462
	 */
491
	 */
Line 463... Line 492...
463
 
492
 
Line -... Line 493...
-
 
493
	public void selectAll() {
464
	public void selectAll() {
494
 
-
 
495
		// TODO : optimiser ...
465
 
496
		for (int i = table.getRowCount() - 1; i >= 0; i--) {
466
		for (int i = table.getRowCount() - 1; i >= 0; i--) {
497
			 if (table.getWidget(i, 0)!=null)
467
			 ((CheckBox) table.getWidget(i, 0)).setChecked(true); 
498
			 ((CheckBox) table.getWidget(i, 0)).setChecked(true); 
Line 468... Line 499...
468
		}
499
		}
Line -... Line 500...
-
 
500
	}
469
	}
501
 
-
 
502
	public void deselectAll() {
470
 
503
	
471
	public void deselectAll() {
504
		// TODO : optimiser ...
472
	
505
		for (int i = table.getRowCount() - 1; i >= 0; i--) {
Line 483... Line 516...
483
	 */
516
	 */
484
	public void updateCount() {
517
	public void updateCount() {
Line 485... Line 518...
485
		
518
		
Line -... Line 519...
-
 
519
		setStatusDisabled();
-
 
520
		
-
 
521
		String adate="all";
-
 
522
		if (date.compareTo("all")!=0) {
-
 
523
			adate=date.substring(6,10)+"-"+date.substring(3,5)+"-"+date.substring(0,2)+" 00:00:00";
486
		setStatusDisabled();
524
		}
487
 
525
 
Line 488... Line 526...
488
		HTTPRequest.asyncGet(serviceBaseUrl + "/InventoryItemList/" + user + "/" + location,
526
		HTTPRequest.asyncGet(serviceBaseUrl + "/InventoryItemList/" + user + "/" + location + "/" + adate , 
Line 489... Line 527...
489
				new ResponseTextHandler() {
527
				new ResponseTextHandler() {
Line 520... Line 558...
520
 
558
 
Line 521... Line 559...
521
	public void update() {
559
	public void update() {
Line -... Line 560...
-
 
560
 
-
 
561
		setStatusDisabled();
-
 
562
 
-
 
563
		String adate="all";
-
 
564
		if (date.compareTo("all")!=0) {
522
 
565
			adate=date.substring(6,10)+"-"+date.substring(3,5)+"-"+date.substring(0,2)+" 00:00:00";
523
		setStatusDisabled();
566
		}
Line 524... Line 567...
524
 
567
			
Line 525... Line 568...
525
		HTTPRequest.asyncGet(serviceBaseUrl + "/InventoryItemList/" + user + "/" + location +"/"
568
		HTTPRequest.asyncGet(serviceBaseUrl + "/InventoryItemList/" + user + "/" + location +"/" + adate + "/"+
Line 526... Line 569...
526
				+ startIndex + "/" + VISIBLE_TAXON_COUNT,
569
				+ startIndex + "/" + VISIBLE_TAXON_COUNT,
527
 
570
 
528
		new ResponseTextHandler() {
571
		new ResponseTextHandler() {
Line -... Line 572...
-
 
572
 
529
 
573
			public void onCompletion(String str) {
530
			public void onCompletion(String str) {
574
 
531
 
575
				JSONValue jsonValue = JSONParser.parse(str);
532
				JSONValue jsonValue = JSONParser.parse(str);
576
				JSONArray jsonArray;
533
				JSONArray jsonArray;
577
				JSONArray jsonArrayNested;
Line 543... Line 587...
543
								 row = table.insertRow(table.getRowCount());
587
								 row = table.insertRow(table.getRowCount());
544
							}
588
							}
545
							else {
589
							else {
546
								row = i;
590
								row = i;
547
							}
591
							}
-
 
592
 
548
							// Case a cocher
593
							// Case a cocher
549
							table.setWidget(row, 0, new CheckBox());
594
							table.setWidget(row, 0, new CheckBox());
550
							// Nom saisi
595
							// Nom saisi
-
 
596
							
551
							table.setText(row, 1, ((JSONString) jsonArrayNested
597
							table.setText(row, 1, ((JSONString) jsonArrayNested
552
									.get(0)).stringValue());
598
									.get(0)).stringValue());
-
 
599
							
553
							// Nom retenu
600
							// Nom retenu
-
 
601
							String aname=((JSONString) jsonArrayNested .get(2)).stringValue();
-
 
602
							
-
 
603
							if (aname.compareTo("null")==0) {
554
							table.setText(row, 2, ((JSONString) jsonArrayNested
604
								table.setText(row, 2, "");
-
 
605
							}
-
 
606
							else {
555
									.get(2)).stringValue());
607
								table.setText(row, 2, aname);
-
 
608
							}
-
 
609
							
556
							// Num nomenclatural
610
							// Num nomenclatural
-
 
611
							String ann=((JSONString) jsonArrayNested .get(3)).stringValue();
-
 
612
							
-
 
613
							if (ann.compareTo("0")==0) {
557
							table.setText(row, 3, ((JSONString) jsonArrayNested
614
								table.setText(row, 3, "");
-
 
615
							}
-
 
616
							else {
558
									.get(1)).stringValue());
617
								table.setText(row, 3, ann);
-
 
618
							}
-
 
619
 
-
 
620
							
559
							// Num Taxonomique
621
							// Num Taxonomique
-
 
622
							
-
 
623
							String ant=((JSONString) jsonArrayNested .get(4)).stringValue();
-
 
624
							
-
 
625
							if (ant.compareTo("0")==0) {
560
							table.setText(row, 4, ((JSONString) jsonArrayNested
626
								table.setText(row, 4, "");
-
 
627
							}
-
 
628
							else {
561
									.get(4)).stringValue());
629
								table.setText(row, 4, ann);
-
 
630
							}
-
 
631
 
562
							// Famille
632
							// Famille
-
 
633
							String afamily=((JSONString) jsonArrayNested .get(5)).stringValue();
-
 
634
							
-
 
635
							if (afamily.compareTo("null")==0) {
563
							table.setText(row, 5, ((JSONString) jsonArrayNested
636
								table.setText(row, 5, "");
-
 
637
							}
-
 
638
							else {
564
									.get(5)).stringValue());
639
								table.setText(row, 5, afamily);
-
 
640
							}
Line 565... Line 641...
565
 
641
 
566
							
642
							
567
							table.getFlexCellFormatter().setWidth(row, 0, "2%");
643
							table.getFlexCellFormatter().setWidth(row, 0, "2%");
568
							table.getFlexCellFormatter()
644
							table.getFlexCellFormatter()
569
									.setWidth(row, 1, "31%");
645
									.setWidth(row, 1, "31%");
570
							table.getFlexCellFormatter()
-
 
571
									.setWidth(row, 2, "31%");
-
 
572
							table.getFlexCellFormatter().setWidth(row, 3, "9%");
-
 
Line 573... Line 646...
573
							table.getFlexCellFormatter().setWidth(row, 4, "9%");
646
							table.getFlexCellFormatter()
-
 
647
									.setWidth(row, 2, "31%");
-
 
648
							
-
 
649
						// TODO : Bool ici non ?	
-
 
650
							
-
 
651
							// Affichage contenu commune si tout demandé.
574
							table.getFlexCellFormatter().setWidth(row, 5, "9%");
652
							
Line 575... Line 653...
575
 
653
							String aloc=((JSONString) jsonArrayNested .get(6)).stringValue();
576
						// TODO : Bool ici non ?	
-
 
Line 577... Line 654...
577
							if (location.compareTo("all")==0) {
654
							
578
								
655
							if (location.compareTo("all")==0) {
579
//								Localisation - Lieu
656
								
580
								String aloc=((JSONString) jsonArrayNested .get(6)).stringValue();
657
//								Localisation - Lieu
581
								
658
								
582
								if (aloc.compareTo("000null")==00) {
659
								if (aloc.compareTo("000null")==0) {
Line -... Line 660...
-
 
660
									table.setText(row, 6, "Inconnu");
583
									table.setText(row, 6, "Inconnu");
661
								}
Line -... Line 662...
-
 
662
								else {
-
 
663
									table.setText(row, 6, aloc );
-
 
664
								}
-
 
665
								
-
 
666
 
-
 
667
								header.getCellFormatter().setVisible(0, 6,true);
-
 
668
							
-
 
669
								table.getFlexCellFormatter().setWidth(row, 1, "31%");
584
								}
670
								table.getFlexCellFormatter().setWidth(row, 2, "31%");
585
								else {
671
 
586
									table.setText(row, 6, ((JSONString) jsonArrayNested .get(6)).stringValue());
672
								table.getFlexCellFormatter().setWidth(row, 3, "9%");
587
								}
673
								table.getFlexCellFormatter().setWidth(row, 4, "9%");
-
 
674
								table.getFlexCellFormatter().setWidth(row, 5, "9%");
-
 
675
								table.getFlexCellFormatter().setWidth(row, 6, "9%");
-
 
676
 
-
 
677
							}
-
 
678
							else {
-
 
679
								header.getCellFormatter().setVisible(0, 6,false);
-
 
680
								table.getCellFormatter().setVisible(row, 6,false);
-
 
681
							
588
								
682
								table.getFlexCellFormatter().setWidth(row, 1, "36%");
589
								header.getCellFormatter().setVisible(0, 6,true);
-
 
Line 590... Line 683...
590
 
683
								table.getFlexCellFormatter().setWidth(row, 2, "36%");
591
							}
684
 
592
							else {
685
								table.getFlexCellFormatter().setWidth(row, 3, "9%");
Line 604... Line 697...
604
							
697
							
Line 605... Line 698...
605
						}
698
						}
606
 
699
 
-
 
700
					}
-
 
701
				}
607
					}
702
 
608
				}
703
				
609
				// Suppression fin ancien affichage
704
				// Suppression fin ancien affichage
610
				if (i<table.getRowCount()-1) {
705
				if (i<table.getRowCount()-1) {
611
					 for (int j = table.getRowCount() - 1; j > i-1; j--) {
706
					 for (int j = table.getRowCount() - 1; j > i-1; j--) {
Line 707... Line 802...
707
		this.location = location;
802
		this.location = location;
708
	}
803
	}
Line -... Line 804...
-
 
804
 
-
 
805
 
-
 
806
 
-
 
807
	public void setDate(String date) {
-
 
808
		this.date = date;
-
 
809
	}
Line 709... Line 810...
709
	
810