修改安全实施计划导出

This commit is contained in:
高飞 2023-07-17 15:58:09 +08:00
parent 58bf6f96d8
commit fa5ccc8f15
2 changed files with 44 additions and 8 deletions

View File

@ -647,8 +647,17 @@ namespace FineUIPro.Web.HSSE.ActionPlan
builder.Font.Bold = false;
if (item.ApproveDate != null)
{
string personName = Person_PersonsService.GetPersonsNameById(item.ApproveMan);
builder.Write(personName + " " + item.ApproveDate.ToString().Split(' ')[0]);
var getUser = Person_PersonsService.GetPerson_PersonsById(item.ApproveMan);
if (!string.IsNullOrEmpty(getUser.SignatureUrl) && File.Exists(rootPath + getUser.SignatureUrl))
{
var file = rootPath + getUser.SignatureUrl;
builder.InsertImage(file, 80, 20);
builder.Write(item.ApproveDate.ToString().Split(' ')[0]);
}
else
{
builder.Write(getUser.PersonName + " " + item.ApproveDate.ToString().Split(' ')[0]);
}
}
else
{
@ -699,8 +708,17 @@ namespace FineUIPro.Web.HSSE.ActionPlan
builder.Font.Bold = false;
if (item.ApproveDate != null)
{
string personName = Person_PersonsService.GetPersonsNameById(item.ApproveMan);
builder.Write(personName + " " + item.ApproveDate.ToString().Split(' ')[0]);
var getUser = Person_PersonsService.GetPerson_PersonsById(item.ApproveMan);
if (!string.IsNullOrEmpty(getUser.SignatureUrl) && File.Exists(rootPath + getUser.SignatureUrl))
{
var file = rootPath + getUser.SignatureUrl;
builder.InsertImage(file, 80, 20);
builder.Write(item.ApproveDate.ToString().Split(' ')[0]);
}
else
{
builder.Write(getUser.PersonName + " " + item.ApproveDate.ToString().Split(' ')[0]);
}
}
else
{

View File

@ -633,8 +633,17 @@ namespace FineUIPro.Web.ZHGL.Plan
builder.Font.Bold = false;
if (item.ApproveDate != null)
{
string personName = Person_PersonsService.GetPersonsNameById(item.ApproveMan);
builder.Write(personName + " " + item.ApproveDate.ToString().Split(' ')[0]);
var getUser = Person_PersonsService.GetPerson_PersonsById(item.ApproveMan);
if (!string.IsNullOrEmpty(getUser.SignatureUrl) && File.Exists(rootPath + getUser.SignatureUrl))
{
var file = rootPath + getUser.SignatureUrl;
builder.InsertImage(file, 80, 20);
builder.Write(item.ApproveDate.ToString().Split(' ')[0]);
}
else
{
builder.Write(getUser.PersonName + " " + item.ApproveDate.ToString().Split(' ')[0]);
}
}
else
{
@ -685,8 +694,17 @@ namespace FineUIPro.Web.ZHGL.Plan
builder.Font.Bold = false;
if (item.ApproveDate != null)
{
string personName = Person_PersonsService.GetPersonsNameById(item.ApproveMan);
builder.Write(personName + " " + item.ApproveDate.ToString().Split(' ')[0]);
var getUser = Person_PersonsService.GetPerson_PersonsById(item.ApproveMan);
if (!string.IsNullOrEmpty(getUser.SignatureUrl) && File.Exists(rootPath + getUser.SignatureUrl))
{
var file = rootPath + getUser.SignatureUrl;
builder.InsertImage(file, 80, 20);
builder.Write(item.ApproveDate.ToString().Split(' ')[0]);
}
else
{
builder.Write(getUser.PersonName + " " + item.ApproveDate.ToString().Split(' ')[0]);
}
}
else
{