tb_core 1.2.8 → 1.3.0.beta1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/javascripts/admin/core/application.js +1 -2
- data/app/assets/javascripts/admin/core/dashboard.js +1 -1
- data/app/assets/javascripts/admin/core/modal.js +4 -13
- data/app/assets/javascripts/admin/core/users.js +0 -120
- data/app/assets/stylesheets/admin/core/application.css.scss +106 -367
- data/app/assets/stylesheets/admin/core/login.css.scss +3 -29
- data/app/controllers/admin/application_controller.rb +1 -2
- data/app/controllers/admin/user_sessions_controller.rb +0 -3
- data/app/controllers/admin/users_controller.rb +3 -13
- data/app/controllers/password_resets_controller.rb +1 -0
- data/app/controllers/spud/application_controller.rb +8 -14
- data/app/controllers/user_sessions_controller.rb +1 -0
- data/app/helpers/admin/application_helper.rb +11 -15
- data/app/helpers/twice_baked/application_helper.rb +24 -1
- data/app/models/spud/spud_user_model.rb +7 -0
- data/app/views/admin/dashboard/index.html.erb +2 -4
- data/app/views/admin/password_resets/index.html.erb +4 -4
- data/app/views/admin/password_resets/show.html.erb +10 -9
- data/app/views/admin/roles/_form.html.erb +20 -22
- data/app/views/admin/roles/index.html.erb +23 -21
- data/app/views/admin/settings/_form.html.erb +36 -45
- data/app/views/admin/settings/edit.html.erb +1 -1
- data/app/views/admin/setup/new.html.erb +37 -46
- data/app/views/admin/user_sessions/new.html.erb +15 -12
- data/app/views/admin/users/_form.html.erb +16 -86
- data/app/views/admin/users/edit.html.erb +1 -1
- data/app/views/admin/users/index.html.erb +47 -27
- data/app/views/admin/users/new.html.erb +1 -1
- data/app/views/admin/users/show.html.erb +21 -31
- data/app/views/layouts/admin/_flashes.html.erb +19 -0
- data/app/views/layouts/admin/application.html.erb +39 -48
- data/app/views/layouts/admin/detail.html.erb +16 -30
- data/app/views/layouts/admin/error_page.html.erb +2 -1
- data/app/views/layouts/admin/login.html.erb +4 -11
- data/app/views/layouts/user_sessions.html.erb +6 -0
- data/app/views/password_resets/index.html.erb +4 -4
- data/app/views/password_resets/show.html.erb +7 -7
- data/app/views/user_sessions/new.html.erb +6 -6
- data/config/locales/en.yml +10 -0
- data/lib/generators/spud/module_generator.rb +6 -4
- data/lib/generators/spud/setup_generator.rb +7 -39
- data/lib/generators/spud/templates/assets/application.css.scss +5 -0
- data/lib/generators/spud/templates/assets/application.js +1 -0
- data/lib/generators/spud/templates/views/admin/_form.html.erb +7 -18
- data/lib/generators/spud/templates/views/admin/index.html.erb +39 -28
- data/lib/generators/spud/templates/views/admin/show.html.erb +6 -7
- data/lib/generators/spud/templates/views/frontend/index.html.erb +2 -1
- data/lib/generators/spud/templates/views/frontend/show.html.erb +6 -4
- data/lib/generators/spud/templates/views/layouts/application.html.erb +16 -6
- data/lib/spud_core/configuration.rb +1 -1
- data/lib/spud_core/engine.rb +9 -1
- data/lib/spud_core/version.rb +1 -1
- data/lib/tb_core/form_builder.rb +254 -0
- data/spec/helpers/spud/admin/application_helper_spec.rb +5 -5
- metadata +38 -14
- data/app/assets/javascripts/admin/core/split_pane.js +0 -150
- data/app/assets/libs/bootstrap/css/bootstrap-responsive.css +0 -1088
- data/app/assets/libs/bootstrap/css/bootstrap.css.scss +0 -5893
- data/app/assets/libs/bootstrap/img/glyphicons-halflings-white.png +0 -0
- data/app/assets/libs/bootstrap/img/glyphicons-halflings.png +0 -0
- data/app/assets/libs/bootstrap/js/bootstrap.js +0 -2025
- data/app/assets/stylesheets/admin/core/roles.css +0 -4
- data/app/assets/stylesheets/admin/core/split_pane.css.scss +0 -126
- data/app/assets/stylesheets/admin/core/users.css.scss +0 -9
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tb_core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.3.0.beta1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Greg Woods
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-11-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -95,7 +95,21 @@ dependencies:
|
|
95
95
|
- !ruby/object:Gem::Version
|
96
96
|
version: '0'
|
97
97
|
- !ruby/object:Gem::Dependency
|
98
|
-
name: bootstrap
|
98
|
+
name: will_paginate-bootstrap
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - ">="
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '0'
|
104
|
+
type: :runtime
|
105
|
+
prerelease: false
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - ">="
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '0'
|
111
|
+
- !ruby/object:Gem::Dependency
|
112
|
+
name: bootstrap-sass
|
99
113
|
requirement: !ruby/object:Gem::Requirement
|
100
114
|
requirements:
|
101
115
|
- - ">="
|
@@ -110,6 +124,20 @@ dependencies:
|
|
110
124
|
version: '0'
|
111
125
|
- !ruby/object:Gem::Dependency
|
112
126
|
name: sass-rails
|
127
|
+
requirement: !ruby/object:Gem::Requirement
|
128
|
+
requirements:
|
129
|
+
- - ">="
|
130
|
+
- !ruby/object:Gem::Version
|
131
|
+
version: 4.0.4
|
132
|
+
type: :runtime
|
133
|
+
prerelease: false
|
134
|
+
version_requirements: !ruby/object:Gem::Requirement
|
135
|
+
requirements:
|
136
|
+
- - ">="
|
137
|
+
- !ruby/object:Gem::Version
|
138
|
+
version: 4.0.4
|
139
|
+
- !ruby/object:Gem::Dependency
|
140
|
+
name: autoprefixer-rails
|
113
141
|
requirement: !ruby/object:Gem::Requirement
|
114
142
|
requirements:
|
115
143
|
- - ">="
|
@@ -298,17 +326,11 @@ files:
|
|
298
326
|
- app/assets/javascripts/admin/core/modal.js
|
299
327
|
- app/assets/javascripts/admin/core/preinit.js
|
300
328
|
- app/assets/javascripts/admin/core/roles.js
|
301
|
-
- app/assets/javascripts/admin/core/split_pane.js
|
302
329
|
- app/assets/javascripts/admin/core/users.js
|
303
330
|
- app/assets/javascripts/tb_core.js.erb
|
304
331
|
- app/assets/javascripts/tb_core/configuration.js.erb
|
305
332
|
- app/assets/javascripts/tb_core/console.js
|
306
333
|
- app/assets/javascripts/tb_core/utility.js
|
307
|
-
- app/assets/libs/bootstrap/css/bootstrap-responsive.css
|
308
|
-
- app/assets/libs/bootstrap/css/bootstrap.css.scss
|
309
|
-
- app/assets/libs/bootstrap/img/glyphicons-halflings-white.png
|
310
|
-
- app/assets/libs/bootstrap/img/glyphicons-halflings.png
|
311
|
-
- app/assets/libs/bootstrap/js/bootstrap.js
|
312
334
|
- app/assets/libs/datepicker/css/datepicker.css
|
313
335
|
- app/assets/libs/datepicker/js/bootstrap-datepicker.js
|
314
336
|
- app/assets/libs/datepicker/less/datepicker.less
|
@@ -330,9 +352,6 @@ files:
|
|
330
352
|
- app/assets/stylesheets/admin/application.css
|
331
353
|
- app/assets/stylesheets/admin/core/application.css.scss
|
332
354
|
- app/assets/stylesheets/admin/core/login.css.scss
|
333
|
-
- app/assets/stylesheets/admin/core/roles.css
|
334
|
-
- app/assets/stylesheets/admin/core/split_pane.css.scss
|
335
|
-
- app/assets/stylesheets/admin/core/users.css.scss
|
336
355
|
- app/controllers/admin/application_controller.rb
|
337
356
|
- app/controllers/admin/dashboard_controller.rb
|
338
357
|
- app/controllers/admin/password_resets_controller.rb
|
@@ -379,16 +398,19 @@ files:
|
|
379
398
|
- app/views/admin/users/show.html.erb
|
380
399
|
- app/views/core_mailer/forgot_password_notification.html.erb
|
381
400
|
- app/views/core_mailer/forgot_password_notification.text.erb
|
401
|
+
- app/views/layouts/admin/_flashes.html.erb
|
382
402
|
- app/views/layouts/admin/application.html.erb
|
383
403
|
- app/views/layouts/admin/detail.html.erb
|
384
404
|
- app/views/layouts/admin/error_page.html.erb
|
385
405
|
- app/views/layouts/admin/login.html.erb
|
386
406
|
- app/views/layouts/error_page.html.erb
|
387
407
|
- app/views/layouts/spud/admin/detail.html.erb
|
408
|
+
- app/views/layouts/user_sessions.html.erb
|
388
409
|
- app/views/password_resets/index.html.erb
|
389
410
|
- app/views/password_resets/show.html.erb
|
390
411
|
- app/views/sitemaps/show.xml.builder
|
391
412
|
- app/views/user_sessions/new.html.erb
|
413
|
+
- config/locales/en.yml
|
392
414
|
- config/routes.rb
|
393
415
|
- db/migrate/20111214161011_create_spud_admin_permissions.rb
|
394
416
|
- db/migrate/20111214161146_create_spud_users.rb
|
@@ -407,6 +429,7 @@ files:
|
|
407
429
|
- lib/generators/spud/templates/assets/admin.css.scss
|
408
430
|
- lib/generators/spud/templates/assets/admin/application.js
|
409
431
|
- lib/generators/spud/templates/assets/admin/module.js.erb
|
432
|
+
- lib/generators/spud/templates/assets/application.css.scss
|
410
433
|
- lib/generators/spud/templates/assets/application.js
|
411
434
|
- lib/generators/spud/templates/assets/module.js.erb
|
412
435
|
- lib/generators/spud/templates/controller.rb.erb
|
@@ -429,6 +452,7 @@ files:
|
|
429
452
|
- lib/spud_core/version.rb
|
430
453
|
- lib/tasks/spud_core_tasks.rake
|
431
454
|
- lib/tb_core.rb
|
455
|
+
- lib/tb_core/form_builder.rb
|
432
456
|
- spec/controllers/admin/application_controller_spec.rb
|
433
457
|
- spec/controllers/admin/dashboard_controller_spec.rb
|
434
458
|
- spec/controllers/admin/password_reset_controller_spec.rb
|
@@ -493,9 +517,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
493
517
|
version: '2.1'
|
494
518
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
495
519
|
requirements:
|
496
|
-
- - "
|
520
|
+
- - ">"
|
497
521
|
- !ruby/object:Gem::Version
|
498
|
-
version:
|
522
|
+
version: 1.3.1
|
499
523
|
requirements: []
|
500
524
|
rubyforge_project:
|
501
525
|
rubygems_version: 2.2.1
|
@@ -1,150 +0,0 @@
|
|
1
|
-
spud.admin.SplitPane = (function(){
|
2
|
-
|
3
|
-
function SplitPane(selector){
|
4
|
-
var container = this.container = $(selector);
|
5
|
-
this.rightPane = container.find('.split-pane-right');
|
6
|
-
this.leftPane = container.find('.split-pane-left');
|
7
|
-
this.contentArea = container.find('.split-pane-right-content');
|
8
|
-
this._listUrl = window.location.pathname;
|
9
|
-
container.on('click', '.split-pane-item', this, clickedItem);
|
10
|
-
container.on('click', '.pagination a', this, clickedPageLink);
|
11
|
-
container.on('submit', '.split-pane-search-form', this, submittedSearchForm);
|
12
|
-
container.on('click', '.split-pane-search-clear-btn', this, clickedClearSearch);
|
13
|
-
container.find('.split-pane-search-clear-btn').hide();
|
14
|
-
this.triggerFirstItem();
|
15
|
-
}
|
16
|
-
|
17
|
-
// Event Handlers
|
18
|
-
/////////////////
|
19
|
-
|
20
|
-
var clickedItem = function(e){
|
21
|
-
var splitPane = e.data;
|
22
|
-
item = $(this);
|
23
|
-
splitPane.setActiveItem(item);
|
24
|
-
url = item.attr('data-url');
|
25
|
-
title = item.attr('data-title') || '';
|
26
|
-
$.ajax(url, {
|
27
|
-
dataType:'html',
|
28
|
-
success:function(html){
|
29
|
-
splitPane.setContentAreaHtml(html);
|
30
|
-
splitPane.setToolbarTitle(title);
|
31
|
-
}
|
32
|
-
});
|
33
|
-
};
|
34
|
-
|
35
|
-
var clickedPageLink = function(e){
|
36
|
-
e.preventDefault();
|
37
|
-
var splitPane = e.data;
|
38
|
-
var url = $(this).attr('href');
|
39
|
-
splitPane.refreshList(url, function(){
|
40
|
-
splitPane.triggerFirstItem();
|
41
|
-
});
|
42
|
-
};
|
43
|
-
|
44
|
-
var clickedClearSearch = function(e){
|
45
|
-
e.preventDefault();
|
46
|
-
var splitPane = e.data;
|
47
|
-
$('.split-pane-search-form input').val('');
|
48
|
-
var btn = $(this);
|
49
|
-
btn.hide();
|
50
|
-
splitPane.refreshList(btn.attr('href'));
|
51
|
-
};
|
52
|
-
|
53
|
-
var submittedSearchForm = function(e){
|
54
|
-
e.preventDefault();
|
55
|
-
var splitPane = e.data;
|
56
|
-
splitPane.container.find('.split-pane-search-clear-btn').show();
|
57
|
-
var form = $(this);
|
58
|
-
var url = form.attr('action') + '?' + form.serialize();
|
59
|
-
splitPane.refreshList(url);
|
60
|
-
};
|
61
|
-
|
62
|
-
// Instance Methods
|
63
|
-
///////////////////
|
64
|
-
|
65
|
-
SplitPane.prototype.refreshList = function(url, callback){
|
66
|
-
if(typeof(url) != 'undefined'){
|
67
|
-
this._listUrl = url;
|
68
|
-
}
|
69
|
-
var activeId = this.getActiveItem().attr('data-id');
|
70
|
-
var self = this;
|
71
|
-
$.ajax(this._listUrl, {
|
72
|
-
success:function(html){
|
73
|
-
self.setLeftSideHtml(html);
|
74
|
-
var originalItem = self.leftPane.find('[data-id='+activeId+']');
|
75
|
-
if(originalItem.length){
|
76
|
-
self.setActiveItem(originalItem);
|
77
|
-
}
|
78
|
-
if(typeof(callback) == 'function'){
|
79
|
-
callback.call(self);
|
80
|
-
}
|
81
|
-
}
|
82
|
-
});
|
83
|
-
};
|
84
|
-
|
85
|
-
SplitPane.prototype.setActiveItem = function(item){
|
86
|
-
this.deselectActiveItem();
|
87
|
-
item.addClass('split-pane-item-selected');
|
88
|
-
};
|
89
|
-
|
90
|
-
SplitPane.prototype.getActiveItem = function(){
|
91
|
-
return this.container.find('.split-pane-item-selected');
|
92
|
-
};
|
93
|
-
|
94
|
-
SplitPane.prototype.deselectActiveItem = function(){
|
95
|
-
this.getActiveItem().removeClass('split-pane-item-selected');
|
96
|
-
};
|
97
|
-
|
98
|
-
SplitPane.prototype.triggerFirstItem = function(){
|
99
|
-
this.container.find('.split-pane-item').first().click();
|
100
|
-
};
|
101
|
-
|
102
|
-
SplitPane.prototype.setToolbarTitle = function(title){
|
103
|
-
if(typeof(title) == 'undefined'){
|
104
|
-
title = '';
|
105
|
-
}
|
106
|
-
this.container.find('.split-pane-toolbar-title').text(title);
|
107
|
-
};
|
108
|
-
|
109
|
-
SplitPane.prototype.setContentAreaHtml = function(html){
|
110
|
-
this.contentArea.html(html);
|
111
|
-
this.rightPane.scrollTop(0);
|
112
|
-
};
|
113
|
-
|
114
|
-
SplitPane.prototype.getContentAreaHtml = function(){
|
115
|
-
return this.contentArea.html();
|
116
|
-
};
|
117
|
-
|
118
|
-
SplitPane.prototype.getPreviousItem = function(){
|
119
|
-
var activeItem = this.getActiveItem();
|
120
|
-
var prev = activeItem.prev(".split-pane-item")[0] || activeItem.siblings(".split-pane-item").last()[0];
|
121
|
-
return prev;
|
122
|
-
};
|
123
|
-
|
124
|
-
SplitPane.prototype.getNextItem = function(){
|
125
|
-
var activeItem = this.getActiveItem();
|
126
|
-
return activeItem.next(".split-pane-item")[0];
|
127
|
-
};
|
128
|
-
|
129
|
-
SplitPane.prototype.removeCurrentlySelectedItem = function(){
|
130
|
-
var sibling = this.getNextItem() || this.getPreviousItem();
|
131
|
-
var activeItem = this.getActiveItem();
|
132
|
-
activeItem.remove();
|
133
|
-
if(sibling){
|
134
|
-
sibling.click();
|
135
|
-
}
|
136
|
-
else{
|
137
|
-
this.setContentAreaHtml('');
|
138
|
-
}
|
139
|
-
};
|
140
|
-
|
141
|
-
SplitPane.prototype.setLeftSideHtml = function(html){
|
142
|
-
this.leftPane.html(html);
|
143
|
-
};
|
144
|
-
|
145
|
-
SplitPane.prototype.find = function(selector){
|
146
|
-
return this.contentArea.find(selector);
|
147
|
-
};
|
148
|
-
|
149
|
-
return SplitPane;
|
150
|
-
})();
|