2013-02-22 15:41:12 -05:00
|
|
|
/**
|
|
|
|
The default view in the admin section
|
2013-02-20 13:15:50 -05:00
|
|
|
|
2013-02-22 15:41:12 -05:00
|
|
|
@class AdminDashboardView
|
|
|
|
@extends Em.View
|
|
|
|
@namespace Discourse
|
|
|
|
@module Discourse
|
|
|
|
**/
|
|
|
|
Discourse.AdminDashboardView = Discourse.View.extend({
|
|
|
|
templateName: 'admin/templates/dashboard',
|
2013-02-21 14:09:28 -05:00
|
|
|
|
2013-02-22 15:41:12 -05:00
|
|
|
updateIconClasses: function() {
|
|
|
|
var classes;
|
|
|
|
classes = "icon icon-warning-sign ";
|
|
|
|
if (this.get('controller.versionCheck.critical_updates')) {
|
|
|
|
classes += "critical-updates-available";
|
|
|
|
} else {
|
|
|
|
classes += "updates-available";
|
|
|
|
}
|
|
|
|
return classes;
|
|
|
|
}.property('controller.versionCheck.critical_updates'),
|
2013-02-21 15:03:43 -05:00
|
|
|
|
2013-02-22 15:41:12 -05:00
|
|
|
priorityClass: function() {
|
|
|
|
if (this.get('controller.versionCheck.critical_updates')) {
|
|
|
|
return 'version-check critical';
|
|
|
|
}
|
|
|
|
return 'version-check normal';
|
|
|
|
}.property('controller.versionCheck.critical_updates')
|
|
|
|
});
|
2013-02-21 15:03:43 -05:00
|
|
|
|
2013-02-20 13:15:50 -05:00
|
|
|
|