Commit 38a9fc4f4701ff3f2d1a06e8567f45d1bb9fb9c6

Authored by Dmitriy Zaporozhets
1 parent 5a211152

Classic (mars) theme will be default for 6.0

Showing 2 changed files with 12 additions and 5 deletions   Show diff stats
app/models/user.rb
... ... @@ -205,6 +205,7 @@ class User < ActiveRecord::Base
205 205 u.projects_limit = Gitlab.config.gitlab.default_projects_limit
206 206 u.can_create_group = Gitlab.config.gitlab.default_can_create_group
207 207 u.can_create_team = Gitlab.config.gitlab.default_can_create_team
  208 + u.theme_id = Gitlab::Theme::MARS
208 209 end
209 210 end
210 211  
... ...
lib/gitlab/theme.rb
1 1 module Gitlab
2 2 class Theme
  3 + BASIC = 1
  4 + MARS = 2
  5 + MODERN = 3
  6 + GRAY = 4
  7 + COLOR = 5
  8 +
3 9 def self.css_class_by_id(id)
4 10 themes = {
5   - 1 => "ui_basic",
6   - 2 => "ui_mars",
7   - 3 => "ui_modern",
8   - 4 => "ui_gray",
9   - 5 => "ui_color"
  11 + BASIC => "ui_basic",
  12 + MARS => "ui_mars",
  13 + MODERN => "ui_modern",
  14 + GRAY => "ui_gray",
  15 + COLOR => "ui_color"
10 16 }
11 17  
12 18 id ||= 1
... ...