|
|
|
@ -20,7 +20,42 @@ public partial class Inviter : ContentView
|
|
|
|
|
string nom = nomEditor.Text;
|
|
|
|
|
string prenom = prenomEditor.Text;
|
|
|
|
|
Modeles.Inviter invite1 = new Modeles.Inviter(nom, prenom);
|
|
|
|
|
BindingContext = invite1;
|
|
|
|
|
m.AddInvite(invite1);
|
|
|
|
|
List<Modeles.Inviter> invites = m.AddInvite(invite1);
|
|
|
|
|
int len = 1;
|
|
|
|
|
foreach (Modeles.Inviter inviter in invites)
|
|
|
|
|
{
|
|
|
|
|
RowDefinition row = new RowDefinition();
|
|
|
|
|
row.Height = new GridLength(45);
|
|
|
|
|
GrilleInvite.RowDefinitions.Add(row);
|
|
|
|
|
|
|
|
|
|
// AJout Prenom
|
|
|
|
|
Label prenomLabel = new Label();
|
|
|
|
|
prenomLabel.Text = inviter.Prenom;
|
|
|
|
|
Grid.SetRow(prenomLabel, len);
|
|
|
|
|
Grid.SetColumn(prenomLabel, 0);
|
|
|
|
|
GrilleInvite.Children.Add(prenomLabel);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Ajout Nom
|
|
|
|
|
Label nomLabel = new Label();
|
|
|
|
|
nomLabel.Text = inviter.Nom;
|
|
|
|
|
Grid.SetRow(nomLabel, len);
|
|
|
|
|
Grid.SetColumn(nomLabel, 1);
|
|
|
|
|
GrilleInvite.Children.Add(nomLabel);
|
|
|
|
|
|
|
|
|
|
// Ajout Bouton
|
|
|
|
|
|
|
|
|
|
Button buttonMoins = new Button();
|
|
|
|
|
buttonMoins.Text = "-";
|
|
|
|
|
Grid.SetRow(buttonMoins, len);
|
|
|
|
|
Grid.SetColumn(buttonMoins , 2);
|
|
|
|
|
GrilleInvite.Children.Add(buttonMoins );
|
|
|
|
|
//GrilleInvite.HeightRequest = Height + 2;
|
|
|
|
|
|
|
|
|
|
len++;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|