Subversion Repositories eFlore/Applications.coel

Rev

Rev 952 | Rev 1122 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 952 Rev 1041
Line 12... Line 12...
12
import org.tela_botanica.client.modeles.Information;
12
import org.tela_botanica.client.modeles.Information;
13
import org.tela_botanica.client.modeles.Utilisateur;
13
import org.tela_botanica.client.modeles.Utilisateur;
14
import org.tela_botanica.client.modeles.collection.Collection;
14
import org.tela_botanica.client.modeles.collection.Collection;
15
import org.tela_botanica.client.modeles.collection.CollectionListe;
15
import org.tela_botanica.client.modeles.collection.CollectionListe;
16
import org.tela_botanica.client.modeles.publication.Publication;
16
import org.tela_botanica.client.modeles.publication.Publication;
-
 
17
import org.tela_botanica.client.modeles.structure.StructureListe;
17
import org.tela_botanica.client.util.Debug;
18
import org.tela_botanica.client.util.Debug;
-
 
19
import org.tela_botanica.client.vues.BarrePaginationVue;
Line 18... Line 20...
18
 
20
 
19
import com.extjs.gxt.ui.client.Registry;
21
import com.extjs.gxt.ui.client.Registry;
20
import com.extjs.gxt.ui.client.Style.SortDir;
22
import com.extjs.gxt.ui.client.Style.SortDir;
21
import com.extjs.gxt.ui.client.event.BaseEvent;
23
import com.extjs.gxt.ui.client.event.BaseEvent;
Line 46... Line 48...
46
	private ListStore<Collection> store = null;
48
	private ListStore<Collection> store = null;
Line 47... Line 49...
47
 
49
 
48
	private Button modifier;
50
	private Button modifier;
49
	private Button supprimer;
51
	private Button supprimer;
-
 
52
	private Button ajouter;
50
	private Button ajouter;
53
	private BarrePaginationVue pagination = null;
51
 
54
	
52
	public CollectionListeVue(Mediateur mediateurCourant) {
55
	public CollectionListeVue(Mediateur mediateurCourant) {
53
		mediateur = mediateurCourant;
56
		mediateur = mediateurCourant;
Line 54... Line 57...
54
		i18nC = Mediateur.i18nC;
57
		i18nC = Mediateur.i18nC;
Line 121... Line 124...
121
			public void handleEvent(BaseEvent be) {
124
			public void handleEvent(BaseEvent be) {
122
				modifier.fireEvent(Events.Select);
125
				modifier.fireEvent(Events.Select);
123
			}
126
			}
124
		});
127
		});
125
		add(grille);
128
		add(grille);
-
 
129
		
-
 
130
		// Définition de la barre de pagination
-
 
131
		pagination = new BarrePaginationVue(new CollectionListe(), mediateur);
-
 
132
		setBottomComponent(pagination);
126
	}
133
	}
Line 127... Line 134...
127
 
134
 
128
	private void clicListe(Collection collection) {
135
	private void clicListe(Collection collection) {
129
		if (collection != null && store.getCount() > 0) {
136
		if (collection != null && store.getCount() > 0) {
Line 153... Line 160...
153
 
160
 
154
	public void rafraichir(Object nouvellesDonnees) {
161
	public void rafraichir(Object nouvellesDonnees) {
155
		if (nouvellesDonnees instanceof CollectionListe) {
162
		if (nouvellesDonnees instanceof CollectionListe) {
Line -... Line 163...
-
 
163
			CollectionListe collections = (CollectionListe) nouvellesDonnees;
-
 
164
 
-
 
165
			pagination.setlistePaginable(collections);
-
 
166
			int[] pt = collections.getPageTable();
156
			CollectionListe collections = (CollectionListe) nouvellesDonnees;
167
			pagination.rafraichir(collections.getPageTable());
157
 
168
			
158
			if (collections != null) {			
169
			if (collections != null) {			
159
				List<Collection> liste = collections.toList();
170
				List<Collection> liste = collections.toList();