mirror of
https://github.com/aljazceru/btcpayserver.git
synced 2026-02-09 00:04:20 +01:00
Defining input names for validation errors
This commit is contained in:
@@ -34,12 +34,12 @@
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label>Checkout Description</label>
|
||||
<input type="text" class="form-control" placeholder="(optional)"
|
||||
<input name="checkoutDesc" type="text" class="form-control" placeholder="(optional)"
|
||||
v-model="srvModel.checkoutDesc" v-on:change="inputChanges">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label>Order Id</label>
|
||||
<input type="text" class="form-control" id="inputAddress" placeholder="(optional)"
|
||||
<input name="orderId" type="text" class="form-control" id="inputAddress" placeholder="(optional)"
|
||||
v-model="srvModel.orderId" v-on:change="inputChanges">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
@@ -119,7 +119,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="row" v-show="errors.any()">
|
||||
<div class="col-lg-12">
|
||||
<div class="col-lg-12 text-danger">
|
||||
Please fix errors shown in order for code generation to successfully execute.
|
||||
</div>
|
||||
</div>
|
||||
@@ -141,6 +141,15 @@
|
||||
<script type="text/javascript">
|
||||
var srvModel = @Html.Raw(Json.Serialize(Model));
|
||||
Vue.use(VeeValidate);
|
||||
const dictionary = {
|
||||
en: {
|
||||
attributes: {
|
||||
price: 'Price', checkoutDesc: 'Checkout Description', orderId: 'Order Id',
|
||||
serverIpn: 'Server IPN', emailToNotify: 'Send Email Notifications', browserRedirect: 'Browser Redirect'
|
||||
}
|
||||
}
|
||||
};
|
||||
VeeValidate.Validator.localize(dictionary);
|
||||
var payButtonCtrl = new Vue({
|
||||
el: '#payButtonCtrl',
|
||||
data: {
|
||||
@@ -224,7 +233,5 @@
|
||||
return inputChanges().replaceAll("<", "<").replaceAll(">", ">");
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
</script>
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user