From 1c4a1562ce486288137d9cf305dd0d40550fc3d6 Mon Sep 17 00:00:00 2001 From: piquerez <corentin.piquerez1@etu.univ-lorraine.fr> Date: Wed, 31 May 2023 17:14:29 +0200 Subject: [PATCH] =?UTF-8?q?d=C3=A9but=20suppression=20cours?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../data/2223_S2/version.txt | 4 +- "r\303\251partition des taches.docx" | Bin 0 -> 16384 bytes shukan/ShukanController.java | 6 +- shukan/ShukanData.java | 8 +++ shukan/ShukanModule.java | 37 +++++++++++ shukan/ShukanParameters.java | 2 +- shukan/ShukanQueue.java | 28 ++++++++ shukan/ShukanSchedule.java | 9 +++ shukan/ShukanView.java | 62 ++++++++++++++++-- 9 files changed, 146 insertions(+), 10 deletions(-) create mode 100644 "r\303\251partition des taches.docx" diff --git a/out/production/sae2.01-developpement-application/data/2223_S2/version.txt b/out/production/sae2.01-developpement-application/data/2223_S2/version.txt index d451762..d82a4c1 100644 --- a/out/production/sae2.01-developpement-application/data/2223_S2/version.txt +++ b/out/production/sae2.01-developpement-application/data/2223_S2/version.txt @@ -1,2 +1,2 @@ -24 -230530 +26 +230531 diff --git "a/r\303\251partition des taches.docx" "b/r\303\251partition des taches.docx" new file mode 100644 index 0000000000000000000000000000000000000000..cb559a7f0caaf371ed7119878be67974b7621d1a GIT binary patch literal 16384 zcmeHugL`Dl_I8I8+qNdQGqG)(6WdNEwlT47+qRR5GchODmvb%-?tQ+0;CFXFy`HYF zdROh<y;jv*Rcpyff`Fm`zyS~d0Dus{7;B?y0t5gQfB^u=00>}BK^tpFV{1oUB{y4R z2W?tcD@%f0P+*E|0Psiq|6TuwpFn-Wm_;8wg7AINTfj`?vP3IILH|f@v@y2X6Hpkl zjL@w>Ui(|;E;~a32?O)UAi>nS#}ouZz|3lzB_v{l3+V|uPm*7}jyc=sm8CrzA0te% z?F9NC{3EQsmdx!Pm{P1j^u!H)aTAJAvKe_90jO#ZfGDcOXcZ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j4A>fYBD;JvfV1?i=7FL!%167lXwU!}gLpX1 zP*D&%rhU)NZ|Z5RaXqC$7YC^606RwVjH*`cq{{m36MCuy<0wJvfe_i~;I!Kgb=$=E zF!*<%U^UGH{eZ$nShfMilgmFk50n6xweu3dtf2FM;=jpE9AHDFzqL~Q9;n*eZ%={k zkM|Wl_h&=c_xhpcZ*J;Q3p7<vz`#pEUeg`~o@Y@q(-?S~t(q_2R;bw4JTS^lob64M zncn0!Rwp3^VNHm0!F}LmD;w|4xx8;L)5Z_pa(C=50;R$k->b*j2qb&Ht67@m@5+e) z;~hfj6oDM-I&>c>+_(^(&EH(=nPZYEK0T4P+SWtvO78Ien~?wk(|oYI|DNjn4=eaX z{+GmOImy2&_-iueA5Z`w>%-apl$!Z>;NP><{(yFU1S|eW&f4GMe+`cP1N?EY`oXRK zf1$E}*Yx-J$Uk&Vez4&G8ZG&E6@QN@`9sA9_CHnpIl|=c@V_4k{{hz~_$T}?2gHBJ z|NRu=4?Gpwzq<eTnZ)10e`o!FfbSXq3I5v};O`p#&TIeBpvwGD4S!*|f5-ooHT;1F u065qHfdAkSe~15daQ`!WhT~80e-8C>l3*X^1pvT&ynsF|^oaYn(*FZRoaci8 literal 0 HcmV?d00001 diff --git a/shukan/ShukanController.java b/shukan/ShukanController.java index e8bf221..206ad70 100644 --- a/shukan/ShukanController.java +++ b/shukan/ShukanController.java @@ -205,11 +205,11 @@ public class ShukanController System.out.println("back"); else if (e.getSource()==bar.buttons[2]) { - canvas.getNewActivity(); + canvas.newActivity(); canvas.repaint(); } - else if (e.getSource()==bar.buttons[3]) - System.out.println("delete"); + else if (e.getSource()==bar.buttons[3]) canvas.deleteActivity(); + else if (e.getSource()==bar.buttons[4]) {if (data.followLeft ()) canvas.repaint ();} else if (e.getSource()==bar.buttons[5]) {if (data.followRight ()) canvas.repaint ();} diff --git a/shukan/ShukanData.java b/shukan/ShukanData.java index 5f7fef5..f67b27b 100644 --- a/shukan/ShukanData.java +++ b/shukan/ShukanData.java @@ -113,6 +113,9 @@ public class ShukanData mod[cursNum][modNum].closeActivities (size); } + /** Delete the activity of a module */ + public void deleteActivity (int cursNum, int modNum, int index) {mod[cursNum][modNum].deleteActivity (index);}; + /** Automatically plans a free module */ public void autoPlan (int cursNum, int modNum) { @@ -131,6 +134,11 @@ public class ShukanData { mod[cursNum][modNum].unschedule (); } + /** Unschedules an activity of a module */ + public void unscheduleActivity (int cursNum, int modNum, int index, int week, int nb_week) + { + mod[cursNum][modNum].unschedule (index, week, nb_week); + } /** Schedules an activity of a module */ public void scheduleActivity (int cursNum, int modNum, int activity, int week) diff --git a/shukan/ShukanModule.java b/shukan/ShukanModule.java index 34f0343..973c98c 100644 --- a/shukan/ShukanModule.java +++ b/shukan/ShukanModule.java @@ -161,6 +161,37 @@ public class ShukanModule } } + /** deletes an activity */ + public void deleteActivity (int index) + { + + int size = activ.length-1; + int[] tmp = new int[size]; + int[][] tmpaff = new int[size][]; + boolean[] tmponLeft = new boolean[activ.length-1]; + boolean[] tmponRight = new boolean[activ.length-1]; + for (int i = 0; i < index; i++) + { + tmp[i] = activ[i]; + tmpaff[i] = affect[i]; + tmponLeft[i] = onLeft[i]; + tmponRight[i] = onRight[i]; + } + for (int i = index+1; i < size; i++) + { + tmp[i-1] = activ[i]; + tmpaff[i-1] = affect[i]; + tmponLeft[i-1] = onLeft[i]; + tmponRight[i-1] = onRight[i]; + } + + activ = tmp; + affect = tmpaff; + onLeft = tmponLeft; + onRight = tmponRight; + + + } /** Automatically plans a free module */ public void autoPlan () @@ -211,6 +242,12 @@ public class ShukanModule scheduled = false; } + /** Unschedules an activity of the module */ + public void unschedule (int index, int week, int nb_week) + { + sched.delete(index, week, nb_week); + } + /** Schedules an activity */ public void schedule (int num, int week) { diff --git a/shukan/ShukanParameters.java b/shukan/ShukanParameters.java index ea3f223..c897749 100644 --- a/shukan/ShukanParameters.java +++ b/shukan/ShukanParameters.java @@ -171,7 +171,7 @@ class ShukanParameters extends JFrame { Lableft = new JLabel("← : Professeur précédent"); Labright = new JLabel("→ : Professeur suivant"); LabE = new JLabel("E : Exporter en format .tex"); - LabX = new JLabel("CTRL + X : Echanger les extrémités"); + LabX = new JLabel("CTRL + X : Echanger les extrémités d'une séléction"); retour = new JButton("Retour"); diff --git a/shukan/ShukanQueue.java b/shukan/ShukanQueue.java index 7fb44d5..febdf3f 100644 --- a/shukan/ShukanQueue.java +++ b/shukan/ShukanQueue.java @@ -26,6 +26,34 @@ public class ShukanQueue length = 0; } + /** delete the nth element in the queue */ + public void delete (int index){ + if (index<=queue.length){ + int tmp[] = new int[queue.length-1]; + for (int i =0; i<index; i++){ + tmp[i] = queue[i]; + } + for (int i =index+1; i<queue.length; i++){ + tmp[i-1] = queue[i]; + } + queue = tmp; + length--; + } + else System.out.println("index trop grand"); + } + + /** remove 1 from an element of the queue */ + public void removeOne(int index){ + queue[index]--; + } + + /** remove 1 from an element of the queue */ + public void removeAllOne(){ + if (queue != null){ + for (int i =0; i<queue.length; i++)queue[i]--; + } + + } /** Pushes a token at the right of the queue */ public void pushRight (int token) { diff --git a/shukan/ShukanSchedule.java b/shukan/ShukanSchedule.java index 6c94de6..1d858b0 100644 --- a/shukan/ShukanSchedule.java +++ b/shukan/ShukanSchedule.java @@ -61,6 +61,15 @@ public class ShukanSchedule for (int i = 0; i < binSet.length; i++) binSet[i].clear (); } + /** delete one element of one queue and update all the queues */ + public void delete(int index, int week, int nb_week){ + binSet[week].delete(index); + for (int i =index; i<binSet[week].length(); i++){ + binSet[week].removeOne(i); + } + for(int i =week+1; i<nb_week; i++) binSet[i].removeAllOne(); + } + /** Add a token to the nth queue */ public void add (int n, int token) { diff --git a/shukan/ShukanView.java b/shukan/ShukanView.java index 9dc7f50..858bb23 100644 --- a/shukan/ShukanView.java +++ b/shukan/ShukanView.java @@ -478,11 +478,11 @@ public class ShukanView extends JPanel /** Creates a new activity with window */ - public void getNewActivity(){ + public void newActivity(){ JFrame f = new JFrame("Informations concernant le nouveau cours"); JPanel global_mod = new JPanel(); JPanel global_act = new JPanel(); - JLabel mod = new JLabel("A quel matiere voulez vous rajouter un cours ?"); + JLabel mod = new JLabel("A quelle matiere voulez vous rajouter un cours ?"); JLabel act = new JLabel("Quel cours voulez vous ajouter? "); JComboBox mod_info = new JComboBox(data.moduleNames(data.cursusNumber())); JComboBox act_info = new JComboBox(ShukanModule.TYPES); @@ -498,7 +498,6 @@ public class ShukanView extends JPanel if (mod_start!=0) mod_start-=data.startWeekNumber(); int nb_act = data.scheduleInWeek(num_mod, mod_start).length; - data.addNewActivity(cursus, num_mod, nb_act, ShukanModule.TYPES[num_act]); data.scheduleActivity(cursus, num_mod, nb_act, mod_start); data.setOnMiddle(cursus, num_mod, nb_act, true); @@ -506,7 +505,6 @@ public class ShukanView extends JPanel data.unscheduleActivities(cursus, num_mod); data.setSchedule(cursus, num_mod, weeks); - repaint(); f.dispose(); } @@ -522,4 +520,60 @@ public class ShukanView extends JPanel f.setVisible(true); f.setSize(new Dimension(400, 150)); } + + /** Creates a new activity with window */ + public void deleteActivity(){ + JFrame f = new JFrame("Informations concernant le cours à supprimer"); + String[] s = new String[data.semesterSize()]; + for (int i =0; i<data.semesterSize(); i++) + s[i] = (data.startWeekNumber()+i)+""; + JPanel global_mod = new JPanel(); + JPanel global_act = new JPanel(); + JPanel global_sem = new JPanel(); + JPanel global = new JPanel(new GridLayout(3,0)); + JLabel mod = new JLabel("A quelle matiere voulez vous supprimer un cours ?"); + JLabel act = new JLabel("Quel cours voulez vous supprimer ? "); + JLabel sem = new JLabel("Pendant quelle semaine le cours se déroule t-il ?"); + JComboBox mod_info = new JComboBox(data.moduleNames(data.cursusNumber())); + JComboBox act_info = new JComboBox(ShukanModule.TYPES); + JComboBox sem_info = new JComboBox(s); + JButton valider = new JButton("Valider"); + + valider.addActionListener(new ActionListener() { + @Override + public void actionPerformed(ActionEvent e) { + int num_mod = mod_info.getSelectedIndex(); + int num_act = act_info.getSelectedIndex(); + int num_sem = sem_info.getSelectedIndex()+data.startWeekNumber(); + int cursus = data.cursusNumber(); + int mod_start = data.moduleStart(cursus, num_mod); + if (mod_start!=0) mod_start-=data.startWeekNumber(); + int nb_act = data.scheduleInWeek(num_mod, mod_start).length; + + data.unscheduleActivity(cursus, num_mod, nb_act, num_sem, data.semesterSize()); + data.deleteActivity(cursus, num_mod, nb_act); + + int[] weeks = data.schedule(num_mod); + data.unscheduleActivities(cursus, num_mod); + data.setSchedule(cursus, num_mod, weeks); + + repaint(); + f.dispose(); + } + }); + + global_mod.add(mod); + global_mod.add(mod_info); + global_act.add(act); + global_act.add(act_info); + global_sem.add(sem); + global_sem.add(sem_info); + global.add(global_mod); + global.add(global_act); + global.add(global_sem); + f.add(global, BorderLayout.NORTH); + f.add(valider, BorderLayout.SOUTH); + f.setVisible(true); + f.setSize(new Dimension(400, 200)); + } } -- GitLab