<%--
MosP - Mind Open Source Project    http://www.mosp.jp/
Copyright (C) MIND Co., Ltd.       http://www.e-mind.co.jp/

This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.

This program 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 General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
--%>
<%@ page
language     = "java"
pageEncoding = "Windows-31J"
buffer       = "256kb"
autoFlush    = "false"
errorPage    = "/jsp/common/error.jsp"
%><%@ page
import = "jp.mosp.common.common.MospConst"
import = "jp.mosp.common.common.HtmlUtility"
import = "jp.mosp.common.CommonConst"
import = "jp.mosp.system.vo.YakusyokuMasterListVo"
%><%
YakusyokuMasterListVo vo = (YakusyokuMasterListVo)request.getAttribute(MospConst.ATT_VO);
String[] aryYCode  		= vo.getAryYCode();
String[] aryTokyu  		= vo.getAryTokyu();
String[] aryTokyuName	= vo.getAryTokyuName();
String[] aryYName		= vo.getAryYName();
%>
<%= HtmlUtility.getHeader(vo) %>
<%= HtmlUtility.getSubTitle(vo) %>
<div class="Body" id="yakusyokuMasterList">
	<%= HtmlUtility.getMessages(vo) %>
	<div class="Search">
		<table>
			<tr>
				<td id="tdCode">
					<span><%= vo.NAM_YCODE %><%= CommonConst.STR_TITLE_SEPARATOR %></span>
					<input type="text" class="CodeTextBox" id="<%= YakusyokuMasterListVo.PRM_TXT_YCODE %>" name="<%= YakusyokuMasterListVo.PRM_TXT_YCODE %>" value="<%= vo.getEscTxtYCode() %>" />
				</td>
				<td id="tdPlt">
					<span><%= vo.NAM_TOKYU %><%=CommonConst.STR_TITLE_SEPARATOR%></span>
					<select id="<%= YakusyokuMasterListVo.PRM_PLT_TOKYU %>" name="<%= YakusyokuMasterListVo.PRM_PLT_TOKYU %>">
						<%=HtmlUtility.getSelectOption(vo.aryPltTokyu, vo.getPltTokyu())%>
					</select>
				</td>
				<td id="tdName">
					<span><%= vo.NAM_YNAME %><%= CommonConst.STR_TITLE_SEPARATOR %></span>
					<input type="text" class="TextBox" id="<%= YakusyokuMasterListVo.PRM_TXT_YNAME %>" name="<%= YakusyokuMasterListVo.PRM_TXT_YNAME %>" value="<%= vo.getEscTxtYName() %>" />
				</td>
				<td class="ButtonTd">
					<button type="button" onclick="doSubmitKey(document.form, 'S2201', '')"><%= CommonConst.NAM_SEARCH %></button>
				</td>
			</tr>
		</table>
	</div>
	<%= HtmlUtility.getListInfo(vo) %>
	<div class="List">
		<table id="list">
			<thead>
				<tr>
					<th id="thButton"></th>
					<th id="thCode"  onclick="doSubmitKey(document.form, 'S2203', '<%= vo.KEY_YCODE %>')">&nbsp;<%= vo.NAM_YCODE %>&nbsp;<%= vo.getSortMark(vo.KEY_YCODE ) %></th>
					<th id="thTokyu" onclick="doSubmitKey(document.form, 'S2203', '<%= vo.KEY_TOKYU %>')">&nbsp;<%= vo.NAM_TOKYU %>&nbsp;<%= vo.getSortMark(vo.KEY_TOKYU ) %></th>
					<th id="thName"  onclick="doSubmitKey(document.form, 'S2203', '<%= vo.KEY_YNAME %>')">&nbsp;<%= vo.NAM_YNAME %>&nbsp;<%= vo.getSortMark(vo.KEY_YNAME ) %></th>
				</tr>
			</thead>
			<tbody>
<%
for (int i = vo.getStart(); i <= vo.getEnd(); i++) {
%>
				<tr>
					<td class="ButtonTd">
						<button type="button" onclick="doSubmitKey(document.form, 'S2206', '<%= aryYCode[i] %>','<%= aryTokyu[i] %>')"><%= CommonConst.NAM_SELECT %></button>
					</td>
					<td id="tdCode" ><%= aryYCode [i] %></td>
					<td id="tdTokyu"><%= aryTokyuName [i] %></td>
					<td id="tdName" ><%= aryYName [i] %></td>
				</tr>
<%
}
%>
			</tbody>
		</table>
	</div>
	<div class="ButtonDiv">
		<button type="button" class="ExecuteButton" onclick="doSubmit(document.form, 'S2205')"><%= CommonConst.NAM_MAKE_NEW_DATA %></button>
		<button type="button" class="MenuButton" onclick="doSubmit(document.form, 'S2910')"><%= CommonConst.NAM_TO_MENU %></button>	
	</div>
</div>
<%= HtmlUtility.getFooter(vo) %>
