<?php include VIEW_DIR.'mobile/common/menu/schedule.tpl'; ?>

<?php if (empty($this->_vars['schedule'])):?>
	<?php _e('Sorry, no results found.'); ?><br><br>
	<?php loadPlugin::callFunc('hitsuji_banner', POSITION_MOBILE); ?><br>
<?php else: ?>
<table border="0" width="<?php Theme::exec()->mainWidth(); ?>">
	<tr><td bgcolor="<?php Theme::exec()->bgColor(); ?>">
	<img src="<?php e(BASE_URL); ?>resource/img/icons/information.gif" width="16" height="16" alt="&gt;">&nbsp;<?php e($this->_vars['schedule']['schedule']); ?><br>
	<?php eDate($this->_vars['schedule']['start_date']); ?>&nbsp;
	<?php e(ifNull($this->_vars['schedule']['start_hour'], '--')); ?>:
	<?php e(ifNull($this->_vars['schedule']['start_minute'], '--')); ?>
	&nbsp;<?php _e(' to '); ?>&nbsp;<br>
	<?php eDate($this->_vars['schedule']['end_date']); ?>
	<?php e(ifNull($this->_vars['schedule']['start_hour'], '--')); ?>:
	<?php e(ifNull($this->_vars['schedule']['start_minute'], '--')); ?><br>
<?php if ($this->_vars['base']['account']['id'] == $this->_vars['schedule']['ref_account']): ?>
	<img src="<?php e(BASE_URL); ?>resource/img/icons/date_edit.gif" width="16" height="16" alt="&gt;">&nbsp;<a href="<?php e(HTTP_ACTION); ?>private/post/schedule/<?php e($this->_vars['schedule']['id']); ?>/"><?php _e('Edit'); ?></a>&nbsp;/
	<img src="<?php e(BASE_URL); ?>resource/img/icons/trash.gif" width="16" height="16" alt="&gt;">&nbsp;<a href="<?php e(HTTP_ACTION); ?>private/post/schedule/<?php e($this->_vars['schedule']['id']); ?>/delete/"><?php _e('Delete'); ?></a><br>
<?php endif; ?>
	</td></tr>
</table>
<hr color="<?php Theme::exec()->borderColor(); ?>" noshade="noshade">
<?php HTML::htmlBody($this->_vars['schedule']['comment']); ?>
<hr color="<?php Theme::exec()->borderColor(); ?>" noshade="noshade">

<table border="0" width="<?php Theme::exec()->mainWidth(); ?>">
	<tr><td bgcolor="<?php Theme::exec()->bgColor(); ?>" align="center">
		<?php if (!empty($this->_vars['prev'])): ?><a href="<?php e(HTTP_ACTION); ?>member/schedule/view/<?php e($this->_vars['prev']['id']); ?>/">&lt;&lt;&nbsp;<?php _e('Preview'); ?></a><?php endif; ?>
		<?php if (!empty($this->_vars['next'])): ?><a href="<?php e(HTTP_ACTION); ?>member/schedule/view/<?php e($this->_vars['next']['id']); ?>/"><?php _e('Next'); ?>&nbsp;&gt;&gt;</a><?php endif; ?><br>
	</td></tr>
	<tr><td bgcolor="<?php Theme::exec()->bgColor(); ?>">
		<img src="<?php e(BASE_URL); ?>resource/img/icons/comment.gif" width="16" height="16" alt="&gt;">&nbsp;<a href="<?php e(HTTP_ACTION); ?>member/schedule/comments/<?php e($this->_vars['base']['member']['id']); ?>/<?php e($this->_vars['schedule']['id']); ?>/"><?php _e('Comments');?>&nbsp;(<?php e($this->_vars['schedule']['posts']); ?>)</a><br>
	</td></tr>
	<tr><td bgcolor="<?php Theme::exec()->bgColor(); ?>">
		<img src="<?php e(BASE_URL); ?>resource/img/icons/comment_edit.gif" width="16" height="16" alt="&gt;">&nbsp;<a href="<?php e(HTTP_ACTION); ?>member/schedule/comment/<?php e($this->_vars['schedule']['id']); ?>/0/"><?php _e('Write a Comment'); ?></a>
	</td></tr>
</table>
<?php endif; ?>
