-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🔨 add project fieds with description in seekers api
- Loading branch information
Showing
13 changed files
with
1,148 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
Server/JobLeet.WebApi/JobLeet.Api/Models/Common/V1/ProjectsModel.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
namespace JobLeet.WebApi.JobLeet.Api.Models.Common.V1 | ||
{ | ||
public class ProjectModel : BaseModel | ||
{ | ||
public string Title { get; set; } | ||
|
||
public List<string> Responsibilities { get; set; } | ||
|
||
public List<string> TechnologiesUsed { get; set; } | ||
|
||
public string? Role { get; set; } | ||
public DateOnly StartDate { get; set; } | ||
public DateOnly? EndDate { get; set; } | ||
|
||
public bool IsOngoing => !EndDate.HasValue; | ||
|
||
public string? ProjectUrl { get; set; } | ||
public string? GitHubUrl { get; set; } | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 22 additions & 0 deletions
22
Server/JobLeet.WebApi/JobLeet.Core/Entities/Common/V1/Projects.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
namespace JobLeet.WebApi.JobLeet.Core.Entities.Common.V1 | ||
{ | ||
public class Project : BaseEntity | ||
{ | ||
public string Title { get; set; } | ||
|
||
public List<string> Responsibilities { get; set; } | ||
|
||
public List<string> TechnologiesUsed { get; set; } | ||
|
||
public string? Role { get; set; } | ||
|
||
public DateOnly StartDate { get; set; } | ||
|
||
public DateOnly? EndDate { get; set; } | ||
|
||
public bool IsOngoing => !EndDate.HasValue; | ||
|
||
public string? ProjectUrl { get; set; } | ||
public string? GitHubUrl { get; set; } | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
40 changes: 40 additions & 0 deletions
40
Server/JobLeet.WebApi/JobLeet.Infrastructure/JobLeet.Mappers/V1/ProjectsMapper.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
using JobLeet.WebApi.JobLeet.Api.Models.Common.V1; | ||
using JobLeet.WebApi.JobLeet.Core.Entities.Common.V1; | ||
|
||
namespace JobLeet.WebApi.JobLeet.Mappers.V1 | ||
{ | ||
public static class ProjectsMapper | ||
{ | ||
public static Project ToProjectDatabase(Project entity) | ||
{ | ||
return new Project | ||
{ | ||
Id = entity.Id, | ||
Title = entity.Title, | ||
Responsibilities = entity.Responsibilities, | ||
TechnologiesUsed = entity.TechnologiesUsed, | ||
Role = entity.Role, | ||
StartDate = entity.StartDate, | ||
EndDate = entity.EndDate, | ||
ProjectUrl = entity.ProjectUrl, | ||
GitHubUrl = entity.ProjectUrl, | ||
}; | ||
} | ||
|
||
public static ProjectModel ToProjectModel(Project model) | ||
{ | ||
return new ProjectModel | ||
{ | ||
Id = model.Id, | ||
Title = model.Title, | ||
Responsibilities = model.Responsibilities, | ||
TechnologiesUsed = model.TechnologiesUsed, | ||
Role = model.Role, | ||
StartDate = model.StartDate, | ||
EndDate = model.EndDate, | ||
ProjectUrl = model.ProjectUrl, | ||
GitHubUrl = model.ProjectUrl, | ||
}; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.