public IHttpActionResult UploadImg(string typeCode, string projectId) { try { HttpRequest request = HttpContext.Current.Request; HttpFileCollection fileCollect = request.Files; for (var i = 0; i < fileCollect.Count; i++) { HttpPostedFile file = fileCollect[i]; string fileExtension = Path.GetExtension(file.FileName); string internalName = Guid.NewGuid() + fileExtension; string absolutePath = HttpContext.Current.Server.MapPath("~/") + "UploadFiles/" + internalName; file.SaveAs(absolutePath); ReopenMemo memo = ReopenMemo.GetReopenMemo(projectId); if (memo == null) { memo = new ReopenMemo(); } memo.ProjectId = projectId; if (typeCode == "ExteriorAfterImg1") { memo.ExteriorAfterImg1 = internalName; } else if (typeCode == "ExteriorAfterImg2") { memo.ExteriorAfterImg2 = internalName; } else if (typeCode == "InteriorAfterImg1") { memo.InteriorAfterImg1 = internalName; } else if (typeCode == "InteriorAfterImg2") { memo.InteriorAfterImg2 = internalName; } ReopenMemo.SaveReopenMemo(memo); } return(Ok()); } catch (Exception ex) { return(BadRequest(ex.Message)); } }
public IHttpActionResult GetReopenMemo(string projectId) { var memo = ReopenMemo.GetReopenMemo(projectId); if (string.IsNullOrEmpty(memo.ExteriorAfterImg1)) { memo.ExteriorAfterImgURL1 = "../Images/mcd_logo.png"; } else { memo.ExteriorAfterImgURL1 = SiteFilePath.UploadFiles_URL + "/" + memo.ExteriorAfterImg1; } if (string.IsNullOrEmpty(memo.ExteriorAfterImg2)) { memo.ExteriorAfterImgURL2 = "../Images/mcd_logo.png"; } else { memo.ExteriorAfterImgURL2 = SiteFilePath.UploadFiles_URL + "/" + memo.ExteriorAfterImg2; } if (string.IsNullOrEmpty(memo.InteriorAfterImg1)) { memo.InteriorAfterImgURL1 = "../Images/mcd_logo.png"; } else { memo.InteriorAfterImgURL1 = SiteFilePath.UploadFiles_URL + "/" + memo.InteriorAfterImg1; } if (string.IsNullOrEmpty(memo.InteriorAfterImg2)) { memo.InteriorAfterImgURL2 = "../Images/mcd_logo.png"; } else { memo.InteriorAfterImgURL2 = SiteFilePath.UploadFiles_URL + "/" + memo.InteriorAfterImg2; } return(Ok(memo)); }
public IHttpActionResult DeleteImg(string typeCode, string projectId) { var memo = ReopenMemo.GetReopenMemo(projectId); if (typeCode == "ExteriorAfterImg1") { memo.ExteriorAfterImg1 = ""; } else if (typeCode == "ExteriorAfterImg2") { memo.ExteriorAfterImg2 = ""; } else if (typeCode == "InteriorAfterImg1") { memo.InteriorAfterImg1 = ""; } else if (typeCode == "InteriorAfterImg2") { memo.InteriorAfterImg2 = ""; } ReopenMemo.SaveReopenMemo(memo); return(Ok()); }
public IHttpActionResult SaveReopenMemo(ReopenMemo memo) { ReopenMemo.SaveReopenMemo(memo); return(Ok()); }
public IHttpActionResult GetSelectYearMonth(string usCode) { var financeYear = ReopenMemo.GetSelectYearMonth(usCode); return(Ok(financeYear)); }
public IHttpActionResult SendReopenMemo(PostMemo <ReopenMemo> postData) { var actor = ProjectUsers.GetProjectUser(postData.Entity.ProjectId, ProjectUserRoleCode.AssetActor); using (TransactionScope tranScope = new TransactionScope()) { Dictionary <string, string> pdfData = new Dictionary <string, string>(); if (postData.Entity.ProjectId.ToLower().IndexOf("rebuild") >= 0) { pdfData.Add("WorkflowName", "Rebuild"); } else if (postData.Entity.ProjectId.ToLower().IndexOf("majorlease") != -1) { pdfData.Add("WorkflowName", "MajorLease"); } else if (postData.Entity.ProjectId.ToLower().IndexOf("renewal") != -1) { pdfData.Add("WorkflowName", "Renewal"); } else if (postData.Entity.ProjectId.ToLower().IndexOf("reimage") >= 0) { pdfData.Add("WorkflowName", "Reimage"); } else { pdfData.Add("WorkflowName", postData.Entity.ProjectId); } pdfData.Add("ProjectID", postData.Entity.ProjectId); pdfData.Add("RegionNameENUS", postData.Entity.Store.StoreBasicInfo.RegionENUS); pdfData.Add("RegionNameZHCN", postData.Entity.Store.StoreBasicInfo.RegionZHCN); pdfData.Add("MarketNameENUS", postData.Entity.Store.StoreBasicInfo.MarketENUS); pdfData.Add("MarketNameZHCN", postData.Entity.Store.StoreBasicInfo.MarketZHCN); pdfData.Add("ProvinceNameENUS", postData.Entity.Store.StoreBasicInfo.ProvinceENUS); pdfData.Add("ProvinceNameZHCN", postData.Entity.Store.StoreBasicInfo.ProvinceZHCN); pdfData.Add("CityNameENUS", postData.Entity.Store.StoreBasicInfo.CityENUS); pdfData.Add("CityNameZHCN", postData.Entity.Store.StoreBasicInfo.CityZHCN); pdfData.Add("StoreNameENUS", postData.Entity.Store.StoreBasicInfo.NameENUS); pdfData.Add("StoreNameZHCN", postData.Entity.Store.StoreBasicInfo.NameZHCN); pdfData.Add("USCode", postData.Entity.Store.StoreBasicInfo.StoreCode); pdfData.Add("IsMcCafe", postData.Entity.NewMcCafe ? "Y" : "N"); pdfData.Add("IsKiosk", postData.Entity.NewKiosk ? "Y" : "N"); pdfData.Add("IsMDS", postData.Entity.NewMDS ? "Y" : "N"); pdfData.Add("Is24Hour", postData.Entity.Is24H ? "Y" : "N"); pdfData.Add("TTMNetSales", DataConverter.ToMoney(postData.Entity.TTMNetSales) ?? " "); var TTMNetSalesYearMonth = ""; if (postData.Entity.YearMonthList != null && postData.Entity.YearMonthList.Count > 0) { foreach (var val in postData.Entity.YearMonthList) { if (val.Value == postData.Entity.TTMNetSales) { TTMNetSalesYearMonth = val.Name; break; } } } pdfData.Add("TTMNetSalesYearMonth", TTMNetSalesYearMonth ?? " "); pdfData.Add("IncrementalSales", postData.Entity.IncrementalSales.HasValue ? DataConverter.ToMoney((postData.Entity.IncrementalSales.Value * 100)) : " "); pdfData.Add("GBDate", postData.Entity.GBDate.HasValue ? postData.Entity.GBDate.Value.ToString("yyyy-MM-dd") : " "); pdfData.Add("ConstCompletionDate", postData.Entity.CompletionDate.HasValue ? postData.Entity.CompletionDate.Value.ToString("yyyy-MM-dd") : " "); //if (postData.Entity.ProjectId.ToLower().IndexOf("reimage") >= 0) //{ // pdfData.Add("ReopenDate", postData.Entity.RmgInfo.ReopenDate.HasValue ? postData.Entity.RmgInfo.ReopenDate.Value.ToString("yyyy-MM-dd") : " "); //} //else //{ // pdfData.Add("ReopenDate", postData.Entity.ReopenDate.HasValue ? postData.Entity.RbdInfo.ReopenDate.Value.ToString("yyyy-MM-dd") : " "); //} pdfData.Add("ReopenDate", postData.Entity.ReopenDate.HasValue ? postData.Entity.ReopenDate.Value.ToString("yyyy-MM-dd") : " "); pdfData.Add("DesignConcept", GetConcetpetDesc(postData.Entity.DesignConcept) ?? " "); pdfData.Add("TotalWriteOff", DataConverter.ToMoney(postData.Entity.WriteOff.TotalWriteOff) ?? " "); pdfData.Add("TotalReinvestmentBudget", DataConverter.ToMoney(postData.Entity.TotalReinvestmentBudget) ?? " "); pdfData.Add("OriginalOperationSize", postData.Entity.OriginalOperationSize ?? " "); pdfData.Add("NewOperationSize", postData.Entity.AftOperationSize ?? " "); pdfData.Add("OriginalSeatNumber", postData.Entity.OriginalSeatNumber ?? " "); pdfData.Add("ARSN", postData.Entity.AftARSN ?? " "); pdfData.Add("AftARPT", postData.Entity.AftARPT ?? " "); pdfData.Add("PriceTiter", postData.Entity.PriceTiter ?? " "); if (postData.Entity.ExteriorAfterImgURL1 != "../Images/mcd_logo.png") { pdfData.Add("ExteriorAfterImgURL1", HtmlConversionUtility.ImageToBase64(postData.Entity.ExteriorAfterImgURL1, System.Drawing.Imaging.ImageFormat.Png)); } else { pdfData.Add("ExteriorAfterImgURL1", "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADYAAAAzCAMAAADrVgtcAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMy1jMDExIDY2LjE0NTY2MSwgMjAxMi8wMi8wNi0xNDo1NjoyNyAgICAgICAgIj4gP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e+aRuMaPBbBLEgGkQDInAQc3Z+F2wsyd6kUKkUKiRiL6xQ4B9RqYoqFApVyfybRVFRTRF7D2rCmSo55t7WbyIqIiqaR8bWn89+Z1Nl5bTcog/OR+Xn3owpik1p/ysKsXVlNtWQr+62b4+7F8eIys5Nmfx67qAF7WNi8p+Ny4i8U5kfc3zQzhdgOCybTXF36hvJk+9Pvc+YX5KxYuB3x2MZGePGPJ6fvGJb8y1GCSOlWQW3dsP6rGrO3t44qHFV2kexq1b/9Gby8adHZcTl3onb1Hxr+zjG6nMaLHxLbMjex1RpkRUjd/bZmTayMZ+Rrekz5PTW9gURkbdUUZEVKWNGgd0wbNfE07vgF+FTmia4rR45O0qlOX0KrG9qAifCGFwPTjyLYd2x1pdAGwySlwbEEERjAzVOECTuD8IgpkFC2BEn1l04wx47Q9jC7tkDw7nwf2Vp/4lhR2l1hx9e2Y7SBp5zOp2H/304nbZdle/R/vz01wMHRj9ELBu97OP3/xFgAEAgj7rRci3dAAAAAElFTkSuQmCC"); } if (postData.Entity.ExteriorAfterImgURL2 != "../Images/mcd_logo.png") { pdfData.Add("ExteriorAfterImgURL2", HtmlConversionUtility.ImageToBase64(postData.Entity.ExteriorAfterImgURL2, System.Drawing.Imaging.ImageFormat.Png)); } else { pdfData.Add("ExteriorAfterImgURL2", "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADYAAAAzCAMAAADrVgtcAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMy1jMDExIDY2LjE0NTY2MSwgMjAxMi8wMi8wNi0xNDo1NjoyNyAgICAgICAgIj4gPHJk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RuMaPBbBLEgGkQDInAQc3Z+F2wsyd6kUKkUKiRiL6xQ4B9RqYoqFApVyfybRVFRTRF7D2rCmSo55t7WbyIqIiqaR8bWn89+Z1Nl5bTcog/OR+Xn3owpik1p/ysKsXVlNtWQr+62b4+7F8eIys5Nmfx67qAF7WNi8p+Ny4i8U5kfc3zQzhdgOCybTXF36hvJk+9Pvc+YX5KxYuB3x2MZGePGPJ6fvGJb8y1GCSOlWQW3dsP6rGrO3t44qHFV2kexq1b/9Gby8adHZcTl3onb1Hxr+zjG6nMaLHxLbMjex1RpkRUjd/bZmTayMZ+Rrekz5PTW9gURkbdUUZEVKWNGgd0wbNfE07vgF+FTmia4rR45O0qlOX0KrG9qAifCGFwPTjyLYd2x1pdAGwySlwbEEERjAzVOECTuD8IgpkFC2BEn1l04wx47Q9jC7tkDw7nwf2Vp/4lhR2l1hx9e2Y7SBp5zOp2H/304nbZdle/R/vz01wMHRj9ELBu97OP3/xFgAEAgj7rRci3dAAAAAElFTkSuQmCC"); } if (postData.Entity.InteriorAfterImgURL1 != "../Images/mcd_logo.png") { pdfData.Add("InteriorAfterImgURL1", HtmlConversionUtility.ImageToBase64(postData.Entity.InteriorAfterImgURL1, System.Drawing.Imaging.ImageFormat.Png)); } else { pdfData.Add("InteriorAfterImgURL1", "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADYAAAAzCAMAAADrVgtcAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMy1jMDExIDY2LjE0NTY2MSwgMjAxMi8wMi8wNi0xNDo1NjoyNyAgICAgICAgIj4gPHJkZjpSREYg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BLEgGkQDInAQc3Z+F2wsyd6kUKkUKiRiL6xQ4B9RqYoqFApVyfybRVFRTRF7D2rCmSo55t7WbyIqIiqaR8bWn89+Z1Nl5bTcog/OR+Xn3owpik1p/ysKsXVlNtWQr+62b4+7F8eIys5Nmfx67qAF7WNi8p+Ny4i8U5kfc3zQzhdgOCybTXF36hvJk+9Pvc+YX5KxYuB3x2MZGePGPJ6fvGJb8y1GCSOlWQW3dsP6rGrO3t44qHFV2kexq1b/9Gby8adHZcTl3onb1Hxr+zjG6nMaLHxLbMjex1RpkRUjd/bZmTayMZ+Rrekz5PTW9gURkbdUUZEVKWNGgd0wbNfE07vgF+FTmia4rR45O0qlOX0KrG9qAifCGFwPTjyLYd2x1pdAGwySlwbEEERjAzVOECTuD8IgpkFC2BEn1l04wx47Q9jC7tkDw7nwf2Vp/4lhR2l1hx9e2Y7SBp5zOp2H/304nbZdle/R/vz01wMHRj9ELBu97OP3/xFgAEAgj7rRci3dAAAAAElFTkSuQmCC"); } if (postData.Entity.InteriorAfterImgURL2 != "../Images/mcd_logo.png") { pdfData.Add("InteriorAfterImgURL2", HtmlConversionUtility.ImageToBase64(postData.Entity.InteriorAfterImgURL2, System.Drawing.Imaging.ImageFormat.Png)); } else { pdfData.Add("InteriorAfterImgURL2", "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADYAAAAzCAMAAADrVgtcAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMy1jMDExIDY2LjE0NTY2MSwgMjAxMi8wMi8wNi0xNDo1NjoyNyAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM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DInAQc3Z+F2wsyd6kUKkUKiRiL6xQ4B9RqYoqFApVyfybRVFRTRF7D2rCmSo55t7WbyIqIiqaR8bWn89+Z1Nl5bTcog/OR+Xn3owpik1p/ysKsXVlNtWQr+62b4+7F8eIys5Nmfx67qAF7WNi8p+Ny4i8U5kfc3zQzhdgOCybTXF36hvJk+9Pvc+YX5KxYuB3x2MZGePGPJ6fvGJb8y1GCSOlWQW3dsP6rGrO3t44qHFV2kexq1b/9Gby8adHZcTl3onb1Hxr+zjG6nMaLHxLbMjex1RpkRUjd/bZmTayMZ+Rrekz5PTW9gURkbdUUZEVKWNGgd0wbNfE07vgF+FTmia4rR45O0qlOX0KrG9qAifCGFwPTjyLYd2x1pdAGwySlwbEEERjAzVOECTuD8IgpkFC2BEn1l04wx47Q9jC7tkDw7nwf2Vp/4lhR2l1hx9e2Y7SBp5zOp2H/304nbZdle/R/vz01wMHRj9ELBu97OP3/xFgAEAgj7rRci3dAAAAAElFTkSuQmCC"); } string pdfPath = HtmlConversionUtility.HtmlConvertToPDF(HtmlTempalteType.ReopenMemo, pdfData, null); EmailSendingResultType result; //邮件模板中的数据 Dictionary <string, string> bodyValues = new Dictionary <string, string>(); //邮件内容中的键值对 bodyValues.Add("ApplicantName", ClientCookie.UserNameENUS);//--提交人 bodyValues.Add("StoreCode", postData.Entity.Store.StoreBasicInfo.StoreCode); bodyValues.Add("StoreName", postData.Entity.Store.StoreBasicInfo.NameENUS); bodyValues.Add("Actor", actor.RoleNameENUS);////--呈递人 if (postData.Entity.ProjectId.ToLower().IndexOf("rebuild") >= 0) { bodyValues.Add("WorkflowName", Constants.Rebuild_ReopenMemo); ////--流程名称 bodyValues.Add("ProjectName", Constants.Rebuild); //项目名称 } else if (postData.Entity.ProjectId.ToLower().IndexOf("reimage") >= 0) { bodyValues.Add("WorkflowName", Constants.Reimage_ReopenMemo); ////--流程名称 bodyValues.Add("ProjectName", Constants.Reimage); //项目名称 } else if (postData.Entity.ProjectId.ToLower().IndexOf("tempclosure") >= 0) { bodyValues.Add("WorkflowName", Constants.TempClosure_ReopenMemo); ////--流程名称 bodyValues.Add("ProjectName", Constants.TempClosure); //项目名称 } else if (postData.Entity.ProjectId.ToLower().IndexOf("majorlease") >= 0) { bodyValues.Add("WorkflowName", Constants.MajorLease_ReopenMemo); ////--流程名称 bodyValues.Add("ProjectName", Constants.MajorLease); //项目名称 } else if (postData.Entity.ProjectId.ToLower().IndexOf("renewal") >= 0) { bodyValues.Add("WorkflowName", Constants.Renewal_ReopenMemo); ////--流程名称 bodyValues.Add("ProjectName", Constants.Renewal); //项目名称 } else { bodyValues.Add("WorkflowName", Constants.TempClosure_ReopenMemo); ////--流程名称 bodyValues.Add("ProjectName", Constants.TempClosure); //项目名称 } string viewPage = ""; if (postData.Entity.ProjectId.ToLower().IndexOf("rebuild") >= 0) { viewPage = string.Format("{0}/Rebuild/Main#/ReopenMemo/Process/View?projectId={1}", ConfigurationManager.AppSettings["webHost"], postData.Entity.ProjectId); } if (postData.Entity.ProjectId.ToLower().IndexOf("reimage") >= 0) { viewPage = string.Format("{0}/Reimage/Main#/ReopenMemo/Process/View?projectId={1}", ConfigurationManager.AppSettings["webHost"], postData.Entity.ProjectId); } bodyValues.Add("FormUrl", viewPage); //调用邮件服务发送邮件 using (EmailServiceClient client = new EmailServiceClient()) { EmailMessage message = new EmailMessage(); StringBuilder sbTo = new StringBuilder(); Dictionary <string, string> attachments = new Dictionary <string, string>(); foreach (Employee emp in postData.Receivers) { if (sbTo.Length > 0) { sbTo.Append(";"); } if (!string.IsNullOrEmpty(emp.Mail)) { sbTo.Append(emp.Mail); } } if (sbTo.Length > 0) { sbTo.Append(";"); } message.EmailBodyValues = bodyValues; string strTitle = ""; if (postData.Entity.ProjectId.ToLower().IndexOf("rebuild") >= 0) { strTitle = "Rebuild_ReopenMemo"; } if (postData.Entity.ProjectId.ToLower().IndexOf("reimage") >= 0) { strTitle = "Reimage_ReopenMemo"; } if (postData.Entity.ProjectId.ToLower().IndexOf("majorlease") >= 0) { strTitle = "MajorLease_ReopenMemo"; } if (postData.Entity.ProjectId.ToLower().IndexOf("renewal") >= 0) { strTitle = "Renewal_ReopenMemo"; } if (postData.Entity.ProjectId.ToLower().IndexOf("tempclosure") >= 0) { strTitle = "TempClosure_ReopenMemo"; } attachments.Add(pdfPath, strTitle + "_" + postData.Entity.ProjectId + ".pdf"); message.AttachmentsDict = attachments; message.To = sbTo.ToString(); message.TemplateCode = EmailTemplateCode.GBMemoNotification; result = client.SendNotificationEmail(message); } if (!result.Successful) { return(BadRequest(result.ErrorMessage + " " + pdfPath)); } ReopenMemo.Submit(postData.Entity); tranScope.Complete(); } return(Ok()); }