Esempio n. 1
0
        public add_act(activ_class con, activ page, int pos)
        {
            this.page   = page;
            this.pos    = pos;
            this.id_act = con.get_id();
            InitializeComponent();
            taches = new List <tache>();
            Designation_activité.Text = con.get_designation();
            titre.Text = "Modifier l'activité";
            bool itemExists = false;

            foreach (ComboBoxItem cbi in comboBox_type.Items)
            {
                itemExists = cbi.Content.Equals(con.get_type());
                if (itemExists)
                {
                    break;
                }
            }
            if (itemExists)
            {
                comboBox_type.Text = con.get_type();
            }
            else
            {
                comboBox_type.SelectedIndex = 2;
                autre_type.Visibility       = System.Windows.Visibility.Visible;
                autre_type.Text             = con.get_type();
            }
            textBlock1_Copy1.Visibility = Visibility.Collapsed;
            ajouter_tache.Visibility    = Visibility.Collapsed;
        }
Esempio n. 2
0
        public list_taches(activ_class a, utilisateur user, activ act_page, acceuil ac_page)
        {
            this.activité = a;
            this.user     = user;
            this.act_page = act_page;
            this.ac_page  = ac_page;
            InitializeComponent();
            nom_activité.Text = activité.get_designation();
            methodes     t     = new methodes();
            List <tache> tache = t.Afficher_Tache(activité.get_id(), activité.get_id_user());

            this.list = tache;
            this.afficher(list);
        }