public ActionResult Hire(int id) { JobNameID jnd = new JobNameID(id); ViewBag.job = jnd; return(View()); }
public ActionResult CompanyDetail(EmployerCompany emp, int id) { JobNameID jnd = new JobNameID(id); ViewBag.Gmap = db.EmployerCompany.Find(job.GetById(id).CompanyID).CompanyAdress.ToString(); ViewBag.job = jnd; return(View(_Emp.GetById(job.GetById(id).CompanyID))); }
/// <summary> /// Returns a string that represents the current object. /// </summary> /// <returns>Returns a string that represents the current object.</returns> public override string ToString() { var sb = new StringBuilder(); sb.AppendFormat("ExtensionSize : {0}\r\n", ExtensionSize); sb.AppendFormat("AuthorName : {0}\r\n", AuthorName.TrimEnd('\0')); sb.AppendFormat("AuthorComments : {0}\r\n", AuthorComments.TrimEnd('\0')); if (TimeStamp.HasValue) { sb.AppendFormat("TimeStamp : {0:yyyy/MM/dd HH:mm:ss}\r\n", TimeStamp.Value); } else { sb.AppendLine("TimeStamp : not specified"); } sb.AppendFormat("Job Name/ID : {0}\r\n", JobNameID.TrimEnd('\0')); sb.AppendFormat("JobTime : {0:hh\\:mm\\:ss}\r\n", JobTime); sb.AppendFormat("SoftwareID : {0}\r\n", SoftwareID); sb.AppendFormat("SoftwareVersion : {0}\r\n", SoftwareVersion); sb.AppendFormat("KeyColor : #{0:X08}\r\n", KeyColor); if (PixelAspectRatioHeight != 0) { sb.AppendFormat("PixelAspectRatio : {0}:{1}\r\n", PixelAspectRatioWidth, PixelAspectRatioHeight); } else { sb.AppendLine("PixelAspectRatio : not specified"); } if (GammaDenominator != 0) { sb.AppendFormat("GammaValue : {0:0.0}\r\n", GammaNumerator / ((double)GammaDenominator)); } else { sb.AppendLine("GammaValue : not specified"); } sb.AppendFormat("ColorCorrectionOffset: {0}\r\n", ColorCorrectionOffset); sb.AppendFormat("PostageStampOffset : {0}\r\n", PostageStampOffset); sb.AppendFormat("ScanLineOffset : {0}\r\n", ScanLineOffset); sb.AppendFormat("AttributesType : {0}\r\n", AttributesType); return(sb.ToString()); }
public ActionResult Hire(Job j, int id, string[] nothing) { var receviceemail = nothing[1]; JobNameID jnd = new JobNameID(id); ViewBag.job = jnd; if (receviceemail != null && receviceemail != "") { System.Net.Mail.MailMessage em = new System.Net.Mail.MailMessage(); em.From = new System.Net.Mail.MailAddress("*****@*****.**", "MSIT11403人資部", System.Text.Encoding.UTF8); em.To.Add(new System.Net.Mail.MailAddress(string.Format("{0}", receviceemail.ToString()))); //收件者 em.Subject = string.Format("你主動應徵{0}已被讀取", job.GetById(id).JobName); //信件主題 em.SubjectEncoding = System.Text.Encoding.UTF8; em.Body = string.Format("{0}你好,你於{1}應徵{2}的信函已被讀取,由於人事單位在處理眾多求職者資料時需要一些時間,若您的資格符合他們的需求將會立即通知您面試,請靜候佳音,謝謝您!<p>(注意:本讀取回條僅代表廠商已打開您的履歷資料,不代表錄取通知!)</p><p>此信件為系統自動發送,請勿直接回覆。</p>", HttpUtility.UrlDecode(Request.Cookies["name"].Value), DateTime.Now, job.GetById(id).JobName); //內容 em.BodyEncoding = System.Text.Encoding.UTF8; em.IsBodyHtml = true; //信件內容是否使用HTML格式 System.Net.Mail.SmtpClient smtp = new System.Net.Mail.SmtpClient(); //登入帳號認證 smtp.Credentials = new System.Net.NetworkCredential("*****@*****.**", "some137root724"); //使用587 Port - google要設定 smtp.Port = 587; smtp.EnableSsl = true; //啟動SSL //end of google設定 smtp.Host = "smtp.gmail.com"; //SMTP伺服器 smtp.Send(em); TempData["message"] = "已寄出申請"; return(RedirectToAction("Index", "Home")); } else { TempData["message"] = "輸入錯誤"; return(View()); } }