Esempio n. 1
0
 private async void GroupsList_OnItemSelected(object sender, SelectedItemChangedEventArgs e)
 {
     MerchGroup selectedGroup = (MerchGroup)e.SelectedItem;
     GroupPage  groupPage     = new GroupPage()
     {
         BindingContext = selectedGroup
     };
     await Navigation.PushAsync(groupPage);
 }
Esempio n. 2
0
        private async void AddGroup(object sender, EventArgs e)
        {
            var profile = (Profile)BindingContext;

            if (!String.IsNullOrEmpty(profile.Name))
            {
                App.Repository.SaveProfile(profile);
            }
            MerchGroup group = new MerchGroup()
            {
                Profile_Id = profile.Id
            };
            GroupPage groupPage = new GroupPage()
            {
                BindingContext = group
            };
            await Navigation.PushAsync(groupPage);
        }
Esempio n. 3
0
 public int DeleteGroup(MerchGroup item)
 {
     return(database.Delete(item));
 }
Esempio n. 4
0
 public int SaveGroup(MerchGroup item)
 {
     return(item.Id != 0 ? database.Update(item) : database.Insert(item));
 }