allows hostname instead of ip for streams

This commit is contained in:
Björn Heinrichs
2021-04-24 01:09:01 +02:00
parent 1a64d44857
commit 389fd158ad
10 changed files with 60 additions and 21 deletions

View File

@ -14,8 +14,8 @@
</div>
<div class="col-sm-8 col-md-8">
<div class="form-group">
<label class="form-label"><%- i18n('streams', 'forward-ip') %><span class="form-required">*</span></label>
<input type="text" name="forward_ip" class="form-control text-monospace" placeholder="000.000.000.000" value="<%- forward_ip %>" autocomplete="off" maxlength="15" required>
<label class="form-label"><%- i18n('streams', 'forwarding-host') %><span class="form-required">*</span></label>
<input type="text" name="forwarding_host" class="form-control text-monospace" value="<%- forwarding_host %>" autocomplete="off" required>
</div>
</div>
<div class="col-sm-4 col-md-4">

View File

@ -13,7 +13,7 @@ module.exports = Mn.View.extend({
ui: {
form: 'form',
forward_ip: 'input[name="forward_ip"]',
forwarding_host: 'input[name="forwarding_host"]',
type_error: '.forward-type-error',
buttons: '.modal-footer button',
switches: '.custom-switch-input',
@ -77,10 +77,6 @@ module.exports = Mn.View.extend({
},
onRender: function () {
this.ui.forward_ip.mask('099.099.099.099', {
clearIfNotMatch: true,
placeholder: '000.000.000.000'
});
},
initialize: function (options) {

View File

@ -12,7 +12,7 @@
</div>
</td>
<td>
<div class="text-monospace"><%- forward_ip %>:<%- forwarding_port %></div>
<div class="text-monospace"><%- forwarding_host %>:<%- forwarding_port %></div>
</td>
<td>
<div>