My page layout save missing in 0.9-stable
Added by Alex Revetchi almost 15 years ago
I can not save the layout on My page, save link is missing. Looked trough the diffs between 0.8.7 and 0.9:
app/views/my/page_layout.rhtml has the link missing
app/controllers/my_controller.rb has page_layout_save routine missing
Replies (1)
RE: My page layout save missing in 0.9-stable - Added by Alex Revetchi almost 15 years ago
I have put back the code removed in a prevous commit and it works fine now:
app/views/my/page_layout.rhtml - after the line 48
+<%= link_to l(:button_save), {:action => 'page_layout_save'}, :class => 'icon icon-save' %>
app/controllers/my_controller.rb - restored page_layout_save routine at the end of the file
+ # Save user's page layout
+ def page_layout_save
+ user user = User.current
+ @user.pref[:my_page_layout] = session[:page_layout] if session[:page_layout]
+ @user.pref.save
+ session[:page_layout] = nil
+ redirect_to :action => 'page'
+ end