Commit e6414617 by Kim Gyeongeun

#56952 設問設定機能追加(アンケート区分別、グレーアウトが効かない問題修正)

#56950 アンケートの設問コピー機能(条件付必須項目がコピーされない問題修正)
parent bce18cc5
......@@ -96,7 +96,7 @@ public class QuestionService extends AbstractService<Question> {
}
public List<Question> findAllByEnqueteId(Integer eid) {
return select().where(new SimpleWhere().eq("enqueteId",eid).eq("delFlg", SinaburoConstant.DelFlg.NOT_DEL)).getResultList();
return select().where(new SimpleWhere().eq("enqueteId",eid).eq("delFlg", SinaburoConstant.DelFlg.NOT_DEL)).orderBy("questionId").getResultList();
}
......@@ -276,18 +276,40 @@ public class QuestionService extends AbstractService<Question> {
List<Question> questionList = findAllByEnqueteId(originEnqueteId);
// アンケートに設問がない場合
if (CollectionUtils.isEmpty(questionList)) {return;}
HashMap<Integer, Integer> questionIdMap = new HashMap<Integer, Integer>();
HashMap<String, String> answerIdStrMap = new HashMap<String, String>();
Integer originQuestionId;
Integer originAnswerId;
for (Question question : questionList) {
originQuestionId = question.questionId;
question.enqueteId = newEnqueteId;
question.version = 0;
// 詳細項目情報取得
List<Answer> answerList = answerService.findAllByEnqueteId(originEnqueteId, question.questionId);
List<Answer> answerList = answerService.findAllByEnqueteId(originEnqueteId, originQuestionId);
insertQuestion(question, loginId);
questionIdMap.put(originQuestionId, question.questionId);
for (Answer answer : answerList) {
originAnswerId = answer.answerId;
answer.enqueteId = newEnqueteId;
// 新しいquestionIdをセット
answer.questionId = question.questionId;
answer.version = 0;
answerService.insertAnswer(answer, loginId);
answerIdStrMap.put(String.valueOf(originAnswerId), String.valueOf(answer.answerId));
}
}
// 条件付必須情報コピー
List<Question> copiedQuestionList = findAllByEnqueteId(newEnqueteId);
String answerIdArrayStr = "";
for (Question copiedQuestion : copiedQuestionList) {
if (copiedQuestion.condRequiredQuestionNo != null && !copiedQuestion.condRequiredQuestionNo.equals(0)) {
copiedQuestion.condRequiredQuestionNo = questionIdMap.get(copiedQuestion.condRequiredQuestionNo);
for (String answerIdStr : copiedQuestion.condRequiredAnswer.split(",")) {
answerIdArrayStr += answerIdStrMap.get(answerIdStr) + ",";
}
copiedQuestion.condRequiredAnswer = answerIdArrayStr.replaceAll(",$", "");
update(copiedQuestion, loginId);
answerIdArrayStr = "";
}
}
}
......
#set($title = "アンケート")
<script type="text/javascript" src="/em/js/jquery-1.3.1.min.js"></script>
#foreach($question in $!enqueteForm.questionList)
#foreach($answer in $question.answerList)
<script language="javascript" type="text/javascript" charset="utf-8">
<!--
$(function() {
//条件付必須チェック
$("input[type=radio], input[type=checkbox], input[type=select]").click(function () {
var thisQuestionId = $(this).attr("class");
var thisAnswerId = $(this).attr("id");
//表示、非表示対象
if (${question.condRequiredQuestionNo} && ${question.condRequiredQuestionNo} == thisQuestionId) {
if ("${question.condRequiredAnswer}".split(",").indexOf(thisAnswerId) < 0) {
if ("${question.controlId}" == "0" || "${question.controlId}" == "1") {
$("#${answer.answerId}").attr("checked", false);
$("#${answer.answerId}").attr("disabled", true);
} else if ("${question.controlId}" == "2" || "${question.controlId}" == "3" || "${question.controlId}" == "4" || "${question.controlId}" == "6") {
$("#${question.questionId}").val("");
$("#${question.questionId}").attr("disabled", true);
} else if ("${question.controlId}" == "5") {
$(".${question.questionId}").val("");
$(".${question.questionId}").attr("disabled", true);
$(".${question.questionId}").next().hide();
}
} else {
if ("${question.controlId}" == "0" || "${question.controlId}" == "1") {
$("#${answer.answerId}").attr("disabled", false);
} else if ("${question.controlId}" == "2" || "${question.controlId}" == "3" || "${question.controlId}" == "4" || "${question.controlId}" == "6") {
$("#${question.questionId}").attr("disabled", false);
} else if ("${question.controlId}" == "5") {
$(".${question.questionId}").attr("disabled", false);
$(".${question.questionId}").next().show();
}
}
}
});
});
// -->
</script>
#end
#end
<!-- preHeader -->
#parse( "/WEB-INF/view/common/preHeader_mb.vm" )
<body style="font-family: monospace; width: 240px; border: 2px solid black;">
......
#set($title = "アンケート")
<script type="text/javascript" src="/em/js/jquery-1.3.1.min.js"></script>
#foreach($question in $!enqueteForm.questionList)
#foreach($answer in $question.answerList)
<script language="javascript" type="text/javascript" charset="utf-8">
<!--
$(function() {
//条件付必須チェック
$("input[type=radio], input[type=checkbox], input[type=select]").click(function () {
var thisQuestionId = $(this).attr("class");
var thisAnswerId = $(this).attr("id");
//表示、非表示対象
if (${question.condRequiredQuestionNo} && ${question.condRequiredQuestionNo} == thisQuestionId) {
if ("${question.condRequiredAnswer}".split(",").indexOf(thisAnswerId) < 0) {
if ("${question.controlId}" == "0" || "${question.controlId}" == "1") {
$("#${answer.answerId}").attr("checked", false);
$("#${answer.answerId}").attr("disabled", true);
} else if ("${question.controlId}" == "2" || "${question.controlId}" == "3" || "${question.controlId}" == "4" || "${question.controlId}" == "6") {
$("#${question.questionId}").val("");
$("#${question.questionId}").attr("disabled", true);
} else if ("${question.controlId}" == "5") {
$(".${question.questionId}").val("");
$(".${question.questionId}").attr("disabled", true);
$(".${question.questionId}").next().hide();
}
} else {
if ("${question.controlId}" == "0" || "${question.controlId}" == "1") {
$("#${answer.answerId}").attr("disabled", false);
} else if ("${question.controlId}" == "2" || "${question.controlId}" == "3" || "${question.controlId}" == "4" || "${question.controlId}" == "6") {
$("#${question.questionId}").attr("disabled", false);
} else if ("${question.controlId}" == "5") {
$(".${question.questionId}").attr("disabled", false);
$(".${question.questionId}").next().show();
}
}
}
});
});
// -->
</script>
#end
#end
<!-- preHeader -->
#parse( "/WEB-INF/view/common/preHeader_mb.vm" )
<body style="font-family: monospace; width: 240px; border: 2px solid black;">
......
#set($title = "アンケート回答")
<script type="text/javascript" src="/em/js/jquery-1.3.1.min.js"></script>
<script language="javascript" type="text/javascript" charset="utf-8">
<!--
window.onload = function () {
$("input[type=text], input[type=date], textArea[type=text]").each(function(){
if ($(this).prop("disabled")) {
$(this).val("");
$(this).textinput().textinput("disable");
if ($(this).prop("type") == "date") {
$(this).next().hide();
}
}
});
}
// -->
</script>
#foreach($question in $!enqueteForm.questionList)
#foreach($answer in $question.answerList)
<script language="javascript" type="text/javascript" charset="utf-8">
<!--
$(function() {
//条件付必須チェック
$("input[type=radio], input[type=checkbox], input[type=select]").click(function () {
var idArray = $(this).attr("class").split(" ");
var thisQuestionId = idArray[0];
var thisAnswerId = idArray[1];
//表示、非表示対象
if (${question.condRequiredQuestionNo} && ${question.condRequiredQuestionNo} == thisQuestionId) {
var key;
if ("${question.condRequiredAnswer}".split(",").indexOf(thisAnswerId) < 0) {
if ("${question.controlId}" == "0" || "${question.controlId}" == "1") {
key = "${answer.answerId}";
$("." + key).prop("checked", false);
$("." + key).checkboxradio('refresh').checkboxradio('disable');
} else if ("${question.controlId}" == "2" || ${question.controlId} == "6") {
key = "${question.questionId}";
$("." + key).val("");
$("." + key).selectmenu("refresh").selectmenu("disable");
} else if ("${question.controlId}" == "3" || "${question.controlId}" == "4") {
key = "${question.questionId}";
$("." + key).val("");
$("." + key).textinput("disable");
} else if ("${question.controlId}" == "5") {
key = "${question.questionId}";
$("." + key).val("");
$("." + key).textinput("disable");
$("." + key).next().hide();
}
} else {
if ("${question.controlId}" == "0" || "${question.controlId}" == "1") {
key = "${answer.answerId}";
$("." + key).checkboxradio('enable');
} else if ("${question.controlId}" == "2" || "${question.controlId}" == "6") {
key = "${question.questionId}";
$("." + key).selectmenu("enable");
} else if ("${question.controlId}" == "3" || "${question.controlId}" == "4") {
key = "${question.questionId}";
$("." + key).textinput("enable");
} else if ("${question.controlId}" == "5") {
key = "${question.questionId}";
$("." + key).textinput("enable");
$("." + key).next().show();
}
}
}
});
});
// -->
</script>
#end
#end
<!-- preHeader -->
#set($ajaxdisable = "1")
#parse( "/WEB-INF/view/common/preHeader_sp.vm" )
......
#set($title = "アンケート回答")
<script type="text/javascript" src="/em/js/jquery-1.3.1.min.js"></script>
<script language="javascript" type="text/javascript" charset="utf-8">
<!--
window.onload = function () {
$("input[type=text], input[type=date], textArea[type=text]").each(function(){
if ($(this).prop("disabled")) {
$(this).val("");
$(this).textinput().textinput("disable");
if ($(this).prop("type") == "date") {
$(this).next().hide();
}
}
});
}
// -->
</script>
#foreach($question in $!enqueteForm.questionList)
#foreach($answer in $question.answerList)
<script language="javascript" type="text/javascript" charset="utf-8">
<!--
$(function() {
//条件付必須チェック
$("input[type=radio], input[type=checkbox], input[type=select]").click(function () {
var idArray = $(this).attr("class").split(" ");
var thisQuestionId = idArray[0];
var thisAnswerId = idArray[1];
//表示、非表示対象
if (${question.condRequiredQuestionNo} && ${question.condRequiredQuestionNo} == thisQuestionId) {
var key;
if ("${question.condRequiredAnswer}".split(",").indexOf(thisAnswerId) < 0) {
if ("${question.controlId}" == "0" || "${question.controlId}" == "1") {
key = "${answer.answerId}";
$("." + key).prop("checked", false);
$("." + key).checkboxradio('refresh').checkboxradio('disable');
} else if ("${question.controlId}" == "2" || ${question.controlId} == "6") {
key = "${question.questionId}";
$("." + key).val("");
$("." + key).selectmenu("refresh").selectmenu("disable");
} else if ("${question.controlId}" == "3" || "${question.controlId}" == "4") {
key = "${question.questionId}";
$("." + key).val("");
$("." + key).textinput("disable");
} else if ("${question.controlId}" == "5") {
key = "${question.questionId}";
$("." + key).val("");
$("." + key).textinput("disable");
$("." + key).next().hide();
}
} else {
if ("${question.controlId}" == "0" || "${question.controlId}" == "1") {
key = "${answer.answerId}";
$("." + key).checkboxradio('enable');
} else if ("${question.controlId}" == "2" || "${question.controlId}" == "6") {
key = "${question.questionId}";
$("." + key).selectmenu("enable");
} else if ("${question.controlId}" == "3" || "${question.controlId}" == "4") {
key = "${question.questionId}";
$("." + key).textinput("enable");
} else if ("${question.controlId}" == "5") {
key = "${question.questionId}";
$("." + key).textinput("enable");
$("." + key).next().show();
}
}
}
});
});
// -->
</script>
#end
#end
<!-- preHeader -->
#set($ajaxdisable = "1")
#parse( "/WEB-INF/view/common/preHeader_sp.vm" )
......
......@@ -28,6 +28,46 @@
#end
#end
</head>
#foreach($question in $!enqueteForm.questionList)
#foreach($answer in $question.answerList)
<script language="javascript" type="text/javascript" charset="utf-8">
<!--
$(function() {
//条件付必須チェック
$("input[type=radio], input[type=checkbox], input[type=select]").click(function () {
var thisQuestionId = $(this).attr("class");
var thisAnswerId = $(this).attr("id");
//表示、非表示対象
if (${question.condRequiredQuestionNo} && ${question.condRequiredQuestionNo} == thisQuestionId) {
if ("${question.condRequiredAnswer}".split(",").indexOf(thisAnswerId) < 0) {
if ("${question.controlId}" == "0" || "${question.controlId}" == "1") {
$("#${answer.answerId}").attr("checked", false);
$("#${answer.answerId}").attr("disabled", true);
} else if ("${question.controlId}" == "2" || "${question.controlId}" == "3" || "${question.controlId}" == "4" || "${question.controlId}" == "6") {
$("#${question.questionId}").val('');
$("#${question.questionId}").attr("disabled", true);
} else if ("${question.controlId}" == "5") {
$(".${question.questionId}").val('');
$(".${question.questionId}").attr("disabled", true);
$(".${question.questionId}").next().hide();
}
} else {
if ("${question.controlId}" == "0" || "${question.controlId}" == "1") {
$("#${answer.answerId}").attr("disabled", false);
} else if ("${question.controlId}" == "2" || "${question.controlId}" == "3" || "${question.controlId}" == "4" || "${question.controlId}" == "6") {
$("#${question.questionId}").attr("disabled", false);
} else if ("${question.controlId}" == "5") {
$(".${question.questionId}").attr("disabled", false);
$(".${question.questionId}").next().show();
}
}
}
});
});
// -->
</script>
#end
#end
<body>
<div id="wrapper">
<div id="logo"><img src="/em/images/ichikawa_logo01.jpg" width="190" height="65" />
......@@ -112,7 +152,7 @@
#if($!question.controlId == "2")
<td align="left" width="$tdWidthPercent%" valign = "top" >
#set($answerIdValueName = "questionList[$questionIndex].answerList[0].answerIdValue")
<select name="$answerIdValueName">
<select name="$answerIdValueName" id="#he($!question.questionId)" #if($!question.questionInitDisable == "1") disabled #end>
#foreach($selectAnswer in $question.answerList)
<option value="$!selectAnswer.answerId" #if($enqueteForm.initCount =="2" && $!selectAnswer.answerId == $!selectAnswer.answerIdValue) selected #elseif($!selectAnswer.defaultFlg == "1" && $enqueteForm.initCount!="2") selected #end >$!escape.html($!selectAnswer.answer)</option>
<!-- <option value="$!selectAnswer.answerId" #if($enqueteForm.initCount =="2" && $!selectAnswer.answerId == $!selectAnswer.answerIdValue) selected $!selectAnswer.answerId , $!selectAnswer.answerIdValue #elseif($!selectAnswer.defaultFlg == "1" ) selected $!selectAnswer.answerId , $!selectAnswer.answerIdValue #end >$!escape.html($!selectAnswer.answer)</option> -->
......@@ -142,41 +182,41 @@
<!-- 0:RADIO インデクスを値にする。 -->
#if($!question.controlId == "0")
##if($!answer.freeTextFlg != "1" && $!answer.freeTextFlg != "2")
<input type="radio" name="$!answerIdValueRadioName" value="$velocityCount" #if($!answer.answerIdValue == $velocityCount.toString() && $enqueteForm.initCount =="2") checked #{end}
<input type="radio" class="#he($!question.questionId)" id="#he($!answer.answerId)" name="$!answerIdValueRadioName" value="$velocityCount" #if($!answer.answerIdValue == $velocityCount.toString() && $enqueteForm.initCount =="2") checked #{end}
#if($!answer.defaultFlg == 1 && $enqueteForm.initCount =="1") checked #end
> $!escape.html($!answer.answer)
#if($!question.questionInitDisable == "1") disabled #end> $!escape.html($!answer.answer)
##end
##<!-- 自由入力欄。freeTextFlg=1(あり)、2(必須) -->
#if($!answer.freeTextFlg == "1" || $!answer.freeTextFlg == "2")
<input type="text" name="$answerValue" size="$!answer.freeTextColWidth" value="$!escape.html($!answer.answerValue)" />
<input type="text" class="#he($!question.questionId)" id="#he($!answer.answerId)" name="$answerValue" size="$!answer.freeTextColWidth" value="$!escape.html($!answer.answerValue)" />
#end
##<!-- 1:CHECKBOX answer.answerNo値を値にする。-->
#elseif($!question.controlId == "1")
##if($!answer.freeTextFlg != "1" && $!answer.freeTextFlg != "2")
<input type="checkbox" name="$answerIdValueName" value="$!escape.html($!answer.answerNo)" #if($answer.answerIdValue != "" && $enqueteForm.initCount =="2") checked #end
<input type="checkbox" class="#he($!question.questionId)" id="#he($!answer.answerId)" name="$answerIdValueName" value="$!escape.html($!answer.answerNo)" #if($answer.answerIdValue != "" && $enqueteForm.initCount =="2") checked #end
#if($!answer.defaultFlg == 1 && $enqueteForm.initCount =="1") checked #end
> $!escape.html($!answer.answer)
#if($!question.questionInitDisable == "1") disabled #end> $!escape.html($!answer.answer)
##end
##<!-- 自由入力欄。freeTextFlg=1(あり)、2(必須) -->
#if($!answer.freeTextFlg == "1" || $!answer.freeTextFlg == "2")
<input type="text" name="$answerValue" size="$!answer.freeTextColWidth" value="$!escape.html($!answer.answerValue)"/>
<input type="text" class="#he($!question.questionId)" id="#he($!answer.answerId)" name="$answerValue" size="$!answer.freeTextColWidth" value="$!escape.html($!answer.answerValue)" #if($!question.questionInitDisable == "1") disabled #end />
#end
##<!-- 3:TEXTAREA ユーザー入力値を値にする。-->
#elseif($!question.controlId == "3")
<textArea type="text" name="$answerIdValueName" cols="$!question.dispWitdth" rows="$!question.rowCount">$!answer.answerIdValue</textarea>
<textArea type="text" id="#he($!question.questionId)" name="$answerIdValueName" cols="$!question.dispWitdth" rows="$!question.rowCount" #if($!question.questionInitDisable == "1") disabled #end>$!answer.answerIdValue</textarea>
##<!-- 4:TEXTFIELD ユーザー入力値を値にする。-->
#elseif($!question.controlId == "4")
<input type="text" name="$answerIdValueName" value="$!escape.html($!answer.answerIdValue)" size="$!question.dispWitdth"/>
<input type="text" id="#he($!question.questionId)" name="$answerIdValueName" value="$!escape.html($!answer.answerIdValue)" size="$!question.dispWitdth" #if($!question.questionInitDisable == "1") disabled #end/>
##<!-- 5:日付入力 ユーザー入力値を値にする。-->
#elseif($!question.controlId == "5")
#set($dateIndex = $dateIndex+1)
<input name="$answerValue" id="enqStartFrom${dateIndex}" type="text" class="w100 mgl10" value="$!escape.html($!answer.answerValue)" >
<div style="display: none;"><img id="enqFrom${dateIndex}" src="/em/images/icon_cal.gif" style="padding-left:5px;padding-right:5px; vertical-align: middle;"></div>
<input name="$answerValue" id="enqStartFrom${dateIndex}" type="text" class="w100 mgl10 #he($!question.questionId)" value="$!escape.html($!answer.answerValue)" #if($!question.questionInitDisable == "1") disabled #end>
<div style="display: none;"><img id="enqFrom${dateIndex}" src="/em/images/icon_cal.gif" style="padding-left:5px;padding-right:5px; vertical-align: middle;" #if($!question.questionInitDisable == '1') display: none; #end"></div>
<input type="hidden" name="$answerIdValueName" value="$!answer.answerId" />
#elseif($!question.controlId == "6")
<select name="$answerIdValueName" >
<select name="$answerIdValueName" id="#he($!question.questionId)" #if($!question.questionInitDisable == "1") disabled #end>
#foreach($pecent1 in $enqueteForm.organizationListFor1Percent)
<option value="$!pecent1.organizationId" #if($!percentOrganizationId == $!pecent1.organizationId) selected #end>$!{pecent1.organizationNo} : $!escape.html($!{pecent1.organizationName})</option>
#end
......
......@@ -26,7 +26,46 @@
#end
#end
</head>
#foreach($question in $!enqueteForm.questionList)
#foreach($answer in $question.answerList)
<script language="javascript" type="text/javascript" charset="utf-8">
<!--
$(function() {
//条件付必須チェック
$("input[type=radio], input[type=checkbox], input[type=select]").click(function () {
var thisQuestionId = $(this).attr("class");
var thisAnswerId = $(this).attr("id");
//表示、非表示対象
if (${question.condRequiredQuestionNo} && ${question.condRequiredQuestionNo} == thisQuestionId) {
if ("${question.condRequiredAnswer}".split(",").indexOf(thisAnswerId) < 0) {
if ("${question.controlId}" == "0" || "${question.controlId}" == "1") {
$("#${answer.answerId}").attr("checked", false);
$("#${answer.answerId}").attr("disabled", true);
} else if ("${question.controlId}" == "2" || "${question.controlId}" == "3" || "${question.controlId}" == "4" || "${question.controlId}" == "6") {
$("#${question.questionId}").val('');
$("#${question.questionId}").attr("disabled", true);
} else if ("${question.controlId}" == "5") {
$(".${question.questionId}").val('');
$(".${question.questionId}").attr("disabled", true);
$(".${question.questionId}").next().hide();
}
} else {
if ("${question.controlId}" == "0" || "${question.controlId}" == "1") {
$("#${answer.answerId}").attr("disabled", false);
} else if ("${question.controlId}" == "2" || "${question.controlId}" == "3" || "${question.controlId}" == "4" || "${question.controlId}" == "6") {
$("#${question.questionId}").attr("disabled", false);
} else if ("${question.controlId}" == "5") {
$(".${question.questionId}").attr("disabled", false);
$(".${question.questionId}").next().show();
}
}
}
});
});
// -->
</script>
#end
#end
<body>
<div id="wrapper">
......@@ -120,7 +159,7 @@ $!enqueteForm.enquete.header
#if($!question.controlId == "2")
<td align="left" width="$tdWidthPercent%" valign = "top" >
#set($answerIdValueName = "questionList[$questionIndex].answerList[0].answerIdValue")
<select name="$answerIdValueName">
<select name="$answerIdValueName" id="#he($!question.questionId)" #if($!question.questionInitDisable == "1") disabled #end>
#foreach($selectAnswer in $question.answerList)
<option value="$!selectAnswer.answerId" #if($enqueteForm.initCount =="2" && $!selectAnswer.answerId == $!selectAnswer.answerIdValue) selected #elseif($!selectAnswer.defaultFlg == "1" && $enqueteForm.initCount!="2") selected #end >$!escape.html($!selectAnswer.answer)</option>
<!-- <option value="$!selectAnswer.answerId" #if($enqueteForm.initCount =="2" && $!selectAnswer.answerId == $!selectAnswer.answerIdValue) selected $!selectAnswer.answerId , $!selectAnswer.answerIdValue #elseif($!selectAnswer.defaultFlg == "1" ) selected $!selectAnswer.answerId , $!selectAnswer.answerIdValue #end >$!escape.html($!selectAnswer.answer)</option> -->
......@@ -150,41 +189,41 @@ $!enqueteForm.enquete.header
<!-- 0:RADIO インデクスを値にする。 -->
#if($!question.controlId == "0")
##if($!answer.freeTextFlg != "1" && $!answer.freeTextFlg != "2")
<input type="radio" name="$!answerIdValueRadioName" value="$velocityCount" #if($!answer.answerIdValue == $velocityCount.toString() && $enqueteForm.initCount =="2") checked #{end}
<input type="radio" class="#he($!question.questionId)" id="#he($!answer.answerId)" name="$!answerIdValueRadioName" value="$velocityCount" #if($!answer.answerIdValue == $velocityCount.toString() && $enqueteForm.initCount =="2") checked #{end}
#if($!answer.defaultFlg == 1 && $enqueteForm.initCount =="1") checked #end
> $!escape.html($!answer.answer)
##end
##<!-- 自由入力欄。freeTextFlg=1(あり)、2(必須) -->
#if($!answer.freeTextFlg == "1" || $!answer.freeTextFlg == "2")
<input type="text" name="$answerValue" size="$!answer.freeTextColWidth" value="$!escape.html($!answer.answerValue)" />
<input type="text" class="#he($!question.questionId)" id="#he($!answer.answerId)" name="$answerValue" size="$!answer.freeTextColWidth" value="$!escape.html($!answer.answerValue)" />
#end
##<!-- 1:CHECKBOX answer.answerNo値を値にする。-->
#elseif($!question.controlId == "1")
##if($!answer.freeTextFlg != "1" && $!answer.freeTextFlg != "2")
<input type="checkbox" name="$answerIdValueName" value="$!escape.html($!answer.answerNo)" #if($answer.answerIdValue != "" && $enqueteForm.initCount =="2") checked #end
<input type="checkbox" class="#he($!question.questionId)" id="#he($!answer.answerId)" name="$answerIdValueName" value="$!escape.html($!answer.answerNo)" #if($answer.answerIdValue != "" && $enqueteForm.initCount =="2") checked #end
#if($!answer.defaultFlg == 1 && $enqueteForm.initCount =="1") checked #end
> $!escape.html($!answer.answer)
#if($!question.questionInitDisable == "1") disabled #end> $!escape.html($!answer.answer)
##end
##<!-- 自由入力欄。freeTextFlg=1(あり)、2(必須) -->
#if($!answer.freeTextFlg == "1" || $!answer.freeTextFlg == "2")
<input type="text" name="$answerValue" size="$!answer.freeTextColWidth" value="$!escape.html($!answer.answerValue)"/>
<input type="text" name="$answerValue" size="$!answer.freeTextColWidth" value="$!escape.html($!answer.answerValue)" #if($!question.questionInitDisable == "1") disabled #end/>
#end
##<!-- 3:TEXTAREA ユーザー入力値を値にする。-->
#elseif($!question.controlId == "3")
<textArea type="text" name="$answerIdValueName" cols="$!question.dispWitdth" rows="$!question.rowCount">$!answer.answerIdValue</textarea>
<textArea type="text" id="#he($!question.questionId)" name="$answerIdValueName" cols="$!question.dispWitdth" rows="$!question.rowCount" #if($!question.questionInitDisable == "1") disabled #end>$!answer.answerIdValue</textarea>
##<!-- 4:TEXTFIELD ユーザー入力値を値にする。-->
#elseif($!question.controlId == "4")
<input type="text" name="$answerIdValueName" value="$!escape.html($!answer.answerIdValue)" size="$!question.dispWitdth"/>
<input type="text" id="#he($!question.questionId)" name="$answerIdValueName" value="$!escape.html($!answer.answerIdValue)" size="$!question.dispWitdth" #if($!question.questionInitDisable == "1") disabled #end/>
##<!-- 5:日付入力 ユーザー入力値を値にする。-->
#elseif($!question.controlId == "5")
#set($dateIndex = $dateIndex+1)
<input name="$answerValue" id="enqStartFrom${dateIndex}" type="text" class="w100 mgl10" value="$!escape.html($!answer.answerValue)" >
<div style="display: none;"><img id="enqFrom${dateIndex}" src="/em/images/icon_cal.gif" style="padding-left:5px;padding-right:5px; vertical-align: middle;"></div>
<input name="$answerValue" id="enqStartFrom${dateIndex}" type="text" class="w100 mgl10 #he($!question.questionId)" value="$!escape.html($!answer.answerValue)" #if($!question.questionInitDisable == "1") disabled #end>
<div style="display: none;"><img id="enqFrom${dateIndex}" src="/em/images/icon_cal.gif" style="padding-left:5px;padding-right:5px; vertical-align: middle;" #if($!question.questionInitDisable == '1') display: none; #end"></div>
<input type="hidden" name="$answerIdValueName" value="$!answer.answerId" />
#elseif($!question.controlId == "6")
<select name="$answerIdValueName" >
<select name="$answerIdValueName" id="#he($!question.questionId)" #if($!question.questionInitDisable == "1") disabled #end>
#foreach($pecent1 in $enqueteForm.organizationListFor1Percent)
<option value="$!pecent1.organizationId" #if($!percentOrganizationId == $!pecent1.organizationId) selected #end>$!{pecent1.organizationNo} : $!escape.html($!{pecent1.organizationName})</option>
#end
......
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