2010-04-24 00:32:36 +00:00
|
|
|
%title= escape_once("#{Locomotive.config.name} — #{current_site.name}")
|
|
|
|
|
|
|
|
= csrf_meta_tag
|
|
|
|
|
2011-11-16 00:39:16 +00:00
|
|
|
- key = Rails.application.config.session_options[:key]
|
|
|
|
|
|
|
|
%meta{ :name => 'key-param', :content => Rails.application.config.session_options[:key] }
|
|
|
|
%meta{ :name => 'key-token', :content => cookies[key] }
|
|
|
|
|
2011-11-08 14:34:25 +00:00
|
|
|
= stylesheet_link_tag 'locomotive', :media => 'screen'
|
2011-11-10 01:43:19 +00:00
|
|
|
= javascript_include_tag 'locomotive'
|
2010-04-25 00:33:38 +00:00
|
|
|
|
2010-12-14 17:00:12 +00:00
|
|
|
/ [if IE]
|
2011-11-08 14:34:25 +00:00
|
|
|
= stylesheet_link_tag 'locomotive/ie', :media => 'screen'
|
2010-04-24 00:32:36 +00:00
|
|
|
|
2010-04-25 00:33:38 +00:00
|
|
|
%script{ :type => 'text/javascript' }
|
2011-11-10 01:43:19 +00:00
|
|
|
:plain
|
|
|
|
window.locale = '#{I18n.locale}';
|
|
|
|
|
|
|
|
Locomotive.current_site = new Locomotive.Models.Site(#{current_site.to_json});
|
|
|
|
Locomotive.current_account = new Locomotive.Models.Account(#{current_locomotive_account.to_json});
|
|
|
|
|
|
|
|
$(document).ready(function() {
|
|
|
|
|
|
|
|
window.application_view = new Locomotive.Views.ApplicationView({
|
2011-11-21 01:27:05 +00:00
|
|
|
flash: #{flash.to_json},
|
|
|
|
view: #{backbone_view_class_name},
|
|
|
|
view_data: #{backbone_view_data}
|
2011-11-10 01:43:19 +00:00
|
|
|
});
|
|
|
|
window.application_view.render();
|
|
|
|
|
|
|
|
});
|
2010-04-24 00:32:36 +00:00
|
|
|
|
|
|
|
= yield :head
|