Class: Godmin::Resolver
- Inherits:
-
ActionView::FileSystemResolver
- Object
- ActionView::FileSystemResolver
- Godmin::Resolver
show all
- Defined in:
- lib/godmin/resolver.rb
Class Method Summary
collapse
Instance Method Summary
collapse
Constructor Details
#initialize(path, controller_path, engine_wrapper) ⇒ Resolver
Returns a new instance of Resolver.
10
11
12
13
14
|
# File 'lib/godmin/resolver.rb', line 10
def initialize(path, controller_path, engine_wrapper)
super(path)
@controller_path = controller_path
@engine_wrapper = engine_wrapper
end
|
Class Method Details
.resolvers(controller_path, engine_wrapper) ⇒ Object
3
4
5
6
7
8
|
# File 'lib/godmin/resolver.rb', line 3
def self.resolvers(controller_path, engine_wrapper)
[
EngineResolver.new(controller_path, engine_wrapper),
GodminResolver.new(controller_path, engine_wrapper)
]
end
|
Instance Method Details
#find_templates(name, prefix, partial, details) ⇒ Object
16
17
18
19
20
21
22
23
24
25
26
27
28
|
# File 'lib/godmin/resolver.rb', line 16
def find_templates(name, prefix, partial, details)
templates = []
template_paths(prefix).each do |path|
if templates.present?
break
else
templates = super(name, path, partial, details)
end
end
templates
end
|