<[include file="common/group_list.tpl"]>
<div id="contents">
<[include file="common/group_menu.tpl"]>
  <div id="site-info">
    <table width="100%">
      <tr>
        <td width="50%" align="left">
          <h3><img src="<[$TEMPLATE_DIR]>/img/icon_large/sakuin.jpg" width="38" height="44" align="absmiddle" style="margin-right:8px;">記事一覧</h3>
        </td>
        <td width="50%" align="right" valign="bottom"><a href="./index.php?mode=13&group_code=<[$current_group.group_code]>" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('shinki','','<[$TEMPLATE_DIR]>/img/btn/shinki_on.gif',1)"><img name="shinki" border="0" src="<[$TEMPLATE_DIR]>/img/btn/shinki_off.gif" alt="新規登録"></a></td>
      </tr>
    </table>
    <div class="entry-site-search">
      <form method="post" action="./index.php?mode=1&group_code=<[$current_group.group_code]>" name="form">
      <div style="float:right;">
        記事タイトル検索:
        <input name="search_word" type="text" value="<[$search_word|escape]>" size="25">
        <input type="submit" value=" 検索 ">
        <input type="button" value="リセット" onclick="document.form.search_word.value='';document.form.category_code.value='';document.form.per_page.value='10';document.form.submit();">
      </div>
      <div>
        カテゴリ:
        <select name="category_code" onchange="submit();">
          <option value="">全て</option>
        <[foreach from=$group_category_array item=group_category]>
          <option value="<[$group_category.category_code]>"<[if $group_category.category_code == $category_code]> selected<[/if]>><[$group_category.category_name|mbtruncate:25|escape]></option>
        <[/foreach]>
          <option value="0"<[if $category_code == "0"]> selected<[/if]>>なし</option>
        </select>
        &nbsp;
        表示件数:
        <select name="per_page" onchange="submit();">
          <option value="10"<[if $per_page == "10"]> selected<[/if]>>10</option>
          <option value="20"<[if $per_page == "20"]> selected<[/if]>>20</option>
          <option value="40"<[if $per_page == "40"]> selected<[/if]>>40</option>
          <option value="50"<[if $per_page == "50"]> selected<[/if]>>50</option>
          <option value="100"<[if $per_page == "100"]> selected<[/if]>>100</option>
        </select>
        ［<a href="./index.php?mode=18&group_code=<[$current_group.group_code]>"><img src="<[$TEMPLATE_DIR]>/img/icon/add.gif" border="0" align="absmiddle" hspace="0" alt="カテゴリの追加">カテゴリの追加</a>］
        </div>
      </form>
    </div>
    <table id="view-table" cellpadding="2" cellspacing="0" width="100%">
      <tr>
        <th width="40" valign="middle" colspan="2" nowrap>確認</th>
        <th width="60" nowrap>掲載</th>
        <th width="120" nowrap>日付</th>
        <th width="60" nowrap>並び替え</th>
        <th nowrap>タイトル</th>
        <th width="60" nowrap>閲覧数</th>
        <th width="40" nowrap>編集</th>
        <th width="40" nowrap>複製</th>
        <th width="40" nowrap>削除</th>
      </tr>
    <[foreach from=$group_entry_array item=group_entry name=group_entry]>
      <tr class="<[cycle values="odd,even"]>">
        <td width="3">
        <[if $group_entry.entry_publish > 0]>
          <div style="margin:0px;padding:1px;background-color:#3333FF;"><img src="<[$TEMPLATE_DIR]>/img/global/space.gif" width="1" height="13"></div>
        <[else]>
          <div style="margin:0px;padding:1px;background-color:#FF3333;"><img src="<[$TEMPLATE_DIR]>/img/global/space.gif" width="1" height="13"></div>
        <[/if]>
        </td>
        <td width="37"><a href="#" onclick="MM_openBrWindow('./index.php?mode=34&group_code=<[$current_group.group_code]>&entry_code=<[$group_entry.entry_code]>','Preview','scrollbars=yes,width=800,height=600')"><img src="<[$TEMPLATE_DIR]>/img/icon/url.gif" border="0" alt="確認"></a></td>
        <td>
        <[if $group_entry.entry_publish > 0]>
          <img src="<[$TEMPLATE_DIR]>/img/icon/on_a.gif" name="publish_icon_on_<[$group_entry.entry_code]>" border="0" hspace="2"><a href="./index.php?mode=25&group_code=<[$current_group.group_code]>&entry_code=<[$group_entry.entry_code]>" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('publish_icon_off_<[$group_entry.entry_code]>','','<[$TEMPLATE_DIR]>/img/icon/off_o.gif',1)"><img src="<[$TEMPLATE_DIR]>/img/icon/off_n.gif" name="publish_icon_off_<[$group_entry.entry_code]>" border="0"></a>
        <[else]>
          <a href="./index.php?mode=24&group_code=<[$current_group.group_code]>&entry_code=<[$group_entry.entry_code]>" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('publish_icon_on_<[$group_entry.entry_code]>','','<[$TEMPLATE_DIR]>/img/icon/on_o.gif',1)"><img src="<[$TEMPLATE_DIR]>/img/icon/on_n.gif" name="publish_icon_on_<[$group_entry.entry_code]>" border="0" hspace="2"></a><img src="<[$TEMPLATE_DIR]>/img/icon/off_a.gif" name="publish_icon_off_<[$group_entry.entry_code]>">
        <[/if]>
        </td>
        <td><[$group_entry.entry_date|date_format:"%Y年%m月%d日"]></td>
        <td>
        <[if !($smarty.foreach.group_entry.first && $first_page)]>
          <a href="./index.php?mode=49&group_code=<[$current_group.group_code]>&entry_code=<[$group_entry.entry_code]>&move=up"><img src="<[$TEMPLATE_DIR]>/img/icon/up.gif" width="16" height="16" border="0"></a>
        <[else]>
          <img src="<[$TEMPLATE_DIR]>/img/global/space.gif" width="16" height="16" border="0">
        <[/if]>
        &nbsp;
        <[if !($smarty.foreach.group_entry.last && $last_page)]>
          <a href="./index.php?mode=49&group_code=<[$current_group.group_code]>&entry_code=<[$group_entry.entry_code]>&move=down"><img src="<[$TEMPLATE_DIR]>/img/icon/down.gif" width="16" height="16" border="0"></a>
        <[else]>
          <img src="<[$TEMPLATE_DIR]>/img/global/space.gif" width="16" height="16" border="0">
        <[/if]>
        </td>
        <td style="text-align:left;"><[$group_entry.entry_title|mbtruncate:100|escape]></td>
        <td style="text-align:right;"><[$group_entry.entry_page_view|number_format]></td>
        <td><a href="./index.php?mode=14&group_code=<[$current_group.group_code]>&entry_code=<[$group_entry.entry_code]>"><img src="<[$TEMPLATE_DIR]>/img/icon/s_edit.gif" border="0"></a></td>
        <td><a href="./index.php?mode=22&group_code=<[$current_group.group_code]>&entry_code=<[$group_entry.entry_code]>" onclick="return confirm('\'<[$group_entry.entry_title|escape:"javascriptall"|escape]>\'&nbsp;を複製しますか？');"><img src="<[$TEMPLATE_DIR]>/img/icon/copy.gif" border="0"></a></td>
        <td><a href="./index.php?mode=23&group_code=<[$current_group.group_code]>&entry_code=<[$group_entry.entry_code]>" onclick="return confirm('\'<[$group_entry.entry_title|escape:"javascriptall"|escape]>\'&nbsp;を削除しますか？');"><img src="<[$TEMPLATE_DIR]>/img/icon/trash.gif" border="0"></a></td>
      </tr>
      <[foreachelse]>
      <tr>
        <td colspan="10">記事データはありません。</td>
      </tr>
    <[/foreach]>
    </table>
  <[if $page_count > 1]>
    <table border="0" width="100%">
      <tr>
        <td>
          <div class="page-navi">
            <[if !$first_page]>&nbsp;<a href="./index.php?mode=1&group_code=<[$current_group.group_code]>&page=<[$current_page-1]>">&lt;&lt;前へ</a><[/if]><[section name=count start=1 loop=$page_count+1]>&nbsp;<[if $smarty.section.count.index != $current_page]><a href="./index.php?mode=1&group_code=<[$current_group.group_code]>&page=<[$smarty.section.count.index]>"><[$smarty.section.count.index]></a><[else]><[$smarty.section.count.index]><[/if]><[/section]><[if !$last_page]>&nbsp;<a href="./index.php?mode=1&group_code=<[$current_group.group_code]>&page=<[$current_page+1]>">次へ&gt;&gt;</a><[/if]>
          </div>
        </td>
      </tr>
    </table>
  <[/if]>
  </div>
</div>