Ejemplo n.º 1
0
 public DirectResult SaveForm(Person p)
 {
     return this.Direct(new {
         success = true,
         data = p
     }, new StringEnumConverter());
 }
Ejemplo n.º 2
0
 public DirectResult LoadForm()
 {
     var person = new Person {
         Name = "John Smith",
         Email = "*****@*****.**",
         Gender = Gender.Male,
         Birthday = new DateTime(1969, 12, 31),
         Salary = 55000
     };
     return this.Direct(new {
         success = true,
         data = person
     });
 }
Ejemplo n.º 3
0
 public DirectResult EchoPerson(Person person)
 {
     return this.Direct(person, new JavaScriptDateTimeConverter(), new StringEnumConverter());
 }