<html>
<head>
{ include file="header.tpl" }
<script type="text/javascript" src="js/common.js"></script>
<script type="text/javascript" src="js/frame_adjuster.js"></script>
<script type="text/javascript" src="js/update.js"></script>
</head>
<body>
<div class="windowStyle">
<table width="100%" border="0" cellspacing="0" cellpadding="5">
{ assign var="window_name" value = $session.user_name }
{if isset($session.unit)}
{ assign var="window_name" value = "`$session.unit`/$window_name" }
{/if}
{if isset($session.tenant) && $session.role == 'system_admin'}
{ assign var="window_name" value = "`$session.tenant`/$window_name" }
{/if}
{if isset($session.system)}
{ assign var="window_name" value = "`$session.system`/$window_name" }
{/if}
{ assign var="window_name" value = "ユーザ $window_name" }
{ include file="window_name.tpl" }
<tr class="windowMenu">
    <th><img src="images/publish.png"></th>
    <th>
    <a href="#" onClick="goAction('action_user_create')"
       title="ユーザを登録します">新規登録</a>
    </th>
    <th>
    &nbsp;&nbsp;
    </th>
    <th><img src="images/import_wiz.gif"></th>
    <th>
    <a href="#" onClick="goAction('action_user_importCSV')"
       title="ユーザを登録します">CSV登録</a>
    </th>
    <th width="100%" align="right">
      <div style="color:royalblue">{ $app.message }</div>
      <div style="color:red">{message name=""}</div>
    </th>
</tr>
</table>
</div>
<div class="infoName">
<table width="100%" border="0" cellspacing="0" cellpadding="2">
<tr><th class="tabActive" style="width:20%">
    <a href="#"
       onClick="doChangeTab('action_user_update')"
       title="ユーザ情報を登録します">ユーザ情報</a></th>
{if isset($config.modules.Group)}
    <th class="tabInactive" style="width:20%">
    <a href="#"
       onClick="doChangeTab('action_user_assignGroup')"
       title="ユーザをグループに追加または削除します">グループ</a></th>
{/if}
</tr>
</table>
</div>
<div class="infoStyle">
{form name="input" target="main" enctype="multipart/form-data"}
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr><td>
    <table width="100%" frame="below" rules="all" cellspacing="0" cellpadding="5" bordercolor="lightgrey">
    <tr><th class="itemName" width="1%">{form_name name="id"}</th>
        <td>{ $form.id }
        </td></tr>
    <tr><th class="itemName" width="1%">{form_name name="empnum"}</th>
        <td>{ $form.empnum }
        </td></tr>
{if isset($config.secioss.user.loginidattr)}
    <tr><th class="itemName" width="1%">{form_name name="loginid"}</th>
        <td>{form_input name="loginid"}
        </td></tr>
{/if}
{if !isset($session.ldaptype) || $session.ldaptype != 'AD'}
    <tr><th class="itemName" width="1%" title="姓名（漢字）です">氏名（漢字）</th>
        <td>
        {form_name name="snkanji"}&nbsp;{form_input name="snkanji" size="20"}
        {form_name name="gnkanji"}&nbsp;{form_input name="gnkanji" size="20"}
        </td></tr>
    <tr><th class="itemName" width="1%" title="姓名（かな）です">氏名（かな）</th>
        <td>
        {form_name name="snkana"}&nbsp;{form_input name="snkana" size="20"}
        {form_name name="gnkana"}&nbsp;{form_input name="gnkana" size="20"}
        </td></tr>
{else}
    <tr><th class="itemName" width="1%" title="姓名（漢字）です">{form_name name="name"}
        </th>
        <td>
        {form_name name="snkanji"}&nbsp;{$form.snkanji}&nbsp;&nbsp;&nbsp;
        {form_name name="gnkanji"}&nbsp;{$form.gnkanji}
        <input type="hidden" name="snkanji" value={$form.snkanji}>
        <input type="hidden" name="gnkanji" value={$form.gnkanji}>
        </td></tr>
{/if}
    <tr><th class="itemName" width="1%" title="メールアドレスです">{form_name name="mail"}</th>
        <td>
        {form_input name="mail" size="40"}
        </td></tr>
    <tr><th class="itemName" width="1%" title="パスワードです">{form_name name="password"}</th>
        <td>
        {form_input name="password" size="20"}
        </td></tr>
    <tr><th class="itemName" width="1%" title="証明書">{form_name name="certificate"}</th>
        <td>
        {form_input name="certificate"}
        </td></tr>
{if isset($config.secioss.user.statusattr)}
    <tr><th class="itemName" width="1%" title="アカウントの状態です">{form_name name="status"}</th>
        <td>
        {form_input name="status" default=$app.status}
        {if $form.lockout}&nbsp;&nbsp{form_input name="unlock"}{/if}
        </td></tr>
{/if}
{if isset($config.secioss.user.pwlodurationattr)}
    <tr><th class="itemName" width="1%" title="アカウントロックアウトの解除時間です">{form_name name="pwloduration"}</th>
        <td>
        {form_input name="pwloduration"}<br>
ユーザ毎にアカウントのロックアウト解除時間を設定します。<br>
0を設定した場合はパスワードポリシーのロックアウト時間が適用されます。
        </td></tr>
{/if}
{if isset($config.secioss.sync)}
    <tr><th class="itemName" width="1%" title="更新対象システムです">{form_name name="sync"}</th>
        <td>{form_input name="sync" default=$form.sync}
        </td></tr>
{/if}
{foreach from=$config.secioss.user.userdefinedattr key=attr item=name}
    <tr><th class="itemName" width="1%">{$name}</th>
        <td><input type="text" name="attr_{$attr}" value="{$app.$attr}"></td></tr>
{/foreach}
    </table>
    </td></tr>
<tr><td align="center">
    <br>
    <input type="button" value="更新" onClick="doUpdate('action_user_update', 'ユーザ情報')">&nbsp;
    <input type="button" value="削除" onClick="doDelete('action_user_delete', 'ユーザ情報')">
    &nbsp;
    <input type="button" value="パスワード初期化" onClick="doInitPwd()">
    </td></tr>
</table>
{form_input name="id" value=$form.id}
{form_input name="empnum" value=$form.empnum}
{form_input name="lockout" value=$form.lockout}
{form_input name="dn" value=$form.dn}
{form_input name="operation"}
<input type="hidden" name="action_user_create" value="">
<input type="hidden" name="action_user_importCSV" value="">
<input type="hidden" name="action_user_update" value="">
<input type="hidden" name="action_user_delete" value="">
<input type="hidden" name="action_user_assignGroup" value="">
<input type="hidden" name="action_user_initPwd" value="">
{/form}
</div>
</body>
</html>
