Je sais pas quoi mettre, j'ai juste avancé 🎉
continuous-integration/drone/push Build is passing Details

Collection
Nicolas BLONDEAU 2 years ago
parent 94e2b4d8d5
commit 06c57cc9cb

@ -42,7 +42,7 @@ namespace Persistance
where m.Name.Contains(texte, System.StringComparison.CurrentCultureIgnoreCase)
select m).ToList(); // LINQ
return new ObservableCollection<Monstre>(listMonstre);
}
} //BINDER DIRECTEMENT ICI
public MonsterManager(IMonsterDataManager dataMngr)
{

@ -1,5 +1,7 @@
using Model;
using Persistance;
using static System.Runtime.InteropServices.JavaScript.JSType;
namespace Vues;
public partial class Inscription : ContentPage
@ -20,30 +22,34 @@ public partial class Inscription : ContentPage
mdp = Mdp.Text;
nom = Nom.Text;
prenom = Prenom.Text;
User newUser = new User { };
if ((Application.Current as App).userManager.checkIfPseudoExists(id))
{
resultLabel.Text = "Error, this username is already taken!";
resultLabel.IsVisible = true;
return;
//await Navigation.PushAsync(new SearchMob());
}
try
{
User newUser = new User(id, nom, prenom, mdp);
newUser = new User(id, nom, prenom, mdp);
(Application.Current as App).userManager.ListUsers.Add(newUser);
(Application.Current as App).User = newUser;
await Navigation.PopAsync();
}
catch (FormatException)
catch (ArgumentException)
{
resultLabel.IsVisible = true;
resultLabel.Text = "You must complete all entries!";
resultLabel.Text = "Vous devez compléter tous les champs.";
}
catch (ArgumentException)
catch (FormatException)
{
resultLabel.IsVisible = true;
resultLabel.Text = "You ";
resultLabel.Text = "Votre identifiant / mot de passe ne peut contenir seulement des nombres !";
}
(Application.Current as App).userManager.ListUsers.Add(newUser);
(Application.Current as App).User = newUser;
await Navigation.PopAsync();
//resultLabel.IsVisible = true;
//resultLabel.Text = "You must complete all entries!";
//resultLabel.IsVisible = true;
return;
}

@ -21,11 +21,11 @@ public partial class SearchMob : ContentPage, INotifyPropertyChanged
set
{
searchText = value;
MnstrTemp = (Application.Current as App).monsterManager.search(searchText);
if (searchText == "")
{
MnstrTemp = (Application.Current as App).monsterManager.ListMonsters;
}
else MnstrTemp = (Application.Current as App).monsterManager.search(searchText);
UpdateAffichMobs();
OnPropertyChanged(nameof(MnstrTemp));
}
@ -39,6 +39,10 @@ public partial class SearchMob : ContentPage, INotifyPropertyChanged
ListViewMonsters.BindingContext = this;
searchBar.BindingContext = this;
imageCollection.BindingContext = this;
if ((Application.Current as App).User != null)
{
}
}
public void OnClick(object sender, ItemTappedEventArgs e)
@ -51,6 +55,7 @@ public partial class SearchMob : ContentPage, INotifyPropertyChanged
var button = sender as Button;
// Afficher les champs à remplir pour ajouter un conseil
//FAIRE UN FUCKING X:NAME :>
var addConseilLayout = button?.Parent?.FindByName<StackLayout>("AddConseilLayout");
if (addConseilLayout != null)
{
@ -63,6 +68,7 @@ public partial class SearchMob : ContentPage, INotifyPropertyChanged
private void OnValiderConseilClicked(object sender, EventArgs e)
{
var button = sender as Button;
//FAIRE UN FUCKING ICI AUSSI X:NAME :>
var addConseilLayout = button?.Parent?.FindByName<StackLayout>("AddConseilLayout");
if (addConseilLayout != null)

Loading…
Cancel
Save