Skip to content

Commit

Permalink
Dev: class text-warning for question code error
Browse files Browse the repository at this point in the history
  • Loading branch information
LouisGac committed Jan 7, 2016
1 parent d004706 commit b24b11b
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions scripts/admin/questions.js
Expand Up @@ -11,15 +11,15 @@
*/

// Collapse in editarticle
$(document).ready(function(){
$('#questionTypeContainer').css("overflow","visible");
$('#collapseOne').on('shown.bs.collapse', function () {
$('#questionTypeContainer').css("overflow","visible");
});
$('#collapseOne').on('hide.bs.collapse', function () {
$('#questionTypeContainer').css("overflow","hidden");
});
$(document).ready(function(){
$('#questionTypeContainer').css("overflow","visible");
$('#collapseOne').on('shown.bs.collapse', function () {
$('#questionTypeContainer').css("overflow","visible");
});

$('#collapseOne').on('hide.bs.collapse', function () {
$('#questionTypeContainer').css("overflow","hidden");
});
});
/**
* Validate question object on blur on title element
Expand Down Expand Up @@ -47,7 +47,7 @@ function validateQuestion(jqObject){
if(typeof jqObject=="undefined"){jqObject=$([]);}
$.post(
validateUrl,
{
{
title: $('#frmeditquestion [name="title"]:first').val(),
other: $('#frmeditquestion [name="other"]:checked:first').val(),

Expand Down Expand Up @@ -83,7 +83,7 @@ function validateQuestion(jqObject){
$('#frmeditquestion [type!=hidden][name="'+name+'"]').addClass("has-error");
if(!$('#frmeditquestion [type!=hidden][name="'+name+'"]:last').next('.errorMessage').length)// :last for radio list
{
$("<span class='errorMessage text-error' />").insertAfter('#frmeditquestion [type!=hidden][name="'+name+'"]:last');
$("<span class='errorMessage text-warning' />").insertAfter('#frmeditquestion [type!=hidden][name="'+name+'"]:last');
}
$.each(aError,function(i,error){
if(hasFormValidation)
Expand Down

0 comments on commit b24b11b

Please sign in to comment.