forked from gitea/gitea
1
0
Fork 0
gitea/templates/release/new.tmpl

70 lines
4.2 KiB
Cheetah
Raw Normal View History

2014-04-06 14:54:28 +08:00
{{template "base/head" .}}
{{template "base/navbar" .}}
{{template "repo/nav" .}}
{{template "repo/toolbar" .}}
<div id="body" class="container">
<div id="release">
<h4 id="release-head">New Release</h4>
2014-04-14 13:57:25 +08:00
{{template "base/alert" .}}
<form id="release-new-form" action="{{.RepoLink}}/releases/new" method="post" class="form form-inline">
{{.CsrfTokenHtml}}
2014-04-06 14:54:28 +08:00
<div class="form-group">
2014-04-14 13:57:25 +08:00
<input id="tag-name" name="tag_name" type="text" class="form-control" placeholder="tag name" value="{{.tag_name}}" />
2014-04-06 16:29:45 +08:00
<span class="target-at">@</span>
<div class="btn-group" id="release-new-target-select">
<button type="button" class="btn btn-default"><i class="fa fa-code-fork fa-lg fa-m"></i>
<span class="target-text">Target : </span>
2014-04-14 13:57:25 +08:00
<strong id="release-new-target-name"> {{.Repository.DefaultBranch}}</strong>
2014-04-06 16:29:45 +08:00
</button>
<button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
<span class="caret"></span>
</button>
<div class="dropdown-menu clone-group-btn" id="release-new-target-branch-list">
<ul class="list-group">
2014-04-14 13:57:25 +08:00
{{range .Branches}}
2014-04-06 16:29:45 +08:00
<li class="list-group-item">
2014-04-14 13:57:25 +08:00
<a href="#" rel="{{.}}"><i class="fa fa-code-fork"></i>{{.}}</a>
2014-04-06 16:29:45 +08:00
</li>
2014-04-14 13:57:25 +08:00
{{end}}
2014-04-06 16:29:45 +08:00
</ul>
</div>
<input id="tag-target" type="hidden" name="tag_target" value="{{.Repository.DefaultBranch}}"/>
2014-04-06 16:29:45 +08:00
</div>
2014-04-14 13:57:25 +08:00
<p class="help-block">Choose an existing tag, or create a new tag on publish</p>
2014-04-06 16:29:45 +08:00
</div>
<div class="form-group" style="display: block">
2014-04-14 13:57:25 +08:00
<input class="form-control input-lg" id="release-new-title" name="title" type="text" placeholder="release title" value="{{.title}}" />
2014-04-06 16:29:45 +08:00
</div>
<div class="form-group col-md-8" style="display: block" id="release-new-content-div">
<div class="md-help pull-right">
Content with <a href="https://help.github.com/articles/markdown-basics">Markdown</a>
</div>
<ul class="nav nav-tabs" data-init="tabs">
<li class="release-write active"><a href="#release-textarea" data-toggle="tab">Write</a></li>
<li class="release-preview"><a href="#release-preview" data-toggle="tab" data-ajax="/api/v1/markdown?repo=repo_id&amp;release=new" data-ajax-name="release-preview" data-ajax-method="post" data-preview="#release-preview">Preview</a></li>
</ul>
<div class="tab-content">
<div class="tab-pane active" id="release-textarea">
<div class="form-group">
2014-04-14 13:57:25 +08:00
<textarea class="form-control" name="content" id="release-new-content" rows="10" placeholder="Write some content" data-ajax-rel="release-preview" data-ajax-val="val" data-ajax-field="content">{{.content}}</textarea>
2014-04-06 16:29:45 +08:00
</div>
</div>
<div class="tab-pane release-preview-content" id="release-preview">loading...</div>
</div>
</div>
<div class="text-right form-group col-md-8" style="display: block">
<hr/>
<label for="release-new-pre-release">
2014-04-14 13:57:25 +08:00
<input id="release-new-pre-release" type="checkbox" name="prerelease" {{if .prerelease}}checked{{end}}/>
2014-04-06 16:29:45 +08:00
<strong>This is a pre-release</strong>
</label>
<p class="help-block">Well point out that this release is identified as non-production ready.</p>
</div>
<div class="text-right form-group col-md-8" style="display: block">
<button class="btn-success btn">Publish release</button>
2014-04-14 13:57:25 +08:00
<!-- <input class="btn btn-default" type="submit" name="draft" value="Save Draft"/> -->
2014-04-06 14:54:28 +08:00
</div>
</form>
</div>
</div>
{{template "base/footer" .}}