| Using the MVC 4 Wijmo Mobile Scaffolding > Step 2 of 4: Add a Model |
Add the following code to create your application Model.
C#
| C# |
Copy Code
|
|---|---|
| using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.Security; using System.ComponentModel.DataAnnotations; |
|
C#
| C# |
Copy Code
|
|---|---|
| public class TahDoList { [Editable(false)] public int Id { get; set; } [Required] public string Title { get; set; } [Display(Name = "Date Created")] public DateTime? CreatedAt { get; set; } [Range(0, 5),UIHint("NumericSlider")] public int Priority { get; set; } [Range(0, 1000000)] public decimal Cost { get; set; } [DataType(DataType.MultilineText)] public string Summary { get; set; } public bool Done { get; set; } [Display(Name = "Date Completed")] public DateTime? DoneAt { get; set; } } } |
|
In the next step, you'll add a Controller to your project.