init
This commit is contained in:
commit
e124a47765
19374 changed files with 9806149 additions and 0 deletions
47
Kreta.BusinessLogic/HelperClasses/KretaCourseCo.cs
Normal file
47
Kreta.BusinessLogic/HelperClasses/KretaCourseCo.cs
Normal file
|
@ -0,0 +1,47 @@
|
|||
using System;
|
||||
using Nexius.IdentityProvider.Model.External.V1;
|
||||
|
||||
namespace Kreta.BusinessLogic.HelperClasses
|
||||
{
|
||||
[Serializable]
|
||||
public class KretaCourseCo
|
||||
{
|
||||
public KretaCourseCo() { CourseObject = new KretaCourseObjectCo(); }
|
||||
|
||||
public KretaCourseCo(Course course)
|
||||
{
|
||||
Id = course.Id;
|
||||
Title = course.Title;
|
||||
Description = course.Description;
|
||||
ImageUrl = course.ImageUrl;
|
||||
CreatedAt = course.CreatedAt;
|
||||
LaunchUri = course.LaunchUri;
|
||||
CourseObject = new KretaCourseObjectCo(course.CourseObject);
|
||||
Tags = course.Tags;
|
||||
}
|
||||
|
||||
public Guid Id { get; set; }
|
||||
public string Title { get; set; }
|
||||
public string Description { get; set; }
|
||||
public string ImageUrl { get; set; }
|
||||
public DateTime CreatedAt { get; set; }
|
||||
public string LaunchUri { get; set; }
|
||||
public KretaCourseObjectCo CourseObject { get; set; }
|
||||
public string Tags { get; set; }
|
||||
|
||||
public Course ToCourse()
|
||||
{
|
||||
return new Course
|
||||
{
|
||||
Id = this.Id,
|
||||
Title = this.Title,
|
||||
Description = this.Description,
|
||||
ImageUrl = this.ImageUrl,
|
||||
CreatedAt = this.CreatedAt,
|
||||
LaunchUri = this.LaunchUri,
|
||||
CourseObject = CourseObject.ToCourseObject(),
|
||||
Tags = this.Tags
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue