本文整理匯總了PHP中app\models\Activity::getUserActivities方法的典型用法代碼示例。如果您正苦於以下問題:PHP Activity::getUserActivities方法的具體用法?PHP Activity::getUserActivities怎麽用?PHP Activity::getUserActivities使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類app\models\Activity
的用法示例。
在下文中一共展示了Activity::getUserActivities方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1:
<?php
use app\models\HealthState;
use app\models\Activity;
use app\models\User;
$this->registerCssFile('@web/css/account/mypage.css');
$this->registerCssFile('@web/css/activity/activity.css');
$session = yii::$app->session;
$thisuser = $session['user'];
//用戶
$nowHealth = HealthState::getUserLatestHealth($thisuser['id']);
//當前健康狀態
$attendActivities = Activity::getUserActivities($thisuser['id']);
$releaseActivities = Activity::getUserReleaseActivity($thisuser['id']);
?>
<div class="container">
<div class="row">
<div class="col-sm-3">
<div class="my_info">
<div class="portrait">
<img alt="頭像" src="image/mypage/portrait.png">
</div>
<h3 id="username"><?php
echo $thisuser['username'];
?>
</h3>
</div>
<div class="sidenav list-group">
<button type="button" id="health_manage_bar" class="list-group-item active" onclick="clickBar(this)">
健康管理
</button>