0
namespace DC.DNS.Models.Areas.Server
{

   public class ServerSearchModel
   {

      [JsonProperty(PropertyName = "id",
                      Order = 10)]
      public int Id{get;set;}

      [JsonProperty(PropertyName = "hostname",
                      Order = 20)]
      public string Hostname{get;set;}

      [JsonProperty(PropertyName = "dnsversion",
                      Order = 30)]
      public int? DnsVersion{get;set;}

      public override string ToString()
      {
         return JsonConvert.SerializeObject(this);
      }

   }

}

I want to import these class properties (Id, Hostname and DnsVersion) as a list, so I can later use that list for my ServerServices. I'm having quite the hard time figuring it out. What can I do?

0 Answers0