Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
02/22/11 00:22:52 (14 years ago)
Author:
swagner
Message:

Worked on OKB (#1174)

Location:
branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views
Files:
1 added
20 moved

Legend:

Unmodified
Added
Removed
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/AdministratorView.Designer.cs

    r5532 r5533  
    2020#endregion
    2121
    22 namespace HeuristicLab.Clients.OKB {
     22namespace HeuristicLab.Clients.OKB.Administration {
    2323  partial class AdministratorView {
    2424    /// <summary>
     
    4848      this.tabControl = new System.Windows.Forms.TabControl();
    4949      this.platformsTabPage = new System.Windows.Forms.TabPage();
    50       this.platformCollectionView = new HeuristicLab.Clients.OKB.PlatformCollectionView();
     50      this.platformCollectionView = new HeuristicLab.Clients.OKB.Administration.PlatformCollectionView();
    5151      this.dataTypesTabPage = new System.Windows.Forms.TabPage();
    52       this.dataTypeCollectionView = new HeuristicLab.Clients.OKB.DataTypeCollectionView();
    5352      this.algorithmClassesTabPage = new System.Windows.Forms.TabPage();
    54       this.algorithmClassCollectionView = new HeuristicLab.Clients.OKB.AlgorithmClassCollectionView();
     53      this.algorithmClassCollectionView = new HeuristicLab.Clients.OKB.Administration.AlgorithmClassCollectionView();
    5554      this.algorithmsTabPage = new System.Windows.Forms.TabPage();
    56       this.algorithmCollectionView = new HeuristicLab.Clients.OKB.AlgorithmCollectionView();
     55      this.algorithmCollectionView = new HeuristicLab.Clients.OKB.Administration.AlgorithmCollectionView();
    5756      this.problemClassesTabPage = new System.Windows.Forms.TabPage();
    5857      this.problemsTabPage = new System.Windows.Forms.TabPage();
    5958      this.refreshButton = new System.Windows.Forms.Button();
    6059      this.toolTip = new System.Windows.Forms.ToolTip(this.components);
    61       this.problemClassCollectionView = new HeuristicLab.Clients.OKB.ProblemClassCollectionView();
    62       this.problemCollectionView = new HeuristicLab.Clients.OKB.ProblemCollectionView();
     60      this.problemClassCollectionView = new HeuristicLab.Clients.OKB.Administration.ProblemClassCollectionView();
     61      this.problemCollectionView = new HeuristicLab.Clients.OKB.Administration.ProblemCollectionView();
    6362      this.tabControl.SuspendLayout();
    6463      this.platformsTabPage.SuspendLayout();
     
    113112      // dataTypesTabPage
    114113      //
    115       this.dataTypesTabPage.Controls.Add(this.dataTypeCollectionView);
    116114      this.dataTypesTabPage.Location = new System.Drawing.Point(4, 22);
    117115      this.dataTypesTabPage.Name = "dataTypesTabPage";
     
    121119      this.dataTypesTabPage.Text = "Data Types";
    122120      this.dataTypesTabPage.UseVisualStyleBackColor = true;
    123       //
    124       // dataTypeCollectionView
    125       //
    126       this.dataTypeCollectionView.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
    127                   | System.Windows.Forms.AnchorStyles.Left)
    128                   | System.Windows.Forms.AnchorStyles.Right)));
    129       this.dataTypeCollectionView.Caption = "DataTypeCollection View";
    130       this.dataTypeCollectionView.Content = null;
    131       this.dataTypeCollectionView.Location = new System.Drawing.Point(3, 3);
    132       this.dataTypeCollectionView.Name = "dataTypeCollectionView";
    133       this.dataTypeCollectionView.ReadOnly = false;
    134       this.dataTypeCollectionView.Size = new System.Drawing.Size(713, 374);
    135       this.dataTypeCollectionView.TabIndex = 0;
    136121      //
    137122      // algorithmClassesTabPage
     
    271256    private PlatformCollectionView platformCollectionView;
    272257    private System.Windows.Forms.TabPage dataTypesTabPage;
    273     private DataTypeCollectionView dataTypeCollectionView;
    274258    private System.Windows.Forms.TabPage problemClassesTabPage;
    275259    private System.Windows.Forms.TabPage problemsTabPage;
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/AdministratorView.cs

    r5532 r5533  
    2525using HeuristicLab.MainForm.WindowsForms;
    2626
    27 namespace HeuristicLab.Clients.OKB {
     27namespace HeuristicLab.Clients.OKB.Administration {
    2828  [View("OKB Administrator")]
    29   [Content(typeof(OKBClient), true)]
     29  [Content(typeof(AdministrationClient), true)]
    3030  public sealed partial class AdministratorView : AsynchronousContentView {
    31     public new OKBClient Content {
    32       get { return (OKBClient)base.Content; }
     31    public new AdministrationClient Content {
     32      get { return (AdministrationClient)base.Content; }
    3333      set { base.Content = value; }
    3434    }
     
    5454      if (Content == null) {
    5555        platformCollectionView.Content = null;
    56         dataTypeCollectionView.Content = null;
    5756        algorithmClassCollectionView.Content = null;
    5857        algorithmCollectionView.Content = null;
     
    6160      } else {
    6261        platformCollectionView.Content = Content.Platforms;
    63         dataTypeCollectionView.Content = Content.DataTypes;
    6462        algorithmClassCollectionView.Content = Content.AlgorithmClasses;
    6563        algorithmCollectionView.Content = Content.Algorithms;
     
    7371      refreshButton.Enabled = Content != null;
    7472      platformCollectionView.Enabled = Content != null;
    75       dataTypeCollectionView.Enabled = Content != null;
    7673      algorithmClassCollectionView.Enabled = Content != null;
    7774      algorithmCollectionView.Enabled = Content != null;
     
    9491      } else {
    9592        platformCollectionView.Content = Content.Platforms;
    96         dataTypeCollectionView.Content = Content.DataTypes;
    9793        algorithmClassCollectionView.Content = Content.AlgorithmClasses;
    9894        algorithmCollectionView.Content = Content.Algorithms;
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/AlgorithmClassCollectionView.Designer.cs

    r5532 r5533  
    2020#endregion
    2121
    22 namespace HeuristicLab.Clients.OKB {
     22namespace HeuristicLab.Clients.OKB.Administration {
    2323  partial class AlgorithmClassCollectionView {
    2424    /// <summary>
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/AlgorithmClassCollectionView.cs

    r5532 r5533  
    2525using HeuristicLab.MainForm;
    2626
    27 namespace HeuristicLab.Clients.OKB {
     27namespace HeuristicLab.Clients.OKB.Administration {
    2828  [View("AlgorithmClassCollection View")]
    2929  [Content(typeof(IItemCollection<AlgorithmClass>), true)]
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/AlgorithmCollectionView.Designer.cs

    r5532 r5533  
    2020#endregion
    2121
    22 namespace HeuristicLab.Clients.OKB {
     22namespace HeuristicLab.Clients.OKB.Administration {
    2323  partial class AlgorithmCollectionView {
    2424    /// <summary>
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/AlgorithmCollectionView.cs

    r5532 r5533  
    2525using HeuristicLab.MainForm;
    2626
    27 namespace HeuristicLab.Clients.OKB {
     27namespace HeuristicLab.Clients.OKB.Administration {
    2828  [View("AlgorithmCollection View")]
    2929  [Content(typeof(IItemCollection<Algorithm>), true)]
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/AlgorithmView.Designer.cs

    r5532 r5533  
    2020#endregion
    2121
    22 namespace HeuristicLab.Clients.OKB {
     22namespace HeuristicLab.Clients.OKB.Administration {
    2323  partial class AlgorithmView {
    2424    /// <summary>
     
    5555      this.refreshUsersButton = new System.Windows.Forms.Button();
    5656      this.dataTabPage = new System.Windows.Forms.TabPage();
    57       this.algorithmDataView = new HeuristicLab.Clients.OKB.AlgorithmDataView();
    5857      this.parametersTabPage = new System.Windows.Forms.TabPage();
    59       this.algorithmParameterCollectionView = new HeuristicLab.Clients.OKB.AlgorithmParameterCollectionView();
    6058      this.refreshParametersButton = new System.Windows.Forms.Button();
    6159      this.resultsTabPage = new System.Windows.Forms.TabPage();
    62       this.resultCollectionView = new HeuristicLab.Clients.OKB.ResultCollectionView();
    6360      this.refreshResultsButton = new System.Windows.Forms.Button();
    6461      this.experimentsTabPage = new System.Windows.Forms.TabPage();
    6562      this.refreshExperimentsButton = new System.Windows.Forms.Button();
    66       this.experimentCollectionView = new HeuristicLab.Clients.OKB.ExperimentCollectionView();
    6763      this.tabControl.SuspendLayout();
    6864      this.usersTabPage.SuspendLayout();
     
    196192      // dataTabPage
    197193      //
    198       this.dataTabPage.Controls.Add(this.algorithmDataView);
    199194      this.dataTabPage.Location = new System.Drawing.Point(4, 22);
    200195      this.dataTabPage.Name = "dataTabPage";
     
    205200      this.dataTabPage.UseVisualStyleBackColor = true;
    206201      //
    207       // algorithmDataView
    208       //
    209       this.algorithmDataView.AlgorithmId = ((long)(0));
    210       this.algorithmDataView.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
    211                   | System.Windows.Forms.AnchorStyles.Left)
    212                   | System.Windows.Forms.AnchorStyles.Right)));
    213       this.algorithmDataView.Caption = "AlgorithmData View";
    214       this.algorithmDataView.Content = null;
    215       this.algorithmDataView.Location = new System.Drawing.Point(6, 6);
    216       this.algorithmDataView.Name = "algorithmDataView";
    217       this.algorithmDataView.ReadOnly = false;
    218       this.algorithmDataView.Size = new System.Drawing.Size(613, 254);
    219       this.algorithmDataView.TabIndex = 0;
    220       //
    221       // parametersTabPage
    222       //
    223       this.parametersTabPage.Controls.Add(this.algorithmParameterCollectionView);
    224       this.parametersTabPage.Controls.Add(this.refreshParametersButton);
    225       this.parametersTabPage.Location = new System.Drawing.Point(4, 22);
    226       this.parametersTabPage.Name = "parametersTabPage";
    227       this.parametersTabPage.Padding = new System.Windows.Forms.Padding(3);
    228       this.parametersTabPage.Size = new System.Drawing.Size(625, 266);
    229       this.parametersTabPage.TabIndex = 2;
    230       this.parametersTabPage.Text = "Parameters";
    231       this.parametersTabPage.UseVisualStyleBackColor = true;
    232       //
    233       // algorithmParameterCollectionView
    234       //
    235       this.algorithmParameterCollectionView.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
    236                   | System.Windows.Forms.AnchorStyles.Left)
    237                   | System.Windows.Forms.AnchorStyles.Right)));
    238       this.algorithmParameterCollectionView.Caption = "AlgorithmParameterCollection View";
    239       this.algorithmParameterCollectionView.Content = null;
    240       this.algorithmParameterCollectionView.Location = new System.Drawing.Point(6, 36);
    241       this.algorithmParameterCollectionView.Name = "algorithmParameterCollectionView";
    242       this.algorithmParameterCollectionView.ReadOnly = false;
    243       this.algorithmParameterCollectionView.Size = new System.Drawing.Size(613, 224);
    244       this.algorithmParameterCollectionView.TabIndex = 1;
    245       //
    246202      // refreshParametersButton
    247203      //
     
    252208      this.refreshParametersButton.TabIndex = 0;
    253209      this.refreshParametersButton.UseVisualStyleBackColor = true;
    254       this.refreshParametersButton.Click += new System.EventHandler(this.refreshParametersButton_Click);
    255       //
    256       // resultsTabPage
    257       //
    258       this.resultsTabPage.Controls.Add(this.resultCollectionView);
    259       this.resultsTabPage.Controls.Add(this.refreshResultsButton);
    260       this.resultsTabPage.Location = new System.Drawing.Point(4, 22);
    261       this.resultsTabPage.Name = "resultsTabPage";
    262       this.resultsTabPage.Padding = new System.Windows.Forms.Padding(3);
    263       this.resultsTabPage.Size = new System.Drawing.Size(625, 266);
    264       this.resultsTabPage.TabIndex = 3;
    265       this.resultsTabPage.Text = "Results";
    266       this.resultsTabPage.UseVisualStyleBackColor = true;
    267       //
    268       // resultCollectionView
    269       //
    270       this.resultCollectionView.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
    271                   | System.Windows.Forms.AnchorStyles.Left)
    272                   | System.Windows.Forms.AnchorStyles.Right)));
    273       this.resultCollectionView.Caption = "ResultCollection View";
    274       this.resultCollectionView.Content = null;
    275       this.resultCollectionView.Location = new System.Drawing.Point(6, 36);
    276       this.resultCollectionView.Name = "resultCollectionView";
    277       this.resultCollectionView.ReadOnly = false;
    278       this.resultCollectionView.Size = new System.Drawing.Size(613, 224);
    279       this.resultCollectionView.TabIndex = 1;
    280210      //
    281211      // refreshResultsButton
     
    287217      this.refreshResultsButton.TabIndex = 0;
    288218      this.refreshResultsButton.UseVisualStyleBackColor = true;
    289       this.refreshResultsButton.Click += new System.EventHandler(this.refreshResultsButton_Click);
    290       //
    291       // experimentsTabPage
    292       //
    293       this.experimentsTabPage.Controls.Add(this.experimentCollectionView);
    294       this.experimentsTabPage.Controls.Add(this.refreshExperimentsButton);
    295       this.experimentsTabPage.Location = new System.Drawing.Point(4, 22);
    296       this.experimentsTabPage.Name = "experimentsTabPage";
    297       this.experimentsTabPage.Padding = new System.Windows.Forms.Padding(3);
    298       this.experimentsTabPage.Size = new System.Drawing.Size(625, 266);
    299       this.experimentsTabPage.TabIndex = 4;
    300       this.experimentsTabPage.Text = "Experiments";
    301       this.experimentsTabPage.UseVisualStyleBackColor = true;
    302219      //
    303220      // refreshExperimentsButton
     
    309226      this.refreshExperimentsButton.TabIndex = 0;
    310227      this.refreshExperimentsButton.UseVisualStyleBackColor = true;
    311       this.refreshExperimentsButton.Click += new System.EventHandler(this.refreshExperimentsButton_Click);
    312       //
    313       // experimentCollectionView
    314       //
    315       this.experimentCollectionView.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
    316                   | System.Windows.Forms.AnchorStyles.Left)
    317                   | System.Windows.Forms.AnchorStyles.Right)));
    318       this.experimentCollectionView.Caption = "ExperimentCollection View";
    319       this.experimentCollectionView.Content = null;
    320       this.experimentCollectionView.Location = new System.Drawing.Point(6, 36);
    321       this.experimentCollectionView.Name = "experimentCollectionView";
    322       this.experimentCollectionView.ReadOnly = false;
    323       this.experimentCollectionView.Size = new System.Drawing.Size(613, 224);
    324       this.experimentCollectionView.TabIndex = 1;
    325228      //
    326229      // AlgorithmView
     
    367270    private System.Windows.Forms.Button refreshUsersButton;
    368271    private System.Windows.Forms.TabPage dataTabPage;
    369     private AlgorithmDataView algorithmDataView;
    370272    private System.Windows.Forms.TabPage parametersTabPage;
    371273    private System.Windows.Forms.TabPage resultsTabPage;
    372     private AlgorithmParameterCollectionView algorithmParameterCollectionView;
    373274    private System.Windows.Forms.Button refreshParametersButton;
    374275    private System.Windows.Forms.Button refreshResultsButton;
    375276    private System.Windows.Forms.TabPage experimentsTabPage;
    376     private ResultCollectionView resultCollectionView;
    377     private ExperimentCollectionView experimentCollectionView;
    378277    private System.Windows.Forms.Button refreshExperimentsButton;
    379278
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/AlgorithmView.cs

    r5532 r5533  
    2424using System.Linq;
    2525using System.Windows.Forms;
     26using HeuristicLab.Clients.OKB.Authentication;
    2627using HeuristicLab.MainForm;
    2728using HeuristicLab.MainForm.WindowsForms;
    2829
    29 namespace HeuristicLab.Clients.OKB {
     30namespace HeuristicLab.Clients.OKB.Administration {
    3031  [View("Algorithm View")]
    3132  [Content(typeof(Algorithm), true)]
     
    4546    protected override void OnInitialized(System.EventArgs e) {
    4647      base.OnInitialized(e);
    47       platformComboBoxValues = OKBClient.Instance.Platforms.ToList();
     48      platformComboBoxValues = AdministrationClient.Instance.Platforms.ToList();
    4849      platformComboBox.DataSource = platformComboBoxValues;
    49       algorithmClassComboBoxValues = OKBClient.Instance.AlgorithmClasses.ToList();
     50      algorithmClassComboBoxValues = AdministrationClient.Instance.AlgorithmClasses.ToList();
    5051      algorithmClassComboBox.DataSource = algorithmClassComboBoxValues;
    5152    }
     
    5657        platformComboBox.SelectedIndex = -1;
    5758        algorithmClassComboBox.SelectedIndex = -1;
    58         algorithmDataView.AlgorithmId = 0;
    5959      } else {
    6060        platformComboBox.SelectedItem = platformComboBoxValues.FirstOrDefault(p => p.Id == Content.PlatformId);
    6161        algorithmClassComboBox.SelectedItem = algorithmClassComboBoxValues.FirstOrDefault(a => a.Id == Content.AlgorithmClassId);
    62         algorithmDataView.AlgorithmId = Content.Id;
    6362      }
    6463      usersListBox.DataSource = null;
    65       algorithmDataView.Content = null;
    6664    }
    6765
     
    7371      storeUsersButton.Enabled = (usersListBox.DataSource != null) && !ReadOnly;
    7472      usersListBox.Enabled = (usersListBox.DataSource != null) && !ReadOnly;
    75       algorithmDataView.Enabled = Content != null;
    7673    }
    7774
    7875    protected override void OnContentPropertyChanged(string propertyName) {
    7976      switch (propertyName) {
    80         case "Id":
    81           algorithmDataView.AlgorithmId = Content.Id;
    82           break;
    8377        case "PlatformId":
    8478          platformComboBox.SelectedItem = platformComboBoxValues.FirstOrDefault(p => p.Id == Content.PlatformId);
     
    10498
    10599    private void refreshUsersButton_Click(object sender, System.EventArgs e) {
    106       List<Guid> ids = OKBClient.Instance.GetAlgorithmUsers(Content.Id);
     100      List<Guid> ids = AdministrationClient.Instance.GetAlgorithmUsers(Content.Id);
    107101      if (ids != null) {
    108         List<User> users = OKBClient.Instance.Users.ToList();
     102        List<User> users = AuthenticationClient.Instance.Users.ToList();
    109103        usersListBox.DataSource = users;
    110104        usersListBox.DisplayMember = "Name";
     
    117111    }
    118112    private void storeUsersButton_Click(object sender, System.EventArgs e) {
    119       if (OKBClient.Instance.UpdateAlgorithmUsers(Content.Id, usersListBox.SelectedItems.Cast<User>().Select(u => u.Id).ToList()))
     113      if (AdministrationClient.Instance.UpdateAlgorithmUsers(Content.Id, usersListBox.SelectedItems.Cast<User>().Select(u => u.Id).ToList()))
    120114        storeUsersButton.Enabled = false;
    121115    }
     
    123117      storeUsersButton.Enabled = !ReadOnly;
    124118    }
    125 
    126     private void refreshParametersButton_Click(object sender, EventArgs e) {
    127       algorithmParameterCollectionView.Content = OKBClient.Instance.GetAlgorithmParameters(Content.Id);
    128     }
    129 
    130     private void refreshResultsButton_Click(object sender, EventArgs e) {
    131       resultCollectionView.Content = OKBClient.Instance.GetResults(Content.Id);
    132     }
    133 
    134     private void refreshExperimentsButton_Click(object sender, EventArgs e) {
    135       experimentCollectionView.Content = OKBClient.Instance.GetExperiments(Content.Id, 0);
    136     }
    137119  }
    138120}
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/NamedOKBItemView.Designer.cs

    r5532 r5533  
    2020#endregion
    2121
    22 namespace HeuristicLab.Clients.OKB {
     22namespace HeuristicLab.Clients.OKB.Administration {
    2323  partial class NamedOKBItemView {
    2424    /// <summary>
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/NamedOKBItemView.cs

    r5532 r5533  
    2626using HeuristicLab.MainForm.WindowsForms;
    2727
    28 namespace HeuristicLab.Clients.OKB {
     28namespace HeuristicLab.Clients.OKB.Administration {
    2929  [View("NamedOKBItem View")]
    3030  [Content(typeof(NamedOKBItem), true)]
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/OKBItemView.Designer.cs

    r5532 r5533  
    2020#endregion
    2121
    22 namespace HeuristicLab.Clients.OKB {
     22namespace HeuristicLab.Clients.OKB.Administration {
    2323  partial class OKBItemView {
    2424    /// <summary>
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/OKBItemView.cs

    r5532 r5533  
    2727using HeuristicLab.MainForm.WindowsForms;
    2828
    29 namespace HeuristicLab.Clients.OKB {
     29namespace HeuristicLab.Clients.OKB.Administration {
    3030  [View("OKBItem View")]
    3131  [Content(typeof(OKBItem), true)]
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/PlatformCollectionView.Designer.cs

    r5532 r5533  
    2020#endregion
    2121
    22 namespace HeuristicLab.Clients.OKB {
     22namespace HeuristicLab.Clients.OKB.Administration {
    2323  partial class PlatformCollectionView {
    2424    /// <summary>
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/PlatformCollectionView.cs

    r5532 r5533  
    2525using HeuristicLab.MainForm;
    2626
    27 namespace HeuristicLab.Clients.OKB {
     27namespace HeuristicLab.Clients.OKB.Administration {
    2828  [View("PlatformCollection View")]
    2929  [Content(typeof(IItemCollection<Platform>), true)]
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/ProblemClassCollectionView.Designer.cs

    r5532 r5533  
    2020#endregion
    2121
    22 namespace HeuristicLab.Clients.OKB {
     22namespace HeuristicLab.Clients.OKB.Administration {
    2323  partial class ProblemClassCollectionView {
    2424    /// <summary>
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/ProblemClassCollectionView.cs

    r5532 r5533  
    2525using HeuristicLab.MainForm;
    2626
    27 namespace HeuristicLab.Clients.OKB {
     27namespace HeuristicLab.Clients.OKB.Administration {
    2828  [View("ProblemClassCollection View")]
    2929  [Content(typeof(IItemCollection<ProblemClass>), true)]
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/ProblemCollectionView.Designer.cs

    r5532 r5533  
    2020#endregion
    2121
    22 namespace HeuristicLab.Clients.OKB {
     22namespace HeuristicLab.Clients.OKB.Administration {
    2323  partial class ProblemCollectionView {
    2424    /// <summary>
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/ProblemCollectionView.cs

    r5532 r5533  
    2525using HeuristicLab.MainForm;
    2626
    27 namespace HeuristicLab.Clients.OKB {
     27namespace HeuristicLab.Clients.OKB.Administration {
    2828  [View("ProblemCollection View")]
    2929  [Content(typeof(IItemCollection<Problem>), true)]
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/ProblemView.Designer.cs

    r5532 r5533  
    2020#endregion
    2121
    22 namespace HeuristicLab.Clients.OKB {
     22namespace HeuristicLab.Clients.OKB.Administration {
    2323  partial class ProblemView {
    2424    /// <summary>
     
    5555      this.refreshUsersButton = new System.Windows.Forms.Button();
    5656      this.dataTabPage = new System.Windows.Forms.TabPage();
    57       this.problemDataView = new HeuristicLab.Clients.OKB.ProblemDataView();
    5857      this.tabControl.SuspendLayout();
    5958      this.usersTabPage.SuspendLayout();
     
    181180      // dataTabPage
    182181      //
    183       this.dataTabPage.Controls.Add(this.problemDataView);
    184182      this.dataTabPage.Location = new System.Drawing.Point(4, 22);
    185183      this.dataTabPage.Name = "dataTabPage";
     
    189187      this.dataTabPage.Text = "Platform-Specific Problem Data";
    190188      this.dataTabPage.UseVisualStyleBackColor = true;
    191       //
    192       // problemDataView
    193       //
    194       this.problemDataView.ProblemId = ((long)(0));
    195       this.problemDataView.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
    196                   | System.Windows.Forms.AnchorStyles.Left)
    197                   | System.Windows.Forms.AnchorStyles.Right)));
    198       this.problemDataView.Caption = "ProblemData View";
    199       this.problemDataView.Content = null;
    200       this.problemDataView.Location = new System.Drawing.Point(6, 6);
    201       this.problemDataView.Name = "problemDataView";
    202       this.problemDataView.ReadOnly = false;
    203       this.problemDataView.Size = new System.Drawing.Size(613, 254);
    204       this.problemDataView.TabIndex = 0;
    205189      //
    206190      // ProblemView
     
    244228    private System.Windows.Forms.Button refreshUsersButton;
    245229    private System.Windows.Forms.TabPage dataTabPage;
    246     private ProblemDataView problemDataView;
    247230
    248231  }
  • branches/OKB (trunk integration)/HeuristicLab.Clients.OKB/3.3/Administration/Views/ProblemView.cs

    r5532 r5533  
    2424using System.Linq;
    2525using System.Windows.Forms;
     26using HeuristicLab.Clients.OKB.Authentication;
    2627using HeuristicLab.MainForm;
    2728using HeuristicLab.MainForm.WindowsForms;
    2829
    29 namespace HeuristicLab.Clients.OKB {
     30namespace HeuristicLab.Clients.OKB.Administration {
    3031  [View("Problem View")]
    3132  [Content(typeof(Problem), true)]
     
    4546    protected override void OnInitialized(System.EventArgs e) {
    4647      base.OnInitialized(e);
    47       platformComboBoxValues = OKBClient.Instance.Platforms.ToList();
     48      platformComboBoxValues = AdministrationClient.Instance.Platforms.ToList();
    4849      platformComboBox.DataSource = platformComboBoxValues;
    49       problemClassComboBoxValues = OKBClient.Instance.ProblemClasses.ToList();
     50      problemClassComboBoxValues = AdministrationClient.Instance.ProblemClasses.ToList();
    5051      problemClassComboBox.DataSource = problemClassComboBoxValues;
    5152    }
     
    5657        platformComboBox.SelectedIndex = -1;
    5758        problemClassComboBox.SelectedIndex = -1;
    58         problemDataView.ProblemId = 0;
    5959      } else {
    6060        platformComboBox.SelectedItem = platformComboBoxValues.FirstOrDefault(p => p.Id == Content.PlatformId);
    6161        problemClassComboBox.SelectedItem = problemClassComboBoxValues.FirstOrDefault(a => a.Id == Content.ProblemClassId);
    62         problemDataView.ProblemId = Content.Id;
    6362      }
    6463      usersListBox.DataSource = null;
    65       problemDataView.Content = null;
    6664    }
    6765
     
    7371      storeUsersButton.Enabled = (usersListBox.DataSource != null) && !ReadOnly;
    7472      usersListBox.Enabled = (usersListBox.DataSource != null) && !ReadOnly;
    75       problemDataView.Enabled = Content != null;
    7673    }
    7774
    7875    protected override void OnContentPropertyChanged(string propertyName) {
    7976      switch (propertyName) {
    80         case "Id":
    81           problemDataView.ProblemId = Content.Id;
    82           break;
    8377        case "PlatformId":
    8478          platformComboBox.SelectedItem = platformComboBoxValues.FirstOrDefault(p => p.Id == Content.PlatformId);
     
    10498
    10599    private void refreshUsersButton_Click(object sender, System.EventArgs e) {
    106       List<Guid> ids = OKBClient.Instance.GetProblemUsers(Content.Id);
     100      List<Guid> ids = AdministrationClient.Instance.GetProblemUsers(Content.Id);
    107101      if (ids != null) {
    108         List<User> users = OKBClient.Instance.Users.ToList();
     102        List<User> users = AuthenticationClient.Instance.Users.ToList();
    109103        usersListBox.DataSource = users;
    110104        usersListBox.DisplayMember = "Name";
     
    117111    }
    118112    private void storeUsersButton_Click(object sender, System.EventArgs e) {
    119       if (OKBClient.Instance.UpdateProblemUsers(Content.Id, usersListBox.SelectedItems.Cast<User>().Select(u => u.Id).ToList()))
     113      if (AdministrationClient.Instance.UpdateProblemUsers(Content.Id, usersListBox.SelectedItems.Cast<User>().Select(u => u.Id).ToList()))
    120114        storeUsersButton.Enabled = false;
    121115    }
Note: See TracChangeset for help on using the changeset viewer.