diff --git a/Sevomin.Models/Avalin.cs b/Sevomin.Models/Avalin.cs index 86907f8..6194b57 100644 --- a/Sevomin.Models/Avalin.cs +++ b/Sevomin.Models/Avalin.cs @@ -1,7 +1,7 @@ -using System.Collections.Generic; +using Sevomin.Models.Helpers; +using System.Collections.Generic; using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; -using Sevomin.Models.Helpers; namespace Sevomin.Models { diff --git a/Sevomin.Models/Dovomin.cs b/Sevomin.Models/Dovomin.cs index e9e379f..7dbb9af 100644 --- a/Sevomin.Models/Dovomin.cs +++ b/Sevomin.Models/Dovomin.cs @@ -9,7 +9,7 @@ namespace Sevomin.Models { public string FirstName { get; set; } public string LastName { get; set; } - public DateTime BirthDate { get; set; } + public DateTime? BirthDate { get; set; } public bool IsFulltime { get; set; } public bool IsPartTime { get; set; } public string Description { get; set; } diff --git a/Sevomin.Models/DovominJob.cs b/Sevomin.Models/DovominJob.cs index 78c120b..3b017eb 100644 --- a/Sevomin.Models/DovominJob.cs +++ b/Sevomin.Models/DovominJob.cs @@ -1,10 +1,7 @@ using System; -using System.Collections.Generic; using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace Sevomin.Models { @@ -49,6 +46,11 @@ namespace Sevomin.Models CalculateAffinity(); } + public DovominJob() + { + + } + private void CalculateAffinity() { MinimumRequirement = true; @@ -58,18 +60,18 @@ namespace Sevomin.Models foreach (var jp in Job.JobParameters.Where(x=>x.Moscow != 0 && !string.IsNullOrWhiteSpace(x.StringValue) )) { + count++; DovominParameter dp = Dovomin.DovominParameters.SingleOrDefault(x=>x.ParameterId == jp.ParameterId); + if (dp == null) + continue; if (jp.Moscow == 4) { - if (dp == null) - MinimumRequirement = false; - if ((jp.StringValue != dp.StringValue && jp.NumericValue == 0) || - (jp.NumericValue > 0 && jp.NumericValue > dp.NumericValue)) + if ((jp.StringValue != dp.StringValue && jp.NumericValue == 0) + || (jp.NumericValue > 0 && jp.NumericValue > dp.NumericValue)) { MinimumRequirement = false; } - } - count++; + } decimal? dpv = dp.NumericValue; decimal? jpv = jp.NumericValue; diff --git a/Sevomin.Models/DovominJobViewModel.cs b/Sevomin.Models/DovominJobViewModel.cs new file mode 100644 index 0000000..ac8add3 --- /dev/null +++ b/Sevomin.Models/DovominJobViewModel.cs @@ -0,0 +1,82 @@ +using Sevomin.Models.Helpers; +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Sevomin.Models +{ + public class DovominJobViewModel + { + public long Id { get; set; } + + public string DovominId { get; set; } + + public long JobId { get; set; } + + public DateTime ApplyDate { get; set; } + + public string JalaliApplyDate + { + get + { + return DateAssist.ToShamsi(this.ApplyDate); + } + set + { + ApplyDate = DateAssist.ValidateAndSetToMiladi(value) ?? DateTime.MinValue; + } + } + + [Required(ErrorMessage = "ورود {0} الزامی است.")] + [DisplayName("نامه خصوصی برای کارفرما")] + public string CoverLetter { get; set; } + + public decimal Affinity { get; set; } + + public bool MinimumRequirement { get; set; } + + public DateTime? AvalinSeen { get; set; } + + public string JalaliAvalinSeen + { + get + { + if(AvalinSeen.HasValue) + return DateAssist.ToShamsi(this.AvalinSeen.Value); + + return null; + } + set + { + AvalinSeen = DateAssist.ValidateAndSetToMiladi(value) ?? DateTime.MinValue; + } + } + + public string AvalinComment { get; set; } + + public bool AvalinDelete { get; set; } + + public DovominJobViewModel(DovominJob dovominJob) + { + this.Id = dovominJob.Id; + this.DovominId = dovominJob.DovominId; + this.JobId = dovominJob.JobId; + this.ApplyDate = dovominJob.ApplyDate; + this.CoverLetter = dovominJob.CoverLetter; + this.Affinity = dovominJob.Affinity; + this.MinimumRequirement = dovominJob.MinimumRequirement; + this.AvalinSeen = dovominJob.AvalinSeen; + this.AvalinComment = dovominJob.AvalinComment; + this.AvalinDelete = dovominJob.AvalinDelete; + } + + public DovominJobViewModel() + { + + } + } +} \ No newline at end of file diff --git a/Sevomin.Models/DovominParameter.cs b/Sevomin.Models/DovominParameter.cs index 5d18013..0b1aaf7 100644 --- a/Sevomin.Models/DovominParameter.cs +++ b/Sevomin.Models/DovominParameter.cs @@ -1,10 +1,5 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; -using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace Sevomin.Models { diff --git a/Sevomin.Models/DovominParameterViewModel.cs b/Sevomin.Models/DovominParameterViewModel.cs index e501032..e659f88 100644 --- a/Sevomin.Models/DovominParameterViewModel.cs +++ b/Sevomin.Models/DovominParameterViewModel.cs @@ -1,9 +1,5 @@ using System; using System.Collections.Generic; -using System.ComponentModel.DataAnnotations; -using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace Sevomin.Models { diff --git a/Sevomin.Models/DovominViewModel.cs b/Sevomin.Models/DovominViewModel.cs index 62c03a1..84892c1 100644 --- a/Sevomin.Models/DovominViewModel.cs +++ b/Sevomin.Models/DovominViewModel.cs @@ -1,12 +1,10 @@ -using System; +using Sevomin.Models.Helpers; +using Sevomin.Models.Repositories; +using System; using System.Collections.Generic; +using System.ComponentModel; using System.ComponentModel.DataAnnotations; using System.Linq; -using System.Text; -using System.Threading.Tasks; -using Sevomin.Models.Helpers; -using System.ComponentModel; -using Sevomin.Models.Repositories; namespace Sevomin.Models { @@ -32,7 +30,7 @@ namespace Sevomin.Models [DisplayName("تاریخ تولد")] [DataType(DataType.Date)] - public DateTime BirthDate { get; set; } + public DateTime? BirthDate { get; set; } [DisplayName("تاریخ تولد")] [DataType(DataType.Date)] @@ -40,11 +38,14 @@ namespace Sevomin.Models { get { - return DateAssist.ToShamsi(this.BirthDate); + if (this.BirthDate.HasValue) + return DateAssist.ToShamsi(this.BirthDate.Value); + else + return string.Empty; } set { - BirthDate = DateAssist.ValidateAndSetToMiladi(value) ?? DateTime.MinValue; + BirthDate = DateAssist.ValidateAndSetToMiladi(value) ?? null; } } @@ -72,7 +73,7 @@ namespace Sevomin.Models this.LastName = dovomin.LastName; this.IsFullTime = dovomin.IsFulltime; this.IsPartTime = dovomin.IsPartTime; - this.BirthDate = dovomin.BirthDate == DateTime.MinValue ? DateTime.Now : dovomin.BirthDate; + this.BirthDate = dovomin.BirthDate; this.Description = dovomin.Description; this.EnglishResume = dovomin.EnglishResume; this.PersianResume = dovomin.PersianResume; diff --git a/Sevomin.Models/Enums/MuSCoW.cs b/Sevomin.Models/Enums/MuSCoW.cs index ab4d9ac..e5ca1ad 100644 --- a/Sevomin.Models/Enums/MuSCoW.cs +++ b/Sevomin.Models/Enums/MuSCoW.cs @@ -1,9 +1,4 @@ using Sevomin.Models.Helpers; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace Sevomin.Models.Enums { diff --git a/Sevomin.Models/Enums/ResumeTypes.cs b/Sevomin.Models/Enums/ResumeTypes.cs index a8a5843..28c7066 100644 --- a/Sevomin.Models/Enums/ResumeTypes.cs +++ b/Sevomin.Models/Enums/ResumeTypes.cs @@ -1,9 +1,4 @@ using Sevomin.Models.Helpers; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace Sevomin.Models.Enums { diff --git a/Sevomin.Models/Helpers/EmailValidationAttribute.cs b/Sevomin.Models/Helpers/EmailValidationAttribute.cs index 4900bb1..0f8143b 100644 --- a/Sevomin.Models/Helpers/EmailValidationAttribute.cs +++ b/Sevomin.Models/Helpers/EmailValidationAttribute.cs @@ -1,9 +1,4 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; - + namespace Sevomin.Models.Helpers { using System.ComponentModel.DataAnnotations; diff --git a/Sevomin.Models/Helpers/SevominUserManager.cs b/Sevomin.Models/Helpers/SevominUserManager.cs index 0d9c79d..dd4a93f 100644 --- a/Sevomin.Models/Helpers/SevominUserManager.cs +++ b/Sevomin.Models/Helpers/SevominUserManager.cs @@ -1,9 +1,4 @@ using Microsoft.AspNet.Identity; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace Sevomin.Models.Helpers { diff --git a/Sevomin.Models/Helpers/SevominUserStore.cs b/Sevomin.Models/Helpers/SevominUserStore.cs index dfb3c8c..e0dbb2e 100644 --- a/Sevomin.Models/Helpers/SevominUserStore.cs +++ b/Sevomin.Models/Helpers/SevominUserStore.cs @@ -1,10 +1,4 @@ -using Microsoft.AspNet.Identity; -using Microsoft.AspNet.Identity.EntityFramework; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; +using Microsoft.AspNet.Identity.EntityFramework; namespace Sevomin.Models.Helpers { diff --git a/Sevomin.Models/Helpers/SevominUserValidator.cs b/Sevomin.Models/Helpers/SevominUserValidator.cs index 5c4ac69..e5cd4da 100644 --- a/Sevomin.Models/Helpers/SevominUserValidator.cs +++ b/Sevomin.Models/Helpers/SevominUserValidator.cs @@ -1,9 +1,7 @@ using Microsoft.AspNet.Identity; using Microsoft.AspNet.Identity.EntityFramework; -using System; using System.Collections.Generic; using System.Linq; -using System.Text; using System.Threading.Tasks; namespace Sevomin.Models.Helpers diff --git a/Sevomin.Models/Job.cs b/Sevomin.Models/Job.cs index af16aa5..4e8cc84 100644 --- a/Sevomin.Models/Job.cs +++ b/Sevomin.Models/Job.cs @@ -1,11 +1,8 @@ -using System; +using Sevomin.Models.Helpers; +using System; using System.Collections.Generic; using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using Sevomin.Models.Helpers; namespace Sevomin.Models { diff --git a/Sevomin.Models/JobMiniViewModel.cs b/Sevomin.Models/JobMiniViewModel.cs index 6a46c22..2f6ca27 100644 --- a/Sevomin.Models/JobMiniViewModel.cs +++ b/Sevomin.Models/JobMiniViewModel.cs @@ -1,11 +1,9 @@ -using System; +using Sevomin.Models.Helpers; +using System; using System.Collections.Generic; using System.ComponentModel; using System.ComponentModel.DataAnnotations; using System.Linq; -using System.Text; -using System.Threading.Tasks; -using Sevomin.Models.Helpers; //استخدام نیروی «کنترل پروژه» با ×× سال سابقه ×× دارای ×مدرک× ×× برای کار در ×کشور×شهر× namespace Sevomin.Models diff --git a/Sevomin.Models/JobParameter.cs b/Sevomin.Models/JobParameter.cs index 8310130..9e93a9d 100644 --- a/Sevomin.Models/JobParameter.cs +++ b/Sevomin.Models/JobParameter.cs @@ -1,10 +1,5 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; -using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace Sevomin.Models { diff --git a/Sevomin.Models/JobParameterViewModel.cs b/Sevomin.Models/JobParameterViewModel.cs index 18d319f..2530b5b 100644 --- a/Sevomin.Models/JobParameterViewModel.cs +++ b/Sevomin.Models/JobParameterViewModel.cs @@ -1,9 +1,5 @@ using System; using System.Collections.Generic; -using System.ComponentModel.DataAnnotations; -using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace Sevomin.Models { diff --git a/Sevomin.Models/JobViewModel.cs b/Sevomin.Models/JobViewModel.cs index 41d605e..77be991 100644 --- a/Sevomin.Models/JobViewModel.cs +++ b/Sevomin.Models/JobViewModel.cs @@ -1,11 +1,9 @@ -using System; +using Sevomin.Models.Helpers; +using System; using System.Collections.Generic; +using System.ComponentModel; using System.ComponentModel.DataAnnotations; using System.Linq; -using System.Text; -using System.Threading.Tasks; -using Sevomin.Models.Helpers; -using System.ComponentModel; namespace Sevomin.Models { diff --git a/Sevomin.Models/Migrations/201403261205298_InitialCreate.Designer.cs b/Sevomin.Models/Migrations/201403261205298_InitialCreate.Designer.cs index 8682629..d1e0361 100644 --- a/Sevomin.Models/Migrations/201403261205298_InitialCreate.Designer.cs +++ b/Sevomin.Models/Migrations/201403261205298_InitialCreate.Designer.cs @@ -2,7 +2,6 @@ namespace Sevomin.Models.Migrations { using System.CodeDom.Compiler; - using System.Data.Entity.Migrations; using System.Data.Entity.Migrations.Infrastructure; using System.Resources; diff --git a/Sevomin.Models/Migrations/201403261205298_InitialCreate.cs b/Sevomin.Models/Migrations/201403261205298_InitialCreate.cs index 5ae200d..e4a2b6c 100644 --- a/Sevomin.Models/Migrations/201403261205298_InitialCreate.cs +++ b/Sevomin.Models/Migrations/201403261205298_InitialCreate.cs @@ -1,6 +1,5 @@ namespace Sevomin.Models.Migrations { - using System; using System.Data.Entity.Migrations; public partial class InitialCreate : DbMigration diff --git a/Sevomin.Models/Migrations/201403270612529_Avalin_Dovomin_New_Tables.Designer.cs b/Sevomin.Models/Migrations/201403270612529_Avalin_Dovomin_New_Tables.Designer.cs index bb37109..af988c5 100644 --- a/Sevomin.Models/Migrations/201403270612529_Avalin_Dovomin_New_Tables.Designer.cs +++ b/Sevomin.Models/Migrations/201403270612529_Avalin_Dovomin_New_Tables.Designer.cs @@ -2,7 +2,6 @@ namespace Sevomin.Models.Migrations { using System.CodeDom.Compiler; - using System.Data.Entity.Migrations; using System.Data.Entity.Migrations.Infrastructure; using System.Resources; diff --git a/Sevomin.Models/Migrations/201403270612529_Avalin_Dovomin_New_Tables.cs b/Sevomin.Models/Migrations/201403270612529_Avalin_Dovomin_New_Tables.cs index c89ab34..051dcf9 100644 --- a/Sevomin.Models/Migrations/201403270612529_Avalin_Dovomin_New_Tables.cs +++ b/Sevomin.Models/Migrations/201403270612529_Avalin_Dovomin_New_Tables.cs @@ -1,6 +1,5 @@ namespace Sevomin.Models.Migrations { - using System; using System.Data.Entity.Migrations; public partial class Avalin_Dovomin_New_Tables : DbMigration diff --git a/Sevomin.Models/Migrations/201403270618585_National_Id_Avalin.Designer.cs b/Sevomin.Models/Migrations/201403270618585_National_Id_Avalin.Designer.cs index 8312cd2..e5f93fb 100644 --- a/Sevomin.Models/Migrations/201403270618585_National_Id_Avalin.Designer.cs +++ b/Sevomin.Models/Migrations/201403270618585_National_Id_Avalin.Designer.cs @@ -2,7 +2,6 @@ namespace Sevomin.Models.Migrations { using System.CodeDom.Compiler; - using System.Data.Entity.Migrations; using System.Data.Entity.Migrations.Infrastructure; using System.Resources; diff --git a/Sevomin.Models/Migrations/201403270618585_National_Id_Avalin.cs b/Sevomin.Models/Migrations/201403270618585_National_Id_Avalin.cs index 3a9d8f0..505b0cc 100644 --- a/Sevomin.Models/Migrations/201403270618585_National_Id_Avalin.cs +++ b/Sevomin.Models/Migrations/201403270618585_National_Id_Avalin.cs @@ -1,6 +1,5 @@ namespace Sevomin.Models.Migrations { - using System; using System.Data.Entity.Migrations; public partial class National_Id_Avalin : DbMigration diff --git a/Sevomin.Models/Migrations/201403270733330_Avvalin-update.Designer.cs b/Sevomin.Models/Migrations/201403270733330_Avvalin-update.Designer.cs index 088f895..61de68b 100644 --- a/Sevomin.Models/Migrations/201403270733330_Avvalin-update.Designer.cs +++ b/Sevomin.Models/Migrations/201403270733330_Avvalin-update.Designer.cs @@ -2,7 +2,6 @@ namespace Sevomin.Models.Migrations { using System.CodeDom.Compiler; - using System.Data.Entity.Migrations; using System.Data.Entity.Migrations.Infrastructure; using System.Resources; diff --git a/Sevomin.Models/Migrations/201403270733330_Avvalin-update.cs b/Sevomin.Models/Migrations/201403270733330_Avvalin-update.cs index 5089a0b..08259dd 100644 --- a/Sevomin.Models/Migrations/201403270733330_Avvalin-update.cs +++ b/Sevomin.Models/Migrations/201403270733330_Avvalin-update.cs @@ -1,6 +1,5 @@ namespace Sevomin.Models.Migrations { - using System; using System.Data.Entity.Migrations; public partial class Avvalinupdate : DbMigration diff --git a/Sevomin.Models/Migrations/201403280733264_Param values.Designer.cs b/Sevomin.Models/Migrations/201403280733264_Param values.Designer.cs index 2cbee85..6dcb684 100644 --- a/Sevomin.Models/Migrations/201403280733264_Param values.Designer.cs +++ b/Sevomin.Models/Migrations/201403280733264_Param values.Designer.cs @@ -2,7 +2,6 @@ namespace Sevomin.Models.Migrations { using System.CodeDom.Compiler; - using System.Data.Entity.Migrations; using System.Data.Entity.Migrations.Infrastructure; using System.Resources; diff --git a/Sevomin.Models/Migrations/201403280733264_Param values.cs b/Sevomin.Models/Migrations/201403280733264_Param values.cs index 5d47ca1..4b02f14 100644 --- a/Sevomin.Models/Migrations/201403280733264_Param values.cs +++ b/Sevomin.Models/Migrations/201403280733264_Param values.cs @@ -1,6 +1,5 @@ namespace Sevomin.Models.Migrations { - using System; using System.Data.Entity.Migrations; public partial class Paramvalues : DbMigration diff --git a/Sevomin.Models/Migrations/201403280938368_Job.Designer.cs b/Sevomin.Models/Migrations/201403280938368_Job.Designer.cs index 9c5509f..f34b128 100644 --- a/Sevomin.Models/Migrations/201403280938368_Job.Designer.cs +++ b/Sevomin.Models/Migrations/201403280938368_Job.Designer.cs @@ -2,7 +2,6 @@ namespace Sevomin.Models.Migrations { using System.CodeDom.Compiler; - using System.Data.Entity.Migrations; using System.Data.Entity.Migrations.Infrastructure; using System.Resources; diff --git a/Sevomin.Models/Migrations/201403280938368_Job.cs b/Sevomin.Models/Migrations/201403280938368_Job.cs index 4646ec9..a3be45e 100644 --- a/Sevomin.Models/Migrations/201403280938368_Job.cs +++ b/Sevomin.Models/Migrations/201403280938368_Job.cs @@ -1,6 +1,5 @@ namespace Sevomin.Models.Migrations { - using System; using System.Data.Entity.Migrations; public partial class Job : DbMigration diff --git a/Sevomin.Models/Migrations/201403281016428_JobParameter.Designer.cs b/Sevomin.Models/Migrations/201403281016428_JobParameter.Designer.cs index fea61cf..e0dd61c 100644 --- a/Sevomin.Models/Migrations/201403281016428_JobParameter.Designer.cs +++ b/Sevomin.Models/Migrations/201403281016428_JobParameter.Designer.cs @@ -2,7 +2,6 @@ namespace Sevomin.Models.Migrations { using System.CodeDom.Compiler; - using System.Data.Entity.Migrations; using System.Data.Entity.Migrations.Infrastructure; using System.Resources; diff --git a/Sevomin.Models/Migrations/201403281016428_JobParameter.cs b/Sevomin.Models/Migrations/201403281016428_JobParameter.cs index e6111e6..7df2d20 100644 --- a/Sevomin.Models/Migrations/201403281016428_JobParameter.cs +++ b/Sevomin.Models/Migrations/201403281016428_JobParameter.cs @@ -1,6 +1,5 @@ namespace Sevomin.Models.Migrations { - using System; using System.Data.Entity.Migrations; public partial class JobParameter : DbMigration diff --git a/Sevomin.Models/Migrations/201403290719225_ParameterValue Change.Designer.cs b/Sevomin.Models/Migrations/201403290719225_ParameterValue Change.Designer.cs index 05bd5f2..bce73b2 100644 --- a/Sevomin.Models/Migrations/201403290719225_ParameterValue Change.Designer.cs +++ b/Sevomin.Models/Migrations/201403290719225_ParameterValue Change.Designer.cs @@ -2,7 +2,6 @@ namespace Sevomin.Models.Migrations { using System.CodeDom.Compiler; - using System.Data.Entity.Migrations; using System.Data.Entity.Migrations.Infrastructure; using System.Resources; diff --git a/Sevomin.Models/Migrations/201403290719225_ParameterValue Change.cs b/Sevomin.Models/Migrations/201403290719225_ParameterValue Change.cs index 5b47e67..c6cfd5a 100644 --- a/Sevomin.Models/Migrations/201403290719225_ParameterValue Change.cs +++ b/Sevomin.Models/Migrations/201403290719225_ParameterValue Change.cs @@ -1,6 +1,5 @@ namespace Sevomin.Models.Migrations { - using System; using System.Data.Entity.Migrations; public partial class ParameterValueChange : DbMigration diff --git a/Sevomin.Models/Migrations/201403300806354_DovominParameter.Designer.cs b/Sevomin.Models/Migrations/201403300806354_DovominParameter.Designer.cs index aa932fa..8890e06 100644 --- a/Sevomin.Models/Migrations/201403300806354_DovominParameter.Designer.cs +++ b/Sevomin.Models/Migrations/201403300806354_DovominParameter.Designer.cs @@ -2,7 +2,6 @@ namespace Sevomin.Models.Migrations { using System.CodeDom.Compiler; - using System.Data.Entity.Migrations; using System.Data.Entity.Migrations.Infrastructure; using System.Resources; diff --git a/Sevomin.Models/Migrations/201403300806354_DovominParameter.cs b/Sevomin.Models/Migrations/201403300806354_DovominParameter.cs index 0957bf4..74afb67 100644 --- a/Sevomin.Models/Migrations/201403300806354_DovominParameter.cs +++ b/Sevomin.Models/Migrations/201403300806354_DovominParameter.cs @@ -1,6 +1,5 @@ namespace Sevomin.Models.Migrations { - using System; using System.Data.Entity.Migrations; public partial class DovominParameter : DbMigration diff --git a/Sevomin.Models/Migrations/201403301120307_remove-dovominParameter-moscow.Designer.cs b/Sevomin.Models/Migrations/201403301120307_remove-dovominParameter-moscow.Designer.cs index 6aec55f..7880963 100644 --- a/Sevomin.Models/Migrations/201403301120307_remove-dovominParameter-moscow.Designer.cs +++ b/Sevomin.Models/Migrations/201403301120307_remove-dovominParameter-moscow.Designer.cs @@ -2,7 +2,6 @@ namespace Sevomin.Models.Migrations { using System.CodeDom.Compiler; - using System.Data.Entity.Migrations; using System.Data.Entity.Migrations.Infrastructure; using System.Resources; diff --git a/Sevomin.Models/Migrations/201403301120307_remove-dovominParameter-moscow.cs b/Sevomin.Models/Migrations/201403301120307_remove-dovominParameter-moscow.cs index 130d938..05a78e9 100644 --- a/Sevomin.Models/Migrations/201403301120307_remove-dovominParameter-moscow.cs +++ b/Sevomin.Models/Migrations/201403301120307_remove-dovominParameter-moscow.cs @@ -1,6 +1,5 @@ namespace Sevomin.Models.Migrations { - using System; using System.Data.Entity.Migrations; public partial class removedovominParametermoscow : DbMigration diff --git a/Sevomin.Models/Migrations/201403310557099_Job CreateDate.Designer.cs b/Sevomin.Models/Migrations/201403310557099_Job CreateDate.Designer.cs index 541d944..d7b21f6 100644 --- a/Sevomin.Models/Migrations/201403310557099_Job CreateDate.Designer.cs +++ b/Sevomin.Models/Migrations/201403310557099_Job CreateDate.Designer.cs @@ -2,7 +2,6 @@ namespace Sevomin.Models.Migrations { using System.CodeDom.Compiler; - using System.Data.Entity.Migrations; using System.Data.Entity.Migrations.Infrastructure; using System.Resources; diff --git a/Sevomin.Models/Migrations/201403310557099_Job CreateDate.cs b/Sevomin.Models/Migrations/201403310557099_Job CreateDate.cs index 02bb0b2..75f6368 100644 --- a/Sevomin.Models/Migrations/201403310557099_Job CreateDate.cs +++ b/Sevomin.Models/Migrations/201403310557099_Job CreateDate.cs @@ -1,6 +1,5 @@ namespace Sevomin.Models.Migrations { - using System; using System.Data.Entity.Migrations; public partial class JobCreateDate : DbMigration diff --git a/Sevomin.Models/Migrations/201403310658336_DispalyFormat.Designer.cs b/Sevomin.Models/Migrations/201403310658336_DispalyFormat.Designer.cs index a7bf7b6..aa757b3 100644 --- a/Sevomin.Models/Migrations/201403310658336_DispalyFormat.Designer.cs +++ b/Sevomin.Models/Migrations/201403310658336_DispalyFormat.Designer.cs @@ -2,7 +2,6 @@ namespace Sevomin.Models.Migrations { using System.CodeDom.Compiler; - using System.Data.Entity.Migrations; using System.Data.Entity.Migrations.Infrastructure; using System.Resources; diff --git a/Sevomin.Models/Migrations/201403310658336_DispalyFormat.cs b/Sevomin.Models/Migrations/201403310658336_DispalyFormat.cs index 5085814..eeca4c8 100644 --- a/Sevomin.Models/Migrations/201403310658336_DispalyFormat.cs +++ b/Sevomin.Models/Migrations/201403310658336_DispalyFormat.cs @@ -1,6 +1,5 @@ namespace Sevomin.Models.Migrations { - using System; using System.Data.Entity.Migrations; public partial class DispalyFormat : DbMigration diff --git a/Sevomin.Models/Migrations/201403310716012_bugfix.Designer.cs b/Sevomin.Models/Migrations/201403310716012_bugfix.Designer.cs index a29e560..56f2f39 100644 --- a/Sevomin.Models/Migrations/201403310716012_bugfix.Designer.cs +++ b/Sevomin.Models/Migrations/201403310716012_bugfix.Designer.cs @@ -2,7 +2,6 @@ namespace Sevomin.Models.Migrations { using System.CodeDom.Compiler; - using System.Data.Entity.Migrations; using System.Data.Entity.Migrations.Infrastructure; using System.Resources; diff --git a/Sevomin.Models/Migrations/201403310716012_bugfix.cs b/Sevomin.Models/Migrations/201403310716012_bugfix.cs index 8a8bba6..bc5bc8f 100644 --- a/Sevomin.Models/Migrations/201403310716012_bugfix.cs +++ b/Sevomin.Models/Migrations/201403310716012_bugfix.cs @@ -1,6 +1,5 @@ namespace Sevomin.Models.Migrations { - using System; using System.Data.Entity.Migrations; public partial class bugfix : DbMigration diff --git a/Sevomin.Models/Migrations/201403311237412_DovominJob.Designer.cs b/Sevomin.Models/Migrations/201403311237412_DovominJob.Designer.cs index c63007c..a26a296 100644 --- a/Sevomin.Models/Migrations/201403311237412_DovominJob.Designer.cs +++ b/Sevomin.Models/Migrations/201403311237412_DovominJob.Designer.cs @@ -2,7 +2,6 @@ namespace Sevomin.Models.Migrations { using System.CodeDom.Compiler; - using System.Data.Entity.Migrations; using System.Data.Entity.Migrations.Infrastructure; using System.Resources; diff --git a/Sevomin.Models/Migrations/201403311237412_DovominJob.cs b/Sevomin.Models/Migrations/201403311237412_DovominJob.cs index 88f34ea..98714ca 100644 --- a/Sevomin.Models/Migrations/201403311237412_DovominJob.cs +++ b/Sevomin.Models/Migrations/201403311237412_DovominJob.cs @@ -1,6 +1,5 @@ namespace Sevomin.Models.Migrations { - using System; using System.Data.Entity.Migrations; public partial class DovominJob : DbMigration diff --git a/Sevomin.Models/Migrations/201404051222069_Dovomin_Birthday_Made_Nullable.Designer.cs b/Sevomin.Models/Migrations/201404051222069_Dovomin_Birthday_Made_Nullable.Designer.cs new file mode 100644 index 0000000..1663a40 --- /dev/null +++ b/Sevomin.Models/Migrations/201404051222069_Dovomin_Birthday_Made_Nullable.Designer.cs @@ -0,0 +1,29 @@ +// +namespace Sevomin.Models.Migrations +{ + using System.CodeDom.Compiler; + using System.Data.Entity.Migrations; + using System.Data.Entity.Migrations.Infrastructure; + using System.Resources; + + [GeneratedCode("EntityFramework.Migrations", "6.1.0-30225")] + public sealed partial class Dovomin_Birthday_Made_Nullable : IMigrationMetadata + { + private readonly ResourceManager Resources = new ResourceManager(typeof(Dovomin_Birthday_Made_Nullable)); + + string IMigrationMetadata.Id + { + get { return "201404051222069_Dovomin_Birthday_Made_Nullable"; } + } + + string IMigrationMetadata.Source + { + get { return null; } + } + + string IMigrationMetadata.Target + { + get { return Resources.GetString("Target"); } + } + } +} diff --git a/Sevomin.Models/Migrations/201404051222069_Dovomin_Birthday_Made_Nullable.cs b/Sevomin.Models/Migrations/201404051222069_Dovomin_Birthday_Made_Nullable.cs new file mode 100644 index 0000000..e976101 --- /dev/null +++ b/Sevomin.Models/Migrations/201404051222069_Dovomin_Birthday_Made_Nullable.cs @@ -0,0 +1,18 @@ +namespace Sevomin.Models.Migrations +{ + using System; + using System.Data.Entity.Migrations; + + public partial class Dovomin_Birthday_Made_Nullable : DbMigration + { + public override void Up() + { + AlterColumn("dbo.Dovomin", "BirthDate", c => c.DateTime()); + } + + public override void Down() + { + AlterColumn("dbo.Dovomin", "BirthDate", c => c.DateTime(nullable: false)); + } + } +} diff --git a/Sevomin.Models/Migrations/201404051222069_Dovomin_Birthday_Made_Nullable.resx b/Sevomin.Models/Migrations/201404051222069_Dovomin_Birthday_Made_Nullable.resx new file mode 100644 index 0000000..5c0e49d --- /dev/null +++ b/Sevomin.Models/Migrations/201404051222069_Dovomin_Birthday_Made_Nullable.resx @@ -0,0 +1,126 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + H4sIAAAAAAAEAO0dXW/cuPG9QP+DsE93Rc7r2EmQGus7OHZ8dRs7RtY59M2gtfRaOH3sSdrERtFf1of+pP6Fkvrkt0iRktZBEARYk9JwOBzODIejmf/957+LXx6j0PsC0yxI4uPZy739mQdjP1kF8fp4ts3vf3o7++XnP/9p8X4VPXq/1c8d4ufQm3F2PHvI883RfJ75DzAC2V4U+GmSJff5np9Ec7BK5gf7+3+dv3w5hwjEDMHyvMWnbZwHESz+QH+eJrEPN/kWhJfJCoZZ1Y56lgVU7wpEMNsAHx7PlvBLEgXxXvnkzDsJA5Dh5vB+5oE4TnKQIxyPPmdwmadJvF5uUAMIb542ED13D8IMVrgftY/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MEK5OAkzYN7nIkzTXD6piBez7ziAIqTiN3B1UX8cZtvtjmaMozuQuq7RexqU42/mHM4Lz4Wn91kLqaA0Azw50gf43fbIFw1eJ8Lvj+TgMA+vCoRAV7LHCckWD81kK64IvAyQBX5GtfjDYw2IQKWfYyX4Avsgxti2A9wDfyn9kNtGZDuhaDJvjgLwBpZm1kFo30f/Yl4eBU9/vx/AYIHPhHqAAA= + + + dbo + + \ No newline at end of file diff --git a/Sevomin.Models/Migrations/Configuration.cs b/Sevomin.Models/Migrations/Configuration.cs index ac2734d..7e9bd50 100644 --- a/Sevomin.Models/Migrations/Configuration.cs +++ b/Sevomin.Models/Migrations/Configuration.cs @@ -1,9 +1,6 @@ namespace Sevomin.Models.Migrations { - using System; - using System.Data.Entity; using System.Data.Entity.Migrations; - using System.Linq; internal sealed class Configuration : DbMigrationsConfiguration { diff --git a/Sevomin.Models/Parameter.cs b/Sevomin.Models/Parameter.cs index a0017db..e812c9d 100644 --- a/Sevomin.Models/Parameter.cs +++ b/Sevomin.Models/Parameter.cs @@ -1,11 +1,7 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; +using System.Collections.Generic; using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; -using Sevomin.Models.Helpers; +using System.Linq; namespace Sevomin.Models diff --git a/Sevomin.Models/ParameterValue.cs b/Sevomin.Models/ParameterValue.cs index 53ec4a7..af6f6a4 100644 --- a/Sevomin.Models/ParameterValue.cs +++ b/Sevomin.Models/ParameterValue.cs @@ -1,10 +1,5 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; -using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace Sevomin.Models { diff --git a/Sevomin.Models/PostResultViewModel.cs b/Sevomin.Models/PostResultViewModel.cs index 60ac9c7..b3de39d 100644 --- a/Sevomin.Models/PostResultViewModel.cs +++ b/Sevomin.Models/PostResultViewModel.cs @@ -1,9 +1,4 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; - + namespace Sevomin.Models { public class PostResultViewModel diff --git a/Sevomin.Models/Repositories/IRepository.cs b/Sevomin.Models/Repositories/IRepository.cs index 8f9d834..ab9b80c 100644 --- a/Sevomin.Models/Repositories/IRepository.cs +++ b/Sevomin.Models/Repositories/IRepository.cs @@ -1,5 +1,4 @@ -using System.Data.Entity.Core.Objects; -using System.Linq; +using System.Linq; namespace Sevomin.Models.Repositories { @@ -20,6 +19,7 @@ namespace Sevomin.Models.Repositories { Job GetEmptyJobFor(Avalin avalin); IQueryable ListAll(); + void Apply(Dovomin dovomin, Job job, string coverLetter); } public interface IParameterRepository : IRepository diff --git a/Sevomin.Models/Repositories/JobRepository.cs b/Sevomin.Models/Repositories/JobRepository.cs index 293fbb1..e20f0f7 100644 --- a/Sevomin.Models/Repositories/JobRepository.cs +++ b/Sevomin.Models/Repositories/JobRepository.cs @@ -1,8 +1,6 @@ using System; using System.Collections.Generic; using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace Sevomin.Models.Repositories { @@ -83,7 +81,24 @@ namespace Sevomin.Models.Repositories avalin.Jobs.Add(job); return job; } - #endregion + public void Apply(Dovomin dovomin, Job job, string coverLetter) + { + DovominJob dj = new DovominJob(dovomin, job); + dj.ApplyDate = DateTime.UtcNow; + dj.CoverLetter = coverLetter; + + if (dovomin.DovominJobs.Any(d => d.JobId == job.Id)) + { + dovomin.DovominJobs.First(d => d.JobId == job.Id).CoverLetter = coverLetter; + } + else + { + dovomin.DovominJobs.Add(dj); + } + + Save(); + } + #endregion } } diff --git a/Sevomin.Models/Repositories/ParameterRepository.cs b/Sevomin.Models/Repositories/ParameterRepository.cs index 96b041b..c7d4068 100644 --- a/Sevomin.Models/Repositories/ParameterRepository.cs +++ b/Sevomin.Models/Repositories/ParameterRepository.cs @@ -1,8 +1,4 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; +using System.Linq; namespace Sevomin.Models.Repositories { diff --git a/Sevomin.Models/Sevomin.Models.csproj b/Sevomin.Models/Sevomin.Models.csproj index d26eca6..8354892 100644 --- a/Sevomin.Models/Sevomin.Models.csproj +++ b/Sevomin.Models/Sevomin.Models.csproj @@ -63,6 +63,7 @@ + @@ -136,6 +137,10 @@ 201403311237412_DovominJob.cs + + + 201404051222069_Dovomin_Birthday_Made_Nullable.cs + @@ -147,7 +152,7 @@ - + @@ -196,6 +201,9 @@ 201403311237412_DovominJob.cs + + 201404051222069_Dovomin_Birthday_Made_Nullable.cs + + + - @@ -74,4 +74,14 @@ - + + + + + + + + + + + \ No newline at end of file diff --git a/Sevomin.sln b/Sevomin.sln index 0e85c0f..c87c6d0 100644 --- a/Sevomin.sln +++ b/Sevomin.sln @@ -3,8 +3,6 @@ Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio 2012 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Sevomin.WebFrontend", "Sevomin.WebFrontend\Sevomin.WebFrontend.csproj", "{95C7D295-0E5E-43EB-AD46-8CED0B9FDB2F}" EndProject -Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Controllers", "Controllers", "{9371666D-949F-4978-824B-AC8C396A8720}" -EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Sevomin.WebFrontend.Controllers", "Sevomin.WebFrontend.Controllers\Sevomin.WebFrontend.Controllers.csproj", "{1E1E197B-9300-4512-98CB-B1B8AAB75964}" EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Sevomin.Models", "Sevomin.Models\Sevomin.Models.csproj", "{CB5D89BC-10D1-44D6-857B-A94B5CFCFB11}" @@ -37,7 +35,4 @@ Global GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection - GlobalSection(NestedProjects) = preSolution - {1E1E197B-9300-4512-98CB-B1B8AAB75964} = {9371666D-949F-4978-824B-AC8C396A8720} - EndGlobalSection EndGlobal