Commit a038fff3 authored by Savorboard's avatar Savorboard

renamed file.

parent 9f6b0e5d
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Text; using System.Text;
using DotNetCore.CAP.Processor.States; using DotNetCore.CAP.Infrastructure;
namespace DotNetCore.CAP.Dashboard namespace DotNetCore.CAP.Dashboard
{ {
public static class JobHistoryRenderer public static class MessageHistoryRenderer
{ {
private static readonly IDictionary<string, Func<HtmlHelper, IDictionary<string, string>, NonEscapedString>> private static readonly IDictionary<string, Func<HtmlHelper, IDictionary<string, string>, NonEscapedString>>
Renderers = new Dictionary<string, Func<HtmlHelper, IDictionary<string, string>, NonEscapedString>>(); Renderers = new Dictionary<string, Func<HtmlHelper, IDictionary<string, string>, NonEscapedString>>();
...@@ -17,23 +17,23 @@ namespace DotNetCore.CAP.Dashboard ...@@ -17,23 +17,23 @@ namespace DotNetCore.CAP.Dashboard
= new Dictionary<string, string>(); = new Dictionary<string, string>();
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Performance", "CA1810:InitializeReferenceTypeStaticFieldsInline")] [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Performance", "CA1810:InitializeReferenceTypeStaticFieldsInline")]
static JobHistoryRenderer() static MessageHistoryRenderer()
{ {
Register(SucceededState.StateName, SucceededRenderer); Register(StatusName.Succeeded, SucceededRenderer);
Register(FailedState.StateName, FailedRenderer); Register(StatusName.Failed, FailedRenderer);
Register(ProcessingState.StateName, ProcessingRenderer); Register(StatusName.Processing, ProcessingRenderer);
BackgroundStateColors.Add(EnqueuedState.StateName, "#F5F5F5"); BackgroundStateColors.Add(StatusName.Enqueued, "#F5F5F5");
BackgroundStateColors.Add(SucceededState.StateName, "#EDF7ED"); BackgroundStateColors.Add(StatusName.Succeeded, "#EDF7ED");
BackgroundStateColors.Add(FailedState.StateName, "#FAEBEA"); BackgroundStateColors.Add(StatusName.Failed, "#FAEBEA");
BackgroundStateColors.Add(ProcessingState.StateName, "#FCEFDC"); BackgroundStateColors.Add(StatusName.Processing, "#FCEFDC");
BackgroundStateColors.Add(ScheduledState.StateName, "#E0F3F8"); BackgroundStateColors.Add(StatusName.Scheduled, "#E0F3F8");
ForegroundStateColors.Add(EnqueuedState.StateName, "#999"); ForegroundStateColors.Add(StatusName.Enqueued, "#999");
ForegroundStateColors.Add(SucceededState.StateName, "#5cb85c"); ForegroundStateColors.Add(StatusName.Succeeded, "#5cb85c");
ForegroundStateColors.Add(FailedState.StateName, "#d9534f"); ForegroundStateColors.Add(StatusName.Failed, "#d9534f");
ForegroundStateColors.Add(ProcessingState.StateName, "#f0ad4e"); ForegroundStateColors.Add(StatusName.Processing, "#f0ad4e");
ForegroundStateColors.Add(ScheduledState.StateName, "#5bc0de"); ForegroundStateColors.Add(StatusName.Scheduled, "#5bc0de");
} }
public static void AddBackgroundStateColor(string stateName, string color) public static void AddBackgroundStateColor(string stateName, string color)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment