GCAT5.0 released

This commit is contained in:
Minh
2015-04-10 15:12:45 -05:00
commit 67544a10e6
257 changed files with 61661 additions and 0 deletions
@@ -0,0 +1,34 @@
/*
* Copyright 2012 The Board of Regents of the University of Wisconsin System.
* Contributors: Jason Shao, James McCurdy, Enhai Xie, Adam G.W. Halstead,
* Michael H. Whitney, Nathan DiPiazza, Trey K. Sato and Yury V. Bukhman
*
* This file is part of GCAT.
*
* GCAT is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* GCAT is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with GCAT. If not, see <http://www.gnu.org/licenses/>.
*/
// This is a manifest file that'll be compiled into including all the files listed below.
// Add new JavaScript/Coffee code in separate files in this directory and they'll automatically
// be included in the compiled file accessible from http://example.com/assets/application.js
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
// the compiled file.
//
//= require jquery
//= require jquery_ujs
//= require yuiloader-min
//= require datatable-min
//= require jquery.loader-min
//= require_tree .
//= require bootstrap.min
+76
View File
@@ -0,0 +1,76 @@
/*
* Copyright 2012 The Board of Regents of the University of Wisconsin System.
* Contributors: Jason Shao, James McCurdy, Enhai Xie, Adam G.W. Halstead,
* Michael H. Whitney, Nathan DiPiazza, Trey K. Sato and Yury V. Bukhman
*
* This file is part of GCAT.
*
* GCAT is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* GCAT is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with GCAT. If not, see <http://www.gnu.org/licenses/>.
*/
$(document).ready(function(){
// Three blocks below for hiding the optional user input fields.
$(".user_enter1").on("change", function(){
$(".optional_input1").toggle($(this).hasClass("user_enter1_yes"));
});
$(".user_enter2").on("change", function(){
$(".optional_input2").toggle($(this).hasClass("user_enter2_yes"));
});
$(".user_enter3").on("change", function(){
$(".optional_input3").toggle($(this).hasClass("user_enter3_yes"));
});
// handle error redirect & browser back cases//////////////////////////////////////////
/****************************************************
* This function checks the radio box for the
* corresponding optional div with input field.
* If checked show else hide
* @return void
****************************************************/
function reset_optional_fields(radio, optional_box){
if(radio && optional_box){
var radio_ckd = radio.prop('checked');
if(radio_ckd){
optional_box.show();
}
else {
optional_box.hide();
}
} else{
console.error("Error: unknown selector in reset_optional_fields()");
}
}
reset_optional_fields($('#assay_plate_type_m'), $("#time"));
reset_optional_fields($("input#assay_blank_value_user"), $("div.optional_input3"));
reset_optional_fields($("input#assay_transformation_-1"), $("div.optional_input2"));
reset_optional_fields($("input#assay_model_-1"), $("div.optional_input1"));
//////////////////////////////////////////////////////////////////////////////////////
$('#new_assay').submit(function() {
$.loader();
});
$("input[name$='assay[plate_type]']").click(function(){
var value = $(this).val();
if(value=='s') {
$("#time").hide();
}
else if(value=='m') {
$("#time").show();
}
});
});