This commit improves templates readability, since all of them use consistent indent with all template command blocks indented too. 1. Indents both HTML containers such as <div>, <p> and Go HTML template blocks such as {{if}} {{with}} 2. Cleans all trailing white-space 3. Adds trailing last line-break to each filetokarchuk/v1.17
parent
dd8a06a397
commit
da2585c11e
@ -1,164 +1,164 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="admin edit authentication"> |
<div class="admin edit authentication"> |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "admin/navbar" .}} |
{{template "admin/navbar" .}} |
||||||
<div class="twelve wide column content"> |
<div class="twelve wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.auths.edit"}} |
{{.i18n.Tr "admin.auths.edit"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached segment"> |
<div class="ui attached segment"> |
||||||
<form class="ui form" action="{{.Link}}" method="post"> |
<form class="ui form" action="{{.Link}}" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<input type="hidden" name="id" value="{{.Source.ID}}"> |
<input type="hidden" name="id" value="{{.Source.ID}}"> |
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<label>{{$.i18n.Tr "admin.auths.auth_type"}}</label> |
<label>{{$.i18n.Tr "admin.auths.auth_type"}}</label> |
||||||
<input type="hidden" name="type" value="{{.Source.Type}}"> |
<input type="hidden" name="type" value="{{.Source.Type}}"> |
||||||
<span>{{.Source.TypeName}}</span> |
<span>{{.Source.TypeName}}</span> |
||||||
</div> |
</div> |
||||||
<div class="required inline field {{if .Err_Name}}error{{end}}"> |
<div class="required inline field {{if .Err_Name}}error{{end}}"> |
||||||
<label for="name">{{.i18n.Tr "admin.auths.auth_name"}}</label> |
<label for="name">{{.i18n.Tr "admin.auths.auth_name"}}</label> |
||||||
<input id="name" name="name" value="{{.Source.Name}}" autofocus required> |
<input id="name" name="name" value="{{.Source.Name}}" autofocus required> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<!-- LDAP and DLDAP --> |
<!-- LDAP and DLDAP --> |
||||||
{{if or .Source.IsLDAP .Source.IsDLDAP}} |
{{if or .Source.IsLDAP .Source.IsDLDAP}} |
||||||
{{ $cfg:=.Source.LDAP }} |
{{ $cfg:=.Source.LDAP }} |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="host">{{.i18n.Tr "admin.auths.host"}}</label> |
<label for="host">{{.i18n.Tr "admin.auths.host"}}</label> |
||||||
<input id="host" name="host" value="{{$cfg.Host}}" placeholder="e.g. mydomain.com" required> |
<input id="host" name="host" value="{{$cfg.Host}}" placeholder="e.g. mydomain.com" required> |
||||||
</div> |
</div> |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="port">{{.i18n.Tr "admin.auths.port"}}</label> |
<label for="port">{{.i18n.Tr "admin.auths.port"}}</label> |
||||||
<input id="port" name="port" value="{{$cfg.Port}}" placeholder="e.g. 636" required> |
<input id="port" name="port" value="{{$cfg.Port}}" placeholder="e.g. 636" required> |
||||||
</div> |
</div> |
||||||
{{if .Source.IsLDAP}} |
{{if .Source.IsLDAP}} |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="bind_dn">{{.i18n.Tr "admin.auths.bind_dn"}}</label> |
<label for="bind_dn">{{.i18n.Tr "admin.auths.bind_dn"}}</label> |
||||||
<input id="bind_dn" name="bind_dn" value="{{$cfg.BindDN}}" placeholder="e.g. cn=Search,dc=mydomain,dc=com" required> |
<input id="bind_dn" name="bind_dn" value="{{$cfg.BindDN}}" placeholder="e.g. cn=Search,dc=mydomain,dc=com" required> |
||||||
</div> |
</div> |
||||||
<input class="fake" type="password"> |
<input class="fake" type="password"> |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="bind_password">{{.i18n.Tr "admin.auths.bind_password"}}</label> |
<label for="bind_password">{{.i18n.Tr "admin.auths.bind_password"}}</label> |
||||||
<input id="bind_password" name="bind_password" type="password" value="{{$cfg.BindPassword}}" required> |
<input id="bind_password" name="bind_password" type="password" value="{{$cfg.BindPassword}}" required> |
||||||
<p class="help text red">{{.i18n.Tr "admin.auths.bind_password_helper"}}</p> |
<p class="help text red">{{.i18n.Tr "admin.auths.bind_password_helper"}}</p> |
||||||
</div> |
</div> |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="user_base">{{.i18n.Tr "admin.auths.user_base"}}</label> |
<label for="user_base">{{.i18n.Tr "admin.auths.user_base"}}</label> |
||||||
<input id="user_base" name="user_base" value="{{$cfg.UserBase}}" placeholder="e.g. ou=Users,dc=mydomain,dc=com" required> |
<input id="user_base" name="user_base" value="{{$cfg.UserBase}}" placeholder="e.g. ou=Users,dc=mydomain,dc=com" required> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
{{if .Source.IsDLDAP}} |
{{if .Source.IsDLDAP}} |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="user_dn">{{.i18n.Tr "admin.auths.user_dn"}}</label> |
<label for="user_dn">{{.i18n.Tr "admin.auths.user_dn"}}</label> |
||||||
<input id="user_dn" name="user_dn" value="{{$cfg.UserDN}}" placeholder="e.g. uid=%s,ou=Users,dc=mydomain,dc=com" required> |
<input id="user_dn" name="user_dn" value="{{$cfg.UserDN}}" placeholder="e.g. uid=%s,ou=Users,dc=mydomain,dc=com" required> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="filter">{{.i18n.Tr "admin.auths.filter"}}</label> |
<label for="filter">{{.i18n.Tr "admin.auths.filter"}}</label> |
||||||
<input id="filter" name="filter" value="{{$cfg.Filter}}" placeholder="e.g. (&(objectClass=posixAccount)(uid=%s))" required> |
<input id="filter" name="filter" value="{{$cfg.Filter}}" placeholder="e.g. (&(objectClass=posixAccount)(uid=%s))" required> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<label for="admin_filter">{{.i18n.Tr "admin.auths.admin_filter"}}</label> |
<label for="admin_filter">{{.i18n.Tr "admin.auths.admin_filter"}}</label> |
||||||
<input id="admin_filter" name="admin_filter" value="{{$cfg.AdminFilter}}"> |
<input id="admin_filter" name="admin_filter" value="{{$cfg.AdminFilter}}"> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<label for="attribute_username">{{.i18n.Tr "admin.auths.attribute_username"}}</label> |
<label for="attribute_username">{{.i18n.Tr "admin.auths.attribute_username"}}</label> |
||||||
<input id="attribute_username" name="attribute_username" value="{{$cfg.AttributeUsername}}" placeholder="{{.i18n.Tr "admin.auths.attribute_username_placeholder"}}"> |
<input id="attribute_username" name="attribute_username" value="{{$cfg.AttributeUsername}}" placeholder="{{.i18n.Tr "admin.auths.attribute_username_placeholder"}}"> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<label for="attribute_name">{{.i18n.Tr "admin.auths.attribute_name"}}</label> |
<label for="attribute_name">{{.i18n.Tr "admin.auths.attribute_name"}}</label> |
||||||
<input id="attribute_name" name="attribute_name" value="{{$cfg.AttributeName}}"> |
<input id="attribute_name" name="attribute_name" value="{{$cfg.AttributeName}}"> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<label for="attribute_surname">{{.i18n.Tr "admin.auths.attribute_surname"}}</label> |
<label for="attribute_surname">{{.i18n.Tr "admin.auths.attribute_surname"}}</label> |
||||||
<input id="attribute_surname" name="attribute_surname" value="{{$cfg.AttributeSurname}}"> |
<input id="attribute_surname" name="attribute_surname" value="{{$cfg.AttributeSurname}}"> |
||||||
</div> |
</div> |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="attribute_mail">{{.i18n.Tr "admin.auths.attribute_mail"}}</label> |
<label for="attribute_mail">{{.i18n.Tr "admin.auths.attribute_mail"}}</label> |
||||||
<input id="attribute_mail" name="attribute_mail" value="{{$cfg.AttributeMail}}" placeholder="e.g. mail" required> |
<input id="attribute_mail" name="attribute_mail" value="{{$cfg.AttributeMail}}" placeholder="e.g. mail" required> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
|
|
||||||
<!-- SMTP --> |
<!-- SMTP --> |
||||||
{{if .Source.IsSMTP}} |
{{if .Source.IsSMTP}} |
||||||
{{ $cfg:=.Source.SMTP }} |
{{ $cfg:=.Source.SMTP }} |
||||||
<div class="inline required field"> |
<div class="inline required field"> |
||||||
<label>{{.i18n.Tr "admin.auths.smtp_auth"}}</label> |
<label>{{.i18n.Tr "admin.auths.smtp_auth"}}</label> |
||||||
<div class="ui selection type dropdown"> |
<div class="ui selection type dropdown"> |
||||||
<input type="hidden" id="smtp_auth" name="smtp_auth" value="{{$cfg.Auth}}" required> |
<input type="hidden" id="smtp_auth" name="smtp_auth" value="{{$cfg.Auth}}" required> |
||||||
<div class="text">{{$cfg.Auth}}</div> |
<div class="text">{{$cfg.Auth}}</div> |
||||||
<i class="dropdown icon"></i> |
<i class="dropdown icon"></i> |
||||||
<div class="menu"> |
<div class="menu"> |
||||||
{{range .SMTPAuths}} |
{{range .SMTPAuths}} |
||||||
<div class="item" data-value="{{.}}">{{.}}</div> |
<div class="item" data-value="{{.}}">{{.}}</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="smtp_host">{{.i18n.Tr "admin.auths.smtphost"}}</label> |
<label for="smtp_host">{{.i18n.Tr "admin.auths.smtphost"}}</label> |
||||||
<input id="smtp_host" name="smtp_host" value="{{$cfg.Host}}" required> |
<input id="smtp_host" name="smtp_host" value="{{$cfg.Host}}" required> |
||||||
</div> |
</div> |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="smtp_port">{{.i18n.Tr "admin.auths.smtpport"}}</label> |
<label for="smtp_port">{{.i18n.Tr "admin.auths.smtpport"}}</label> |
||||||
<input id="smtp_port" name="smtp_port" value="{{$cfg.Port}}" required> |
<input id="smtp_port" name="smtp_port" value="{{$cfg.Port}}" required> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<label for="allowed_domains">{{.i18n.Tr "admin.auths.allowed_domains"}}</label> |
<label for="allowed_domains">{{.i18n.Tr "admin.auths.allowed_domains"}}</label> |
||||||
<input id="allowed_domains" name="allowed_domains" value="{{$cfg.AllowedDomains}}"> |
<input id="allowed_domains" name="allowed_domains" value="{{$cfg.AllowedDomains}}"> |
||||||
<p class="help">{{.i18n.Tr "admin.auths.allowed_domains_helper"}}</p> |
<p class="help">{{.i18n.Tr "admin.auths.allowed_domains_helper"}}</p> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
|
|
||||||
<!-- PAM --> |
<!-- PAM --> |
||||||
{{if .Source.IsPAM}} |
{{if .Source.IsPAM}} |
||||||
{{ $cfg:=.Source.PAM }} |
{{ $cfg:=.Source.PAM }} |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="pam_service_name">{{.i18n.Tr "admin.auths.pam_service_name"}}</label> |
<label for="pam_service_name">{{.i18n.Tr "admin.auths.pam_service_name"}}</label> |
||||||
<input id="pam_service_name" name="pam_service_name" value="{{$cfg.ServiceName}}" required> |
<input id="pam_service_name" name="pam_service_name" value="{{$cfg.ServiceName}}" required> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
|
|
||||||
<div class="inline field {{if not (or (or .Source.IsLDAP .Source.IsDLDAP) .Source.IsSMTP)}}hide{{end}}"> |
<div class="inline field {{if not (or (or .Source.IsLDAP .Source.IsDLDAP) .Source.IsSMTP)}}hide{{end}}"> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
<label><strong>{{.i18n.Tr "admin.auths.enable_tls"}}</strong></label> |
<label><strong>{{.i18n.Tr "admin.auths.enable_tls"}}</strong></label> |
||||||
<input name="tls" type="checkbox" {{if .Source.UseTLS}}checked{{end}}> |
<input name="tls" type="checkbox" {{if .Source.UseTLS}}checked{{end}}> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="inline field {{if not (or (or .Source.IsLDAP .Source.IsDLDAP) .Source.IsSMTP)}}hide{{end}}"> |
<div class="inline field {{if not (or (or .Source.IsLDAP .Source.IsDLDAP) .Source.IsSMTP)}}hide{{end}}"> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
<label><strong>{{.i18n.Tr "admin.auths.skip_tls_verify"}}</strong></label> |
<label><strong>{{.i18n.Tr "admin.auths.skip_tls_verify"}}</strong></label> |
||||||
<input name="skip_verify" type="checkbox" {{if .Source.SkipVerify}}checked{{end}}> |
<input name="skip_verify" type="checkbox" {{if .Source.SkipVerify}}checked{{end}}> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
<label><strong>{{.i18n.Tr "admin.auths.activated"}}</strong></label> |
<label><strong>{{.i18n.Tr "admin.auths.activated"}}</strong></label> |
||||||
<input name="is_active" type="checkbox" {{if .Source.IsActived}}checked{{end}}> |
<input name="is_active" type="checkbox" {{if .Source.IsActived}}checked{{end}}> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="field"> |
<div class="field"> |
||||||
<button class="ui green button">{{.i18n.Tr "admin.auths.update"}}</button> |
<button class="ui green button">{{.i18n.Tr "admin.auths.update"}}</button> |
||||||
<div class="ui red button delete-button" data-url="{{$.Link}}/delete" data-id="{{.Source.ID}}">{{.i18n.Tr "admin.auths.delete"}}</div> |
<div class="ui red button delete-button" data-url="{{$.Link}}/delete" data-id="{{.Source.ID}}">{{.i18n.Tr "admin.auths.delete"}}</div> |
||||||
</div> |
</div> |
||||||
</form> |
</form> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="ui small basic delete modal"> |
<div class="ui small basic delete modal"> |
||||||
<div class="ui icon header"> |
<div class="ui icon header"> |
||||||
<i class="trash icon"></i> |
<i class="trash icon"></i> |
||||||
{{.i18n.Tr "admin.auths.delete_auth_title"}} |
{{.i18n.Tr "admin.auths.delete_auth_title"}} |
||||||
</div> |
</div> |
||||||
<div class="content"> |
<div class="content"> |
||||||
<p>{{.i18n.Tr "admin.auths.delete_auth_desc"}}</p> |
<p>{{.i18n.Tr "admin.auths.delete_auth_desc"}}</p> |
||||||
</div> |
</div> |
||||||
{{template "base/delete_modal_actions" .}} |
{{template "base/delete_modal_actions" .}} |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,46 +1,46 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="admin authentication"> |
<div class="admin authentication"> |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "admin/navbar" .}} |
{{template "admin/navbar" .}} |
||||||
<div class="twelve wide column content"> |
<div class="twelve wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.auths.auth_manage_panel"}} ({{.i18n.Tr "admin.total" .Total}}) |
{{.i18n.Tr "admin.auths.auth_manage_panel"}} ({{.i18n.Tr "admin.total" .Total}}) |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<a class="ui blue tiny button" href="{{AppSubUrl}}/admin/auths/new">{{.i18n.Tr "admin.auths.new"}}</a> |
<a class="ui blue tiny button" href="{{AppSubUrl}}/admin/auths/new">{{.i18n.Tr "admin.auths.new"}}</a> |
||||||
</div> |
</div> |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<table class="ui very basic striped table"> |
<table class="ui very basic striped table"> |
||||||
<thead> |
<thead> |
||||||
<tr> |
<tr> |
||||||
<th>ID</th> |
<th>ID</th> |
||||||
<th>{{.i18n.Tr "admin.auths.name"}}</th> |
<th>{{.i18n.Tr "admin.auths.name"}}</th> |
||||||
<th>{{.i18n.Tr "admin.auths.type"}}</th> |
<th>{{.i18n.Tr "admin.auths.type"}}</th> |
||||||
<th>{{.i18n.Tr "admin.auths.enabled"}}</th> |
<th>{{.i18n.Tr "admin.auths.enabled"}}</th> |
||||||
<th>{{.i18n.Tr "admin.auths.updated"}}</th> |
<th>{{.i18n.Tr "admin.auths.updated"}}</th> |
||||||
<th>{{.i18n.Tr "admin.users.created"}}</th> |
<th>{{.i18n.Tr "admin.users.created"}}</th> |
||||||
<th>{{.i18n.Tr "admin.users.edit"}}</th> |
<th>{{.i18n.Tr "admin.users.edit"}}</th> |
||||||
</tr> |
</tr> |
||||||
</thead> |
</thead> |
||||||
<tbody> |
<tbody> |
||||||
{{range .Sources}} |
{{range .Sources}} |
||||||
<tr> |
<tr> |
||||||
<td>{{.ID}}</td> |
<td>{{.ID}}</td> |
||||||
<td><a href="{{AppSubUrl}}/admin/auths/{{.ID}}">{{.Name}}</a></td> |
<td><a href="{{AppSubUrl}}/admin/auths/{{.ID}}">{{.Name}}</a></td> |
||||||
<td>{{.TypeName}}</td> |
<td>{{.TypeName}}</td> |
||||||
<td><i class="fa fa{{if .IsActived}}-check{{end}}-square-o"></i></td> |
<td><i class="fa fa{{if .IsActived}}-check{{end}}-square-o"></i></td> |
||||||
<td><span class="poping up" data-content="{{DateFmtLong .Updated}}" data-variation="tiny">{{DateFmtShort .Updated}}</span></td> |
<td><span class="poping up" data-content="{{DateFmtLong .Updated}}" data-variation="tiny">{{DateFmtShort .Updated}}</span></td> |
||||||
<td><span class="poping up" data-content="{{DateFmtLong .Created}}" data-variation="tiny">{{DateFmtShort .Created}}</span></td> |
<td><span class="poping up" data-content="{{DateFmtLong .Created}}" data-variation="tiny">{{DateFmtShort .Created}}</span></td> |
||||||
<td><a href="{{AppSubUrl}}/admin/auths/{{.ID}}"><i class="fa fa-pencil-square-o"></i></a></td> |
<td><a href="{{AppSubUrl}}/admin/auths/{{.ID}}"><i class="fa fa-pencil-square-o"></i></a></td> |
||||||
</tr> |
</tr> |
||||||
{{end}} |
{{end}} |
||||||
</tbody> |
</tbody> |
||||||
</table> |
</table> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,159 +1,159 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="admin new authentication"> |
<div class="admin new authentication"> |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "admin/navbar" .}} |
{{template "admin/navbar" .}} |
||||||
<div class="twelve wide column content"> |
<div class="twelve wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.auths.new"}} |
{{.i18n.Tr "admin.auths.new"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached segment"> |
<div class="ui attached segment"> |
||||||
<form class="ui form" action="{{.Link}}" method="post"> |
<form class="ui form" action="{{.Link}}" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<!-- Types and name --> |
<!-- Types and name --> |
||||||
<div class="inline required field {{if .Err_Type}}error{{end}}"> |
<div class="inline required field {{if .Err_Type}}error{{end}}"> |
||||||
<label>{{.i18n.Tr "admin.auths.auth_type"}}</label> |
<label>{{.i18n.Tr "admin.auths.auth_type"}}</label> |
||||||
<div class="ui selection type dropdown"> |
<div class="ui selection type dropdown"> |
||||||
<input type="hidden" id="auth_type" name="type" value="{{.type}}"> |
<input type="hidden" id="auth_type" name="type" value="{{.type}}"> |
||||||
<div class="text">{{.CurTypeName}}</div> |
<div class="text">{{.CurTypeName}}</div> |
||||||
<i class="dropdown icon"></i> |
<i class="dropdown icon"></i> |
||||||
<div class="menu"> |
<div class="menu"> |
||||||
{{range .AuthSources}} |
{{range .AuthSources}} |
||||||
<div class="item" data-value="{{.Type}}">{{.Name}}</div> |
<div class="item" data-value="{{.Type}}">{{.Name}}</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="required inline field {{if .Err_Name}}error{{end}}"> |
<div class="required inline field {{if .Err_Name}}error{{end}}"> |
||||||
<label for="name">{{.i18n.Tr "admin.auths.auth_name"}}</label> |
<label for="name">{{.i18n.Tr "admin.auths.auth_name"}}</label> |
||||||
<input id="name" name="name" value="{{.name}}" autofocus required> |
<input id="name" name="name" value="{{.name}}" autofocus required> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<!-- LDAP and DLDAP --> |
<!-- LDAP and DLDAP --> |
||||||
<div class="ldap dldap field {{if not (or (eq .type 2) (eq .type 5))}}hide{{end}}"> |
<div class="ldap dldap field {{if not (or (eq .type 2) (eq .type 5))}}hide{{end}}"> |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="host">{{.i18n.Tr "admin.auths.host"}}</label> |
<label for="host">{{.i18n.Tr "admin.auths.host"}}</label> |
||||||
<input id="host" name="host" value="{{.host}}" placeholder="e.g. mydomain.com"> |
<input id="host" name="host" value="{{.host}}" placeholder="e.g. mydomain.com"> |
||||||
</div> |
</div> |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="port">{{.i18n.Tr "admin.auths.port"}}</label> |
<label for="port">{{.i18n.Tr "admin.auths.port"}}</label> |
||||||
<input id="port" name="port" value="{{.port}}" placeholder="e.g. 636"> |
<input id="port" name="port" value="{{.port}}" placeholder="e.g. 636"> |
||||||
</div> |
</div> |
||||||
<div class="ldap required field {{if not (eq .type 2)}}hide{{end}}"> |
<div class="ldap required field {{if not (eq .type 2)}}hide{{end}}"> |
||||||
<label for="bind_dn">{{.i18n.Tr "admin.auths.bind_dn"}}</label> |
<label for="bind_dn">{{.i18n.Tr "admin.auths.bind_dn"}}</label> |
||||||
<input id="bind_dn" name="bind_dn" value="{{.bind_dn}}" placeholder="e.g. cn=Search,dc=mydomain,dc=com"> |
<input id="bind_dn" name="bind_dn" value="{{.bind_dn}}" placeholder="e.g. cn=Search,dc=mydomain,dc=com"> |
||||||
</div> |
</div> |
||||||
<input class="fake" type="password"> |
<input class="fake" type="password"> |
||||||
<div class="ldap required field {{if not (eq .type 2)}}hide{{end}}"> |
<div class="ldap required field {{if not (eq .type 2)}}hide{{end}}"> |
||||||
<label for="bind_password">{{.i18n.Tr "admin.auths.bind_password"}}</label> |
<label for="bind_password">{{.i18n.Tr "admin.auths.bind_password"}}</label> |
||||||
<input id="bind_password" name="bind_password" type="password" value="{{.bind_password}}"> |
<input id="bind_password" name="bind_password" type="password" value="{{.bind_password}}"> |
||||||
<p class="help text red">{{.i18n.Tr "admin.auths.bind_password_helper"}}</p> |
<p class="help text red">{{.i18n.Tr "admin.auths.bind_password_helper"}}</p> |
||||||
</div> |
</div> |
||||||
<div class="ldap required field {{if not (eq .type 2)}}hide{{end}}"> |
<div class="ldap required field {{if not (eq .type 2)}}hide{{end}}"> |
||||||
<label for="user_base">{{.i18n.Tr "admin.auths.user_base"}}</label> |
<label for="user_base">{{.i18n.Tr "admin.auths.user_base"}}</label> |
||||||
<input id="user_base" name="user_base" value="{{.user_base}}" placeholder="e.g. ou=Users,dc=mydomain,dc=com"> |
<input id="user_base" name="user_base" value="{{.user_base}}" placeholder="e.g. ou=Users,dc=mydomain,dc=com"> |
||||||
</div> |
</div> |
||||||
<div class="dldap required field {{if not (eq .type 5)}}hide{{end}}"> |
<div class="dldap required field {{if not (eq .type 5)}}hide{{end}}"> |
||||||
<label for="user_dn">{{.i18n.Tr "admin.auths.user_dn"}}</label> |
<label for="user_dn">{{.i18n.Tr "admin.auths.user_dn"}}</label> |
||||||
<input id="user_dn" name="user_dn" value="{{.user_dn}}" placeholder="e.g. uid=%s,ou=Users,dc=mydomain,dc=com"> |
<input id="user_dn" name="user_dn" value="{{.user_dn}}" placeholder="e.g. uid=%s,ou=Users,dc=mydomain,dc=com"> |
||||||
</div> |
</div> |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="filter">{{.i18n.Tr "admin.auths.filter"}}</label> |
<label for="filter">{{.i18n.Tr "admin.auths.filter"}}</label> |
||||||
<input id="filter" name="filter" value="{{.filter}}" placeholder="e.g. (&(objectClass=posixAccount)(uid=%s))"> |
<input id="filter" name="filter" value="{{.filter}}" placeholder="e.g. (&(objectClass=posixAccount)(uid=%s))"> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<label for="admin_filter">{{.i18n.Tr "admin.auths.admin_filter"}}</label> |
<label for="admin_filter">{{.i18n.Tr "admin.auths.admin_filter"}}</label> |
||||||
<input id="admin_filter" name="admin_filter" value="{{.admin_filter}}"> |
<input id="admin_filter" name="admin_filter" value="{{.admin_filter}}"> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<label for="attribute_username">{{.i18n.Tr "admin.auths.attribute_username"}}</label> |
<label for="attribute_username">{{.i18n.Tr "admin.auths.attribute_username"}}</label> |
||||||
<input id="attribute_username" name="attribute_username" value="{{.attribute_username}}" placeholder="{{.i18n.Tr "admin.auths.attribute_username_placeholder"}}"> |
<input id="attribute_username" name="attribute_username" value="{{.attribute_username}}" placeholder="{{.i18n.Tr "admin.auths.attribute_username_placeholder"}}"> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<label for="attribute_name">{{.i18n.Tr "admin.auths.attribute_name"}}</label> |
<label for="attribute_name">{{.i18n.Tr "admin.auths.attribute_name"}}</label> |
||||||
<input id="attribute_name" name="attribute_name" value="{{.attribute_name}}"> |
<input id="attribute_name" name="attribute_name" value="{{.attribute_name}}"> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<label for="attribute_surname">{{.i18n.Tr "admin.auths.attribute_surname"}}</label> |
<label for="attribute_surname">{{.i18n.Tr "admin.auths.attribute_surname"}}</label> |
||||||
<input id="attribute_surname" name="attribute_surname" value="{{.attribute_surname}}"> |
<input id="attribute_surname" name="attribute_surname" value="{{.attribute_surname}}"> |
||||||
</div> |
</div> |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="attribute_mail">{{.i18n.Tr "admin.auths.attribute_mail"}}</label> |
<label for="attribute_mail">{{.i18n.Tr "admin.auths.attribute_mail"}}</label> |
||||||
<input id="attribute_mail" name="attribute_mail" value="{{.attribute_mail}}" placeholder="e.g. mail"> |
<input id="attribute_mail" name="attribute_mail" value="{{.attribute_mail}}" placeholder="e.g. mail"> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<!-- SMTP --> |
<!-- SMTP --> |
||||||
<div class="smtp field {{if not (eq .type 3)}}hide{{end}}"> |
<div class="smtp field {{if not (eq .type 3)}}hide{{end}}"> |
||||||
<div class="inline required field"> |
<div class="inline required field"> |
||||||
<label>{{.i18n.Tr "admin.auths.smtp_auth"}}</label> |
<label>{{.i18n.Tr "admin.auths.smtp_auth"}}</label> |
||||||
<div class="ui selection type dropdown"> |
<div class="ui selection type dropdown"> |
||||||
<input type="hidden" id="smtp_auth" name="smtp_auth" value="{{.smtp_auth}}"> |
<input type="hidden" id="smtp_auth" name="smtp_auth" value="{{.smtp_auth}}"> |
||||||
<div class="text">{{.smtp_auth}}</div> |
<div class="text">{{.smtp_auth}}</div> |
||||||
<i class="dropdown icon"></i> |
<i class="dropdown icon"></i> |
||||||
<div class="menu"> |
<div class="menu"> |
||||||
{{range .SMTPAuths}} |
{{range .SMTPAuths}} |
||||||
<div class="item" data-value="{{.}}">{{.}}</div> |
<div class="item" data-value="{{.}}">{{.}}</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="smtp_host">{{.i18n.Tr "admin.auths.smtphost"}}</label> |
<label for="smtp_host">{{.i18n.Tr "admin.auths.smtphost"}}</label> |
||||||
<input id="smtp_host" name="smtp_host" value="{{.smtp_host}}"> |
<input id="smtp_host" name="smtp_host" value="{{.smtp_host}}"> |
||||||
</div> |
</div> |
||||||
<div class="required field"> |
<div class="required field"> |
||||||
<label for="smtp_port">{{.i18n.Tr "admin.auths.smtpport"}}</label> |
<label for="smtp_port">{{.i18n.Tr "admin.auths.smtpport"}}</label> |
||||||
<input id="smtp_port" name="smtp_port" value="{{.smtp_port}}"> |
<input id="smtp_port" name="smtp_port" value="{{.smtp_port}}"> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<label for="allowed_domains">{{.i18n.Tr "admin.auths.allowed_domains"}}</label> |
<label for="allowed_domains">{{.i18n.Tr "admin.auths.allowed_domains"}}</label> |
||||||
<input id="allowed_domains" name="allowed_domains" value="{{.allowed_domains}}"> |
<input id="allowed_domains" name="allowed_domains" value="{{.allowed_domains}}"> |
||||||
<p class="help">{{.i18n.Tr "admin.auths.allowed_domains_helper"}}</p> |
<p class="help">{{.i18n.Tr "admin.auths.allowed_domains_helper"}}</p> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<!-- PAM --> |
<!-- PAM --> |
||||||
<div class="pam required field {{if not (eq .type 4)}}hide{{end}}"> |
<div class="pam required field {{if not (eq .type 4)}}hide{{end}}"> |
||||||
<label for="pam_service_name">{{.i18n.Tr "admin.auths.pam_service_name"}}</label> |
<label for="pam_service_name">{{.i18n.Tr "admin.auths.pam_service_name"}}</label> |
||||||
<input id="pam_service_name" name="pam_service_name" value="{{.pam_service_name}}" /> |
<input id="pam_service_name" name="pam_service_name" value="{{.pam_service_name}}" /> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="ldap dldap smtp inline field {{if not (or (or (eq .type 2) (eq .type 5)) (eq .type 3))}}hide{{end}}"> |
<div class="ldap dldap smtp inline field {{if not (or (or (eq .type 2) (eq .type 5)) (eq .type 3))}}hide{{end}}"> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
<label><strong>{{.i18n.Tr "admin.auths.enable_tls"}}</strong></label> |
<label><strong>{{.i18n.Tr "admin.auths.enable_tls"}}</strong></label> |
||||||
<input name="tls" type="checkbox" {{if .tls}}checked{{end}}> |
<input name="tls" type="checkbox" {{if .tls}}checked{{end}}> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="ldap dldap smtp inline field {{if not (or (or (eq .type 2) (eq .type 5)) (eq .type 3))}}hide{{end}}"> |
<div class="ldap dldap smtp inline field {{if not (or (or (eq .type 2) (eq .type 5)) (eq .type 3))}}hide{{end}}"> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
<label><strong>{{.i18n.Tr "admin.auths.skip_tls_verify"}}</strong></label> |
<label><strong>{{.i18n.Tr "admin.auths.skip_tls_verify"}}</strong></label> |
||||||
<input name="skip_verify" type="checkbox" {{if .skip_verify}}checked{{end}}> |
<input name="skip_verify" type="checkbox" {{if .skip_verify}}checked{{end}}> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
<label><strong>{{.i18n.Tr "admin.auths.activated"}}</strong></label> |
<label><strong>{{.i18n.Tr "admin.auths.activated"}}</strong></label> |
||||||
<input name="is_active" type="checkbox" {{if .is_active}}checked{{end}}> |
<input name="is_active" type="checkbox" {{if .is_active}}checked{{end}}> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="field"> |
<div class="field"> |
||||||
<button class="ui green button">{{.i18n.Tr "admin.auths.new"}}</button> |
<button class="ui green button">{{.i18n.Tr "admin.auths.new"}}</button> |
||||||
</div> |
</div> |
||||||
</form> |
</form> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.auths.tips"}} |
{{.i18n.Tr "admin.auths.tips"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached segment"> |
<div class="ui attached segment"> |
||||||
<h5>GMail Setting:</h5> |
<h5>GMail Setting:</h5> |
||||||
<p>Host: smtp.gmail.com, Post: 587, Enable TLS Encryption: true</p> |
<p>Host: smtp.gmail.com, Post: 587, Enable TLS Encryption: true</p> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,190 +1,190 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="admin monitor"> |
<div class="admin monitor"> |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "admin/navbar" .}} |
{{template "admin/navbar" .}} |
||||||
<div class="twelve wide column content"> |
<div class="twelve wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.config.server_config"}} |
{{.i18n.Tr "admin.config.server_config"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<dl class="dl-horizontal admin-dl-horizontal"> |
<dl class="dl-horizontal admin-dl-horizontal"> |
||||||
<dt>{{.i18n.Tr "admin.config.app_name"}}</dt> |
<dt>{{.i18n.Tr "admin.config.app_name"}}</dt> |
||||||
<dd>{{AppName}}</dd> |
<dd>{{AppName}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.app_ver"}}</dt> |
<dt>{{.i18n.Tr "admin.config.app_ver"}}</dt> |
||||||
<dd>{{AppVer}}</dd> |
<dd>{{AppVer}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.app_url"}}</dt> |
<dt>{{.i18n.Tr "admin.config.app_url"}}</dt> |
||||||
<dd>{{.AppUrl}}</dd> |
<dd>{{.AppUrl}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.domain"}}</dt> |
<dt>{{.i18n.Tr "admin.config.domain"}}</dt> |
||||||
<dd>{{.Domain}}</dd> |
<dd>{{.Domain}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.offline_mode"}}</dt> |
<dt>{{.i18n.Tr "admin.config.offline_mode"}}</dt> |
||||||
<dd><i class="fa fa{{if .OfflineMode}}-check{{end}}-square-o"></i></dd> |
<dd><i class="fa fa{{if .OfflineMode}}-check{{end}}-square-o"></i></dd> |
||||||
<dt>{{.i18n.Tr "admin.config.disable_router_log"}}</dt> |
<dt>{{.i18n.Tr "admin.config.disable_router_log"}}</dt> |
||||||
<dd><i class="fa fa{{if .DisableRouterLog}}-check{{end}}-square-o"></i></dd> |
<dd><i class="fa fa{{if .DisableRouterLog}}-check{{end}}-square-o"></i></dd> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
<dt>{{.i18n.Tr "admin.config.run_user"}}</dt> |
<dt>{{.i18n.Tr "admin.config.run_user"}}</dt> |
||||||
<dd>{{.RunUser}}</dd> |
<dd>{{.RunUser}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.run_mode"}}</dt> |
<dt>{{.i18n.Tr "admin.config.run_mode"}}</dt> |
||||||
<dd>{{.RunMode}}</dd> |
<dd>{{.RunMode}}</dd> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
<dt>{{.i18n.Tr "admin.config.repo_root_path"}}</dt> |
<dt>{{.i18n.Tr "admin.config.repo_root_path"}}</dt> |
||||||
<dd>{{.RepoRootPath}}</dd> |
<dd>{{.RepoRootPath}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.static_file_root_path"}}</dt> |
<dt>{{.i18n.Tr "admin.config.static_file_root_path"}}</dt> |
||||||
<dd>{{.StaticRootPath}}</dd> |
<dd>{{.StaticRootPath}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.log_file_root_path"}}</dt> |
<dt>{{.i18n.Tr "admin.config.log_file_root_path"}}</dt> |
||||||
<dd>{{.LogRootPath}}</dd> |
<dd>{{.LogRootPath}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.script_type"}}</dt> |
<dt>{{.i18n.Tr "admin.config.script_type"}}</dt> |
||||||
<dd>{{.ScriptType}}</dd> |
<dd>{{.ScriptType}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.reverse_auth_user"}}</dt> |
<dt>{{.i18n.Tr "admin.config.reverse_auth_user"}}</dt> |
||||||
<dd>{{.ReverseProxyAuthUser}}</dd> |
<dd>{{.ReverseProxyAuthUser}}</dd> |
||||||
</dl> |
</dl> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.config.db_config"}} |
{{.i18n.Tr "admin.config.db_config"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<dl class="dl-horizontal admin-dl-horizontal"> |
<dl class="dl-horizontal admin-dl-horizontal"> |
||||||
<dt>{{.i18n.Tr "admin.config.db_type"}}</dt> |
<dt>{{.i18n.Tr "admin.config.db_type"}}</dt> |
||||||
<dd>{{.DbCfg.Type}}</dd> |
<dd>{{.DbCfg.Type}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.db_host"}}</dt> |
<dt>{{.i18n.Tr "admin.config.db_host"}}</dt> |
||||||
<dd>{{.DbCfg.Host}}</dd> |
<dd>{{.DbCfg.Host}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.db_name"}}</dt> |
<dt>{{.i18n.Tr "admin.config.db_name"}}</dt> |
||||||
<dd>{{.DbCfg.Name}}</dd> |
<dd>{{.DbCfg.Name}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.db_user"}}</dt> |
<dt>{{.i18n.Tr "admin.config.db_user"}}</dt> |
||||||
<dd>{{.DbCfg.User}}</dd> |
<dd>{{.DbCfg.User}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.db_ssl_mode"}}</dt> |
<dt>{{.i18n.Tr "admin.config.db_ssl_mode"}}</dt> |
||||||
<dd>{{.DbCfg.SSLMode}} {{.i18n.Tr "admin.config.db_ssl_mode_helper"}}</dd> |
<dd>{{.DbCfg.SSLMode}} {{.i18n.Tr "admin.config.db_ssl_mode_helper"}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.db_path"}}</dt> |
<dt>{{.i18n.Tr "admin.config.db_path"}}</dt> |
||||||
<dd>{{.DbCfg.Path}} {{.i18n.Tr "admin.config.db_path_helper"}}</dd> |
<dd>{{.DbCfg.Path}} {{.i18n.Tr "admin.config.db_path_helper"}}</dd> |
||||||
</dl> |
</dl> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.config.service_config"}} |
{{.i18n.Tr "admin.config.service_config"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<dl class="dl-horizontal admin-dl-horizontal"> |
<dl class="dl-horizontal admin-dl-horizontal"> |
||||||
<dt>{{.i18n.Tr "admin.config.register_email_confirm"}}</dt> |
<dt>{{.i18n.Tr "admin.config.register_email_confirm"}}</dt> |
||||||
<dd><i class="fa fa{{if .Service.RegisterEmailConfirm}}-check{{end}}-square-o"></i></dd> |
<dd><i class="fa fa{{if .Service.RegisterEmailConfirm}}-check{{end}}-square-o"></i></dd> |
||||||
<dt>{{.i18n.Tr "admin.config.disable_register"}}</dt> |
<dt>{{.i18n.Tr "admin.config.disable_register"}}</dt> |
||||||
<dd><i class="fa fa{{if .Service.DisableRegistration}}-check{{end}}-square-o"></i></dd> |
<dd><i class="fa fa{{if .Service.DisableRegistration}}-check{{end}}-square-o"></i></dd> |
||||||
<dt>{{.i18n.Tr "admin.config.show_registration_button"}}</dt> |
<dt>{{.i18n.Tr "admin.config.show_registration_button"}}</dt> |
||||||
<dd><i class="fa fa{{if .Service.ShowRegistrationButton}}-check{{end}}-square-o"></i></dd> |
<dd><i class="fa fa{{if .Service.ShowRegistrationButton}}-check{{end}}-square-o"></i></dd> |
||||||
<dt>{{.i18n.Tr "admin.config.require_sign_in_view"}}</dt> |
<dt>{{.i18n.Tr "admin.config.require_sign_in_view"}}</dt> |
||||||
<dd><i class="fa fa{{if .Service.RequireSignInView}}-check{{end}}-square-o"></i></dd> |
<dd><i class="fa fa{{if .Service.RequireSignInView}}-check{{end}}-square-o"></i></dd> |
||||||
<dt>{{.i18n.Tr "admin.config.enable_cache_avatar"}}</dt> |
<dt>{{.i18n.Tr "admin.config.enable_cache_avatar"}}</dt> |
||||||
<dd><i class="fa fa{{if .Service.EnableCacheAvatar}}-check{{end}}-square-o"></i></dd> |
<dd><i class="fa fa{{if .Service.EnableCacheAvatar}}-check{{end}}-square-o"></i></dd> |
||||||
<dt>{{.i18n.Tr "admin.config.mail_notify"}}</dt> |
<dt>{{.i18n.Tr "admin.config.mail_notify"}}</dt> |
||||||
<dd><i class="fa fa{{if .Service.EnableNotifyMail}}-check{{end}}-square-o"></i></dd> |
<dd><i class="fa fa{{if .Service.EnableNotifyMail}}-check{{end}}-square-o"></i></dd> |
||||||
<dt>{{.i18n.Tr "admin.config.disable_key_size_check"}}</dt> |
<dt>{{.i18n.Tr "admin.config.disable_key_size_check"}}</dt> |
||||||
<dd><i class="fa fa{{if .Service.DisableMinimumKeySizeCheck}}-check{{end}}-square-o"></i></dd> |
<dd><i class="fa fa{{if .Service.DisableMinimumKeySizeCheck}}-check{{end}}-square-o"></i></dd> |
||||||
<dt>{{.i18n.Tr "admin.config.enable_captcha"}}</dt> |
<dt>{{.i18n.Tr "admin.config.enable_captcha"}}</dt> |
||||||
<dd><i class="fa fa{{if .Service.EnableCaptcha}}-check{{end}}-square-o"></i></dd> |
<dd><i class="fa fa{{if .Service.EnableCaptcha}}-check{{end}}-square-o"></i></dd> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
<dt>{{.i18n.Tr "admin.config.active_code_lives"}}</dt> |
<dt>{{.i18n.Tr "admin.config.active_code_lives"}}</dt> |
||||||
<dd>{{.Service.ActiveCodeLives}} {{.i18n.Tr "tool.raw_minutes"}}</dd> |
<dd>{{.Service.ActiveCodeLives}} {{.i18n.Tr "tool.raw_minutes"}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.reset_password_code_lives"}}</dt> |
<dt>{{.i18n.Tr "admin.config.reset_password_code_lives"}}</dt> |
||||||
<dd>{{.Service.ResetPwdCodeLives}} {{.i18n.Tr "tool.raw_minutes"}}</dd> |
<dd>{{.Service.ResetPwdCodeLives}} {{.i18n.Tr "tool.raw_minutes"}}</dd> |
||||||
</dl> |
</dl> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.config.webhook_config"}} |
{{.i18n.Tr "admin.config.webhook_config"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<dl class="dl-horizontal admin-dl-horizontal"> |
<dl class="dl-horizontal admin-dl-horizontal"> |
||||||
<dt>{{.i18n.Tr "admin.config.queue_length"}}</dt> |
<dt>{{.i18n.Tr "admin.config.queue_length"}}</dt> |
||||||
<dd>{{.Webhook.QueueLength}}</dd> |
<dd>{{.Webhook.QueueLength}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.deliver_timeout"}}</dt> |
<dt>{{.i18n.Tr "admin.config.deliver_timeout"}}</dt> |
||||||
<dd>{{.Webhook.DeliverTimeout}} {{.i18n.Tr "tool.raw_seconds"}}</dd> |
<dd>{{.Webhook.DeliverTimeout}} {{.i18n.Tr "tool.raw_seconds"}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.skip_tls_verify"}}</dt> |
<dt>{{.i18n.Tr "admin.config.skip_tls_verify"}}</dt> |
||||||
<dd><i class="fa fa{{if .Webhook.SkipTLSVerify}}-check{{end}}-square-o"></i></dd> |
<dd><i class="fa fa{{if .Webhook.SkipTLSVerify}}-check{{end}}-square-o"></i></dd> |
||||||
</dl> |
</dl> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.config.mailer_config"}} |
{{.i18n.Tr "admin.config.mailer_config"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<dl class="dl-horizontal admin-dl-horizontal"> |
<dl class="dl-horizontal admin-dl-horizontal"> |
||||||
<dt>{{.i18n.Tr "admin.config.mailer_enabled"}}</dt> |
<dt>{{.i18n.Tr "admin.config.mailer_enabled"}}</dt> |
||||||
<dd><i class="fa fa{{if .MailerEnabled}}-check{{end}}-square-o"></i></dd> |
<dd><i class="fa fa{{if .MailerEnabled}}-check{{end}}-square-o"></i></dd> |
||||||
{{if .MailerEnabled}}<dt>{{.i18n.Tr "admin.config.mailer_name"}}</dt> |
{{if .MailerEnabled}}<dt>{{.i18n.Tr "admin.config.mailer_name"}}</dt> |
||||||
<dd>{{.Mailer.Name}}</dd> |
<dd>{{.Mailer.Name}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.mailer_disable_helo"}}</dt> |
<dt>{{.i18n.Tr "admin.config.mailer_disable_helo"}}</dt> |
||||||
<dd><i class="fa fa{{if .Mailer.DisableHelo}}-check{{end}}-square-o"></i></dd> |
<dd><i class="fa fa{{if .Mailer.DisableHelo}}-check{{end}}-square-o"></i></dd> |
||||||
<dt>{{.i18n.Tr "admin.config.mailer_host"}}</dt> |
<dt>{{.i18n.Tr "admin.config.mailer_host"}}</dt> |
||||||
<dd>{{.Mailer.Host}}</dd> |
<dd>{{.Mailer.Host}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.mailer_user"}}</dt> |
<dt>{{.i18n.Tr "admin.config.mailer_user"}}</dt> |
||||||
<dd>{{.Mailer.User}}</dd>{{end}} |
<dd>{{.Mailer.User}}</dd>{{end}} |
||||||
</dl> |
</dl> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.config.cache_config"}} |
{{.i18n.Tr "admin.config.cache_config"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<dl class="dl-horizontal admin-dl-horizontal"> |
<dl class="dl-horizontal admin-dl-horizontal"> |
||||||
<dt>{{.i18n.Tr "admin.config.cache_adapter"}}</dt> |
<dt>{{.i18n.Tr "admin.config.cache_adapter"}}</dt> |
||||||
<dd>{{.CacheAdapter}}</dd> |
<dd>{{.CacheAdapter}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.cache_interval"}}</dt> |
<dt>{{.i18n.Tr "admin.config.cache_interval"}}</dt> |
||||||
<dd>{{.CacheInternal}} {{.i18n.Tr "tool.raw_seconds"}}</dd> |
<dd>{{.CacheInternal}} {{.i18n.Tr "tool.raw_seconds"}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.cache_conn"}}</dt> |
<dt>{{.i18n.Tr "admin.config.cache_conn"}}</dt> |
||||||
<dd><pre>{{.CacheConn}}</pre></dd> |
<dd><pre>{{.CacheConn}}</pre></dd> |
||||||
</dl> |
</dl> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.config.session_config"}} |
{{.i18n.Tr "admin.config.session_config"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<dl class="dl-horizontal admin-dl-horizontal"> |
<dl class="dl-horizontal admin-dl-horizontal"> |
||||||
<dt>{{.i18n.Tr "admin.config.session_provider"}}</dt> |
<dt>{{.i18n.Tr "admin.config.session_provider"}}</dt> |
||||||
<dd>{{.SessionConfig.Provider}}</dd> |
<dd>{{.SessionConfig.Provider}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.provider_config"}}</dt> |
<dt>{{.i18n.Tr "admin.config.provider_config"}}</dt> |
||||||
<dd><pre>{{.SessionConfig.ProviderConfig}}</pre></dd> |
<dd><pre>{{.SessionConfig.ProviderConfig}}</pre></dd> |
||||||
<dt>{{.i18n.Tr "admin.config.cookie_name"}}</dt> |
<dt>{{.i18n.Tr "admin.config.cookie_name"}}</dt> |
||||||
<dd>{{.SessionConfig.CookieName}}</dd> |
<dd>{{.SessionConfig.CookieName}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.gc_interval_time"}}</dt> |
<dt>{{.i18n.Tr "admin.config.gc_interval_time"}}</dt> |
||||||
<dd>{{.SessionConfig.Gclifetime}} {{.i18n.Tr "tool.raw_seconds"}}</dd> |
<dd>{{.SessionConfig.Gclifetime}} {{.i18n.Tr "tool.raw_seconds"}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.session_life_time"}}</dt> |
<dt>{{.i18n.Tr "admin.config.session_life_time"}}</dt> |
||||||
<dd>{{.SessionConfig.Maxlifetime}} {{.i18n.Tr "tool.raw_seconds"}}</dd> |
<dd>{{.SessionConfig.Maxlifetime}} {{.i18n.Tr "tool.raw_seconds"}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.https_only"}}</dt> |
<dt>{{.i18n.Tr "admin.config.https_only"}}</dt> |
||||||
<dd><i class="fa fa{{if .SessionConfig.Secure}}-check{{end}}-square-o"></i></dd> |
<dd><i class="fa fa{{if .SessionConfig.Secure}}-check{{end}}-square-o"></i></dd> |
||||||
<dt>{{.i18n.Tr "admin.config.cookie_life_time"}}</dt> |
<dt>{{.i18n.Tr "admin.config.cookie_life_time"}}</dt> |
||||||
<dd>{{.SessionConfig.CookieLifeTime}} {{.i18n.Tr "tool.raw_seconds"}}</dd> |
<dd>{{.SessionConfig.CookieLifeTime}} {{.i18n.Tr "tool.raw_seconds"}}</dd> |
||||||
</dl> |
</dl> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.config.picture_config"}} |
{{.i18n.Tr "admin.config.picture_config"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<dl class="dl-horizontal admin-dl-horizontal"> |
<dl class="dl-horizontal admin-dl-horizontal"> |
||||||
<dt>{{.i18n.Tr "admin.config.picture_service"}}</dt> |
<dt>{{.i18n.Tr "admin.config.picture_service"}}</dt> |
||||||
<dd>{{.PictureService}}</dd> |
<dd>{{.PictureService}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.config.disable_gravatar"}}</dt> |
<dt>{{.i18n.Tr "admin.config.disable_gravatar"}}</dt> |
||||||
<dd><i class="fa fa{{if .DisableGravatar}}-check{{end}}-square-o"></i></dd> |
<dd><i class="fa fa{{if .DisableGravatar}}-check{{end}}-square-o"></i></dd> |
||||||
</dl> |
</dl> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.config.log_config"}} |
{{.i18n.Tr "admin.config.log_config"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<dl class="dl-horizontal admin-dl-horizontal"> |
<dl class="dl-horizontal admin-dl-horizontal"> |
||||||
{{range .Loggers}} |
{{range .Loggers}} |
||||||
<dt>{{$.i18n.Tr "admin.config.log_mode"}}</dt> |
<dt>{{$.i18n.Tr "admin.config.log_mode"}}</dt> |
||||||
<dd>{{.Mode}}</dd> |
<dd>{{.Mode}}</dd> |
||||||
<dt>{{$.i18n.Tr "admin.config.log_config"}}</dt> |
<dt>{{$.i18n.Tr "admin.config.log_config"}}</dt> |
||||||
<dd><pre>{{.Config}}</pre></dd> |
<dd><pre>{{.Config}}</pre></dd> |
||||||
{{end}} |
{{end}} |
||||||
</dl> |
</dl> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,121 +1,121 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="admin dashboard"> |
<div class="admin dashboard"> |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "admin/navbar" .}} |
{{template "admin/navbar" .}} |
||||||
<div class="twelve wide column content"> |
<div class="twelve wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.dashboard.statistic"}} |
{{.i18n.Tr "admin.dashboard.statistic"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached segment"> |
<div class="ui attached segment"> |
||||||
<p> |
<p> |
||||||
{{.i18n.Tr "admin.dashboard.statistic_info" .Stats.Counter.User .Stats.Counter.Org .Stats.Counter.PublicKey .Stats.Counter.Repo .Stats.Counter.Watch .Stats.Counter.Star .Stats.Counter.Action .Stats.Counter.Access .Stats.Counter.Issue .Stats.Counter.Comment .Stats.Counter.Oauth .Stats.Counter.Follow .Stats.Counter.Mirror .Stats.Counter.Release .Stats.Counter.LoginSource .Stats.Counter.Webhook .Stats.Counter.Milestone .Stats.Counter.Label .Stats.Counter.HookTask .Stats.Counter.Team .Stats.Counter.UpdateTask .Stats.Counter.Attachment | Str2html}} |
{{.i18n.Tr "admin.dashboard.statistic_info" .Stats.Counter.User .Stats.Counter.Org .Stats.Counter.PublicKey .Stats.Counter.Repo .Stats.Counter.Watch .Stats.Counter.Star .Stats.Counter.Action .Stats.Counter.Access .Stats.Counter.Issue .Stats.Counter.Comment .Stats.Counter.Oauth .Stats.Counter.Follow .Stats.Counter.Mirror .Stats.Counter.Release .Stats.Counter.LoginSource .Stats.Counter.Webhook .Stats.Counter.Milestone .Stats.Counter.Label .Stats.Counter.HookTask .Stats.Counter.Team .Stats.Counter.UpdateTask .Stats.Counter.Attachment | Str2html}} |
||||||
</p> |
</p> |
||||||
</div> |
</div> |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.dashboard.operations"}} |
{{.i18n.Tr "admin.dashboard.operations"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<table class="ui very basic table"> |
<table class="ui very basic table"> |
||||||
<tbody> |
<tbody> |
||||||
<tr> |
<tr> |
||||||
<td>{{.i18n.Tr "admin.dashboard.delete_inactivate_accounts"}}</td> |
<td>{{.i18n.Tr "admin.dashboard.delete_inactivate_accounts"}}</td> |
||||||
<td><i class="fa fa-caret-square-o-right"></i> <a href="{{AppSubUrl}}/admin?op=1">{{.i18n.Tr "admin.dashboard.operation_run"}}</a></td> |
<td><i class="fa fa-caret-square-o-right"></i> <a href="{{AppSubUrl}}/admin?op=1">{{.i18n.Tr "admin.dashboard.operation_run"}}</a></td> |
||||||
</tr> |
</tr> |
||||||
<tr> |
<tr> |
||||||
<td>{{.i18n.Tr "admin.dashboard.delete_repo_archives"}}</td> |
<td>{{.i18n.Tr "admin.dashboard.delete_repo_archives"}}</td> |
||||||
<td><i class="fa fa-caret-square-o-right"></i> <a href="{{AppSubUrl}}/admin?op=2">{{.i18n.Tr "admin.dashboard.operation_run"}}</a></td> |
<td><i class="fa fa-caret-square-o-right"></i> <a href="{{AppSubUrl}}/admin?op=2">{{.i18n.Tr "admin.dashboard.operation_run"}}</a></td> |
||||||
</tr> |
</tr> |
||||||
<tr> |
<tr> |
||||||
<td>{{.i18n.Tr "admin.dashboard.delete_missing_repos"}}</td> |
<td>{{.i18n.Tr "admin.dashboard.delete_missing_repos"}}</td> |
||||||
<td><i class="fa fa-caret-square-o-right"></i> <a href="{{AppSubUrl}}/admin?op=3">{{.i18n.Tr "admin.dashboard.operation_run"}}</a></td> |
<td><i class="fa fa-caret-square-o-right"></i> <a href="{{AppSubUrl}}/admin?op=3">{{.i18n.Tr "admin.dashboard.operation_run"}}</a></td> |
||||||
</tr> |
</tr> |
||||||
<tr> |
<tr> |
||||||
<td>{{.i18n.Tr "admin.dashboard.git_gc_repos"}}</td> |
<td>{{.i18n.Tr "admin.dashboard.git_gc_repos"}}</td> |
||||||
<td><i class="fa fa-caret-square-o-right"></i> <a href="{{AppSubUrl}}/admin?op=4">{{.i18n.Tr "admin.dashboard.operation_run"}}</a></td> |
<td><i class="fa fa-caret-square-o-right"></i> <a href="{{AppSubUrl}}/admin?op=4">{{.i18n.Tr "admin.dashboard.operation_run"}}</a></td> |
||||||
</tr> |
</tr> |
||||||
<tr> |
<tr> |
||||||
<td>{{.i18n.Tr "admin.dashboard.resync_all_sshkeys"}}</td> |
<td>{{.i18n.Tr "admin.dashboard.resync_all_sshkeys"}}</td> |
||||||
<td><i class="fa fa-caret-square-o-right"></i> <a href="{{AppSubUrl}}/admin?op=5">{{.i18n.Tr "admin.dashboard.operation_run"}}</a></td> |
<td><i class="fa fa-caret-square-o-right"></i> <a href="{{AppSubUrl}}/admin?op=5">{{.i18n.Tr "admin.dashboard.operation_run"}}</a></td> |
||||||
</tr> |
</tr> |
||||||
<tr> |
<tr> |
||||||
<td>{{.i18n.Tr "admin.dashboard.resync_all_update_hooks"}}</td> |
<td>{{.i18n.Tr "admin.dashboard.resync_all_update_hooks"}}</td> |
||||||
<td><i class="fa fa-caret-square-o-right"></i> <a href="{{AppSubUrl}}/admin?op=6">{{.i18n.Tr "admin.dashboard.operation_run"}}</a></td> |
<td><i class="fa fa-caret-square-o-right"></i> <a href="{{AppSubUrl}}/admin?op=6">{{.i18n.Tr "admin.dashboard.operation_run"}}</a></td> |
||||||
</tr> |
</tr> |
||||||
</tbody> |
</tbody> |
||||||
</table> |
</table> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.dashboard.system_status"}} |
{{.i18n.Tr "admin.dashboard.system_status"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<dl class="dl-horizontal admin-dl-horizontal"> |
<dl class="dl-horizontal admin-dl-horizontal"> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.server_uptime"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.server_uptime"}}</dt> |
||||||
<dd>{{.SysStatus.Uptime}}</dd> |
<dd>{{.SysStatus.Uptime}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.current_goroutine"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.current_goroutine"}}</dt> |
||||||
<dd>{{.SysStatus.NumGoroutine}}</dd> |
<dd>{{.SysStatus.NumGoroutine}}</dd> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.current_memory_usage"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.current_memory_usage"}}</dt> |
||||||
<dd>{{.SysStatus.MemAllocated}}</dd> |
<dd>{{.SysStatus.MemAllocated}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.total_memory_allocated"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.total_memory_allocated"}}</dt> |
||||||
<dd>{{.SysStatus.MemTotal}}</dd> |
<dd>{{.SysStatus.MemTotal}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.memory_obtained"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.memory_obtained"}}</dt> |
||||||
<dd>{{.SysStatus.MemSys}}</dd> |
<dd>{{.SysStatus.MemSys}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.pointer_lookup_times"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.pointer_lookup_times"}}</dt> |
||||||
<dd>{{.SysStatus.Lookups}}</dd> |
<dd>{{.SysStatus.Lookups}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.memory_allocate_times"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.memory_allocate_times"}}</dt> |
||||||
<dd>{{.SysStatus.MemMallocs}}</dd> |
<dd>{{.SysStatus.MemMallocs}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.memory_free_times"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.memory_free_times"}}</dt> |
||||||
<dd>{{.SysStatus.MemFrees}}</dd> |
<dd>{{.SysStatus.MemFrees}}</dd> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.current_heap_usage"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.current_heap_usage"}}</dt> |
||||||
<dd>{{.SysStatus.HeapAlloc}}</dd> |
<dd>{{.SysStatus.HeapAlloc}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.heap_memory_obtained"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.heap_memory_obtained"}}</dt> |
||||||
<dd>{{.SysStatus.HeapSys}}</dd> |
<dd>{{.SysStatus.HeapSys}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.heap_memory_idle"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.heap_memory_idle"}}</dt> |
||||||
<dd>{{.SysStatus.HeapIdle}}</dd> |
<dd>{{.SysStatus.HeapIdle}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.heap_memory_in_use"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.heap_memory_in_use"}}</dt> |
||||||
<dd>{{.SysStatus.HeapInuse}}</dd> |
<dd>{{.SysStatus.HeapInuse}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.heap_memory_released"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.heap_memory_released"}}</dt> |
||||||
<dd>{{.SysStatus.HeapReleased}}</dd> |
<dd>{{.SysStatus.HeapReleased}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.heap_objects"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.heap_objects"}}</dt> |
||||||
<dd>{{.SysStatus.HeapObjects}}</dd> |
<dd>{{.SysStatus.HeapObjects}}</dd> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.bootstrap_stack_usage"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.bootstrap_stack_usage"}}</dt> |
||||||
<dd>{{.SysStatus.StackInuse}}</dd> |
<dd>{{.SysStatus.StackInuse}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.stack_memory_obtained"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.stack_memory_obtained"}}</dt> |
||||||
<dd>{{.SysStatus.StackSys}}</dd> |
<dd>{{.SysStatus.StackSys}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.mspan_structures_usage"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.mspan_structures_usage"}}</dt> |
||||||
<dd>{{.SysStatus.MSpanInuse}}</dd> |
<dd>{{.SysStatus.MSpanInuse}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.mspan_structures_obtained"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.mspan_structures_obtained"}}</dt> |
||||||
<dd>{{.SysStatus.HeapSys}}</dd> |
<dd>{{.SysStatus.HeapSys}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.mcache_structures_usage"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.mcache_structures_usage"}}</dt> |
||||||
<dd>{{.SysStatus.MCacheInuse}}</dd> |
<dd>{{.SysStatus.MCacheInuse}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.mcache_structures_obtained"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.mcache_structures_obtained"}}</dt> |
||||||
<dd>{{.SysStatus.MCacheSys}}</dd> |
<dd>{{.SysStatus.MCacheSys}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.profiling_bucket_hash_table_obtained"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.profiling_bucket_hash_table_obtained"}}</dt> |
||||||
<dd>{{.SysStatus.BuckHashSys}}</dd> |
<dd>{{.SysStatus.BuckHashSys}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.gc_metadata_obtained"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.gc_metadata_obtained"}}</dt> |
||||||
<dd>{{.SysStatus.GCSys}}</dd> |
<dd>{{.SysStatus.GCSys}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.other_system_allocation_obtained"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.other_system_allocation_obtained"}}</dt> |
||||||
<dd>{{.SysStatus.OtherSys}}</dd> |
<dd>{{.SysStatus.OtherSys}}</dd> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.next_gc_recycle"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.next_gc_recycle"}}</dt> |
||||||
<dd>{{.SysStatus.NextGC}}</dd> |
<dd>{{.SysStatus.NextGC}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.last_gc_time"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.last_gc_time"}}</dt> |
||||||
<dd>{{.SysStatus.LastGC}}</dd> |
<dd>{{.SysStatus.LastGC}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.total_gc_pause"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.total_gc_pause"}}</dt> |
||||||
<dd>{{.SysStatus.PauseTotalNs}}</dd> |
<dd>{{.SysStatus.PauseTotalNs}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.last_gc_pause"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.last_gc_pause"}}</dt> |
||||||
<dd>{{.SysStatus.PauseNs}}</dd> |
<dd>{{.SysStatus.PauseNs}}</dd> |
||||||
<dt>{{.i18n.Tr "admin.dashboard.gc_times"}}</dt> |
<dt>{{.i18n.Tr "admin.dashboard.gc_times"}}</dt> |
||||||
<dd>{{.SysStatus.NumGC}}</dd> |
<dd>{{.SysStatus.NumGC}}</dd> |
||||||
</dl> |
</dl> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,65 +1,65 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="admin monitor"> |
<div class="admin monitor"> |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "admin/navbar" .}} |
{{template "admin/navbar" .}} |
||||||
<div class="twelve wide column content"> |
<div class="twelve wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.monitor.cron"}} |
{{.i18n.Tr "admin.monitor.cron"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<table class="ui very basic striped table"> |
<table class="ui very basic striped table"> |
||||||
<thead> |
<thead> |
||||||
<tr> |
<tr> |
||||||
<th>{{.i18n.Tr "admin.monitor.name"}}</th> |
<th>{{.i18n.Tr "admin.monitor.name"}}</th> |
||||||
<th>{{.i18n.Tr "admin.monitor.schedule"}}</th> |
<th>{{.i18n.Tr "admin.monitor.schedule"}}</th> |
||||||
<th>{{.i18n.Tr "admin.monitor.next"}}</th> |
<th>{{.i18n.Tr "admin.monitor.next"}}</th> |
||||||
<th>{{.i18n.Tr "admin.monitor.previous"}}</th> |
<th>{{.i18n.Tr "admin.monitor.previous"}}</th> |
||||||
<th>{{.i18n.Tr "admin.monitor.execute_times"}}</th> |
<th>{{.i18n.Tr "admin.monitor.execute_times"}}</th> |
||||||
</tr> |
</tr> |
||||||
</thead> |
</thead> |
||||||
<tbody> |
<tbody> |
||||||
{{range .Entries}} |
{{range .Entries}} |
||||||
<tr> |
<tr> |
||||||
<td>{{.Description}}</td> |
<td>{{.Description}}</td> |
||||||
<td>{{.Spec}}</td> |
<td>{{.Spec}}</td> |
||||||
<td>{{DateFmtLong .Next}}</td> |
<td>{{DateFmtLong .Next}}</td> |
||||||
<td>{{if gt .Prev.Year 1 }}{{DateFmtLong .Prev}}{{else}}N/A{{end}}</td> |
<td>{{if gt .Prev.Year 1 }}{{DateFmtLong .Prev}}{{else}}N/A{{end}}</td> |
||||||
<td>{{.ExecTimes}}</td> |
<td>{{.ExecTimes}}</td> |
||||||
</tr> |
</tr> |
||||||
{{end}} |
{{end}} |
||||||
</tbody> |
</tbody> |
||||||
</table> |
</table> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.monitor.process"}} |
{{.i18n.Tr "admin.monitor.process"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<table class="ui very basic striped table"> |
<table class="ui very basic striped table"> |
||||||
<thead> |
<thead> |
||||||
<tr> |
<tr> |
||||||
<th>Pid</th> |
<th>Pid</th> |
||||||
<th>{{.i18n.Tr "admin.monitor.desc"}}</th> |
<th>{{.i18n.Tr "admin.monitor.desc"}}</th> |
||||||
<th>{{.i18n.Tr "admin.monitor.start"}}</th> |
<th>{{.i18n.Tr "admin.monitor.start"}}</th> |
||||||
<th>{{.i18n.Tr "admin.monitor.execute_time"}}</th> |
<th>{{.i18n.Tr "admin.monitor.execute_time"}}</th> |
||||||
</tr> |
</tr> |
||||||
</thead> |
</thead> |
||||||
<tbody> |
<tbody> |
||||||
{{range .Processes}} |
{{range .Processes}} |
||||||
<tr> |
<tr> |
||||||
<td>{{.Pid}}</td> |
<td>{{.Pid}}</td> |
||||||
<td>{{.Description}}</td> |
<td>{{.Description}}</td> |
||||||
<td>{{DateFmtLong .Start}}</td> |
<td>{{DateFmtLong .Start}}</td> |
||||||
<td>{{TimeSince .Start $.Lang}}</td> |
<td>{{TimeSince .Start $.Lang}}</td> |
||||||
</tr> |
</tr> |
||||||
{{end}} |
{{end}} |
||||||
</tbody> |
</tbody> |
||||||
</table> |
</table> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,15 +1,15 @@ |
|||||||
<div id="setting-menu" class="grid-1-5 panel panel-radius left"> |
<div id="setting-menu" class="grid-1-5 panel panel-radius left"> |
||||||
<p class="panel-header"><strong>{{.i18n.Tr "admin_panel"}}</strong></p> |
<p class="panel-header"><strong>{{.i18n.Tr "admin_panel"}}</strong></p> |
||||||
<div class="panel-body"> |
<div class="panel-body"> |
||||||
<ul class="menu menu-vertical switching-list grid-1-5 left"> |
<ul class="menu menu-vertical switching-list grid-1-5 left"> |
||||||
<li {{if .PageIsAdminDashboard}}class="current"{{end}}><a href="{{AppSubUrl}}/admin">{{.i18n.Tr "admin.dashboard"}}</a></li> |
<li {{if .PageIsAdminDashboard}}class="current"{{end}}><a href="{{AppSubUrl}}/admin">{{.i18n.Tr "admin.dashboard"}}</a></li> |
||||||
<li {{if .PageIsAdminUsers}}class="current"{{end}}><a href="{{AppSubUrl}}/admin/users">{{.i18n.Tr "admin.users"}}</a></li> |
<li {{if .PageIsAdminUsers}}class="current"{{end}}><a href="{{AppSubUrl}}/admin/users">{{.i18n.Tr "admin.users"}}</a></li> |
||||||
<li {{if .PageIsAdminOrganizations}}class="current"{{end}}><a href="{{AppSubUrl}}/admin/orgs">{{.i18n.Tr "admin.organizations"}}</a></li> |
<li {{if .PageIsAdminOrganizations}}class="current"{{end}}><a href="{{AppSubUrl}}/admin/orgs">{{.i18n.Tr "admin.organizations"}}</a></li> |
||||||
<li {{if .PageIsAdminRepositories}}class="current"{{end}}><a href="{{AppSubUrl}}/admin/repos">{{.i18n.Tr "admin.repositories"}}</a></li> |
<li {{if .PageIsAdminRepositories}}class="current"{{end}}><a href="{{AppSubUrl}}/admin/repos">{{.i18n.Tr "admin.repositories"}}</a></li> |
||||||
<li {{if .PageIsAdminAuthentications}}class="current"{{end}}><a href="{{AppSubUrl}}/admin/auths">{{.i18n.Tr "admin.authentication"}}</a></li> |
<li {{if .PageIsAdminAuthentications}}class="current"{{end}}><a href="{{AppSubUrl}}/admin/auths">{{.i18n.Tr "admin.authentication"}}</a></li> |
||||||
<li {{if .PageIsAdminConfig}}class="current"{{end}}><a href="{{AppSubUrl}}/admin/config">{{.i18n.Tr "admin.config"}}</a></li> |
<li {{if .PageIsAdminConfig}}class="current"{{end}}><a href="{{AppSubUrl}}/admin/config">{{.i18n.Tr "admin.config"}}</a></li> |
||||||
<li {{if .PageIsAdminNotices}}class="current"{{end}}><a href="{{AppSubUrl}}/admin/notices">{{.i18n.Tr "admin.notices"}}</a></li> |
<li {{if .PageIsAdminNotices}}class="current"{{end}}><a href="{{AppSubUrl}}/admin/notices">{{.i18n.Tr "admin.notices"}}</a></li> |
||||||
<li {{if .PageIsAdminMonitor}}class="current"{{end}}><a href="{{AppSubUrl}}/admin/monitor">{{.i18n.Tr "admin.monitor"}}</a></li> |
<li {{if .PageIsAdminMonitor}}class="current"{{end}}><a href="{{AppSubUrl}}/admin/monitor">{{.i18n.Tr "admin.monitor"}}</a></li> |
||||||
</ul> |
</ul> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
@ -1,29 +1,29 @@ |
|||||||
<div class="four wide column"> |
<div class="four wide column"> |
||||||
<div class="ui vertical menu"> |
<div class="ui vertical menu"> |
||||||
<div class="header item">{{.i18n.Tr "admin_panel"}}</div> |
<div class="header item">{{.i18n.Tr "admin_panel"}}</div> |
||||||
<a class="{{if .PageIsAdminDashboard}}active{{end}} item" href="{{AppSubUrl}}/admin"> |
<a class="{{if .PageIsAdminDashboard}}active{{end}} item" href="{{AppSubUrl}}/admin"> |
||||||
{{.i18n.Tr "admin.dashboard"}} |
{{.i18n.Tr "admin.dashboard"}} |
||||||
</a> |
</a> |
||||||
<a class="{{if .PageIsAdminUsers}}active{{end}} item" href="{{AppSubUrl}}/admin/users"> |
<a class="{{if .PageIsAdminUsers}}active{{end}} item" href="{{AppSubUrl}}/admin/users"> |
||||||
{{.i18n.Tr "admin.users"}} |
{{.i18n.Tr "admin.users"}} |
||||||
</a> |
</a> |
||||||
<a class="{{if .PageIsAdminOrganizations}}active{{end}} item" href="{{AppSubUrl}}/admin/orgs"> |
<a class="{{if .PageIsAdminOrganizations}}active{{end}} item" href="{{AppSubUrl}}/admin/orgs"> |
||||||
{{.i18n.Tr "admin.organizations"}} |
{{.i18n.Tr "admin.organizations"}} |
||||||
</a> |
</a> |
||||||
<a class="{{if .PageIsAdminRepositories}}active{{end}} item" href="{{AppSubUrl}}/admin/repos"> |
<a class="{{if .PageIsAdminRepositories}}active{{end}} item" href="{{AppSubUrl}}/admin/repos"> |
||||||
{{.i18n.Tr "admin.repositories"}} |
{{.i18n.Tr "admin.repositories"}} |
||||||
</a> |
</a> |
||||||
<a class="{{if .PageIsAdminAuthentications}}active{{end}} item" href="{{AppSubUrl}}/admin/auths"> |
<a class="{{if .PageIsAdminAuthentications}}active{{end}} item" href="{{AppSubUrl}}/admin/auths"> |
||||||
{{.i18n.Tr "admin.authentication"}} |
{{.i18n.Tr "admin.authentication"}} |
||||||
</a> |
</a> |
||||||
<a class="{{if .PageIsAdminConfig}}active{{end}} item" href="{{AppSubUrl}}/admin/config"> |
<a class="{{if .PageIsAdminConfig}}active{{end}} item" href="{{AppSubUrl}}/admin/config"> |
||||||
{{.i18n.Tr "admin.config"}} |
{{.i18n.Tr "admin.config"}} |
||||||
</a> |
</a> |
||||||
<a class="{{if .PageIsAdminNotices}}active{{end}} item" href="{{AppSubUrl}}/admin/notices"> |
<a class="{{if .PageIsAdminNotices}}active{{end}} item" href="{{AppSubUrl}}/admin/notices"> |
||||||
{{.i18n.Tr "admin.notices"}} |
{{.i18n.Tr "admin.notices"}} |
||||||
</a> |
</a> |
||||||
<a class="{{if .PageIsAdminMonitor}}active{{end}} item" href="{{AppSubUrl}}/admin/monitor"> |
<a class="{{if .PageIsAdminMonitor}}active{{end}} item" href="{{AppSubUrl}}/admin/monitor"> |
||||||
{{.i18n.Tr "admin.monitor"}} |
{{.i18n.Tr "admin.monitor"}} |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
@ -1,104 +1,104 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="admin notice"> |
<div class="admin notice"> |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "admin/navbar" .}} |
{{template "admin/navbar" .}} |
||||||
<div class="twelve wide column content"> |
<div class="twelve wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.notices.system_notice_list"}} ({{.i18n.Tr "admin.total" .Total}}) |
{{.i18n.Tr "admin.notices.system_notice_list"}} ({{.i18n.Tr "admin.total" .Total}}) |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<table class="ui very basic select selectable table"> |
<table class="ui very basic select selectable table"> |
||||||
<thead> |
<thead> |
||||||
<tr> |
<tr> |
||||||
<th></th> |
<th></th> |
||||||
<th>ID</th> |
<th>ID</th> |
||||||
<th>{{.i18n.Tr "admin.notices.type"}}</th> |
<th>{{.i18n.Tr "admin.notices.type"}}</th> |
||||||
<th>{{.i18n.Tr "admin.notices.desc"}}</th> |
<th>{{.i18n.Tr "admin.notices.desc"}}</th> |
||||||
<th width="100px">{{.i18n.Tr "admin.users.created"}}</th> |
<th width="100px">{{.i18n.Tr "admin.users.created"}}</th> |
||||||
<th>{{.i18n.Tr "admin.notices.op"}}</th> |
<th>{{.i18n.Tr "admin.notices.op"}}</th> |
||||||
</tr> |
</tr> |
||||||
</thead> |
</thead> |
||||||
<tbody> |
<tbody> |
||||||
{{range .Notices}} |
{{range .Notices}} |
||||||
<tr> |
<tr> |
||||||
<td class="collapsing"> |
<td class="collapsing"> |
||||||
<div class="ui fitted checkbox" data-id="{{.ID}}"> |
<div class="ui fitted checkbox" data-id="{{.ID}}"> |
||||||
<input type="checkbox"> <label></label> |
<input type="checkbox"> <label></label> |
||||||
</div> |
</div> |
||||||
</td> |
</td> |
||||||
<td>{{.ID}}</td> |
<td>{{.ID}}</td> |
||||||
<td>{{$.i18n.Tr .TrStr}}</td> |
<td>{{$.i18n.Tr .TrStr}}</td> |
||||||
<td>{{SubStr .Description 0 120}}...</td> |
<td>{{SubStr .Description 0 120}}...</td> |
||||||
<td><span class="poping up" data-content="{{.Created}}" data-variation="inverted tiny">{{DateFmtShort .Created}}</span></td> |
<td><span class="poping up" data-content="{{.Created}}" data-variation="inverted tiny">{{DateFmtShort .Created}}</span></td> |
||||||
<td><a href="#"><i class="browser icon view-detail" data-content="{{.Description}}"></i></a></td> |
<td><a href="#"><i class="browser icon view-detail" data-content="{{.Description}}"></i></a></td> |
||||||
</tr> |
</tr> |
||||||
{{end}} |
{{end}} |
||||||
</tbody> |
</tbody> |
||||||
<tfoot class="full-width"> |
<tfoot class="full-width"> |
||||||
<tr> |
<tr> |
||||||
<th></th> |
<th></th> |
||||||
<th colspan="5"> |
<th colspan="5"> |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<a class="ui red small button" href="{{AppSubUrl}}/admin/notices/empty">{{.i18n.Tr "admin.notices.delete_all"}}</a> |
<a class="ui red small button" href="{{AppSubUrl}}/admin/notices/empty">{{.i18n.Tr "admin.notices.delete_all"}}</a> |
||||||
</div> |
</div> |
||||||
<div class="ui floating upward dropdown small button"> |
<div class="ui floating upward dropdown small button"> |
||||||
<span class="text">{{.i18n.Tr "admin.notices.actions"}}</span> |
<span class="text">{{.i18n.Tr "admin.notices.actions"}}</span> |
||||||
<div class="menu"> |
<div class="menu"> |
||||||
<div class="item select action" data-action="select-all"> |
<div class="item select action" data-action="select-all"> |
||||||
{{.i18n.Tr "admin.notices.select_all"}} |
{{.i18n.Tr "admin.notices.select_all"}} |
||||||
</div> |
</div> |
||||||
<div class="item select action" data-action="deselect-all"> |
<div class="item select action" data-action="deselect-all"> |
||||||
{{.i18n.Tr "admin.notices.deselect_all"}} |
{{.i18n.Tr "admin.notices.deselect_all"}} |
||||||
</div> |
</div> |
||||||
<div class="item select action" data-action="inverse"> |
<div class="item select action" data-action="inverse"> |
||||||
{{.i18n.Tr "admin.notices.inverse_selection"}} |
{{.i18n.Tr "admin.notices.inverse_selection"}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="ui small teal button" id="delete-selection" data-link="{{.Link}}/delete" data-redirect="{{.Link}}?page={{.Page.Current}}"> |
<div class="ui small teal button" id="delete-selection" data-link="{{.Link}}/delete" data-redirect="{{.Link}}?page={{.Page.Current}}"> |
||||||
{{.i18n.Tr "admin.notices.delete_selected"}} |
{{.i18n.Tr "admin.notices.delete_selected"}} |
||||||
</div> |
</div> |
||||||
</th> |
</th> |
||||||
</tr> |
</tr> |
||||||
</tfoot> |
</tfoot> |
||||||
</table> |
</table> |
||||||
</div> |
</div> |
||||||
|
|
||||||
{{with .Page}} |
{{with .Page}} |
||||||
{{if gt .TotalPages 1}} |
{{if gt .TotalPages 1}} |
||||||
<div class="center page buttons"> |
<div class="center page buttons"> |
||||||
<div class="ui borderless pagination menu"> |
<div class="ui borderless pagination menu"> |
||||||
<a class="{{if .IsFirst}}disabled{{end}} item" href="{{$.Link}}"><i class="angle double left icon"></i> {{$.i18n.Tr "admin.first_page"}}</a> |
<a class="{{if .IsFirst}}disabled{{end}} item" href="{{$.Link}}"><i class="angle double left icon"></i> {{$.i18n.Tr "admin.first_page"}}</a> |
||||||
<a class="{{if not .HasPrevious}}disabled{{end}} item" {{if .HasPrevious}}href="{{$.Link}}?page={{.Previous}}"{{end}}> |
<a class="{{if not .HasPrevious}}disabled{{end}} item" {{if .HasPrevious}}href="{{$.Link}}?page={{.Previous}}"{{end}}> |
||||||
<i class="left arrow icon"></i> {{$.i18n.Tr "repo.issues.previous"}} |
<i class="left arrow icon"></i> {{$.i18n.Tr "repo.issues.previous"}} |
||||||
</a> |
</a> |
||||||
{{range .Pages}} |
{{range .Pages}} |
||||||
{{if eq .Num -1}} |
{{if eq .Num -1}} |
||||||
<a class="disabled item">...</a> |
<a class="disabled item">...</a> |
||||||
{{else}} |
{{else}} |
||||||
<a class="{{if .IsCurrent}}active{{end}} item" {{if not .IsCurrent}}href="{{$.Link}}?page={{.Num}}"{{end}}>{{.Num}}</a> |
<a class="{{if .IsCurrent}}active{{end}} item" {{if not .IsCurrent}}href="{{$.Link}}?page={{.Num}}"{{end}}>{{.Num}}</a> |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
<a class="{{if not .HasNext}}disabled{{end}} item" {{if .HasNext}}href="{{$.Link}}?page={{.Next}}"{{end}}> |
<a class="{{if not .HasNext}}disabled{{end}} item" {{if .HasNext}}href="{{$.Link}}?page={{.Next}}"{{end}}> |
||||||
{{$.i18n.Tr "repo.issues.next"}} <i class="icon right arrow"></i> |
{{$.i18n.Tr "repo.issues.next"}} <i class="icon right arrow"></i> |
||||||
</a> |
</a> |
||||||
<a class="{{if .IsLast}}disabled{{end}} item" href="{{$.Link}}?page={{.TotalPages}}">{{$.i18n.Tr "admin.last_page"}} <i class="angle double right icon"></i></a> |
<a class="{{if .IsLast}}disabled{{end}} item" href="{{$.Link}}?page={{.TotalPages}}">{{$.i18n.Tr "admin.last_page"}} <i class="angle double right icon"></i></a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="ui modal" id="detail-modal"> |
<div class="ui modal" id="detail-modal"> |
||||||
<i class="close icon"></i> |
<i class="close icon"></i> |
||||||
<div class="header">{{$.i18n.Tr "admin.notices.view_detail_header"}}</div> |
<div class="header">{{$.i18n.Tr "admin.notices.view_detail_header"}}</div> |
||||||
<div class="content"> |
<div class="content"> |
||||||
<p></p> |
<p></p> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,65 +1,65 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="admin user"> |
<div class="admin user"> |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "admin/navbar" .}} |
{{template "admin/navbar" .}} |
||||||
<div class="twelve wide column content"> |
<div class="twelve wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.orgs.org_manage_panel"}} ({{.i18n.Tr "admin.total" .Total}}) |
{{.i18n.Tr "admin.orgs.org_manage_panel"}} ({{.i18n.Tr "admin.total" .Total}}) |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<table class="ui very basic striped table"> |
<table class="ui very basic striped table"> |
||||||
<thead> |
<thead> |
||||||
<tr> |
<tr> |
||||||
<th>ID</th> |
<th>ID</th> |
||||||
<th>{{.i18n.Tr "admin.orgs.name"}}</th> |
<th>{{.i18n.Tr "admin.orgs.name"}}</th> |
||||||
<th>{{.i18n.Tr "admin.orgs.teams"}}</th> |
<th>{{.i18n.Tr "admin.orgs.teams"}}</th> |
||||||
<th>{{.i18n.Tr "admin.orgs.members"}}</th> |
<th>{{.i18n.Tr "admin.orgs.members"}}</th> |
||||||
<th>{{.i18n.Tr "admin.users.repos"}}</th> |
<th>{{.i18n.Tr "admin.users.repos"}}</th> |
||||||
<th>{{.i18n.Tr "admin.users.created"}}</th> |
<th>{{.i18n.Tr "admin.users.created"}}</th> |
||||||
</tr> |
</tr> |
||||||
</thead> |
</thead> |
||||||
<tbody> |
<tbody> |
||||||
{{range .Orgs}} |
{{range .Orgs}} |
||||||
<tr> |
<tr> |
||||||
<td>{{.Id}}</td> |
<td>{{.Id}}</td> |
||||||
<td><a href="{{.HomeLink}}">{{.Name}}</a></td> |
<td><a href="{{.HomeLink}}">{{.Name}}</a></td> |
||||||
<td>{{.NumTeams}}</td> |
<td>{{.NumTeams}}</td> |
||||||
<td>{{.NumMembers}}</td> |
<td>{{.NumMembers}}</td> |
||||||
<td>{{.NumRepos}}</td> |
<td>{{.NumRepos}}</td> |
||||||
<td><span title="{{DateFmtLong .Created}}">{{DateFmtShort .Created}}</span></td> |
<td><span title="{{DateFmtLong .Created}}">{{DateFmtShort .Created}}</span></td> |
||||||
</tr> |
</tr> |
||||||
{{end}} |
{{end}} |
||||||
</tbody> |
</tbody> |
||||||
</table> |
</table> |
||||||
</div> |
</div> |
||||||
|
|
||||||
{{with .Page}} |
{{with .Page}} |
||||||
{{if gt .TotalPages 1}} |
{{if gt .TotalPages 1}} |
||||||
<div class="center page buttons"> |
<div class="center page buttons"> |
||||||
<div class="ui borderless pagination menu"> |
<div class="ui borderless pagination menu"> |
||||||
<a class="{{if .IsFirst}}disabled{{end}} item" href="{{$.Link}}"><i class="angle double left icon"></i> {{$.i18n.Tr "admin.first_page"}}</a> |
<a class="{{if .IsFirst}}disabled{{end}} item" href="{{$.Link}}"><i class="angle double left icon"></i> {{$.i18n.Tr "admin.first_page"}}</a> |
||||||
<a class="{{if not .HasPrevious}}disabled{{end}} item" {{if .HasPrevious}}href="{{$.Link}}?page={{.Previous}}"{{end}}> |
<a class="{{if not .HasPrevious}}disabled{{end}} item" {{if .HasPrevious}}href="{{$.Link}}?page={{.Previous}}"{{end}}> |
||||||
<i class="left arrow icon"></i> {{$.i18n.Tr "repo.issues.previous"}} |
<i class="left arrow icon"></i> {{$.i18n.Tr "repo.issues.previous"}} |
||||||
</a> |
</a> |
||||||
{{range .Pages}} |
{{range .Pages}} |
||||||
{{if eq .Num -1}} |
{{if eq .Num -1}} |
||||||
<a class="disabled item">...</a> |
<a class="disabled item">...</a> |
||||||
{{else}} |
{{else}} |
||||||
<a class="{{if .IsCurrent}}active{{end}} item" {{if not .IsCurrent}}href="{{$.Link}}?page={{.Num}}"{{end}}>{{.Num}}</a> |
<a class="{{if .IsCurrent}}active{{end}} item" {{if not .IsCurrent}}href="{{$.Link}}?page={{.Num}}"{{end}}>{{.Num}}</a> |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
<a class="{{if not .HasNext}}disabled{{end}} item" {{if .HasNext}}href="{{$.Link}}?page={{.Next}}"{{end}}> |
<a class="{{if not .HasNext}}disabled{{end}} item" {{if .HasNext}}href="{{$.Link}}?page={{.Next}}"{{end}}> |
||||||
{{$.i18n.Tr "repo.issues.next"}} <i class="icon right arrow"></i> |
{{$.i18n.Tr "repo.issues.next"}} <i class="icon right arrow"></i> |
||||||
</a> |
</a> |
||||||
<a class="{{if .IsLast}}disabled{{end}} item" href="{{$.Link}}?page={{.TotalPages}}">{{$.i18n.Tr "admin.last_page"}} <i class="angle double right icon"></i></a> |
<a class="{{if .IsLast}}disabled{{end}} item" href="{{$.Link}}?page={{.TotalPages}}">{{$.i18n.Tr "admin.last_page"}} <i class="angle double right icon"></i></a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,106 +1,106 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="admin edit user"> |
<div class="admin edit user"> |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "admin/navbar" .}} |
{{template "admin/navbar" .}} |
||||||
<div class="twelve wide column content"> |
<div class="twelve wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.users.edit_account"}} |
{{.i18n.Tr "admin.users.edit_account"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached segment"> |
<div class="ui attached segment"> |
||||||
<form class="ui form" action="{{.Link}}" method="post"> |
<form class="ui form" action="{{.Link}}" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<div class="inline field {{if .Err_UserName}}error{{end}}"> |
<div class="inline field {{if .Err_UserName}}error{{end}}"> |
||||||
<label for="user_name">{{.i18n.Tr "username"}}</label> |
<label for="user_name">{{.i18n.Tr "username"}}</label> |
||||||
<span>{{.User.Name}}</span> |
<span>{{.User.Name}}</span> |
||||||
</div> |
</div> |
||||||
<!-- Types and name --> |
<!-- Types and name --> |
||||||
<div class="inline required field {{if .Err_LoginType}}error{{end}}"> |
<div class="inline required field {{if .Err_LoginType}}error{{end}}"> |
||||||
<label>{{.i18n.Tr "admin.users.auth_source"}}</label> |
<label>{{.i18n.Tr "admin.users.auth_source"}}</label> |
||||||
<div class="ui selection type dropdown"> |
<div class="ui selection type dropdown"> |
||||||
<input type="hidden" id="login_type" name="login_type" value="{{.LoginSource.Type}}-{{.LoginSource.ID}}" required> |
<input type="hidden" id="login_type" name="login_type" value="{{.LoginSource.Type}}-{{.LoginSource.ID}}" required> |
||||||
<div class="text">{{.i18n.Tr "admin.users.local"}}</div> |
<div class="text">{{.i18n.Tr "admin.users.local"}}</div> |
||||||
<i class="dropdown icon"></i> |
<i class="dropdown icon"></i> |
||||||
<div class="menu"> |
<div class="menu"> |
||||||
<div class="item" data-value="0-0">{{.i18n.Tr "admin.users.local"}}</div> |
<div class="item" data-value="0-0">{{.i18n.Tr "admin.users.local"}}</div> |
||||||
{{range .Sources}} |
{{range .Sources}} |
||||||
<div class="item" data-value="{{.Type}}-{{.ID}}">{{.Name}}</div> |
<div class="item" data-value="{{.Type}}-{{.ID}}">{{.Name}}</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="required non-local field {{if .Err_LoginName}}error{{end}} {{if eq .User.LoginSource 0}}hide{{end}}"> |
<div class="required non-local field {{if .Err_LoginName}}error{{end}} {{if eq .User.LoginSource 0}}hide{{end}}"> |
||||||
<label for="login_name">{{.i18n.Tr "admin.users.auth_login_name"}}</label> |
<label for="login_name">{{.i18n.Tr "admin.users.auth_login_name"}}</label> |
||||||
<input id="login_name" name="login_name" value="{{.User.LoginName}}" autofocus> |
<input id="login_name" name="login_name" value="{{.User.LoginName}}" autofocus> |
||||||
</div> |
</div> |
||||||
<div class="field {{if .Err_FullName}}error{{end}}"> |
<div class="field {{if .Err_FullName}}error{{end}}"> |
||||||
<label for="full_name">{{.i18n.Tr "settings.full_name"}}</label> |
<label for="full_name">{{.i18n.Tr "settings.full_name"}}</label> |
||||||
<input id="full_name" name="full_name" value="{{.User.FullName}}"> |
<input id="full_name" name="full_name" value="{{.User.FullName}}"> |
||||||
</div> |
</div> |
||||||
<div class="required field {{if .Err_Email}}error{{end}}"> |
<div class="required field {{if .Err_Email}}error{{end}}"> |
||||||
<label for="email">{{.i18n.Tr "email"}}</label> |
<label for="email">{{.i18n.Tr "email"}}</label> |
||||||
<input id="email" name="email" type="email" value="{{.User.Email}}" autofocus required> |
<input id="email" name="email" type="email" value="{{.User.Email}}" autofocus required> |
||||||
</div> |
</div> |
||||||
<input class="fake" type="password"> |
<input class="fake" type="password"> |
||||||
<div class="local field {{if .Err_Password}}error{{end}} {{if not (eq .User.LoginSource 0)}}hide{{end}}"> |
<div class="local field {{if .Err_Password}}error{{end}} {{if not (eq .User.LoginSource 0)}}hide{{end}}"> |
||||||
<label for="password">{{.i18n.Tr "password"}}</label> |
<label for="password">{{.i18n.Tr "password"}}</label> |
||||||
<input id="password" name="password" type="password"> |
<input id="password" name="password" type="password"> |
||||||
<p class="help">{{.i18n.Tr "admin.users.password_helper"}}</p> |
<p class="help">{{.i18n.Tr "admin.users.password_helper"}}</p> |
||||||
</div> |
</div> |
||||||
<div class="field {{if .Err_Website}}error{{end}}"> |
<div class="field {{if .Err_Website}}error{{end}}"> |
||||||
<label for="website">{{.i18n.Tr "settings.website"}}</label> |
<label for="website">{{.i18n.Tr "settings.website"}}</label> |
||||||
<input id="website" name="website" type="url" value="{{.User.Website}}" placeholder="e.g. http://mydomain.com or https://mydomain.com"> |
<input id="website" name="website" type="url" value="{{.User.Website}}" placeholder="e.g. http://mydomain.com or https://mydomain.com"> |
||||||
</div> |
</div> |
||||||
<div class="field {{if .Err_Location}}error{{end}}"> |
<div class="field {{if .Err_Location}}error{{end}}"> |
||||||
<label for="location">{{.i18n.Tr "settings.location"}}</label> |
<label for="location">{{.i18n.Tr "settings.location"}}</label> |
||||||
<input id="location" name="location" value="{{.User.Location}}"> |
<input id="location" name="location" value="{{.User.Location}}"> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
<label><strong>{{.i18n.Tr "admin.users.is_activated"}}</strong></label> |
<label><strong>{{.i18n.Tr "admin.users.is_activated"}}</strong></label> |
||||||
<input name="active" type="checkbox" {{if .User.IsActive}}checked{{end}}> |
<input name="active" type="checkbox" {{if .User.IsActive}}checked{{end}}> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
<label><strong>{{.i18n.Tr "admin.users.is_admin"}}</strong></label> |
<label><strong>{{.i18n.Tr "admin.users.is_admin"}}</strong></label> |
||||||
<input name="admin" type="checkbox" {{if .User.IsAdmin}}checked{{end}}> |
<input name="admin" type="checkbox" {{if .User.IsAdmin}}checked{{end}}> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
<label><strong>{{.i18n.Tr "admin.users.allow_git_hook"}}</strong></label> |
<label><strong>{{.i18n.Tr "admin.users.allow_git_hook"}}</strong></label> |
||||||
<input name="allow_git_hook" type="checkbox" {{if .User.CanEditGitHook}}checked{{end}}> |
<input name="allow_git_hook" type="checkbox" {{if .User.CanEditGitHook}}checked{{end}}> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
<label><strong>{{.i18n.Tr "admin.users.allow_import_local"}}</strong></label> |
<label><strong>{{.i18n.Tr "admin.users.allow_import_local"}}</strong></label> |
||||||
<input name="allow_import_local" type="checkbox" {{if .User.CanImportLocal}}checked{{end}}> |
<input name="allow_import_local" type="checkbox" {{if .User.CanImportLocal}}checked{{end}}> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="field"> |
<div class="field"> |
||||||
<button class="ui green button">{{.i18n.Tr "admin.users.update_profile"}}</button> |
<button class="ui green button">{{.i18n.Tr "admin.users.update_profile"}}</button> |
||||||
<div class="ui red button delete-button" data-url="{{$.Link}}/delete" data-id="{{.User.Id}}">{{.i18n.Tr "admin.users.delete_account"}}</div> |
<div class="ui red button delete-button" data-url="{{$.Link}}/delete" data-id="{{.User.Id}}">{{.i18n.Tr "admin.users.delete_account"}}</div> |
||||||
</div> |
</div> |
||||||
</form> |
</form> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="ui small basic delete modal"> |
<div class="ui small basic delete modal"> |
||||||
<div class="ui icon header"> |
<div class="ui icon header"> |
||||||
<i class="trash icon"></i> |
<i class="trash icon"></i> |
||||||
{{.i18n.Tr "settings.delete_account_title"}} |
{{.i18n.Tr "settings.delete_account_title"}} |
||||||
</div> |
</div> |
||||||
<div class="content"> |
<div class="content"> |
||||||
<p>{{.i18n.Tr "settings.delete_account_desc"}}</p> |
<p>{{.i18n.Tr "settings.delete_account_desc"}}</p> |
||||||
</div> |
</div> |
||||||
{{template "base/delete_modal_actions" .}} |
{{template "base/delete_modal_actions" .}} |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,72 +1,72 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="admin user"> |
<div class="admin user"> |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "admin/navbar" .}} |
{{template "admin/navbar" .}} |
||||||
<div class="twelve wide column content"> |
<div class="twelve wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.users.user_manage_panel"}} ({{.i18n.Tr "admin.total" .Total}}) |
{{.i18n.Tr "admin.users.user_manage_panel"}} ({{.i18n.Tr "admin.total" .Total}}) |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<a class="ui blue tiny button" href="{{AppSubUrl}}/admin/users/new">{{.i18n.Tr "admin.users.new_account"}}</a> |
<a class="ui blue tiny button" href="{{AppSubUrl}}/admin/users/new">{{.i18n.Tr "admin.users.new_account"}}</a> |
||||||
</div> |
|
||||||
</h4> |
|
||||||
<div class="ui attached table segment"> |
|
||||||
<table class="ui very basic striped table"> |
|
||||||
<thead> |
|
||||||
<tr> |
|
||||||
<th>ID</th> |
|
||||||
<th>{{.i18n.Tr "admin.users.name"}}</th> |
|
||||||
<th>{{.i18n.Tr "email"}}</th> |
|
||||||
<th>{{.i18n.Tr "admin.users.activated"}}</th> |
|
||||||
<th>{{.i18n.Tr "admin.users.admin"}}</th> |
|
||||||
<th>{{.i18n.Tr "admin.users.repos"}}</th> |
|
||||||
<th>{{.i18n.Tr "admin.users.created"}}</th> |
|
||||||
<th>{{.i18n.Tr "admin.users.edit"}}</th> |
|
||||||
</tr> |
|
||||||
</thead> |
|
||||||
<tbody> |
|
||||||
{{range .Users}} |
|
||||||
<tr> |
|
||||||
<td>{{.Id}}</td> |
|
||||||
<td><a href="{{AppSubUrl}}/{{.Name}}">{{.Name}}</a></td> |
|
||||||
<td><span class="text truncate email">{{.Email}}</span></td> |
|
||||||
<td><i class="fa fa{{if .IsActive}}-check{{end}}-square-o"></i></td> |
|
||||||
<td><i class="fa fa{{if .IsAdmin}}-check{{end}}-square-o"></i></td> |
|
||||||
<td>{{.NumRepos}}</td> |
|
||||||
<td><span title="{{DateFmtLong .Created}}">{{DateFmtShort .Created }}</span></td> |
|
||||||
<td><a href="{{AppSubUrl}}/admin/users/{{.Id}}"><i class="fa fa-pencil-square-o"></i></a></td> |
|
||||||
</tr> |
|
||||||
{{end}} |
|
||||||
</tbody> |
|
||||||
</table> |
|
||||||
</div> |
|
||||||
|
|
||||||
{{with .Page}} |
|
||||||
{{if gt .TotalPages 1}} |
|
||||||
<div class="center page buttons"> |
|
||||||
<div class="ui borderless pagination menu"> |
|
||||||
<a class="{{if .IsFirst}}disabled{{end}} item" href="{{$.Link}}"><i class="angle double left icon"></i> {{$.i18n.Tr "admin.first_page"}}</a> |
|
||||||
<a class="{{if not .HasPrevious}}disabled{{end}} item" {{if .HasPrevious}}href="{{$.Link}}?page={{.Previous}}"{{end}}> |
|
||||||
<i class="left arrow icon"></i> {{$.i18n.Tr "repo.issues.previous"}} |
|
||||||
</a> |
|
||||||
{{range .Pages}} |
|
||||||
{{if eq .Num -1}} |
|
||||||
<a class="disabled item">...</a> |
|
||||||
{{else}} |
|
||||||
<a class="{{if .IsCurrent}}active{{end}} item" {{if not .IsCurrent}}href="{{$.Link}}?page={{.Num}}"{{end}}>{{.Num}}</a> |
|
||||||
{{end}} |
|
||||||
{{end}} |
|
||||||
<a class="{{if not .HasNext}}disabled{{end}} item" {{if .HasNext}}href="{{$.Link}}?page={{.Next}}"{{end}}> |
|
||||||
{{$.i18n.Tr "repo.issues.next"}} <i class="icon right arrow"></i> |
|
||||||
</a> |
|
||||||
<a class="{{if .IsLast}}disabled{{end}} item" href="{{$.Link}}?page={{.TotalPages}}">{{$.i18n.Tr "admin.last_page"}} <i class="angle double right icon"></i></a> |
|
||||||
</div> |
</div> |
||||||
|
</h4> |
||||||
|
<div class="ui attached table segment"> |
||||||
|
<table class="ui very basic striped table"> |
||||||
|
<thead> |
||||||
|
<tr> |
||||||
|
<th>ID</th> |
||||||
|
<th>{{.i18n.Tr "admin.users.name"}}</th> |
||||||
|
<th>{{.i18n.Tr "email"}}</th> |
||||||
|
<th>{{.i18n.Tr "admin.users.activated"}}</th> |
||||||
|
<th>{{.i18n.Tr "admin.users.admin"}}</th> |
||||||
|
<th>{{.i18n.Tr "admin.users.repos"}}</th> |
||||||
|
<th>{{.i18n.Tr "admin.users.created"}}</th> |
||||||
|
<th>{{.i18n.Tr "admin.users.edit"}}</th> |
||||||
|
</tr> |
||||||
|
</thead> |
||||||
|
<tbody> |
||||||
|
{{range .Users}} |
||||||
|
<tr> |
||||||
|
<td>{{.Id}}</td> |
||||||
|
<td><a href="{{AppSubUrl}}/{{.Name}}">{{.Name}}</a></td> |
||||||
|
<td><span class="text truncate email">{{.Email}}</span></td> |
||||||
|
<td><i class="fa fa{{if .IsActive}}-check{{end}}-square-o"></i></td> |
||||||
|
<td><i class="fa fa{{if .IsAdmin}}-check{{end}}-square-o"></i></td> |
||||||
|
<td>{{.NumRepos}}</td> |
||||||
|
<td><span title="{{DateFmtLong .Created}}">{{DateFmtShort .Created }}</span></td> |
||||||
|
<td><a href="{{AppSubUrl}}/admin/users/{{.Id}}"><i class="fa fa-pencil-square-o"></i></a></td> |
||||||
|
</tr> |
||||||
|
{{end}} |
||||||
|
</tbody> |
||||||
|
</table> |
||||||
</div> |
</div> |
||||||
|
|
||||||
|
{{with .Page}} |
||||||
|
{{if gt .TotalPages 1}} |
||||||
|
<div class="center page buttons"> |
||||||
|
<div class="ui borderless pagination menu"> |
||||||
|
<a class="{{if .IsFirst}}disabled{{end}} item" href="{{$.Link}}"><i class="angle double left icon"></i> {{$.i18n.Tr "admin.first_page"}}</a> |
||||||
|
<a class="{{if not .HasPrevious}}disabled{{end}} item" {{if .HasPrevious}}href="{{$.Link}}?page={{.Previous}}"{{end}}> |
||||||
|
<i class="left arrow icon"></i> {{$.i18n.Tr "repo.issues.previous"}} |
||||||
|
</a> |
||||||
|
{{range .Pages}} |
||||||
|
{{if eq .Num -1}} |
||||||
|
<a class="disabled item">...</a> |
||||||
|
{{else}} |
||||||
|
<a class="{{if .IsCurrent}}active{{end}} item" {{if not .IsCurrent}}href="{{$.Link}}?page={{.Num}}"{{end}}>{{.Num}}</a> |
||||||
|
{{end}} |
||||||
|
{{end}} |
||||||
|
<a class="{{if not .HasNext}}disabled{{end}} item" {{if .HasNext}}href="{{$.Link}}?page={{.Next}}"{{end}}> |
||||||
|
{{$.i18n.Tr "repo.issues.next"}} <i class="icon right arrow"></i> |
||||||
|
</a> |
||||||
|
<a class="{{if .IsLast}}disabled{{end}} item" href="{{$.Link}}?page={{.TotalPages}}">{{$.i18n.Tr "admin.last_page"}} <i class="angle double right icon"></i></a> |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
|
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,66 +1,66 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="admin new user"> |
<div class="admin new user"> |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "admin/navbar" .}} |
{{template "admin/navbar" .}} |
||||||
<div class="twelve wide column content"> |
<div class="twelve wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "admin.users.new_account"}} |
{{.i18n.Tr "admin.users.new_account"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached segment"> |
<div class="ui attached segment"> |
||||||
<form class="ui form" action="{{.Link}}" method="post"> |
<form class="ui form" action="{{.Link}}" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<!-- Types and name --> |
<!-- Types and name --> |
||||||
<div class="inline required field {{if .Err_LoginType}}error{{end}}"> |
<div class="inline required field {{if .Err_LoginType}}error{{end}}"> |
||||||
<label>{{.i18n.Tr "admin.users.auth_source"}}</label> |
<label>{{.i18n.Tr "admin.users.auth_source"}}</label> |
||||||
<div class="ui selection type dropdown"> |
<div class="ui selection type dropdown"> |
||||||
<input type="hidden" id="login_type" name="login_type" value="{{.login_type}}" data-password="required" required> |
<input type="hidden" id="login_type" name="login_type" value="{{.login_type}}" data-password="required" required> |
||||||
<div class="text">{{.i18n.Tr "admin.users.local"}}</div> |
<div class="text">{{.i18n.Tr "admin.users.local"}}</div> |
||||||
<i class="dropdown icon"></i> |
<i class="dropdown icon"></i> |
||||||
<div class="menu"> |
<div class="menu"> |
||||||
<div class="item" data-value="0-0">{{.i18n.Tr "admin.users.local"}}</div> |
<div class="item" data-value="0-0">{{.i18n.Tr "admin.users.local"}}</div> |
||||||
{{range .Sources}} |
{{range .Sources}} |
||||||
<div class="item" data-value="{{.Type}}-{{.ID}}">{{.Name}}</div> |
<div class="item" data-value="{{.Type}}-{{.ID}}">{{.Name}}</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="required non-local field {{if .Err_LoginName}}error{{end}} {{if eq .login_type "0-0"}}hide{{end}}"> |
<div class="required non-local field {{if .Err_LoginName}}error{{end}} {{if eq .login_type "0-0"}}hide{{end}}"> |
||||||
<label for="login_name">{{.i18n.Tr "admin.users.auth_login_name"}}</label> |
<label for="login_name">{{.i18n.Tr "admin.users.auth_login_name"}}</label> |
||||||
<input id="login_name" name="login_name" value="{{.login_name}}"> |
<input id="login_name" name="login_name" value="{{.login_name}}"> |
||||||
</div> |
</div> |
||||||
<div class="required field {{if .Err_UserName}}error{{end}}"> |
<div class="required field {{if .Err_UserName}}error{{end}}"> |
||||||
<label for="user_name">{{.i18n.Tr "username"}}</label> |
<label for="user_name">{{.i18n.Tr "username"}}</label> |
||||||
<input id="user_name" name="user_name" value="{{.user_name}}" autofocus required> |
<input id="user_name" name="user_name" value="{{.user_name}}" autofocus required> |
||||||
</div> |
</div> |
||||||
<div class="required field {{if .Err_Email}}error{{end}}"> |
<div class="required field {{if .Err_Email}}error{{end}}"> |
||||||
<label for="email">{{.i18n.Tr "email"}}</label> |
<label for="email">{{.i18n.Tr "email"}}</label> |
||||||
<input id="email" name="email" type="email" value="{{.email}}" required> |
<input id="email" name="email" type="email" value="{{.email}}" required> |
||||||
</div> |
</div> |
||||||
<input class="fake" type="password"> |
<input class="fake" type="password"> |
||||||
<div class="required local field {{if .Err_Password}}error{{end}} {{if not (eq .login_type "0-0")}}hide{{end}}"> |
<div class="required local field {{if .Err_Password}}error{{end}} {{if not (eq .login_type "0-0")}}hide{{end}}"> |
||||||
<label for="password">{{.i18n.Tr "password"}}</label> |
<label for="password">{{.i18n.Tr "password"}}</label> |
||||||
<input id="password" name="password" type="password" value="{{.password}}" {{if eq .login_type "0-0"}}required{{end}}> |
<input id="password" name="password" type="password" value="{{.password}}" {{if eq .login_type "0-0"}}required{{end}}> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<!-- Send register notify e-mail --> |
<!-- Send register notify e-mail --> |
||||||
{{if .CanSendEmail}} |
{{if .CanSendEmail}} |
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
<label><strong>{{.i18n.Tr "admin.users.send_register_notify"}}</strong></label> |
<label><strong>{{.i18n.Tr "admin.users.send_register_notify"}}</strong></label> |
||||||
<input name="send_notify" type="checkbox" {{if .send_notify}}checked{{end}}> |
<input name="send_notify" type="checkbox" {{if .send_notify}}checked{{end}}> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
|
|
||||||
<div class="field"> |
<div class="field"> |
||||||
<button class="ui green button">{{.i18n.Tr "admin.users.new_account"}}</button> |
<button class="ui green button">{{.i18n.Tr "admin.users.new_account"}}</button> |
||||||
</div> |
</div> |
||||||
</form> |
</form> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,15 +1,15 @@ |
|||||||
{{if .Flash.ErrorMsg}} |
{{if .Flash.ErrorMsg}} |
||||||
<div class="ui negative message"> |
<div class="ui negative message"> |
||||||
<p>{{.Flash.ErrorMsg}}</p> |
<p>{{.Flash.ErrorMsg}}</p> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
{{if .Flash.SuccessMsg}} |
{{if .Flash.SuccessMsg}} |
||||||
<div class="ui positive message"> |
<div class="ui positive message"> |
||||||
<p>{{.Flash.SuccessMsg}}</p> |
<p>{{.Flash.SuccessMsg}}</p> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
{{if .Flash.InfoMsg}} |
{{if .Flash.InfoMsg}} |
||||||
<div class="ui info message"> |
<div class="ui info message"> |
||||||
<p>{{.Flash.InfoMsg}}</p> |
<p>{{.Flash.InfoMsg}}</p> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
|
@ -1,10 +1,10 @@ |
|||||||
<div class="actions"> |
<div class="actions"> |
||||||
<div class="ui red basic inverted cancel button"> |
<div class="ui red basic inverted cancel button"> |
||||||
<i class="remove icon"></i> |
<i class="remove icon"></i> |
||||||
{{.i18n.Tr "modal.no"}} |
{{.i18n.Tr "modal.no"}} |
||||||
</div> |
</div> |
||||||
<div class="ui green basic inverted ok button"> |
<div class="ui green basic inverted ok button"> |
||||||
<i class="checkmark icon"></i> |
<i class="checkmark icon"></i> |
||||||
{{.i18n.Tr "modal.yes"}} |
{{.i18n.Tr "modal.yes"}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
@ -1,23 +1,23 @@ |
|||||||
<div class="ui repository list"> |
<div class="ui repository list"> |
||||||
{{range .Repos}} |
{{range .Repos}} |
||||||
<div class="item"> |
<div class="item"> |
||||||
<div class="ui header"> |
<div class="ui header"> |
||||||
<a href="{{AppSubUrl}}/{{if .Owner}}{{.Owner.Name}}{{else if $.Org}}{{$.Org.Name}}{{else}}{{$.Owner.Name}}{{end}}/{{.Name}}">{{if $.PageIsExplore}}{{.Owner.Name}} / {{end}}{{.Name}}</a> |
<a href="{{AppSubUrl}}/{{if .Owner}}{{.Owner.Name}}{{else if $.Org}}{{$.Org.Name}}{{else}}{{$.Owner.Name}}{{end}}/{{.Name}}">{{if $.PageIsExplore}}{{.Owner.Name}} / {{end}}{{.Name}}</a> |
||||||
{{if .IsPrivate}} |
{{if .IsPrivate}} |
||||||
<span class="text gold"><i class="icon octicon octicon-lock"></i></span> |
<span class="text gold"><i class="icon octicon octicon-lock"></i></span> |
||||||
{{else if .IsFork}} |
{{else if .IsFork}} |
||||||
<span><i class="icon octicon octicon-repo-forked"></i></span> |
<span><i class="icon octicon octicon-repo-forked"></i></span> |
||||||
{{else if .IsMirror}} |
{{else if .IsMirror}} |
||||||
<span><i class="icon octicon octicon-repo-clone"></i></span> |
<span><i class="icon octicon octicon-repo-clone"></i></span> |
||||||
{{end}} |
{{end}} |
||||||
|
|
||||||
<div class="ui right metas"> |
<div class="ui right metas"> |
||||||
<span class="text grey"><i class="octicon octicon-star"></i> {{.NumStars}}</span> |
<span class="text grey"><i class="octicon octicon-star"></i> {{.NumStars}}</span> |
||||||
<span class="text grey"><i class="octicon octicon-git-branch"></i> {{.NumForks}}</span> |
<span class="text grey"><i class="octicon octicon-git-branch"></i> {{.NumForks}}</span> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{if .Description}}<p>{{.Description}}</p>{{end}} |
{{if .Description}}<p>{{.Description}}</p>{{end}} |
||||||
<p class="time">{{$.i18n.Tr "org.repo_updated"}} {{TimeSince .Updated $.i18n.Lang}}</p> |
<p class="time">{{$.i18n.Tr "org.repo_updated"}} {{TimeSince .Updated $.i18n.Lang}}</p> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
|
@ -1,15 +1,15 @@ |
|||||||
<!DOCTYPE html> |
<!DOCTYPE html> |
||||||
<html> |
<html> |
||||||
<head> |
<head> |
||||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
||||||
<title>{{.User.Name}}, please activate your account</title> |
<title>{{.User.Name}}, please activate your account</title> |
||||||
</head> |
</head> |
||||||
|
|
||||||
<body> |
<body> |
||||||
<p>Hi <b>{{.User.Name}}</b>, thanks for registering at {{.AppName}}!</p> |
<p>Hi <b>{{.User.Name}}</b>, thanks for registering at {{.AppName}}!</p> |
||||||
<p>Please click the following link to verify your e-mail address within <b>{{.ActiveCodeLives}} hours</b>:</p> |
<p>Please click the following link to verify your e-mail address within <b>{{.ActiveCodeLives}} hours</b>:</p> |
||||||
<p><a href="{{.AppUrl}}user/activate?code={{.Code}}">{{.AppUrl}}user/activate?code={{.Code}}</a></p> |
<p><a href="{{.AppUrl}}user/activate?code={{.Code}}">{{.AppUrl}}user/activate?code={{.Code}}</a></p> |
||||||
<p>Not working? Try copying and pasting it to your browser.</p> |
<p>Not working? Try copying and pasting it to your browser.</p> |
||||||
<p>© 2015 <a target="_blank" href="http://gogs.io">Gogs: Go Git Service</a></p> |
<p>© 2015 <a target="_blank" href="http://gogs.io">Gogs: Go Git Service</a></p> |
||||||
</body> |
</body> |
||||||
</html> |
</html> |
||||||
|
@ -1,15 +1,15 @@ |
|||||||
<!DOCTYPE html> |
<!DOCTYPE html> |
||||||
<html> |
<html> |
||||||
<head> |
<head> |
||||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
||||||
<title>{{.User.Name}}, please verify your e-mail address</title> |
<title>{{.User.Name}}, please verify your e-mail address</title> |
||||||
</head> |
</head> |
||||||
|
|
||||||
<body> |
<body> |
||||||
<p>Hi <b>{{.User.Name}}</b>,</p> |
<p>Hi <b>{{.User.Name}}</b>,</p> |
||||||
<p>Please click the following link to verify your e-mail address within <b>{{.ActiveCodeLives}} hours</b>:</p> |
<p>Please click the following link to verify your e-mail address within <b>{{.ActiveCodeLives}} hours</b>:</p> |
||||||
<p><a href="{{.AppUrl}}user/activate_email?code={{.Code}}&email={{.Email}}">{{.AppUrl}}user/activate_email?code={{.Code}}&email={{.Email}}</a></p> |
<p><a href="{{.AppUrl}}user/activate_email?code={{.Code}}&email={{.Email}}">{{.AppUrl}}user/activate_email?code={{.Code}}&email={{.Email}}</a></p> |
||||||
<p>Not working? Try copying and pasting it to your browser.</p> |
<p>Not working? Try copying and pasting it to your browser.</p> |
||||||
<p>© 2015 <a target="_blank" href="http://gogs.io">Gogs: Go Git Service</a></p> |
<p>© 2015 <a target="_blank" href="http://gogs.io">Gogs: Go Git Service</a></p> |
||||||
</body> |
</body> |
||||||
</html> |
</html> |
||||||
|
@ -1,14 +1,14 @@ |
|||||||
<!DOCTYPE html> |
<!DOCTYPE html> |
||||||
<html> |
<html> |
||||||
<head> |
<head> |
||||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
||||||
<title>{{.User.Name}}, welcome to {{.AppName}}</title> |
<title>{{.User.Name}}, welcome to {{.AppName}}</title> |
||||||
</head> |
</head> |
||||||
|
|
||||||
<body> |
<body> |
||||||
<p>Hi <b>{{.User.Name}}</b>, this is your registration confirmation email for {{.AppName}}!</p> |
<p>Hi <b>{{.User.Name}}</b>, this is your registration confirmation email for {{.AppName}}!</p> |
||||||
<p>You can now login via username: {{.User.Name}}.</p> |
<p>You can now login via username: {{.User.Name}}.</p> |
||||||
<p><a href="{{.AppUrl}}user/login">{{.AppUrl}}user/login</a></p> |
<p><a href="{{.AppUrl}}user/login">{{.AppUrl}}user/login</a></p> |
||||||
<p>© 2015 <a target="_blank" href="http://gogs.io">Gogs: Go Git Service</a></p> |
<p>© 2015 <a target="_blank" href="http://gogs.io">Gogs: Go Git Service</a></p> |
||||||
</body> |
</body> |
||||||
</html> |
</html> |
||||||
|
@ -1,15 +1,15 @@ |
|||||||
<!DOCTYPE html> |
<!DOCTYPE html> |
||||||
<html> |
<html> |
||||||
<head> |
<head> |
||||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
||||||
<title>{{.User.Name}}, you have requested to reset your password</title> |
<title>{{.User.Name}}, you have requested to reset your password</title> |
||||||
</head> |
</head> |
||||||
|
|
||||||
<body> |
<body> |
||||||
<p>Hi <b>{{.User.Name}}</b>,</p> |
<p>Hi <b>{{.User.Name}}</b>,</p> |
||||||
<p>Please click the following link to verify your e-mail address within <b>{{.ActiveCodeLives}} hours</b>:</p> |
<p>Please click the following link to verify your e-mail address within <b>{{.ActiveCodeLives}} hours</b>:</p> |
||||||
<p><a href="{{.AppUrl}}user/reset_password?code={{.Code}}">{{.AppUrl}}user/reset_password?code={{.Code}}</a></p> |
<p><a href="{{.AppUrl}}user/reset_password?code={{.Code}}">{{.AppUrl}}user/reset_password?code={{.Code}}</a></p> |
||||||
<p>Not working? Try copying and pasting it to your browser.</p> |
<p>Not working? Try copying and pasting it to your browser.</p> |
||||||
<p>© 2015 <a target="_blank" href="http://gogs.io">Gogs: Go Git Service</a></p> |
<p>© 2015 <a target="_blank" href="http://gogs.io">Gogs: Go Git Service</a></p> |
||||||
</body> |
</body> |
||||||
</html> |
</html> |
||||||
|
@ -1,16 +1,16 @@ |
|||||||
<!DOCTYPE html> |
<!DOCTYPE html> |
||||||
<html> |
<html> |
||||||
<head> |
<head> |
||||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
||||||
<title>{{.Subject}}</title> |
<title>{{.Subject}}</title> |
||||||
</head> |
</head> |
||||||
|
|
||||||
<body> |
<body> |
||||||
<p>You are now a collaborator of this repository.</p> |
<p>You are now a collaborator of this repository.</p> |
||||||
<p> |
<p> |
||||||
--- |
--- |
||||||
<br> |
<br> |
||||||
View it on Gogs: <a href="{{.AppUrl}}{{.RepoLink}}">{{.RepoLink}}</a> |
View it on Gogs: <a href="{{.AppUrl}}{{.RepoLink}}">{{.RepoLink}}</a> |
||||||
</p> |
</p> |
||||||
</body> |
</body> |
||||||
</html> |
</html> |
||||||
|
@ -1,17 +1,17 @@ |
|||||||
<!DOCTYPE html> |
<!DOCTYPE html> |
||||||
<html> |
<html> |
||||||
<head> |
<head> |
||||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
||||||
<title>{{.Subject}}</title> |
<title>{{.Subject}}</title> |
||||||
</head> |
</head> |
||||||
|
|
||||||
<body> |
<body> |
||||||
<p>@{{.ActUserName}} mentioned you:</p> |
<p>@{{.ActUserName}} mentioned you:</p> |
||||||
<p>{{.Content | Str2html}}</p> |
<p>{{.Content | Str2html}}</p> |
||||||
<p> |
<p> |
||||||
--- |
--- |
||||||
<br> |
<br> |
||||||
<a href="{{.AppUrl}}{{.IssueLink}}">View it on Gogs</a>. |
<a href="{{.AppUrl}}{{.IssueLink}}">View it on Gogs</a>. |
||||||
</p> |
</p> |
||||||
</body> |
</body> |
||||||
</html> |
</html> |
||||||
|
@ -1,30 +1,30 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="organization new org"> |
<div class="organization new org"> |
||||||
<div class="ui middle very relaxed page grid"> |
<div class="ui middle very relaxed page grid"> |
||||||
<div class="column"> |
<div class="column"> |
||||||
<form class="ui form" action="{{.Link}}" method="post"> |
<form class="ui form" action="{{.Link}}" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<h3 class="ui top attached header"> |
<h3 class="ui top attached header"> |
||||||
{{.i18n.Tr "new_org"}} |
{{.i18n.Tr "new_org"}} |
||||||
</h3> |
</h3> |
||||||
<div class="ui attached segment"> |
<div class="ui attached segment"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<div class="inline required field {{if .Err_OrgName}}error{{end}}"> |
<div class="inline required field {{if .Err_OrgName}}error{{end}}"> |
||||||
<label for="org_name">{{.i18n.Tr "org.org_name_holder"}}</label> |
<label for="org_name">{{.i18n.Tr "org.org_name_holder"}}</label> |
||||||
<input id="org_name" name="org_name" value="{{.org_name}}" autofocus required> |
<input id="org_name" name="org_name" value="{{.org_name}}" autofocus required> |
||||||
<span class="help">{{.i18n.Tr "org.org_name_helper"}}</span> |
<span class="help">{{.i18n.Tr "org.org_name_helper"}}</span> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<label></label> |
<label></label> |
||||||
<button class="ui green button"> |
<button class="ui green button"> |
||||||
{{.i18n.Tr "org.create_org"}} |
{{.i18n.Tr "org.create_org"}} |
||||||
</button> |
</button> |
||||||
<a class="ui button" href="{{AppSubUrl}}/">{{.i18n.Tr "cancel"}}</a> |
<a class="ui button" href="{{AppSubUrl}}/">{{.i18n.Tr "cancel"}}</a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</form> |
</form> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,26 +1,26 @@ |
|||||||
{{with .Org}} |
{{with .Org}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui vertically grid head"> |
<div class="ui vertically grid head"> |
||||||
<div class="column"> |
<div class="column"> |
||||||
<div class="ui header"> |
<div class="ui header"> |
||||||
<img class="ui image" src="{{.AvatarLink}}?s=100"> |
<img class="ui image" src="{{.AvatarLink}}?s=100"> |
||||||
<span class="text thin grey"><a href="{{.HomeLink}}">{{.DisplayName}}</a></span> |
<span class="text thin grey"><a href="{{.HomeLink}}">{{.DisplayName}}</a></span> |
||||||
|
|
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<div class="ui menu"> |
<div class="ui menu"> |
||||||
<a class="{{if $.PageIsOrgMembers}}active{{end}} item" href="{{$.OrgLink}}/members"> |
<a class="{{if $.PageIsOrgMembers}}active{{end}} item" href="{{$.OrgLink}}/members"> |
||||||
<i class="octicon octicon-organization"></i> {{$.i18n.Tr "org.people"}} |
<i class="octicon octicon-organization"></i> {{$.i18n.Tr "org.people"}} |
||||||
<div class="floating ui black label">{{.NumMembers}}</div> |
<div class="floating ui black label">{{.NumMembers}}</div> |
||||||
</a> |
</a> |
||||||
<a class="{{if $.PageIsOrgTeams}}active{{end}} item" href="{{$.OrgLink}}/teams"> |
<a class="{{if $.PageIsOrgTeams}}active{{end}} item" href="{{$.OrgLink}}/teams"> |
||||||
<i class="octicon octicon-jersey"></i> {{$.i18n.Tr "org.teams"}} |
<i class="octicon octicon-jersey"></i> {{$.i18n.Tr "org.teams"}} |
||||||
<div class="floating ui black label">{{.NumTeams}}</div> |
<div class="floating ui black label">{{.NumTeams}}</div> |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
|
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
<div class="ui divider"></div> |
||||||
<div class="ui divider"></div> |
{{end}} |
||||||
{{end}} |
|
||||||
|
@ -1,85 +1,85 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="organization profile"> |
<div class="organization profile"> |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
<div class="ui sixteen wide column"> |
<div class="ui sixteen wide column"> |
||||||
<img class="ui left" id="org-avatar" src="{{.Org.AvatarLink}}?s=140"/> |
<img class="ui left" id="org-avatar" src="{{.Org.AvatarLink}}?s=140"/> |
||||||
<div id="org-info"> |
<div id="org-info"> |
||||||
<div class="ui header"> |
<div class="ui header"> |
||||||
{{.Org.FullName}} |
{{.Org.FullName}} |
||||||
{{if .IsOrganizationOwner}}<a class="text grey" href="{{.OrgLink}}/settings"><span class="icon octicon octicon-gear"></span></a>{{end}} |
{{if .IsOrganizationOwner}}<a class="text grey" href="{{.OrgLink}}/settings"><span class="icon octicon octicon-gear"></span></a>{{end}} |
||||||
</div> |
</div> |
||||||
{{if .Org.Description}}<p class="desc">{{.Org.Description}}</p>{{end}} |
{{if .Org.Description}}<p class="desc">{{.Org.Description}}</p>{{end}} |
||||||
<div class="text grey meta"> |
<div class="text grey meta"> |
||||||
{{if .Org.Location}}<div class="item"><span class="icon octicon octicon-location"></span> <span>{{.Org.Location}}</span></div>{{end}} |
{{if .Org.Location}}<div class="item"><span class="icon octicon octicon-location"></span> <span>{{.Org.Location}}</span></div>{{end}} |
||||||
{{if .Org.Website}}<div class="item"><span class="icon octicon octicon-link"></span> <a target="_blank" href="{{.Org.Website}}">{{.Org.Website}}</a></div>{{end}} |
{{if .Org.Website}}<div class="item"><span class="icon octicon octicon-link"></span> <a target="_blank" href="{{.Org.Website}}">{{.Org.Website}}</a></div>{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
|
|
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
<div class="ui eleven wide column"> |
<div class="ui eleven wide column"> |
||||||
{{if .IsOrganizationOwner}} |
{{if .IsOrganizationOwner}} |
||||||
<div class="text right"> |
<div class="text right"> |
||||||
<a class="ui green button" href="{{AppSubUrl}}/repo/create?org={{.Org.Id}}"><i class="octicon octicon-repo-create"></i> {{.i18n.Tr "new_repo"}}</a> |
<a class="ui green button" href="{{AppSubUrl}}/repo/create?org={{.Org.Id}}"><i class="octicon octicon-repo-create"></i> {{.i18n.Tr "new_repo"}}</a> |
||||||
</div> |
</div> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
{{end}} |
{{end}} |
||||||
{{template "explore/repo_list" .}} |
{{template "explore/repo_list" .}} |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="ui five wide column"> |
<div class="ui five wide column"> |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
<strong>{{.i18n.Tr "org.people"}}</strong> |
<strong>{{.i18n.Tr "org.people"}}</strong> |
||||||
{{if .IsOrganizationMember}} |
{{if .IsOrganizationMember}} |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<a class="text grey" href="{{.OrgLink}}/members"><strong>{{.Org.NumMembers}}</strong><span class="octicon octicon-chevron-right"></span></a> |
<a class="text grey" href="{{.OrgLink}}/members"><strong>{{.Org.NumMembers}}</strong><span class="octicon octicon-chevron-right"></span></a> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached segment members"> |
<div class="ui attached segment members"> |
||||||
{{$isMember := .IsOrganizationMember}} |
{{$isMember := .IsOrganizationMember}} |
||||||
{{range .Members}} |
{{range .Members}} |
||||||
{{if or $isMember (.IsPublicMember $.Org.Id)}} |
{{if or $isMember (.IsPublicMember $.Org.Id)}} |
||||||
<a href="{{.HomeLink}}" title="{{.Name}}"><img class="ui avatar" src="{{.AvatarLink}}"></a> |
<a href="{{.HomeLink}}" title="{{.Name}}"><img class="ui avatar" src="{{.AvatarLink}}"></a> |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
{{if .IsOrganizationOwner}} |
{{if .IsOrganizationOwner}} |
||||||
<div class="ui bottom attached segment"> |
<div class="ui bottom attached segment"> |
||||||
<a class="ui blue small button" href="{{.OrgLink}}/invitations/new">{{.i18n.Tr "org.invite_someone"}}</a> |
<a class="ui blue small button" href="{{.OrgLink}}/invitations/new">{{.i18n.Tr "org.invite_someone"}}</a> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
|
|
||||||
{{if .IsOrganizationMember}} |
{{if .IsOrganizationMember}} |
||||||
<div class="ui top attached header"> |
<div class="ui top attached header"> |
||||||
<strong>{{.i18n.Tr "org.teams"}}</strong> |
<strong>{{.i18n.Tr "org.teams"}}</strong> |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<a class="text grey" href="{{.OrgLink}}/teams"><strong>{{.Org.NumTeams}}</strong><span class="octicon octicon-chevron-right"></span></a> |
<a class="text grey" href="{{.OrgLink}}/teams"><strong>{{.Org.NumTeams}}</strong><span class="octicon octicon-chevron-right"></span></a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="ui attached table segment teams"> |
<div class="ui attached table segment teams"> |
||||||
{{range .Teams}} |
{{range .Teams}} |
||||||
<div class="item"> |
<div class="item"> |
||||||
<a href="{{$.OrgLink}}/teams/{{.LowerName}}"><strong class="team-name">{{.Name}}</strong></a> |
<a href="{{$.OrgLink}}/teams/{{.LowerName}}"><strong class="team-name">{{.Name}}</strong></a> |
||||||
<p class="text grey">{{.NumMembers}} {{$.i18n.Tr "org.lower_members"}} · {{.NumRepos}} {{$.i18n.Tr "org.lower_repositories"}}</p> |
<p class="text grey">{{.NumMembers}} {{$.i18n.Tr "org.lower_members"}} · {{.NumRepos}} {{$.i18n.Tr "org.lower_repositories"}}</p> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
{{if .IsOrganizationOwner}} |
{{if .IsOrganizationOwner}} |
||||||
<div class="ui bottom attached segment"> |
<div class="ui bottom attached segment"> |
||||||
<a class="ui blue small button" href="{{.OrgLink}}/teams/new">{{.i18n.Tr "org.create_new_team"}}</a> |
<a class="ui blue small button" href="{{.OrgLink}}/teams/new">{{.i18n.Tr "org.create_new_team"}}</a> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,23 +1,23 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="organization invite"> |
<div class="organization invite"> |
||||||
{{template "org/header" .}} |
{{template "org/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div id="invite-box"> |
<div id="invite-box"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h2>{{.i18n.Tr "org.members.invite_desc" .Org.DisplayName}}</h2> |
<h2>{{.i18n.Tr "org.members.invite_desc" .Org.DisplayName}}</h2> |
||||||
<form class="ui form" action="{{.Link}}" method="post"> |
<form class="ui form" action="{{.Link}}" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<div class="inline field ui left"> |
<div class="inline field ui left"> |
||||||
<div id="search-user-box"> |
<div id="search-user-box"> |
||||||
<div class="ui input"> |
<div class="ui input"> |
||||||
<input class="prompt" name="uname" placeholder="{{.i18n.Tr "repo.settings.search_user_placeholder"}}" autocomplete="off" autofocus required> |
<input class="prompt" name="uname" placeholder="{{.i18n.Tr "repo.settings.search_user_placeholder"}}" autocomplete="off" autofocus required> |
||||||
</div> |
</div> |
||||||
<div class="ui segment results hide"></div> |
<div class="ui segment results hide"></div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<button class="ui blue button">{{.i18n.Tr "org.members.invite_now"}}</button> |
<button class="ui blue button">{{.i18n.Tr "org.members.invite_now"}}</button> |
||||||
</form> |
</form> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,60 +1,60 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="organization members"> |
<div class="organization members"> |
||||||
{{template "org/header" .}} |
{{template "org/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
{{if .IsOrganizationOwner}} |
{{if .IsOrganizationOwner}} |
||||||
<div class="text right"> |
<div class="text right"> |
||||||
<a class="ui blue button" href="{{.OrgLink}}/invitations/new"><i class="octicon octicon-repo-create"></i> {{.i18n.Tr "org.invite_someone"}}</a> |
<a class="ui blue button" href="{{.OrgLink}}/invitations/new"><i class="octicon octicon-repo-create"></i> {{.i18n.Tr "org.invite_someone"}}</a> |
||||||
</div> |
</div> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
{{end}} |
{{end}} |
||||||
|
|
||||||
<div class="list"> |
<div class="list"> |
||||||
{{range .Members}} |
{{range .Members}} |
||||||
<div class="item ui grid"> |
<div class="item ui grid"> |
||||||
<div class="ui one wide column"> |
<div class="ui one wide column"> |
||||||
<img class="ui avatar" src="{{.AvatarLink}}?s=48"> |
<img class="ui avatar" src="{{.AvatarLink}}?s=48"> |
||||||
</div> |
|
||||||
<div class="ui three wide column"> |
|
||||||
<div class="meta"><a href="{{.HomeLink}}">{{.Name}}</a></div> |
|
||||||
<div class="meta">{{.FullName}}</div> |
|
||||||
</div> |
|
||||||
<div class="ui five wide column center"> |
|
||||||
<div class="meta"> |
|
||||||
{{$.i18n.Tr "org.members.membership_visibility"}} |
|
||||||
</div> |
</div> |
||||||
<div class="meta"> |
<div class="ui three wide column"> |
||||||
{{ $isPublic := .IsPublicMember $.Org.Id}} |
<div class="meta"><a href="{{.HomeLink}}">{{.Name}}</a></div> |
||||||
{{if $isPublic}} |
<div class="meta">{{.FullName}}</div> |
||||||
<strong>{{$.i18n.Tr "org.members.public"}}</strong> |
|
||||||
{{if or (eq $.SignedUser.Id .Id) $.IsOrganizationOwner}}(<a href="{{$.OrgLink}}/members/action/private?uid={{.Id}}">{{$.i18n.Tr "org.members.public_helper"}}</a>){{end}} |
|
||||||
{{else}} |
|
||||||
<strong>{{$.i18n.Tr "org.members.private"}}</strong> |
|
||||||
{{if or (eq $.SignedUser.Id .Id) $.IsOrganizationOwner}}(<a href="{{$.OrgLink}}/members/action/public?uid={{.Id}}">{{$.i18n.Tr "org.members.private_helper"}}</a>){{end}} |
|
||||||
{{end}} |
|
||||||
</div> |
</div> |
||||||
</div> |
<div class="ui five wide column center"> |
||||||
<div class="ui three wide column center"> |
<div class="meta"> |
||||||
<div class="meta"> |
{{$.i18n.Tr "org.members.membership_visibility"}} |
||||||
{{$.i18n.Tr "org.members.member_role"}} |
</div> |
||||||
|
<div class="meta"> |
||||||
|
{{ $isPublic := .IsPublicMember $.Org.Id}} |
||||||
|
{{if $isPublic}} |
||||||
|
<strong>{{$.i18n.Tr "org.members.public"}}</strong> |
||||||
|
{{if or (eq $.SignedUser.Id .Id) $.IsOrganizationOwner}}(<a href="{{$.OrgLink}}/members/action/private?uid={{.Id}}">{{$.i18n.Tr "org.members.public_helper"}}</a>){{end}} |
||||||
|
{{else}} |
||||||
|
<strong>{{$.i18n.Tr "org.members.private"}}</strong> |
||||||
|
{{if or (eq $.SignedUser.Id .Id) $.IsOrganizationOwner}}(<a href="{{$.OrgLink}}/members/action/public?uid={{.Id}}">{{$.i18n.Tr "org.members.private_helper"}}</a>){{end}} |
||||||
|
{{end}} |
||||||
|
</div> |
||||||
</div> |
</div> |
||||||
<div class="meta"> |
<div class="ui three wide column center"> |
||||||
<strong>{{if .IsUserOrgOwner $.Org.Id}}<span class="octicon octicon-shield"></span> {{$.i18n.Tr "org.members.owner"}}{{else}}{{$.i18n.Tr "org.members.member"}}{{end}}</strong> |
<div class="meta"> |
||||||
|
{{$.i18n.Tr "org.members.member_role"}} |
||||||
|
</div> |
||||||
|
<div class="meta"> |
||||||
|
<strong>{{if .IsUserOrgOwner $.Org.Id}}<span class="octicon octicon-shield"></span> {{$.i18n.Tr "org.members.owner"}}{{else}}{{$.i18n.Tr "org.members.member"}}{{end}}</strong> |
||||||
|
</div> |
||||||
</div> |
</div> |
||||||
</div> |
<div class="ui four wide column"> |
||||||
<div class="ui four wide column"> |
<div class="text right"> |
||||||
<div class="text right"> |
{{if eq $.SignedUser.Id .Id}} |
||||||
{{if eq $.SignedUser.Id .Id}} |
<a class="ui red small button" href="{{$.OrgLink}}/members/action/leave?uid={{.Id}}">{{$.i18n.Tr "org.members.leave"}}</a> |
||||||
<a class="ui red small button" href="{{$.OrgLink}}/members/action/leave?uid={{.Id}}">{{$.i18n.Tr "org.members.leave"}}</a> |
{{else if $.IsOrganizationOwner}} |
||||||
{{else if $.IsOrganizationOwner}} |
<a class="ui red small button" href="{{$.OrgLink}}/members/action/remove?uid={{.Id}}">{{$.i18n.Tr "org.members.remove"}}</a> |
||||||
<a class="ui red small button" href="{{$.OrgLink}}/members/action/remove?uid={{.Id}}">{{$.i18n.Tr "org.members.remove"}}</a> |
{{end}} |
||||||
{{end}} |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
|
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,43 +1,43 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="organization settings delete"> |
<div class="organization settings delete"> |
||||||
{{template "org/header" .}} |
{{template "org/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "org/settings/navbar" .}} |
{{template "org/settings/navbar" .}} |
||||||
<div class="twelve wide column content"> |
<div class="twelve wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h4 class="ui top attached warning header"> |
<h4 class="ui top attached warning header"> |
||||||
{{.i18n.Tr "org.settings.delete_account"}} |
{{.i18n.Tr "org.settings.delete_account"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached warning segment"> |
<div class="ui attached warning segment"> |
||||||
<div class="ui red message"> |
<div class="ui red message"> |
||||||
<p class="text left"><i class="octicon octicon-alert"></i> {{.i18n.Tr "org.settings.delete_prompt" | Str2html}}</p> |
<p class="text left"><i class="octicon octicon-alert"></i> {{.i18n.Tr "org.settings.delete_prompt" | Str2html}}</p> |
||||||
</div> |
</div> |
||||||
<form class="ui form" id="delete-form" action="{{.Link}}" method="post"> |
<form class="ui form" id="delete-form" action="{{.Link}}" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<input class="fake" type="password"> |
<input class="fake" type="password"> |
||||||
<div class="inline required field {{if .Err_Password}}error{{end}}"> |
<div class="inline required field {{if .Err_Password}}error{{end}}"> |
||||||
<label for="password">{{.i18n.Tr "password"}}</label> |
<label for="password">{{.i18n.Tr "password"}}</label> |
||||||
<input id="password" name="password" type="password" autofocus required> |
<input id="password" name="password" type="password" autofocus required> |
||||||
</div> |
</div> |
||||||
<div class="ui red button delete-button" data-type="form" data-form="#delete-form"> |
<div class="ui red button delete-button" data-type="form" data-form="#delete-form"> |
||||||
{{.i18n.Tr "org.settings.confirm_delete_account"}} |
{{.i18n.Tr "org.settings.confirm_delete_account"}} |
||||||
</div> |
</div> |
||||||
</form> |
</form> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="ui small basic delete modal"> |
<div class="ui small basic delete modal"> |
||||||
<div class="ui icon header"> |
<div class="ui icon header"> |
||||||
<i class="trash icon"></i> |
<i class="trash icon"></i> |
||||||
{{.i18n.Tr "org.settings.delete_org_title"}} |
{{.i18n.Tr "org.settings.delete_org_title"}} |
||||||
</div> |
</div> |
||||||
<div class="content"> |
<div class="content"> |
||||||
<p>{{.i18n.Tr "org.settings.delete_org_desc"}}</p> |
<p>{{.i18n.Tr "org.settings.delete_org_desc"}}</p> |
||||||
</div> |
</div> |
||||||
{{template "base/delete_modal_actions" .}} |
{{template "base/delete_modal_actions" .}} |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,29 +1,29 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="organization settings new webhook"> |
<div class="organization settings new webhook"> |
||||||
{{template "org/header" .}} |
{{template "org/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "org/settings/navbar" .}} |
{{template "org/settings/navbar" .}} |
||||||
<div class="twelve wide column content"> |
<div class="twelve wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{if .PageIsSettingsHooksNew}}{{.i18n.Tr "repo.settings.add_webhook"}}{{else}}{{.i18n.Tr "repo.settings.update_webhook"}}{{end}} |
{{if .PageIsSettingsHooksNew}}{{.i18n.Tr "repo.settings.add_webhook"}}{{else}}{{.i18n.Tr "repo.settings.update_webhook"}}{{end}} |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
{{if eq .HookType "gogs"}} |
{{if eq .HookType "gogs"}} |
||||||
<img class="img-13" src="{{AppSubUrl}}/img/favicon.png"> |
<img class="img-13" src="{{AppSubUrl}}/img/favicon.png"> |
||||||
{{else if eq .HookType "slack"}} |
{{else if eq .HookType "slack"}} |
||||||
<img class="img-13" src="{{AppSubUrl}}/img/slack.png"> |
<img class="img-13" src="{{AppSubUrl}}/img/slack.png"> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached segment"> |
<div class="ui attached segment"> |
||||||
{{template "repo/settings/hook_gogs" .}} |
{{template "repo/settings/hook_gogs" .}} |
||||||
{{template "repo/settings/hook_slack" .}} |
{{template "repo/settings/hook_slack" .}} |
||||||
</div> |
</div> |
||||||
|
|
||||||
{{template "repo/settings/hook_history" .}} |
{{template "repo/settings/hook_history" .}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,11 +1,11 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="organization settings webhooks"> |
<div class="organization settings webhooks"> |
||||||
{{template "org/header" .}} |
{{template "org/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "org/settings/navbar" .}} |
{{template "org/settings/navbar" .}} |
||||||
{{template "repo/settings/hook_list" .}} |
{{template "repo/settings/hook_list" .}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,14 +1,14 @@ |
|||||||
<div class="four wide column"> |
<div class="four wide column"> |
||||||
<div class="ui vertical menu"> |
<div class="ui vertical menu"> |
||||||
<div class="header item">{{.i18n.Tr "org.settings"}}</div> |
<div class="header item">{{.i18n.Tr "org.settings"}}</div> |
||||||
<a class="{{if .PageIsSettingsOptions}}active{{end}} item" href="{{.OrgLink}}/settings"> |
<a class="{{if .PageIsSettingsOptions}}active{{end}} item" href="{{.OrgLink}}/settings"> |
||||||
{{.i18n.Tr "org.settings.options"}} |
{{.i18n.Tr "org.settings.options"}} |
||||||
</a> |
</a> |
||||||
<a class="{{if .PageIsSettingsHooks}}active{{end}} item" href="{{.OrgLink}}/settings/hooks"> |
<a class="{{if .PageIsSettingsHooks}}active{{end}} item" href="{{.OrgLink}}/settings/hooks"> |
||||||
{{.i18n.Tr "repo.settings.hooks"}} |
{{.i18n.Tr "repo.settings.hooks"}} |
||||||
</a> |
</a> |
||||||
<a class="{{if .PageIsSettingsDelete}}active{{end}} item" href="{{.OrgLink}}/settings/delete"> |
<a class="{{if .PageIsSettingsDelete}}active{{end}} item" href="{{.OrgLink}}/settings/delete"> |
||||||
{{.i18n.Tr "org.settings.delete"}} |
{{.i18n.Tr "org.settings.delete"}} |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
@ -1,59 +1,59 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="organization settings options"> |
<div class="organization settings options"> |
||||||
{{template "org/header" .}} |
{{template "org/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "org/settings/navbar" .}} |
{{template "org/settings/navbar" .}} |
||||||
<div class="twelve wide column content"> |
<div class="twelve wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "org.settings.options"}} |
{{.i18n.Tr "org.settings.options"}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached segment"> |
<div class="ui attached segment"> |
||||||
<form class="ui form" action="{{.Link}}" method="post"> |
<form class="ui form" action="{{.Link}}" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<div class="required field {{if .Err_Name}}error{{end}}"> |
<div class="required field {{if .Err_Name}}error{{end}}"> |
||||||
<label for="org_name">{{.i18n.Tr "org.org_name_holder"}}<span class="text red hide" id="org-name-change-prompt"> {{.i18n.Tr "org.settings.change_orgname_prompt"}}</span></label> |
<label for="org_name">{{.i18n.Tr "org.org_name_holder"}}<span class="text red hide" id="org-name-change-prompt"> {{.i18n.Tr "org.settings.change_orgname_prompt"}}</span></label> |
||||||
<input id="org_name" name="name" value="{{.Org.Name}}" data-org-name="{{.Org.Name}}" autofocus required> |
<input id="org_name" name="name" value="{{.Org.Name}}" data-org-name="{{.Org.Name}}" autofocus required> |
||||||
</div> |
</div> |
||||||
<div class="field {{if .Err_FullName}}error{{end}}"> |
<div class="field {{if .Err_FullName}}error{{end}}"> |
||||||
<label for="full_name">{{.i18n.Tr "org.org_full_name_holder"}}</label> |
<label for="full_name">{{.i18n.Tr "org.org_full_name_holder"}}</label> |
||||||
<input id="full_name" name="full_name" value="{{.Org.FullName}}"> |
<input id="full_name" name="full_name" value="{{.Org.FullName}}"> |
||||||
</div> |
</div> |
||||||
<div class="field {{if .Err_Description}}error{{end}}"> |
<div class="field {{if .Err_Description}}error{{end}}"> |
||||||
<label for="description">{{$.i18n.Tr "org.org_desc"}}</label> |
<label for="description">{{$.i18n.Tr "org.org_desc"}}</label> |
||||||
<textarea id="description" name="description" rows="2">{{.Org.Description}}</textarea> |
<textarea id="description" name="description" rows="2">{{.Org.Description}}</textarea> |
||||||
</div> |
</div> |
||||||
<div class="field {{if .Err_Website}}error{{end}}"> |
<div class="field {{if .Err_Website}}error{{end}}"> |
||||||
<label for="website">{{.i18n.Tr "org.settings.website"}}</label> |
<label for="website">{{.i18n.Tr "org.settings.website"}}</label> |
||||||
<input id="website" name="website" type="url" value="{{.Org.Website}}"> |
<input id="website" name="website" type="url" value="{{.Org.Website}}"> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<label for="location">{{.i18n.Tr "org.settings.location"}}</label> |
<label for="location">{{.i18n.Tr "org.settings.location"}}</label> |
||||||
<input id="location" name="location" value="{{.Org.Location}}"> |
<input id="location" name="location" value="{{.Org.Location}}"> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="field"> |
<div class="field"> |
||||||
<button class="ui green button">{{$.i18n.Tr "org.settings.update_settings"}}</button> |
<button class="ui green button">{{$.i18n.Tr "org.settings.update_settings"}}</button> |
||||||
</div> |
</div> |
||||||
</form> |
</form> |
||||||
|
|
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
|
|
||||||
<form class="ui form" action="{{.Link}}/avatar" method="post" enctype="multipart/form-data"> |
<form class="ui form" action="{{.Link}}/avatar" method="post" enctype="multipart/form-data"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<label for="avatar">{{.i18n.Tr "settings.choose_new_avatar"}}</label> |
<label for="avatar">{{.i18n.Tr "settings.choose_new_avatar"}}</label> |
||||||
<input name="avatar" type="file" > |
<input name="avatar" type="file" > |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="field"> |
<div class="field"> |
||||||
<button class="ui green button">{{$.i18n.Tr "settings.update_avatar"}}</button> |
<button class="ui green button">{{$.i18n.Tr "settings.update_avatar"}}</button> |
||||||
</div> |
</div> |
||||||
</form> |
</form> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,46 +1,46 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="organization teams"> |
<div class="organization teams"> |
||||||
{{template "org/header" .}} |
{{template "org/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
{{template "org/team/sidebar" .}} |
{{template "org/team/sidebar" .}} |
||||||
<div class="ui ten wide column"> |
<div class="ui ten wide column"> |
||||||
<div class="ui top attached header"> |
<div class="ui top attached header"> |
||||||
{{.i18n.Tr "org.teams.members"}} |
{{.i18n.Tr "org.teams.members"}} |
||||||
</div> |
</div> |
||||||
<div class="ui attached table segment members"> |
<div class="ui attached table segment members"> |
||||||
{{range .Team.Members}} |
{{range .Team.Members}} |
||||||
<div class="item"> |
<div class="item"> |
||||||
{{if $.IsOrganizationOwner}} |
{{if $.IsOrganizationOwner}} |
||||||
<a class="ui red small button right" href="{{$.OrgLink}}/teams/{{$.Team.LowerName}}/action/remove?uid={{.Id}}">{{$.i18n.Tr "org.members.remove"}}</a> |
<a class="ui red small button right" href="{{$.OrgLink}}/teams/{{$.Team.LowerName}}/action/remove?uid={{.Id}}">{{$.i18n.Tr "org.members.remove"}}</a> |
||||||
{{end}} |
{{end}} |
||||||
<a href="{{.HomeLink}}"> |
<a href="{{.HomeLink}}"> |
||||||
<img class="ui avatar image" src="{{.AvatarLink}}"> |
<img class="ui avatar image" src="{{.AvatarLink}}"> |
||||||
{{.DisplayName}} |
{{.DisplayName}} |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
|
||||||
{{if .IsOrganizationOwner}} |
|
||||||
<div class="ui bottom attached segment"> |
|
||||||
<form class="ui form" id="add-member-form" action="{{$.OrgLink}}/teams/{{$.Team.LowerName}}/action/add" method="post"> |
|
||||||
{{.CsrfTokenHtml}} |
|
||||||
<input type="hidden" name="uid" value="{{.SignedUser.Id}}"> |
|
||||||
<div class="inline field ui left"> |
|
||||||
<div id="search-user-box"> |
|
||||||
<div class="ui input"> |
|
||||||
<input class="prompt" name="uname" placeholder="{{.i18n.Tr "repo.settings.search_user_placeholder"}}" autocomplete="off" required> |
|
||||||
</div> |
|
||||||
<div class="ui segment results hide"></div> |
|
||||||
</div> |
|
||||||
</div> |
|
||||||
<button class="ui green button">{{.i18n.Tr "org.teams.add_team_member"}}</button> |
|
||||||
</form> |
|
||||||
</div> |
</div> |
||||||
|
{{if .IsOrganizationOwner}} |
||||||
|
<div class="ui bottom attached segment"> |
||||||
|
<form class="ui form" id="add-member-form" action="{{$.OrgLink}}/teams/{{$.Team.LowerName}}/action/add" method="post"> |
||||||
|
{{.CsrfTokenHtml}} |
||||||
|
<input type="hidden" name="uid" value="{{.SignedUser.Id}}"> |
||||||
|
<div class="inline field ui left"> |
||||||
|
<div id="search-user-box"> |
||||||
|
<div class="ui input"> |
||||||
|
<input class="prompt" name="uname" placeholder="{{.i18n.Tr "repo.settings.search_user_placeholder"}}" autocomplete="off" required> |
||||||
|
</div> |
||||||
|
<div class="ui segment results hide"></div> |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
<button class="ui green button">{{.i18n.Tr "org.teams.add_team_member"}}</button> |
||||||
|
</form> |
||||||
|
</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,82 +1,82 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="organization new team"> |
<div class="organization new team"> |
||||||
{{template "org/header" .}} |
{{template "org/header" .}} |
||||||
<div class="ui middle very relaxed page grid"> |
<div class="ui middle very relaxed page grid"> |
||||||
<div class="column"> |
<div class="column"> |
||||||
<form class="ui form" action="{{if .PageIsOrgTeamsNew}}{{.OrgLink}}/teams/new{{else}}{{.OrgLink}}/teams/{{.Team.LowerName}}/edit{{end}}" data-delete-url="{{.OrgLink}}/teams/{{.Team.LowerName}}/delete" method="post"> |
<form class="ui form" action="{{if .PageIsOrgTeamsNew}}{{.OrgLink}}/teams/new{{else}}{{.OrgLink}}/teams/{{.Team.LowerName}}/edit{{end}}" data-delete-url="{{.OrgLink}}/teams/{{.Team.LowerName}}/delete" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<h3 class="ui top attached header"> |
<h3 class="ui top attached header"> |
||||||
{{if .PageIsOrgTeamsNew}}{{.i18n.Tr "org.create_new_team"}}{{else}}{{.i18n.Tr "org.teams.settings"}}{{end}} |
{{if .PageIsOrgTeamsNew}}{{.i18n.Tr "org.create_new_team"}}{{else}}{{.i18n.Tr "org.teams.settings"}}{{end}} |
||||||
</h3> |
</h3> |
||||||
<div class="ui attached segment"> |
<div class="ui attached segment"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<div class="required field {{if .Err_TeamName}}error{{end}}"> |
<div class="required field {{if .Err_TeamName}}error{{end}}"> |
||||||
<label for="team_name">{{.i18n.Tr "org.team_name"}}</label> |
<label for="team_name">{{.i18n.Tr "org.team_name"}}</label> |
||||||
{{if eq .Team.LowerName "owners"}} |
{{if eq .Team.LowerName "owners"}} |
||||||
<input type="hidden" name="team_name" value="{{.team_name}}"> |
<input type="hidden" name="team_name" value="{{.team_name}}"> |
||||||
{{end}} |
{{end}} |
||||||
<input id="team_name" name="team_name" value="{{.team_name}}" required {{if eq .Team.LowerName "owners"}}disabled{{end}} autofocus> |
<input id="team_name" name="team_name" value="{{.team_name}}" required {{if eq .Team.LowerName "owners"}}disabled{{end}} autofocus> |
||||||
<span class="help">{{.i18n.Tr "org.team_name_helper"}}</span> |
<span class="help">{{.i18n.Tr "org.team_name_helper"}}</span> |
||||||
</div> |
</div> |
||||||
<div class="field {{if .Err_Description}}error{{end}}"> |
<div class="field {{if .Err_Description}}error{{end}}"> |
||||||
<label for="desc">{{.i18n.Tr "org.team_desc"}}</label> |
<label for="desc">{{.i18n.Tr "org.team_desc"}}</label> |
||||||
<input id="desc" name="desc" value="{{.desc}}"> |
<input id="desc" name="desc" value="{{.desc}}"> |
||||||
<span class="help">{{.i18n.Tr "org.team_desc_helper"}}</span> |
<span class="help">{{.i18n.Tr "org.team_desc_helper"}}</span> |
||||||
</div> |
</div> |
||||||
{{if not (eq .Team.LowerName "owners")}} |
{{if not (eq .Team.LowerName "owners")}} |
||||||
<div class="grouped field"> |
<div class="grouped field"> |
||||||
<label>{{.i18n.Tr "org.team_permission_desc"}}</label> |
<label>{{.i18n.Tr "org.team_permission_desc"}}</label> |
||||||
<br> |
<br> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<div class="ui radio checkbox"> |
<div class="ui radio checkbox"> |
||||||
<input type="radio" name="permission" value="read" {{if or .PageIsOrgTeamsNew (eq .Team.Authorize 1)}}checked{{end}}> |
<input type="radio" name="permission" value="read" {{if or .PageIsOrgTeamsNew (eq .Team.Authorize 1)}}checked{{end}}> |
||||||
<label>{{.i18n.Tr "org.teams.read_access"}}</label> |
<label>{{.i18n.Tr "org.teams.read_access"}}</label> |
||||||
<span class="help">{{.i18n.Tr "org.teams.read_access_helper"}}</span> |
<span class="help">{{.i18n.Tr "org.teams.read_access_helper"}}</span> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<div class="ui radio checkbox"> |
<div class="ui radio checkbox"> |
||||||
<input type="radio" name="permission" value="write" {{if eq .Team.Authorize 2}}checked{{end}}> |
<input type="radio" name="permission" value="write" {{if eq .Team.Authorize 2}}checked{{end}}> |
||||||
<label>{{.i18n.Tr "org.teams.write_access"}}</label> |
<label>{{.i18n.Tr "org.teams.write_access"}}</label> |
||||||
<span class="help">{{.i18n.Tr "org.teams.write_access_helper"}}</span> |
<span class="help">{{.i18n.Tr "org.teams.write_access_helper"}}</span> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<div class="ui radio checkbox"> |
<div class="ui radio checkbox"> |
||||||
<input type="radio" name="permission" value="admin" {{if eq .Team.Authorize 3}}checked{{end}}> |
<input type="radio" name="permission" value="admin" {{if eq .Team.Authorize 3}}checked{{end}}> |
||||||
<label>{{.i18n.Tr "org.teams.admin_access"}}</label> |
<label>{{.i18n.Tr "org.teams.admin_access"}}</label> |
||||||
<span class="help">{{.i18n.Tr "org.teams.admin_access_helper"}}</span> |
<span class="help">{{.i18n.Tr "org.teams.admin_access_helper"}}</span> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
{{end}} |
{{end}} |
||||||
|
|
||||||
<div class="field"> |
<div class="field"> |
||||||
{{if .PageIsOrgTeamsNew}} |
{{if .PageIsOrgTeamsNew}} |
||||||
<button class="ui green button">{{.i18n.Tr "org.create_new_team"}}</button> |
<button class="ui green button">{{.i18n.Tr "org.create_new_team"}}</button> |
||||||
<a class="ui button" href="{{.OrgLink}}/teams">{{.i18n.Tr "cancel"}}</a> |
<a class="ui button" href="{{.OrgLink}}/teams">{{.i18n.Tr "cancel"}}</a> |
||||||
{{else}} |
{{else}} |
||||||
<button class="ui green button">{{.i18n.Tr "org.teams.update_settings"}}</button> |
<button class="ui green button">{{.i18n.Tr "org.teams.update_settings"}}</button> |
||||||
{{if not (eq .Team.LowerName "owners")}} |
{{if not (eq .Team.LowerName "owners")}} |
||||||
<button class="ui red button delete-button" data-url="{{.OrgLink}}/teams/{{.team_name}}/delete">{{.i18n.Tr "org.teams.delete_team"}}</button> |
<button class="ui red button delete-button" data-url="{{.OrgLink}}/teams/{{.team_name}}/delete">{{.i18n.Tr "org.teams.delete_team"}}</button> |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</form> |
</form> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="ui small basic delete modal"> |
<div class="ui small basic delete modal"> |
||||||
<div class="ui icon header"> |
<div class="ui icon header"> |
||||||
<i class="trash icon"></i> |
<i class="trash icon"></i> |
||||||
{{.i18n.Tr "org.teams.delete_team_title"}} |
{{.i18n.Tr "org.teams.delete_team_title"}} |
||||||
</div> |
</div> |
||||||
<div class="content"> |
<div class="content"> |
||||||
<p>{{.i18n.Tr "org.teams.delete_team_desc"}}</p> |
<p>{{.i18n.Tr "org.teams.delete_team_desc"}}</p> |
||||||
</div> |
</div> |
||||||
{{template "base/delete_modal_actions" .}} |
{{template "base/delete_modal_actions" .}} |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,41 +1,41 @@ |
|||||||
<div class="ui six wide column"> |
<div class="ui six wide column"> |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
<strong>{{.Team.Name}}</strong> |
<strong>{{.Team.Name}}</strong> |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
{{if .Team.IsMember $.SignedUser.Id}} |
{{if .Team.IsMember $.SignedUser.Id}} |
||||||
<a class="ui red tiny button" href="{{.OrgLink}}/teams/{{.Team.LowerName}}/action/leave?uid={{$.SignedUser.Id}}&page=team">{{$.i18n.Tr "org.teams.leave"}}</a> |
<a class="ui red tiny button" href="{{.OrgLink}}/teams/{{.Team.LowerName}}/action/leave?uid={{$.SignedUser.Id}}&page=team">{{$.i18n.Tr "org.teams.leave"}}</a> |
||||||
{{else if .IsOrganizationOwner}} |
{{else if .IsOrganizationOwner}} |
||||||
<a class="ui blue tiny button" href="{{.OrgLink}}/teams/{{.Team.LowerName}}/action/join?uid={{$.SignedUser.Id}}&page=team">{{$.i18n.Tr "org.teams.join"}}</a> |
<a class="ui blue tiny button" href="{{.OrgLink}}/teams/{{.Team.LowerName}}/action/join?uid={{$.SignedUser.Id}}&page=team">{{$.i18n.Tr "org.teams.join"}}</a> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment detail"> |
<div class="ui attached table segment detail"> |
||||||
<div class="item"> |
<div class="item"> |
||||||
{{if .Team.Description}} |
{{if .Team.Description}} |
||||||
{{.Team.Description}} |
{{.Team.Description}} |
||||||
{{else}} |
{{else}} |
||||||
<span class="text grey italic">{{.i18n.Tr "org.teams.no_desc"}}</span> |
<span class="text grey italic">{{.i18n.Tr "org.teams.no_desc"}}</span> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
<div class="item"> |
<div class="item"> |
||||||
<a href="{{.OrgLink}}/teams/{{.Team.LowerName}}"><span class="octicon octicon-person"></span> <strong>{{.Team.NumMembers}}</strong> {{$.i18n.Tr "org.lower_members"}}</a> · |
<a href="{{.OrgLink}}/teams/{{.Team.LowerName}}"><span class="octicon octicon-person"></span> <strong>{{.Team.NumMembers}}</strong> {{$.i18n.Tr "org.lower_members"}}</a> · |
||||||
<a href="{{.OrgLink}}/teams/{{.Team.LowerName}}/repositories"><span class="octicon octicon-repo"></span> <strong>{{.Team.NumRepos}}</strong> {{$.i18n.Tr "org.lower_repositories"}}</a> |
<a href="{{.OrgLink}}/teams/{{.Team.LowerName}}/repositories"><span class="octicon octicon-repo"></span> <strong>{{.Team.NumRepos}}</strong> {{$.i18n.Tr "org.lower_repositories"}}</a> |
||||||
</div> |
</div> |
||||||
<div class="item"> |
<div class="item"> |
||||||
{{if eq .Team.LowerName "owners"}} |
{{if eq .Team.LowerName "owners"}} |
||||||
{{.i18n.Tr "org.teams.owners_permission_desc" | Str2html}} |
{{.i18n.Tr "org.teams.owners_permission_desc" | Str2html}} |
||||||
{{else if (eq .Team.Authorize 1)}} |
{{else if (eq .Team.Authorize 1)}} |
||||||
{{.i18n.Tr "org.teams.read_permission_desc" | Str2html}} |
{{.i18n.Tr "org.teams.read_permission_desc" | Str2html}} |
||||||
{{else if (eq .Team.Authorize 2)}} |
{{else if (eq .Team.Authorize 2)}} |
||||||
{{.i18n.Tr "org.teams.write_permission_desc" | Str2html}} |
{{.i18n.Tr "org.teams.write_permission_desc" | Str2html}} |
||||||
{{else if (eq .Team.Authorize 3)}} |
{{else if (eq .Team.Authorize 3)}} |
||||||
{{.i18n.Tr "org.teams.admin_permission_desc" | Str2html}} |
{{.i18n.Tr "org.teams.admin_permission_desc" | Str2html}} |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{if .IsOrganizationOwner}} |
{{if .IsOrganizationOwner}} |
||||||
<div class="ui bottom attached segment"> |
<div class="ui bottom attached segment"> |
||||||
<a class="ui teal small button" href="{{.OrgLink}}/teams/{{.Team.LowerName}}/edit"><span class="octicon octicon-gear"></span> {{$.i18n.Tr "org.teams.settings"}}</a> |
<a class="ui teal small button" href="{{.OrgLink}}/teams/{{.Team.LowerName}}/edit"><span class="octicon octicon-gear"></span> {{$.i18n.Tr "org.teams.settings"}}</a> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
|
@ -1,41 +1,41 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="organization teams"> |
<div class="organization teams"> |
||||||
{{template "org/header" .}} |
{{template "org/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
{{if .IsOrganizationOwner}} |
{{if .IsOrganizationOwner}} |
||||||
<div class="text right"> |
<div class="text right"> |
||||||
<a class="ui green button" href="{{.OrgLink}}/teams/new"><i class="octicon octicon-repo-create"></i> {{.i18n.Tr "org.create_new_team"}}</a> |
<a class="ui green button" href="{{.OrgLink}}/teams/new"><i class="octicon octicon-repo-create"></i> {{.i18n.Tr "org.create_new_team"}}</a> |
||||||
</div> |
</div> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
{{end}} |
{{end}} |
||||||
|
|
||||||
<div class="ui two column grid"> |
<div class="ui two column grid"> |
||||||
{{range .Teams}} |
{{range .Teams}} |
||||||
<div class="column"> |
<div class="column"> |
||||||
<div class="ui top attached header"> |
<div class="ui top attached header"> |
||||||
<a class="text black" href="{{$.OrgLink}}/teams/{{.LowerName}}"><strong>{{.Name}}</strong></a> |
<a class="text black" href="{{$.OrgLink}}/teams/{{.LowerName}}"><strong>{{.Name}}</strong></a> |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
{{if .IsMember $.SignedUser.Id}} |
{{if .IsMember $.SignedUser.Id}} |
||||||
<a class="ui red small button" href="{{$.OrgLink}}/teams/{{.LowerName}}/action/leave?uid={{$.SignedUser.Id}}">{{$.i18n.Tr "org.teams.leave"}}</a> |
<a class="ui red small button" href="{{$.OrgLink}}/teams/{{.LowerName}}/action/leave?uid={{$.SignedUser.Id}}">{{$.i18n.Tr "org.teams.leave"}}</a> |
||||||
{{else if $.IsOrganizationOwner}} |
{{else if $.IsOrganizationOwner}} |
||||||
<a class="ui blue small button" href="{{$.OrgLink}}/teams/{{.LowerName}}/action/join?uid={{$.SignedUser.Id}}">{{$.i18n.Tr "org.teams.join"}}</a> |
<a class="ui blue small button" href="{{$.OrgLink}}/teams/{{.LowerName}}/action/join?uid={{$.SignedUser.Id}}">{{$.i18n.Tr "org.teams.join"}}</a> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="ui attached segment members"> |
<div class="ui attached segment members"> |
||||||
{{range .Members}} |
{{range .Members}} |
||||||
<a href="{{.HomeLink}}" title="{{.Name}}"> |
<a href="{{.HomeLink}}" title="{{.Name}}"> |
||||||
<img class="ui avatar image" src="{{.AvatarLink}}"> |
<img class="ui avatar image" src="{{.AvatarLink}}"> |
||||||
</a> |
</a> |
||||||
{{end}} |
{{end}} |
||||||
|
</div> |
||||||
|
<div class="ui bottom attached header"> |
||||||
|
<p class="team-meta">{{.NumMembers}} {{$.i18n.Tr "org.lower_members"}} · {{.NumRepos}} {{$.i18n.Tr "org.lower_repositories"}}</p> |
||||||
|
</div> |
||||||
</div> |
</div> |
||||||
<div class="ui bottom attached header"> |
|
||||||
<p class="team-meta">{{.NumMembers}} {{$.i18n.Tr "org.lower_members"}} · {{.NumRepos}} {{$.i18n.Tr "org.lower_repositories"}}</p> |
|
||||||
</div> |
|
||||||
</div> |
|
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,61 +1,61 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="repository quickstart"> |
<div class="repository quickstart"> |
||||||
{{template "repo/header" .}} |
{{template "repo/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
<div class="sixteen wide column content"> |
<div class="sixteen wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
{{if .IsRepositoryAdmin}} |
{{if .IsRepositoryAdmin}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "repo.quick_guide"}} |
{{.i18n.Tr "repo.quick_guide"}} |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<a class="ui black tiny button" href="{{.RepoLink}}/settings">{{.i18n.Tr "repo.settings"}}</a> |
<a class="ui black tiny button" href="{{.RepoLink}}/settings">{{.i18n.Tr "repo.settings"}}</a> |
||||||
</div> |
</div> |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached guide table segment"> |
<div class="ui attached guide table segment"> |
||||||
<div class="item"> |
<div class="item"> |
||||||
<h3>{{.i18n.Tr "repo.clone_this_repo"}} <small>{{.i18n.Tr "repo.clone_helper" "http://git-scm.com/book/en/Git-Basics-Getting-a-Git-Repository" | Str2html}}</small></h3> |
<h3>{{.i18n.Tr "repo.clone_this_repo"}} <small>{{.i18n.Tr "repo.clone_helper" "http://git-scm.com/book/en/Git-Basics-Getting-a-Git-Repository" | Str2html}}</small></h3> |
||||||
<div class="ui action small input"> |
<div class="ui action small input"> |
||||||
{{if not $.DisableSSH}} |
{{if not $.DisableSSH}} |
||||||
<button class="ui blue basic clone button" id="repo-clone-ssh" data-link="{{.CloneLink.SSH}}"> |
<button class="ui blue basic clone button" id="repo-clone-ssh" data-link="{{.CloneLink.SSH}}"> |
||||||
SSH |
SSH |
||||||
</button> |
</button> |
||||||
{{end}} |
{{end}} |
||||||
<button class="ui {{if $.DisableSSH}}blue{{end}} basic clone button" id="repo-clone-https" data-link="{{.CloneLink.HTTPS}}"> |
<button class="ui {{if $.DisableSSH}}blue{{end}} basic clone button" id="repo-clone-https" data-link="{{.CloneLink.HTTPS}}"> |
||||||
{{if UseHTTPS}}HTTPS{{else}}HTTP{{end}} |
{{if UseHTTPS}}HTTPS{{else}}HTTP{{end}} |
||||||
</button> |
</button> |
||||||
<input id="repo-clone-url" value="{{if $.DisableSSH}}{{$.CloneLink.HTTPS}}{{else}}{{$.CloneLink.SSH}}{{end}}" readonly> |
<input id="repo-clone-url" value="{{if $.DisableSSH}}{{$.CloneLink.HTTPS}}{{else}}{{$.CloneLink.SSH}}{{end}}" readonly> |
||||||
<button class="ui basic button poping up clipboard" id="clipboard-btn" data-original="{{.i18n.Tr "repo.copy_link"}}" data-success="{{.i18n.Tr "repo.copy_link_success"}}" data-error="{{.i18n.Tr "repo.copy_link_error"}}" data-content="{{.i18n.Tr "repo.copy_link"}}" data-variation="inverted tiny" data-clipboard-target="#repo-clone-url"> |
<button class="ui basic button poping up clipboard" id="clipboard-btn" data-original="{{.i18n.Tr "repo.copy_link"}}" data-success="{{.i18n.Tr "repo.copy_link_success"}}" data-error="{{.i18n.Tr "repo.copy_link_error"}}" data-content="{{.i18n.Tr "repo.copy_link"}}" data-variation="inverted tiny" data-clipboard-target="#repo-clone-url"> |
||||||
<i class="octicon octicon-clippy"></i> |
<i class="octicon octicon-clippy"></i> |
||||||
</button> |
</button> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
|
|
||||||
<div class="item"> |
<div class="item"> |
||||||
<h3>{{.i18n.Tr "repo.create_new_repo_command"}}</h3> |
<h3>{{.i18n.Tr "repo.create_new_repo_command"}}</h3> |
||||||
<div class="markdown"> |
<div class="markdown"> |
||||||
<pre><code>touch README.md |
<pre><code>touch README.md |
||||||
git init |
git init |
||||||
git add README.md |
git add README.md |
||||||
git commit -m "first commit" |
git commit -m "first commit" |
||||||
git remote add origin <span class="clone-url">{{if $.DisableSSH}}{{$.CloneLink.HTTPS}}{{else}}{{$.CloneLink.SSH}}{{end}}</span> |
git remote add origin <span class="clone-url">{{if $.DisableSSH}}{{$.CloneLink.HTTPS}}{{else}}{{$.CloneLink.SSH}}{{end}}</span> |
||||||
git push -u origin master</code></pre> |
git push -u origin master</code></pre> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
|
|
||||||
<div class="item"> |
<div class="item"> |
||||||
<h3>{{.i18n.Tr "repo.push_exist_repo"}}</h3> |
<h3>{{.i18n.Tr "repo.push_exist_repo"}}</h3> |
||||||
<div class="markdown"> |
<div class="markdown"> |
||||||
<pre><code>git remote add origin <span class="clone-url">{{if $.DisableSSH}}{{$.CloneLink.HTTPS}}{{else}}{{$.CloneLink.SSH}}{{end}}</span> |
<pre><code>git remote add origin <span class="clone-url">{{if $.DisableSSH}}{{$.CloneLink.HTTPS}}{{else}}{{$.CloneLink.SSH}}{{end}}</span> |
||||||
git push -u origin master</code></pre> |
git push -u origin master</code></pre> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,8 +1,8 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="repository commits"> |
<div class="repository commits"> |
||||||
{{template "repo/header" .}} |
{{template "repo/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
{{template "repo/commits_table" .}} |
{{template "repo/commits_table" .}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,70 +1,70 @@ |
|||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.CommitCount}} {{.i18n.Tr "repo.commits.commits"}} {{if .Branch}}({{.Branch}}){{end}} |
{{.CommitCount}} {{.i18n.Tr "repo.commits.commits"}} {{if .Branch}}({{.Branch}}){{end}} |
||||||
{{if .PageIsCommits}} |
{{if .PageIsCommits}} |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<form action="{{.RepoLink}}/commits/{{.BranchName}}/search"> |
<form action="{{.RepoLink}}/commits/{{.BranchName}}/search"> |
||||||
<div class="ui tiny search input"> |
<div class="ui tiny search input"> |
||||||
<input name="q" placeholder="{{.i18n.Tr "repo.commits.search"}}" value="{{.Keyword}}" autofocus> |
<input name="q" placeholder="{{.i18n.Tr "repo.commits.search"}}" value="{{.Keyword}}" autofocus> |
||||||
</div> |
</div> |
||||||
<button class="ui black tiny button" data-panel="#add-deploy-key-panel">{{.i18n.Tr "repo.commits.find"}}</button> |
<button class="ui black tiny button" data-panel="#add-deploy-key-panel">{{.i18n.Tr "repo.commits.find"}}</button> |
||||||
</form> |
</form> |
||||||
</div> |
</div> |
||||||
{{else if .IsDiffCompare}} |
{{else if .IsDiffCompare}} |
||||||
<a href="{{$.CommitRepoLink}}/commit/{{.BeforeCommitID}}" class="ui green sha label">{{ShortSha .BeforeCommitID}}</a> ... <a href="{{$.CommitRepoLink}}/commit/{{.AfterCommitID}}" class="ui green sha label">{{ShortSha .AfterCommitID}}</a> |
<a href="{{$.CommitRepoLink}}/commit/{{.BeforeCommitID}}" class="ui green sha label">{{ShortSha .BeforeCommitID}}</a> ... <a href="{{$.CommitRepoLink}}/commit/{{.AfterCommitID}}" class="ui green sha label">{{ShortSha .AfterCommitID}}</a> |
||||||
{{end}} |
{{end}} |
||||||
</h4> |
</h4> |
||||||
|
|
||||||
{{if .Commits}} |
{{if .Commits}} |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<table class="ui very basic striped fixed table single line" id="commits-table"> |
<table class="ui very basic striped fixed table single line" id="commits-table"> |
||||||
<thead> |
<thead> |
||||||
<tr> |
<tr> |
||||||
<th class="four wide">{{.i18n.Tr "repo.commits.author"}}</th> |
<th class="four wide">{{.i18n.Tr "repo.commits.author"}}</th> |
||||||
<th class="nine wide message"><span class="sha">SHA1</span> {{.i18n.Tr "repo.commits.message"}}</th> |
<th class="nine wide message"><span class="sha">SHA1</span> {{.i18n.Tr "repo.commits.message"}}</th> |
||||||
<th class="three wide right aligned">{{.i18n.Tr "repo.commits.date"}}</th> |
<th class="three wide right aligned">{{.i18n.Tr "repo.commits.date"}}</th> |
||||||
</tr> |
</tr> |
||||||
</thead> |
</thead> |
||||||
<tbody> |
<tbody> |
||||||
{{ $r:= List .Commits}} |
{{ $r:= List .Commits}} |
||||||
{{range $r}} |
{{range $r}} |
||||||
<tr> |
<tr> |
||||||
<td class="author"> |
<td class="author"> |
||||||
{{if .User}} |
{{if .User}} |
||||||
<img class="ui avatar image" src="{{.User.AvatarLink}}" alt=""/> <a href="{{AppSubUrl}}/{{.User.Name}}">{{.Author.Name}}</a> |
<img class="ui avatar image" src="{{.User.AvatarLink}}" alt=""/> <a href="{{AppSubUrl}}/{{.User.Name}}">{{.Author.Name}}</a> |
||||||
{{else}} |
{{else}} |
||||||
<img class="ui avatar image" src="{{AvatarLink .Author.Email}}" alt=""/> {{.Author.Name}} |
<img class="ui avatar image" src="{{AvatarLink .Author.Email}}" alt=""/> {{.Author.Name}} |
||||||
{{end}} |
{{end}} |
||||||
</td> |
</td> |
||||||
<td class="message collapsing"> |
<td class="message collapsing"> |
||||||
<a rel="nofollow" class="ui sha label" href="{{AppSubUrl}}/{{$.Username}}/{{$.Reponame}}/commit/{{.ID}}">{{ShortSha .ID.String}}</a> |
<a rel="nofollow" class="ui sha label" href="{{AppSubUrl}}/{{$.Username}}/{{$.Reponame}}/commit/{{.ID}}">{{ShortSha .ID.String}}</a> |
||||||
{{RenderCommitMessage false .Summary $.RepoLink $.Repository.ComposeMetas}} |
{{RenderCommitMessage false .Summary $.RepoLink $.Repository.ComposeMetas}} |
||||||
</td> |
</td> |
||||||
<td class="grey text right aligned">{{TimeSince .Author.When $.Lang}}</td> |
<td class="grey text right aligned">{{TimeSince .Author.When $.Lang}}</td> |
||||||
</tr> |
</tr> |
||||||
{{end}} |
{{end}} |
||||||
</tbody> |
</tbody> |
||||||
</table> |
</table> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
|
|
||||||
{{with .Page}} |
{{with .Page}} |
||||||
{{if gt .TotalPages 1}} |
{{if gt .TotalPages 1}} |
||||||
<div class="center page buttons"> |
<div class="center page buttons"> |
||||||
<div class="ui borderless pagination menu"> |
<div class="ui borderless pagination menu"> |
||||||
<a class="{{if not .HasPrevious}}disabled{{end}} item" {{if .HasPrevious}}href="{{$.RepoLink}}/commits/{{$.BranchName}}{{if $.FileName}}/{{$.FileName}}{{end}}?page={{.Previous}}"{{end}}> |
<a class="{{if not .HasPrevious}}disabled{{end}} item" {{if .HasPrevious}}href="{{$.RepoLink}}/commits/{{$.BranchName}}{{if $.FileName}}/{{$.FileName}}{{end}}?page={{.Previous}}"{{end}}> |
||||||
<i class="left arrow icon"></i> {{$.i18n.Tr "repo.issues.previous"}} |
<i class="left arrow icon"></i> {{$.i18n.Tr "repo.issues.previous"}} |
||||||
</a> |
</a> |
||||||
{{range .Pages}} |
{{range .Pages}} |
||||||
{{if eq .Num -1}} |
{{if eq .Num -1}} |
||||||
<a class="disabled item">...</a> |
<a class="disabled item">...</a> |
||||||
{{else}} |
{{else}} |
||||||
<a class="{{if .IsCurrent}}active{{end}} item" {{if not .IsCurrent}}href="{{$.RepoLink}}/commits/{{$.BranchName}}{{if $.FileName}}/{{$.FileName}}{{end}}?page={{.Num}}"{{end}}>{{.Num}}</a> |
<a class="{{if .IsCurrent}}active{{end}} item" {{if not .IsCurrent}}href="{{$.RepoLink}}/commits/{{$.BranchName}}{{if $.FileName}}/{{$.FileName}}{{end}}?page={{.Num}}"{{end}}>{{.Num}}</a> |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
<a class="{{if not .HasNext}}disabled{{end}} item" {{if .HasNext}}href="{{$.RepoLink}}/commits/{{$.BranchName}}{{if $.FileName}}/{{$.FileName}}{{end}}?page={{.Next}}"{{end}}> |
<a class="{{if not .HasNext}}disabled{{end}} item" {{if .HasNext}}href="{{$.RepoLink}}/commits/{{$.BranchName}}{{if $.FileName}}/{{$.FileName}}{{end}}?page={{.Next}}"{{end}}> |
||||||
{{$.i18n.Tr "repo.issues.next"}} <i class="icon right arrow"></i> |
{{$.i18n.Tr "repo.issues.next"}} <i class="icon right arrow"></i> |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
|
@ -1,116 +1,116 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="repository new repo"> |
<div class="repository new repo"> |
||||||
<div class="ui middle very relaxed page grid"> |
<div class="ui middle very relaxed page grid"> |
||||||
<div class="column"> |
<div class="column"> |
||||||
<form class="ui form" action="{{.Link}}" method="post"> |
<form class="ui form" action="{{.Link}}" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<h3 class="ui top attached header"> |
<h3 class="ui top attached header"> |
||||||
{{.i18n.Tr "new_repo"}} |
{{.i18n.Tr "new_repo"}} |
||||||
</h3> |
</h3> |
||||||
<div class="ui attached segment"> |
<div class="ui attached segment"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<div class="inline required field {{if .Err_Owner}}error{{end}}"> |
<div class="inline required field {{if .Err_Owner}}error{{end}}"> |
||||||
<label>{{.i18n.Tr "repo.owner"}}</label> |
<label>{{.i18n.Tr "repo.owner"}}</label> |
||||||
<div class="ui selection owner dropdown"> |
<div class="ui selection owner dropdown"> |
||||||
<input type="hidden" id="uid" name="uid" value="{{.ContextUser.Id}}" required> |
<input type="hidden" id="uid" name="uid" value="{{.ContextUser.Id}}" required> |
||||||
<span class="text"> |
<span class="text"> |
||||||
<img class="ui mini image" src="{{.ContextUser.AvatarLink}}"> |
<img class="ui mini image" src="{{.ContextUser.AvatarLink}}"> |
||||||
{{.ContextUser.ShortName 20}} |
{{.ContextUser.ShortName 20}} |
||||||
</span> |
</span> |
||||||
<i class="dropdown icon"></i> |
<i class="dropdown icon"></i> |
||||||
<div class="menu"> |
<div class="menu"> |
||||||
<div class="item" data-value="{{.SignedUser.Id}}"> |
<div class="item" data-value="{{.SignedUser.Id}}"> |
||||||
<img class="ui mini image" src="{{.SignedUser.AvatarLink}}"> |
<img class="ui mini image" src="{{.SignedUser.AvatarLink}}"> |
||||||
{{.SignedUser.ShortName 20}} |
{{.SignedUser.ShortName 20}} |
||||||
</div> |
</div> |
||||||
{{range .Orgs}} |
{{range .Orgs}} |
||||||
<div class="item" data-value="{{.Id}}"> |
<div class="item" data-value="{{.Id}}"> |
||||||
<img class="ui mini image" src="{{.AvatarLink}}"> |
<img class="ui mini image" src="{{.AvatarLink}}"> |
||||||
{{.ShortName 20}} |
{{.ShortName 20}} |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="inline required field {{if .Err_RepoName}}error{{end}}"> |
<div class="inline required field {{if .Err_RepoName}}error{{end}}"> |
||||||
<label for="repo_name">{{.i18n.Tr "repo.repo_name"}}</label> |
<label for="repo_name">{{.i18n.Tr "repo.repo_name"}}</label> |
||||||
<input id="repo_name" name="repo_name" value="{{.repo_name}}" autofocus required> |
<input id="repo_name" name="repo_name" value="{{.repo_name}}" autofocus required> |
||||||
<span class="help">{{.i18n.Tr "repo.repo_name_helper" | Safe}}</span> |
<span class="help">{{.i18n.Tr "repo.repo_name_helper" | Safe}}</span> |
||||||
</div> |
</div> |
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<label>{{.i18n.Tr "repo.visibility"}}</label> |
<label>{{.i18n.Tr "repo.visibility"}}</label> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
{{if .IsForcedPrivate}} |
{{if .IsForcedPrivate}} |
||||||
<input name="private" type="checkbox" checked readonly> |
<input name="private" type="checkbox" checked readonly> |
||||||
<label>{{.i18n.Tr "repo.visiblity_helper_forced" | Safe}}</label> |
<label>{{.i18n.Tr "repo.visiblity_helper_forced" | Safe}}</label> |
||||||
{{else}} |
{{else}} |
||||||
<input name="private" type="checkbox" {{if .private}}checked{{end}}> |
<input name="private" type="checkbox" {{if .private}}checked{{end}}> |
||||||
<label>{{.i18n.Tr "repo.visiblity_helper" | Safe}}</label> |
<label>{{.i18n.Tr "repo.visiblity_helper" | Safe}}</label> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="inline field {{if .Err_Description}}error{{end}}"> |
<div class="inline field {{if .Err_Description}}error{{end}}"> |
||||||
<label for="description">{{.i18n.Tr "repo.repo_desc"}}</label> |
<label for="description">{{.i18n.Tr "repo.repo_desc"}}</label> |
||||||
<textarea id="description" name="description">{{.description}}</textarea> |
<textarea id="description" name="description">{{.description}}</textarea> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="ui divider"></div> |
|
||||||
|
|
||||||
<div class="inline field"> |
<div class="ui divider"></div> |
||||||
<label>{{.i18n.Tr "repo.repo_lang"}}</label> |
|
||||||
<div class="ui multiple search normal selection dropdown"> |
|
||||||
<input type="hidden" name="gitignores" value="{{.gitignores}}"> |
|
||||||
<div class="default text">{{.i18n.Tr "repo.repo_lang_helper"}}</div> |
|
||||||
<div class="menu"> |
|
||||||
{{range .Gitignores}} |
|
||||||
<div class="item" data-value="{{.}}">{{.}}</div> |
|
||||||
{{end}} |
|
||||||
</div> |
|
||||||
</div> |
|
||||||
</div> |
|
||||||
<div class="inline field"> |
|
||||||
<label>{{.i18n.Tr "repo.license"}}</label> |
|
||||||
<div class="ui search selection dropdown"> |
|
||||||
<input type="hidden" name="license" value="{{.license}}"> |
|
||||||
<div class="default text">{{.i18n.Tr "repo.license_helper"}}</div> |
|
||||||
<div class="menu"> |
|
||||||
{{range .Licenses}} |
|
||||||
<div class="item" data-value="{{.}}">{{.}}</div> |
|
||||||
{{end}} |
|
||||||
</div> |
|
||||||
</div> |
|
||||||
</div> |
|
||||||
|
|
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<label>{{.i18n.Tr "repo.readme"}} <a target="_blank" href="https://github.com/gogits/go-gogs-client/wiki/Repositories#litte-notes-on-readme-template"><span class="octicon octicon-question"></span></a></label> |
<label>{{.i18n.Tr "repo.repo_lang"}}</label> |
||||||
<div class="ui selection dropdown"> |
<div class="ui multiple search normal selection dropdown"> |
||||||
<input type="hidden" name="readme" value="{{.readme}}"> |
<input type="hidden" name="gitignores" value="{{.gitignores}}"> |
||||||
<div class="default text">{{.i18n.Tr "repo.readme_helper"}}</div> |
<div class="default text">{{.i18n.Tr "repo.repo_lang_helper"}}</div> |
||||||
<div class="menu"> |
<div class="menu"> |
||||||
{{range .Readmes}} |
{{range .Gitignores}} |
||||||
<div class="item" data-value="{{.}}">{{.}}</div> |
<div class="item" data-value="{{.}}">{{.}}</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<div class="ui checkbox" id="auto-init"> |
<label>{{.i18n.Tr "repo.license"}}</label> |
||||||
<input class="hidden" name="auto_init" type="checkbox" tabindex="0" {{if .auto_init}}checked{{end}}> |
<div class="ui search selection dropdown"> |
||||||
<label>{{.i18n.Tr "repo.auto_init"}}</label> |
<input type="hidden" name="license" value="{{.license}}"> |
||||||
</div> |
<div class="default text">{{.i18n.Tr "repo.license_helper"}}</div> |
||||||
</div> |
<div class="menu"> |
||||||
|
{{range .Licenses}} |
||||||
|
<div class="item" data-value="{{.}}">{{.}}</div> |
||||||
|
{{end}} |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
|
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<label></label> |
<label>{{.i18n.Tr "repo.readme"}} <a target="_blank" href="https://github.com/gogits/go-gogs-client/wiki/Repositories#litte-notes-on-readme-template"><span class="octicon octicon-question"></span></a></label> |
||||||
<button class="ui green button"> |
<div class="ui selection dropdown"> |
||||||
{{.i18n.Tr "repo.create_repo"}} |
<input type="hidden" name="readme" value="{{.readme}}"> |
||||||
</button> |
<div class="default text">{{.i18n.Tr "repo.readme_helper"}}</div> |
||||||
<a class="ui button" href="{{AppSubUrl}}/">{{.i18n.Tr "cancel"}}</a> |
<div class="menu"> |
||||||
</div> |
{{range .Readmes}} |
||||||
</div> |
<div class="item" data-value="{{.}}">{{.}}</div> |
||||||
</form> |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
</div> |
||||||
|
<div class="inline field"> |
||||||
|
<div class="ui checkbox" id="auto-init"> |
||||||
|
<input class="hidden" name="auto_init" type="checkbox" tabindex="0" {{if .auto_init}}checked{{end}}> |
||||||
|
<label>{{.i18n.Tr "repo.auto_init"}}</label> |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
|
||||||
|
<div class="inline field"> |
||||||
|
<label></label> |
||||||
|
<button class="ui green button"> |
||||||
|
{{.i18n.Tr "repo.create_repo"}} |
||||||
|
</button> |
||||||
|
<a class="ui button" href="{{AppSubUrl}}/">{{.i18n.Tr "cancel"}}</a> |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
</form> |
||||||
|
</div> |
||||||
|
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,45 +1,45 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="repository diff"> |
<div class="repository diff"> |
||||||
{{template "repo/header" .}} |
{{template "repo/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
{{if .IsDiffCompare }} |
{{if .IsDiffCompare }} |
||||||
{{template "repo/commits_table" .}} |
{{template "repo/commits_table" .}} |
||||||
{{else}} |
{{else}} |
||||||
<div class="ui top attached info clearing segment"> |
<div class="ui top attached info clearing segment"> |
||||||
<a class="ui floated right blue tiny button" href="{{EscapePound .SourcePath}}"> |
<a class="ui floated right blue tiny button" href="{{EscapePound .SourcePath}}"> |
||||||
{{.i18n.Tr "repo.diff.browse_source"}} |
{{.i18n.Tr "repo.diff.browse_source"}} |
||||||
</a> |
</a> |
||||||
{{RenderCommitMessage true .Commit.Message $.RepoLink $.Repository.ComposeMetas}} |
{{RenderCommitMessage true .Commit.Message $.RepoLink $.Repository.ComposeMetas}} |
||||||
</div> |
</div> |
||||||
<div class="ui attached info segment"> |
<div class="ui attached info segment"> |
||||||
{{if .Author}} |
{{if .Author}} |
||||||
<img class="ui avatar image" src="{{.Author.AvatarLink}}" /> |
<img class="ui avatar image" src="{{.Author.AvatarLink}}" /> |
||||||
<a href="{{.Author.HomeLink}}"><strong>{{.Commit.Author.Name}}</strong></a> |
<a href="{{.Author.HomeLink}}"><strong>{{.Commit.Author.Name}}</strong></a> |
||||||
{{else}} |
{{else}} |
||||||
<img class="ui avatar image" src="{{AvatarLink .Commit.Author.Email}}" /> |
<img class="ui avatar image" src="{{AvatarLink .Commit.Author.Email}}" /> |
||||||
<strong>{{.Commit.Author.Name}}</strong> |
<strong>{{.Commit.Author.Name}}</strong> |
||||||
{{end}} |
{{end}} |
||||||
<span class="text grey" id="authored-time">{{TimeSince .Commit.Author.When $.Lang}}</span> |
<span class="text grey" id="authored-time">{{TimeSince .Commit.Author.When $.Lang}}</span> |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<div class="ui horizontal list"> |
<div class="ui horizontal list"> |
||||||
{{if .Parents}} |
{{if .Parents}} |
||||||
<div class="item"> |
<div class="item"> |
||||||
{{.i18n.Tr "repo.diff.parent"}} |
{{.i18n.Tr "repo.diff.parent"}} |
||||||
</div> |
</div> |
||||||
<div class="item"> |
<div class="item"> |
||||||
{{range .Parents}} |
{{range .Parents}} |
||||||
<a class="ui blue sha label" href="{{$.RepoLink}}/commit/{{.}}">{{ShortSha .}}</a> |
<a class="ui blue sha label" href="{{$.RepoLink}}/commit/{{.}}">{{ShortSha .}}</a> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
<div class="item">{{.i18n.Tr "repo.diff.commit"}}</div> |
<div class="item">{{.i18n.Tr "repo.diff.commit"}}</div> |
||||||
<div class="item"><span class="ui blue sha label">{{ShortSha .CommitID}}</span></div> |
<div class="item"><span class="ui blue sha label">{{ShortSha .CommitID}}</span></div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
|
|
||||||
{{template "repo/diff_box" .}} |
{{template "repo/diff_box" .}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,94 +1,94 @@ |
|||||||
{{if .DiffNotAvailable}} |
{{if .DiffNotAvailable}} |
||||||
<h4>{{.i18n.Tr "repo.diff.data_not_available"}}</h4> |
<h4>{{.i18n.Tr "repo.diff.data_not_available"}}</h4> |
||||||
{{else}} |
{{else}} |
||||||
<div class="diff-detail-box diff-box"> |
<div class="diff-detail-box diff-box"> |
||||||
<div> |
<div> |
||||||
<i class="fa fa-retweet"></i> |
<i class="fa fa-retweet"></i> |
||||||
{{.i18n.Tr "repo.diff.stats_desc" .Diff.NumFiles .Diff.TotalAddition .Diff.TotalDeletion | Str2html}} |
{{.i18n.Tr "repo.diff.stats_desc" .Diff.NumFiles .Diff.TotalAddition .Diff.TotalDeletion | Str2html}} |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<a class="ui tiny basic black toggle button" data-target="#diff-files">{{.i18n.Tr "repo.diff.show_diff_stats"}}</a> |
<a class="ui tiny basic black toggle button" data-target="#diff-files">{{.i18n.Tr "repo.diff.show_diff_stats"}}</a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<ol class="detail-files hide" id="diff-files"> |
<ol class="detail-files hide" id="diff-files"> |
||||||
{{range .Diff.Files}} |
{{range .Diff.Files}} |
||||||
<li> |
<li> |
||||||
<div class="diff-counter count pull-right"> |
<div class="diff-counter count pull-right"> |
||||||
{{if not .IsBin}} |
{{if not .IsBin}} |
||||||
<span class="add" data-line="{{.Addition}}">{{.Addition}}</span> |
<span class="add" data-line="{{.Addition}}">{{.Addition}}</span> |
||||||
<span class="bar"> |
<span class="bar"> |
||||||
<span class="pull-left add"></span> |
<span class="pull-left add"></span> |
||||||
<span class="pull-left del"></span> |
<span class="pull-left del"></span> |
||||||
</span> |
</span> |
||||||
<span class="del" data-line="{{.Deletion}}">{{.Deletion}}</span> |
<span class="del" data-line="{{.Deletion}}">{{.Deletion}}</span> |
||||||
{{else}} |
{{else}} |
||||||
<span>{{$.i18n.Tr "repo.diff.bin"}}</span> |
<span>{{$.i18n.Tr "repo.diff.bin"}}</span> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
<!-- todo finish all file status, now modify, add, delete and rename --> |
<!-- todo finish all file status, now modify, add, delete and rename --> |
||||||
<span class="status {{DiffTypeToStr .Type}} poping up" data-content="{{DiffTypeToStr .Type}}" data-variation="inverted tiny" data-position="right center"> </span> |
<span class="status {{DiffTypeToStr .Type}} poping up" data-content="{{DiffTypeToStr .Type}}" data-variation="inverted tiny" data-position="right center"> </span> |
||||||
<a class="file" href="#diff-{{.Index}}">{{.Name}}</a> |
<a class="file" href="#diff-{{.Index}}">{{.Name}}</a> |
||||||
</li> |
</li> |
||||||
{{end}} |
{{end}} |
||||||
</ol> |
</ol> |
||||||
</div> |
</div> |
||||||
|
|
||||||
{{range $i, $file := .Diff.Files}} |
{{range $i, $file := .Diff.Files}} |
||||||
<div class="diff-file-box diff-box file-content" id="diff-{{.Index}}"> |
<div class="diff-file-box diff-box file-content" id="diff-{{.Index}}"> |
||||||
<h4 class="ui top attached normal header"> |
<h4 class="ui top attached normal header"> |
||||||
<div class="diff-counter count ui left"> |
<div class="diff-counter count ui left"> |
||||||
{{if $file.IsBin}} |
{{if $file.IsBin}} |
||||||
{{$.i18n.Tr "repo.diff.bin"}} |
{{$.i18n.Tr "repo.diff.bin"}} |
||||||
{{else if not $file.IsRenamed}} |
{{else if not $file.IsRenamed}} |
||||||
<span class="add" data-line="{{.Addition}}">+ {{.Addition}}</span> |
<span class="add" data-line="{{.Addition}}">+ {{.Addition}}</span> |
||||||
<span class="bar"> |
<span class="bar"> |
||||||
<span class="pull-left add"></span> |
<span class="pull-left add"></span> |
||||||
<span class="pull-left del"></span> |
<span class="pull-left del"></span> |
||||||
</span> |
</span> |
||||||
<span class="del" data-line="{{.Deletion}}">- {{.Deletion}}</span> |
<span class="del" data-line="{{.Deletion}}">- {{.Deletion}}</span> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
<span class="file">{{if $file.IsRenamed}}{{$file.OldName}} → {{end}}{{$file.Name}}</span> |
<span class="file">{{if $file.IsRenamed}}{{$file.OldName}} → {{end}}{{$file.Name}}</span> |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
{{if $file.IsDeleted}} |
{{if $file.IsDeleted}} |
||||||
<a class="ui basic tiny button" rel="nofollow" href="{{EscapePound $.BeforeSourcePath}}/{{EscapePound .Name}}">{{$.i18n.Tr "repo.diff.view_file"}}</a> |
<a class="ui basic tiny button" rel="nofollow" href="{{EscapePound $.BeforeSourcePath}}/{{EscapePound .Name}}">{{$.i18n.Tr "repo.diff.view_file"}}</a> |
||||||
{{else}} |
{{else}} |
||||||
<a class="ui basic tiny button" rel="nofollow" href="{{EscapePound $.SourcePath}}/{{EscapePound .Name}}">{{$.i18n.Tr "repo.diff.view_file"}}</a> |
<a class="ui basic tiny button" rel="nofollow" href="{{EscapePound $.SourcePath}}/{{EscapePound .Name}}">{{$.i18n.Tr "repo.diff.view_file"}}</a> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
{{if not $file.IsRenamed}} |
{{if not $file.IsRenamed}} |
||||||
{{$isImage := (call $.IsImageFile $file.Name)}} |
{{$isImage := (call $.IsImageFile $file.Name)}} |
||||||
{{if and $isImage}} |
{{if and $isImage}} |
||||||
<div class="center"> |
<div class="center"> |
||||||
<img src="{{$.RawPath}}/{{EscapePound .Name}}"> |
<img src="{{$.RawPath}}/{{EscapePound .Name}}"> |
||||||
</div> |
</div> |
||||||
{{else}} |
{{else}} |
||||||
<div class="file-body file-code code-view code-diff"> |
<div class="file-body file-code code-view code-diff"> |
||||||
<table> |
<table> |
||||||
<tbody> |
<tbody> |
||||||
{{range .Sections}} |
{{range .Sections}} |
||||||
{{range $k, $line := .Lines}} |
{{range $k, $line := .Lines}} |
||||||
<tr class="{{DiffLineTypeToStr .Type}}-code nl-{{$k}} ol-{{$k}}"> |
<tr class="{{DiffLineTypeToStr .Type}}-code nl-{{$k}} ol-{{$k}}"> |
||||||
<td class="lines-num lines-num-old"> |
<td class="lines-num lines-num-old"> |
||||||
<span rel="{{if $line.LeftIdx}}diff-{{Sha1 $file.Name}}L{{$line.LeftIdx}}{{end}}">{{if $line.LeftIdx}}{{$line.LeftIdx}}{{end}}</span> |
<span rel="{{if $line.LeftIdx}}diff-{{Sha1 $file.Name}}L{{$line.LeftIdx}}{{end}}">{{if $line.LeftIdx}}{{$line.LeftIdx}}{{end}}</span> |
||||||
</td> |
</td> |
||||||
<td class="lines-num lines-num-new"> |
<td class="lines-num lines-num-new"> |
||||||
<span rel="{{if $line.RightIdx}}diff-{{Sha1 $file.Name}}R{{$line.RightIdx}}{{end}}">{{if $line.RightIdx}}{{$line.RightIdx}}{{end}}</span> |
<span rel="{{if $line.RightIdx}}diff-{{Sha1 $file.Name}}R{{$line.RightIdx}}{{end}}">{{if $line.RightIdx}}{{$line.RightIdx}}{{end}}</span> |
||||||
</td> |
</td> |
||||||
<td class="lines-code"> |
<td class="lines-code"> |
||||||
<pre>{{$line.Content}}</pre> |
<pre>{{$line.Content}}</pre> |
||||||
</td> |
</td> |
||||||
</tr> |
</tr> |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
</tbody> |
</tbody> |
||||||
</table> |
</table> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<br> |
<br> |
||||||
|
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
|
@ -1,22 +1,22 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="repository forks"> |
<div class="repository forks"> |
||||||
{{template "repo/header" .}} |
{{template "repo/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<h2 class="ui dividing header"> |
<h2 class="ui dividing header"> |
||||||
{{.i18n.Tr "repo.forks"}} |
{{.i18n.Tr "repo.forks"}} |
||||||
</h2> |
</h2> |
||||||
<div class="ui list"> |
<div class="ui list"> |
||||||
{{range .Forks}} |
{{range .Forks}} |
||||||
<div class="item"> |
<div class="item"> |
||||||
<img class="ui avatar image" src="{{.Owner.AvatarLink}}"> |
<img class="ui avatar image" src="{{.Owner.AvatarLink}}"> |
||||||
<div class="link"> |
<div class="link"> |
||||||
<a href="{{AppSubUrl}}/{{.Owner.Name}}">{{.Owner.Name}}</a> |
<a href="{{AppSubUrl}}/{{.Owner.Name}}">{{.Owner.Name}}</a> |
||||||
/ |
/ |
||||||
<a href="{{AppSubUrl}}/{{.Owner.Name}}/{{.Name}}">{{.Name}}</a> |
<a href="{{AppSubUrl}}/{{.Owner.Name}}/{{.Name}}">{{.Name}}</a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,87 +1,87 @@ |
|||||||
{{with .Repository}} |
{{with .Repository}} |
||||||
<div class="ui container"><!-- start container --> |
<div class="ui container"><!-- start container --> |
||||||
<div class="ui vertically padded grid head"><!-- start grid --> |
<div class="ui vertically padded grid head"><!-- start grid --> |
||||||
<div class="column"><!-- start column --> |
<div class="column"><!-- start column --> |
||||||
<div class="ui header"> |
<div class="ui header"> |
||||||
<div class="ui huge breadcrumb"> |
<div class="ui huge breadcrumb"> |
||||||
<i class="mega-octicon octicon-{{if .IsPrivate}}lock{{else if .IsMirror}}repo-clone{{else if .IsFork}}repo-forked{{else}}repo{{end}}"></i> |
<i class="mega-octicon octicon-{{if .IsPrivate}}lock{{else if .IsMirror}}repo-clone{{else if .IsFork}}repo-forked{{else}}repo{{end}}"></i> |
||||||
<a href="{{AppSubUrl}}/{{.Owner.Name}}">{{.Owner.Name}}</a> |
<a href="{{AppSubUrl}}/{{.Owner.Name}}">{{.Owner.Name}}</a> |
||||||
<div class="divider"> / </div> |
<div class="divider"> / </div> |
||||||
<a href="{{$.RepoLink}}">{{.Name}}</a> |
<a href="{{$.RepoLink}}">{{.Name}}</a> |
||||||
{{if .IsMirror}}<div class="ui label">{{$.i18n.Tr "mirror"}}</div>{{end}} |
{{if .IsMirror}}<div class="ui label">{{$.i18n.Tr "mirror"}}</div>{{end}} |
||||||
{{if .IsFork}}<div class="fork-flag">{{$.i18n.Tr "repo.forked_from"}} <a href="{{.BaseRepo.RepoLink}}">{{SubStr .BaseRepo.RepoLink 1 -1}}</a></div>{{end}} |
{{if .IsFork}}<div class="fork-flag">{{$.i18n.Tr "repo.forked_from"}} <a href="{{.BaseRepo.RepoLink}}">{{SubStr .BaseRepo.RepoLink 1 -1}}</a></div>{{end}} |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<div class="ui labeled button" tabindex="0"> |
<div class="ui labeled button" tabindex="0"> |
||||||
<a class="ui button" href="{{$.RepoLink}}/action/{{if $.IsWatchingRepo}}un{{end}}watch?redirect_to={{$.Link}}"> |
<a class="ui button" href="{{$.RepoLink}}/action/{{if $.IsWatchingRepo}}un{{end}}watch?redirect_to={{$.Link}}"> |
||||||
<i class="icon fa fa-eye{{if not $.IsWatchingRepo}}-slash{{end}}"></i>{{if $.IsWatchingRepo}}{{$.i18n.Tr "repo.unwatch"}}{{else}}{{$.i18n.Tr "repo.watch"}}{{end}} |
<i class="icon fa fa-eye{{if not $.IsWatchingRepo}}-slash{{end}}"></i>{{if $.IsWatchingRepo}}{{$.i18n.Tr "repo.unwatch"}}{{else}}{{$.i18n.Tr "repo.watch"}}{{end}} |
||||||
</a> |
</a> |
||||||
<a class="ui basic label" href="{{.RepoLink}}/watchers"> |
<a class="ui basic label" href="{{.RepoLink}}/watchers"> |
||||||
{{.NumWatches}} |
{{.NumWatches}} |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
<div class="ui labeled button" tabindex="0"> |
<div class="ui labeled button" tabindex="0"> |
||||||
<a class="ui button" href="{{$.RepoLink}}/action/{{if $.IsStaringRepo}}un{{end}}star?redirect_to={{$.Link}}"> |
<a class="ui button" href="{{$.RepoLink}}/action/{{if $.IsStaringRepo}}un{{end}}star?redirect_to={{$.Link}}"> |
||||||
<i class="icon fa-star{{if not $.IsStaringRepo}}-o{{end}}"></i>{{if $.IsStaringRepo}}{{$.i18n.Tr "repo.unstar"}}{{else}}{{$.i18n.Tr "repo.star"}}{{end}} |
<i class="icon fa-star{{if not $.IsStaringRepo}}-o{{end}}"></i>{{if $.IsStaringRepo}}{{$.i18n.Tr "repo.unstar"}}{{else}}{{$.i18n.Tr "repo.star"}}{{end}} |
||||||
</a> |
</a> |
||||||
<a class="ui basic label" href="{{.RepoLink}}/stars"> |
<a class="ui basic label" href="{{.RepoLink}}/stars"> |
||||||
{{.NumStars}} |
{{.NumStars}} |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
{{if .CanBeForked}} |
{{if .CanBeForked}} |
||||||
<div class="ui labeled button" tabindex="0"> |
<div class="ui labeled button" tabindex="0"> |
||||||
<a class="ui button {{if eq .OwnerID $.SignedUserID}}poping up{{end}}" {{if not (eq .OwnerID $.SignedUserID)}}href="{{AppSubUrl}}/repo/fork/{{.ID}}"{{else}} data-content="{{$.i18n.Tr "repo.fork_from_self"}}" data-position="top center" data-variation="tiny"{{end}}> |
<a class="ui button {{if eq .OwnerID $.SignedUserID}}poping up{{end}}" {{if not (eq .OwnerID $.SignedUserID)}}href="{{AppSubUrl}}/repo/fork/{{.ID}}"{{else}} data-content="{{$.i18n.Tr "repo.fork_from_self"}}" data-position="top center" data-variation="tiny"{{end}}> |
||||||
<i class="icon octicon octicon-repo-forked"></i>{{$.i18n.Tr "repo.fork"}} |
<i class="icon octicon octicon-repo-forked"></i>{{$.i18n.Tr "repo.fork"}} |
||||||
</a> |
</a> |
||||||
<a class="ui basic label" href="{{.RepoLink}}/forks"> |
<a class="ui basic label" href="{{.RepoLink}}/forks"> |
||||||
{{.NumForks}} |
{{.NumForks}} |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div><!-- end column --> |
</div><!-- end column --> |
||||||
</div><!-- end grid --> |
</div><!-- end grid --> |
||||||
</div><!-- end container --> |
</div><!-- end container --> |
||||||
{{end}} |
{{end}} |
||||||
{{if not (or .IsBareRepo .IsDiffCompare)}} |
{{if not (or .IsBareRepo .IsDiffCompare)}} |
||||||
<div class="ui tabs container"> |
<div class="ui tabs container"> |
||||||
<div class="ui tabular menu navbar"> |
<div class="ui tabular menu navbar"> |
||||||
<a class="{{if .PageIsViewCode}}active{{end}} item" href="{{.RepoLink}}"> |
<a class="{{if .PageIsViewCode}}active{{end}} item" href="{{.RepoLink}}"> |
||||||
<i class="icon octicon octicon-code"></i> {{.i18n.Tr "repo.code"}} |
<i class="icon octicon octicon-code"></i> {{.i18n.Tr "repo.code"}} |
||||||
</a> |
</a> |
||||||
{{if .Repository.EnableIssues}} |
{{if .Repository.EnableIssues}} |
||||||
<a class="{{if .PageIsIssueList}}active{{end}} item" href="{{.RepoLink}}/issues"> |
<a class="{{if .PageIsIssueList}}active{{end}} item" href="{{.RepoLink}}/issues"> |
||||||
<i class="icon octicon octicon-issue-opened"></i> {{.i18n.Tr "repo.issues"}} <span class="ui {{if not .Repository.NumOpenIssues}}gray{{else}}blue{{end}} small label">{{.Repository.NumOpenIssues}}</span> |
<i class="icon octicon octicon-issue-opened"></i> {{.i18n.Tr "repo.issues"}} <span class="ui {{if not .Repository.NumOpenIssues}}gray{{else}}blue{{end}} small label">{{.Repository.NumOpenIssues}}</span> |
||||||
</a> |
</a> |
||||||
{{end}} |
{{end}} |
||||||
{{if .Repository.EnablePulls}} |
{{if .Repository.EnablePulls}} |
||||||
<a class="{{if .PageIsPullList}}active{{end}} item" href="{{.RepoLink}}/pulls"> |
<a class="{{if .PageIsPullList}}active{{end}} item" href="{{.RepoLink}}/pulls"> |
||||||
<i class="icon octicon octicon-git-pull-request"></i> {{.i18n.Tr "repo.pulls"}} <span class="ui {{if not .Repository.NumOpenPulls}}gray{{else}}blue{{end}} small label">{{.Repository.NumOpenPulls}}</span> |
<i class="icon octicon octicon-git-pull-request"></i> {{.i18n.Tr "repo.pulls"}} <span class="ui {{if not .Repository.NumOpenPulls}}gray{{else}}blue{{end}} small label">{{.Repository.NumOpenPulls}}</span> |
||||||
</a> |
</a> |
||||||
{{end}} |
{{end}} |
||||||
<a class="{{if .PageIsCommits}}active{{end}} item" href="{{.RepoLink}}/commits/{{EscapePound .BranchName}}"> |
<a class="{{if .PageIsCommits}}active{{end}} item" href="{{.RepoLink}}/commits/{{EscapePound .BranchName}}"> |
||||||
<i class="icon octicon octicon-history"></i> {{.i18n.Tr "repo.commits"}} <span class="ui {{if not .CommitsCount}}gray{{else}}blue{{end}} small label">{{.CommitsCount}}</span> |
<i class="icon octicon octicon-history"></i> {{.i18n.Tr "repo.commits"}} <span class="ui {{if not .CommitsCount}}gray{{else}}blue{{end}} small label">{{.CommitsCount}}</span> |
||||||
</a> |
</a> |
||||||
<a class="{{if .PageIsReleaseList}}active{{end}} item" href="{{.RepoLink}}/releases"> |
<a class="{{if .PageIsReleaseList}}active{{end}} item" href="{{.RepoLink}}/releases"> |
||||||
<i class="icon octicon octicon-tag"></i> {{.i18n.Tr "repo.releases"}} <span class="ui {{if not .Repository.NumTags}}gray{{else}}blue{{end}} small label">{{.Repository.NumTags}}</span> |
<i class="icon octicon octicon-tag"></i> {{.i18n.Tr "repo.releases"}} <span class="ui {{if not .Repository.NumTags}}gray{{else}}blue{{end}} small label">{{.Repository.NumTags}}</span> |
||||||
</a> |
</a> |
||||||
{{if .Repository.EnableWiki}} |
{{if .Repository.EnableWiki}} |
||||||
<a class="{{if .PageIsWiki}}active{{end}} item" href="{{.RepoLink}}/wiki"> |
<a class="{{if .PageIsWiki}}active{{end}} item" href="{{.RepoLink}}/wiki"> |
||||||
<i class="icon octicon octicon-book"></i> {{.i18n.Tr "repo.wiki"}} |
<i class="icon octicon octicon-book"></i> {{.i18n.Tr "repo.wiki"}} |
||||||
</a> |
</a> |
||||||
{{end}} |
{{end}} |
||||||
{{if .IsRepositoryAdmin}} |
{{if .IsRepositoryAdmin}} |
||||||
<div class="right menu"> |
<div class="right menu"> |
||||||
<a class="{{if .PageIsSettings}}active{{end}} item" href="{{.RepoLink}}/settings"> |
<a class="{{if .PageIsSettings}}active{{end}} item" href="{{.RepoLink}}/settings"> |
||||||
<i class="icon octicon octicon-tools"></i> {{.i18n.Tr "repo.settings"}} |
<i class="icon octicon octicon-tools"></i> {{.i18n.Tr "repo.settings"}} |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="ui tabs divider"></div> |
<div class="ui tabs divider"></div> |
||||||
{{else}} |
{{else}} |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
{{end}} |
{{end}} |
||||||
|
@ -1,111 +1,111 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="repository file list"> |
<div class="repository file list"> |
||||||
{{template "repo/header" .}} |
{{template "repo/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<p id="repo-desc"> |
<p id="repo-desc"> |
||||||
{{if .Repository.DescriptionHtml}}<span class="description">{{.Repository.DescriptionHtml}}</span>{{else}}<span class="no-description text-italic">{{.i18n.Tr "repo.no_desc"}}</span>{{end}} |
{{if .Repository.DescriptionHtml}}<span class="description">{{.Repository.DescriptionHtml}}</span>{{else}}<span class="no-description text-italic">{{.i18n.Tr "repo.no_desc"}}</span>{{end}} |
||||||
<a class="link" href="{{.Repository.Website}}">{{.Repository.Website}}</a> |
<a class="link" href="{{.Repository.Website}}">{{.Repository.Website}}</a> |
||||||
</p> |
</p> |
||||||
<div class="ui secondary menu"> |
<div class="ui secondary menu"> |
||||||
{{if .CanPullRequest}} |
{{if .CanPullRequest}} |
||||||
<div class="fitted item"> |
<div class="fitted item"> |
||||||
{{ $baseRepo := .Repository.BaseRepo}} |
{{ $baseRepo := .Repository.BaseRepo}} |
||||||
<a href="{{AppSubUrl}}/{{$baseRepo.Owner.Name}}/{{$baseRepo.Name}}/compare/{{$.BaseDefaultBranch}}...{{$.Owner.Name}}:{{$.BranchName}}"> |
<a href="{{AppSubUrl}}/{{$baseRepo.Owner.Name}}/{{$baseRepo.Name}}/compare/{{$.BaseDefaultBranch}}...{{$.Owner.Name}}:{{$.BranchName}}"> |
||||||
<button class="ui green small button"><i class="octicon octicon-git-compare"></i></button> |
<button class="ui green small button"><i class="octicon octicon-git-compare"></i></button> |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
<div class="fitted item choose reference"> |
<div class="fitted item choose reference"> |
||||||
<div class="ui floating filter dropdown" data-no-results="{{.i18n.Tr "repo.pulls.no_results"}}"> |
<div class="ui floating filter dropdown" data-no-results="{{.i18n.Tr "repo.pulls.no_results"}}"> |
||||||
<div class="ui basic small button"> |
<div class="ui basic small button"> |
||||||
<span class="text"> |
<span class="text"> |
||||||
<i class="octicon octicon-git-branch"></i> |
<i class="octicon octicon-git-branch"></i> |
||||||
{{if .IsViewBranch}}{{.i18n.Tr "repo.branch"}}{{else}}{{.i18n.Tr "repo.tree"}}{{end}}: |
{{if .IsViewBranch}}{{.i18n.Tr "repo.branch"}}{{else}}{{.i18n.Tr "repo.tree"}}{{end}}: |
||||||
<strong>{{if .IsViewBranch}}{{.BranchName}}{{else}}{{ShortSha .BranchName}}{{end}}</strong> |
<strong>{{if .IsViewBranch}}{{.BranchName}}{{else}}{{ShortSha .BranchName}}{{end}}</strong> |
||||||
</span> |
</span> |
||||||
<i class="dropdown icon"></i> |
<i class="dropdown icon"></i> |
||||||
</div> |
</div> |
||||||
<div class="menu"> |
<div class="menu"> |
||||||
<div class="ui icon search input"> |
<div class="ui icon search input"> |
||||||
<i class="filter icon"></i> |
<i class="filter icon"></i> |
||||||
<input name="search" placeholder="{{.i18n.Tr "repo.filter_branch_and_tag"}}..."> |
<input name="search" placeholder="{{.i18n.Tr "repo.filter_branch_and_tag"}}..."> |
||||||
</div> |
</div> |
||||||
<div class="header"> |
<div class="header"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
<div class="two column row"> |
<div class="two column row"> |
||||||
<a class="reference column" href="#" data-target="#branch-list"> |
<a class="reference column" href="#" data-target="#branch-list"> |
||||||
<span class="text {{if .IsViewBranch}}black{{end}}"> |
<span class="text {{if .IsViewBranch}}black{{end}}"> |
||||||
<i class="icon octicon octicon-git-branch"></i> {{.i18n.Tr "repo.branches"}} |
<i class="icon octicon octicon-git-branch"></i> {{.i18n.Tr "repo.branches"}} |
||||||
</span> |
</span> |
||||||
</a> |
</a> |
||||||
<a class="reference column" href="#" data-target="#tag-list"> |
<a class="reference column" href="#" data-target="#tag-list"> |
||||||
<span class="text {{if .IsTag}}black{{end}}"> |
<span class="text {{if .IsTag}}black{{end}}"> |
||||||
<i class="reference tags icon"></i> {{.i18n.Tr "repo.tags"}} |
<i class="reference tags icon"></i> {{.i18n.Tr "repo.tags"}} |
||||||
</span> |
</span> |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div id="branch-list" class="scrolling menu" {{if .IsTag}}style="display: none"{{end}}> |
<div id="branch-list" class="scrolling menu" {{if .IsTag}}style="display: none"{{end}}> |
||||||
{{range .Branches}} |
{{range .Branches}} |
||||||
<div class="item {{if eq $.BranchName .}}selected{{end}}" data-url="{{$.RepoLink}}/src/{{EscapePound .}}">{{.}}</div> |
<div class="item {{if eq $.BranchName .}}selected{{end}}" data-url="{{$.RepoLink}}/src/{{EscapePound .}}">{{.}}</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
<div id="tag-list" class="scrolling menu" {{if .IsViewBranch}}style="display: none"{{end}}> |
<div id="tag-list" class="scrolling menu" {{if .IsViewBranch}}style="display: none"{{end}}> |
||||||
{{range .Tags}} |
{{range .Tags}} |
||||||
<div class="item {{if eq $.BranchName .}}selected{{end}}" data-url="{{$.RepoLink}}/src/{{EscapePound .}}">{{.}}</div> |
<div class="item {{if eq $.BranchName .}}selected{{end}}" data-url="{{$.RepoLink}}/src/{{EscapePound .}}">{{.}}</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="item fitted"> |
<div class="item fitted"> |
||||||
<div class="ui breadcrumb"> |
<div class="ui breadcrumb"> |
||||||
<a class="section" href="{{.RepoLink}}/src/{{EscapePound .BranchName}}">{{.Repository.Name}}</a> |
<a class="section" href="{{.RepoLink}}/src/{{EscapePound .BranchName}}">{{.Repository.Name}}</a> |
||||||
{{ $n := len .Treenames}} |
{{ $n := len .Treenames}} |
||||||
{{ $l := Subtract $n 1}} |
{{ $l := Subtract $n 1}} |
||||||
{{range $i, $v := .Treenames}} |
{{range $i, $v := .Treenames}} |
||||||
<div class="divider"> / </div> |
<div class="divider"> / </div> |
||||||
{{if eq $i $l}} |
{{if eq $i $l}} |
||||||
<span class="active section">{{$v}}</span> |
<span class="active section">{{$v}}</span> |
||||||
{{else}} |
{{else}} |
||||||
{{ $p := index $.Paths $i}} |
{{ $p := index $.Paths $i}} |
||||||
<span class="section"><a href="{{EscapePound $.BranchLink}}/{{EscapePound $p}}">{{$v}}</a></span> |
<span class="section"><a href="{{EscapePound $.BranchLink}}/{{EscapePound $p}}">{{$v}}</a></span> |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{if eq $n 0}} |
{{if eq $n 0}} |
||||||
<div class="right fitted item"> |
<div class="right fitted item"> |
||||||
<div class="ui action small input" id="clone-panel"> |
<div class="ui action small input" id="clone-panel"> |
||||||
{{if not $.DisableSSH}} |
{{if not $.DisableSSH}} |
||||||
<button class="ui blue basic clone button" id="repo-clone-ssh" data-link="{{.CloneLink.SSH}}"> |
<button class="ui blue basic clone button" id="repo-clone-ssh" data-link="{{.CloneLink.SSH}}"> |
||||||
SSH |
SSH |
||||||
</button> |
</button> |
||||||
{{end}} |
{{end}} |
||||||
<button class="ui {{if $.DisableSSH}}blue{{end}} basic clone button" id="repo-clone-https" data-link="{{.CloneLink.HTTPS}}"> |
<button class="ui {{if $.DisableSSH}}blue{{end}} basic clone button" id="repo-clone-https" data-link="{{.CloneLink.HTTPS}}"> |
||||||
{{if UseHTTPS}}HTTPS{{else}}HTTP{{end}} |
{{if UseHTTPS}}HTTPS{{else}}HTTP{{end}} |
||||||
</button> |
</button> |
||||||
<input id="repo-clone-url" value="{{if $.DisableSSH}}{{$.CloneLink.HTTPS}}{{else}}{{$.CloneLink.SSH}}{{end}}" readonly> |
<input id="repo-clone-url" value="{{if $.DisableSSH}}{{$.CloneLink.HTTPS}}{{else}}{{$.CloneLink.SSH}}{{end}}" readonly> |
||||||
<button class="ui basic icon button poping up clipboard" id="clipboard-btn" data-original="{{.i18n.Tr "repo.copy_link"}}" data-success="{{.i18n.Tr "repo.copy_link_success"}}" data-error="{{.i18n.Tr "repo.copy_link_error"}}" data-content="{{.i18n.Tr "repo.copy_link"}}" data-variation="inverted tiny" data-clipboard-target="#repo-clone-url"> |
<button class="ui basic icon button poping up clipboard" id="clipboard-btn" data-original="{{.i18n.Tr "repo.copy_link"}}" data-success="{{.i18n.Tr "repo.copy_link_success"}}" data-error="{{.i18n.Tr "repo.copy_link_error"}}" data-content="{{.i18n.Tr "repo.copy_link"}}" data-variation="inverted tiny" data-clipboard-target="#repo-clone-url"> |
||||||
<i class="octicon octicon-clippy"></i> |
<i class="octicon octicon-clippy"></i> |
||||||
</button> |
</button> |
||||||
<div class="ui basic jump dropdown icon button"> |
<div class="ui basic jump dropdown icon button"> |
||||||
<i class="download icon"></i> |
<i class="download icon"></i> |
||||||
<div class="menu"> |
<div class="menu"> |
||||||
<a class="item" href="{{$.RepoLink}}/archive/{{EscapePound $.BranchName}}.zip"><i class="icon octicon octicon-file-zip"></i> ZIP</a> |
<a class="item" href="{{$.RepoLink}}/archive/{{EscapePound $.BranchName}}.zip"><i class="icon octicon octicon-file-zip"></i> ZIP</a> |
||||||
<a class="item" href="{{$.RepoLink}}/archive/{{EscapePound $.BranchName}}.tar.gz"><i class="icon octicon octicon-file-zip"></i> TAR.GZ</a> |
<a class="item" href="{{$.RepoLink}}/archive/{{EscapePound $.BranchName}}.tar.gz"><i class="icon octicon octicon-file-zip"></i> TAR.GZ</a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
{{if .IsFile}} |
{{if .IsFile}} |
||||||
{{template "repo/view_file" .}} |
{{template "repo/view_file" .}} |
||||||
{{else}} |
{{else}} |
||||||
{{template "repo/view_list" .}} |
{{template "repo/view_list" .}} |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,16 +1,16 @@ |
|||||||
<div class="field"> |
<div class="field"> |
||||||
<div class="ui top attached tabular menu" data-write="write" data-preview="preview"> |
<div class="ui top attached tabular menu" data-write="write" data-preview="preview"> |
||||||
<a class="active item" data-tab="write">{{.i18n.Tr "repo.release.write"}}</a> |
<a class="active item" data-tab="write">{{.i18n.Tr "repo.release.write"}}</a> |
||||||
<a class="item" data-tab="preview" data-url="{{AppSubUrl}}/api/v1/markdown" data-context="{{.RepoLink}}">{{.i18n.Tr "repo.release.preview"}}</a> |
<a class="item" data-tab="preview" data-url="{{AppSubUrl}}/api/v1/markdown" data-context="{{.RepoLink}}">{{.i18n.Tr "repo.release.preview"}}</a> |
||||||
</div> |
</div> |
||||||
<div class="ui bottom attached active tab segment" data-tab="write"> |
<div class="ui bottom attached active tab segment" data-tab="write"> |
||||||
<textarea id="content" name="content" tabindex="4"></textarea> |
<textarea id="content" name="content" tabindex="4"></textarea> |
||||||
</div> |
</div> |
||||||
<div class="ui bottom attached tab segment markdown" data-tab="preview"> |
<div class="ui bottom attached tab segment markdown" data-tab="preview"> |
||||||
{{.i18n.Tr "repo.release.loading"}} |
{{.i18n.Tr "repo.release.loading"}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{if .IsAttachmentEnabled}} |
{{if .IsAttachmentEnabled}} |
||||||
<div class="attachments"></div> |
<div class="attachments"></div> |
||||||
<div class="ui basic button dropzone" id="dropzone" data-upload-url="{{AppSubUrl}}/issues/attachments" data-accepts="{{.AttachmentAllowedTypes}}" data-max-file="{{.AttachmentMaxFiles}}" data-max-size="{{.AttachmentMaxSize}}" data-default-message="{{.i18n.Tr "dropzone.default_message"}}" data-invalid-input-type="{{.i18n.Tr "dropzone.invalid_input_type"}}" data-file-too-big="{{.i18n.Tr "dropzone.file_too_big"}}" data-remove-file="{{.i18n.Tr "dropzone.remove_file"}}"></div> |
<div class="ui basic button dropzone" id="dropzone" data-upload-url="{{AppSubUrl}}/issues/attachments" data-accepts="{{.AttachmentAllowedTypes}}" data-max-file="{{.AttachmentMaxFiles}}" data-max-size="{{.AttachmentMaxSize}}" data-default-message="{{.i18n.Tr "dropzone.default_message"}}" data-invalid-input-type="{{.i18n.Tr "dropzone.invalid_input_type"}}" data-file-too-big="{{.i18n.Tr "dropzone.file_too_big"}}" data-remove-file="{{.i18n.Tr "dropzone.remove_file"}}"></div> |
||||||
{{end}} |
{{end}} |
||||||
|
@ -1,4 +1,4 @@ |
|||||||
<div class="ui compact small menu"> |
<div class="ui compact small menu"> |
||||||
<a class="{{if .PageIsLabels}}active{{end}} item" href="{{.RepoLink}}/labels">{{.i18n.Tr "repo.labels"}}</a> |
<a class="{{if .PageIsLabels}}active{{end}} item" href="{{.RepoLink}}/labels">{{.i18n.Tr "repo.labels"}}</a> |
||||||
<a class="{{if .PageIsMilestones}}active{{end}} item" href="{{.RepoLink}}/milestones">{{.i18n.Tr "repo.milestones"}}</a> |
<a class="{{if .PageIsMilestones}}active{{end}} item" href="{{.RepoLink}}/milestones">{{.i18n.Tr "repo.milestones"}}</a> |
||||||
</div> |
</div> |
||||||
|
@ -1,17 +1,17 @@ |
|||||||
<div class="ui top attached pull tabular menu"> |
<div class="ui top attached pull tabular menu"> |
||||||
<a class="item {{if .PageIsPullConversation}}active{{end}}" href="{{.RepoLink}}/pulls/{{.Issue.Index}}"> |
<a class="item {{if .PageIsPullConversation}}active{{end}}" href="{{.RepoLink}}/pulls/{{.Issue.Index}}"> |
||||||
<span class="octicon octicon-comment-discussion"></span> |
<span class="octicon octicon-comment-discussion"></span> |
||||||
{{$.i18n.Tr "repo.pulls.tab_conversation"}} |
{{$.i18n.Tr "repo.pulls.tab_conversation"}} |
||||||
<span class="ui label">{{.Issue.NumComments}}</span> |
<span class="ui label">{{.Issue.NumComments}}</span> |
||||||
</a> |
</a> |
||||||
<a class="item {{if .PageIsPullCommits}}active{{end}}" {{if .NumCommits}}href="{{.RepoLink}}/pulls/{{.Issue.Index}}/commits"{{end}}> |
<a class="item {{if .PageIsPullCommits}}active{{end}}" {{if .NumCommits}}href="{{.RepoLink}}/pulls/{{.Issue.Index}}/commits"{{end}}> |
||||||
<span class="octicon octicon-git-commit"></span> |
<span class="octicon octicon-git-commit"></span> |
||||||
{{$.i18n.Tr "repo.pulls.tab_commits"}} |
{{$.i18n.Tr "repo.pulls.tab_commits"}} |
||||||
<span class="ui label">{{if .NumCommits}}{{.NumCommits}}{{else}}N/A{{end}}</span> |
<span class="ui label">{{if .NumCommits}}{{.NumCommits}}{{else}}N/A{{end}}</span> |
||||||
</a> |
</a> |
||||||
<a class="item {{if .PageIsPullFiles}}active{{end}}" {{if .NumFiles}}href="{{.RepoLink}}/pulls/{{.Issue.Index}}/files"{{end}}> |
<a class="item {{if .PageIsPullFiles}}active{{end}}" {{if .NumFiles}}href="{{.RepoLink}}/pulls/{{.Issue.Index}}/files"{{end}}> |
||||||
<span class="octicon octicon-diff"></span> |
<span class="octicon octicon-diff"></span> |
||||||
{{$.i18n.Tr "repo.pulls.tab_files"}} |
{{$.i18n.Tr "repo.pulls.tab_files"}} |
||||||
<span class="ui label">{{if .NumFiles}}{{.NumFiles}}{{else}}N/A{{end}}</span> |
<span class="ui label">{{if .NumFiles}}{{.NumFiles}}{{else}}N/A{{end}}</span> |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
|
@ -1,80 +1,80 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="repository release"> |
<div class="repository release"> |
||||||
{{template "repo/header" .}} |
{{template "repo/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h2 class="ui header"> |
<h2 class="ui header"> |
||||||
{{.i18n.Tr "repo.release.releases"}} |
{{.i18n.Tr "repo.release.releases"}} |
||||||
{{if .IsRepositoryAdmin}} |
{{if .IsRepositoryAdmin}} |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<a class="ui small green button" href="{{$.RepoLink}}/releases/new"> |
<a class="ui small green button" href="{{$.RepoLink}}/releases/new"> |
||||||
{{.i18n.Tr "repo.release.new_release"}} |
{{.i18n.Tr "repo.release.new_release"}} |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
</h2> |
</h2> |
||||||
<ul id="release-list"> |
<ul id="release-list"> |
||||||
{{range .Releases}} |
{{range .Releases}} |
||||||
<li class="ui grid"> |
<li class="ui grid"> |
||||||
<div class="ui four wide column meta"> |
<div class="ui four wide column meta"> |
||||||
{{if .PublisherID}} |
{{if .PublisherID}} |
||||||
{{if .IsDraft}} |
{{if .IsDraft}} |
||||||
<span class="ui yellow label">{{$.i18n.Tr "repo.release.draft"}}</span> |
<span class="ui yellow label">{{$.i18n.Tr "repo.release.draft"}}</span> |
||||||
{{else if .IsPrerelease}} |
{{else if .IsPrerelease}} |
||||||
<span class="ui orange label">{{$.i18n.Tr "repo.release.prerelease"}}</span> |
<span class="ui orange label">{{$.i18n.Tr "repo.release.prerelease"}}</span> |
||||||
{{else}} |
{{else}} |
||||||
<span class="ui green label">{{$.i18n.Tr "repo.release.stable"}}</span> |
<span class="ui green label">{{$.i18n.Tr "repo.release.stable"}}</span> |
||||||
{{end}} |
{{end}} |
||||||
<span class="tag text blue"> |
<span class="tag text blue"> |
||||||
<a href="{{$.RepoLink}}/src/{{.TagName}}" rel="nofollow"><i class="tag icon"></i> {{.TagName}}</a> |
<a href="{{$.RepoLink}}/src/{{.TagName}}" rel="nofollow"><i class="tag icon"></i> {{.TagName}}</a> |
||||||
</span> |
</span> |
||||||
{{end}} |
{{end}} |
||||||
<span class="commit"> |
<span class="commit"> |
||||||
<a href="{{$.RepoLink}}/src/{{.Sha1}}" rel="nofollow"><i class="code icon"></i> {{ShortSha .Sha1}}</a> |
<a href="{{$.RepoLink}}/src/{{.Sha1}}" rel="nofollow"><i class="code icon"></i> {{ShortSha .Sha1}}</a> |
||||||
</span> |
</span> |
||||||
</div> |
</div> |
||||||
<div class="ui twelve wide column detail"> |
<div class="ui twelve wide column detail"> |
||||||
{{if .PublisherID}} |
{{if .PublisherID}} |
||||||
<h3> |
<h3> |
||||||
<a href="{{$.RepoLink}}/src/{{.TagName}}">{{.Title}}</a> |
<a href="{{$.RepoLink}}/src/{{.TagName}}">{{.Title}}</a> |
||||||
{{if $.IsRepositoryAdmin}}<small>(<a href="{{$.RepoLink}}/releases/edit/{{.TagName}}" rel="nofollow">{{$.i18n.Tr "repo.release.edit"}}</a>)</small>{{end}} |
{{if $.IsRepositoryAdmin}}<small>(<a href="{{$.RepoLink}}/releases/edit/{{.TagName}}" rel="nofollow">{{$.i18n.Tr "repo.release.edit"}}</a>)</small>{{end}} |
||||||
</h3> |
</h3> |
||||||
<p class="text grey"> |
<p class="text grey"> |
||||||
<span class="author"> |
<span class="author"> |
||||||
<img class="img-10" src="{{.Publisher.AvatarLink}}"> |
<img class="img-10" src="{{.Publisher.AvatarLink}}"> |
||||||
<a href="{{AppSubUrl}}/{{.Publisher.Name}}">{{.Publisher.Name}}</a> |
<a href="{{AppSubUrl}}/{{.Publisher.Name}}">{{.Publisher.Name}}</a> |
||||||
</span> |
</span> |
||||||
{{if .Created}}<span class="time">{{TimeSince .Created $.Lang}}</span>{{end}} |
{{if .Created}}<span class="time">{{TimeSince .Created $.Lang}}</span>{{end}} |
||||||
<span class="ahead">{{$.i18n.Tr "repo.release.ahead" .NumCommitsBehind .Target | Str2html}}</span> |
<span class="ahead">{{$.i18n.Tr "repo.release.ahead" .NumCommitsBehind .Target | Str2html}}</span> |
||||||
</p> |
</p> |
||||||
<div class="markdown desc"> |
<div class="markdown desc"> |
||||||
{{Str2html .Note}} |
{{Str2html .Note}} |
||||||
</div> |
</div> |
||||||
<div class="download"> |
<div class="download"> |
||||||
<h2>{{$.i18n.Tr "repo.release.downloads"}}</h2> |
<h2>{{$.i18n.Tr "repo.release.downloads"}}</h2> |
||||||
<ul class="list"> |
<ul class="list"> |
||||||
<li> |
<li> |
||||||
<a href="{{$.RepoLink}}/archive/{{.TagName}}.zip" rel="nofollow"><i class="icon octicon octicon-file-zip"></i> {{$.i18n.Tr "repo.release.source_code"}} (ZIP)</a> |
<a href="{{$.RepoLink}}/archive/{{.TagName}}.zip" rel="nofollow"><i class="icon octicon octicon-file-zip"></i> {{$.i18n.Tr "repo.release.source_code"}} (ZIP)</a> |
||||||
</li> |
</li> |
||||||
<li> |
<li> |
||||||
<a href="{{$.RepoLink}}/archive/{{.TagName}}.tar.gz"><i class="icon octicon octicon-file-zip"></i> {{$.i18n.Tr "repo.release.source_code"}} (TAR.GZ)</a> |
<a href="{{$.RepoLink}}/archive/{{.TagName}}.tar.gz"><i class="icon octicon octicon-file-zip"></i> {{$.i18n.Tr "repo.release.source_code"}} (TAR.GZ)</a> |
||||||
</li> |
</li> |
||||||
</ul> |
</ul> |
||||||
</div> |
</div> |
||||||
{{else}} |
{{else}} |
||||||
<h4> |
<h4> |
||||||
<a href="{{$.RepoLink}}/src/{{.TagName}}" rel="nofollow"><i class="tag icon"></i> {{.TagName}}</a> |
<a href="{{$.RepoLink}}/src/{{.TagName}}" rel="nofollow"><i class="tag icon"></i> {{.TagName}}</a> |
||||||
</h4> |
</h4> |
||||||
<div class="download"> |
<div class="download"> |
||||||
<a href="{{$.RepoLink}}/archive/{{.TagName}}.zip" rel="nofollow"><i class="octicon octicon-file-zip"></i> ZIP</a> |
<a href="{{$.RepoLink}}/archive/{{.TagName}}.zip" rel="nofollow"><i class="octicon octicon-file-zip"></i> ZIP</a> |
||||||
<a href="{{$.RepoLink}}/archive/{{.TagName}}.tar.gz"><i class="octicon octicon-file-zip"></i> TAR.GZ</a> |
<a href="{{$.RepoLink}}/archive/{{.TagName}}.tar.gz"><i class="octicon octicon-file-zip"></i> TAR.GZ</a> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
<span class="dot"> </span> |
<span class="dot"> </span> |
||||||
</div> |
</div> |
||||||
</li> |
</li> |
||||||
{{end}} |
{{end}} |
||||||
</ul> |
</ul> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,98 +1,98 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="repository new release"> |
<div class="repository new release"> |
||||||
{{template "repo/header" .}} |
{{template "repo/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<h2 class="ui dividing header"> |
<h2 class="ui dividing header"> |
||||||
{{if .PageIsEditRelease}} |
{{if .PageIsEditRelease}} |
||||||
{{.i18n.Tr "repo.release.edit_release"}} |
{{.i18n.Tr "repo.release.edit_release"}} |
||||||
<div class="sub header">{{.i18n.Tr "repo.release.edit_subheader"}}</div> |
<div class="sub header">{{.i18n.Tr "repo.release.edit_subheader"}}</div> |
||||||
{{else}} |
{{else}} |
||||||
{{.i18n.Tr "repo.release.new_release"}} |
{{.i18n.Tr "repo.release.new_release"}} |
||||||
<div class="sub header">{{.i18n.Tr "repo.release.new_subheader"}}</div> |
<div class="sub header">{{.i18n.Tr "repo.release.new_subheader"}}</div> |
||||||
{{end}} |
{{end}} |
||||||
</h2> |
</h2> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<form class="ui form grid" action="{{.Link}}" method="post"> |
<form class="ui form grid" action="{{.Link}}" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<div class="ui seven wide column target"> |
<div class="ui seven wide column target"> |
||||||
<div class="inline field {{if .Err_TagName}}error{{end}}"> |
<div class="inline field {{if .Err_TagName}}error{{end}}"> |
||||||
{{if .PageIsEditRelease}} |
{{if .PageIsEditRelease}} |
||||||
<b>{{.tag_name}}</b><span class="at">@</span><strong>{{.tag_target}}</strong> |
<b>{{.tag_name}}</b><span class="at">@</span><strong>{{.tag_target}}</strong> |
||||||
{{else}} |
{{else}} |
||||||
<input name="tag_name" value="{{.tag_name}}" placeholder="{{.i18n.Tr "repo.release.tag_name"}}" autofocus required> |
<input name="tag_name" value="{{.tag_name}}" placeholder="{{.i18n.Tr "repo.release.tag_name"}}" autofocus required> |
||||||
<span class="at">@</span> |
<span class="at">@</span> |
||||||
<div class="ui selection dropdown"> |
<div class="ui selection dropdown"> |
||||||
<input type="hidden" name="tag_target" value="{{.tag_target}}"/> |
<input type="hidden" name="tag_target" value="{{.tag_target}}"/> |
||||||
<i class="octicon octicon-git-branch"></i> |
<i class="octicon octicon-git-branch"></i> |
||||||
<div class="text"> |
<div class="text"> |
||||||
{{.i18n.Tr "repo.release.target"}} : |
{{.i18n.Tr "repo.release.target"}} : |
||||||
<strong id="repo-branch-current">{{.Repository.DefaultBranch}}</strong> |
<strong id="repo-branch-current">{{.Repository.DefaultBranch}}</strong> |
||||||
</div> |
</div> |
||||||
<i class="dropdown icon"></i> |
<i class="dropdown icon"></i> |
||||||
<div class="menu"> |
<div class="menu"> |
||||||
{{range .Branches}} |
{{range .Branches}} |
||||||
<div class="item" data-value="{{.}}">{{.}}</div> |
<div class="item" data-value="{{.}}">{{.}}</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<span class="help">{{.i18n.Tr "repo.release.tag_helper"}}</span> |
<span class="help">{{.i18n.Tr "repo.release.tag_helper"}}</span> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="eleven wide column"> |
<div class="eleven wide column"> |
||||||
<div class="field {{if .Err_Title}}error{{end}}"> |
<div class="field {{if .Err_Title}}error{{end}}"> |
||||||
<label>{{.i18n.Tr "repo.release.title"}}</label> |
<label>{{.i18n.Tr "repo.release.title"}}</label> |
||||||
<input name="title" placeholder="{{.i18n.Tr "repo.release.title"}}" value="{{.title}}" autofocus required> |
<input name="title" placeholder="{{.i18n.Tr "repo.release.title"}}" value="{{.title}}" autofocus required> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<label>{{.i18n.Tr "repo.release.content"}}</label> |
<label>{{.i18n.Tr "repo.release.content"}}</label> |
||||||
<textarea name="content">{{.content}}</textarea> |
<textarea name="content">{{.content}}</textarea> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
<div class="ui text right"> |
<div class="ui text right"> |
||||||
<div class="prerelease field"> |
<div class="prerelease field"> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
<input type="checkbox" name="prerelease" {{if .prerelease}}checked{{end}}> |
<input type="checkbox" name="prerelease" {{if .prerelease}}checked{{end}}> |
||||||
<label><strong>{{.i18n.Tr "repo.release.prerelease_desc"}}</strong></label> |
<label><strong>{{.i18n.Tr "repo.release.prerelease_desc"}}</strong></label> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<span class="help">{{.i18n.Tr "repo.release.prerelease_helper"}}</span> |
<span class="help">{{.i18n.Tr "repo.release.prerelease_helper"}}</span> |
||||||
<div class="field"> |
<div class="field"> |
||||||
{{if .PageIsEditRelease}} |
{{if .PageIsEditRelease}} |
||||||
<a class="ui blue basic button" href="{{.RepoLink}}/releases"> |
<a class="ui blue basic button" href="{{.RepoLink}}/releases"> |
||||||
{{.i18n.Tr "repo.release.cancel"}} |
{{.i18n.Tr "repo.release.cancel"}} |
||||||
</a> |
</a> |
||||||
<button class="ui green button"> |
<button class="ui green button"> |
||||||
{{.i18n.Tr "repo.release.edit_release"}} |
{{.i18n.Tr "repo.release.edit_release"}} |
||||||
</button> |
</button> |
||||||
<a class="ui red button delete-button" data-url="{{$.RepoLink}}/releases/delete" data-id="{{.ID}}"> |
<a class="ui red button delete-button" data-url="{{$.RepoLink}}/releases/delete" data-id="{{.ID}}"> |
||||||
{{$.i18n.Tr "repo.release.delete_release"}} |
{{$.i18n.Tr "repo.release.delete_release"}} |
||||||
</a> |
</a> |
||||||
{{else}} |
{{else}} |
||||||
<button class="ui green button"> |
<button class="ui green button"> |
||||||
{{.i18n.Tr "repo.release.publish"}} |
{{.i18n.Tr "repo.release.publish"}} |
||||||
</button> |
</button> |
||||||
<input class="ui grey button" type="submit" name="draft" value="{{.i18n.Tr "repo.release.save_draft"}}"/> |
<input class="ui grey button" type="submit" name="draft" value="{{.i18n.Tr "repo.release.save_draft"}}"/> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</form> |
</form> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
{{if .PageIsEditRelease}} |
{{if .PageIsEditRelease}} |
||||||
<div class="ui small basic delete modal"> |
<div class="ui small basic delete modal"> |
||||||
<div class="ui icon header"> |
<div class="ui icon header"> |
||||||
<i class="trash icon"></i> |
<i class="trash icon"></i> |
||||||
{{.i18n.Tr "repo.release.deletion"}} |
{{.i18n.Tr "repo.release.deletion"}} |
||||||
</div> |
</div> |
||||||
<div class="content"> |
<div class="content"> |
||||||
<p>{{.i18n.Tr "repo.release.deletion_desc"}}</p> |
<p>{{.i18n.Tr "repo.release.deletion_desc"}}</p> |
||||||
</div> |
</div> |
||||||
{{template "base/delete_modal_actions" .}} |
{{template "base/delete_modal_actions" .}} |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,19 +1,19 @@ |
|||||||
<div class="ui small basic delete modal"> |
<div class="ui small basic delete modal"> |
||||||
<div class="ui icon header"> |
<div class="ui icon header"> |
||||||
<i class="trash icon"></i> |
<i class="trash icon"></i> |
||||||
{{.i18n.Tr "repo.settings.webhook_deletion"}} |
{{.i18n.Tr "repo.settings.webhook_deletion"}} |
||||||
</div> |
</div> |
||||||
<div class="content"> |
<div class="content"> |
||||||
<p>{{.i18n.Tr "repo.settings.webhook_deletion_desc"}}</p> |
<p>{{.i18n.Tr "repo.settings.webhook_deletion_desc"}}</p> |
||||||
</div> |
</div> |
||||||
<div class="actions"> |
<div class="actions"> |
||||||
<div class="ui red basic inverted cancel button"> |
<div class="ui red basic inverted cancel button"> |
||||||
<i class="remove icon"></i> |
<i class="remove icon"></i> |
||||||
{{.i18n.Tr "modal.no"}} |
{{.i18n.Tr "modal.no"}} |
||||||
</div> |
</div> |
||||||
<div class="ui green basic inverted ok button"> |
<div class="ui green basic inverted ok button"> |
||||||
<i class="checkmark icon"></i> |
<i class="checkmark icon"></i> |
||||||
{{.i18n.Tr "modal.yes"}} |
{{.i18n.Tr "modal.yes"}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
@ -1,28 +1,28 @@ |
|||||||
{{if eq .HookType "gogs"}} |
{{if eq .HookType "gogs"}} |
||||||
<p>{{.i18n.Tr "repo.settings.add_webhook_desc" "http://gogs.io/docs/features/webhook.html" | Str2html}}</p> |
<p>{{.i18n.Tr "repo.settings.add_webhook_desc" "http://gogs.io/docs/features/webhook.html" | Str2html}}</p> |
||||||
<form class="ui form" action="{{.BaseLink}}/settings/hooks/gogs/{{if .PageIsSettingsHooksNew}}new{{else}}{{.Webhook.ID}}{{end}}" method="post"> |
<form class="ui form" action="{{.BaseLink}}/settings/hooks/gogs/{{if .PageIsSettingsHooksNew}}new{{else}}{{.Webhook.ID}}{{end}}" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<div class="required field {{if .Err_PayloadURL}}error{{end}}"> |
<div class="required field {{if .Err_PayloadURL}}error{{end}}"> |
||||||
<label for="payload_url">{{.i18n.Tr "repo.settings.payload_url"}}</label> |
<label for="payload_url">{{.i18n.Tr "repo.settings.payload_url"}}</label> |
||||||
<input id="payload_url" name="payload_url" type="url" value="{{.Webhook.URL}}" autofocus required> |
<input id="payload_url" name="payload_url" type="url" value="{{.Webhook.URL}}" autofocus required> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<label>{{.i18n.Tr "repo.settings.content_type"}}</label> |
<label>{{.i18n.Tr "repo.settings.content_type"}}</label> |
||||||
<div class="ui selection dropdown"> |
<div class="ui selection dropdown"> |
||||||
<input type="hidden" id="content_type" name="content_type" value="{{if .Webhook.ContentType}}{{.Webhook.ContentType}}{{else}}application/json{{end}}"> |
<input type="hidden" id="content_type" name="content_type" value="{{if .Webhook.ContentType}}{{.Webhook.ContentType}}{{else}}application/json{{end}}"> |
||||||
<div class="default text"></div> |
<div class="default text"></div> |
||||||
<i class="dropdown icon"></i> |
<i class="dropdown icon"></i> |
||||||
<div class="menu"> |
<div class="menu"> |
||||||
<div class="item" data-value="1">application/json</div> |
<div class="item" data-value="1">application/json</div> |
||||||
<div class="item" data-value="2">application/x-www-form-urlencoded</div> |
<div class="item" data-value="2">application/x-www-form-urlencoded</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<input class="fake" type="password"> |
<input class="fake" type="password"> |
||||||
<div class="field {{if .Err_Secret}}error{{end}}"> |
<div class="field {{if .Err_Secret}}error{{end}}"> |
||||||
<label for="secret">{{.i18n.Tr "repo.settings.secret"}}</label> |
<label for="secret">{{.i18n.Tr "repo.settings.secret"}}</label> |
||||||
<input id="secret" name="secret" type="password" value="{{.Webhook.Secret}}" autocomplete="off"> |
<input id="secret" name="secret" type="password" value="{{.Webhook.Secret}}" autocomplete="off"> |
||||||
</div> |
</div> |
||||||
{{template "repo/settings/hook_settings" .}} |
{{template "repo/settings/hook_settings" .}} |
||||||
</form> |
</form> |
||||||
{{end}} |
{{end}} |
||||||
|
@ -1,73 +1,73 @@ |
|||||||
{{if .PageIsSettingsHooksEdit}} |
{{if .PageIsSettingsHooksEdit}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "repo.settings.recent_deliveries"}} |
{{.i18n.Tr "repo.settings.recent_deliveries"}} |
||||||
{{if .IsRepositoryAdmin}} |
{{if .IsRepositoryAdmin}} |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<button class="ui teal tiny button poping up" id="test-delivery" data-content= |
<button class="ui teal tiny button poping up" id="test-delivery" data-content= |
||||||
"{{.i18n.Tr "repo.settings.webhook.test_delivery_desc"}}" data-variation="inverted tiny" data-link="{{.Link}}/test" data-redirect="{{.Link}}">{{.i18n.Tr "repo.settings.webhook.test_delivery"}}</button> |
"{{.i18n.Tr "repo.settings.webhook.test_delivery_desc"}}" data-variation="inverted tiny" data-link="{{.Link}}/test" data-redirect="{{.Link}}">{{.i18n.Tr "repo.settings.webhook.test_delivery"}}</button> |
||||||
</div> |
|
||||||
{{end}} |
|
||||||
</h4> |
|
||||||
<div class="ui attached table segment"> |
|
||||||
<div class="ui hook history list"> |
|
||||||
{{range .History}} |
|
||||||
<div class="item"> |
|
||||||
<div class="meta"> |
|
||||||
{{if .IsSucceed}} |
|
||||||
<span class="text green"><i class="octicon octicon-check"></i></span> |
|
||||||
{{else}} |
|
||||||
<span class="text red"><i class="octicon octicon-alert"></i></span> |
|
||||||
{{end}} |
|
||||||
<a class="ui blue sha label toggle button" data-target="#info-{{.ID}}">{{.UUID}}</a> |
|
||||||
<div class="ui right"> |
|
||||||
<span class="text grey time"> |
|
||||||
{{.DeliveredString}} |
|
||||||
</span> |
|
||||||
</div> |
|
||||||
</div> |
</div> |
||||||
<div class="info hide" id="info-{{.ID}}"> |
{{end}} |
||||||
<div class="ui top attached tabular menu"> |
</h4> |
||||||
<a class="item active" data-tab="request-{{.ID}}">{{$.i18n.Tr "repo.settings.webhook.request"}}</a> |
<div class="ui attached table segment"> |
||||||
<a class="item" data-tab="response-{{.ID}}"> |
<div class="ui hook history list"> |
||||||
{{$.i18n.Tr "repo.settings.webhook.response"}} |
{{range .History}} |
||||||
{{if .ResponseInfo}} |
<div class="item"> |
||||||
{{if .IsSucceed}} |
<div class="meta"> |
||||||
<span class="ui green label">{{.ResponseInfo.Status}}</span> |
{{if .IsSucceed}} |
||||||
{{else}} |
<span class="text green"><i class="octicon octicon-check"></i></span> |
||||||
<span class="ui red label">{{.ResponseInfo.Status}}</span> |
{{else}} |
||||||
{{end}} |
<span class="text red"><i class="octicon octicon-alert"></i></span> |
||||||
{{else}} |
{{end}} |
||||||
<span class="ui label">N/A</span> |
<a class="ui blue sha label toggle button" data-target="#info-{{.ID}}">{{.UUID}}</a> |
||||||
{{end}} |
<div class="ui right"> |
||||||
</a> |
<span class="text grey time"> |
||||||
</div> |
{{.DeliveredString}} |
||||||
<div class="ui bottom attached tab segment active" data-tab="request-{{.ID}}"> |
</span> |
||||||
{{if .RequestInfo}} |
</div> |
||||||
<h5>{{$.i18n.Tr "repo.settings.webhook.headers"}}</h5> |
</div> |
||||||
<pre class="raw"><strong>Request URL:</strong> {{.URL}} |
<div class="info hide" id="info-{{.ID}}"> |
||||||
|
<div class="ui top attached tabular menu"> |
||||||
|
<a class="item active" data-tab="request-{{.ID}}">{{$.i18n.Tr "repo.settings.webhook.request"}}</a> |
||||||
|
<a class="item" data-tab="response-{{.ID}}"> |
||||||
|
{{$.i18n.Tr "repo.settings.webhook.response"}} |
||||||
|
{{if .ResponseInfo}} |
||||||
|
{{if .IsSucceed}} |
||||||
|
<span class="ui green label">{{.ResponseInfo.Status}}</span> |
||||||
|
{{else}} |
||||||
|
<span class="ui red label">{{.ResponseInfo.Status}}</span> |
||||||
|
{{end}} |
||||||
|
{{else}} |
||||||
|
<span class="ui label">N/A</span> |
||||||
|
{{end}} |
||||||
|
</a> |
||||||
|
</div> |
||||||
|
<div class="ui bottom attached tab segment active" data-tab="request-{{.ID}}"> |
||||||
|
{{if .RequestInfo}} |
||||||
|
<h5>{{$.i18n.Tr "repo.settings.webhook.headers"}}</h5> |
||||||
|
<pre class="raw"><strong>Request URL:</strong> {{.URL}} |
||||||
<strong>Request method:</strong> POST |
<strong>Request method:</strong> POST |
||||||
{{ range $key, $val := .RequestInfo.Headers }}<strong>{{$key}}:</strong> {{$val}} |
{{ range $key, $val := .RequestInfo.Headers }}<strong>{{$key}}:</strong> {{$val}} |
||||||
{{end}}</pre> |
{{end}}</pre> |
||||||
<h5>{{$.i18n.Tr "repo.settings.webhook.payload"}}</h5> |
<h5>{{$.i18n.Tr "repo.settings.webhook.payload"}}</h5> |
||||||
<pre class="raw"><code class="json">{{.PayloadContent}}</code></pre> |
<pre class="raw"><code class="json">{{.PayloadContent}}</code></pre> |
||||||
{{else}} |
{{else}} |
||||||
N/A |
N/A |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
<div class="ui bottom attached tab segment" data-tab="response-{{.ID}}"> |
<div class="ui bottom attached tab segment" data-tab="response-{{.ID}}"> |
||||||
{{if .ResponseInfo}} |
{{if .ResponseInfo}} |
||||||
<h5>{{$.i18n.Tr "repo.settings.webhook.headers"}}</h5> |
<h5>{{$.i18n.Tr "repo.settings.webhook.headers"}}</h5> |
||||||
<pre class="raw">{{ range $key, $val := .ResponseInfo.Headers }}<strong>{{$key}}:</strong> {{$val}} |
<pre class="raw">{{ range $key, $val := .ResponseInfo.Headers }}<strong>{{$key}}:</strong> {{$val}} |
||||||
{{end}}</pre> |
{{end}}</pre> |
||||||
<h5>{{$.i18n.Tr "repo.settings.webhook.body"}}</h5> |
<h5>{{$.i18n.Tr "repo.settings.webhook.body"}}</h5> |
||||||
<pre class="raw"><code>{{.ResponseInfo.Body}}</code></pre> |
<pre class="raw"><code>{{.ResponseInfo.Body}}</code></pre> |
||||||
{{else}} |
{{else}} |
||||||
N/A |
N/A |
||||||
{{end}} |
{{end}} |
||||||
|
</div> |
||||||
|
</div> |
||||||
</div> |
</div> |
||||||
</div> |
{{end}} |
||||||
</div> |
</div> |
||||||
{{end}} |
|
||||||
</div> |
</div> |
||||||
</div> |
{{end}} |
||||||
{{end}} |
|
||||||
|
@ -1,44 +1,44 @@ |
|||||||
<div class="twelve wide column content"> |
<div class="twelve wide column content"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<h4 class="ui top attached header"> |
<h4 class="ui top attached header"> |
||||||
{{.i18n.Tr "repo.settings.hooks"}} |
{{.i18n.Tr "repo.settings.hooks"}} |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<div class="ui floating1 jump dropdown"> |
<div class="ui floating1 jump dropdown"> |
||||||
<div class="ui blue tiny button">{{.i18n.Tr "repo.settings.add_webhook"}}</div> |
<div class="ui blue tiny button">{{.i18n.Tr "repo.settings.add_webhook"}}</div> |
||||||
<div class="menu"> |
<div class="menu"> |
||||||
<a class="item" href="{{.BaseLink}}/settings/hooks/gogs/new"> |
<a class="item" href="{{.BaseLink}}/settings/hooks/gogs/new"> |
||||||
<img class="img-10" src="{{AppSubUrl}}/img/favicon.png">Gogs |
<img class="img-10" src="{{AppSubUrl}}/img/favicon.png">Gogs |
||||||
</a> |
</a> |
||||||
<a class="item" href="{{.BaseLink}}/settings/hooks/slack/new"> |
<a class="item" href="{{.BaseLink}}/settings/hooks/slack/new"> |
||||||
<img class="img-10" src="{{AppSubUrl}}/img/slack.png">Slack |
<img class="img-10" src="{{AppSubUrl}}/img/slack.png">Slack |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<div class="ui hook list"> |
<div class="ui hook list"> |
||||||
<div class="item"> |
|
||||||
{{.Description | Str2html}} |
|
||||||
</div> |
|
||||||
{{range .Webhooks}} |
|
||||||
<div class="item"> |
<div class="item"> |
||||||
{{if eq .LastStatus 1}} |
{{.Description | Str2html}} |
||||||
<span class="text green"><i class="octicon octicon-check"></i></span> |
|
||||||
{{else if eq .LastStatus 2}} |
|
||||||
<span class="text red"><i class="octicon octicon-alert"></i></span> |
|
||||||
{{else}} |
|
||||||
<span class="text grey"><i class="octicon octicon-primitive-dot"></i></span> |
|
||||||
{{end}} |
|
||||||
<a href="{{$.BaseLink}}/settings/hooks/{{.ID}}">{{.URL}}</a> |
|
||||||
<div class="ui right"> |
|
||||||
<span class="text blue"><a href="{{$.BaseLink}}/settings/hooks/{{.ID}}"><i class="fa fa-pencil"></i></a></span> |
|
||||||
<span class="text red"><a class="delete-button" data-url="{{$.Link}}/delete" data-id="{{.ID}}"><i class="fa fa-times"></i></a></span> |
|
||||||
</div> |
|
||||||
</div> |
</div> |
||||||
{{end}} |
{{range .Webhooks}} |
||||||
</div> |
<div class="item"> |
||||||
</div> |
{{if eq .LastStatus 1}} |
||||||
|
<span class="text green"><i class="octicon octicon-check"></i></span> |
||||||
|
{{else if eq .LastStatus 2}} |
||||||
|
<span class="text red"><i class="octicon octicon-alert"></i></span> |
||||||
|
{{else}} |
||||||
|
<span class="text grey"><i class="octicon octicon-primitive-dot"></i></span> |
||||||
|
{{end}} |
||||||
|
<a href="{{$.BaseLink}}/settings/hooks/{{.ID}}">{{.URL}}</a> |
||||||
|
<div class="ui right"> |
||||||
|
<span class="text blue"><a href="{{$.BaseLink}}/settings/hooks/{{.ID}}"><i class="fa fa-pencil"></i></a></span> |
||||||
|
<span class="text red"><a class="delete-button" data-url="{{$.Link}}/delete" data-id="{{.ID}}"><i class="fa fa-times"></i></a></span> |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
{{end}} |
||||||
|
</div> |
||||||
|
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
{{template "repo/settings/hook_delete_modal" .}} |
{{template "repo/settings/hook_delete_modal" .}} |
||||||
|
@ -1,66 +1,66 @@ |
|||||||
<div class="field"> |
<div class="field"> |
||||||
<h4>{{.i18n.Tr "repo.settings.event_desc"}}</h4> |
<h4>{{.i18n.Tr "repo.settings.event_desc"}}</h4> |
||||||
<div class="grouped event type fields"> |
<div class="grouped event type fields"> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<div class="ui radio non-events checkbox"> |
<div class="ui radio non-events checkbox"> |
||||||
<input class="hidden" name="events" type="radio" value="push_only" {{if or .PageIsSettingsHooksNew .Webhook.PushOnly}}checked{{end}}> |
<input class="hidden" name="events" type="radio" value="push_only" {{if or .PageIsSettingsHooksNew .Webhook.PushOnly}}checked{{end}}> |
||||||
<label>{{.i18n.Tr "repo.settings.event_push_only" | Str2html}}</label> |
<label>{{.i18n.Tr "repo.settings.event_push_only" | Str2html}}</label> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<div class="ui radio non-events checkbox"> |
<div class="ui radio non-events checkbox"> |
||||||
<input class="hidden" name="events" type="radio" value="send_everything" {{if .Webhook.SendEverything}}checked{{end}}> |
<input class="hidden" name="events" type="radio" value="send_everything" {{if .Webhook.SendEverything}}checked{{end}}> |
||||||
<label>{{.i18n.Tr "repo.settings.event_send_everything" | Str2html}}</label> |
<label>{{.i18n.Tr "repo.settings.event_send_everything" | Str2html}}</label> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<div class="ui radio events checkbox"> |
<div class="ui radio events checkbox"> |
||||||
<input class="hidden" name="events" type="radio" value="choose_events" {{if .Webhook.ChooseEvents}}checked{{end}}> |
<input class="hidden" name="events" type="radio" value="choose_events" {{if .Webhook.ChooseEvents}}checked{{end}}> |
||||||
<label>{{.i18n.Tr "repo.settings.event_choose" | Str2html}}</label> |
<label>{{.i18n.Tr "repo.settings.event_choose" | Str2html}}</label> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="events fields ui grid" {{if not .Webhook.ChooseEvents}}style="display:none"{{end}}> |
<div class="events fields ui grid" {{if not .Webhook.ChooseEvents}}style="display:none"{{end}}> |
||||||
<!-- Create --> |
<!-- Create --> |
||||||
<div class="seven wide column"> |
<div class="seven wide column"> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
<input class="hidden" name="create" type="checkbox" tabindex="0" {{if .Webhook.Create}}checked{{end}}> |
<input class="hidden" name="create" type="checkbox" tabindex="0" {{if .Webhook.Create}}checked{{end}}> |
||||||
<label>{{.i18n.Tr "repo.settings.event_create"}}</label> |
<label>{{.i18n.Tr "repo.settings.event_create"}}</label> |
||||||
<span class="help">{{.i18n.Tr "repo.settings.event_create_desc"}}</span> |
<span class="help">{{.i18n.Tr "repo.settings.event_create_desc"}}</span> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<!-- Push --> |
<!-- Push --> |
||||||
<div class="seven wide column"> |
<div class="seven wide column"> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
<input class="hidden" name="push" type="checkbox" tabindex="0" {{if .Webhook.Push}}checked{{end}}> |
<input class="hidden" name="push" type="checkbox" tabindex="0" {{if .Webhook.Push}}checked{{end}}> |
||||||
<label>{{.i18n.Tr "repo.settings.event_push"}}</label> |
<label>{{.i18n.Tr "repo.settings.event_push"}}</label> |
||||||
<span class="help">{{.i18n.Tr "repo.settings.event_push_desc"}}</span> |
<span class="help">{{.i18n.Tr "repo.settings.event_push_desc"}}</span> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
|
|
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<div class="ui checkbox"> |
<div class="ui checkbox"> |
||||||
<input class="hidden" name="active" type="checkbox" tabindex="0" {{if or .PageIsSettingsHooksNew .Webhook.IsActive}}checked{{end}}> |
<input class="hidden" name="active" type="checkbox" tabindex="0" {{if or .PageIsSettingsHooksNew .Webhook.IsActive}}checked{{end}}> |
||||||
<label>{{.i18n.Tr "repo.settings.active"}}</label> |
<label>{{.i18n.Tr "repo.settings.active"}}</label> |
||||||
<span class="help">{{.i18n.Tr "repo.settings.active_helper"}}</span> |
<span class="help">{{.i18n.Tr "repo.settings.active_helper"}}</span> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
{{if .PageIsSettingsHooksNew}} |
{{if .PageIsSettingsHooksNew}} |
||||||
<button class="ui green button">{{.i18n.Tr "repo.settings.add_webhook"}}</button> |
<button class="ui green button">{{.i18n.Tr "repo.settings.add_webhook"}}</button> |
||||||
{{else}} |
{{else}} |
||||||
<button class="ui green button">{{.i18n.Tr "repo.settings.update_webhook"}}</button> |
<button class="ui green button">{{.i18n.Tr "repo.settings.update_webhook"}}</button> |
||||||
<a class="ui red delete-button button" data-url="{{.BaseLink}}/settings/hooks/delete" data-id="{{.Webhook.ID}}">{{.i18n.Tr "repo.settings.delete_webhook"}}</a> |
<a class="ui red delete-button button" data-url="{{.BaseLink}}/settings/hooks/delete" data-id="{{.Webhook.ID}}">{{.i18n.Tr "repo.settings.delete_webhook"}}</a> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
|
|
||||||
{{template "repo/settings/hook_delete_modal" .}} |
{{template "repo/settings/hook_delete_modal" .}} |
||||||
|
@ -1,28 +1,28 @@ |
|||||||
{{if eq .HookType "slack"}} |
{{if eq .HookType "slack"}} |
||||||
<p>{{.i18n.Tr "repo.settings.add_slack_hook_desc" "http://slack.com" | Str2html}}</p> |
<p>{{.i18n.Tr "repo.settings.add_slack_hook_desc" "http://slack.com" | Str2html}}</p> |
||||||
<form class="ui form" action="{{.BaseLink}}/settings/hooks/slack/{{if .PageIsSettingsHooksNew}}new{{else}}{{.Webhook.ID}}{{end}}" method="post"> |
<form class="ui form" action="{{.BaseLink}}/settings/hooks/slack/{{if .PageIsSettingsHooksNew}}new{{else}}{{.Webhook.ID}}{{end}}" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<div class="required field {{if .Err_PayloadURL}}error{{end}}"> |
<div class="required field {{if .Err_PayloadURL}}error{{end}}"> |
||||||
<label for="payload_url">{{.i18n.Tr "repo.settings.payload_url"}}</label> |
<label for="payload_url">{{.i18n.Tr "repo.settings.payload_url"}}</label> |
||||||
<input id="payload_url" name="payload_url" type="url" value="{{.Webhook.URL}}" autofocus required> |
<input id="payload_url" name="payload_url" type="url" value="{{.Webhook.URL}}" autofocus required> |
||||||
</div> |
</div> |
||||||
<div class="required field {{if .Err_Channel}}error{{end}}"> |
<div class="required field {{if .Err_Channel}}error{{end}}"> |
||||||
<label for="channel">{{.i18n.Tr "repo.settings.slack_channel"}}</label> |
<label for="channel">{{.i18n.Tr "repo.settings.slack_channel"}}</label> |
||||||
<input id="channel" name="channel" value="{{.SlackHook.Channel}}" placeholder="e.g. #general" required> |
<input id="channel" name="channel" value="{{.SlackHook.Channel}}" placeholder="e.g. #general" required> |
||||||
</div> |
</div> |
||||||
|
|
||||||
<div class="field"> |
<div class="field"> |
||||||
<label for="username">{{.i18n.Tr "repo.settings.slack_username"}}</label> |
<label for="username">{{.i18n.Tr "repo.settings.slack_username"}}</label> |
||||||
<input id="username" name="username" value="{{.SlackHook.Username}}" placeholder="e.g. Gogs"> |
<input id="username" name="username" value="{{.SlackHook.Username}}" placeholder="e.g. Gogs"> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<label for="icon_url">{{.i18n.Tr "repo.settings.slack_icon_url"}}</label> |
<label for="icon_url">{{.i18n.Tr "repo.settings.slack_icon_url"}}</label> |
||||||
<input id="icon_url" name="icon_url" value="{{.SlackHook.IconURL}}" placeholder="e.g. https://example.com/img/favicon.png"> |
<input id="icon_url" name="icon_url" value="{{.SlackHook.IconURL}}" placeholder="e.g. https://example.com/img/favicon.png"> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<label for="color">{{.i18n.Tr "repo.settings.slack_color"}}</label> |
<label for="color">{{.i18n.Tr "repo.settings.slack_color"}}</label> |
||||||
<input id="color" name="color" value="{{.SlackHook.Color}}" placeholder="e.g. #dd4b39, good, warning, danger"> |
<input id="color" name="color" value="{{.SlackHook.Color}}" placeholder="e.g. #dd4b39, good, warning, danger"> |
||||||
</div> |
</div> |
||||||
{{template "repo/settings/hook_settings" .}} |
{{template "repo/settings/hook_settings" .}} |
||||||
</form> |
</form> |
||||||
{{end}} |
{{end}} |
||||||
|
@ -1,14 +1,14 @@ |
|||||||
<div id="setting-menu" class="grid-1-5 panel panel-radius left"> |
<div id="setting-menu" class="grid-1-5 panel panel-radius left"> |
||||||
<p class="panel-header"><strong>{{.i18n.Tr "repo.settings"}}</strong></p> |
<p class="panel-header"><strong>{{.i18n.Tr "repo.settings"}}</strong></p> |
||||||
<div class="panel-body"> |
<div class="panel-body"> |
||||||
<ul class="menu menu-vertical switching-list grid-1-5 left"> |
<ul class="menu menu-vertical switching-list grid-1-5 left"> |
||||||
<li {{if .PageIsSettingsOptions}}class="current"{{end}}><a href="{{.RepoLink}}/settings">{{.i18n.Tr "repo.settings.options"}}</a></li> |
<li {{if .PageIsSettingsOptions}}class="current"{{end}}><a href="{{.RepoLink}}/settings">{{.i18n.Tr "repo.settings.options"}}</a></li> |
||||||
<li {{if .PageIsSettingsCollaboration}}class="current"{{end}}><a href="{{.RepoLink}}/settings/collaboration">{{.i18n.Tr "repo.settings.collaboration"}}</a></li> |
<li {{if .PageIsSettingsCollaboration}}class="current"{{end}}><a href="{{.RepoLink}}/settings/collaboration">{{.i18n.Tr "repo.settings.collaboration"}}</a></li> |
||||||
<li {{if .PageIsSettingsHooks}}class="current"{{end}}><a href="{{.RepoLink}}/settings/hooks">{{.i18n.Tr "repo.settings.hooks"}}</a></li> |
<li {{if .PageIsSettingsHooks}}class="current"{{end}}><a href="{{.RepoLink}}/settings/hooks">{{.i18n.Tr "repo.settings.hooks"}}</a></li> |
||||||
{{if or .SignedUser.AllowGitHook .SignedUser.IsAdmin}} |
{{if or .SignedUser.AllowGitHook .SignedUser.IsAdmin}} |
||||||
<li {{if .PageIsSettingsGitHooks}}class="current"{{end}}><a href="{{.RepoLink}}/settings/hooks/git">{{.i18n.Tr "repo.settings.githooks"}}</a></li> |
<li {{if .PageIsSettingsGitHooks}}class="current"{{end}}><a href="{{.RepoLink}}/settings/hooks/git">{{.i18n.Tr "repo.settings.githooks"}}</a></li> |
||||||
{{end}} |
{{end}} |
||||||
<li {{if .PageIsSettingsKeys}}class="current"{{end}}><a href="{{.RepoLink}}/settings/keys">{{.i18n.Tr "repo.settings.deploy_keys"}}</a></li> |
<li {{if .PageIsSettingsKeys}}class="current"{{end}}><a href="{{.RepoLink}}/settings/keys">{{.i18n.Tr "repo.settings.deploy_keys"}}</a></li> |
||||||
</ul> |
</ul> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
@ -1,22 +1,22 @@ |
|||||||
<div class="four wide column"> |
<div class="four wide column"> |
||||||
<div class="ui vertical menu"> |
<div class="ui vertical menu"> |
||||||
<div class="header item">{{.i18n.Tr "repo.settings"}}</div> |
<div class="header item">{{.i18n.Tr "repo.settings"}}</div> |
||||||
<a class="{{if .PageIsSettingsOptions}}active{{end}} item" href="{{.RepoLink}}/settings"> |
<a class="{{if .PageIsSettingsOptions}}active{{end}} item" href="{{.RepoLink}}/settings"> |
||||||
{{.i18n.Tr "repo.settings.options"}} |
{{.i18n.Tr "repo.settings.options"}} |
||||||
</a> |
</a> |
||||||
<a class="{{if .PageIsSettingsCollaboration}}active{{end}} item" href="{{.RepoLink}}/settings/collaboration"> |
<a class="{{if .PageIsSettingsCollaboration}}active{{end}} item" href="{{.RepoLink}}/settings/collaboration"> |
||||||
{{.i18n.Tr "repo.settings.collaboration"}} |
{{.i18n.Tr "repo.settings.collaboration"}} |
||||||
</a> |
</a> |
||||||
<a class="{{if .PageIsSettingsHooks}}active{{end}} item" href="{{.RepoLink}}/settings/hooks"> |
<a class="{{if .PageIsSettingsHooks}}active{{end}} item" href="{{.RepoLink}}/settings/hooks"> |
||||||
{{.i18n.Tr "repo.settings.hooks"}} |
{{.i18n.Tr "repo.settings.hooks"}} |
||||||
</a> |
</a> |
||||||
{{if .SignedUser.CanEditGitHook}} |
{{if .SignedUser.CanEditGitHook}} |
||||||
<a class="{{if .PageIsSettingsGitHooks}}active{{end}} item" href="{{.RepoLink}}/settings/hooks/git"> |
<a class="{{if .PageIsSettingsGitHooks}}active{{end}} item" href="{{.RepoLink}}/settings/hooks/git"> |
||||||
{{.i18n.Tr "repo.settings.githooks"}} |
{{.i18n.Tr "repo.settings.githooks"}} |
||||||
</a> |
</a> |
||||||
{{end}} |
{{end}} |
||||||
<a class="{{if .PageIsSettingsKeys}}active{{end}} item" href="{{.RepoLink}}/settings/keys"> |
<a class="{{if .PageIsSettingsKeys}}active{{end}} item" href="{{.RepoLink}}/settings/keys"> |
||||||
{{.i18n.Tr "repo.settings.deploy_keys"}} |
{{.i18n.Tr "repo.settings.deploy_keys"}} |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
@ -1,50 +1,50 @@ |
|||||||
<div id="file-content"> |
<div id="file-content"> |
||||||
<h4 class="ui top attached header" id="{{if .ReadmeExist}}repo-readme{{else}}repo-read-file{{end}}"> |
<h4 class="ui top attached header" id="{{if .ReadmeExist}}repo-readme{{else}}repo-read-file{{end}}"> |
||||||
{{if .ReadmeExist}} |
{{if .ReadmeExist}} |
||||||
<i class="book icon ui left"></i> |
<i class="book icon ui left"></i> |
||||||
{{if .ReadmeInList}} |
{{if .ReadmeInList}} |
||||||
<strong>{{.FileName}}</strong> |
<strong>{{.FileName}}</strong> |
||||||
{{else}} |
{{else}} |
||||||
<strong>{{.FileName}}</strong> <span class="text grey normal">{{FileSize .FileSize}}</span> |
<strong>{{.FileName}}</strong> <span class="text grey normal">{{FileSize .FileSize}}</span> |
||||||
{{end}} |
{{end}} |
||||||
{{else}} |
{{else}} |
||||||
<i class="file text outline icon ui left"></i> |
<i class="file text outline icon ui left"></i> |
||||||
<strong>{{.FileName}}</strong> <span class="text grey normal">{{FileSize .FileSize}}</span> |
<strong>{{.FileName}}</strong> <span class="text grey normal">{{FileSize .FileSize}}</span> |
||||||
{{end}} |
{{end}} |
||||||
{{if not .ReadmeInList}} |
{{if not .ReadmeInList}} |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<div class="ui small grey basic buttons"> |
<div class="ui small grey basic buttons"> |
||||||
{{if not .IsCommit}} |
{{if not .IsCommit}} |
||||||
<a class="ui button" href="{{.RepoLink}}/src/{{.CommitID}}/{{EscapePound .TreeName}}">{{.i18n.Tr "repo.file_permalink"}}</a> |
<a class="ui button" href="{{.RepoLink}}/src/{{.CommitID}}/{{EscapePound .TreeName}}">{{.i18n.Tr "repo.file_permalink"}}</a> |
||||||
{{end}} |
{{end}} |
||||||
<a class="ui button" href="{{.RepoLink}}/commits/{{EscapePound .BranchName}}/{{EscapePound .TreeName}}">{{.i18n.Tr "repo.file_history"}}</a> |
<a class="ui button" href="{{.RepoLink}}/commits/{{EscapePound .BranchName}}/{{EscapePound .TreeName}}">{{.i18n.Tr "repo.file_history"}}</a> |
||||||
<a class="ui button" href="{{EscapePound .FileLink}}">{{.i18n.Tr "repo.file_raw"}}</a> |
<a class="ui button" href="{{EscapePound .FileLink}}">{{.i18n.Tr "repo.file_raw"}}</a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
</h4> |
</h4> |
||||||
<div class="ui attached table segment"> |
<div class="ui attached table segment"> |
||||||
<div class="file-view {{if .ReadmeExist}}markdown{{else if .IsFileText}}code-view{{end}}"> |
<div class="file-view {{if .ReadmeExist}}markdown{{else if .IsFileText}}code-view{{end}}"> |
||||||
{{if .ReadmeExist}} |
{{if .ReadmeExist}} |
||||||
{{if .FileContent}}{{.FileContent | Str2html}}{{end}} |
{{if .FileContent}}{{.FileContent | Str2html}}{{end}} |
||||||
{{else if not .IsFileText}} |
{{else if not .IsFileText}} |
||||||
<div class="view-raw"> |
<div class="view-raw"> |
||||||
{{if .IsImageFile}} |
{{if .IsImageFile}} |
||||||
<img src="{{EscapePound .FileLink}}"> |
<img src="{{EscapePound .FileLink}}"> |
||||||
{{else}} |
{{else}} |
||||||
<a href="{{EscapePound .FileLink}}" rel="nofollow" class="btn btn-gray btn-radius">{{.i18n.Tr "repo.file_view_raw"}}</a> |
<a href="{{EscapePound .FileLink}}" rel="nofollow" class="btn btn-gray btn-radius">{{.i18n.Tr "repo.file_view_raw"}}</a> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
{{else if .FileSize}} |
{{else if .FileSize}} |
||||||
<table> |
<table> |
||||||
<tbody> |
<tbody> |
||||||
<tr> |
<tr> |
||||||
<td class="lines-num"></td> |
<td class="lines-num"></td> |
||||||
<td class="lines-code"><pre class="{{if .FileExt}}lang-{{.FileExt}}{{end}}"><code><ol class="linenums">{{.FileContent}}</ol></code></pre></td> |
<td class="lines-code"><pre class="{{if .FileExt}}lang-{{.FileExt}}{{end}}"><code><ol class="linenums">{{.FileContent}}</ol></code></pre></td> |
||||||
</tr> |
</tr> |
||||||
</tbody> |
</tbody> |
||||||
</table> |
</table> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
|
@ -1,56 +1,56 @@ |
|||||||
<table id="repo-files-table" class="ui fixed single line table"> |
<table id="repo-files-table" class="ui fixed single line table"> |
||||||
<thead> |
<thead> |
||||||
<tr> |
<tr> |
||||||
<th class="four wide"> |
<th class="four wide"> |
||||||
{{if .LastCommitUser}} |
{{if .LastCommitUser}} |
||||||
<img class="ui avatar image img-12" src="{{.LastCommitUser.AvatarLink}}" /> |
<img class="ui avatar image img-12" src="{{.LastCommitUser.AvatarLink}}" /> |
||||||
<a href="{{AppSubUrl}}/{{.LastCommitUser.Name}}"><strong>{{.LastCommit.Author.Name}}</strong></a> |
<a href="{{AppSubUrl}}/{{.LastCommitUser.Name}}"><strong>{{.LastCommit.Author.Name}}</strong></a> |
||||||
{{else}} |
{{else}} |
||||||
<img class="ui avatar image img-12" src="{{AvatarLink .LastCommit.Author.Email}}" /> |
<img class="ui avatar image img-12" src="{{AvatarLink .LastCommit.Author.Email}}" /> |
||||||
<strong>{{.LastCommit.Author.Name}}</strong> |
<strong>{{.LastCommit.Author.Name}}</strong> |
||||||
{{end}} |
{{end}} |
||||||
<a rel="nofollow" class="ui sha label" href="{{.RepoLink}}/commit/{{.LastCommit.ID}}" rel="nofollow">{{ShortSha .LastCommit.ID.String}}</a> |
<a rel="nofollow" class="ui sha label" href="{{.RepoLink}}/commit/{{.LastCommit.ID}}" rel="nofollow">{{ShortSha .LastCommit.ID.String}}</a> |
||||||
<span class="grey">{{RenderCommitMessage false .LastCommit.Summary .RepoLink $.Repository.ComposeMetas}}</span> |
<span class="grey">{{RenderCommitMessage false .LastCommit.Summary .RepoLink $.Repository.ComposeMetas}}</span> |
||||||
</th> |
</th> |
||||||
<th class="nine wide"> |
<th class="nine wide"> |
||||||
</th> |
</th> |
||||||
<th class="three wide text grey right age">{{TimeSince .LastCommit.Author.When $.Lang}}</th> |
<th class="three wide text grey right age">{{TimeSince .LastCommit.Author.When $.Lang}}</th> |
||||||
</tr> |
</tr> |
||||||
</thead> |
</thead> |
||||||
<tbody> |
<tbody> |
||||||
{{if .HasParentPath}} |
{{if .HasParentPath}} |
||||||
<tr class="has-parent"> |
<tr class="has-parent"> |
||||||
<td colspan="3"><i class="icon octicon octicon-mail-reply"></i><a href="{{EscapePound .BranchLink}}{{.ParentPath}}">..</a></td> |
<td colspan="3"><i class="icon octicon octicon-mail-reply"></i><a href="{{EscapePound .BranchLink}}{{.ParentPath}}">..</a></td> |
||||||
</tr> |
</tr> |
||||||
{{end}} |
{{end}} |
||||||
{{range $item := .Files}} |
{{range $item := .Files}} |
||||||
{{$entry := index $item 0}} |
{{$entry := index $item 0}} |
||||||
{{$commit := index $item 1}} |
{{$commit := index $item 1}} |
||||||
<tr> |
<tr> |
||||||
{{if $entry.IsSubModule}} |
{{if $entry.IsSubModule}} |
||||||
<td> |
<td> |
||||||
<span class="icon octicon octicon-file-submodule"></span> |
<span class="icon octicon octicon-file-submodule"></span> |
||||||
{{if $commit.RefUrl}} |
{{if $commit.RefUrl}} |
||||||
<a href="{{$commit.RefUrl}}">{{$entry.Name}}</a> @ <a href="{{$commit.RefUrl}}/commit/{{$commit.RefId}}">{{ShortSha $commit.RefId}}</a> |
<a href="{{$commit.RefUrl}}">{{$entry.Name}}</a> @ <a href="{{$commit.RefUrl}}/commit/{{$commit.RefId}}">{{ShortSha $commit.RefId}}</a> |
||||||
{{else}} |
{{else}} |
||||||
{{$entry.Name}} @ {{ShortSha $commit.RefId}} |
{{$entry.Name}} @ {{ShortSha $commit.RefId}} |
||||||
{{end}} |
{{end}} |
||||||
</td> |
</td> |
||||||
{{else}} |
{{else}} |
||||||
<td class="name"> |
<td class="name"> |
||||||
<span class="icon octicon octicon-file-{{if or $entry.IsDir}}directory{{else}}text{{end}}"></span> |
<span class="icon octicon octicon-file-{{if or $entry.IsDir}}directory{{else}}text{{end}}"></span> |
||||||
<a href="{{EscapePound $.BranchLink}}/{{EscapePound $.TreePath}}{{EscapePound $entry.Name}}">{{$entry.Name}}</a> |
<a href="{{EscapePound $.BranchLink}}/{{EscapePound $.TreePath}}{{EscapePound $entry.Name}}">{{$entry.Name}}</a> |
||||||
</td> |
</td> |
||||||
{{end}} |
{{end}} |
||||||
<td class="message collapsing"> |
<td class="message collapsing"> |
||||||
<a rel="nofollow" class="ui sha label" href="{{AppSubUrl}}/{{$.Username}}/{{$.Reponame}}/commit/{{$commit.ID}}">{{ShortSha $commit.ID.String}}</a> |
<a rel="nofollow" class="ui sha label" href="{{AppSubUrl}}/{{$.Username}}/{{$.Reponame}}/commit/{{$commit.ID}}">{{ShortSha $commit.ID.String}}</a> |
||||||
{{RenderCommitMessage false $commit.Summary $.RepoLink $.Repository.ComposeMetas}} |
{{RenderCommitMessage false $commit.Summary $.RepoLink $.Repository.ComposeMetas}} |
||||||
</td> |
</td> |
||||||
<td class="text grey right age">{{TimeSince $commit.Committer.When $.Lang}}</td> |
<td class="text grey right age">{{TimeSince $commit.Committer.When $.Lang}}</td> |
||||||
</tr> |
</tr> |
||||||
{{end}} |
{{end}} |
||||||
</tbody> |
</tbody> |
||||||
</table> |
</table> |
||||||
{{if .ReadmeExist}} |
{{if .ReadmeExist}} |
||||||
{{template "repo/view_file" .}} |
{{template "repo/view_file" .}} |
||||||
{{end}} |
{{end}} |
||||||
|
@ -1,56 +1,56 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="repository watchers"> |
<div class="repository watchers"> |
||||||
{{template "repo/header" .}} |
{{template "repo/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<h2 class="ui dividing header"> |
<h2 class="ui dividing header"> |
||||||
{{if .PageIsWatchers}} |
{{if .PageIsWatchers}} |
||||||
{{.i18n.Tr "repo.watchers"}} |
{{.i18n.Tr "repo.watchers"}} |
||||||
{{else}} |
{{else}} |
||||||
{{.i18n.Tr "repo.stargazers"}} |
{{.i18n.Tr "repo.stargazers"}} |
||||||
{{end}} |
{{end}} |
||||||
</h2> |
</h2> |
||||||
<ul class="list"> |
<ul class="list"> |
||||||
{{range .Watchers}} |
{{range .Watchers}} |
||||||
<li class="item ui segment"> |
<li class="item ui segment"> |
||||||
<a href="{{.HomeLink}}"> |
<a href="{{.HomeLink}}"> |
||||||
<img class="avatar" src="{{.AvatarLink}}"/> |
<img class="avatar" src="{{.AvatarLink}}"/> |
||||||
</a> |
</a> |
||||||
<h3 class="name"><a href="{{.HomeLink}}">{{.DisplayName}}</a></h3> |
<h3 class="name"><a href="{{.HomeLink}}">{{.DisplayName}}</a></h3> |
||||||
|
|
||||||
<div class="meta"> |
<div class="meta"> |
||||||
{{if .Website}} |
{{if .Website}} |
||||||
<span class="icon octicon octicon-link"></span> <a href="{{.Website}}" target="_blank">{{.Website}}</a> |
<span class="icon octicon octicon-link"></span> <a href="{{.Website}}" target="_blank">{{.Website}}</a> |
||||||
{{else if .Location}} |
{{else if .Location}} |
||||||
<span class="icon octicon octicon-location"></span> {{.Location}} |
<span class="icon octicon octicon-location"></span> {{.Location}} |
||||||
{{else}} |
{{else}} |
||||||
<span class="icon octicon octicon-clock"></span> {{$.i18n.Tr "user.join_on"}} {{DateFmtShort .Created}} |
<span class="icon octicon octicon-clock"></span> {{$.i18n.Tr "user.join_on"}} {{DateFmtShort .Created}} |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</li> |
</li> |
||||||
{{end}} |
{{end}} |
||||||
</ul> |
</ul> |
||||||
|
|
||||||
{{with .Page}} |
{{with .Page}} |
||||||
{{if gt .TotalPages 1}} |
{{if gt .TotalPages 1}} |
||||||
<div class="center page buttons"> |
<div class="center page buttons"> |
||||||
<div class="ui borderless pagination menu"> |
<div class="ui borderless pagination menu"> |
||||||
<a class="{{if not .HasPrevious}}disabled{{end}} item" {{if .HasPrevious}}href="{{$.Link}}?page={{.Previous}}"{{end}}> |
<a class="{{if not .HasPrevious}}disabled{{end}} item" {{if .HasPrevious}}href="{{$.Link}}?page={{.Previous}}"{{end}}> |
||||||
<i class="left arrow icon"></i> {{$.i18n.Tr "repo.issues.previous"}} |
<i class="left arrow icon"></i> {{$.i18n.Tr "repo.issues.previous"}} |
||||||
</a> |
</a> |
||||||
{{range .Pages}} |
{{range .Pages}} |
||||||
{{if eq .Num -1}} |
{{if eq .Num -1}} |
||||||
<a class="disabled item">...</a> |
<a class="disabled item">...</a> |
||||||
{{else}} |
{{else}} |
||||||
<a class="{{if .IsCurrent}}active{{end}} item" {{if not .IsCurrent}}href="{{$.Link}}?page={{.Num}}"{{end}}>{{.Num}}</a> |
<a class="{{if .IsCurrent}}active{{end}} item" {{if not .IsCurrent}}href="{{$.Link}}?page={{.Num}}"{{end}}>{{.Num}}</a> |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
<a class="{{if not .HasNext}}disabled{{end}} item" {{if .HasNext}}href="{{$.Link}}?page={{.Next}}"{{end}}> |
<a class="{{if not .HasNext}}disabled{{end}} item" {{if .HasNext}}href="{{$.Link}}?page={{.Next}}"{{end}}> |
||||||
{{$.i18n.Tr "repo.issues.next"}} <i class="icon right arrow"></i> |
{{$.i18n.Tr "repo.issues.next"}} <i class="icon right arrow"></i> |
||||||
</a> |
</a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,34 +1,34 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="repository wiki new"> |
<div class="repository wiki new"> |
||||||
{{template "repo/header" .}} |
{{template "repo/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
<div class="ui header"> |
<div class="ui header"> |
||||||
{{.i18n.Tr "repo.wiki.new_page"}} |
{{.i18n.Tr "repo.wiki.new_page"}} |
||||||
{{if .PageIsWikiEdit}} |
{{if .PageIsWikiEdit}} |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<a class="ui green small button" href="{{.RepoLink}}/wiki/_new">{{.i18n.Tr "repo.wiki.new_page_button"}}</a> |
<a class="ui green small button" href="{{.RepoLink}}/wiki/_new">{{.i18n.Tr "repo.wiki.new_page_button"}}</a> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
<form class="ui form" action="{{.Link}}" method="post"> |
<form class="ui form" action="{{.Link}}" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<input type="hidden" name="old_title" value="{{.old_title}}"> |
<input type="hidden" name="old_title" value="{{.old_title}}"> |
||||||
<div class="field {{if .Err_Title}}error{{end}}"> |
<div class="field {{if .Err_Title}}error{{end}}"> |
||||||
<input name="title" value="{{.title}}" autofocus required> |
<input name="title" value="{{.title}}" autofocus required> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<textarea id="edit-area" name="content" data-url="{{AppSubUrl}}/api/v1/markdown" data-context="{{.RepoLink}}">{{if .PageIsWikiEdit}}{{.content}}{{else}}{{.i18n.Tr "repo.wiki.welcome"}}{{end}}</textarea required> |
<textarea id="edit-area" name="content" data-url="{{AppSubUrl}}/api/v1/markdown" data-context="{{.RepoLink}}">{{if .PageIsWikiEdit}}{{.content}}{{else}}{{.i18n.Tr "repo.wiki.welcome"}}{{end}}</textarea required> |
||||||
</div> |
</div> |
||||||
<div class="field"> |
<div class="field"> |
||||||
<input name="message" placeholder="{{.i18n.Tr "repo.wiki.default_commit_message"}}"> |
<input name="message" placeholder="{{.i18n.Tr "repo.wiki.default_commit_message"}}"> |
||||||
</div> |
</div> |
||||||
<div class="text right"> |
<div class="text right"> |
||||||
<button class="ui green button"> |
<button class="ui green button"> |
||||||
{{.i18n.Tr "repo.wiki.save_page"}} |
{{.i18n.Tr "repo.wiki.save_page"}} |
||||||
</button> |
</button> |
||||||
</div> |
</div> |
||||||
</form> |
</form> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,27 +1,27 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="repository wiki pages"> |
<div class="repository wiki pages"> |
||||||
{{template "repo/header" .}} |
{{template "repo/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui header"> |
<div class="ui header"> |
||||||
{{.i18n.Tr "repo.wiki.pages"}} |
{{.i18n.Tr "repo.wiki.pages"}} |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<a class="ui green small button" href="{{.RepoLink}}/wiki/_new">{{.i18n.Tr "repo.wiki.new_page_button"}}</a> |
<a class="ui green small button" href="{{.RepoLink}}/wiki/_new">{{.i18n.Tr "repo.wiki.new_page_button"}}</a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<table class="ui table"> |
<table class="ui table"> |
||||||
<tbody> |
<tbody> |
||||||
{{range .Pages}} |
{{range .Pages}} |
||||||
<tr> |
<tr> |
||||||
<td> |
<td> |
||||||
<i class="icon octicon octicon-file-text"></i> |
<i class="icon octicon octicon-file-text"></i> |
||||||
<a href="{{$.RepoLink}}/wiki/{{.URL}}">{{.Name}}</a> |
<a href="{{$.RepoLink}}/wiki/{{.URL}}">{{.Name}}</a> |
||||||
</td> |
</td> |
||||||
{{$timeSince := TimeSince .Updated $.Lang}} |
{{$timeSince := TimeSince .Updated $.Lang}} |
||||||
<td class="text right grey">{{$.i18n.Tr "repo.wiki.last_updated" $timeSince | Safe}}</td> |
<td class="text right grey">{{$.i18n.Tr "repo.wiki.last_updated" $timeSince | Safe}}</td> |
||||||
</tr> |
</tr> |
||||||
{{end}} |
{{end}} |
||||||
</tbody> |
</tbody> |
||||||
</table> |
</table> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,15 +1,15 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="repository wiki start"> |
<div class="repository wiki start"> |
||||||
{{template "repo/header" .}} |
{{template "repo/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui center segment"> |
<div class="ui center segment"> |
||||||
<span class="mega-octicon octicon-book"></span> |
<span class="mega-octicon octicon-book"></span> |
||||||
<h2>{{.i18n.Tr "repo.wiki.welcome"}}</h2> |
<h2>{{.i18n.Tr "repo.wiki.welcome"}}</h2> |
||||||
<p>{{.i18n.Tr "repo.wiki.welcome_desc"}}</p> |
<p>{{.i18n.Tr "repo.wiki.welcome_desc"}}</p> |
||||||
{{if .IsRepositoryPusher}} |
{{if .IsRepositoryPusher}} |
||||||
<a class="ui green button" href="{{.RepoLink}}/wiki/_new">{{.i18n.Tr "repo.wiki.create_first_page"}}</a> |
<a class="ui green button" href="{{.RepoLink}}/wiki/_new">{{.i18n.Tr "repo.wiki.create_first_page"}}</a> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,72 +1,72 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="repository wiki view"> |
<div class="repository wiki view"> |
||||||
{{template "repo/header" .}} |
{{template "repo/header" .}} |
||||||
<div class="ui container"> |
<div class="ui container"> |
||||||
<div class="ui grid"> |
<div class="ui grid"> |
||||||
<div class="ui ten wide column"> |
<div class="ui ten wide column"> |
||||||
<div class="choose page"> |
<div class="choose page"> |
||||||
<div class="ui floating filter dropdown" data-no-results="{{.i18n.Tr "repo.pulls.no_results"}}"> |
<div class="ui floating filter dropdown" data-no-results="{{.i18n.Tr "repo.pulls.no_results"}}"> |
||||||
<div class="ui basic small button"> |
<div class="ui basic small button"> |
||||||
<span class="text"> |
<span class="text"> |
||||||
{{.i18n.Tr "repo.wiki.page"}}: |
{{.i18n.Tr "repo.wiki.page"}}: |
||||||
<strong>{{.title}}</strong> |
<strong>{{.title}}</strong> |
||||||
</span> |
</span> |
||||||
<i class="dropdown icon"></i> |
<i class="dropdown icon"></i> |
||||||
</div> |
</div> |
||||||
<div class="menu"> |
<div class="menu"> |
||||||
<div class="ui icon search input"> |
<div class="ui icon search input"> |
||||||
<i class="filter icon"></i> |
<i class="filter icon"></i> |
||||||
<input name="search" placeholder="{{.i18n.Tr "repo.wiki.filter_page"}}..."> |
<input name="search" placeholder="{{.i18n.Tr "repo.wiki.filter_page"}}..."> |
||||||
</div> |
</div> |
||||||
<div class="scrolling menu" {{if .IsTag}}style="display: none"{{end}}> |
<div class="scrolling menu" {{if .IsTag}}style="display: none"{{end}}> |
||||||
{{range .Pages}} |
{{range .Pages}} |
||||||
<div class="item {{if eq $.Title .Name}}selected{{end}}" data-url="{{$.RepoLink}}/wiki/{{.URL}}">{{.Name}}</div> |
<div class="item {{if eq $.Title .Name}}selected{{end}}" data-url="{{$.RepoLink}}/wiki/{{.URL}}">{{.Name}}</div> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="ui six wide column"> |
<div class="ui six wide column"> |
||||||
<div class="ui action small input" id="clone-panel"> |
<div class="ui action small input" id="clone-panel"> |
||||||
{{if not $.DisableSSH}} |
{{if not $.DisableSSH}} |
||||||
<button class="ui blue basic clone button" id="repo-clone-ssh" data-link="{{.WikiCloneLink.SSH}}"> |
<button class="ui blue basic clone button" id="repo-clone-ssh" data-link="{{.WikiCloneLink.SSH}}"> |
||||||
SSH |
SSH |
||||||
</button> |
</button> |
||||||
{{end}} |
{{end}} |
||||||
<button class="ui {{if $.DisableSSH}}blue{{end}} basic clone button" id="repo-clone-https" data-link="{{.WikiCloneLink.HTTPS}}"> |
<button class="ui {{if $.DisableSSH}}blue{{end}} basic clone button" id="repo-clone-https" data-link="{{.WikiCloneLink.HTTPS}}"> |
||||||
{{if UseHTTPS}}HTTPS{{else}}HTTP{{end}} |
{{if UseHTTPS}}HTTPS{{else}}HTTP{{end}} |
||||||
</button> |
</button> |
||||||
<input id="repo-clone-url" value="{{if $.DisableSSH}}{{$.WikiCloneLink.HTTPS}}{{else}}{{$.WikiCloneLink.SSH}}{{end}}" readonly> |
<input id="repo-clone-url" value="{{if $.DisableSSH}}{{$.WikiCloneLink.HTTPS}}{{else}}{{$.WikiCloneLink.SSH}}{{end}}" readonly> |
||||||
<button class="ui basic icon button poping up clipboard" id="clipboard-btn" data-original="{{.i18n.Tr "repo.copy_link"}}" data-success="{{.i18n.Tr "repo.copy_link_success"}}" data-error="{{.i18n.Tr "repo.copy_link_error"}}" data-content="{{.i18n.Tr "repo.copy_link"}}" data-variation="inverted tiny" data-clipboard-target="#repo-clone-url"> |
<button class="ui basic icon button poping up clipboard" id="clipboard-btn" data-original="{{.i18n.Tr "repo.copy_link"}}" data-success="{{.i18n.Tr "repo.copy_link_success"}}" data-error="{{.i18n.Tr "repo.copy_link_error"}}" data-content="{{.i18n.Tr "repo.copy_link"}}" data-variation="inverted tiny" data-clipboard-target="#repo-clone-url"> |
||||||
<i class="octicon octicon-clippy"></i> |
<i class="octicon octicon-clippy"></i> |
||||||
</button> |
</button> |
||||||
<div class="ui basic jump dropdown icon button"> |
<div class="ui basic jump dropdown icon button"> |
||||||
<i class="download icon"></i> |
<i class="download icon"></i> |
||||||
<div class="menu"> |
<div class="menu"> |
||||||
<a class="item" href="{{$.RepoLink}}/archive/{{EscapePound $.BranchName}}.zip"><i class="icon octicon octicon-file-zip"></i> ZIP</a> |
<a class="item" href="{{$.RepoLink}}/archive/{{EscapePound $.BranchName}}.zip"><i class="icon octicon octicon-file-zip"></i> ZIP</a> |
||||||
<a class="item" href="{{$.RepoLink}}/archive/{{EscapePound $.BranchName}}.tar.gz"><i class="icon octicon octicon-file-zip"></i> TAR.GZ</a> |
<a class="item" href="{{$.RepoLink}}/archive/{{EscapePound $.BranchName}}.tar.gz"><i class="icon octicon octicon-file-zip"></i> TAR.GZ</a> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="ui dividing header"> |
<div class="ui dividing header"> |
||||||
{{.title}} |
{{.title}} |
||||||
{{if .IsRepositoryPusher}} |
{{if .IsRepositoryPusher}} |
||||||
<div class="ui right"> |
<div class="ui right"> |
||||||
<a class="ui small button" href="{{.RepoLink}}/wiki/{{.PageURL}}/_edit">{{.i18n.Tr "repo.wiki.edit_page_button"}}</a> |
<a class="ui small button" href="{{.RepoLink}}/wiki/{{.PageURL}}/_edit">{{.i18n.Tr "repo.wiki.edit_page_button"}}</a> |
||||||
<a class="ui green small button" href="{{.RepoLink}}/wiki/_new">{{.i18n.Tr "repo.wiki.new_page_button"}}</a> |
<a class="ui green small button" href="{{.RepoLink}}/wiki/_new">{{.i18n.Tr "repo.wiki.new_page_button"}}</a> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
<div class="ui sub header"> |
<div class="ui sub header"> |
||||||
{{$timeSince := TimeSince .Author.When $.Lang}} |
{{$timeSince := TimeSince .Author.When $.Lang}} |
||||||
{{.i18n.Tr "repo.wiki.last_commit_info" .Author.Name $timeSince | Safe}} |
{{.i18n.Tr "repo.wiki.last_commit_info" .Author.Name $timeSince | Safe}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
<div class="ui segment markdown"> |
<div class="ui segment markdown"> |
||||||
{{.content | Str2html}} |
{{.content | Str2html}} |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,9 +1,9 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="ui container center"> |
<div class="ui container center"> |
||||||
<p style="margin-top: 100px"><img src="{{AppSubUrl}}/img/404.png" alt="404"/></p> |
<p style="margin-top: 100px"><img src="{{AppSubUrl}}/img/404.png" alt="404"/></p> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
<br> |
<br> |
||||||
{{if .ShowFooterVersion}}<p>Application Version: {{AppVer}}</p>{{end}} |
{{if .ShowFooterVersion}}<p>Application Version: {{AppVer}}</p>{{end}} |
||||||
<p>If you think this is an error, please open an issue on <a href="https://github.com/gogits/gogs/issues/new">GitHub</a>.</p> |
<p>If you think this is an error, please open an issue on <a href="https://github.com/gogits/gogs/issues/new">GitHub</a>.</p> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,9 +1,9 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="ui container center"> |
<div class="ui container center"> |
||||||
<p style="margin-top: 100px"><img src="{{AppSubUrl}}/img/500.png" alt="500"/></p> |
<p style="margin-top: 100px"><img src="{{AppSubUrl}}/img/500.png" alt="500"/></p> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
<br> |
<br> |
||||||
{{if .ErrorMsg}}<p>An error has occurred : {{.ErrorMsg}}</p>{{end}} |
{{if .ErrorMsg}}<p>An error has occurred : {{.ErrorMsg}}</p>{{end}} |
||||||
{{if .ShowFooterVersion}}<p>Application Version: {{AppVer}}</p>{{end}} |
{{if .ShowFooterVersion}}<p>Application Version: {{AppVer}}</p>{{end}} |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,38 +1,38 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="user activate"> |
<div class="user activate"> |
||||||
<div class="ui middle very relaxed page grid"> |
<div class="ui middle very relaxed page grid"> |
||||||
<div class="column"> |
<div class="column"> |
||||||
<form class="ui form" action="{{AppSubUrl}}/user/activate" method="post"> |
<form class="ui form" action="{{AppSubUrl}}/user/activate" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<h2 class="ui top attached header"> |
<h2 class="ui top attached header"> |
||||||
{{.i18n.Tr "auth.active_your_account"}} |
{{.i18n.Tr "auth.active_your_account"}} |
||||||
</h2> |
</h2> |
||||||
<div class="ui attached segment"> |
<div class="ui attached segment"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
{{if .IsActivatePage}} |
{{if .IsActivatePage}} |
||||||
{{if .ServiceNotEnabled}} |
{{if .ServiceNotEnabled}} |
||||||
<p class="center">{{.i18n.Tr "auth.disable_register_mail"}}</p> |
<p class="center">{{.i18n.Tr "auth.disable_register_mail"}}</p> |
||||||
{{else if .ResendLimited}} |
{{else if .ResendLimited}} |
||||||
<p class="center">{{.i18n.Tr "auth.resent_limit_prompt"}}</p> |
<p class="center">{{.i18n.Tr "auth.resent_limit_prompt"}}</p> |
||||||
{{else}} |
{{else}} |
||||||
<p>{{.i18n.Tr "auth.confirmation_mail_sent_prompt" .SignedUser.Email .Hours | Str2html}}</p> |
<p>{{.i18n.Tr "auth.confirmation_mail_sent_prompt" .SignedUser.Email .Hours | Str2html}}</p> |
||||||
{{end}} |
{{end}} |
||||||
{{else}} |
{{else}} |
||||||
{{if .IsSendRegisterMail}} |
{{if .IsSendRegisterMail}} |
||||||
<p>{{.i18n.Tr "auth.confirmation_mail_sent_prompt" .Email .Hours | Str2html}}</p> |
<p>{{.i18n.Tr "auth.confirmation_mail_sent_prompt" .Email .Hours | Str2html}}</p> |
||||||
{{else if .IsActivateFailed}} |
{{else if .IsActivateFailed}} |
||||||
<p>{{.i18n.Tr "auth.invalid_code"}}</p> |
<p>{{.i18n.Tr "auth.invalid_code"}}</p> |
||||||
{{else}} |
{{else}} |
||||||
<p>{{.i18n.Tr "auth.has_unconfirmed_mail" .SignedUser.Name .SignedUser.Email | Str2html}}</p> |
<p>{{.i18n.Tr "auth.has_unconfirmed_mail" .SignedUser.Name .SignedUser.Email | Str2html}}</p> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
<div class="text right"> |
<div class="text right"> |
||||||
<button class="ui blue button">{{.i18n.Tr "auth.resend_mail"}}</button> |
<button class="ui blue button">{{.i18n.Tr "auth.resend_mail"}}</button> |
||||||
</div> |
</div> |
||||||
{{end}} |
{{end}} |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</form> |
</form> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,34 +1,34 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="user forgot password"> |
<div class="user forgot password"> |
||||||
<div class="ui middle very relaxed page grid"> |
<div class="ui middle very relaxed page grid"> |
||||||
<div class="column"> |
<div class="column"> |
||||||
<form class="ui form" action="{{.Link}}" method="post"> |
<form class="ui form" action="{{.Link}}" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<h2 class="ui top attached header"> |
<h2 class="ui top attached header"> |
||||||
{{.i18n.Tr "auth.forgot_password"}} |
{{.i18n.Tr "auth.forgot_password"}} |
||||||
</h2> |
</h2> |
||||||
<div class="ui attached segment"> |
<div class="ui attached segment"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
{{if .IsResetSent}} |
{{if .IsResetSent}} |
||||||
<p>{{.i18n.Tr "auth.confirmation_mail_sent_prompt" .Email .Hours | Str2html}}</p> |
<p>{{.i18n.Tr "auth.confirmation_mail_sent_prompt" .Email .Hours | Str2html}}</p> |
||||||
{{else if .IsResetRequest}} |
{{else if .IsResetRequest}} |
||||||
<div class="required inline field {{if .Err_Email}}error{{end}}"> |
<div class="required inline field {{if .Err_Email}}error{{end}}"> |
||||||
<label for="email">{{.i18n.Tr "email"}}</label> |
<label for="email">{{.i18n.Tr "email"}}</label> |
||||||
<input id="email" name="email" type="email" value="{{.Email}}" autofocus required> |
<input id="email" name="email" type="email" value="{{.Email}}" autofocus required> |
||||||
</div> |
</div> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<label></label> |
<label></label> |
||||||
<button class="ui blue button">{{.i18n.Tr "auth.send_reset_mail"}}</button> |
<button class="ui blue button">{{.i18n.Tr "auth.send_reset_mail"}}</button> |
||||||
</div> |
</div> |
||||||
{{else if .IsResetDisable}} |
{{else if .IsResetDisable}} |
||||||
<p class="center">{{.i18n.Tr "auth.disable_register_mail"}}</p> |
<p class="center">{{.i18n.Tr "auth.disable_register_mail"}}</p> |
||||||
{{else if .ResendLimited}} |
{{else if .ResendLimited}} |
||||||
<p class="center">{{.i18n.Tr "auth.resent_limit_prompt"}}</p> |
<p class="center">{{.i18n.Tr "auth.resent_limit_prompt"}}</p> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</form> |
</form> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
@ -1,31 +1,31 @@ |
|||||||
{{template "base/head" .}} |
{{template "base/head" .}} |
||||||
<div class="user reset password"> |
<div class="user reset password"> |
||||||
<div class="ui middle very relaxed page grid"> |
<div class="ui middle very relaxed page grid"> |
||||||
<div class="column"> |
<div class="column"> |
||||||
<form class="ui form" action="{{.Link}}" method="post"> |
<form class="ui form" action="{{.Link}}" method="post"> |
||||||
{{.CsrfTokenHtml}} |
{{.CsrfTokenHtml}} |
||||||
<input name="code" type="hidden" value="{{.Code}}"> |
<input name="code" type="hidden" value="{{.Code}}"> |
||||||
<h2 class="ui top attached header"> |
<h2 class="ui top attached header"> |
||||||
{{.i18n.Tr "auth.reset_password"}} |
{{.i18n.Tr "auth.reset_password"}} |
||||||
</h2> |
</h2> |
||||||
<div class="ui attached segment"> |
<div class="ui attached segment"> |
||||||
{{template "base/alert" .}} |
{{template "base/alert" .}} |
||||||
{{if .IsResetForm}} |
{{if .IsResetForm}} |
||||||
<div class="required inline field {{if .Err_Password}}error{{end}}"> |
<div class="required inline field {{if .Err_Password}}error{{end}}"> |
||||||
<label for="password">{{.i18n.Tr "password"}}</label> |
<label for="password">{{.i18n.Tr "password"}}</label> |
||||||
<input id="password" name="password" type="password" value="{{.password}}" autofocus required> |
<input id="password" name="password" type="password" value="{{.password}}" autofocus required> |
||||||
</div> |
</div> |
||||||
<div class="ui divider"></div> |
<div class="ui divider"></div> |
||||||
<div class="inline field"> |
<div class="inline field"> |
||||||
<label></label> |
<label></label> |
||||||
<button class="ui blue button">{{.i18n.Tr "auth.reset_password_helper"}}</button> |
<button class="ui blue button">{{.i18n.Tr "auth.reset_password_helper"}}</button> |
||||||
</div> |
</div> |
||||||
{{else}} |
{{else}} |
||||||
<p class="center">{{.i18n.Tr "auth.invalid_code"}}</p> |
<p class="center">{{.i18n.Tr "auth.invalid_code"}}</p> |
||||||
{{end}} |
{{end}} |
||||||
</div> |
</div> |
||||||
</form> |
</form> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
</div> |
</div> |
||||||
{{template "base/footer" .}} |
{{template "base/footer" .}} |
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue