Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
01/31/11 18:15:15 (14 years ago)
Author:
cneumuel
Message:

#1233

  • single sign on with HL
  • local plugins are uploaded if not available online (user can force the useage of local plugins)
  • changed plugin and plugindata db-schema
  • plugin dao tests
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HeuristicLab.Hive-3.4/sources/HeuristicLab.Services.Hive.DataAccess/3.4/Convert.cs

    r5375 r5402  
    6767        target.JobState = source.JobState;
    6868        target.UserId = source.UserId;
    69         //        target.RequiredPlugins = db.Plugins.Select(x => source.PluginsNeededIds.Contains(x.PluginId)); - this is difficult
     69        // RequiredPlugins need to be added by Dao
    7070      }
    7171    }
     
    109109    public static DT.Plugin ToDto(Plugin source) {
    110110      if (source == null) return null;
    111       return new DT.Plugin { Id = source.PluginId, Name = source.Name, Version = new Version(source.Version) };
     111      return new DT.Plugin { Id = source.PluginId, Name = source.Name, Version = new Version(source.Version), UserId = source.UserId, IsLocal = source.IsLocal, DateCreated = source.DateCreated };
    112112    }
    113113    public static Plugin ToEntity(DT.Plugin source) {
     
    118118    public static void ToEntity(DT.Plugin source, Plugin target) {
    119119      if ((source != null) && (target != null)) {
    120         target.PluginId = source.Id; target.Name = source.Name; target.Version = source.Version.ToString();
     120        target.PluginId = source.Id; target.Name = source.Name; target.Version = source.Version.ToString(); target.UserId = source.UserId; target.IsLocal = source.IsLocal; target.DateCreated = source.DateCreated;
    121121      }
    122122    }
     
    126126    public static DT.PluginData ToDto(PluginData source) {
    127127      if (source == null) return null;
    128       return new DT.PluginData { PluginId = source.PluginId, Data = source.Data.ToArray(), FileName = source.FileName, PluginDataId = source.PluginDataId };
     128      return new DT.PluginData { Id = source.PluginDataId, PluginId = source.PluginId, Data = source.Data.ToArray(), FileName = source.FileName };
    129129    }
    130130    public static PluginData ToEntity(DT.PluginData source) {
     
    135135    public static void ToEntity(DT.PluginData source, PluginData target) {
    136136      if ((source != null) && (target != null)) {
    137         target.PluginId = source.PluginId; target.Data = new Binary(source.Data);
    138         target.FileName = target.FileName;
     137        target.PluginDataId = source.Id; target.PluginId = source.PluginId; target.Data = new Binary(source.Data); target.FileName = source.FileName;
    139138      }
    140139    }
Note: See TracChangeset for help on using the changeset viewer.