rails-image-post-solution 0.1.16 → 0.1.18
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.
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: c757e3042b09a8e5f9f993c124dfc032a18ac5b452f9f7af19dec46d55b0a122
|
|
4
|
+
data.tar.gz: 70176cf82368b13be78cc268d3f929a43dd742ac78467e5eae9f80b7c0ae5fc1
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: bf21964848ba780e9ed3388a347bdcc5cf5b9379bdf167e8ccdc477da5f08e5856c77f5a9a86f5e772664d724922084c0d8b8d26ce651c6254500e2dde6e20f1
|
|
7
|
+
data.tar.gz: 32e73d2ddf11bc9fa1e2805fc24503fa84d10d5438c10772b376fd7e48e3dfc2290b011c231bf9fa7cb6f831d2446f87cd1d8932dd709ba6a84c95186564c6be
|
|
@@ -5,6 +5,9 @@ module RailsImagePostSolution
|
|
|
5
5
|
# Engine's base controller inherits from host application's ApplicationController
|
|
6
6
|
# This allows the engine to use the host app's authentication methods
|
|
7
7
|
|
|
8
|
+
# Prepend engine's view path
|
|
9
|
+
prepend_view_path Engine.root.join("app", "views")
|
|
10
|
+
|
|
8
11
|
# Override require_login to use main_app routes
|
|
9
12
|
def require_login
|
|
10
13
|
unless logged_in?
|
|
@@ -14,6 +14,13 @@ module RailsImagePostSolution
|
|
|
14
14
|
#{root}/app/controllers
|
|
15
15
|
]
|
|
16
16
|
|
|
17
|
+
# Prepend view paths so engine views are found
|
|
18
|
+
initializer "rails_image_post_solution.view_paths" do
|
|
19
|
+
ActiveSupport.on_load(:action_controller) do
|
|
20
|
+
prepend_view_path Engine.root.join("app", "views")
|
|
21
|
+
end
|
|
22
|
+
end
|
|
23
|
+
|
|
17
24
|
# Load admin module and controllers when app prepares
|
|
18
25
|
config.to_prepare do
|
|
19
26
|
# Ensure Admin module is loaded
|