ここの情報は古いです。ご理解頂いた上でお取り扱いください。

Changeset 9870


Ignore:
Timestamp:
Jan 4, 2009, 12:53:30 PM (14 years ago)
Author:
ogawa
Message:

#3209:fixed design for the pc_frontend application

Location:
OpenPNE3/plugins/opDiaryPlugin/trunk
Files:
1 added
8 edited

Legend:

Unmodified
Added
Removed
  • OpenPNE3/plugins/opDiaryPlugin/trunk/apps/mobile_frontend/modules/diary/templates/showSuccess.php

    r9862 r9870  
    1 <?php include_page_title(__('Diary of %1%', array('%1%' => $diary->getMember()->getName())), $diary->getTitle()) ?>
     1<?php include_page_title(__('Diary of %1%', array('%1%' => $member->getName())), $diary->getTitle()) ?>
    22<?php use_helper('Date') ?>
    33
  • OpenPNE3/plugins/opDiaryPlugin/trunk/apps/pc_frontend/modules/diary/actions/components.class.php

    r9645 r9870  
    1010class diaryComponents extends opDiaryPluginDiaryComponents
    1111{
     12  public function executeSidemenu()
     13  {
     14  }
    1215}
  • OpenPNE3/plugins/opDiaryPlugin/trunk/apps/pc_frontend/modules/diary/templates/editSuccess.php

    r9853 r9870  
     1<?php decorate_with('layoutB') ?>
     2<?php slot('op_sidemenu', get_component('diary', 'sidemenu', array('member' => $member))) ?>
     3
    14<?php
    25$options = array('form' => array($form));
     
    710include_box('formDiary', $title, '', $options);
    811?>
     12
     13<div id="formDiaryDelete" class="dparts box"><div class="parts">
     14<div class="partsHeading">
     15<h3><?php echo __('Delete this diary') ?></h3>
     16</div>
     17<div class="block">
     18<form action="<?php echo url_for('@diary_delete?id='.$diary->getId()) ?>" method="post">
     19<div class="operation">
     20<ul class="moreInfo button">
     21<li>
     22<input class="input_submit" type="submit" value="<?php echo __('Delete') ?>" />
     23</li>
     24</ul>
     25</div>
     26</form>
     27</div>
     28</div></div>
  • OpenPNE3/plugins/opDiaryPlugin/trunk/apps/pc_frontend/modules/diary/templates/listMemberSuccess.php

    r9853 r9870  
    11<?php use_helper('Date'); ?>
     2
     3<?php decorate_with('layoutB') ?>
     4<?php slot('op_sidemenu', get_component('diary', 'sidemenu', array('member' => $member))) ?>
    25
    36<div class="dparts recentList"><div class="parts">
  • OpenPNE3/plugins/opDiaryPlugin/trunk/apps/pc_frontend/modules/diary/templates/newSuccess.php

    r9853 r9870  
     1<?php decorate_with('layoutB') ?>
     2<?php slot('op_sidemenu', get_component('diary', 'sidemenu', array('member' => $member))) ?>
     3
    14<?php
    25$options = array('form' => array($form));
  • OpenPNE3/plugins/opDiaryPlugin/trunk/apps/pc_frontend/modules/diary/templates/showSuccess.php

    r9862 r9870  
    11<?php use_helper('Date') ?>
    22
     3<?php decorate_with('layoutB') ?>
     4<?php slot('op_sidemenu', get_component('diary', 'sidemenu', array('member' => $member))) ?>
     5
     6<?php /* {{{ diaryDetailBox */ ?>
    37<div class="dparts diaryDetailBox"><div class="parts">
    4 <div class="partsHeading"><h3><?php echo __('Diary of %1%', array('%1%' => $diary->getMember()->getName())) ?></h3>
     8<div class="partsHeading"><h3><?php echo __('Diary of %1%', array('%1%' => $member->getName())) ?></h3>
    59<p class="public">(<?php echo $diary->getPublicFlagLabel() ?>)</p></div>
    610<dl>
     
    1519<ul class="photo">
    1620<?php foreach ($images as $image): ?>
    17 <li><?php echo image_tag_sf_image($image->getFile(), array('size' => '120x120')) ?></li>
     21<li><a href="<?php echo sf_image_path($image->getFile()) ?>" target="_blank"><?php echo image_tag_sf_image($image->getFile(), array('size' => '120x120')) ?></a></li>
    1822<?php endforeach; ?>
    1923</ul>
     
    2327</dd>
    2428</dl>
     29<?php if ($diary->getMemberId() === $sf_user->getMemberId()): ?>
     30<div class="operation">
     31<form action="<?php echo url_for('diary_edit', $diary) ?>">
     32<ul class="moreInfo button">
     33<li><input type="submit" class="input_submit" value="<?php echo __('Edit this diary') ?>" /></li>
     34</ul>
     35</form>
     36</div>
     37<?php endif; ?>
    2538</div></div>
    26 
    27 <div class="parts">
    28 <?php if ($diary->getMemberId() === $sf_user->getMemberId()): ?>
    29 <ul>
    30 <li><?php echo link_to(__('Edit this diary'), 'diary_edit', $diary) ?></li>
    31 <li><form action="<?php echo url_for('diary_delete', $diary) ?>" method="post"><input type="submit" value="<?php echo __('Delete this diary') ?>" /></form></li>
    32 </ul>
    33 <?php endif; ?>
    34 </div>
     39<?php /* }}} */ ?>
    3540
    3641<?php $comments = $diary->getDiaryComments() ?>
    3742<?php if (count($comments)): ?>
    38 <div class="dparts"><div class="parts">
     43<?php /* {{{ commentList */ ?>
     44<div class="dparts commentList"><div class="parts">
    3945<div class="partsHeading"><h3><?php echo __('Comments') ?></h3></div>
    4046<?php foreach ($comments as $comment): ?>
    4147<dl>
    4248<dt><?php echo format_datetime($comment->getCreatedAt(), 'f') ?></dt>
    43 <dd><p><?php echo $comment->getMember()->getName() ?></p></dd>
     49<dd>
     50<div class="title">
     51<p class="heading"><strong><?php echo $comment->getNumber() ?></strong>:
     52<?php if ($_member = $comment->getMember()): ?> <?php echo link_to($_member->getName(), 'member/profile?id='.$_member->getId()) ?><?php endif; ?>
     53<?php if ($diary->getMemberId() === $sf_user->getMemberId() || $comment->getMemberId() === $sf_user->getMemberId()): ?>
     54 <?php echo link_to(__('Delete this comment'), 'diary_comment_delete', $comment) ?>
     55<?php endif; ?>
     56</p>
     57</div>
     58<div class="body">
    4459<?php $images = $comment->getDiaryCommentImages() ?>
    4560<?php if (count($images)): ?>
    46 <dd>
    4761<ul class="photo">
    4862<?php foreach ($images as $image): ?>
    49 <li><?php echo image_tag_sf_image($image->getFile(), array('size' => '120x120')) ?></li>
     63<li><a href="<?php echo sf_image_path($image->getFile()) ?>" target="_blank"><?php echo image_tag_sf_image($image->getFile(), array('size' => '120x120')) ?></a></li>
    5064<?php endforeach; ?>
    5165</ul>
     66<?php endif; ?>
     67<p class="text"><?php echo nl2br($comment->getBody()) ?></p>
     68</div>
    5269</dd>
    53 <?php endif; ?>
    54 <dd><p><?php echo nl2br($comment->getBody()) ?></p></dd>
    55 <?php if ($diary->getMemberId() === $sf_user->getMemberId() || $comment->getMemberId() === $sf_user->getMemberId()): ?>
    56 <dd><p><?php echo link_to(__('Delete this comment'), 'diary_comment_delete', $comment) ?></p></dd>
    57 <?php endif; ?>
    5870</dl>
    5971<?php endforeach; ?>
    6072</div></div>
     73<?php /* }}} */ ?>
    6174<?php endif; ?>
    6275
  • OpenPNE3/plugins/opDiaryPlugin/trunk/lib/action/opDiaryPluginActions.class.php

    r9860 r9870  
    1818      {
    1919        $this->diary = $object;
    20         $this->setNavigation($this->diary->getMemberId());
     20        $this->member = $this->diary->getMember();
    2121      }
    2222      elseif ($object instanceof DiaryComment)
     
    2424        $this->diaryComment = $object;
    2525        $this->diary = $this->diaryComment->getDiary();
    26         $this->setNavigation($this->diary->getMemberId());
     26        $this->member = $this->diary->getMember();
    2727      }
    2828      elseif ($object instanceof Member)
    2929      {
    3030        $this->member = $object;
    31         $this->setNavigation($this->member->getId());
    3231      }
    3332    }
    3433  }
    3534
    36   protected function setNavigation($memberId)
     35  public function postExecute()
    3736  {
    38     if ($memberId !== $this->getUser()->getMemberId())
     37    if (empty($this->member))
     38    {
     39      $this->member = $this->getUser()->getMember();
     40    }
     41
     42    $this->setNavigation($this->member);
     43  }
     44
     45  protected function setNavigation(Member $member)
     46  {
     47    if ($member->getId() !== $this->getUser()->getMemberId())
    3948    {
    4049      sfConfig::set('sf_navi_type', 'friend');
    41       sfConfig::set('sf_navi_id', $memberId);
     50      sfConfig::set('sf_navi_id', $member->getId());
    4251    }
    4352  }
  • OpenPNE3/plugins/opDiaryPlugin/trunk/web/css/diary.css

    r9559 r9870  
    66.diaryDetailBox .partsHeading,
    77.diaryDetailBox dl,
     8.commentList dl,
    89.recentList dl,
    910.formTable .partsHeading,
     
    1516.diaryDetailBox .partsHeading:after,
    1617.diaryDetailBox dl:after,
     18.commentList dl:after,
    1719.recentList dl:after,
    1820.formTable .partsHeading:after,
     
    191193
    192194/*==============================================================================
     195 * 22. commentList(コメントリスト)
     196 *----------------------------------------------------------------------------*/
     197.commentList dl
     198{
     199  border-top: 1px solid #CCCCCC;
     200}
     201.commentList dt
     202{
     203  float: left;
     204  width: 70px;
     205  padding-top: 5px;
     206  text-align: center;
     207}
     208.commentList dd
     209{
     210  zoom: 1;
     211  min-height: 5.5em;
     212  margin-left: 70px;
     213  border-left: 1px solid #CCCCCC;
     214}
     215* html .commentList dd
     216{
     217  height: 5.5em;
     218}
     219#LayoutC .commentList dt
     220{
     221  width: 110px;
     222}
     223#LayoutC .commentList dd
     224{
     225  margin-left: 110px;
     226}
     227.commentList dd div
     228{
     229  border-top: 1px solid #CCCCCC;
     230}
     231.commentList dd div p
     232{
     233  padding: 4px 3px;
     234}
     235.commentList dd div.title
     236{
     237  padding: 4px 3px;
     238  border-top: none;
     239}
     240.commentList dd div.title p
     241{
     242  padding: 0;
     243}
     244.commentList dd ul.photo
     245{
     246  padding: 5px 5px 0;
     247}
     248.commentList dd ul.photo li
     249{
     250  display: inline;
     251  margin-left: 6px;
     252}
     253.commentList dd div.footer p
     254{
     255  text-align: right;
     256}
     257.commentList div.operation
     258{
     259  padding: 8px 0;
     260}
     261.commentList dd div.attachFile
     262{
     263  padding: 16px 5px;
     264}
     265
     266/*==============================================================================
    193267 * 23. searchResultList(検索結果リスト)
    194268 *----------------------------------------------------------------------------*/
Note: See TracChangeset for help on using the changeset viewer.