diff --git a/app/forms/contents/create_form.rb b/app/forms/contents/create_form.rb index 6a0294887..ec60697d6 100644 --- a/app/forms/contents/create_form.rb +++ b/app/forms/contents/create_form.rb @@ -3,6 +3,8 @@ class Contents::CreateForm < BaseForm validates :filepath, presence: true + validates :new_branch, length: { maximum: 100, too_long: "过长,仅支持%{count}的长度"} + validate :check_branch def check_branch diff --git a/config/locales/forms/create_file_form.zh-CN.yml b/config/locales/forms/create_file_form.zh-CN.yml new file mode 100644 index 000000000..0f9ea86a7 --- /dev/null +++ b/config/locales/forms/create_file_form.zh-CN.yml @@ -0,0 +1,5 @@ +'zh-CN': + activemodel: + attributes: + contents/create_form: + new_branch: 分支名称 \ No newline at end of file diff --git a/public/images/logo.png b/public/images/logo.png new file mode 100644 index 000000000..8664f5c79 Binary files /dev/null and b/public/images/logo.png differ diff --git a/public/images/logo_x2.png b/public/images/logo_x2.png new file mode 100644 index 000000000..1263b5b49 Binary files /dev/null and b/public/images/logo_x2.png differ