public MainPage() { this.InitializeComponent(); AutoGenerateFormService.ForEntity <Student>().Property(s => s.FirstName).DisplayAs("Primer Nombre").WithOrder(1).VisibleWhen(s => s.FirstName != null); AutoGenerateFormService.ForEntity <Student>().Property(s => s.Birthday).DisplayAs("CumpleaƱos"); this.MyStudent = new Student() { LastName = "Brus", FirstName = "Medina", Semester = 6, Birthday = new DateTime() }; autogenerator.CurrentDataContext = MyStudent; }
public MainPage() { this.InitializeComponent(); this.DataContext = new MainPageViewModel(); AutoGenerateFormService.ForEntity <Student>() .Property(s => s.Name) .DisplayAs("Primer Nombre") .WithOrder(1) .VisibleWhen(s => s.Name != null); AutoGenerateFormService.ForEntity <Group>() .CollectionProperty(g => g.Students) .DisplayMember(m => m.Name) .DisplayAs("Estudiantes") .VisibleWhen(g => g.Students != null && g.Students.Count > 0); }