Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/DevWorkMainProject/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ static class Program
[STAThread]
static void Main()
{


Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Application.Run(new Forms.MainForm());
Expand Down
2 changes: 1 addition & 1 deletion src/DevWorkMainSolution.sln
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Express 2013 for Windows Desktop
# Visual Studio 2013
VisualStudioVersion = 12.0.31101.0
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DevWorkMainProject", "DevWorkMainProject\DevWorkMainProject.csproj", "{A8B749A8-ECB6-4BD0-AA46-2F0DD7AEAE82}"
Expand Down
68 changes: 68 additions & 0 deletions src/Domain/Domain.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,21 @@
<AssemblyName>Domain</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<PublishUrl>publish\</PublishUrl>
<Install>true</Install>
<InstallFrom>Disk</InstallFrom>
<UpdateEnabled>false</UpdateEnabled>
<UpdateMode>Foreground</UpdateMode>
<UpdateInterval>7</UpdateInterval>
<UpdateIntervalUnits>Days</UpdateIntervalUnits>
<UpdatePeriodically>false</UpdatePeriodically>
<UpdateRequired>false</UpdateRequired>
<MapFileExtensions>true</MapFileExtensions>
<ApplicationRevision>0</ApplicationRevision>
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
<IsWebBootstrapper>false</IsWebBootstrapper>
<UseApplicationTrust>false</UseApplicationTrust>
<BootstrapperEnabled>true</BootstrapperEnabled>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
Expand All @@ -30,6 +45,15 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="FluentNHibernate">
<HintPath>..\packages\FluentNHibernate.2.0.1.0\lib\net40\FluentNHibernate.dll</HintPath>
</Reference>
<Reference Include="Iesi.Collections">
<HintPath>..\packages\Iesi.Collections.4.0.0.4000\lib\net40\Iesi.Collections.dll</HintPath>
</Reference>
<Reference Include="NHibernate">
<HintPath>..\packages\NHibernate.4.0.0.4000\lib\net40\NHibernate.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Drawing" />
Expand All @@ -41,16 +65,60 @@
</ItemGroup>
<ItemGroup>
<Compile Include="Entities\Candidate.cs" />
<Compile Include="Maps\CandidateMap.cs" />
<Compile Include="Entities\Contact.cs" />
<Compile Include="Maps\ContactMap.cs" />
<Compile Include="Entities\ContactType.cs" />
<Compile Include="Entities\EnglishLevelType.cs" />
<Compile Include="Entities\GenderType.cs" />
<Compile Include="NHibernateHelper.cs" />
<Compile Include="Entities\PhoneNumber.cs" />
<Compile Include="Maps\PhoneNumberMap.cs" />
<Compile Include="Entities\PhoneType.cs" />
<Compile Include="Maps\SocialNetworkProfileMap.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Entities\SocialNetworkProfile.cs" />
<Compile Include="Entities\SocialNetworkType.cs" />
</ItemGroup>
<ItemGroup>
<None Include="packages.config" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\DevWorkMainProject\DevWorkMainProject.csproj">
<Project>{a8b749a8-ecb6-4bd0-aa46-2f0dd7aeae82}</Project>
<Name>DevWorkMainProject</Name>
</ProjectReference>
</ItemGroup>
<ItemGroup>
<WCFMetadata Include="Service References\" />
</ItemGroup>
<ItemGroup>
<BootstrapperPackage Include=".NETFramework,Version=v4.5">
<Visible>False</Visible>
<ProductName>Microsoft .NET Framework 4.5 %28x86 and x64%29</ProductName>
<Install>true</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Client.3.5">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5 SP1 Client Profile</ProductName>
<Install>false</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5 SP1</ProductName>
<Install>false</Install>
</BootstrapperPackage>
</ItemGroup>
<ItemGroup />
<ItemGroup>
<Content Include="Sql\Database.mdf">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
<Content Include="Sql\Database_log.ldf">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
<DependentUpon>Database.mdf</DependentUpon>
</Content>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
Expand Down
206 changes: 19 additions & 187 deletions src/Domain/Entities/Candidate.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,198 +9,30 @@ namespace Domain
{
public class Candidate
{
private string firstName;
private string middleName;
private string lastName;
private DateTime birthdayDate;
private GenderType gender;
private string country;
private string city;
private bool relocationAgreement;
private Image photo;
private List<PhoneNumber> phonesList;
private string email;
private string skype;
private string siteURL;
private EnglishLevelType englishLevel;
private List<Contact> contacsList;
private List<SocialNetworkProfile> socialNetworksList;

public Candidate()
{
BirthdayDate = new DateTime();
PhonesList = new List<PhoneNumber>();
ContacsList = new List<Contact>();
ContactsList = new List<Contact>();
SocialNetworksList = new List<SocialNetworkProfile>();
}

public virtual string FirstName
{
get
{
return firstName;
}

set
{
firstName = value;
}
}

public virtual string MiddleName
{
get
{
return middleName;
}

set
{
middleName = value;
}
}

public virtual string LastName
{
get
{
return lastName;
}

set
{
lastName = value;
}
}


public virtual DateTime BirthdayDate
{
get
{
return birthdayDate;
}
set
{
if (value == null)
birthdayDate = new DateTime();
else birthdayDate = value;
}
}
public virtual GenderType Gender
{
get
{
return gender;
}
set
{
gender = value;
}
}
public virtual string Country
{
get
{
return country;
}
set
{
country = value;
}
}
public virtual string City
{
get
{
return city;
}
set
{
city = value;
}
}
public virtual bool RelocationAgreement { get { return relocationAgreement; } set { relocationAgreement = value; } }
public virtual Image Photo { get; set; } //???
public virtual List<PhoneNumber> PhonesList
{
get
{
return phonesList;
}
set
{
if (value == null)
phonesList = new List<PhoneNumber>();
else phonesList = value;
}
}
public virtual string Email
{
get
{
return email;
}
set
{
email = value;
}
}
public virtual string Skype
{
get
{
return skype;
}
set
{
skype = value;
}
}
public virtual string SiteURL
{
get
{
return siteURL;
}
set
{
siteURL = value;
}
}
public virtual int Id { get; private set; }
public virtual string FirstName {get; set;}
public virtual string MiddleName{get; set;}
public virtual string LastName {get; set;}
public virtual DateTime DOB {get; set;}
public virtual GenderType Gender {get; set;}
public virtual string Country {get; set;}
public virtual string City {get; set;}
public virtual bool RelocationAgreement { get; set; }
public virtual Image Photo { get; set; }
public virtual List<PhoneNumber> PhonesList { get; set; }
public virtual string Email { get; set; }
public virtual string Skype { get; set; }
public virtual string SiteURL { get; set; }
public virtual EnglishLevelType EnglishLevel { get; set; }

public virtual List<Contact> ContacsList
{
get
{
return contacsList;
}
set
{
if (value == null)
contacsList = new List<Contact>();
else contacsList = value;
}
}
public virtual List<SocialNetworkProfile> SocialNetworksList
{
get
{
return socialNetworksList;
}
set
{
if (value == null)
socialNetworksList = new List<SocialNetworkProfile>();
else socialNetworksList = value;
}
}

//List has to be sorted by dates
public virtual Contact getLastContact()
{
return ContacsList[ContacsList.Count - 1];
}
}
public virtual List<Contact> ContactsList { get; set; }
public virtual List<SocialNetworkProfile> SocialNetworksList { get; set; }
public virtual Contact LastContact { get; set; }
}
}
24 changes: 6 additions & 18 deletions src/Domain/Entities/Contact.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,11 @@ namespace Domain

public class Contact
{
private ContactType type;
private DateTime date;
private string comment;
public ContactType Type
{
get { return type; }
set { type = value; }
}
public DateTime Date
{
get { return date; }
set { date = value; }
}
public string Comment
{
get { return comment; }
set { comment = value; }
}
public virtual int Id { get; private set; }
public ContactType Type{get; set;}
public DateTime Date { get; set; }
public string Comment { get; set; }
public virtual Candidate Candidate { get; set; }
public Contact() {}
}
}
17 changes: 5 additions & 12 deletions src/Domain/Entities/PhoneNumber.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,10 @@ namespace Domain

public class PhoneNumber
{
private string phone;
private PhoneType type;
public string Phone
{
get { return phone; }
set { phone = value; }
}
public PhoneType Type
{
get { return type; }
set { type = value; }
}
public virtual int Id { get; private set; }
public virtual string Phone { get; set; }
public virtual PhoneType Type { get; set; }
public virtual Candidate Candidate { get; set; }
public PhoneNumber() { }
}
}
Loading