Finish SZO

Create SZO everyday mailing
This commit is contained in:
Georgy Khatuncev 2020-11-19 16:30:38 +05:00
parent 00c55b8a63
commit e2fcfed44c
231 changed files with 7320 additions and 409 deletions

Binary file not shown.

@ -14,4 +14,8 @@
<PackageReference Include="System.Text.Encoding.CodePages" Version="4.7.1" /> <PackageReference Include="System.Text.Encoding.CodePages" Version="4.7.1" />
</ItemGroup> </ItemGroup>
<ItemGroup>
<ProjectReference Include="..\SupportClasses\SupportClasses.csproj" />
</ItemGroup>
</Project> </Project>

@ -0,0 +1,108 @@
{
"runtimeTarget": {
"name": ".NETStandard,Version=v2.0/",
"signature": ""
},
"compilationOptions": {},
"targets": {
".NETStandard,Version=v2.0": {},
".NETStandard,Version=v2.0/": {
"DataClients/1.0.0": {
"dependencies": {
"NETStandard.Library": "2.0.3",
"SharpZipLib": "1.2.0",
"SupportClasses": "1.0.0",
"System.Text.Encoding.CodePages": "4.7.1"
},
"runtime": {
"DataClients.dll": {}
}
},
"Microsoft.NETCore.Platforms/1.1.0": {},
"NETStandard.Library/2.0.3": {
"dependencies": {
"Microsoft.NETCore.Platforms": "1.1.0"
}
},
"SharpZipLib/1.2.0": {
"runtime": {
"lib/netstandard2.0/ICSharpCode.SharpZipLib.dll": {
"assemblyVersion": "1.2.0.246",
"fileVersion": "1.2.0.246"
}
}
},
"System.Runtime.CompilerServices.Unsafe/4.7.1": {
"runtime": {
"lib/netstandard2.0/System.Runtime.CompilerServices.Unsafe.dll": {
"assemblyVersion": "4.0.6.0",
"fileVersion": "4.700.20.12001"
}
}
},
"System.Text.Encoding.CodePages/4.7.1": {
"dependencies": {
"System.Runtime.CompilerServices.Unsafe": "4.7.1"
},
"runtime": {
"lib/netstandard2.0/System.Text.Encoding.CodePages.dll": {
"assemblyVersion": "4.1.3.0",
"fileVersion": "4.700.20.21406"
}
}
},
"SupportClasses/1.0.0": {
"runtime": {
"SupportClasses.dll": {}
}
}
}
},
"libraries": {
"DataClients/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"Microsoft.NETCore.Platforms/1.1.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-kz0PEW2lhqygehI/d6XsPCQzD7ff7gUJaVGPVETX611eadGsA3A877GdSlU0LRVMCTH/+P3o2iDTak+S08V2+A==",
"path": "microsoft.netcore.platforms/1.1.0",
"hashPath": "microsoft.netcore.platforms.1.1.0.nupkg.sha512"
},
"NETStandard.Library/2.0.3": {
"type": "package",
"serviceable": true,
"sha512": "sha512-st47PosZSHrjECdjeIzZQbzivYBJFv6P2nv4cj2ypdI204DO+vZ7l5raGMiX4eXMJ53RfOIg+/s4DHVZ54Nu2A==",
"path": "netstandard.library/2.0.3",
"hashPath": "netstandard.library.2.0.3.nupkg.sha512"
},
"SharpZipLib/1.2.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-zvWa/L02JHNatdtjya6Swpudb2YEHaOLHL1eRrqpjm71iGRNUNONO5adUF/9CHbSJbzhELW1UoH4NGy7n7+3bQ==",
"path": "sharpziplib/1.2.0",
"hashPath": "sharpziplib.1.2.0.nupkg.sha512"
},
"System.Runtime.CompilerServices.Unsafe/4.7.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-zOHkQmzPCn5zm/BH+cxC1XbUS3P4Yoi3xzW7eRgVpDR2tPGSzyMZ17Ig1iRkfJuY0nhxkQQde8pgePNiA7z7TQ==",
"path": "system.runtime.compilerservices.unsafe/4.7.1",
"hashPath": "system.runtime.compilerservices.unsafe.4.7.1.nupkg.sha512"
},
"System.Text.Encoding.CodePages/4.7.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-i2fOvznVVgOOTLUz8FgSap/MsR98I4Iaoz99VXcOW/e7Y2OdY42zhYpBYpZyivk5alYY/UsOWAVswhtjxceodA==",
"path": "system.text.encoding.codepages/4.7.1",
"hashPath": "system.text.encoding.codepages.4.7.1.nupkg.sha512"
},
"SupportClasses/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
}
}
}

Binary file not shown.

Binary file not shown.

@ -0,0 +1,108 @@
{
"runtimeTarget": {
"name": ".NETStandard,Version=v2.0/",
"signature": ""
},
"compilationOptions": {},
"targets": {
".NETStandard,Version=v2.0": {},
".NETStandard,Version=v2.0/": {
"DataClients/1.0.0": {
"dependencies": {
"NETStandard.Library": "2.0.3",
"SharpZipLib": "1.2.0",
"SupportClasses": "1.0.0",
"System.Text.Encoding.CodePages": "4.7.1"
},
"runtime": {
"DataClients.dll": {}
}
},
"Microsoft.NETCore.Platforms/1.1.0": {},
"NETStandard.Library/2.0.3": {
"dependencies": {
"Microsoft.NETCore.Platforms": "1.1.0"
}
},
"SharpZipLib/1.2.0": {
"runtime": {
"lib/netstandard2.0/ICSharpCode.SharpZipLib.dll": {
"assemblyVersion": "1.2.0.246",
"fileVersion": "1.2.0.246"
}
}
},
"System.Runtime.CompilerServices.Unsafe/4.7.1": {
"runtime": {
"lib/netstandard2.0/System.Runtime.CompilerServices.Unsafe.dll": {
"assemblyVersion": "4.0.6.0",
"fileVersion": "4.700.20.12001"
}
}
},
"System.Text.Encoding.CodePages/4.7.1": {
"dependencies": {
"System.Runtime.CompilerServices.Unsafe": "4.7.1"
},
"runtime": {
"lib/netstandard2.0/System.Text.Encoding.CodePages.dll": {
"assemblyVersion": "4.1.3.0",
"fileVersion": "4.700.20.21406"
}
}
},
"SupportClasses/1.0.0": {
"runtime": {
"SupportClasses.dll": {}
}
}
}
},
"libraries": {
"DataClients/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"Microsoft.NETCore.Platforms/1.1.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-kz0PEW2lhqygehI/d6XsPCQzD7ff7gUJaVGPVETX611eadGsA3A877GdSlU0LRVMCTH/+P3o2iDTak+S08V2+A==",
"path": "microsoft.netcore.platforms/1.1.0",
"hashPath": "microsoft.netcore.platforms.1.1.0.nupkg.sha512"
},
"NETStandard.Library/2.0.3": {
"type": "package",
"serviceable": true,
"sha512": "sha512-st47PosZSHrjECdjeIzZQbzivYBJFv6P2nv4cj2ypdI204DO+vZ7l5raGMiX4eXMJ53RfOIg+/s4DHVZ54Nu2A==",
"path": "netstandard.library/2.0.3",
"hashPath": "netstandard.library.2.0.3.nupkg.sha512"
},
"SharpZipLib/1.2.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-zvWa/L02JHNatdtjya6Swpudb2YEHaOLHL1eRrqpjm71iGRNUNONO5adUF/9CHbSJbzhELW1UoH4NGy7n7+3bQ==",
"path": "sharpziplib/1.2.0",
"hashPath": "sharpziplib.1.2.0.nupkg.sha512"
},
"System.Runtime.CompilerServices.Unsafe/4.7.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-zOHkQmzPCn5zm/BH+cxC1XbUS3P4Yoi3xzW7eRgVpDR2tPGSzyMZ17Ig1iRkfJuY0nhxkQQde8pgePNiA7z7TQ==",
"path": "system.runtime.compilerservices.unsafe/4.7.1",
"hashPath": "system.runtime.compilerservices.unsafe.4.7.1.nupkg.sha512"
},
"System.Text.Encoding.CodePages/4.7.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-i2fOvznVVgOOTLUz8FgSap/MsR98I4Iaoz99VXcOW/e7Y2OdY42zhYpBYpZyivk5alYY/UsOWAVswhtjxceodA==",
"path": "system.text.encoding.codepages/4.7.1",
"hashPath": "system.text.encoding.codepages.4.7.1.nupkg.sha512"
},
"SupportClasses/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
}
}
}

Binary file not shown.

Binary file not shown.

@ -1 +1 @@
28f25e2c7da5c3cddc132285b76b94739ff791dd dcd43f965ba9bd3497fc087ead8b4421f1313830

@ -25,3 +25,6 @@ D:\GIT\ASCKU_PC\DataClients\obj\Debug\netstandard2.0\DataClients.AssemblyInfo.cs
D:\GIT\ASCKU_PC\DataClients\obj\Debug\netstandard2.0\DataClients.csproj.CoreCompileInputs.cache D:\GIT\ASCKU_PC\DataClients\obj\Debug\netstandard2.0\DataClients.csproj.CoreCompileInputs.cache
D:\GIT\ASCKU_PC\DataClients\obj\Debug\netstandard2.0\DataClients.dll D:\GIT\ASCKU_PC\DataClients\obj\Debug\netstandard2.0\DataClients.dll
D:\GIT\ASCKU_PC\DataClients\obj\Debug\netstandard2.0\DataClients.pdb D:\GIT\ASCKU_PC\DataClients\obj\Debug\netstandard2.0\DataClients.pdb
D:\GIT\ASCKU_PC\DataClients\bin\Debug\netstandard2.0\SupportClasses.dll
D:\GIT\ASCKU_PC\DataClients\bin\Debug\netstandard2.0\SupportClasses.pdb
D:\GIT\ASCKU_PC\DataClients\obj\Debug\netstandard2.0\DataClients.csproj.CopyComplete

@ -0,0 +1,4 @@
// <autogenerated />
using System;
using System.Reflection;
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETStandard,Version=v2.0", FrameworkDisplayName = "")]

@ -0,0 +1,23 @@
//------------------------------------------------------------------------------
// <auto-generated>
// Этот код создан программой.
// Исполняемая версия:4.0.30319.42000
//
// Изменения в этом файле могут привести к неправильной работе и будут потеряны в случае
// повторной генерации кода.
// </auto-generated>
//------------------------------------------------------------------------------
using System;
using System.Reflection;
[assembly: System.Reflection.AssemblyCompanyAttribute("DataClients")]
[assembly: System.Reflection.AssemblyConfigurationAttribute("Release")]
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")]
[assembly: System.Reflection.AssemblyProductAttribute("DataClients")]
[assembly: System.Reflection.AssemblyTitleAttribute("DataClients")]
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
// Создано классом WriteCodeFragment MSBuild.

@ -0,0 +1 @@
ea98a8b17e3fc7f2bf776b1d13af537d64ea224f

@ -0,0 +1 @@
4ae8ce6eebe1054eb1c67ffb85e61f9a1dcb14bc

@ -0,0 +1,12 @@
D:\GIT\ASCKU_PC\DataClients\bin\Release\netstandard2.0\DataClients.deps.json
D:\GIT\ASCKU_PC\DataClients\bin\Release\netstandard2.0\DataClients.dll
D:\GIT\ASCKU_PC\DataClients\bin\Release\netstandard2.0\DataClients.pdb
D:\GIT\ASCKU_PC\DataClients\bin\Release\netstandard2.0\SupportClasses.dll
D:\GIT\ASCKU_PC\DataClients\bin\Release\netstandard2.0\SupportClasses.pdb
D:\GIT\ASCKU_PC\DataClients\obj\Release\netstandard2.0\DataClients.csprojAssemblyReference.cache
D:\GIT\ASCKU_PC\DataClients\obj\Release\netstandard2.0\DataClients.AssemblyInfoInputs.cache
D:\GIT\ASCKU_PC\DataClients\obj\Release\netstandard2.0\DataClients.AssemblyInfo.cs
D:\GIT\ASCKU_PC\DataClients\obj\Release\netstandard2.0\DataClients.csproj.CoreCompileInputs.cache
D:\GIT\ASCKU_PC\DataClients\obj\Release\netstandard2.0\DataClients.csproj.CopyComplete
D:\GIT\ASCKU_PC\DataClients\obj\Release\netstandard2.0\DataClients.dll
D:\GIT\ASCKU_PC\DataClients\obj\Release\netstandard2.0\DataClients.pdb

Binary file not shown.

Binary file not shown.

@ -20,7 +20,7 @@ namespace Mailing
} }
} }
public static class SZOEveryday public static class CollectData
{ {
public static List<SZOWork> GetSZOWorks(DateTime timeStart, DateTime timeEnd, ushort vdp) public static List<SZOWork> GetSZOWorks(DateTime timeStart, DateTime timeEnd, ushort vdp)
{ {
@ -45,6 +45,14 @@ namespace Mailing
{ {
if (!chk1.Contains((int)cycle.index) && !chk2.Contains((int)cycle.index)) if (!chk1.Contains((int)cycle.index) && !chk2.Contains((int)cycle.index))
continue; continue;
if (cycle.end < timeStart || cycle.start > timeEnd)
continue;
if (cycle.start < timeStart)
cycle.start = timeStart;
if (cycle.end > timeEnd)
cycle.end = timeEnd;
if (chk1.Contains((int)cycle.index)) if (chk1.Contains((int)cycle.index))
{ {
var test = var test =
@ -60,11 +68,17 @@ namespace Mailing
for(var i = 0; i < ad.di[22].Length; i++) for(var i = 0; i < ad.di[22].Length; i++)
{ {
var ts = ad.di[22][i].Item1; var ts = ad.di[22][i].Item1;
var te = (i == ad.di[22].Length) ? var te = (i == (ad.di[22].Length - 1)) ?
(ad.di[22][i].Item1 < timeEnd) ? (ad.di[22][i].Item1 < timeEnd) ?
timeEnd : timeEnd :
ad.di[22][i].Item1 : ad.di[22][i].Item1 :
ad.di[22][i + 1].Item1; ad.di[22][i + 1].Item1;
if (te >= timeStart && ts <= timeStart)
ts = timeStart;
if (ts <= timeEnd && te >= timeEnd)
te = timeEnd;
var v = ad.di[22][i].Item2; var v = ad.di[22][i].Item2;
if ( if (
@ -90,23 +104,6 @@ namespace Mailing
} }
return result; return result;
} }
public static void GetPDF(DateTime time)
{
timeStart = new DateTime(time.Year, time.Month, time.Day, 0, 0, 0);
timeEnd = new DateTime(time.Year, time.Month, time.Day, 0, 0, 0).AddDays(1);
GetData();
PDFGenSZO.AddHeader("Контроль работы водокольцевых насосов SZO ", timeStart, timeEnd);
foreach (var e in resFull)
PDFGenSZO.AddSZOTable(e.Key, e.Value);
PDFGenSZO.AddTotalTime();
PDFGenSZO.Print(time);
}
} }
} }

358
Mailing/CreatePDF.cs Normal file

@ -0,0 +1,358 @@
using DataClients;
using MigraDoc.DocumentObjectModel;
using MigraDoc.DocumentObjectModel.Tables;
using MigraDoc.Rendering;
using PdfSharp.Drawing;
using PdfSharp.Fonts;
using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
namespace Mailing
{
public static class CreatePDF
{
public static void PDFSZO(List<List<SZOWork>> data, DateTime date)
{
//Create Documents
Document doc = new Document();
//Create Fonts
EZFontResolver fontRes = EZFontResolver.Get;
GlobalFontSettings.FontResolver = fontRes;
fontRes.AddFont("TNR", XFontStyle.Regular, @"./times.ttf");
fontRes.AddFont("TNR", XFontStyle.Bold, @"./timesbd.ttf");
fontRes.AddFont("TNR", XFontStyle.BoldItalic, @"./timesbi.ttf");
fontRes.AddFont("TNR", XFontStyle.Italic, @"./timesi.ttf");
//Create page
Section page = doc.AddSection();
page.PageSetup.PageFormat = PageFormat.A4;
page.PageSetup.Orientation = Orientation.Portrait;
page.PageSetup.BottomMargin = new Unit(20, UnitType.Millimeter);
page.PageSetup.TopMargin = new Unit(20, UnitType.Millimeter);
page.PageSetup.LeftMargin = new Unit(30, UnitType.Millimeter);
page.PageSetup.RightMargin = new Unit(15, UnitType.Millimeter);
//Create Format
var title = page.AddParagraph();
title.Format.Alignment = ParagraphAlignment.Center;
title.Format.Font.Size = 14;
title.Format.Font.Name = "TNR";
title.Format.SpaceAfter = new Unit(10, UnitType.Millimeter);
//Header
title.AddText("Контроль работы водокольцевых насосов SZO\n");
title.AddText("за " + date.ToString("dd.MM.yyyy") + "\n");
var totalTime = new TimeSpan();
for (var i = 0; i < data.Count; i++)
{
if (data[i].Count == 0)
continue;
//Create Format
title = doc.LastSection.AddParagraph();
title.Format.Alignment = ParagraphAlignment.Left;
title.Format.Font.Size = 12;
title.Format.Font.Name = "TNR";
title.Format.SpaceAfter = new Unit(2, UnitType.Millimeter);
//Add Title for Table
title.AddText("Работа SZO печи №" + (i + 1).ToString("D2") + "\n");
//Create Table
var table = doc.LastSection.AddTable();
table.Format.Alignment = ParagraphAlignment.Center;
table.Format.Font.Size = 12;
table.Format.Font.Name = "TNR";
table.Style = "Table";
table.Borders.Color = new Color(0, 0, 0);
table.Borders.Width = 0.25;
table.Borders.Left.Width = 0.5;
table.Borders.Right.Width = 0.5;
table.Rows.LeftIndent = 0;
double[] colSize = { 5 , 4, 5, 3 };
foreach (var e in colSize)
table.AddColumn(new Unit(e, UnitType.Centimeter));
//Add Header for Table
var row = table.AddRow();
row.HeadingFormat = true;
row.VerticalAlignment = VerticalAlignment.Center;
row.Format.Font.Bold = true;
row.Cells[0].AddParagraph("Начало тех. цикла");
row.Cells[1].AddParagraph("Название тех. цикла");
row.Cells[1].MergeDown = 1;
row.Cells[2].AddParagraph("Начало работы SZO");
row.Cells[3].AddParagraph("Время работы SZO");
row.Cells[3].MergeDown = 1;
row = table.AddRow();
row.HeadingFormat = true;
row.VerticalAlignment = VerticalAlignment.Center;
row.Format.Font.Bold = true;
row.Cells[0].AddParagraph("Конец тех. цикла");
row.Cells[2].AddParagraph("Конец работы SZO");
//Add Row in Table
var totalTimeVDP = new TimeSpan();
for (var j = 0; j < data[i].Count;)
{
var currCycle = data[i][j].tc;
var currSZO = new List<SZOWork>();
while (j < data[i].Count)
{
if (data[i][j].tc != currCycle) break;
totalTimeVDP = totalTimeVDP.Add(data[i][j].workTime.Subtract(new TimeSpan(00, 15, 00)));
currSZO.Add(data[i][j]);
j++;
}
for (var k = 0; k < currSZO.Count; k++)
{
row = table.AddRow();
row.HeadingFormat = true;
row.VerticalAlignment = VerticalAlignment.Center;
if (k == 0)
{
row.Cells[0].AddParagraph(currCycle.start.ToString(@"yyyy.MM.dd HH:mm:ss"));
if (currSZO.Count > 1)
row.Cells[0].MergeDown = currSZO.Count - 1;
row.Cells[1].AddParagraph(Names.techCycle[(int)currCycle.index]);
row.Cells[1].MergeDown = currSZO.Count * 2 - 1;
}
row.Cells[2].AddParagraph(currSZO[k].tStart.ToString(@"HH\:mm\:ss"));
row.Cells[3].AddParagraph(currSZO[k].workTime.Subtract(new TimeSpan(00, 15, 00)).ToString(@"hh\:mm\:ss"));
row.Cells[3].MergeDown = 1;
if (currSZO.Count / 2 == k && currSZO.Count % 2 == 0)
{
row.Cells[0].AddParagraph(currCycle.end.ToString(@"yyyy.MM.dd HH:mm:ss"));
if (currSZO.Count > 1)
row.Cells[0].MergeDown = currSZO.Count - 1;
}
row = table.AddRow();
row.HeadingFormat = true;
row.VerticalAlignment = VerticalAlignment.Center;
if (currSZO.Count / 2 == k && currSZO.Count % 2 == 1)
{
row.Cells[0].AddParagraph(currCycle.end.ToString(@"yyyy.MM.dd HH:mm:ss"));
if (currSZO.Count > 1)
row.Cells[0].MergeDown = currSZO.Count - 1;
}
row.Cells[2].AddParagraph(currSZO[k].tEnd.ToString(@"HH\:mm\:ss"));
}
}
//Add Footer for Table
title = doc.LastSection.AddParagraph();
title.Format.Alignment = ParagraphAlignment.Right;
title.Format.Font.Size = 12;
title.Format.Font.Name = "TNR";
title.Format.SpaceAfter = new Unit(10, UnitType.Millimeter);
title.AddText(
"Общее время работы SZO печи №" + (i + 1).ToString("D2") +
": " + totalTimeVDP.ToString(@"hh\:mm\:ss")
);
totalTime = totalTime.Add(totalTimeVDP);
}
title = doc.LastSection.AddParagraph();
title.Format.Alignment = ParagraphAlignment.Left;
title.Format.Font.Size = 12;
title.Format.Font.Name = "TNR";
title.Format.SpaceAfter = new Unit(10, UnitType.Millimeter);
title.AddText("Общее время работы SZO: " + totalTime.ToString(@"%d\.hh\:mm\:ss"));
Print(date, doc, "SZO");
}
public static void Print(DateTime time, Document doc, string type)
{
Directory.CreateDirectory(Directory.GetCurrentDirectory() + '/' + type);
var file = Directory.GetCurrentDirectory() + '/' + type + '/' + time.ToString("yyyy-MM-dd") + ".pdf";
if (File.Exists(file)) File.Delete(file);
var pdfRenderer = new PdfDocumentRenderer(true) { Document = doc };
pdfRenderer.RenderDocument();
pdfRenderer.PdfDocument.Save(file);
}
/// <summary>
/// EZFontResolver is a generic font resolver for PDFsharp.
/// It implement IFontResolver internally.
/// To use it, just pass your fonts as filename or byte[]
/// in calls to AddFont.
/// </summary>
public class EZFontResolver : IFontResolver
{
EZFontResolver()
{ }
/// <summary>
/// Gets the one and only EZFontResolver object.
/// </summary>
public static EZFontResolver Get
{
get { return _singleton ?? (_singleton = new EZFontResolver()); }
}
private static EZFontResolver _singleton;
/// <summary>
/// Adds the font passing a filename.
/// </summary>
/// <param name="familyName">Name of the font family.</param>
/// <param name="style">The style.</param>
/// <param name="filename">The filename.</param>
/// <param name="simulateBold">if set to <c>true</c> bold will be simulated.</param>
/// <param name="simulateItalic">if set to <c>true</c> italic will be simulated.</param>
/// <exception cref="Exception">
/// Font file is too big.
/// or
/// Reading font file failed.
/// </exception>
public void AddFont(string familyName, XFontStyle style, string filename,
bool simulateBold = false, bool simulateItalic = false)
{
using (var fs = new FileStream(filename, FileMode.Open, FileAccess.Read, FileShare.Read))
{
var size = fs.Length;
if (size > int.MaxValue)
throw new Exception("Font file is too big.");
var length = (int)size;
var data = new byte[length];
var read = fs.Read(data, 0, length);
if (length != read)
throw new Exception("Reading font file failed.");
AddFont(familyName, style, data, simulateBold, simulateItalic);
}
}
/// <summary>
/// Adds the font passing a byte array containing the font.
/// </summary>
/// <param name="familyName">Name of the font family.</param>
/// <param name="style">The style.</param>
/// <param name="data">The data.</param>
/// <param name="simulateBold">if set to <c>true</c> bold will be simulated.</param>
/// <param name="simulateItalic">if set to <c>true</c> italic will be simulated.</param>
public void AddFont(string familyName, XFontStyle style, byte[] data,
bool simulateBold = false, bool simulateItalic = false)
{
// Add the font as we get it.
AddFontHelper(familyName, style, data, false, false);
// If the font is not bold and bold simulation is requested, add that, too.
if (simulateBold && (style & XFontStyle.Bold) == 0)
{
AddFontHelper(familyName, style | XFontStyle.Bold, data, true, false);
}
// Same for italic.
if (simulateItalic && (style & XFontStyle.Italic) == 0)
{
AddFontHelper(familyName, style | XFontStyle.Italic, data, false, true);
}
// Same for bold and italic.
if (simulateBold && (style & XFontStyle.Bold) == 0 &&
simulateItalic && (style & XFontStyle.Italic) == 0)
{
AddFontHelper(familyName, style | XFontStyle.BoldItalic, data, true, true);
}
}
void AddFontHelper(string familyName, XFontStyle style, byte[] data, bool simulateBold, bool simulateItalic)
{
// Currently we do not need FamilyName and Style.
// FaceName is a combination of FamilyName and Style.
var fi = new EZFontInfo
{
//FamilyName = familyName,
FaceName = familyName.ToLower(),
//Style = style,
Data = data,
SimulateBold = simulateBold,
SimulateItalic = simulateItalic
};
if ((style & XFontStyle.Bold) != 0)
{
// TODO Create helper method to prevent having duplicate string literals?
fi.FaceName += "|b";
}
if ((style & XFontStyle.Italic) != 0)
{
fi.FaceName += "|i";
}
// Check if we already have this font.
var test = GetFont(fi.FaceName);
if (test != null)
throw new Exception("Font " + familyName + " with this style was already registered.");
_fonts.Add(fi.FaceName.ToLower(), fi);
}
#region IFontResolver
public FontResolverInfo ResolveTypeface(string familyName, bool isBold, bool isItalic)
{
string faceName = familyName.ToLower() +
(isBold ? "|b" : "") +
(isItalic ? "|i" : "");
EZFontInfo item;
if (_fonts.TryGetValue(faceName, out item))
{
var result = new FontResolverInfo(item.FaceName, item.SimulateBold, item.SimulateItalic);
return result;
}
return null;
}
public byte[] GetFont(string faceName)
{
EZFontInfo item;
if (_fonts.TryGetValue(faceName, out item))
{
return item.Data;
}
return null;
}
#endregion
private readonly Dictionary<string, EZFontInfo> _fonts = new Dictionary<string, EZFontInfo>();
struct EZFontInfo
{
//internal string FamilyName;
internal string FaceName;
//internal XFontStyle Style;
internal byte[] Data;
internal bool SimulateBold;
internal bool SimulateItalic;
}
}
}
}

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<_LastSelectedProfileId>D:\GIT\ASCKU_PC\Mailing\Properties\PublishProfiles\FolderProfile.pubxml</_LastSelectedProfileId>
</PropertyGroup>
</Project>

@ -63,7 +63,12 @@ namespace Mailing
return; return;
} }
} }
GenSZO.GetPDF(time); var ts = new DateTime(time.Year, time.Month, time.Day, 0, 0, 0, 0);
var te = new DateTime(time.Year, time.Month, time.Day, 23, 59, 59, 999);
var resVDP = new List<List<SZOWork>>();
for (var i = 1; i <= 50; i++)
resVDP.Add(CollectData.GetSZOWorks(ts, te, (ushort)i));
CreatePDF.PDFSZO(resVDP, ts);
var fileszo = Directory.GetCurrentDirectory() + "/SZO/" + time.ToString("yyyy-MM-dd") + ".pdf"; var fileszo = Directory.GetCurrentDirectory() + "/SZO/" + time.ToString("yyyy-MM-dd") + ".pdf";
foreach (var e in mailList) foreach (var e in mailList)
Mailing.SendMail(new MailAddress(e), fileszo); Mailing.SendMail(new MailAddress(e), fileszo);

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
https://go.microsoft.com/fwlink/?LinkID=208121.
-->
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration>Release</Configuration>
<Platform>Any CPU</Platform>
<PublishDir>bin\Release\netcoreapp3.1\publish\</PublishDir>
<PublishProtocol>FileSystem</PublishProtocol>
</PropertyGroup>
</Project>

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
https://go.microsoft.com/fwlink/?LinkID=208121.
-->
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
</Project>

@ -1,380 +0,0 @@
using DataClients;
using MigraDoc.DocumentObjectModel;
using MigraDoc.DocumentObjectModel.Tables;
using MigraDoc.Rendering;
using PdfSharp.Drawing;
using PdfSharp.Fonts;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
namespace Mailing
{
public static class GenSZO
{
private static DateTime timeStart = DateTime.Now.AddDays(-1);
private static DateTime timeEnd = DateTime.Now;
private static Dictionary<int, List<SZOWork>> resFull = new Dictionary<int, List<SZOWork>>();
public static void GetPDF(DateTime time)
{
timeStart = new DateTime(time.Year, time.Month, time.Day, 0, 0, 0);
timeEnd = new DateTime(time.Year, time.Month, time.Day, 0, 0, 0).AddDays(1);
GetData();
PDFGenSZO.AddHeader("Контроль работы водокольцевых насосов SZO ", timeStart, timeEnd);
foreach (var e in resFull)
PDFGenSZO.AddSZOTable(e.Key, e.Value);
PDFGenSZO.AddTotalTime();
PDFGenSZO.Print(time);
}
private static void GetData()
{
var a = new STPClient();
for (ushort i = 1; i <= 50; i++)
{
var tc = a.GetTechCycle(timeStart, timeEnd, i);
var ad = a.GetAnalogDiscret(timeStart, timeEnd, i);
foreach (var e in tc)
{
int[] chk1 = {
(int)TechCycle.Operation.cooling_ingot,
(int)TechCycle.Operation.cooling_reflow,
(int)TechCycle.Operation.cooling_welding };
int[] chk2 =
{
(int)TechCycle.Operation.end_tech_cycle,
(int)TechCycle.Operation.unloading_loading,
(int)TechCycle.Operation.looking_welding,
(int)TechCycle.Operation.unloading_kit
};
if (!chk1.Contains((int)e.index) && !chk2.Contains((int)e.index))
continue;
if (chk1.Contains((int)e.index))
{
var test =
(from l in ad.an[13]
where l.Item1 >= e.start &&
l.Item1 <= e.end &&
l.Item2 >= 30
select l).ToArray();
if (test.Length == 0)
continue;
}
var currstat = new Tuple<DateTime, bool?>(e.start, null);
foreach (var d in ad.di[22])
{
if (
currstat.Item1 <= e.end &&
d.Item1 >= e.start &&
currstat.Item2.HasValue &&
currstat.Item2.Value
)
{
var t1 = currstat.Item1 > e.start ? currstat.Item1 : e.start;
var t2 = d.Item1 > e.end ? e.end : d.Item1;
var res = t2 - t1;
currstat = d;
if (res.TotalMinutes < 15)
continue;
if (!resFull.ContainsKey(i))
resFull.Add(i, new List<SZOWork>());
resFull[i].Add(new SZOWork()
{
oper = e.index,
techCycleStart = e.start,
WorkTime = res.Subtract(new TimeSpan(00, 15, 00))
});
}
currstat = d;
}
}
}
}
public class SZOWork
{
public TechCycle.Operation oper = TechCycle.Operation.unloading_loading;
public DateTime techCycleStart = DateTime.Now;
public TimeSpan WorkTime = new TimeSpan();
}
}
public static class PDFGenSZO
{
private static TimeSpan totalTime = new TimeSpan();
private static Document doc = new Document();
public static void AddHeader(string name, DateTime start, DateTime end)
{
EZFontResolver fontRes = EZFontResolver.Get;
GlobalFontSettings.FontResolver = fontRes;
fontRes.AddFont("TNR", XFontStyle.Regular, @"./times.ttf");
fontRes.AddFont("TNR", XFontStyle.Bold, @"./timesbd.ttf");
fontRes.AddFont("TNR", XFontStyle.BoldItalic, @"./timesbi.ttf");
fontRes.AddFont("TNR", XFontStyle.Italic, @"./timesi.ttf");
Section page = AddPage();
var title = page.AddParagraph();
title.Format.Alignment = ParagraphAlignment.Center;
title.Format.Font.Size = 14;
title.Format.Font.Name = "TNR";
title.Format.SpaceAfter = new Unit(10, UnitType.Millimeter);
title.AddText(name + "\n");
end = end.AddSeconds(-1);
title.AddText("за период с " + start.ToString("dd.MM.yyyy") + " по " + end.ToString("dd.MM.yyyy") + "\n");
}
public static void AddSZOTable(int vdp, List<GenSZO.SZOWork> res)
{
var title = doc.LastSection.AddParagraph();
title.Format.Alignment = ParagraphAlignment.Left;
title.Format.Font.Size = 12;
title.Format.Font.Name = "TNR";
title.Format.SpaceAfter = new Unit(2, UnitType.Millimeter);
title.AddText("Работа SZO печи №" + vdp.ToString("D2") + "\n");
var table = doc.LastSection.AddTable();
table.Format.Alignment = ParagraphAlignment.Center;
table.Format.Font.Size = 12;
table.Format.Font.Name = "TNR";
table.Rows.LeftIndent = 0;
int[] colSize = { 5, 8, 4 };
foreach (var e in colSize)
{
var col = table.AddColumn(new Unit(e, UnitType.Centimeter));
col.Borders.Left.Color = new Color(0, 0, 0);
col.Borders.Left.Width = 0.25;
col.Borders.Right.Color = new Color(0, 0, 0);
col.Borders.Right.Width = 0.25;
}
var row = table.AddRow();
row.Borders.Top.Color = new Color(0, 0, 0);
row.Borders.Top.Width = 0.25;
row.Borders.Bottom.Color = new Color(0, 0, 0);
row.Borders.Bottom.Width = 0.25;
row.HeadingFormat = true;
row.VerticalAlignment = VerticalAlignment.Center;
row.Cells[0].AddParagraph("Время начала операции");
row.Cells[1].AddParagraph("Название операции");
row.Cells[2].AddParagraph("Время работы SZO");
var totalVDP = new TimeSpan();
foreach (var e in res)
{
row = table.AddRow();
row.Borders.Bottom.Color = new Color(0, 0, 0);
row.Borders.Bottom.Width = 0.25;
row.VerticalAlignment = VerticalAlignment.Center;
row.Cells[0].AddParagraph(e.techCycleStart.ToString(@"yyyy.MM.dd HH:mm:ss.ff"));
row.Cells[1].AddParagraph(Names.techCycle[(int)e.oper]);
row.Cells[2].AddParagraph(e.WorkTime.ToString(@"hh\:mm\:ss"));
totalVDP = totalVDP.Add(e.WorkTime);
}
title = doc.LastSection.AddParagraph();
title.Format.Alignment = ParagraphAlignment.Right;
title.Format.Font.Size = 12;
title.Format.Font.Name = "TNR";
title.Format.SpaceAfter = new Unit(10, UnitType.Millimeter);
title.AddText(
"Общее время работы SZO печи №" + vdp.ToString("D2") +
": " + totalVDP.ToString(@"hh\:mm\:ss")
);
totalTime = totalTime.Add(totalVDP);
}
public static void AddTotalTime() { AddTotalTime(totalTime); }
public static void AddTotalTime(TimeSpan time)
{
var title = doc.LastSection.AddParagraph();
title.Format.Alignment = ParagraphAlignment.Left;
title.Format.Font.Size = 12;
title.Format.Font.Name = "TNR";
title.Format.SpaceAfter = new Unit(10, UnitType.Millimeter);
title.AddText("Общее время работы SZO: " + time.ToString(@"%d\.hh\:mm\:ss"));
}
public static void Print(DateTime time)
{
Directory.CreateDirectory(Directory.GetCurrentDirectory() + '/' + "SZO");
var file = Directory.GetCurrentDirectory() + '/' + "SZO" + '/' + time.ToString("yyyy-MM-dd") + ".pdf";
if (File.Exists(file))
File.Delete(file);
var pdfRenderer = new PdfDocumentRenderer(true) { Document = doc };
pdfRenderer.RenderDocument();
pdfRenderer.PdfDocument.Save(file);
}
private static Section AddPage()
{
Section section = doc.AddSection();
section.PageSetup.PageFormat = PageFormat.A4;
section.PageSetup.Orientation = Orientation.Portrait;
section.PageSetup.BottomMargin = new Unit(20, UnitType.Millimeter);
section.PageSetup.TopMargin = new Unit(20, UnitType.Millimeter);
section.PageSetup.LeftMargin = new Unit(30, UnitType.Millimeter);
section.PageSetup.RightMargin = new Unit(15, UnitType.Millimeter);
return section;
}
}
/// <summary>
/// EZFontResolver is a generic font resolver for PDFsharp.
/// It implement IFontResolver internally.
/// To use it, just pass your fonts as filename or byte[]
/// in calls to AddFont.
/// </summary>
public class EZFontResolver : IFontResolver
{
EZFontResolver()
{ }
/// <summary>
/// Gets the one and only EZFontResolver object.
/// </summary>
public static EZFontResolver Get
{
get { return _singleton ?? (_singleton = new EZFontResolver()); }
}
private static EZFontResolver _singleton;
/// <summary>
/// Adds the font passing a filename.
/// </summary>
/// <param name="familyName">Name of the font family.</param>
/// <param name="style">The style.</param>
/// <param name="filename">The filename.</param>
/// <param name="simulateBold">if set to <c>true</c> bold will be simulated.</param>
/// <param name="simulateItalic">if set to <c>true</c> italic will be simulated.</param>
/// <exception cref="Exception">
/// Font file is too big.
/// or
/// Reading font file failed.
/// </exception>
public void AddFont(string familyName, XFontStyle style, string filename,
bool simulateBold = false, bool simulateItalic = false)
{
using (var fs = new FileStream(filename, FileMode.Open, FileAccess.Read, FileShare.Read))
{
var size = fs.Length;
if (size > int.MaxValue)
throw new Exception("Font file is too big.");
var length = (int)size;
var data = new byte[length];
var read = fs.Read(data, 0, length);
if (length != read)
throw new Exception("Reading font file failed.");
AddFont(familyName, style, data, simulateBold, simulateItalic);
}
}
/// <summary>
/// Adds the font passing a byte array containing the font.
/// </summary>
/// <param name="familyName">Name of the font family.</param>
/// <param name="style">The style.</param>
/// <param name="data">The data.</param>
/// <param name="simulateBold">if set to <c>true</c> bold will be simulated.</param>
/// <param name="simulateItalic">if set to <c>true</c> italic will be simulated.</param>
public void AddFont(string familyName, XFontStyle style, byte[] data,
bool simulateBold = false, bool simulateItalic = false)
{
// Add the font as we get it.
AddFontHelper(familyName, style, data, false, false);
// If the font is not bold and bold simulation is requested, add that, too.
if (simulateBold && (style & XFontStyle.Bold) == 0)
{
AddFontHelper(familyName, style | XFontStyle.Bold, data, true, false);
}
// Same for italic.
if (simulateItalic && (style & XFontStyle.Italic) == 0)
{
AddFontHelper(familyName, style | XFontStyle.Italic, data, false, true);
}
// Same for bold and italic.
if (simulateBold && (style & XFontStyle.Bold) == 0 &&
simulateItalic && (style & XFontStyle.Italic) == 0)
{
AddFontHelper(familyName, style | XFontStyle.BoldItalic, data, true, true);
}
}
void AddFontHelper(string familyName, XFontStyle style, byte[] data, bool simulateBold, bool simulateItalic)
{
// Currently we do not need FamilyName and Style.
// FaceName is a combination of FamilyName and Style.
var fi = new EZFontInfo
{
//FamilyName = familyName,
FaceName = familyName.ToLower(),
//Style = style,
Data = data,
SimulateBold = simulateBold,
SimulateItalic = simulateItalic
};
if ((style & XFontStyle.Bold) != 0)
{
// TODO Create helper method to prevent having duplicate string literals?
fi.FaceName += "|b";
}
if ((style & XFontStyle.Italic) != 0)
{
fi.FaceName += "|i";
}
// Check if we already have this font.
var test = GetFont(fi.FaceName);
if (test != null)
throw new Exception("Font " + familyName + " with this style was already registered.");
_fonts.Add(fi.FaceName.ToLower(), fi);
}
#region IFontResolver
public FontResolverInfo ResolveTypeface(string familyName, bool isBold, bool isItalic)
{
string faceName = familyName.ToLower() +
(isBold ? "|b" : "") +
(isItalic ? "|i" : "");
EZFontInfo item;
if (_fonts.TryGetValue(faceName, out item))
{
var result = new FontResolverInfo(item.FaceName, item.SimulateBold, item.SimulateItalic);
return result;
}
return null;
}
public byte[] GetFont(string faceName)
{
EZFontInfo item;
if (_fonts.TryGetValue(faceName, out item))
{
return item.Data;
}
return null;
}
#endregion
private readonly Dictionary<string, EZFontInfo> _fonts = new Dictionary<string, EZFontInfo>();
struct EZFontInfo
{
//internal string FamilyName;
internal string FaceName;
//internal XFontStyle Style;
internal byte[] Data;
internal bool SimulateBold;
internal bool SimulateItalic;
}
}
}

@ -94,6 +94,7 @@
"DataClients/1.0.0": { "DataClients/1.0.0": {
"dependencies": { "dependencies": {
"SharpZipLib": "1.2.0", "SharpZipLib": "1.2.0",
"SupportClasses": "1.0.0",
"System.Text.Encoding.CodePages": "4.7.1" "System.Text.Encoding.CodePages": "4.7.1"
}, },
"runtime": { "runtime": {
@ -140,6 +141,11 @@
"runtime": { "runtime": {
"PdfSharp.Charting.dll": {} "PdfSharp.Charting.dll": {}
} }
},
"SupportClasses/1.0.0": {
"runtime": {
"SupportClasses.dll": {}
}
} }
} }
}, },
@ -208,6 +214,11 @@
"type": "project", "type": "project",
"serviceable": false, "serviceable": false,
"sha512": "" "sha512": ""
},
"SupportClasses/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
} }
} }
} }

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -0,0 +1,224 @@
{
"runtimeTarget": {
"name": ".NETCoreApp,Version=v3.1",
"signature": ""
},
"compilationOptions": {},
"targets": {
".NETCoreApp,Version=v3.1": {
"Mailing/1.0.0": {
"dependencies": {
"DataClients": "1.0.0",
"MigraDoc.DocumentObjectModel": "3.0.0",
"MigraDoc.Rendering": "3.0.0",
"PdfSharp": "3.0.0",
"SharpZipLib": "1.2.0"
},
"runtime": {
"Mailing.dll": {}
}
},
"Microsoft.NETCore.Platforms/3.1.1": {},
"Microsoft.Win32.SystemEvents/4.5.0": {
"dependencies": {
"Microsoft.NETCore.Platforms": "3.1.1"
},
"runtime": {
"lib/netstandard2.0/Microsoft.Win32.SystemEvents.dll": {
"assemblyVersion": "4.0.0.0",
"fileVersion": "4.6.26515.6"
}
},
"runtimeTargets": {
"runtimes/win/lib/netcoreapp2.0/Microsoft.Win32.SystemEvents.dll": {
"rid": "win",
"assetType": "runtime",
"assemblyVersion": "4.0.0.0",
"fileVersion": "4.6.26515.6"
}
}
},
"SharpZipLib/1.2.0": {
"runtime": {
"lib/netstandard2.0/ICSharpCode.SharpZipLib.dll": {
"assemblyVersion": "1.2.0.246",
"fileVersion": "1.2.0.246"
}
}
},
"System.Drawing.Common/4.5.0": {
"dependencies": {
"Microsoft.NETCore.Platforms": "3.1.1",
"Microsoft.Win32.SystemEvents": "4.5.0"
},
"runtime": {
"lib/netstandard2.0/System.Drawing.Common.dll": {
"assemblyVersion": "4.0.0.0",
"fileVersion": "4.6.26515.6"
}
},
"runtimeTargets": {
"runtimes/unix/lib/netcoreapp2.0/System.Drawing.Common.dll": {
"rid": "unix",
"assetType": "runtime",
"assemblyVersion": "4.0.0.0",
"fileVersion": "4.6.26515.6"
},
"runtimes/win/lib/netcoreapp2.0/System.Drawing.Common.dll": {
"rid": "win",
"assetType": "runtime",
"assemblyVersion": "4.0.0.0",
"fileVersion": "4.6.26515.6"
}
}
},
"System.Text.Encoding.CodePages/4.7.1": {
"dependencies": {
"Microsoft.NETCore.Platforms": "3.1.1"
},
"runtime": {
"lib/netstandard2.0/System.Text.Encoding.CodePages.dll": {
"assemblyVersion": "4.1.3.0",
"fileVersion": "4.700.20.21406"
}
},
"runtimeTargets": {
"runtimes/win/lib/netcoreapp2.0/System.Text.Encoding.CodePages.dll": {
"rid": "win",
"assetType": "runtime",
"assemblyVersion": "4.1.3.0",
"fileVersion": "4.700.20.21406"
}
}
},
"DataClients/1.0.0": {
"dependencies": {
"SharpZipLib": "1.2.0",
"SupportClasses": "1.0.0",
"System.Text.Encoding.CodePages": "4.7.1"
},
"runtime": {
"DataClients.dll": {}
}
},
"MigraDoc.DocumentObjectModel/3.0.0": {
"dependencies": {
"System.Drawing.Common": "4.5.0"
},
"runtime": {
"MigraDoc.DocumentObjectModel.dll": {}
}
},
"MigraDoc.Rendering/3.0.0": {
"dependencies": {
"MigraDoc.DocumentObjectModel": "3.0.0",
"PdfSharp": "3.0.0",
"PdfSharp.Charting": "3.0.0",
"System.Drawing.Common": "4.5.0"
},
"runtime": {
"MigraDoc.Rendering.dll": {}
},
"resources": {
"de/MigraDoc.Rendering.resources.dll": {
"locale": "de"
}
}
},
"PdfSharp/3.0.0": {
"dependencies": {
"System.Drawing.Common": "4.5.0"
},
"runtime": {
"PdfSharp.dll": {}
}
},
"PdfSharp.Charting/3.0.0": {
"dependencies": {
"PdfSharp": "3.0.0",
"System.Drawing.Common": "4.5.0"
},
"runtime": {
"PdfSharp.Charting.dll": {}
}
},
"SupportClasses/1.0.0": {
"runtime": {
"SupportClasses.dll": {}
}
}
}
},
"libraries": {
"Mailing/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"Microsoft.NETCore.Platforms/3.1.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-RmINcaqiEkawM9C8oxFMN/CZmn1fGKWVsosbSY/8ARUNdHqV47hqhPVbrG3qUqLaRQI5w4HuqFOqrbhoSWcH6w==",
"path": "microsoft.netcore.platforms/3.1.1",
"hashPath": "microsoft.netcore.platforms.3.1.1.nupkg.sha512"
},
"Microsoft.Win32.SystemEvents/4.5.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-LuI1oG+24TUj1ZRQQjM5Ew73BKnZE5NZ/7eAdh1o8ST5dPhUnJvIkiIn2re3MwnkRy6ELRnvEbBxHP8uALKhJw==",
"path": "microsoft.win32.systemevents/4.5.0",
"hashPath": "microsoft.win32.systemevents.4.5.0.nupkg.sha512"
},
"SharpZipLib/1.2.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-zvWa/L02JHNatdtjya6Swpudb2YEHaOLHL1eRrqpjm71iGRNUNONO5adUF/9CHbSJbzhELW1UoH4NGy7n7+3bQ==",
"path": "sharpziplib/1.2.0",
"hashPath": "sharpziplib.1.2.0.nupkg.sha512"
},
"System.Drawing.Common/4.5.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-AiJFxxVPdeITstiRS5aAu8+8Dpf5NawTMoapZ53Gfirml24p7HIfhjmCRxdXnmmf3IUA3AX3CcW7G73CjWxW/Q==",
"path": "system.drawing.common/4.5.0",
"hashPath": "system.drawing.common.4.5.0.nupkg.sha512"
},
"System.Text.Encoding.CodePages/4.7.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-i2fOvznVVgOOTLUz8FgSap/MsR98I4Iaoz99VXcOW/e7Y2OdY42zhYpBYpZyivk5alYY/UsOWAVswhtjxceodA==",
"path": "system.text.encoding.codepages/4.7.1",
"hashPath": "system.text.encoding.codepages.4.7.1.nupkg.sha512"
},
"DataClients/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"MigraDoc.DocumentObjectModel/3.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"MigraDoc.Rendering/3.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"PdfSharp/3.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"PdfSharp.Charting/3.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"SupportClasses/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
}
}
}

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -0,0 +1,10 @@
{
"runtimeOptions": {
"additionalProbingPaths": [
"C:\\Users\\google\\.dotnet\\store\\|arch|\\|tfm|",
"C:\\Users\\google\\.nuget\\packages",
"C:\\Microsoft\\Xamarin\\NuGet",
"C:\\Program Files\\dotnet\\sdk\\NuGetFallbackFolder"
]
}
}

@ -0,0 +1,9 @@
{
"runtimeOptions": {
"tfm": "netcoreapp3.1",
"framework": {
"name": "Microsoft.NETCore.App",
"version": "3.1.0"
}
}
}

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -0,0 +1,224 @@
{
"runtimeTarget": {
"name": ".NETCoreApp,Version=v3.1",
"signature": ""
},
"compilationOptions": {},
"targets": {
".NETCoreApp,Version=v3.1": {
"Mailing/1.0.0": {
"dependencies": {
"DataClients": "1.0.0",
"MigraDoc.DocumentObjectModel": "3.0.0",
"MigraDoc.Rendering": "3.0.0",
"PdfSharp": "3.0.0",
"SharpZipLib": "1.2.0"
},
"runtime": {
"Mailing.dll": {}
}
},
"Microsoft.NETCore.Platforms/3.1.1": {},
"Microsoft.Win32.SystemEvents/4.5.0": {
"dependencies": {
"Microsoft.NETCore.Platforms": "3.1.1"
},
"runtime": {
"lib/netstandard2.0/Microsoft.Win32.SystemEvents.dll": {
"assemblyVersion": "4.0.0.0",
"fileVersion": "4.6.26515.6"
}
},
"runtimeTargets": {
"runtimes/win/lib/netcoreapp2.0/Microsoft.Win32.SystemEvents.dll": {
"rid": "win",
"assetType": "runtime",
"assemblyVersion": "4.0.0.0",
"fileVersion": "4.6.26515.6"
}
}
},
"SharpZipLib/1.2.0": {
"runtime": {
"lib/netstandard2.0/ICSharpCode.SharpZipLib.dll": {
"assemblyVersion": "1.2.0.246",
"fileVersion": "1.2.0.246"
}
}
},
"System.Drawing.Common/4.5.0": {
"dependencies": {
"Microsoft.NETCore.Platforms": "3.1.1",
"Microsoft.Win32.SystemEvents": "4.5.0"
},
"runtime": {
"lib/netstandard2.0/System.Drawing.Common.dll": {
"assemblyVersion": "4.0.0.0",
"fileVersion": "4.6.26515.6"
}
},
"runtimeTargets": {
"runtimes/unix/lib/netcoreapp2.0/System.Drawing.Common.dll": {
"rid": "unix",
"assetType": "runtime",
"assemblyVersion": "4.0.0.0",
"fileVersion": "4.6.26515.6"
},
"runtimes/win/lib/netcoreapp2.0/System.Drawing.Common.dll": {
"rid": "win",
"assetType": "runtime",
"assemblyVersion": "4.0.0.0",
"fileVersion": "4.6.26515.6"
}
}
},
"System.Text.Encoding.CodePages/4.7.1": {
"dependencies": {
"Microsoft.NETCore.Platforms": "3.1.1"
},
"runtime": {
"lib/netstandard2.0/System.Text.Encoding.CodePages.dll": {
"assemblyVersion": "4.1.3.0",
"fileVersion": "4.700.20.21406"
}
},
"runtimeTargets": {
"runtimes/win/lib/netcoreapp2.0/System.Text.Encoding.CodePages.dll": {
"rid": "win",
"assetType": "runtime",
"assemblyVersion": "4.1.3.0",
"fileVersion": "4.700.20.21406"
}
}
},
"DataClients/1.0.0": {
"dependencies": {
"SharpZipLib": "1.2.0",
"SupportClasses": "1.0.0",
"System.Text.Encoding.CodePages": "4.7.1"
},
"runtime": {
"DataClients.dll": {}
}
},
"MigraDoc.DocumentObjectModel/3.0.0": {
"dependencies": {
"System.Drawing.Common": "4.5.0"
},
"runtime": {
"MigraDoc.DocumentObjectModel.dll": {}
}
},
"MigraDoc.Rendering/3.0.0": {
"dependencies": {
"MigraDoc.DocumentObjectModel": "3.0.0",
"PdfSharp": "3.0.0",
"PdfSharp.Charting": "3.0.0",
"System.Drawing.Common": "4.5.0"
},
"runtime": {
"MigraDoc.Rendering.dll": {}
},
"resources": {
"de/MigraDoc.Rendering.resources.dll": {
"locale": "de"
}
}
},
"PdfSharp/3.0.0": {
"dependencies": {
"System.Drawing.Common": "4.5.0"
},
"runtime": {
"PdfSharp.dll": {}
}
},
"PdfSharp.Charting/3.0.0": {
"dependencies": {
"PdfSharp": "3.0.0",
"System.Drawing.Common": "4.5.0"
},
"runtime": {
"PdfSharp.Charting.dll": {}
}
},
"SupportClasses/1.0.0": {
"runtime": {
"SupportClasses.dll": {}
}
}
}
},
"libraries": {
"Mailing/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"Microsoft.NETCore.Platforms/3.1.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-RmINcaqiEkawM9C8oxFMN/CZmn1fGKWVsosbSY/8ARUNdHqV47hqhPVbrG3qUqLaRQI5w4HuqFOqrbhoSWcH6w==",
"path": "microsoft.netcore.platforms/3.1.1",
"hashPath": "microsoft.netcore.platforms.3.1.1.nupkg.sha512"
},
"Microsoft.Win32.SystemEvents/4.5.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-LuI1oG+24TUj1ZRQQjM5Ew73BKnZE5NZ/7eAdh1o8ST5dPhUnJvIkiIn2re3MwnkRy6ELRnvEbBxHP8uALKhJw==",
"path": "microsoft.win32.systemevents/4.5.0",
"hashPath": "microsoft.win32.systemevents.4.5.0.nupkg.sha512"
},
"SharpZipLib/1.2.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-zvWa/L02JHNatdtjya6Swpudb2YEHaOLHL1eRrqpjm71iGRNUNONO5adUF/9CHbSJbzhELW1UoH4NGy7n7+3bQ==",
"path": "sharpziplib/1.2.0",
"hashPath": "sharpziplib.1.2.0.nupkg.sha512"
},
"System.Drawing.Common/4.5.0": {
"type": "package",
"serviceable": true,
"sha512": "sha512-AiJFxxVPdeITstiRS5aAu8+8Dpf5NawTMoapZ53Gfirml24p7HIfhjmCRxdXnmmf3IUA3AX3CcW7G73CjWxW/Q==",
"path": "system.drawing.common/4.5.0",
"hashPath": "system.drawing.common.4.5.0.nupkg.sha512"
},
"System.Text.Encoding.CodePages/4.7.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-i2fOvznVVgOOTLUz8FgSap/MsR98I4Iaoz99VXcOW/e7Y2OdY42zhYpBYpZyivk5alYY/UsOWAVswhtjxceodA==",
"path": "system.text.encoding.codepages/4.7.1",
"hashPath": "system.text.encoding.codepages.4.7.1.nupkg.sha512"
},
"DataClients/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"MigraDoc.DocumentObjectModel/3.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"MigraDoc.Rendering/3.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"PdfSharp/3.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"PdfSharp.Charting/3.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"SupportClasses/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
}
}
}

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -0,0 +1,9 @@
{
"runtimeOptions": {
"tfm": "netcoreapp3.1",
"framework": {
"name": "Microsoft.NETCore.App",
"version": "3.1.0"
}
}
}

Binary file not shown.

Binary file not shown.

@ -1 +1 @@
e79626e0af92f8b473bc98f42f0bd95f726cf733 caf869e0c7cd8f80b530707b376cbfb635a1c3df

@ -81,3 +81,5 @@ D:\GIT\ASCKU_PC\Mailing\obj\Debug\netcoreapp3.1\Mailing.csproj.CopyComplete
D:\GIT\ASCKU_PC\Mailing\obj\Debug\netcoreapp3.1\Mailing.dll D:\GIT\ASCKU_PC\Mailing\obj\Debug\netcoreapp3.1\Mailing.dll
D:\GIT\ASCKU_PC\Mailing\obj\Debug\netcoreapp3.1\Mailing.pdb D:\GIT\ASCKU_PC\Mailing\obj\Debug\netcoreapp3.1\Mailing.pdb
D:\GIT\ASCKU_PC\Mailing\obj\Debug\netcoreapp3.1\Mailing.genruntimeconfig.cache D:\GIT\ASCKU_PC\Mailing\obj\Debug\netcoreapp3.1\Mailing.genruntimeconfig.cache
D:\GIT\ASCKU_PC\Mailing\bin\Debug\netcoreapp3.1\SupportClasses.dll
D:\GIT\ASCKU_PC\Mailing\bin\Debug\netcoreapp3.1\SupportClasses.pdb

Some files were not shown because too many files have changed in this diff Show More