1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-22 18:50:08 +03:00

Fix user inputs for new flow service instance

This commit is contained in:
Carlos Martín 2016-04-27 15:09:58 +02:00
parent 39086ca46f
commit ea81a63d5f
3 changed files with 6 additions and 2 deletions

View File

@ -26,7 +26,7 @@
<label for="service_n_times">{{tr "Number of instances"}}
<span class="tip">{{tr "Number of Services that will be created using this template"}}.</span>
</label>
<input type="text" name="service_n_times" id="service_n_times" value="1">
<input type="number" min="1" name="service_n_times" id="service_n_times" value="1">
</div>
</div>
<div id="instantiate_service_user_inputs">

View File

@ -50,7 +50,7 @@
{{tr "Number of Virtual Machines that will be created using this template"}}.
</span>
</label>
<input type="number" name="vm_n_times" id="vm_n_times" value="1">
<input type="number" name="vm_n_times" id="vm_n_times" value="1" min="1">
<input type="number" name="vm_n_times_disabled" id="vm_n_times_disabled" value="1" disabled>
</div>
<div class="medium-4 columns">

View File

@ -184,6 +184,10 @@ define(function(require) {
// opts.network_header: header text for the network inputs
// returns true if at least one input was inserted
function _generateServiceTemplateUserInputs(div, template_json, opts) {
if(opts == undefined){
opts = {};
}
opts.div = div;
opts.user_inputs = template_json.DOCUMENT.TEMPLATE.BODY.custom_attrs;