text: S3.dc_question_types=function(e,f){var a;if("2"==e){options_field=$("#dc_question_options");options_field.hasClass("tagit-hidden-field")&&options_field.tagit("destroy");$("#dc_question_options__row").hide();if(f){var c=$("#dc_question_totals");if(e=c.val()){var d=JSON.parse(e);var b="";for(a in d)d.hasOwnProperty(a)&&(""!=b&&(b+=","),b+=d[a]);c.val(b)}}$("#dc_question_totals__row").show()}else if("6"==e){$("#dc_question_totals__row").hide();if(f&&(e=c.val())){d=JSON.parse(e);b="";for(a in d)d.hasOwnProperty(a)&&
  (""!=b&&(b+=","),b+=d[a]);$("#dc_question_options").val(b)}$textarea=$("#dc_question_options");c=$("<input></input>").attr({id:$textarea.prop("id"),name:$textarea.prop("name"),value:$textarea.val()});$textarea.after(c).remove();$("#dc_question_options__row").show();$("#dc_question_options").tagit()}else $("#dc_question_totals__row").hide(),options_field=$("#dc_question_options"),options_field.hasClass("tagit-hidden-field")&&options_field.tagit("destroy"),$("#dc_question_options__row").hide();if(f&&
  "9"!=e&&(c=$("#dc_question_grid"),e=c.val())){d=JSON.parse(e);b="";for(a in d)d.hasOwnProperty(a)&&(""!=b&&(b+=","),b+=d[a]);c.val(b)}};
  $(document).ready(function(){var e=$("#dc_question_field_type");S3.dc_question_types(e.val(),!0);e.change(function(){S3.dc_question_types($(this).val(),!1)});$("form").submit(function(){S3ClearNavigateAwayConfirm();var f=e.val();if("2"==f){var a=$("#dc_question_totals");var c=[];var d=a.val();var b=d.split(",");$(b).each(function(a){c.push(b[a])});a.val(JSON.stringify(c))}else"6"==f&&(a=$("#dc_question_options"),c={},d=a.val(),b=d.split(","),$(b).each(function(a){c[a+1]=b[a]}),a.val(JSON.stringify(c)));
  "9"!=f&&(a=$("#dc_question_grid"),c=[],d=a.val(),b=d.split(","),$(b).each(function(a){c.push(b[a])}),a.val(JSON.stringify(c)));return!0})});
  