#*
 * Aipo is a groupware program developed by Aimluck,Inc.
 * Copyright (C) 2004-2008 Aimluck,Inc.
 * http://aipostyle.com/
 * 
 * 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 3 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, see <http://www.gnu.org/licenses/>.
 *#
##-------------------------------------------------------------------
#set ($newUrl1 = $!utils.escapeXML($!jslink.getPortletById($!portlet.ID).addQueryData("template","WebMailAccountFormScreen").addQueryData("entityid","new")))
#set ($submenulist = [["メールアカウントを追加する","javascript:aipo.common.showDialog('$newUrl1');","images/icon/icon_add.gif"]])
#set($tabs = [["メールアカウント一覧", "",""]])
##------------------------------------------------------------------------------
#ALsubmenubar($submenulist "")
#ALajaxtabheader($tabs "")
#ALspacebothheader()
#if($result.List.size() <= 0)
<div class="message">メールアカウントが登録されていません。</div>
#else
#ALajaxlistformheader('WebMail')
#ALajaxpageview('WebMailAccountListScreen' $result)
#ALtableheaderWide()
<tr>
#ALtdhead("#ALajaxsort('account_name' 'アカウント名' $result 'WebMailAccountListScreen')")
#ALtdheadAtt('未読数' 'width="1%"')
#ALtdheadAtt('最終受信日' 'width="1%"')
#ALtdheadAtt(' ' 'width="1%"')
</tr>
#foreach ($record in $result.List)
#if($!record.countUnRead>= 0)
#set($countUnRead = $!record.countUnRead)
#else
#set($countUnRead = "確認失敗")
#end
<tr>
#ALtdcellheader()
<a href="javascript:void(0);" onclick="aipo.common.showDialog('$!utils.escapeXML($!jslink.getPortletById($!portlet.ID).addQueryData("template","WebMailAccountDetailScreen").addQueryData("accountid",$record.AccountId))');">$!record.AccountName</a>
#ALtdcellfooter()
#ALtdcellAtt("$countUnRead" 'align="right" nowrap')
#if($!record.FinalAccessDate.toString() != "")
#ALtdcellAtt("$!{record.FinalAccessDate.Month}月$!{record.FinalAccessDate.Day}日 $!{record.FinalAccessDate.Hour}時$!{record.FinalAccessDate.Minute}分" 'align="left" valign="center" nowrap')
#else
#ALtdcellAtt("なし" 'align="center"')
#end
#ALtdcellAtt("#ALajaxbuttonLink('編集' $!jslink.getPortletById($!portlet.ID).addQueryData('template','WebMailAccountFormScreen').addQueryData('mode','form').addQueryData('entityid',$record.AccountId) 'images/icon/icon_edit.gif')" 'nowrap')
</tr>
#end
#ALtablefooter()
#ALajaxpageviewFooter('WebMailAccountListScreen' $result)
#end
#ALformfooter()
#ALspacebothfooter()
#ALajaxtabfooter()
