Esempio n. 1
0
        public NewPickupItemPage()
        {
            InitializeComponent();

            Item = new PickupItem
            {
                Title = "Item name"
            };

            BindingContext = this;
        }
        // Note - The Xamarin.Forms Previewer requires a default, parameterless constructor to render a page.
        public PickupItemDetailPage()
        {
            InitializeComponent();

            var item = new PickupItem
            {
                Title = "New Item posted"
            };

            viewModel      = new PickupItemDetailViewModel(item);
            BindingContext = viewModel;
        }
Esempio n. 3
0
 public PickupItemDetailViewModel(PickupItem item = null)
 {
     Title = item?.Title;
     Item  = item;
 }