diff options
author | Sam Rose <sam@gitlab.com> | 2017-05-07 22:20:37 -0400 |
---|---|---|
committer | Sam Rose <sam@gitlab.com> | 2017-05-10 17:39:50 -0400 |
commit | 2434d135d6d7953726d1a521fd9faf6ee4590b8a (patch) | |
tree | 27a097e9cc1d3c465976bf902652650be5f74a7d /app/views/projects | |
parent | 9b03ed0a182c9ad96957085826cc85f8f229569c (diff) | |
download | gitlab-ce-2434d135d6d7953726d1a521fd9faf6ee4590b8a.tar.gz |
Keep input data after creating existing tag
Diffstat (limited to 'app/views/projects')
-rw-r--r-- | app/views/projects/_zen.html.haml | 3 | ||||
-rw-r--r-- | app/views/projects/tags/new.html.haml | 4 |
2 files changed, 4 insertions, 3 deletions
diff --git a/app/views/projects/_zen.html.haml b/app/views/projects/_zen.html.haml index 0c8241053e7..3b3d08ddd3c 100644 --- a/app/views/projects/_zen.html.haml +++ b/app/views/projects/_zen.html.haml @@ -1,10 +1,11 @@ - @gfm_form = true +- current_text ||= nil - supports_slash_commands = local_assigns.fetch(:supports_slash_commands, false) .zen-backdrop - classes << ' js-gfm-input js-autosize markdown-area' - if defined?(f) && f = f.text_area attr, class: classes, placeholder: placeholder, data: { supports_slash_commands: supports_slash_commands } - else - = text_area_tag attr, nil, class: classes, placeholder: placeholder + = text_area_tag attr, current_text, class: classes, placeholder: placeholder %a.zen-control.zen-control-leave.js-zen-leave{ href: "#" } = icon('compress') diff --git a/app/views/projects/tags/new.html.haml b/app/views/projects/tags/new.html.haml index 7c607d2956b..cbf841762b7 100644 --- a/app/views/projects/tags/new.html.haml +++ b/app/views/projects/tags/new.html.haml @@ -22,14 +22,14 @@ .form-group = label_tag :message, nil, class: 'control-label' .col-sm-10 - = text_area_tag :message, nil, required: false, tabindex: 3, class: 'form-control', rows: 5 + = text_area_tag :message, @message, required: false, tabindex: 3, class: 'form-control', rows: 5 .help-block Optionally, add a message to the tag. %hr .form-group = label_tag :release_description, 'Release notes', class: 'control-label' .col-sm-10 = render layout: 'projects/md_preview', locals: { url: preview_markdown_path(@project), referenced_users: true } do - = render 'projects/zen', attr: :release_description, classes: 'note-textarea', placeholder: "Write your release notes or drag files here..." + = render 'projects/zen', attr: :release_description, classes: 'note-textarea', placeholder: "Write your release notes or drag files here...", current_text: @release_description = render 'shared/notes/hints' .help-block Optionally, add release notes to the tag. They will be stored in the GitLab database and displayed on the tags page. .form-actions |