Esempio n. 1
0
<?php

$this->beginContent('application.modules_core.activity.views.activityLayout', array('activity' => $activity));
?>

<?php 
if ($workspace != null && Wall::$currentType != Wall::TYPE_SPACE) {
    ?>
    <?php 
    echo Yii::t('ActivityModule.views_activities_ActivitySpaceCreated', "%displayName% created the new space %spaceName%", array('%displayName%' => '<strong>' . $user->displayName . '</strong>', '%spaceName%' => '<strong>' . Helpers::truncateText($workspace->name, 25) . '</strong>'));
    ?>

<?php 
} else {
    ?>
    <?php 
    echo Yii::t('ActivityModule.views_activities_ActivitySpaceCreated', "%displayName% created this space.", array('%displayName%' => '<strong>' . $user->displayName . '</strong>'));
}
?>

<?php 
$this->endContent();
?>

Esempio n. 2
0
 /**
  * Returns a title/text which identifies this IContent.
  * e.g. Post: foo bar 123...
  *
  * @return String
  */
 public function getContentTitle()
 {
     return Yii::t('CommentModule.models_comment', 'Comment') . " \"" . Helpers::truncateText($this->message, 40) . "\"";
 }
Esempio n. 3
0
<?php

$this->beginContent('application.modules_core.activity.views.activityLayout', array('activity' => $activity));
?>

<?php 
if ($workspace != null && !Yii::app()->controller instanceof ContentContainerController) {
    ?>

<?php 
    if ($user->group_id == '2') {
        echo Yii::t('ActivityModule.views_activities_ActivitySpaceMemberAdded', "%displayName% joined the space %spaceName%", array('%displayName%' => '<strong>' . CHtml::encode($user->displayName) . '</strong>', '%spaceName%' => '<strong>' . CHtml::encode(Helpers::truncateText($workspace->name, 40)) . '</strong>'));
    } else {
        if ($user->group_id == '3') {
            echo Yii::t('ActivityModule.views_activities_ActivitySpaceMemberAdded', "%displayName% joined the space %spaceName%", array('%displayName%' => '<strong>' . CHtml::encode($user->profile->companyname . ' - ' . $user->displayName) . '</strong>', '%spaceName%' => '<strong>' . CHtml::encode(Helpers::truncateText($workspace->name, 40)) . '</strong>'));
        }
    }
    ?>

<?php 
} else {
    ?>
	
<?php 
    if ($user->group_id == '2') {
        echo Yii::t('ActivityModule.views_activities_ActivitySpaceMemberAdded', "%displayName% joined this space.", array('%displayName%' => '<strong>' . CHtml::encode($user->displayName) . '</strong>'));
    } else {
        if ($user->group_id == '3') {
            echo Yii::t('ActivityModule.views_activities_ActivitySpaceMemberAdded', "%displayName% joined this space.", array('%displayName%' => '<strong>' . CHtml::encode($user->profile->companyname . ' - ' . $user->displayName) . '</strong>'));
        }
    }
 /**
  * Returns a title/text which identifies this IContent.
  *
  * e.g. Post: foo bar 123...
  *
  * @return String
  */
 public function getContentTitle()
 {
     return Helpers::truncateText($this->post_title, 60);
 }
Esempio n. 5
0
 /**
  * Returns a title/text which identifies this IContent.
  * e.g. Post: foo bar 123...
  *
  * @return String
  */
 public function getContentTitle()
 {
     return "Comment \"" . Helpers::truncateText($this->message, 40) . "\"";
 }
Esempio n. 6
0
    echo $space->getProfileImage()->getUrl();
    ?>
">
                <!-- Show space image, if you are outside from a space -->
                <div class="media-body">
                    <!-- Show content -->
                    <strong><?php 
    echo $space->name;
    ?>
</strong>

                    <div id="space-badge-<?php 
    echo $count;
    ?>
" class="badge badge-space pull-right" style="display:none;">0</div>
                    <br>
                    <p><?php 
    echo Helpers::truncateText($space->description, 60);
    ?>
</p>
                </div>
            </div>
        </a>
    </li>
    <?php 
    $count++;
}
?>


                    <b><?php 
echo $stats['answers'];
?>
</b>
                    <p>answers</p>
                </div>
            </div>

            <div class="media-body" style="padding-top:5px; padding-left:5px;">
                <div class="content">
                    <b><?php 
echo CHtml::link(CHtml::encode($question->post_title), $question::model()->getUrl(array('id' => $question->id)));
?>
</b><br />
                    <?php 
echo CHtml::encode(Helpers::truncateText($question->post_text, 250));
?>
                    <?php 
echo CHtml::link("read more <i class=\"fa fa-share\"></i>", $question::model()->getUrl(array('id' => $question->id)));
?>
                </div>
            </div>
        </div>

        <?php 
$this->endContent();
?>

    </div>
</div>
 /**
  * Returns a title/text which identifies this IContent.
  * @return String
  */
 public function getContentTitle()
 {
     return Yii::t('LibraryModule.base', "Document") . " \"" . Helpers::truncateText($this->title, 25) . "\"";
 }
Esempio n. 9
0
">

        <div class="media">
            <img class="media-object img-rounded pull-left"
                 src="<?php 
echo $target->getProfileImage()->getUrl();
?>
" width="50"
                 height="50" alt="50x50" data-src="holder.js/50x50" style="width: 50px; height: 50px;">

            <?php 
if ($target->status == Space::STATUS_ARCHIVED) {
    echo '<div class="archive_icon34"></div>';
}
?>

            <div class="media-body">
                <strong><?php 
echo $target->name;
?>
 </strong><br>

                <span class="content"><?php 
echo Helpers::truncateText($post->message, 200);
?>
</span>

            </div>
        </div>
    </a>
</li>
Esempio n. 10
0
 /**
  * Get wall title.
  */
 public function getWallTitle()
 {
     return 'album <b>' . Helpers::truncateText($this->name, 25) . '</b>';
 }
<?php

$this->beginContent('application.modules_core.activity.views.activityLayoutMail', array('activity' => $activity, 'showSpace' => false));
?>

<?php 
echo Yii::t('ActivityModule.views_activities_ActivitySpaceMemberAdded', "%displayName% joined the space %spaceName%", array('%displayName%' => '<strong>' . $user->displayName . '</strong>', '%spaceName%' => '<strong>' . Helpers::truncateText($workspace->name, 40) . '</strong>'));
?>
<br/>

<?php 
$this->endContent();
?>

    ?>
</b>
                                <p>answers</p>
                            </div>

                        </div>

                        <div class="media-body" style="padding-top:5px; padding-left:10px;">
                            <h4 class="media-heading">
                                <?php 
    echo CHtml::link(CHtml::encode($question['post_title']), Yii::app()->createUrl('//questionanswer/main/view', array('id' => $question['id'])));
    ?>
                            </h4>

                            <h5><?php 
    echo CHtml::encode(Helpers::truncateText($question['post_text'], 200));
    ?>
</h5>
                        </div>
                    </div>
                <?php 
}
?>

                </div>
            </div>
        </div>

        <div class="col-md-3">
            <div class="panel panel-default">
                <div class="panel-heading"><strong>Related</strong> Questions</div>
Esempio n. 13
0
 /**
  * Returns a title/text which identifies this IContent.
  *
  * e.g. Wiki: Page title...
  *
  * @return String
  */
 public function getContentTitle()
 {
     return Yii::t('WikiModule.models_WikiPage', "Wiki page") . " \"" . Helpers::truncateText($this->title, 25) . "\"";
 }
?>
">
                <div class="profile-overlay-img profile-overlay-img-sm"></div>
            </span>
            
            <div class="media-body">
                <h4 class="media-heading"><?php 
echo CHtml::encode($message->getLastEntry()->user->displayName);
?>
 <small><?php 
echo HHtml::timeago($message->updated_at);
?>
</small></h4>
                <h5><?php 
print CHtml::encode(Helpers::truncateText($message->title, 75));
?>
</h5>
                <?php 
echo Helpers::truncateText(HMarkdownPreview::Render($message->getLastEntry()->content), 200);
?>
                <?php 
// show the new badge, if this message is still unread
if ($message->updated_at > $userMessage->last_viewed and $message->getLastEntry()->user->id != Yii::app()->user->id) {
    echo '<span class="label label-danger">' . Yii::t('MailModule.views_mail_index', 'New') . '</span>';
}
?>
            </div>
        </div>
    </a>
</li>
<?php

$this->beginContent('application.modules_core.activity.views.activityLayout', array('activity' => $activity));
echo Yii::t('PollsModule.views_activities_PollCreated', '{userName} created a new {question}.', array('{userName}' => '<strong>' . $user->displayName . '</strong>', '{question}' => Helpers::truncateText($target['body'], 25)));
$this->endContent();
?>


Esempio n. 16
0
 /**
  * Returns a title/text which identifies this IContent.
  *
  * e.g. Post: foo bar 123...
  *
  * @return String
  */
 public function getContentTitle()
 {
     return Yii::t('PostModule.models_Post', 'Post') . " \"" . Helpers::truncateText(CHtml::encode($this->message), 25) . "\"";
 }
Esempio n. 17
0
    echo CHtml::encode($membership->room->name);
    ?>
</strong>
                    <?php 
    if ($newItems != 0) {
        ?>
                        <div class="badge badge-space pull-right" style="display:none"><?php 
        echo $newItems;
        ?>
</div>
                    <?php 
    }
    ?>
                    <br>
                    <p><?php 
    echo CHtml::encode(Helpers::truncateText($membership->room->description, 60));
    ?>
</p>
                </div>
            </div>
        </a>
    </li>
<?php 
}
?>
<script>
    jQuery('.badge-space').fadeIn('slow');
</script>


Esempio n. 18
0
    echo $space->getProfileImage()->getUrl();
    ?>
">
                <!-- Show space image, if you are outside from a space -->
                <div class="media-body">
                    <!-- Show content -->
                    <strong><?php 
    echo CHtml::encode($space->name);
    ?>
</strong>

                    <div id="space-badge-<?php 
    echo $count;
    ?>
" class="badge badge-space pull-right" style="display:none;">0</div>
                    <br>
                    <p><?php 
    echo CHtml::encode(Helpers::truncateText($space->description, 60));
    ?>
</p>
                </div>
            </div>
        </a>
    </li>
    <?php 
    $count++;
}
?>


<?php

/**
 * This View shows a post inside the search
 *
 * @property Post $post is the post object
 *
 * @package humhub.modules.post
 * @since 0.5
 */
?>
<li>
    <a href="<?php 
echo $this->createUrl('//questionanswer/question/view', array('id' => $question['id']));
?>
">
        <div class="media">
            <div class="media-body">
                <strong><?php 
echo CHtml::encode($question['post_title']);
?>
 </strong><br>
                <span class="content" style="border-left:2px solid #ccc; padding-top:2px; padding-bottom:2px; padding-left:5px; margin-left: 5px;"><?php 
echo CHtml::encode(Helpers::truncateText($answer->post_text, 150));
?>
</span>
                <br />
            </div>
        </div>
    </a>
</li>
Esempio n. 20
0
 /**
  * Returns a title/text which identifies this IContent.
  *
  * e.g. Post: foo bar 123...
  *
  * @return String
  */
 public function getContentTitle()
 {
     return Yii::t('PollsModule.models_Poll', "Question") . " \"" . Helpers::truncateText($this->body, 25) . "\"";
 }
            <b><?php 
echo $stats['score'];
?>
</b>
            <p>votes</p>
        </div>
        <div class="pull-left" style="text-align:center; margin-top:5px;">
            <b><?php 
echo $stats['answers'];
?>
</b>
            <p>answers</p>
        </div>

    </div>

    <div class="media-body" style="padding-top:5px; padding-left:10px;">
        <h4 class="media-heading">
        	<?php 
echo CHtml::link(CHtml::encode($data->post_title), array('view', 'id' => $data->id));
?>
        </h4>

        <h5><?php 
echo CHtml::encode(Helpers::truncateText($data->post_text, 200));
?>
</h5>
    </div>
</div>

<?php

$this->beginContent('application.modules_core.activity.views.activityLayoutMail', array('activity' => $activity, 'showSpace' => false));
?>

<?php 
echo Yii::t('ActivityModule.views_activities_ActivitySpaceMemberRemoved', "%displayName% left the space %spaceName%", array('%displayName%' => '<strong>' . CHtml::encode($user->displayName) . '</strong>', '%spaceName%' => '<strong>' . CHtml::encode(Helpers::truncateText($workspace->name, 40)) . '</strong>'));
?>
<br/>

<?php 
$this->endContent();
?>

Esempio n. 23
0
">

        <div class="media">
            <img class="media-object img-rounded pull-left"
                 src="<?php 
echo $target->getProfileImage()->getUrl();
?>
" width="50"
                 height="50" alt="50x50" data-src="holder.js/50x50" style="width: 50px; height: 50px;">

            <?php 
if ($target->status == Space::STATUS_ARCHIVED) {
    echo '<div class="archive_icon34"></div>';
}
?>

            <div class="media-body">
                <strong><?php 
echo CHtml::encode($target->name);
?>
 </strong><br>

                <span class="content"><?php 
echo CHtml::encode(Helpers::truncateText($post->message, 200));
?>
</span>

            </div>
        </div>
    </a>
</li>