From ed26a0a10525f41e4c26d8aca1213edea5af0418 Mon Sep 17 00:00:00 2001 From: pekopekopekopayo Date: Fri, 5 Apr 2024 23:58:14 +0900 Subject: [PATCH] add blank allowed message to api doc --- app/views/apipie/apipies/_params.html.erb | 1 + app/views/apipie/apipies/_params_plain.html.erb | 1 + config/locales/en.yml | 1 + config/locales/ko.yml | 1 + 4 files changed, 4 insertions(+) diff --git a/app/views/apipie/apipies/_params.html.erb b/app/views/apipie/apipies/_params.html.erb index 71a20bab6..91ea0792e 100644 --- a/app/views/apipie/apipies/_params.html.erb +++ b/app/views/apipie/apipies/_params.html.erb @@ -15,6 +15,7 @@ <%= param[:required] ? t('apipie.required') : t('apipie.optional') %> <%= param[:allow_nil] ? ', '+t('apipie.nil_allowed') : '' %> + <%= param[:allow_blank] ? ', '+t('apipie.blank_allowed') : '' %> diff --git a/app/views/apipie/apipies/_params_plain.html.erb b/app/views/apipie/apipies/_params_plain.html.erb index 00d9aac3a..2704ff1b2 100644 --- a/app/views/apipie/apipies/_params_plain.html.erb +++ b/app/views/apipie/apipies/_params_plain.html.erb @@ -9,6 +9,7 @@ <%= param[:required] ? t('apipie.required') : t('apipie.optional') %> <%= param[:allow_nil] ? ', '+t('apipie.nil_allowed') : '' %> + <%= param[:allow_blank] ? ', '+t('apipie.blank_allowed') : '' %> <% if param[:validator] %> [ <%= Apipie.markup_to_html(param[:validator]).html_safe %> ] <% end %> diff --git a/config/locales/en.yml b/config/locales/en.yml index f751cffe3..91dcc653d 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -15,6 +15,7 @@ en: required: required optional: optional nil_allowed: nil allowed + blank_allowed: blank allowed param_name: Param name params: Params examples: Examples diff --git a/config/locales/ko.yml b/config/locales/ko.yml index f15a70cba..01433c1de 100644 --- a/config/locales/ko.yml +++ b/config/locales/ko.yml @@ -15,6 +15,7 @@ ko: required: 필수 optional: 옵션 nil_allowed: nil 허용 + blank_allowed: blank 허용 param_name: Param 이름 params: Params examples: 예시