Browse Source

switch to 255 limit to match db

spalger 5 năm trước cách đây
mục cha
commit
3af560c2d0

+ 2 - 1
backend/schema/endpoints/proxy-hosts.json

@@ -24,7 +24,8 @@
     },
     "forward_host": {
       "type": "string",
-      "minLength": 1
+      "minLength": 1,
+      "maxLength": 255
     },
     "forward_port": {
       "type": "integer",

+ 1 - 1
frontend/js/app/nginx/proxy/form.ejs

@@ -44,7 +44,7 @@
                         <div class="col-sm-5 col-md-5">
                             <div class="form-group">
                                 <label class="form-label"><%- i18n('proxy-hosts', 'forward-host') %><span class="form-required">*</span></label>
-                                <input type="text" name="forward_host" class="form-control text-monospace" placeholder="" value="<%- forward_host %>" autocomplete="off" required>
+                                <input type="text" name="forward_host" class="form-control text-monospace" placeholder="" value="<%- forward_host %>" autocomplete="off" maxlength="255" required>
                             </div>
                         </div>
                         <div class="col-sm-4 col-md-4">