<?php
/**
 * タグの追加・編集・削除画面内のタグ表示部分
 *
 * Copyright (c) 2010-2011 SetucoCMS Project.(http://sourceforge.jp/projects/setucocms)
 * All Rights Reserved.
 * 
 * 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
 *
 * @category   Setuco
 * @package    Admin
 * @subpackage View_Partial
 * @license    http://www.opensource.org/licenses/gpl-2.0.php GNU General Public License, version 2
 * @copyright  Copyright (c) 2010 SetucoCMS Project.(http://sourceforge.jp/projects/setucocms)
 * @link
 * @version
 * @since      File available since Release 0.1.0
 * @param      int         $index       インデックス番号
 * @param      Setuco_Form $editTagForm タグ編集フォーム
 * @param      array       $tag         タグ情報の配列
 * @author     charlesvineyard
 */
?>
<?php
    $form = clone($this->editTagForm);
    $form->addAllIdSuffix($this->index);
    $form->getElement('tag')->setValue($this->tag['name']);
    $form->getElement('id')->setValue($this->tag['id']);
    $form->getElement('preTag')->setValue($this->tag['name']);
?>

<td>
    <span><?php echo $this->escape($this->tag['name']) ?></span>
    <div class="rowEdit"><?php echo $form ?></div>
</td>
<td>
    <a href="javascript:void(0)" onclick="showRowEdit(this)">
        <img src="<?php echo $this->baseUrl('/images/admin/share/btn_edit.png') ?>" alt="編集" width="27" height="27" />
    </a>
</td>
<td>
    <a href="javascript:void(0)" onclick="confirmDeleteRedirect('<?php echo $this->baseUrl("/admin/tag/delete/id/{$this->tag['id']}") ?>', '<?php echo $this->escape($this->tag['name']) ?>');">
        <img src="<?php echo $this->baseUrl('/images/admin/share/btn_delete.png') ?>" alt="削除" width="27" height="27" />
    </a>
</td>