Пример #1
0
        public static async void CreateInspectionButtonClicked(object sender, EventArgs e)
        {
            CreateInspectionButton button    = (CreateInspectionButton)sender;
            ChecklistModel         checklist = button.checklist;
            EditInspectionPage     page      = new EditInspectionPage(null, checklist);

            page.CallingPage = (ChecklistPage)button.ParentView.ParentView;
            await App.Navigation.PushAsync(page);
        }
Пример #2
0
        public static async void CreateInspectionButtonClicked(object sender, EventArgs e)
        {
            CreateInspectionButton button    = (CreateInspectionButton)sender;
            ChecklistModel         checklist = button.checklist;
            EditInspectionPage     page      = new EditInspectionPage(null, checklist);
            VisualElement          Parent    = button.ParentView.ParentView;

            if (Parent.GetType() == typeof(InspectionListPage))
            {
                page.CallingPage = (InspectionListPage)button.ParentView.ParentView;
            }
            else
            {
                InspectionListPage ListPage = new InspectionListPage(checklist);
                page.CallingPage = ListPage;
            }
            await App.Navigation.PushAsync(page);
        }