コード例 #1
0
ファイル: CommentController.php プロジェクト: IVsevolod/zouk
 public function actionAlarm()
 {
     $id = Yii::$app->request->post('id');
     $msg = Yii::$app->request->post('msg');
     $comment = Comment::findOne($id);
     if ($comment && !empty($msg)) {
         if (Alarm::addAlarm(Alarm::ENTITY_COMMENT, $comment->id, $msg)) {
             return json_encode(['content' => \frontend\widgets\CommentsWidget::widget(['entity' => $comment->entity, 'entity_id' => $comment->entity_id, 'showDialog' => false]), 'anchor' => $comment->id]);
         } else {
             return json_encode(['content' => '', 'anchor' => '']);
         }
     }
 }
コード例 #2
0
ファイル: view.php プロジェクト: IVsevolod/zouk
    echo Html::a(Lang::t('main', 'mainButtonAddRecord'), ['/list/add'], ['class' => 'btn btn-success btn-label-main add-item']);
}
?>
        </div>
    </div>

    <div class="row block-event block-event-comment hide">
        <div class="col-md-12">
            <div>
                <h3><?php 
echo Lang::t('page/eventView', 'titleComment');
?>
</h3>
                <div>
                    <?php 
echo \frontend\widgets\CommentsWidget::widget(['entity' => Comment::ENTITY_EVENT, 'entity_id' => $event->id]);
?>
                </div>
            </div>

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


<div class="modal fade modal-delete-confirm bs-example-modal-sm" tabindex="-1" role="dialog"
     aria-labelledby="mySmallModalLabel">
    <div class="modal-dialog modal-sm">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
コード例 #3
0
ファイル: view.php プロジェクト: IVsevolod/zouk
    echo Html::a(Lang::t('main', 'mainButtonAddRecord'), ['/list/add'], ['class' => 'btn btn-success btn-label-main add-item']);
}
?>
        </div>
    </div>

    <div class="row block-school-comment hide">
        <div class="col-md-12">
            <div>
                <h3><?php 
echo Lang::t('page/schoolView', 'titleComment');
?>
</h3>
                <div>
                    <?php 
echo \frontend\widgets\CommentsWidget::widget(['entity' => Comment::ENTITY_SCHOOL, 'entity_id' => $school->id]);
?>
                </div>
            </div>

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


<div class="modal fade modal-delete-confirm bs-example-modal-sm" tabindex="-1" role="dialog"
     aria-labelledby="mySmallModalLabel">
    <div class="modal-dialog modal-sm">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
コード例 #4
0
ファイル: view.php プロジェクト: IVsevolod/zouk
            </div>
        </div>
        <div class="share42init hide"></div>
    </div>
</div>
<div class="row">
    <hr/>
    <div class="col-md-12">
        <div>
            <h3><?php 
echo Lang::t('page/listView', 'titleComment');
?>
</h3>
            <div>
                <?php 
echo \frontend\widgets\CommentsWidget::widget(['entity' => Comment::ENTITY_ITEM, 'entity_id' => $item->id]);
?>
            </div>
        </div>
    </div>
</div>


<div class="modal fade modal-delete-confirm bs-example-modal-sm" tabindex="-1" role="dialog"
     aria-labelledby="mySmallModalLabel">
    <div class="modal-dialog modal-sm">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
                        aria-hidden="true">&times;</span></button>
                <h4 class="modal-title"><?php