redde 0.0.4 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +2 -0
- data/lib/generators/redde/layout/templates/assets/javascripts/admin.js +1 -1
- data/lib/generators/redde/layout/templates/helpers/admin_helper.rb +2 -2
- data/lib/generators/redde/layout/templates/shared/_launchbar.html.haml +2 -2
- data/lib/generators/redde/layout/templates/shared/_sidebar.html.haml +0 -14
- data/lib/generators/redde/scaffold/templates/edit.html.haml +2 -2
- data/lib/generators/redde/scaffold/templates/index.html.haml +1 -1
- data/lib/redde/version.rb +1 -1
- metadata +2 -2
data/Gemfile
CHANGED
@@ -1,5 +1,5 @@
|
|
1
|
-
- @active = :shop if (["products"
|
2
|
-
- @active = :materials if (["articles"
|
1
|
+
- @active = :shop if (["products"].include? controller.controller_name)
|
2
|
+
- @active = :materials if (["articles"].include? controller.controller_name)
|
3
3
|
- @active = :system if ["users"].include? controller.controller_name
|
4
4
|
#launchbar
|
5
5
|
%ul.menus
|
@@ -3,21 +3,7 @@
|
|
3
3
|
-case @active
|
4
4
|
-when :shop then
|
5
5
|
%li{:class => "#{'active' if a == 'products'}"}= link_to "Товары", admin_products_path
|
6
|
-
%li{:class => "#{'active' if a == 'categories'}"}= link_to "Категории", admin_categories_path
|
7
|
-
%li{:class => "#{'active' if a == 'countries'}"}= link_to "Страны", admin_countries_path
|
8
|
-
%li{:class => "#{'active' if a == 'regions'}"}= link_to "Регионы", admin_regions_path
|
9
|
-
%li{:class => "#{'active' if a == 'brands'}"}= link_to "Производители", [:admin, :brands]
|
10
|
-
%li{:class => "#{'active' if a == 'sliders' && params[:slider_block] == "1"}"}= link_to "Слайдер", admin_sliders_path(slider_block: 1)
|
11
|
-
%li{:class => "#{'active' if a == 'sliders' && params[:slider_block] == "3"}"}= link_to "Баннеры (маленькие)", admin_sliders_path(slider_block: 3)
|
12
|
-
%li{:class => "#{'active' if a == 'orders'}"}= link_to "Заказы", [:admin, :orders]
|
13
|
-
|
14
|
-
|
15
6
|
-when :materials then
|
16
7
|
%li{:class => "#{'active' if a == 'articles'}"}= link_to "Статьи", [:admin, :articles]
|
17
|
-
%li{:class => "#{'active' if a == 'categories'}"}= link_to "Категории", [:admin, :categories]
|
18
|
-
%li{:class => "#{'active' if a == 'works'}"}= link_to "Портфолио", [:admin, :works]
|
19
|
-
|
20
|
-
|
21
|
-
|
22
8
|
-when :system
|
23
9
|
%li{:class => "#{'active' if a == 'users'}"}= link_to "Пользователи", admin_users_path
|
@@ -1,9 +1,9 @@
|
|
1
1
|
- content_for :page_header do
|
2
2
|
%h1
|
3
3
|
- if @<%= resource_name %>.new_record?
|
4
|
-
Добавить #{
|
4
|
+
Добавить #{taccusative(:<%= resource_name %>)}
|
5
5
|
- else
|
6
|
-
Редактировать #{
|
6
|
+
Редактировать #{taccusative(:<%= resource_name %>)}
|
7
7
|
|
8
8
|
= form_for [:admin, @<%= resource_name %>] do |f|
|
9
9
|
- if @<%= resource_name %>.errors.any?
|
@@ -1,6 +1,6 @@
|
|
1
1
|
- content_for(:page_header) do
|
2
2
|
%h1= tplural(<%= resource_name.capitalize %>)
|
3
|
-
%p= link_to "Добавить #{
|
3
|
+
%p= link_to "Добавить #{taccusative('<%= resource_name %>')}", [:new, :admin, :<%= resource_name %>]
|
4
4
|
|
5
5
|
- unless @<%= plural_resource_name %>.empty?
|
6
6
|
%table.list<%= ".sortable" if column_names.include?("position") %>
|
data/lib/redde/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: redde
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.5
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-
|
12
|
+
date: 2013-11-01 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: russian
|