Api tweaks
Dieser Commit ist enthalten in:
Ursprung
79fc4eee24
Commit
c24c7f7b44
8 geänderte Dateien mit 74 neuen und 77 gelöschten Zeilen
|
@ -266,7 +266,7 @@ const actionProperties = {
|
|||
}
|
||||
}
|
||||
|
||||
if (Discourse.SiteSettings.wizard_api_features) {
|
||||
if (Discourse.SiteSettings.wizard_apis_enabled) {
|
||||
actionProperties.types.send_to_api = {
|
||||
api: null,
|
||||
api_endpoint: null,
|
||||
|
|
|
@ -30,7 +30,7 @@ export default DiscourseRoute.extend({
|
|||
},
|
||||
|
||||
_getApis(model) {
|
||||
return ajax('/admin/wizards/apis')
|
||||
return ajax('/admin/wizards/api')
|
||||
.then((result) => set(model, 'apis', result));
|
||||
},
|
||||
|
||||
|
|
3
assets/javascripts/discourse/templates/admin-wizards-api.hbs
Normale Datei
3
assets/javascripts/discourse/templates/admin-wizards-api.hbs
Normale Datei
|
@ -0,0 +1,3 @@
|
|||
<div class="admin-wizard-container">
|
||||
{{outlet}}
|
||||
</div>
|
|
@ -1,8 +1,8 @@
|
|||
{{#admin-nav}}
|
||||
{{nav-item route='adminWizardsWizard' label='admin.wizard.nav_label'}}
|
||||
{{nav-item route='adminWizardsSubmissions' label='admin.wizard.submissions.nav_label'}}
|
||||
{{#if siteSettings.wizard_api_features}}
|
||||
{{nav-item route='adminWizardsApis' label='admin.wizard.api.nav_label'}}
|
||||
{{#if siteSettings.wizard_apis_enabled}}
|
||||
{{nav-item route='adminWizardsApi' label='admin.wizard.api.nav_label'}}
|
||||
{{/if}}
|
||||
{{nav-item route='adminWizardsLogs' label='admin.wizard.log.nav_label'}}
|
||||
{{nav-item route='adminWizardsTransfer' label='admin.wizard.transfer.nav_label'}}
|
||||
|
|
|
@ -34,10 +34,9 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
{{#if siteSettings.wizard_step_advanced}}
|
||||
{{wizard-advanced-toggle showAdvanced=step.showAdvanced}}
|
||||
{{wizard-advanced-toggle showAdvanced=step.showAdvanced}}
|
||||
|
||||
{{#if step.showAdvanced}}
|
||||
{{#if step.showAdvanced}}
|
||||
<div class="advanced-settings">
|
||||
|
||||
<div class="setting full field-mapper-setting">
|
||||
|
@ -96,7 +95,6 @@
|
|||
</div>
|
||||
|
||||
</div>
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
|
||||
{{wizard-links itemType="field" current=currentField items=step.fields}}
|
||||
|
|
|
@ -29,5 +29,4 @@ en:
|
|||
custom_wizard_enabled: "Enable custom wizards."
|
||||
wizard_redirect_exclude_paths: "Routes excluded from wizard redirects."
|
||||
wizard_recognised_image_upload_formats: "File types which will result in upload displaying an image preview"
|
||||
wizard_step_advanced: "Enable advanced settings for wizard steps (experimental)."
|
||||
wizard_api_features: "Enable API features (experimental)."
|
||||
wizard_apis_enabled: "Enable API features (experimental)."
|
|
@ -23,14 +23,14 @@ Discourse::Application.routes.append do
|
|||
get 'admin/wizards/submissions/:wizard_id' => 'admin_submissions#show'
|
||||
get 'admin/wizards/submissions/:wizard_id/download' => 'admin_submissions#download'
|
||||
|
||||
get 'admin/wizards/apis' => 'admin_api#list'
|
||||
get 'admin/wizards/apis/new' => 'admin_api#index'
|
||||
get 'admin/wizards/apis/:name' => 'admin_api#find'
|
||||
put 'admin/wizards/apis/:name' => 'admin_api#save'
|
||||
delete 'admin/wizards/apis/:name' => 'admin_api#remove'
|
||||
delete 'admin/wizards/apis/logs/:name' => 'admin_api#clearlogs'
|
||||
get 'admin/wizards/apis/:name/redirect' => 'admin_api#redirect'
|
||||
get 'admin/wizards/apis/:name/authorize' => 'admin_api#authorize'
|
||||
get 'admin/wizards/api' => 'admin_api#list'
|
||||
get 'admin/wizards/api/new' => 'admin_api#index'
|
||||
get 'admin/wizards/api/:name' => 'admin_api#find'
|
||||
put 'admin/wizards/api/:name' => 'admin_api#save'
|
||||
delete 'admin/wizards/api/:name' => 'admin_api#remove'
|
||||
delete 'admin/wizards/api/log/:name' => 'admin_api#clearlogs'
|
||||
get 'admin/wizards/api/:name/redirect' => 'admin_api#redirect'
|
||||
get 'admin/wizards/api/:name/authorize' => 'admin_api#authorize'
|
||||
|
||||
get 'admin/wizards/logs' => 'admin_logs#index'
|
||||
|
||||
|
|
|
@ -15,9 +15,6 @@ plugins:
|
|||
refresh: true
|
||||
type: list
|
||||
list_type: compact
|
||||
wizard_step_advanced:
|
||||
client: true
|
||||
default: false
|
||||
wizard_api_features:
|
||||
wizard_apis_enabled:
|
||||
client: true
|
||||
default: false
|
Laden …
In neuem Issue referenzieren