From b1400bcb684c43790dd38628b6c131e9e7c4d400 Mon Sep 17 00:00:00 2001 From: Jesse Plamondon-Willard Date: Wed, 27 Nov 2019 21:49:36 -0500 Subject: fallback to Amazon S3 if saving a log to Pastebin fails --- src/SMAPI.Web/Views/LogParser/Index.cshtml | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) (limited to 'src/SMAPI.Web/Views/LogParser/Index.cshtml') diff --git a/src/SMAPI.Web/Views/LogParser/Index.cshtml b/src/SMAPI.Web/Views/LogParser/Index.cshtml index f98ffdf9..df2ac115 100644 --- a/src/SMAPI.Web/Views/LogParser/Index.cshtml +++ b/src/SMAPI.Web/Views/LogParser/Index.cshtml @@ -1,3 +1,4 @@ +@using Humanizer @using Newtonsoft.Json @using StardewModdingAPI.Toolkit.Utilities @using StardewModdingAPI.Web.Framework.LogParsing.Models @@ -18,7 +19,7 @@ { } - + @@ -62,6 +63,18 @@ else if (Model.ParsedLog?.IsValid == true) } +@* save warnings *@ +@if (Model.UploadWarning != null || Model.Expiry != null) +{ +
+ @if (Model.Expiry != null) + { + This log will expire in @((DateTime.UtcNow - Model.Expiry.Value).Humanize()). + } + +
+} + @* upload new log *@ @if (Model.ParsedLog == null) { @@ -71,7 +84,7 @@ else if (Model.ParsedLog?.IsValid == true) @foreach (Platform platform in new[] { Platform.Android, Platform.Linux, Platform.Mac, Platform.Windows }) {
  • - +
  • } @@ -151,7 +164,7 @@ else if (Model.ParsedLog?.IsValid == true)
    @foreach (LogModInfo contentPack in contentPackList.Where(pack => pack.HasUpdate)) { - + @contentPack.Name
    + + @contentPack.Name
    }
    } @@ -173,7 +186,7 @@ else if (Model.ParsedLog?.IsValid == true)
    @foreach (LogModInfo contentPack in contentPackList.Where(pack => pack.HasUpdate)) { - @contentPack.Version → @contentPack.UpdateVersion
    + @contentPack.Version → @contentPack.UpdateVersion
    }
    } -- cgit