Procházet zdrojové kódy

Feature / Add image in header on every page (iTextSharp)

Feature
Safet Purkovic před 4 roky
rodič
revize
d1161d05bb

+ 1
- 0
BlackRock.Reporting.API/BlackRock.Reporting.API.csproj Zobrazit soubor

@@ -40,6 +40,7 @@
<ItemGroup>
<PackageReference Include="AutoMapper" Version="10.1.1" />
<PackageReference Include="AutoMapper.Extensions.Microsoft.DependencyInjection" Version="8.1.1" />
<PackageReference Include="itextsharp" Version="5.5.13.2" />
<PackageReference Include="PuppeteerSharp" Version="5.1.0" />
<PackageReference Include="Swashbuckle.AspNetCore" Version="6.1.5" />
</ItemGroup>

+ 180
- 4
BlackRock.Reporting.API/Controllers/PDFGeneratorController.cs Zobrazit soubor

@@ -4,6 +4,8 @@ using BlackRock.Reporting.API.Core;
using BlackRock.Reporting.API.Core.Models;
using Microsoft.AspNetCore.Mvc;
using PuppeteerSharp;
using iTextSharp.text;
using iTextSharp.text.pdf;

namespace BlackRock.Reporting.API.Controllers
{
@@ -22,7 +24,7 @@ namespace BlackRock.Reporting.API.Controllers
}

[HttpGet("{url}")]
public async Task<IActionResult> Get([FromQuery] OptionsForPdf pdfOptions,string url = "http://localhost:3000/#/dashboard")
public async Task<IActionResult> Get([FromQuery] OptionsForPdf pdfOptions, string url = "http://localhost:3000/#/dashboard")
{
if (string.IsNullOrEmpty(url))
return BadRequest();
@@ -33,14 +35,29 @@ namespace BlackRock.Reporting.API.Controllers
// Path to wwwroot folder combined with name of pdf file
string path = Path.Combine(host.ContentRootPath, $"wwwroot/pdfs/{fileName}");

var options = mapper.Map<OptionsForPdf,PdfOptions>(pdfOptions);
var options = mapper.Map<OptionsForPdf, PdfOptions>(pdfOptions);

await generator.Generate(result, path, options);

// Document document = new Document(PageSize.A4, 36, 36, 36 + 100, 36); // note height should be set here
// MyEvent e = new MyEvent(host);
// PdfWriter pw = PdfWriter.GetInstance(document, new FileStream(Path.Combine(host.ContentRootPath, "logtest.pdf"), FileMode.Create));
// pw.PageEvent = e;
// document.Open();

// for (int i = 0; i < 100; i++)
// {
// document.Add(new Phrase("TESTING\n"));
// }

// document.Close();

ModifyPDF(path);
FileStream stream = new FileStream(path, FileMode.Open);
return File(stream, "application/pdf", fileName);
}
[HttpGet("isolate/{url}")]
public async Task<IActionResult> GetIsolated([FromQuery] OptionsForPdf pdfOptions,string url = "http://localhost:3000/#/dashboard")
public async Task<IActionResult> GetIsolated([FromQuery] OptionsForPdf pdfOptions, string url = "http://localhost:3000/#/dashboard")
{
if (string.IsNullOrEmpty(url))
return BadRequest();
@@ -51,11 +68,170 @@ namespace BlackRock.Reporting.API.Controllers
// Path to wwwroot folder combined with name of pdf file
string path = Path.Combine(host.ContentRootPath, $"wwwroot/pdfs/{fileName}");

var options = mapper.Map<OptionsForPdf,PdfOptions>(pdfOptions);
var options = mapper.Map<OptionsForPdf, PdfOptions>(pdfOptions);

await generator.Isolate(result, path, options);
FileStream stream = new FileStream(path, FileMode.Open);
return File(stream, "application/pdf", fileName);
}

private void Nesto()
{
//string oldFile = Path.Combine(host.ContentRootPath, "0bd7e2f4-b01e-4c17-8f1e-99562d2bab4a.pdf");
string oldFile = Path.Combine(host.ContentRootPath, "oldFile.pdf");
string newFile = Path.Combine(host.ContentRootPath, "newFilxex.pdf");

// open the reader
PdfReader reader = new PdfReader(oldFile);
Rectangle size = reader.GetPageSizeWithRotation(1);
Document document = new Document(size);

AcroFields form = reader.AcroFields;
try
{
for (int pagew = 1; pagew <= reader.NumberOfPages; pagew++)
{

}
}
catch { }

// open the writer
FileStream fs = new FileStream(newFile, FileMode.Create, FileAccess.Write);
PdfWriter writer = PdfWriter.GetInstance(document, fs);
document.Open();

// the pdf content
PdfContentByte cb = writer.DirectContent;

// select the font properties
BaseFont bf = BaseFont.CreateFont(BaseFont.HELVETICA, BaseFont.CP1252, BaseFont.NOT_EMBEDDED);
cb.SetColorFill(BaseColor.DARK_GRAY);
cb.SetFontAndSize(bf, 8);

// write the text in the pdf content
cb.BeginText();
string text = "Some random blablablabla...";
// put the alignment and coordinates here
cb.ShowTextAligned(1, text, 520, 640, 0);
cb.EndText();
cb.BeginText();
text = "Other random blabla...";
// put the alignment and coordinates here
cb.ShowTextAligned(2, text, 100, 200, 0);
cb.EndText();

// create the new page and add it to the pdf
PdfImportedPage page = writer.GetImportedPage(reader, 1);
var pages = reader.GetPageN(1);
var content = writer.DirectContent;
var template = content.CreateTemplate(100, 100);
float width = 100, height = 100;
// PdfDictionary
// pages.CreateTemplate(writer,100,100);
// cb.AddTemplate(page, 0, 0);
// cb.AddTemplate()
// Document document = new Document(PageSize.A4, 36, 36, 36 + 100, 36); // note height should be set here
MyEvent e = new MyEvent(host);
//PdfWriter pw = PdfWriter.GetInstance(document, new FileStream(Path.Combine(host.ContentRootPath, "logtest.pdf"), FileMode.Create));
writer.PageEvent = e;
document.Open();

// for (int i = 0; i < 100; i++)
// {
// document.Add(new Phrase("TESTING\n"));
// }

//document.Close();
// close the streams and voilá the file should be changed :)
document.Close();
fs.Close();
writer.Close();
reader.Close();
}

private void ModifyPDF(string path)
{
var filePath = path;
byte[] bytes = System.IO.File.ReadAllBytes(filePath);
var pdfReader = new PdfReader(bytes);
using (Stream output = new FileStream(filePath, FileMode.Create, FileAccess.Write, FileShare.None))
{
using (PdfStamper pdfStamper = new PdfStamper(pdfReader, output))
{
for (int pageIndex = 1; pageIndex <= pdfReader.NumberOfPages; pageIndex++)
{
pdfStamper.FormFlattening = false;
Rectangle pageRectangle = pdfReader.GetPageSizeWithRotation(pageIndex);
PdfContentByte pdfData = pdfStamper.GetOverContent(pageIndex);
pdfData.SetFontAndSize(BaseFont.CreateFont(BaseFont.HELVETICA_BOLD, BaseFont.CP1252, BaseFont.NOT_EMBEDDED), 10);
PdfGState graphicsState = new PdfGState
{
FillOpacity = 0.3F
};
pdfData.SetGState(graphicsState);
Image image = Image.GetInstance(Path.Combine(host.ContentRootPath, "logo.png"));
image.SetAbsolutePosition(pageRectangle.Width/2-image.Width/2,pageRectangle.Height-image.Height-5);
pdfData.AddImage(image);
// pdfData.BeginText();

// // select the font properties
// BaseFont bf = BaseFont.CreateFont(BaseFont.HELVETICA, BaseFont.CP1252, BaseFont.NOT_EMBEDDED);
// pdfData.SetColorFill(BaseColor.BLACK);
// pdfData.SetFontAndSize(bf, 8);

// write the text in the pdf content
// pdfData.BeginText();
// string text = "Faisal Pathan";
// // put the alignment and coordinates here
// pdfData.ShowTextAligned(1, text, 70, 775, 0);
// pdfData.EndText();

// pdfData.BeginText();
// string text1 = "faisalmpathan@gmail.com";
// pdfData.ShowTextAligned(1, text1, 550, 775, 0);
// pdfData.ShowTextAligned(0,"logo",pageRectangle.Width/2,pageRectangle.Height-15,0);
// pdfData.EndText();

}
}
output.Close();
output.Dispose();
}
}
}
public partial class MyEvent : PdfPageEventHelper
{
public MyEvent(IHostEnvironment host)
{
this.host = host;
}
iTextSharp.text.Image image1;
PdfPTable header = new PdfPTable(3);
private readonly IHostEnvironment host;

public override void OnOpenDocument(PdfWriter writer, Document document)
{
image1 = Image.GetInstance(Path.Combine(host.ContentRootPath, "logo.png"));

image1.SetAbsolutePosition(20, (document.PageSize.Height - 120));

//header.WriteSelectedRows(0, -1, document.Left, document.Top, writer.DirectContent);

}

public override void OnEndPage(PdfWriter writer, Document document)
{


PdfPTable tbHeader = new PdfPTable(1);

tbHeader.AddCell(image1);
//tbHeader.TotalWidth = image1.Width;
// tbHeader.WriteSelectedRows(0, -1, 10, document.PageSize.Height - 15, writer.DirectContent);
tbHeader.WriteSelectedRows(0, -1, document.PageSize.Width / 2 - image1.Width / 2, document.PageSize.Height - 15, writer.DirectContent);
}
}
}

+ 0
- 1
BlackRock.Reporting.API/Core/Models/OptionsForPdf.cs Zobrazit soubor

@@ -30,7 +30,6 @@ namespace BlackRock.Reporting.API.Core.Models
/// <c>totalPages</c> - total pages in the document
/// </summary>
public string HeaderTemplate { get; set; } = string.Empty;

/// <summary>
/// HTML template for the print footer. Should be valid HTML markup with following classes used to inject printing values into them:
/// <c>date</c> - formatted print date

+ 116
- 4
BlackRock.Reporting.API/Persistence/PdfGenerator.cs Zobrazit soubor

@@ -1,16 +1,21 @@
using System.Data.Common;
using BlackRock.Reporting.API.Core;
using BlackRock.Reporting.API.Core.Models;
using iTextSharp.text;
using iTextSharp.text.pdf;
using PuppeteerSharp;
using iTextSharp;
using iTextSharp.text.xml;

namespace BlackRock.Reporting.API.Persistence
{
public class PdfGenerator : IPdfGenerator
{
private readonly IHostEnvironment host;
public PdfGenerator(IHostEnvironment host)
{
this.host = host;

}
public async Task Generate(string url, string path, PdfOptions options)
{
@@ -28,14 +33,19 @@ namespace BlackRock.Reporting.API.Persistence
var allResultsSelector = ".chartjs-render-monitor";
await page.WaitForSelectorAsync(allResultsSelector);
await EvaluateScript(page, "dist/main.js");
await page.PdfAsync(path,options
await page.PdfAsync(path, options
// new PdfOptions{
// Landscape = true,
// PrintBackground = true,
// Format = PuppeteerSharp.Media.PaperFormat.Letter
// }
);

}
// POST header image

// ModifyPdf(path);
}

public async Task Isolate(string url, string path, PdfOptions options)
@@ -53,8 +63,9 @@ namespace BlackRock.Reporting.API.Persistence

var allResultsSelector = ".chartjs-render-monitor";
await page.WaitForSelectorAsync(allResultsSelector);
await EvaluateScript(page, "dist/main.js");
await EvaluateScript(page, "dist/main2.js");
await page.PdfAsync(path,options
await page.PdfAsync(path, options
// new PdfOptions{
// PrintBackground = true,
// Format = PuppeteerSharp.Media.PaperFormat.Letter
@@ -70,5 +81,106 @@ namespace BlackRock.Reporting.API.Persistence
var result = await System.IO.File.ReadAllTextAsync(path2);
await page.EvaluateExpressionAsync(result);
}
private void AddAnImage()
{
using (var inputPdfStream = new FileStream(Path.Combine(host.ContentRootPath, "newFile.pdf"), FileMode.Open))
using (var inputImageStream = new FileStream(Path.Combine(host.ContentRootPath, "pic.jpg"), FileMode.Open))
using (var outputPdfStream = new FileStream(Path.Combine(host.ContentRootPath, "newFilesesses.pdf"), FileMode.Create))
{
PdfReader reader = new PdfReader(inputPdfStream);
PdfStamper stamper = new PdfStamper(reader, outputPdfStream);
PdfContentByte pdfContentByte = stamper.GetOverContent(1);
var image = iTextSharp.text.Image.GetInstance(inputImageStream);
image.ScaleAbsolute(40, 40);
image.SetAbsolutePosition(0, 0);
pdfContentByte.AddImage(image);
stamper.Close();
}
}
private void ModifyPdf(string oldFile)
{
string formFile = Path.Combine(host.ContentRootPath, "newFile.pdf");
string newFile = Path.Combine(host.ContentRootPath, "newFiles.pdf");
// string newFile = Path.Combine(host.ContentRootPath,"newFile.pdf");
PdfReader reader = new PdfReader(formFile);
using (PdfStamper stamper = new PdfStamper(reader, new FileStream(newFile, FileMode.Create)))
{
AcroFields fields = stamper.AcroFields;

// set form fields
fields.SetField("name", "John Doe");
fields.SetField("address", "xxxxx, yyyy");
fields.SetField("postal_code", "12345");
fields.SetField("email", "johndoe@xxx.com");

// flatten form fields and close document
stamper.FormFlattening = true;
stamper.Close();
}
}

private void Nesto()
{
//string oldFile = Path.Combine(host.ContentRootPath, "0bd7e2f4-b01e-4c17-8f1e-99562d2bab4a.pdf");
string oldFile = "oldFile.pdf";
string newFile = Path.Combine(host.ContentRootPath, "newFile.pdf");

// open the reader
PdfReader reader = new PdfReader(oldFile);
Rectangle size = reader.GetPageSizeWithRotation(1);
Document document = new Document(size);

AcroFields form = reader.AcroFields;
try
{
for (int pagew = 1; pagew <= reader.NumberOfPages; pagew++)
{

}
}
catch { }

// open the writer
FileStream fs = new FileStream(newFile, FileMode.Create, FileAccess.Write);
PdfWriter writer = PdfWriter.GetInstance(document, fs);
document.Open();

// the pdf content
PdfContentByte cb = writer.DirectContent;

// select the font properties
BaseFont bf = BaseFont.CreateFont(BaseFont.HELVETICA, BaseFont.CP1252, BaseFont.NOT_EMBEDDED);
cb.SetColorFill(BaseColor.DARK_GRAY);
cb.SetFontAndSize(bf, 8);

// write the text in the pdf content
cb.BeginText();
string text = "Some random blablablabla...";
// put the alignment and coordinates here
cb.ShowTextAligned(1, text, 520, 640, 0);
cb.EndText();
cb.BeginText();
text = "Other random blabla...";
// put the alignment and coordinates here
cb.ShowTextAligned(2, text, 100, 200, 0);
cb.EndText();

// create the new page and add it to the pdf
PdfImportedPage page = writer.GetImportedPage(reader, 1);
var pages = reader.GetPageN(1);
var content = writer.DirectContent;
var template = content.CreateTemplate(100, 100);
float width = 100, height = 100;
// PdfDictionary
// pages.CreateTemplate(writer,100,100);
// cb.AddTemplate(page, 0, 0);
// cb.AddTemplate()

// close the streams and voilá the file should be changed :)
document.Close();
fs.Close();
writer.Close();
reader.Close();
}
}
}
}

+ 1
- 1
BlackRock.Reporting.API/dist/main.js
Diff nebyl zobrazen, protože je příliš veliký
Zobrazit soubor


binární
BlackRock.Reporting.API/logo.png Zobrazit soubor


+ 9
- 5
BlackRock.Reporting.API/obj/BlackRock.Reporting.API.csproj.nuget.dgspec.json Zobrazit soubor

@@ -1,17 +1,17 @@
{
"format": 1,
"restore": {
"C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\blackrock.reporting.api\\BlackRock.Reporting.API.csproj": {}
"C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\BlackRock.Reporting.API\\BlackRock.Reporting.API.csproj": {}
},
"projects": {
"C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\blackrock.reporting.api\\BlackRock.Reporting.API.csproj": {
"C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\BlackRock.Reporting.API\\BlackRock.Reporting.API.csproj": {
"version": "1.0.0",
"restore": {
"projectUniqueName": "C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\blackrock.reporting.api\\BlackRock.Reporting.API.csproj",
"projectUniqueName": "C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\BlackRock.Reporting.API\\BlackRock.Reporting.API.csproj",
"projectName": "BlackRock.Reporting.API",
"projectPath": "C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\blackrock.reporting.api\\BlackRock.Reporting.API.csproj",
"projectPath": "C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\BlackRock.Reporting.API\\BlackRock.Reporting.API.csproj",
"packagesPath": "C:\\Users\\safet.purkovic\\.nuget\\packages\\",
"outputPath": "C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\blackrock.reporting.api\\obj\\",
"outputPath": "C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\BlackRock.Reporting.API\\obj\\",
"projectStyle": "PackageReference",
"configFilePaths": [
"C:\\Users\\safet.purkovic\\AppData\\Roaming\\NuGet\\NuGet.Config",
@@ -55,6 +55,10 @@
"Swashbuckle.AspNetCore": {
"target": "Package",
"version": "[6.1.5, )"
},
"itextsharp": {
"target": "Package",
"version": "[5.5.13.2, )"
}
},
"imports": [

+ 82
- 5
BlackRock.Reporting.API/obj/project.assets.json Zobrazit soubor

@@ -29,6 +29,27 @@
"lib/netstandard2.0/AutoMapper.Extensions.Microsoft.DependencyInjection.dll": {}
}
},
"BouncyCastle/1.8.6.1": {
"type": "package",
"compile": {
"lib/BouncyCastle.Crypto.dll": {}
},
"runtime": {
"lib/BouncyCastle.Crypto.dll": {}
}
},
"iTextSharp/5.5.13.2": {
"type": "package",
"dependencies": {
"BouncyCastle": "1.8.6.1"
},
"compile": {
"lib/itextsharp.dll": {}
},
"runtime": {
"lib/itextsharp.dll": {}
}
},
"Microsoft.AspNetCore.WebUtilities/2.0.2": {
"type": "package",
"dependencies": {
@@ -1589,6 +1610,35 @@
"lib/netstandard2.0/AutoMapper.Extensions.Microsoft.DependencyInjection.dll"
]
},
"BouncyCastle/1.8.6.1": {
"sha512": "rkqpuKmJkdcfTMBkIj1b5nMdBAWKwAyh+I/BQYeqqSD2jkIlhwc9qBNKmSbnpmmm5c29qHZGLpvBSTNWvDLtQA==",
"type": "package",
"path": "bouncycastle/1.8.6.1",
"files": [
".nupkg.metadata",
".signature.p7s",
"README.md",
"bouncycastle.1.8.6.1.nupkg.sha512",
"bouncycastle.nuspec",
"lib/BouncyCastle.Crypto.dll"
]
},
"iTextSharp/5.5.13.2": {
"sha512": "8m9oT1nh9F4Z1tzWUey/8lEzZtMGFCDXQY5+8/SSmPgUWAAAWniRo8pimKUZyteNqJr5vtFBxjAhRwLxG7Q0zQ==",
"type": "package",
"path": "itextsharp/5.5.13.2",
"files": [
".nupkg.metadata",
".signature.p7s",
"LICENSE.md",
"gnu-agpl-v3.0.md",
"itextsharp.5.5.13.2.nupkg.sha512",
"itextsharp.nuspec",
"lib/iTextSharp.xml",
"lib/itextsharp.dll",
"notice.txt"
]
},
"Microsoft.AspNetCore.WebUtilities/2.0.2": {
"sha512": "dvn80+p1AIQKOfJ+VrOhVMUktWRvJs7Zb+UapZGBNSyrCzTsYiXbb9C7Mzw+nGj5UevnLNFcWWc7BUlLMD2qpw==",
"type": "package",
@@ -5624,7 +5674,8 @@
"AutoMapper >= 10.1.1",
"AutoMapper.Extensions.Microsoft.DependencyInjection >= 8.1.1",
"PuppeteerSharp >= 5.1.0",
"Swashbuckle.AspNetCore >= 6.1.5"
"Swashbuckle.AspNetCore >= 6.1.5",
"itextsharp >= 5.5.13.2"
]
},
"packageFolders": {
@@ -5633,11 +5684,11 @@
"project": {
"version": "1.0.0",
"restore": {
"projectUniqueName": "C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\blackrock.reporting.api\\BlackRock.Reporting.API.csproj",
"projectUniqueName": "C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\BlackRock.Reporting.API\\BlackRock.Reporting.API.csproj",
"projectName": "BlackRock.Reporting.API",
"projectPath": "C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\blackrock.reporting.api\\BlackRock.Reporting.API.csproj",
"projectPath": "C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\BlackRock.Reporting.API\\BlackRock.Reporting.API.csproj",
"packagesPath": "C:\\Users\\safet.purkovic\\.nuget\\packages\\",
"outputPath": "C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\blackrock.reporting.api\\obj\\",
"outputPath": "C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\BlackRock.Reporting.API\\obj\\",
"projectStyle": "PackageReference",
"configFilePaths": [
"C:\\Users\\safet.purkovic\\AppData\\Roaming\\NuGet\\NuGet.Config",
@@ -5681,6 +5732,10 @@
"Swashbuckle.AspNetCore": {
"target": "Package",
"version": "[6.1.5, )"
},
"itextsharp": {
"target": "Package",
"version": "[5.5.13.2, )"
}
},
"imports": [
@@ -5704,5 +5759,27 @@
"runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\6.0.100-rc.1.21463.6\\RuntimeIdentifierGraph.json"
}
}
}
},
"logs": [
{
"code": "NU1701",
"level": "Warning",
"warningLevel": 1,
"message": "Package 'BouncyCastle 1.8.6.1' was restored using '.NETFramework,Version=v4.6.1, .NETFramework,Version=v4.6.2, .NETFramework,Version=v4.7, .NETFramework,Version=v4.7.1, .NETFramework,Version=v4.7.2, .NETFramework,Version=v4.8' instead of the project target framework 'net6.0'. This package may not be fully compatible with your project.",
"libraryId": "BouncyCastle",
"targetGraphs": [
"net6.0"
]
},
{
"code": "NU1701",
"level": "Warning",
"warningLevel": 1,
"message": "Package 'iTextSharp 5.5.13.2' was restored using '.NETFramework,Version=v4.6.1, .NETFramework,Version=v4.6.2, .NETFramework,Version=v4.7, .NETFramework,Version=v4.7.1, .NETFramework,Version=v4.7.2, .NETFramework,Version=v4.8' instead of the project target framework 'net6.0'. This package may not be fully compatible with your project.",
"libraryId": "iTextSharp",
"targetGraphs": [
"net6.0"
]
}
]
}

+ 26
- 3
BlackRock.Reporting.API/obj/project.nuget.cache Zobrazit soubor

@@ -1,11 +1,13 @@
{
"version": 2,
"dgSpecHash": "u5LCzMsSc98tqejgvIS7vh2sBsOKVmvwB91LkGNhpRK/OTJT4TBibJo14VN9KPzUL1djIsrbKAcg0IlFWE3yWg==",
"dgSpecHash": "uGRigRRvQQLqSi6P2KFT/1jzW6nyAKXVgIvhCGPyaVuLKGbYTr++UywDDIosCl0aFO+8/kqLPzMQjvPA8lf+ug==",
"success": true,
"projectFilePath": "C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\blackrock.reporting.api\\BlackRock.Reporting.API.csproj",
"projectFilePath": "C:\\Users\\safet.purkovic\\Desktop\\PDFEngineAPI\\BlackRock.Reporting.API\\BlackRock.Reporting.API.csproj",
"expectedPackageFiles": [
"C:\\Users\\safet.purkovic\\.nuget\\packages\\automapper\\10.1.1\\automapper.10.1.1.nupkg.sha512",
"C:\\Users\\safet.purkovic\\.nuget\\packages\\automapper.extensions.microsoft.dependencyinjection\\8.1.1\\automapper.extensions.microsoft.dependencyinjection.8.1.1.nupkg.sha512",
"C:\\Users\\safet.purkovic\\.nuget\\packages\\bouncycastle\\1.8.6.1\\bouncycastle.1.8.6.1.nupkg.sha512",
"C:\\Users\\safet.purkovic\\.nuget\\packages\\itextsharp\\5.5.13.2\\itextsharp.5.5.13.2.nupkg.sha512",
"C:\\Users\\safet.purkovic\\.nuget\\packages\\microsoft.aspnetcore.webutilities\\2.0.2\\microsoft.aspnetcore.webutilities.2.0.2.nupkg.sha512",
"C:\\Users\\safet.purkovic\\.nuget\\packages\\microsoft.bcl.asyncinterfaces\\1.1.0\\microsoft.bcl.asyncinterfaces.1.1.0.nupkg.sha512",
"C:\\Users\\safet.purkovic\\.nuget\\packages\\microsoft.csharp\\4.7.0\\microsoft.csharp.4.7.0.nupkg.sha512",
@@ -107,5 +109,26 @@
"C:\\Users\\safet.purkovic\\.nuget\\packages\\system.xml.xdocument\\4.3.0\\system.xml.xdocument.4.3.0.nupkg.sha512",
"C:\\Users\\safet.purkovic\\.nuget\\packages\\system.xml.xmldocument\\4.3.0\\system.xml.xmldocument.4.3.0.nupkg.sha512"
],
"logs": []
"logs": [
{
"code": "NU1701",
"level": "Warning",
"warningLevel": 1,
"message": "Package 'BouncyCastle 1.8.6.1' was restored using '.NETFramework,Version=v4.6.1, .NETFramework,Version=v4.6.2, .NETFramework,Version=v4.7, .NETFramework,Version=v4.7.1, .NETFramework,Version=v4.7.2, .NETFramework,Version=v4.8' instead of the project target framework 'net6.0'. This package may not be fully compatible with your project.",
"libraryId": "BouncyCastle",
"targetGraphs": [
"net6.0"
]
},
{
"code": "NU1701",
"level": "Warning",
"warningLevel": 1,
"message": "Package 'iTextSharp 5.5.13.2' was restored using '.NETFramework,Version=v4.6.1, .NETFramework,Version=v4.6.2, .NETFramework,Version=v4.7, .NETFramework,Version=v4.7.1, .NETFramework,Version=v4.7.2, .NETFramework,Version=v4.8' instead of the project target framework 'net6.0'. This package may not be fully compatible with your project.",
"libraryId": "iTextSharp",
"targetGraphs": [
"net6.0"
]
}
]
}

Načítá se…
Zrušit
Uložit