mirror of https://github.com/go-gitea/gitea
Backport #23092 Fix #23082. This bug is caused by a nil context in https://github.com/go-gitea/gitea/issues/23082#issuecomment-1441276546 . Co-authored-by: Zettat123 <zettat123@gmail.com> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>pull/23119/head
parent
5ddf67a9c2
commit
e02e752f68
@ -1,6 +1,6 @@ |
||||
{{if .Attributes.label}} |
||||
<h3>{{.Attributes.label}}{{if .Validations.required}}<label class="required"></label>{{end}}</h3> |
||||
{{if .item.Attributes.label}} |
||||
<h3>{{.item.Attributes.label}}{{if .item.Validations.required}}<label class="required"></label>{{end}}</h3> |
||||
{{end}} |
||||
{{if .Attributes.description}} |
||||
<span class="help">{{RenderMarkdownToHtml .Attributes.description}}</span> |
||||
{{if .item.Attributes.description}} |
||||
<span class="help">{{RenderMarkdownToHtml .Context .item.Attributes.description}}</span> |
||||
{{end}} |
||||
|
@ -1,4 +1,4 @@ |
||||
<div class="field"> |
||||
{{template "repo/issue/fields/header" .}} |
||||
<input type="{{if .Validations.is_number}}number{{else}}text{{end}}" name="form-field-{{.ID}}" placeholder="{{.Attributes.placeholder}}" value="{{.Attributes.value}}" {{if .Validations.required}}required{{end}} {{if .Validations.regex}}pattern="{{.Validations.regex}}" title="{{.Validations.regex}}"{{end}}> |
||||
<input type="{{if .item.Validations.is_number}}number{{else}}text{{end}}" name="form-field-{{.item.ID}}" placeholder="{{.item.Attributes.placeholder}}" value="{{.item.Attributes.value}}" {{if .item.Validations.required}}required{{end}} {{if .item.Validations.regex}}pattern="{{.item.Validations.regex}}" title="{{.item.Validations.regex}}"{{end}}> |
||||
</div> |
||||
|
@ -1,3 +1,3 @@ |
||||
<div class="field"> |
||||
<div>{{RenderMarkdownToHtml .Attributes.value}}</div> |
||||
<div>{{RenderMarkdownToHtml .Context .item.Attributes.value}}</div> |
||||
</div> |
||||
|
Loading…
Reference in new issue