Commit b08e0b0f authored by Mathieu Giraud's avatar Mathieu Giraud

js/model.js: show NORM_{EXPECTED,EXTERNAL} buttons only where needed

Closes #3661.
parent f0fdb02a
...@@ -274,6 +274,8 @@ Model.prototype = { ...@@ -274,6 +274,8 @@ Model.prototype = {
initClones: function () { initClones: function () {
console.log("initClones()"); console.log("initClones()");
var have_external_normalization = false var have_external_normalization = false
$("#external_normalization").hide();
$("#expected_normalization").hide();
// time_type to name_short if there is many samples // time_type to name_short if there is many samples
if (this.samples.order.length > 6) if (this.samples.order.length > 6)
...@@ -312,6 +314,7 @@ Model.prototype = { ...@@ -312,6 +314,7 @@ Model.prototype = {
var radio = document.getElementById("external_normalization_input") var radio = document.getElementById("external_normalization_input")
if (radio != undefined) { if (radio != undefined) {
radio.checked = true; radio.checked = true;
$("#external_normalization").show();
} }
} }
}, //end initClones }, //end initClones
...@@ -1998,6 +2001,7 @@ changeAlleleNotation: function(alleleNotation) { ...@@ -1998,6 +2001,7 @@ changeAlleleNotation: function(alleleNotation) {
if (size>0 && size<1){ if (size>0 && size<1){
self.set_normalization( self.NORM_EXPECTED ) self.set_normalization( self.NORM_EXPECTED )
$("#expected_normalization").show();
self.norm_input.value = "" self.norm_input.value = ""
self.clone(cloneID).expected=size; self.clone(cloneID).expected=size;
self.compute_normalization(cloneID, size) self.compute_normalization(cloneID, size)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment