Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
05/07/11 13:39:31 (14 years ago)
Author:
gschwarz
Message:

#1433 Updated Problem Control/View

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/WebApplication/MVC2/HLWebOKBAdminPlugin/Models/ProblemModel.cs

    r6130 r6142  
    2121                Problem[] problems = adminClient.GetProblems();
    2222                return problems.ToList<Problem>();
     23            }
     24        }
    2325
     26        public List<ProblemClass> ProblemClasses {
     27            get {
     28                AdministrationServiceClient adminClient = Admin.GetClientFactory("okbtester", "okbtester");
     29                IList<ProblemClass> problemClassList = new List<ProblemClass>();
     30                ProblemClass[] problemClass = adminClient.GetProblemClasses();
     31                return problemClass.ToList<ProblemClass>();
     32            }
     33        }
     34
     35        public List<Platform> Plattforms {
     36            get {
     37                AdministrationServiceClient adminClient = Admin.GetClientFactory("okbtester", "okbtester");
     38                IList<Platform> plattformList = new List<Platform>();
     39                Platform[] plattforms = adminClient.GetPlatforms();
     40                return plattforms.ToList<Platform>();
    2441            }
    2542        }
     
    3047        public Problem Problem { get; set; }
    3148
     49        public void SaveProblem(Problem problem) {
     50            AdministrationServiceClient adminClient = Admin.GetClientFactory("okbtester", "okbtester");
     51            adminClient.UpdateProblem(problem);
     52        }
     53
     54        public void CreateProblem(Problem problem) {
     55            AdministrationServiceClient adminClient = Admin.GetClientFactory("okbtester", "okbtester");
     56            adminClient.AddProblem(problem);
     57        }
     58
    3259    }
    3360}
Note: See TracChangeset for help on using the changeset viewer.