Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
em
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ichikawa
em
Commits
b697f54d
Commit
b697f54d
authored
Jan 10, 2024
by
Kim Gyeongeun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
#56952 設問設定機能追加
parent
d0bbfdf4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
122 additions
and
24 deletions
+122
-24
src/main/webapp/WEB-INF/view/common/enquete_mb.vm
+12
-11
src/main/webapp/WEB-INF/view/common/enquete_sp.vm
+15
-13
src/main/webapp/WEB-INF/view/mb/user/enquete/enquete.html
+41
-0
src/main/webapp/WEB-INF/view/sp/user/enquete/enquete.html
+54
-0
No files found.
src/main/webapp/WEB-INF/view/common/enquete_mb.vm
View file @
b697f54d
...
@@ -37,7 +37,7 @@ $tools.getMsg("errorheader")
...
@@ -37,7 +37,7 @@ $tools.getMsg("errorheader")
#if($!question.controlId == "2")
#if($!question.controlId == "2")
<td width="$tdWidthPercent%" valign = "top" >
<td width="$tdWidthPercent%" valign = "top" >
#set($answerIdValueName = "questionList[$questionIndex].answerList[0].answerIdValue")
#set($answerIdValueName = "questionList[$questionIndex].answerList[0].answerIdValue")
<select name="$answerIdValueName" style="width:100%">
<select name="$answerIdValueName" style="width:100%"
id="#he($!question.questionId)" #if($!question.questionInitDisable == "1") disabled #end
>
#foreach($selectAnswer in $question.answerList)
#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 #elseif($!selectAnswer.defaultFlg == "1" && $enqueteForm.initCount!="2") selected #end >$!escape.html($!selectAnswer.answer)</option>
#end
#end
...
@@ -66,31 +66,32 @@ $tools.getMsg("errorheader")
...
@@ -66,31 +66,32 @@ $tools.getMsg("errorheader")
<!-- 0:RADIO インデクスを値にする。 -->
<!-- 0:RADIO インデクスを値にする。 -->
#if($!question.controlId == "0")
#if($!question.controlId == "0")
<input type="radio" name="$!answerIdValueRadioName" value="$!escape.html($!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="$!escape.html($!velocityCount)" #if($!answer.answerIdValue == $velocityCount.toString() && $enqueteForm.initCount =="2") checked #{end}
#if($!answer.defaultFlg == 1 && $enqueteForm.initCount =="1") checked #end
#if($!answer.defaultFlg == 1 && $enqueteForm.initCount =="1") checked #end
/>$!answer.answer
#if($!answer.answerInitDisable == "1") disabled #end
/>$!answer.answer
##end
##end
##<!-- 自由入力欄。freeTextFlg=1(あり)、2(必須) -->
##<!-- 自由入力欄。freeTextFlg=1(あり)、2(必須) -->
#if($!answer.freeTextFlg == "1" || $!answer.freeTextFlg == "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
#end
##<!-- 1:CHECKBOX answer.answerNo値を値にする。-->
##<!-- 1:CHECKBOX answer.answerNo値を値にする。-->
#elseif($!question.controlId == "1")
#elseif($!question.controlId == "1")
##if($!answer.freeTextFlg != "1" && $!answer.freeTextFlg != "2")
##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
#if($!answer.defaultFlg == 1 && $enqueteForm.initCount =="1") checked #end
#if($!answer.answerInitDisable == "1") disabled #end
/>$!answer.answer
/>$!answer.answer
##end
##end
##<!-- 自由入力欄。freeTextFlg=1(あり)、2(必須) -->
##<!-- 自由入力欄。freeTextFlg=1(あり)、2(必須) -->
#if($!answer.freeTextFlg == "1" || $!answer.freeTextFlg == "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
#end
##<!-- 2:SELECTMENU answer.answerNo値を値にする。-->
##<!-- 2:SELECTMENU answer.answerNo値を値にする。-->
#elseif($!question.controlId == "2")
#elseif($!question.controlId == "2")
#if($velocityCount == 0)
#if($velocityCount == 0)
<select name="$answerIdValueName" style="width:100%">
<select name="$answerIdValueName" style="width:100%"
#if($!question.questionInitDisable == "1") disabled #end
>
#foreach($selectAnswer in $question.answerList)
#foreach($selectAnswer in $question.answerList)
<option value="$!selectAnswer.answerId" #if($!selectAnswer.defaultFlg == "1") selected #end >$!escape.html($!selectAnswer.answer)</option>
<option value="$!selectAnswer.answerId" #if($!selectAnswer.defaultFlg == "1") selected #end >$!escape.html($!selectAnswer.answer)</option>
#end
#end
...
@@ -99,18 +100,18 @@ $tools.getMsg("errorheader")
...
@@ -99,18 +100,18 @@ $tools.getMsg("errorheader")
##<!-- 3:TEXTAREA ユーザー入力値を値にする。-->
##<!-- 3:TEXTAREA ユーザー入力値を値にする。-->
#elseif($!question.controlId == "3")
#elseif($!question.controlId == "3")
#if($!question.dispWitdth > 25) #set($question.dispWitdth = 25) #end
#if($!question.dispWitdth > 25) #set($question.dispWitdth = 25) #end
<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 ユーザー入力値を値にする。-->
##<!-- 4:TEXTFIELD ユーザー入力値を値にする。-->
#elseif($!question.controlId == "4")
#elseif($!question.controlId == "4")
#if($!question.dispWitdth > 37) #set($!question.dispWitdth = 37) #end
#if($!question.dispWitdth > 37) #set($!question.dispWitdth = 37) #end
<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:日付入力 ユーザー入力値を値にする。-->
##<!-- 5:日付入力 ユーザー入力値を値にする。-->
#elseif($!question.controlId == "5")
#elseif($!question.controlId == "5")
#set($dateIndex = $dateIndex+1)
#set($dateIndex = $dateIndex+1)
<input type="text"
name="$answerValue" value="$!escape.html($!answer.answerValue)"
/>
<input type="text"
class="#he($!question.questionId)" name="$answerValue" value="$!escape.html($!answer.answerValue)" #if($!question.questionInitDisable == "1") disabled #end
/>
<input type="hidden" name="$answerIdValueName" value="$!answer.answerId" />
<input type="hidden" name="$answerIdValueName" value="$!answer.answerId" />
#elseif($!question.controlId == "6")
#elseif($!question.controlId == "6")
<select name="$answerIdValueName" style="width:100%">
<select name="$answerIdValueName" style="width:100%"
id="#he($!question.questionId)" #if($!question.questionInitDisable == "1") disabled #end
>
<option value="" >下記より選択してください</option>
<option value="" >下記より選択してください</option>
#foreach($pecent1 in $enqueteForm.organizationListFor1Percent)
#foreach($pecent1 in $enqueteForm.organizationListFor1Percent)
<option value="$!pecent1.organizationId" #if($!answer.answerIdValue == $!pecent1.organizationId) selected #end>$!{pecent1.organizationNo} : $!escape.html($!{pecent1.organizationName})</option>
<option value="$!pecent1.organizationId" #if($!answer.answerIdValue == $!pecent1.organizationId) selected #end>$!{pecent1.organizationNo} : $!escape.html($!{pecent1.organizationName})</option>
...
...
src/main/webapp/WEB-INF/view/common/enquete_sp.vm
View file @
b697f54d
...
@@ -44,7 +44,7 @@ $tools.getMsg("errorheader")
...
@@ -44,7 +44,7 @@ $tools.getMsg("errorheader")
#if($!question.controlId == "2")
#if($!question.controlId == "2")
<td width="$tdWidthPercent%" valign = "top" >
<td width="$tdWidthPercent%" valign = "top" >
#set($answerIdValueName = "questionList[$questionIndex].answerList[0].answerIdValue")
#set($answerIdValueName = "questionList[$questionIndex].answerList[0].answerIdValue")
<select name="$answerIdValueName">
<select name="$answerIdValueName"
class="#he($!question.questionId),#he($!answer.answerId)" #if($!question.questionInitDisable == "1") disabled #end
>
#foreach($selectAnswer in $question.answerList)
#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 #elseif($!selectAnswer.defaultFlg == "1" && $enqueteForm.initCount!="2") selected #end >$!escape.html($!selectAnswer.answer)</option>
#end
#end
...
@@ -77,16 +77,17 @@ $tools.getMsg("errorheader")
...
@@ -77,16 +77,17 @@ $tools.getMsg("errorheader")
#set($answerId ="$!answerIdValueRadioName"+"$velocityCount")
#set($answerId ="$!answerIdValueRadioName"+"$velocityCount")
<div data-role="fieldcontain">
<div data-role="fieldcontain">
<input type="radio" name="$!answerIdValueRadioName" id=$answerId value="$velocityCount"
<input type="radio"
class="#he($!question.questionId) #he($!answer.answerId)"
name="$!answerIdValueRadioName" id=$answerId value="$velocityCount"
#if($!answer.answerIdValue == $velocityCount.toString() && $enqueteForm.initCount =="2") checked #{end}
#if($!answer.answerIdValue == $velocityCount.toString() && $enqueteForm.initCount =="2") checked #{end}
#if($!answer.defaultFlg == 1 && $enqueteForm.initCount =="1") checked #end>
#if($!answer.defaultFlg == 1 && $enqueteForm.initCount =="1") checked #end
#if($!answer.answerInitDisable == "1") disabled #end>
<label for=$answerId>$!answer.answer</label>
<label for=$answerId>$!answer.answer</label>
</div>
</div>
##<!-- 自由入力欄。freeTextFlg=1(あり)、2(必須) -->
##<!-- 自由入力欄。freeTextFlg=1(あり)、2(必須) -->
#if($!answer.freeTextFlg == 1 || $!answer.freeTextFlg == 2)
#if($!answer.freeTextFlg == 1 || $!answer.freeTextFlg == 2)
<div data-role="fieldcontain">
<div data-role="fieldcontain">
<input type="text" id="$answerValue" name="$answerValue" size="$!answer.freeTextColWidth" value="$!escape.html($!answer.answerValue)" />
<input type="text"
class="#he($!answer.answerId)"
id="$answerValue" name="$answerValue" size="$!answer.freeTextColWidth" value="$!escape.html($!answer.answerValue)" />
<label for=$answerValue class="ui-hidden-accessible"></label>
<label for=$answerValue class="ui-hidden-accessible"></label>
</div>
</div>
#end
#end
...
@@ -96,15 +97,16 @@ $tools.getMsg("errorheader")
...
@@ -96,15 +97,16 @@ $tools.getMsg("errorheader")
#set($answerId ="$!answerIdValueName"+"$velocityCount")
#set($answerId ="$!answerIdValueName"+"$velocityCount")
<div data-role="fieldcontain">
<div data-role="fieldcontain">
<input type="checkbox" id=$answerId name="$answerIdValueName" value="$!escape.html($!answer.answerNo)" #if($answer.answerIdValue != "" && $enqueteForm.initCount =="2") checked #end
<input type="checkbox" class="#he($!question.questionId) #he($!answer.answerId)" id=$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>
#if($!answer.defaultFlg == 1 && $enqueteForm.initCount =="1") checked #end
<label for=$answerId>$!answer.answer</label>
#if($!answer.answerInitDisable == "1") disabled #end>
<label for=$answerId id="#he($!answer.answerId)">$!answer.answer</label>
</div>
</div>
##<!-- 自由入力欄。freeTextFlg=1(あり)、2(必須) -->
##<!-- 自由入力欄。freeTextFlg=1(あり)、2(必須) -->
#if($!answer.freeTextFlg == 1 || $!answer.freeTextFlg == 2)
#if($!answer.freeTextFlg == 1 || $!answer.freeTextFlg == 2)
<div data-role="fieldcontain">
<div data-role="fieldcontain">
<input type="text"
id="$answerValue" name="$answerValue" size="$!answer.freeTextColWidth" value="$!escape.html($!answer.answerValue)"
/>
<input type="text"
class="#he($!answer.answerId)" id="$answerValue" name="$answerValue" size="$!answer.freeTextColWidth" value="$!escape.html($!answer.answerValue)" #if($!question.questionInitDisable == "1") disabled #end
/>
<label for=$answerValue class="ui-hidden-accessible"></label>
<label for=$answerValue class="ui-hidden-accessible"></label>
</div>
</div>
#end
#end
...
@@ -114,7 +116,7 @@ $tools.getMsg("errorheader")
...
@@ -114,7 +116,7 @@ $tools.getMsg("errorheader")
#if($velocityCount == 0)
#if($velocityCount == 0)
<div data-role="fieldcontain">
<div data-role="fieldcontain">
<select name="$answerIdValueName"
>
<select name="$answerIdValueName"
class="#he($!question.questionId),#he($!answer.answerId)" #if($!question.questionInitDisable == "1") disabled #end
>
#foreach($selectAnswer in $question.answerList)
#foreach($selectAnswer in $question.answerList)
<option value="$!selectAnswer.answerId" #if($!selectAnswer.defaultFlg == "1") selected #end >$!selectAnswer.answer</option>
<option value="$!selectAnswer.answerId" #if($!selectAnswer.defaultFlg == "1") selected #end >$!selectAnswer.answer</option>
#end
#end
...
@@ -125,24 +127,24 @@ $tools.getMsg("errorheader")
...
@@ -125,24 +127,24 @@ $tools.getMsg("errorheader")
##<!-- 3:TEXTAREA ユーザー入力値を値にする。-->
##<!-- 3:TEXTAREA ユーザー入力値を値にする。-->
#elseif($!question.controlId == "3")
#elseif($!question.controlId == "3")
<div data-role="fieldcontain">
<div data-role="fieldcontain">
<textArea type="text" name="$answerIdValueName" cols="$!question.dispWitdth" rows="$!question.rowCount">$!answer.answerIdValue</textarea>
<textArea type="text"
class="#he($!question.questionId)"
name="$answerIdValueName" cols="$!question.dispWitdth" rows="$!question.rowCount">$!answer.answerIdValue</textarea>
</div>
</div>
##<!-- 4:TEXTFIELD ユーザー入力値を値にする。-->
##<!-- 4:TEXTFIELD ユーザー入力値を値にする。-->
#elseif($!question.controlId == "4")
#elseif($!question.controlId == "4")
<div data-role="fieldcontain">
<div data-role="fieldcontain">
<input type="text"
id="$answerIdValueName" name="$answerIdValueName" value="$!escape.html($!answer.answerIdValue)" size="$!question.dispWitdth"
/>
<input type="text"
class="#he($!question.questionId)" id="$answerIdValueName" name="$answerIdValueName" value="$!escape.html($!answer.answerIdValue)" size="$!question.dispWitdth" #if($!question.questionInitDisable == "1") disabled #end
/>
<label for=$answerIdValueName class="ui-hidden-accessible"></label>
<label for=$answerIdValueName class="ui-hidden-accessible"></label>
</div>
</div>
##<!-- 5:日付入力 ユーザー入力値を値にする。-->
##<!-- 5:日付入力 ユーザー入力値を値にする。-->
#elseif($!question.controlId == "5")
#elseif($!question.controlId == "5")
<div data-role="fieldcontain">
<div data-role="fieldcontain">
<input type="date"
id="$answerIdName" name="$answerValue" value="$!escape.html($!answer.answerValue)"
/>
<input type="date"
class="#he($!question.questionId)" id="$answerIdName" name="$answerValue" value="$!escape.html($!answer.answerValue)" #if($!question.questionInitDisable == "1") disabled #end
/>
<label for=$answerIdName class="ui-hidden-accessible"></label>
<label for=$answerIdName class="ui-hidden-accessible"></label>
<input type="hidden" name="$answerIdValueName" value="$!answer.answerId" />
<input type="hidden" name="$answerIdValueName" value="$!answer.answerId" />
</div>
</div>
#elseif($!question.controlId == "6")
#elseif($!question.controlId == "6")
<div data-role="fieldcontain">
<div data-role="fieldcontain">
<select name="$answerIdValueName" >
<select name="$answerIdValueName"
class="#he($!question.questionId),#he($!answer.answerId)" #if($!question.questionInitDisable == "1") disabled #end
>
<option value="" >下記より選択してください</option>
<option value="" >下記より選択してください</option>
#foreach($pecent1 in $enqueteForm.organizationListFor1Percent)
#foreach($pecent1 in $enqueteForm.organizationListFor1Percent)
<option value="$!pecent1.organizationId" #if($!answer.answerIdValue == $!pecent1.organizationId) selected #end>$!{pecent1.organizationNo} : $!escape.html($!{pecent1.organizationName})</option>
<option value="$!pecent1.organizationId" #if($!answer.answerIdValue == $!pecent1.organizationId) selected #end>$!{pecent1.organizationNo} : $!escape.html($!{pecent1.organizationName})</option>
...
...
src/main/webapp/WEB-INF/view/mb/user/enquete/enquete.html
View file @
b697f54d
#set($title = "アンケート")
#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.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.questionId}"
).
attr
(
"disabled"
,
false
);
}
else
if
(
"${question.controlId}"
==
"5"
)
{
$
(
".${question.questionId}"
).
attr
(
"disabled"
,
false
);
$
(
".${question.questionId}"
).
next
().
show
();
}
}
}
});
});
// -->
</script>
#end
#end
<!-- preHeader -->
<!-- preHeader -->
#parse( "/WEB-INF/view/common/preHeader_mb.vm" )
#parse( "/WEB-INF/view/common/preHeader_mb.vm" )
<body
style=
"font-family: monospace; width: 240px; border: 2px solid black;"
>
<body
style=
"font-family: monospace; width: 240px; border: 2px solid black;"
>
...
...
src/main/webapp/WEB-INF/view/sp/user/enquete/enquete.html
View file @
b697f54d
#set($title = "アンケート回答")
#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
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}"
;
var
controlName
=
(
"${question.controlId}"
==
"0"
)?
"radio"
:
"checkbox"
;
document
.
getElementById
(
key
).
classList
.
remove
(
"ui-"
+
controlName
+
"-on"
);
document
.
getElementById
(
key
).
classList
.
add
(
"ui-"
+
controlName
+
"-off"
);
$
(
"#"
+
key
).
children
().
children
(
"span:eq(1)"
).
removeClass
(
"ui-icon-"
+
controlName
+
"-on"
);
$
(
"#"
+
key
).
children
().
children
(
"span:eq(1)"
).
addClass
(
"ui-icon-"
+
controlName
+
"-off"
);
$
(
"#"
+
key
).
closest
(
"span.ui-icon"
).
removeClass
(
"ui-checkbox-on"
);
$
(
"#"
+
key
).
closest
(
"span.ui-icon"
).
addClass
(
"ui-checkbox-off"
);
$
(
"."
+
key
).
attr
(
"checked"
,
false
);
$
(
"."
+
key
).
attr
(
"disabled"
,
true
);
}
else
if
(
"${question.controlId}"
==
"2"
||
"${question.controlId}"
==
"3"
||
"${question.controlId}"
==
"4"
)
{
$
(
"#${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"
)
{
key
=
"${answer.answerId}"
;
$
(
"."
+
key
).
prop
(
"disabled"
,
false
);
}
else
if
(
"${question.controlId}"
==
"2"
||
"${question.controlId}"
==
"3"
||
"${question.controlId}"
==
"4"
)
{
$
(
"#${question.questionId}"
).
attr
(
"disabled"
,
false
);
}
else
if
(
"${question.controlId}"
==
"5"
)
{
$
(
".${question.questionId}"
).
attr
(
"disabled"
,
false
);
$
(
".${question.questionId}"
).
next
().
show
();
}
}
}
});
});
// -->
</script>
#end
#end
<!-- preHeader -->
<!-- preHeader -->
#set($ajaxdisable = "1")
#set($ajaxdisable = "1")
#parse( "/WEB-INF/view/common/preHeader_sp.vm" )
#parse( "/WEB-INF/view/common/preHeader_sp.vm" )
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment