typus 3.1.9 → 3.1.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/CHANGELOG.md
CHANGED
@@ -1,10 +1,90 @@
|
|
1
1
|
CHANGELOG
|
2
2
|
=========
|
3
3
|
|
4
|
-
3.
|
4
|
+
3.2.0 (unrelased)
|
5
5
|
------------------
|
6
6
|
|
7
|
-
|
7
|
+
* [CHANGED] Dropped support for Ruby 1.8.7. This doesn't mean Typus will
|
8
|
+
not run willith that version of Ruby, but I don't longer have plans to
|
9
|
+
test against that version.
|
10
|
+
|
11
|
+
* [CHANGED] We do not longer look for Typus configuration files in the
|
12
|
+
plugins folder. Store them in `config/typus` or `lib/*/config/typus`.
|
13
|
+
Rails 4 will not support plugins and Rails 3.2 marks them as deprecated
|
14
|
+
so doesn't make sense to support them anymore.
|
15
|
+
|
16
|
+
* [CHANGED] Require at least `Rails 3.2.2`.
|
17
|
+
|
18
|
+
* [FIXED] Documentation about exporting data.
|
19
|
+
|
20
|
+
* [CHANGED] `login_info` helper becomes `admin_login_info`.
|
21
|
+
|
22
|
+
* [CHANGED] `search` helper becomes `admin_search`.
|
23
|
+
|
24
|
+
* [CHANGED] `title` helper becomes `admin_title` (and merged methods).
|
25
|
+
|
26
|
+
* [CHANGED] `apps` helper becomes `admin_apps`.
|
27
|
+
|
28
|
+
* [CHANGED] We do not longer detect if the application has a `root_path`
|
29
|
+
defined. A new setting `Typus.admin_title_link` has been added so we have
|
30
|
+
more control on which URL we want to use. This is useful because we don't
|
31
|
+
always want to link to the main site.
|
32
|
+
|
33
|
+
* [CHANGED] `display_flash_message` becomes `admin_display_flash_message`.
|
34
|
+
|
35
|
+
* [CHANGED] "Add New" becomes "Add".
|
36
|
+
|
37
|
+
* [FIXED] `return_to` now works as expected so now it's easier to send links to
|
38
|
+
the admin interface.
|
39
|
+
|
40
|
+
* [CHANGED] "Applications" in dashboard is now "Site administration".
|
41
|
+
|
42
|
+
* [FIXED] Model names in Trash module.
|
43
|
+
|
44
|
+
* [CHANGED] Removed `generate_html` alias method and use `get_paginated_data`.
|
45
|
+
This also fixes the usage of `ctags`.
|
46
|
+
|
47
|
+
* [CHANGED] Do not show "Add" link on the sidebar because it's confusing,
|
48
|
+
duplicated. We also have plans to remove the sidebar, so consider this as an
|
49
|
+
starting point. (Sidebar will be replaced by a drop down menu.)
|
50
|
+
|
51
|
+
* [CHANGED] No need to confirm when pressing "Sign out".
|
52
|
+
|
53
|
+
* [CHANGED] Instead of settings the session to `nil` when login out, we are
|
54
|
+
now removing it using `session.delete(:typus_user_id)`.
|
55
|
+
|
56
|
+
* [CHANGED] `TypusClass#to_label` now returns the email.
|
57
|
+
|
58
|
+
* [CHANGED] Session and account forms are now using `Typus.user_class`.
|
59
|
+
|
60
|
+
* [CHANGED] Extracted `account` and `session` forms into a partial.
|
61
|
+
|
62
|
+
* [CHANGED] `not_allowed` now accepts an param so we can give better feedback
|
63
|
+
to the user when an action is not allowed.
|
64
|
+
|
65
|
+
* [FIXED] Filter scopes so we can only run those scopes defined in configuration
|
66
|
+
files.
|
67
|
+
|
68
|
+
* [NEW] `Model.typus_scopes` to detect defined scopes.
|
69
|
+
|
70
|
+
Changes: <https://github.com/fesplugas/typus/compare/v3.1.10...master>
|
71
|
+
|
72
|
+
|
73
|
+
3.1.11 (unrelased)
|
74
|
+
-------------------
|
75
|
+
|
76
|
+
Changes: <https://github.com/fesplugas/typus/compare/v3.1.10...3-1-stable>
|
77
|
+
|
78
|
+
|
79
|
+
3.1.10 (2012-03-27)
|
80
|
+
-------------------
|
81
|
+
|
82
|
+
* [FIXED] Filter scopes so we can only run those scopes defined in configuration
|
83
|
+
files.
|
84
|
+
|
85
|
+
* [NEW] `Model.typus_scopes` to detect defined scopes.
|
86
|
+
|
87
|
+
Changes: <https://github.com/fesplugas/typus/compare/v3.1.9...v3.1.10>
|
8
88
|
|
9
89
|
|
10
90
|
3.1.9 (2012-03-08)
|
@@ -167,12 +167,12 @@ class Admin::ResourcesController < Admin::BaseController
|
|
167
167
|
helper_method :fields
|
168
168
|
|
169
169
|
def set_scope
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
170
|
+
return unless params[:scope]
|
171
|
+
|
172
|
+
if @resource.typus_scopes.include?(params[:scope])
|
173
|
+
@resource = @resource.send(params[:scope])
|
174
|
+
else
|
175
|
+
not_allowed("Requested scope not defined on your whitelist.")
|
176
176
|
end
|
177
177
|
end
|
178
178
|
|
@@ -20,7 +20,7 @@
|
|
20
20
|
<%= "(#{resource.count})" if @resource.typus_options_for(:counters) %>
|
21
21
|
</li>
|
22
22
|
|
23
|
-
<%
|
23
|
+
<% @resource.typus_scopes.each do |scope| %>
|
24
24
|
<li>
|
25
25
|
<%= link_to Typus::I18n.t(scope.humanize), :scope => scope %>
|
26
26
|
<%= "(#{@resource.send(scope).count})" if @resource.typus_options_for(:counters) %>
|
@@ -30,6 +30,10 @@ module Typus
|
|
30
30
|
read_model_config[filter.to_s].try(:extract_settings) || []
|
31
31
|
end
|
32
32
|
|
33
|
+
def typus_scopes
|
34
|
+
typus_defaults_for(:scopes).reject { |s| !respond_to?(s) }
|
35
|
+
end
|
36
|
+
|
33
37
|
def typus_search_fields
|
34
38
|
Hash.new.tap do |search|
|
35
39
|
typus_defaults_for(:search).each do |field|
|
data/lib/typus/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: typus
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.1.
|
4
|
+
version: 3.1.10
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,11 +9,11 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-03-
|
12
|
+
date: 2012-03-27 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: bcrypt-ruby
|
16
|
-
requirement:
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ~>
|
@@ -21,10 +21,15 @@ dependencies:
|
|
21
21
|
version: 3.0.0
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements:
|
24
|
+
version_requirements: !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
26
|
+
requirements:
|
27
|
+
- - ~>
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: 3.0.0
|
25
30
|
- !ruby/object:Gem::Dependency
|
26
31
|
name: jquery-rails
|
27
|
-
requirement:
|
32
|
+
requirement: !ruby/object:Gem::Requirement
|
28
33
|
none: false
|
29
34
|
requirements:
|
30
35
|
- - ! '>='
|
@@ -32,10 +37,15 @@ dependencies:
|
|
32
37
|
version: '0'
|
33
38
|
type: :runtime
|
34
39
|
prerelease: false
|
35
|
-
version_requirements:
|
40
|
+
version_requirements: !ruby/object:Gem::Requirement
|
41
|
+
none: false
|
42
|
+
requirements:
|
43
|
+
- - ! '>='
|
44
|
+
- !ruby/object:Gem::Version
|
45
|
+
version: '0'
|
36
46
|
- !ruby/object:Gem::Dependency
|
37
47
|
name: rails
|
38
|
-
requirement:
|
48
|
+
requirement: !ruby/object:Gem::Requirement
|
39
49
|
none: false
|
40
50
|
requirements:
|
41
51
|
- - ! '>='
|
@@ -43,7 +53,12 @@ dependencies:
|
|
43
53
|
version: 3.1.3
|
44
54
|
type: :runtime
|
45
55
|
prerelease: false
|
46
|
-
version_requirements:
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
none: false
|
58
|
+
requirements:
|
59
|
+
- - ! '>='
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: 3.1.3
|
47
62
|
description: Ruby on Rails Admin Panel (Engine) to allow trusted users edit structured
|
48
63
|
content.
|
49
64
|
email:
|
@@ -323,7 +338,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
323
338
|
version: '0'
|
324
339
|
segments:
|
325
340
|
- 0
|
326
|
-
hash:
|
341
|
+
hash: 4061502594870613970
|
327
342
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
328
343
|
none: false
|
329
344
|
requirements:
|
@@ -332,10 +347,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
332
347
|
version: '0'
|
333
348
|
segments:
|
334
349
|
- 0
|
335
|
-
hash:
|
350
|
+
hash: 4061502594870613970
|
336
351
|
requirements: []
|
337
352
|
rubyforge_project: typus
|
338
|
-
rubygems_version: 1.8.
|
353
|
+
rubygems_version: 1.8.21
|
339
354
|
signing_key:
|
340
355
|
specification_version: 3
|
341
356
|
summary: Effortless backend interface for Ruby on Rails applications. (Admin scaffold
|