예제 #1
0
파일: PRepo.cs 프로젝트: giangcsp/apitest
 public PRepo(Pcontext context)
 {
     this.context = context;
     jsonsettings = new JsonSerializerSettings()
     {
         ReferenceLoopHandling = ReferenceLoopHandling.Ignore,
         Error = (sender, args) =>
         {
             args.ErrorContext.Handled = true;
         },
     };
 }
예제 #2
0
파일: ARepo.cs 프로젝트: giangcsp/apitest
 public ARepo(Pcontext context)
 {
     this.context = context;
     this.context.Database.EnsureCreated();
     this.jsonsettings = new JsonSerializerSettings()
     {
         ReferenceLoopHandling = ReferenceLoopHandling.Ignore,
         Error = (sender, args) =>
         {
             args.ErrorContext.Handled = true;
         },
     };
 }
예제 #3
0
 public void Setup()
 {
     context      = new Pcontext();
     repo         = new ARepo(context);
     jsonsettings = new JsonSerializerSettings()
     {
         ReferenceLoopHandling = ReferenceLoopHandling.Ignore,
         Error = (sender, args) =>
         {
             args.ErrorContext.Handled = true;
         },
     };
 }