mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-22 18:50:08 +03:00
Bug #2315: Uncheck context on update if context doesn't exist
As a bonus, set memory default on VM template create
This commit is contained in:
parent
15ae2c9fa4
commit
ff9210f95e
@ -4588,6 +4588,9 @@ function fillTemplatePopUp(request, response){
|
||||
var context = template.CONTEXT;
|
||||
var context_section = $('li#contextTab', $create_template_dialog);
|
||||
|
||||
$("#ssh_context", context_section).removeAttr('checked');
|
||||
$("#network_context", context_section).removeAttr('checked');
|
||||
|
||||
if (context) {
|
||||
var file_ds_regexp = /\$FILE\[IMAGE_ID=([0-9]+)+/g;
|
||||
var net_regexp = /^NETWORK$/;;
|
||||
@ -4598,8 +4601,6 @@ function fillTemplatePopUp(request, response){
|
||||
var net_flag = false;
|
||||
var files = [];
|
||||
|
||||
$("#ssh_context", context_section).removeAttr('checked');
|
||||
$("#network_context", context_section).removeAttr('checked');
|
||||
$.each(context, function(key, value){
|
||||
if (ssh_regexp.test(key)) {
|
||||
$("#ssh_context", context_section).attr('checked','checked');
|
||||
|
Loading…
x
Reference in New Issue
Block a user