$
This commit is contained in:
@@ -172,8 +172,40 @@ public class Controller implements ActionListener {
|
||||
}
|
||||
}
|
||||
|
||||
else if(Objects.equals(command, "av::MoveStudent")) {
|
||||
else if(Objects.equals(command, "av::MoveStudGrup")) {
|
||||
BFrame frame = new BFrame(
|
||||
"Deplacer un etudiant",
|
||||
1,
|
||||
1,
|
||||
500,
|
||||
500,
|
||||
"GridLayout",
|
||||
1,
|
||||
1,
|
||||
2
|
||||
);
|
||||
|
||||
String[][] data = new String[this.e.size()][3];
|
||||
|
||||
Object[] titre = {
|
||||
(String) "Nom",
|
||||
(String) "Prenom",
|
||||
(String) "Groupe",
|
||||
(String) "Action"
|
||||
};
|
||||
|
||||
for(int i = 0; i <= this.e.size()-1; i++) {
|
||||
Object[] info = {
|
||||
(String) this.e.get(i).getNom(),
|
||||
(String) this.e.get(i).getPrenom(),
|
||||
(String) String.valueOf(this.e.get(i).getGroupe()),
|
||||
(String) "Deplacer"
|
||||
};
|
||||
|
||||
data[i] = info;
|
||||
}
|
||||
|
||||
Display(frame, data, titre);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -183,7 +215,7 @@ public class Controller implements ActionListener {
|
||||
* @param data Les donnees des colonnes du tableau
|
||||
* @param titre Les titres des colonnes
|
||||
* */
|
||||
private void Display(BFrame frame, String[][] data, String[] titre) {
|
||||
private void Display(BFrame frame, Object[][] data, Object[] titre) {
|
||||
JTable liste = new JTable(data, titre) {
|
||||
public boolean editCellAt(int row, int column, java.util.EventObject e) {
|
||||
return false;
|
||||
|
Reference in New Issue
Block a user