dhatu 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/dhatu/blog_posts_controller.rb +1 -1
- data/app/controllers/dhatu/bookings_controller.rb +1 -1
- data/app/controllers/dhatu/branches_controller.rb +1 -1
- data/app/controllers/dhatu/categories_controller.rb +7 -6
- data/app/controllers/dhatu/events_controller.rb +1 -1
- data/app/controllers/dhatu/offers_controller.rb +1 -1
- data/app/controllers/dhatu/pages_controller.rb +1 -1
- data/app/controllers/dhatu/photo_albums_controller.rb +172 -0
- data/app/controllers/dhatu/prices_controller.rb +1 -1
- data/app/controllers/dhatu/projects_controller.rb +1 -1
- data/app/controllers/dhatu/promotion_enquiries_controller.rb +1 -1
- data/app/controllers/dhatu/promotions_controller.rb +1 -1
- data/app/controllers/dhatu/sections_controller.rb +2 -2
- data/app/controllers/dhatu/services_controller.rb +1 -1
- data/app/controllers/dhatu/team_members_controller.rb +1 -1
- data/app/controllers/dhatu/testimonials_controller.rb +1 -1
- data/app/models/dhatu/photo_album.rb +172 -0
- data/app/views/dhatu/categories/_header.html.erb +86 -0
- data/app/views/dhatu/categories/_index.html.erb +0 -91
- data/app/views/dhatu/categories/_row.html.erb +13 -8
- data/app/views/dhatu/categories/index.html.erb +6 -1
- data/app/views/dhatu/dashboard/_index.html.erb +6 -0
- data/app/views/dhatu/pages/_index.html.erb +4 -27
- data/app/views/dhatu/pages/_row.html.erb +3 -21
- data/app/views/dhatu/pages/index.html.erb +7 -6
- data/app/views/dhatu/photo_albums/_form.html.erb +38 -0
- data/app/views/dhatu/photo_albums/_header.html.erb +70 -0
- data/app/views/dhatu/photo_albums/_index.html.erb +44 -0
- data/app/views/dhatu/photo_albums/_row.html.erb +28 -0
- data/app/views/dhatu/photo_albums/_show.html.erb +145 -0
- data/app/views/dhatu/photo_albums/index.html.erb +34 -0
- data/app/views/dhatu/sections/_index.html.erb +29 -53
- data/app/views/dhatu/sections/_row.html.erb +9 -25
- data/app/views/dhatu/sections_old/_form.html.erb +171 -0
- data/app/views/dhatu/sections_old/_index.html.erb +53 -0
- data/app/views/dhatu/sections_old/_row.html.erb +26 -0
- data/app/views/dhatu/sections_old/_show.html.erb +208 -0
- data/app/views/dhatu/sections_old/index.html.erb +52 -0
- data/app/views/layouts/kuppayam/_sidebar.html.erb +6 -0
- data/config/routes.rb +9 -0
- data/db/migrate/20180101093437_create_photo_albums.rb +24 -0
- data/lib/dhatu/version.rb +1 -1
- data/spec/dummy/spec/factories/photo_album.rb +28 -0
- metadata +18 -4
- data/app/views/dhatu/categories/_index_list.html.erb +0 -118
- data/app/views/dhatu/categories/_row_list.html.erb +0 -34
@@ -1,118 +0,0 @@
|
|
1
|
-
<div id="div_category_action_buttons">
|
2
|
-
<div class="row">
|
3
|
-
<div class="col-md-6">
|
4
|
-
|
5
|
-
<%#= theme_button('Back to Category Types', 'arrow-left', choose_category_type_path, classes: "pull-left mr-10", btn_type: "white", remote: false) %>
|
6
|
-
|
7
|
-
<% if @current_category %>
|
8
|
-
<%= theme_button('Back', 'arrow-left', categories_path(parent_id: @current_category.try(:parent_id), category_type: @category_type), classes: "pull-left mr-10", btn_type: "white") %>
|
9
|
-
<% end %>
|
10
|
-
|
11
|
-
<%= theme_button('Refresh', 'refresh', categories_path(parent_id: @current_category.try(:id), category_type: @feature.try(:name)), classes: "pull-left mr-10", btn_type: "white") %>
|
12
|
-
|
13
|
-
<% if @current_user.has_create_permission?(Dhatu::Category) %>
|
14
|
-
<%= theme_button('Add a Category', 'plus', new_category_path(parent_id: @current_category.try(:id), category_type: @feature.try(:name)), classes: "pull-left mr-10", btn_type: "success") %>
|
15
|
-
<% end %>
|
16
|
-
|
17
|
-
</div>
|
18
|
-
<div class="col-md-6">
|
19
|
-
<%= search_form_kuppayam(Dhatu::Category, categories_path, text: @filters[:query]) %>
|
20
|
-
</div>
|
21
|
-
</div>
|
22
|
-
</div>
|
23
|
-
<%= clear_tag(10) %>
|
24
|
-
|
25
|
-
<div class="row">
|
26
|
-
<div class="col-md-3">
|
27
|
-
<% @filter_ui_settings.each do |filter_name, options| %>
|
28
|
-
<% if options[:object_filter] == true %>
|
29
|
-
<%= report_object_filter(filter_name, options) %>
|
30
|
-
<% else %>
|
31
|
-
<%= report_filter(filter_name, options) %>
|
32
|
-
<% end %>
|
33
|
-
<% end %>
|
34
|
-
</div>
|
35
|
-
<div class="col-md-9" id="div_category_breadcrumbs">
|
36
|
-
<% c_list = [] %>
|
37
|
-
<% c = @current_category %>
|
38
|
-
<% while c do %>
|
39
|
-
<% c_list << c %>
|
40
|
-
<% c = c.parent %>
|
41
|
-
<% end %>
|
42
|
-
|
43
|
-
<% if c_list.count >= 1 %>
|
44
|
-
<ol class="breadcrumb auto-hidden1 bc-3">
|
45
|
-
<% c_list.reverse.each do |c| %>
|
46
|
-
<% if c_list[0] == c %>
|
47
|
-
<li class="active"><strong><%= c.display_name %></strong></li>
|
48
|
-
<% else %>
|
49
|
-
<li><%= link_to c.display_name, categories_path(parent_id: c.id), remote: true, class: "collapsed" %></li>
|
50
|
-
<% end %>
|
51
|
-
<% end %>
|
52
|
-
</ol>
|
53
|
-
<% end %>
|
54
|
-
</div>
|
55
|
-
</div>
|
56
|
-
|
57
|
-
<%= clear_tag %>
|
58
|
-
|
59
|
-
<div class="table-responsive">
|
60
|
-
<table class="table table-hover members-table middle-align">
|
61
|
-
<thead>
|
62
|
-
<tr>
|
63
|
-
<th style="text-align: center;width:60px" class="hidden-sm hidden-xs">#</th>
|
64
|
-
<th>Category</th>
|
65
|
-
<% if display_manage_links? %>
|
66
|
-
<th style="text-align: center;" colspan="2" class="hidden-sm hidden-xs">Actions</th>
|
67
|
-
<% end %>
|
68
|
-
</tr>
|
69
|
-
</thead>
|
70
|
-
<tbody>
|
71
|
-
<% @categories.each_with_index do |category, i| %>
|
72
|
-
<tr id="tr_category_<%= category.id %>">
|
73
|
-
|
74
|
-
<th scope="row" style="text-align: center;" class="hidden-sm hidden-xs">
|
75
|
-
<% if i < 0 %>
|
76
|
-
<i class="fa fa-check text-success"></i>
|
77
|
-
<% else %>
|
78
|
-
<%= i + 1 + (@per_page.to_i * (@current_page.to_i - 1)) %>
|
79
|
-
<% end %>
|
80
|
-
</th>
|
81
|
-
|
82
|
-
<% if category.end_node? %>
|
83
|
-
<td class="category-name">
|
84
|
-
<%= content_tag :span, category.display_name, style: ";font-size:14px;" %>
|
85
|
-
<%= display_publishable_status(category) %>
|
86
|
-
<div class="badge">Priority: <%= category.priority %></div><br>
|
87
|
-
<%= content_tag :span, category.display_category_type, style: "color: #ffba00;" %>
|
88
|
-
</td>
|
89
|
-
<% else %>
|
90
|
-
<td class="category-name">
|
91
|
-
<%= link_to raw("<i class=\"fa fa-caret-right\"></i> #{category.display_name}"), categories_path(parent_id: category.id, category_type: @category_type), remote: true, style: "font-weight:bold;font-size:14px;" %>
|
92
|
-
<%= display_publishable_status(category) %>
|
93
|
-
<div class="badge">Priority: <%= category.priority %></div><br>
|
94
|
-
<%= content_tag :span, category.display_category_type, style: "color: #ffba00;" %>
|
95
|
-
</td>
|
96
|
-
<% end %>
|
97
|
-
|
98
|
-
<% if display_manage_links? %>
|
99
|
-
<td class="action-links hidden-sm hidden-xs" style="width:10%"><%= display_publishable_links(category) %></td>
|
100
|
-
|
101
|
-
<td class="action-links hidden-sm hidden-xs" style="width:10%">
|
102
|
-
<%= link_to raw("<i class=\"linecons-desktop\"></i> View Details"), category_path(category), :remote=>true, style: "color:#40bbea" %>
|
103
|
-
<%= display_manage_links(category, @current_user) %>
|
104
|
-
</td>
|
105
|
-
<% end %>
|
106
|
-
|
107
|
-
</tr>
|
108
|
-
<% end %>
|
109
|
-
</tbody>
|
110
|
-
</table>
|
111
|
-
</div>
|
112
|
-
|
113
|
-
<div class="row">
|
114
|
-
<div class="col-sm-12">
|
115
|
-
<%= paginate_kuppayam(@categories) %>
|
116
|
-
</div>
|
117
|
-
</div>
|
118
|
-
|
@@ -1,34 +0,0 @@
|
|
1
|
-
<tr id="tr_category_<%= category.id %>">
|
2
|
-
|
3
|
-
<th scope="row" style="text-align: center;">
|
4
|
-
<% if i < 0 %>
|
5
|
-
<i class="fa fa-check text-success"></i>
|
6
|
-
<% else %>
|
7
|
-
<%= i + 1 + (@per_page.to_i * (@current_page.to_i - 1)) %>
|
8
|
-
<% end %>
|
9
|
-
</th>
|
10
|
-
|
11
|
-
<% if category.end_node? %>
|
12
|
-
<td class="category-name">
|
13
|
-
<%= link_to category.display_name, "#", remote: true, style: ";font-size:14px;" %> - <%= category.display_category_type %><br>
|
14
|
-
<%= display_publishable_status(category) %>
|
15
|
-
<div class="badge">Priority: <%= category.priority %></div>
|
16
|
-
</td>
|
17
|
-
<% else %>
|
18
|
-
<td class="category-name">
|
19
|
-
<%= link_to raw("<i class=\"fa fa-caret-right\"></i> #{category.display_name}"), categories_path(parent_id: category.id, category_type: @category_type), remote: true, style: "font-weight:bold;font-size:14px;" %> - <%= category.display_category_type %><br>
|
20
|
-
<%= display_publishable_status(category) %>
|
21
|
-
<div class="badge">Priority: <%= category.priority %></div>
|
22
|
-
</td>
|
23
|
-
<% end %>
|
24
|
-
|
25
|
-
<% if display_manage_links? %>
|
26
|
-
<td class="action-links hidden-sm hidden-xs" style="width:10%"><%= display_publishable_links(category) %></td>
|
27
|
-
|
28
|
-
<td class="action-links hidden-sm hidden-xs" style="width:10%">
|
29
|
-
<%= link_to raw("<i class=\"linecons-desktop\"></i> View Details"), category_path(category), :remote=>true, style: "color:#40bbea" %>
|
30
|
-
<%= display_manage_links(category, @current_user) %>
|
31
|
-
</td>
|
32
|
-
<% end %>
|
33
|
-
|
34
|
-
</tr>
|