use if
This commit is contained in:
@@ -4,8 +4,14 @@ define(["events", "globalize", "dom", "datetime", "userSettings", "serverNotific
|
||||
function getEntryHtml(entry, apiClient) {
|
||||
var html = "";
|
||||
html += '<div class="listItem listItem-border">';
|
||||
var color = "Error" == entry.Severity || "Fatal" == entry.Severity || "Warn" == entry.Severity ? "#cc0000" : "#00a4dc";
|
||||
var icon = "Error" == entry.Severity || "Fatal" == entry.Severity || "Warn" == entry.Severity ? "notification_important" : "notifications";
|
||||
if ("Error" == entry.Severity || "Fatal" == entry.Severity || "Warn" == entry.Severity) {
|
||||
var color = "#cc0000";
|
||||
var icon = "notification_important";
|
||||
}
|
||||
else {
|
||||
var color = "#00a4dc";
|
||||
var icon = "notifications";
|
||||
}
|
||||
if (entry.UserId && entry.UserPrimaryImageTag) {
|
||||
html += '<i class="listItemIcon md-icon" style="width:2em!important;height:2em!important;padding:0;color:transparent;background-color:' + color + ";background-image:url('" + apiClient.getUserImageUrl(entry.UserId, {
|
||||
type: "Primary",
|
||||
|
||||
Reference in New Issue
Block a user