Remove the artificial limit of 4000 characters from text areas. Fixes #2877

This commit is contained in:
Murtuza Zabuawala 2017-11-21 11:02:21 +00:00 committed by Dave Page
parent 5b5363e2c4
commit a85538a1fc

View File

@ -273,7 +273,8 @@
_.extend(
Backform.TextareaControl.prototype, {
defaults: _.extend(
Backform.TextareaControl.prototype.defaults, {rows: 5, helpMessage: null}
Backform.TextareaControl.prototype.defaults,
{rows: 5, helpMessage: null, maxlength: null}
),
events : {
"change textarea": "onChange",
@ -287,7 +288,10 @@
'<div class="<%=Backform.controlsClassName%>">',
' <textarea ',
' class="<%=Backform.controlClassName%> <%=extraClasses.join(\' \')%>" name="<%=name%>"',
' maxlength="<%=maxlength%>" placeholder="<%-placeholder%>" <%=disabled ? "disabled" : ""%>',
' <% if (maxlength) { %>',
' maxlength="<%=maxlength%>"',
' <% } %>',
' placeholder="<%-placeholder%>" <%=disabled ? "disabled" : ""%>',
' rows=<%=rows ? rows : ""%>',
' <%=required ? "required" : ""%>><%-value%></textarea>',
' <% if (helpMessage && helpMessage.length) { %>',