fix column width and plugin styles

This commit is contained in:
Lee Lawlor 2014-10-15 21:47:51 -04:00
parent ee05bbd102
commit 75ac3db89a
6 changed files with 143 additions and 135 deletions

View File

@ -4,9 +4,11 @@
<h4 class="breadcrumb"><%= t(:watched_channels) %></h4>
<% if @channels.empty? %>
<%= t(:watched_empty) %>
<br><br>
<%= link_to t(:watched_find), public_channels_path %>
<div class="col-pad">
<%= t(:watched_empty) %>
<br><br>
<%= link_to t(:watched_find), public_channels_path %>
</div>
<% else %>
<%= render :partial => 'list' %>
<% end %>

View File

@ -18,24 +18,12 @@
<ol class="breadcrumb" data-no-turbolink>
<li><%= link_to t(:plugins), plugins_path %></li>
<li><%= link_to plugin_path(@plugin.id) do %><%= t(:plugin) %> <%= @plugin.id %><% end %></li>
<li><%= link_to plugin_path(@plugin.id), target: '_blank' do %><%= t(:plugin) %> <%= @plugin.id %><% end %></li>
<li class="active"><%= t(:edit) %></li>
</ol>
<%= form_for @plugin, :html => {:method => 'put', :class => 'form-horizontal'} do |c| %>
<%= error_messages_for 'plugin', :header_message => t(:try_again), :message => t(:plugin_error) %>
<input name='userlogin' class='userlogin' />
<div class="form-group">
<div class="col-sm-offset-2 col-sm-10 col-xs-12">
<div class="checkbox">
<label>
<%= c.check_box :private_flag %>
<%= t(:plugin_private_flag) %>
</label>
</div>
</div>
</div>
<div class="form-group">
<label class="col-sm-2 col-xs-12 control-label"><%= t(:plugin_name) %></label>
@ -57,6 +45,17 @@
<div class="col-sm-10 col-xs-12"><%= c.text_area :js, :class => 'form-control', :rows => 14 %></div>
</div>
<div class="form-group">
<div class="col-sm-offset-2 col-sm-10 col-xs-12">
<div class="checkbox">
<label>
<%= c.check_box :private_flag %>
<b><%= t(:plugin_private_flag) %></b>
</label>
</div>
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label"></label>
<div class="col-sm-10"><p class="form-control-static"><%= c.submit t(:plugin_save), :class => 'btn btn-primary' %></p></div>

View File

@ -3,40 +3,43 @@
<h4 class='breadcrumb'><%= t(:plugins) %></h4>
<%= link_to t(:plugin_new), new_plugin_path, class: 'btn btn-primary' %>
<br><br>
<div class="col-pad">
<% if @plugins.length > 0 %>
<table class="table table-striped table-bordered tablesorter">
<thead>
<tr>
<th><%= t(:plugin_name) %> <i class="fa fa-unsorted"></i></th>
<th><%= t(:created) %> <i class="fa fa-unsorted"></i></td>
</tr>
</thead>
<tbody>
<% @plugins.each do |p| %>
<tr>
<td>
<h4 style="margin-top: 0;">
<a href="<%= plugin_path(p.id) %>" target="_blank">
<i class="fa fa-<%= 'un' if p.private_flag != true %>lock fa-fw"></i>
<%= p.name %>
</a>
</h4>
<div class="btn-group btn-group-sm">
<%= link_to T(:view), plugin_path(p.id), :target => '_blank', class: 'btn btn-default' %>
<%= link_to T(:edit), edit_plugin_path(p.id), class: 'btn btn-default', 'data-no-turbolink' => 'true' %>
</div>
</td>
<td><%= p.created_at.strftime("%Y-%m-%d") %></td>
</tr>
<% end %>
</tbody>
<%= link_to t(:plugin_new), new_plugin_path, class: 'btn btn-primary' %>
<br><br>
</table>
<% end %>
<% if @plugins.length > 0 %>
<table class="table table-striped table-bordered tablesorter">
<thead>
<tr>
<th><%= t(:plugin_name) %> <i class="fa fa-unsorted"></i></th>
<th><%= t(:created) %> <i class="fa fa-unsorted"></i></td>
</tr>
</thead>
<tbody>
<% @plugins.each do |p| %>
<tr>
<td>
<h4 style="margin-top: 0;">
<a href="<%= plugin_path(p.id) %>" target="_blank">
<i class="fa fa-<%= 'un' if p.private_flag != true %>lock fa-fw"></i>
<%= p.name %>
</a>
</h4>
<div class="btn-group btn-group-sm">
<%= link_to T(:view), plugin_path(p.id), :target => '_blank', class: 'btn btn-default' %>
<%= link_to T(:edit), edit_plugin_path(p.id), class: 'btn btn-default', 'data-no-turbolink' => 'true' %>
</div>
</td>
<td><%= p.created_at.strftime("%Y-%m-%d") %></td>
</tr>
<% end %>
</tbody>
</table>
<% end %>
</div>
</div>
<div id="sidebar" class="col-xs-12 col-sm-6">

View File

@ -6,44 +6,45 @@
<li class="active"><%= t(:new) %></li>
</ol>
<h3><%= t(:plugin_new) %></h3>
<br>
<div><%= t(:plugin_new_message) %></div>
<br>
<div class="col-pad">
<h3><%= t(:plugin_new) %></h3>
<br>
<div><%= t(:plugin_new_message) %></div>
<br>
<%= form_for Plugin.new, :html => {:class => 'form-horizontal'} do |f| %>
<div class="form-group">
<label class="col-sm-3 col-xs-12 control-label"><%= t(:plugin_template) %></label>
<div class="col-sm-9 col-xs-12">
<div class="radio">
<label>
<%= radio_button_tag :template, 'default', :checked => 'checked' %> <%= T(:default) %>
</label>
</div>
<div class="radio">
<label>
<%= radio_button_tag :template, 'gauge' %> Google Gauge
</label>
</div>
<div class="radio">
<label>
<%= radio_button_tag :template, 'chart' %> <%= t(:plugin_chart) %>
</label>
<%= form_for Plugin.new, :html => {:class => 'form-horizontal'} do |f| %>
<div class="form-group">
<label class="col-sm-3 col-xs-12 control-label"><%= t(:plugin_template) %></label>
<div class="col-sm-9 col-xs-12">
<div class="radio">
<label>
<%= radio_button_tag :template, 'default', :checked => 'checked' %> <%= T(:default) %>
</label>
</div>
<div class="radio">
<label>
<%= radio_button_tag :template, 'gauge' %> Google Gauge
</label>
</div>
<div class="radio">
<label>
<%= radio_button_tag :template, 'chart' %> <%= t(:plugin_chart) %>
</label>
</div>
</div>
</div>
</div>
<div class="form-group">
<div class="col-sm-offset-3 col-sm-9">
<p class="form-control-static">
<%= f.submit t(:plugin_create), :class => 'btn btn-primary' %>
</p>
<div class="form-group">
<div class="col-sm-offset-3 col-sm-9">
<p class="form-control-static">
<%= f.submit t(:plugin_create), :class => 'btn btn-primary' %>
</p>
</div>
</div>
</div>
<% end %>
<br>
<% end %>
<br>
</div>
</div>
<div id="sidebar" class="col-xs-12 col-sm-6">

View File

@ -6,45 +6,47 @@
<li class="active"><%= t(:account_edit) %></li>
</ol>
<%= form_for @user, :url => account_path, :html => {:class => 'form-horizontal'} do |f| %>
<%= error_messages_for 'user', :header_message => t(:try_again), :message => t(:account_error_edit) %>
<input name='userlogin' class='userlogin' />
<div class="col-pad">
<%= form_for @user, :url => account_path, :html => {:class => 'form-horizontal'} do |f| %>
<%= error_messages_for 'user', :header_message => t(:try_again), :message => t(:account_error_edit) %>
<input name='userlogin' class='userlogin' />
<div class="form-group">
<label class="col-sm-4 col-xs-4 control-label"><%= t(:userid) %></label>
<div class="col-sm-8 col-xs-8"><%= f.text_field :login, :class => 'form-control' %></div>
</div>
<div class="form-group">
<label class="col-sm-4 col-xs-4 control-label"><%= t(:email) %></label>
<div class="col-sm-8 col-xs-8"><%= f.text_field :email, :class => 'form-control' %></div>
</div>
<div class="form-group">
<label class="col-sm-4 col-xs-4 control-label"><%= t(:time_zone) %></label>
<div class="col-sm-8 col-xs-8">
<p class="form-control-static">
<%= time_zone_select 'user', 'time_zone', nil, {:default => 'Eastern Time (US & Canada)'}, {:class => 'form-control'} %>
</p>
<div class="form-group">
<label class="col-sm-4 col-xs-4 control-label"><%= t(:userid) %></label>
<div class="col-sm-8 col-xs-8"><%= f.text_field :login, :class => 'form-control' %></div>
</div>
</div>
<div class="form-group">
<label class="col-sm-4 col-xs-4 control-label"><%= t(:password_change) %></label>
<div class="col-sm-8 col-xs-8"><%= f.password_field :password, :class => 'form-control' %></div>
</div>
<div class="form-group">
<label class="col-sm-4 col-xs-4 control-label"><%= t(:email) %></label>
<div class="col-sm-8 col-xs-8"><%= f.text_field :email, :class => 'form-control' %></div>
</div>
<div class="form-group">
<label class="col-sm-4 col-xs-4 control-label"><%= t(:password_current) %></label>
<div class="col-sm-8 col-xs-8"><%= f.password_field :password_current, :class => 'form-control' %></div>
</div>
<div class="form-group">
<label class="col-sm-4 col-xs-4 control-label"><%= t(:time_zone) %></label>
<div class="col-sm-8 col-xs-8">
<p class="form-control-static">
<%= time_zone_select 'user', 'time_zone', nil, {:default => 'Eastern Time (US & Canada)'}, {:class => 'form-control'} %>
</p>
</div>
</div>
<div class="form-group">
<div class="col-sm-offset-4 col-sm-8 col-xs-offset-4 col-xs-8"><p class="form-control-static"><%= f.submit t(:account_update), :class => 'btn btn-primary' %></p></div>
</div>
<div class="form-group">
<label class="col-sm-4 col-xs-4 control-label"><%= t(:password_change) %></label>
<div class="col-sm-8 col-xs-8"><%= f.password_field :password, :class => 'form-control' %></div>
</div>
<% end %>
<div class="form-group">
<label class="col-sm-4 col-xs-4 control-label"><%= t(:password_current) %></label>
<div class="col-sm-8 col-xs-8"><%= f.password_field :password_current, :class => 'form-control' %></div>
</div>
<div class="form-group">
<div class="col-sm-offset-4 col-sm-8 col-xs-offset-4 col-xs-8"><p class="form-control-static"><%= f.submit t(:account_update), :class => 'btn btn-primary' %></p></div>
</div>
<% end %>
</div>
</div>
</div>

View File

@ -5,39 +5,40 @@
<li class="active"><%= t(:profile_edit) %></li>
</ol>
<div class="col-pad">
<%= form_for @user, :url => update_profile_path, :html => {:class => 'form-horizontal'} do |f| %>
<input name='userlogin' class='userlogin' />
<%= form_for @user, :url => update_profile_path, :html => {:class => 'form-horizontal'} do |f| %>
<input name='userlogin' class='userlogin' />
<div class="form-group">
<div class="col-sm-offset-4 col-sm-8 col-xs-offset-3 col-xs-6">
<div class="checkbox">
<label>
<%= f.check_box :public_flag %>
<%= t(:public) %>
</label>
<div class="form-group">
<div class="col-sm-offset-4 col-sm-8 col-xs-offset-3 col-xs-6">
<div class="checkbox">
<label>
<%= f.check_box :public_flag %>
<%= t(:public) %>
</label>
</div>
</div>
</div>
</div>
<div class="form-group">
<label class="col-sm-4 col-xs-3 control-label"><%= t(:profile_website) %></label>
<div class="col-sm-8 col-xs-6"><%= f.text_field :website, :class => 'form-control' %></div>
</div>
<div class="form-group">
<label class="col-sm-4 col-xs-3 control-label"><%= t(:profile_website) %></label>
<div class="col-sm-8 col-xs-6"><%= f.text_field :website, :class => 'form-control' %></div>
</div>
<div class="form-group">
<label class="col-sm-4 col-xs-3 control-label"><%= t(:profile_bio) %></label>
<div class="col-sm-8 col-xs-6"><%= f.text_area :bio, :class => 'form-control', :rows => 4 %></div>
</div>
<div class="form-group">
<label class="col-sm-4 col-xs-3 control-label"><%= t(:profile_bio) %></label>
<div class="col-sm-8 col-xs-6"><%= f.text_area :bio, :class => 'form-control', :rows => 4 %></div>
</div>
<div class="form-group">
<label class="col-sm-4 control-label"></label>
<div class="col-sm-8"><p class="form-control-static"><%= f.submit t(:profile_update), :class => 'btn btn-primary' %></p></div>
</div>
<div class="form-group">
<label class="col-sm-4 control-label"></label>
<div class="col-sm-8"><p class="form-control-static"><%= f.submit t(:profile_update), :class => 'btn btn-primary' %></p></div>
</div>
<% end %>
<% end %>
</div>
</div>