mirror of
https://github.com/jenkinsci/jenkins.git
synced 2026-11-16 21:42:27 +00:00
Make preview feature more generic
- previewEndpoint attribute is used to obtain formatted html
This commit is contained in:
1 parent
9412373852
commit
b4ad3fbfea
10 files changed
+23
-22
No files matched your search
@@ -103,9 +103,9 @@ public abstract class MarkupFormatter extends AbstractDescribableImpl<MarkupForm
|
||||
* Generate HTML for preview, using markup formatter.
|
||||
* Can be called from other views.
|
||||
*/
|
||||
public HttpResponse doPreviewDescription(@QueryParameter String description) throws IOException {
|
||||
public HttpResponse doPreviewDescription(@QueryParameter String text) throws IOException {
|
||||
StringWriter w = new StringWriter();
|
||||
translate(description, w);
|
||||
translate(text, w);
|
||||
return HttpResponses.html(w.toString());
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user