File indexing completed on 2024-12-29 05:24:38
0001 <?php 0002 /** 0003 * ocs-webserver 0004 * 0005 * Copyright 2016 by pling GmbH. 0006 * 0007 * This file is part of ocs-webserver. 0008 * 0009 * This program is free software: you can redistribute it and/or modify 0010 * it under the terms of the GNU Affero General Public License as 0011 * published by the Free Software Foundation, either version 3 of the 0012 * License, or (at your option) any later version. 0013 * 0014 * This program is distributed in the hope that it will be useful, 0015 * but WITHOUT ANY WARRANTY; without even the implied warranty of 0016 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 0017 * GNU Affero General Public License for more details. 0018 * 0019 * You should have received a copy of the GNU Affero General Public License 0020 * along with this program. If not, see <http://www.gnu.org/licenses/>. 0021 **/ 0022 0023 $helperHumanTiming = new Default_View_Helper_HumanTiming(); 0024 $helperBuildMemberUrl = new Default_View_Helper_BuildMemberUrl(); 0025 $helperBuildBaseUrl = new Default_View_Helper_BuildBaseUrl(); 0026 $helperUserIsOwner = new Default_View_Helper_UserIsOwner(); 0027 $helperImage = new Default_View_Helper_Image(); 0028 $comment = $this->comment; 0029 $marginLeft = $this->marginLeft; 0030 $age = $helperHumanTiming->humanTiming($comment['comment_created_at']); 0031 ?><div class="comment-row" style="margin-left: <?php echo $marginLeft?>px;"> 0032 <div class="comment well background-white"> 0033 <div class="row"> 0034 <div class="col-md-9 col-lg-9 col-sm-9 col-xs-9"> 0035 <span class="name"> 0036 by <a href="<?= $helperBuildMemberUrl->buildMemberUrl($comment['username']) ?>"><?php echo $comment['username']; ?></a></span> 0037 on: <span class="small lightgrey"> <?= $age['age'] ?> <span class="light"><?= $age['unit'] ?> ago</span> </span> 0038 </div> 0039 <div class="col-md-3 col-lg-3 col-sm-3 col-xs-3"> 0040 <figure class="well relative row" style="width:150px;padding:0;margin-bottom: 0;"> 0041 <div class="col-md-5 col-lg-5 col-sm-5 col-xs-5 product-maker-thumbnail relative"> 0042 <a title="<?= $comment['username'] ?>" href="<?= $helperBuildMemberUrl->buildMemberUrl($comment['username']) ?>"> 0043 <div class="profile-image-overlay-4 absolute"></div> 0044 <img width="40" 0045 height="40" 0046 alt="<?= $comment['username'] ?>" 0047 src="<?= $helperImage->Image($comment['profile_image_url'], array('width' => 40, 'height' => 40)) ?>"> 0048 </a> 0049 </div> 0050 <div class="col-md-7 col-lg-7 col-sm-7 col-xs-7 product-maker-summary"> 0051 <h6> 0052 <a href="<?= $helperBuildMemberUrl->buildMemberUrl($comment['username']) ?>" class="small"><?= $comment['username'] ?></a> 0053 </h6> 0054 </div> 0055 </figure> 0056 </div> 0057 </div> 0058 <div class="comment-content"> 0059 <div class="popover-content"> 0060 <p><?= Default_Model_HtmlPurify::purify($comment['comment_text']) ?></p> 0061 </div> 0062 <?php if (Zend_Auth::getInstance()->hasIdentity()) { 0063 $identity = Zend_Auth::getInstance()->getStorage()->read(); 0064 ?> 0065 <a class="btn btn-native small show-maker-reply" style="padding: 4px;">Reply to this</a> 0066 <div class="popover-content maker-comment-container maker-form well" style="display:none;"> 0067 <div class="row"> 0068 <div class="col-md-11 col-lg-11 col-sm-11 col-xs-11"> 0069 <figure class="supporter-thumbnail relative"> 0070 <a href="<?= $helperBuildMemberUrl->buildMemberUrl($identity->username) ?>" 0071 title="<?= $identity->username ?>"> 0072 <img height="40" width="40" src="<?= $helperImage->Image($identity->profile_image_url,array('width' => 40, 'height' => 40, 'crop' => 2)); ?>" 0073 alt="<?= $identity->username ?>"> 0074 </a> 0075 </figure> 0076 </div> 0077 <div class="col-md-1 col-lg-1 col-sm-1 col-xs-1"> 0078 <span class="glyphicon glyphicon-remove pull-right"></span> 0079 </div> 0080 </div> 0081 0082 <div class="maker-comment comment-content"> 0083 <div class="popover-content"> 0084 <form class="full-width" action="<?= $helperBuildBaseUrl->buildBaseUrl('productcomment/addreply') ?>"> 0085 <input type="hidden" name="i" value="<?= $comment['comment_id'] ?>"> 0086 <input type="hidden" name="p" value="<?= $comment['comment_target_id'] ?>"> 0087 <input type="hidden" name="m" value="<?= $identity->member_id ?>"> 0088 <textarea name="msg" class="full-width"></textarea> 0089 <input type="submit" 0090 class="btn btn-native small" 0091 style="padding:5px;margin-top:5px;" 0092 value="Send"/> 0093 </form> 0094 </div> 0095 </div> 0096 </div> 0097 <?php } ?> 0098 </div> 0099 </div> 0100 </div>