/
fat_free_crm.rb
executable file
·42 lines (36 loc) · 1.67 KB
/
fat_free_crm.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# Fat Free CRM
# Copyright (C) 2008-2010 by Michael Dvorkin
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http:#www.gnu.org/licenses/>.
#------------------------------------------------------------------------------
if RUBY_VERSION.start_with?("1.9") && ActiveRecord::Base.connection.adapter_name.downcase == "mysql"
require "fat_free_crm/mysql_utf8.rb"
end
require "fat_free_crm/version"
require "fat_free_crm/core_ext"
require "fat_free_crm/exceptions"
require "fat_free_crm/i18n"
require "fat_free_crm/permissions"
require "fat_free_crm/sortable"
require "fat_free_crm/tabs"
require "fat_free_crm/callback"
require "fat_free_crm/plugin"
require "fat_free_crm/plugin_views"
ActionView::Base.send(:include, FatFreeCRM::I18n)
ActionController::Base.send(:include, FatFreeCRM::I18n)
ActionView::Base.send(:include, FatFreeCRM::Callback::Helper)
ActionController::Base.send(:include, FatFreeCRM::Callback::Helper)
ActiveRecord::Base.send(:include, FatFreeCRM::Permissions)
ActiveRecord::Base.send(:include, FatFreeCRM::Sortable)
Rails::Plugin::Loader.send(:include, FatFreeCRM::PrependEngineViews)