Subversion Repositories eFlore/Applications.coel

Rev

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

Rev 935 Rev 992
Line 12... Line 12...
12
 
12
 
Line 13... Line 13...
13
	private static final long serialVersionUID = 7769105365939978129L;
13
	private static final long serialVersionUID = 7769105365939978129L;
14
	
14
	
-
 
15
	public static final String PREFIXE = "cpuap";
-
 
16
	public static final String ROLE_AUTEUR = "2360";
-
 
17
	//FIXME: insérer en base de données une valeur cohérente pour l'identifiant ci-dessous
15
	public static final String PREFIXE = "cpuap";
18
	public static final String ROLE_SUJET = "30762";
-
 
19
	
Line 16... Line 20...
16
	public static final String ROLE_AUTEUR = "2360";
20
	private Personne personneLiee = null;
-
 
21
	private Publication publicationLiee = null;
-
 
22
	
Line 17... Line 23...
17
	private Personne personneLiee = null;
23
	public PublicationAPersonne() {
18
	
24
		new PublicationAPersonne(new JSONObject());
-
 
25
	}
Line -... Line 26...
-
 
26
	
19
	public PublicationAPersonne() {}
27
	public PublicationAPersonne(JSONObject pubAPersListe) {
20
	
28
		personneLiee = new Personne(pubAPersListe);
Line 21... Line 29...
21
	public PublicationAPersonne(JSONObject pubAPersListe) {
29
		publicationLiee = new Publication(pubAPersListe);
22
		personneLiee = new Personne(pubAPersListe);
30
		
Line 37... Line 45...
37
				this.set(cleObjet, valeur);
45
				this.set(cleObjet, valeur);
38
			} else {
46
			} else {
39
				this.set(cleObjet, valeur);
47
				this.set(cleObjet, valeur);
40
			}
48
			}
41
		}
49
		}
-
 
50
		
-
 
51
		initialiserChampsPourGrille();
-
 
52
	}
-
 
53
	
-
 
54
	
-
 
55
	private void initialiserChampsPourGrille() {
-
 
56
		set("fmt_auteur", publicationLiee.getAuteur());
-
 
57
		set("titre", publicationLiee.getTitre());
-
 
58
		set("collection", publicationLiee.getCollection());
-
 
59
		set("_editeur_", "");
-
 
60
		set("_annee_", "");
-
 
61
		set("indication_nvt", publicationLiee.getIndicationNvt());
-
 
62
		set("fascicule", publicationLiee.getFascicule());
-
 
63
		set("truk_pages", publicationLiee.getPages());
-
 
64
		set("_etat_", "");
42
	}
65
	}
Line -... Line 66...
-
 
66
	
43
	
67
	
44
	@Override
68
	@Override
45
	protected String getPrefixe() {
69
	protected String getPrefixe() {
46
		return PREFIXE;
70
		return PREFIXE;
Line 74... Line 98...
74
	}
98
	}
75
	public void setIdPublication(String id) {
99
	public void setIdPublication(String id) {
76
		set("id_publication", id);
100
		set("id_publication", id);
77
	}
101
	}
Line -... Line 102...
-
 
102
	
-
 
103
	// PUBLICATION LIEE
-
 
104
	public Publication getPublicationLiee()	{
-
 
105
		return this.publicationLiee;
-
 
106
	}
-
 
107
	
-
 
108
	// LIER PUBLICATION
-
 
109
	public void setPublicationLiee(Publication publication)	{
-
 
110
		this.publicationLiee = publication;
-
 
111
		initialiserChampsPourGrille();
-
 
112
	}
78
	
113
	
79
	// ID PERSONNE
114
	// ID PERSONNE
80
	public String getIdPersonne() {
115
	public String getIdPersonne() {
81
		return renvoyerValeurCorrecte("id_personne");
116
		return renvoyerValeurCorrecte("id_personne");
82
	}
117
	}