Add missing files. Add API for client apps.
[wsti_pai.git] / Projects / Models / Metadata.cs
index a5bac9cff26daed96b733f02dfc61d696be92c1c..ed7b886b727bc1d5f873dc564d7aa5152c3933ee 100644 (file)
@@ -1,8 +1,11 @@
-using System;
+using Newtonsoft.Json;
+using System;
+using System.Collections.Generic;
 using System.ComponentModel.DataAnnotations;
 
 namespace Projects.Models
 {
+    [JsonObject(IsReference = true)]
     public class ProjectMetadata
     {
         [StringLength(50)]
@@ -22,6 +25,7 @@ namespace Projects.Models
         public Nullable<int> user_id;
     }
 
+    [JsonObject(IsReference = true)]
     public class ProjectTaskMetadata
     {
         [StringLength(50)]
@@ -41,6 +45,7 @@ namespace Projects.Models
         public Nullable<int> user_id;
     }
 
+    [JsonObject(IsReference = true)]
     public class UserMetadata
     {
         [Display(Name = "Nazwa użytkownika")]
@@ -50,6 +55,7 @@ namespace Projects.Models
         public string password;
     }
 
+    [JsonObject(IsReference = true)]
     public class TaskStatusMetadata
     {
         [Display(Name = "Status")]