forked from Trustie/forgeplus
新增:消息模板初始化接口
This commit is contained in:
parent
8e8cabb2f4
commit
61b50cd5d3
|
|
@ -0,0 +1,12 @@
|
|||
class MessageTemplatesController < ApplicationController
|
||||
before_action :require_login
|
||||
|
||||
|
||||
def init_data
|
||||
if MessageTemplate.build_init_data
|
||||
render_ok
|
||||
else
|
||||
render_error("初始化数据失败")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -216,6 +216,10 @@ Rails.application.routes.draw do
|
|||
resources :issue_depends, only: [:create, :destroy]
|
||||
end
|
||||
|
||||
resources :message_templates, only: [:index] do
|
||||
post :init_data, on: :collection
|
||||
end
|
||||
|
||||
resources :template_message_settings, only: [:index]
|
||||
|
||||
resources :applied_projects, only: [:create]
|
||||
|
|
|
|||
Loading…
Reference in New Issue