Browse Source

Quickfixes

master
NikolaJovanovic 3 years ago
parent
commit
9a01df11a8

BIN
.vs/ClockifyReport/FileContentIndex/d0b5dbec-8f69-424a-9ec8-012448adc627.vsidx View File


BIN
.vs/ClockifyReport/FileContentIndex/f87ce9a7-8ee9-484a-b46e-b3c1eae8f8bf.vsidx View File


BIN
.vs/ClockifyReport/v17/.suo View File


+ 1
- 1
ClockifyReport/Business/ReportGenerator.cs View File

public static Workbook GenerateReportContent(Root reportObject) public static Workbook GenerateReportContent(Root reportObject)
{ {
var excelFile = new Workbook(); var excelFile = new Workbook();
excelFile.Worksheets.Clear();
var ws = excelFile.Worksheets.Add("Content"); var ws = excelFile.Worksheets.Add("Content");


AddReportItems(reportObject, ws); AddReportItems(reportObject, ws);
TimeSpan t, time, time1; TimeSpan t, time, time1;
int row = 1; int row = 1;
string[] sectionNames = { "User ", "Description ", "Time (h) ", "Time (decimal) " }; string[] sectionNames = { "User ", "Description ", "Time (h) ", "Time (decimal) " };
decimal totalAmountSum = 0;
List<string> usersDecimalHours = new List<string>(); List<string> usersDecimalHours = new List<string>();


for (int i = 0; i < sectionNames.Length; i++) for (int i = 0; i < sectionNames.Length; i++)

+ 1
- 1
ClockifyReport/ClockifyReport.csproj View File

<ItemGroup> <ItemGroup>
<PackageReference Include="Azure.Storage.Blobs" Version="12.12.0" /> <PackageReference Include="Azure.Storage.Blobs" Version="12.12.0" />
<PackageReference Include="Azure.Storage.Queues" Version="12.10.0" /> <PackageReference Include="Azure.Storage.Queues" Version="12.10.0" />
<PackageReference Include="FreeSpire.XLS" Version="12.7.0" />
<PackageReference Include="MailKit" Version="3.3.0" /> <PackageReference Include="MailKit" Version="3.3.0" />
<PackageReference Include="Microsoft.AspNet.WebApi.Client" Version="5.2.9" /> <PackageReference Include="Microsoft.AspNet.WebApi.Client" Version="5.2.9" />
<PackageReference Include="Microsoft.AspNetCore.Mvc.Abstractions" Version="2.2.0" /> <PackageReference Include="Microsoft.AspNetCore.Mvc.Abstractions" Version="2.2.0" />
<PackageReference Include="Microsoft.Azure.WebJobs.Extensions.SendGrid" Version="3.0.2" /> <PackageReference Include="Microsoft.Azure.WebJobs.Extensions.SendGrid" Version="3.0.2" />
<PackageReference Include="Microsoft.Build.Tasks.Core" Version="17.2.0" /> <PackageReference Include="Microsoft.Build.Tasks.Core" Version="17.2.0" />
<PackageReference Include="RestSharp" Version="108.0.1" /> <PackageReference Include="RestSharp" Version="108.0.1" />
<PackageReference Include="Spire.XLS" Version="12.7.1" />
<PackageReference Include="System.Core" Version="3.5.21022.801" /> <PackageReference Include="System.Core" Version="3.5.21022.801" />
<PackageReference Include="System.Drawing.Common" Version="6.0.0" /> <PackageReference Include="System.Drawing.Common" Version="6.0.0" />
<PackageReference Include="System.IO.Packaging" Version="6.0.0" /> <PackageReference Include="System.IO.Packaging" Version="6.0.0" />

+ 1
- 1
ClockifyReport/Function3.cs View File

[Function("Function3")] [Function("Function3")]
public void Run([BlobTrigger("report-container/{name}", Connection = "AzureWebJobsStorage")] byte[] fileData, string name, ILogger log) public void Run([BlobTrigger("report-container/{name}", Connection = "AzureWebJobsStorage")] byte[] fileData, string name, ILogger log)
{ {
string fileName = string.Format($"BlackRockReport_{DateTime.Now.ToString("f")}.xlsx");
string fileName = string.Format($"BlackRockReport_{DateTime.Now.ToString("f")}.xls");


var client = new RestClient("https://api.mailgun.net/v3"); var client = new RestClient("https://api.mailgun.net/v3");
client.Authenticator = new HttpBasicAuthenticator("api", MailGunApiKey); client.Authenticator = new HttpBasicAuthenticator("api", MailGunApiKey);

Loading…
Cancel
Save