mirror of
https://gitlink.org.cn/Gitlink/forgeplus.git
synced 2026-05-03 03:40:49 +08:00
init project
This commit is contained in:
18
app/controllers/admins/abouts_controller.rb
Normal file
18
app/controllers/admins/abouts_controller.rb
Normal file
@@ -0,0 +1,18 @@
|
||||
class Admins::AboutsController < Admins::BaseController
|
||||
def edit
|
||||
current_doc
|
||||
end
|
||||
|
||||
def update
|
||||
current_doc.update!(about_us: params[:about_us])
|
||||
|
||||
flash[:success] = '保存成功'
|
||||
redirect_to edit_admins_about_path
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def current_doc
|
||||
@doc ||= Help.first || Help.create
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user