本文整理汇总了PHP中Theme::make方法的典型用法代码示例。如果您正苦于以下问题:PHP Theme::make方法的具体用法?PHP Theme::make怎么用?PHP Theme::make使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Theme
的用法示例。
在下文中一共展示了Theme::make方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: poll
public static function poll($polls)
{
$polls = json_decode($polls);
$_results = array();
if (is_array($polls) && count($polls) > 0) {
foreach ($polls as $i => $_poll) {
switch ($_poll->type) {
case "template":
$_results[$_poll->id] = array('type' => 'html', 'args' => Theme::make($_poll->func, array('value' => $_poll->value))->render());
break;
case "plugin":
if ($_poll->func) {
$_results[$_poll->id] = call_user_func($_poll->func, $_poll->value);
}
break;
case "check_logs":
$list = Dashboard::activity();
Session::put('usersonline_lastcheck', time());
$_results[$_poll->id] = array('type' => 'function', 'func' => 'fnUpdateGrowler', 'args' => $list);
break;
}
}
}
return $_results;
}
示例2: postPolling
public function postPolling()
{
$polls = json_decode(Input::get('polls'));
$_results = array();
if (is_array($polls) && count($polls) > 0) {
foreach ($polls as $i => $_poll) {
switch ($_poll->type) {
case "plugin":
if ($_poll->func) {
$_results[$_poll->id] = call_user_func($_poll->func, $_poll->value);
}
break;
case "check_logs":
$list = Activity::whereRaw('UNIX_TIMESTAMP(`activity_log`.`created_at`) > ? AND (activity_log.content_type="notification" OR activity_log.content_type="login")', array(Session::get('usersonline_lastcheck', time())))->select(array('description', 'details', 'users.displayname', 'content_type'))->groupBy(DB::raw('description, details, users.displayname, content_type'))->orderBy('activity_log.id', 'DESC')->leftJoin('users', 'users.id', '=', 'activity_log.user_id')->get()->toArray();
Session::put('usersonline_lastcheck', time());
$_results[$_poll->id] = array('type' => 'function', 'func' => 'fnUpdateGrowler', 'args' => $list);
break;
case "users_online":
$_results[$_poll->id] = array('type' => 'html', 'args' => Theme::make('admin/helpers/users-online')->render());
break;
}
}
}
return Response::json($_results);
}
示例3: getEdit
/**
* Show the form for editing the specified resource.
*
* @param $post
* @return Response
*/
public function getEdit($autoreply)
{
$roles = Support::getRoles();
$deps = Support::getDeps();
$actions = Support::getActions();
$title = Lang::get('l4cp-support::core.autoreply_update');
return Theme::make('l4cp-support::autoreplys/create_edit', compact('autoreply', 'title', 'deps', 'actions', 'roles'));
}
示例4: getEdit
public function getEdit($role)
{
if (!empty($role)) {
$permissions = $this->permission->preparePermissionsForDisplay($role->perms()->get());
} else {
return Api::to(array('error', Lang::get('admin/roles/messages.does_not_exist'))) ?: Redirect::to('admin/roles')->with('error', Lang::get('admin/roles/messages.does_not_exist'));
}
return Theme::make('admin/roles/create_edit', compact('role', 'permissions'));
}
示例5: index
public function index()
{
list($user, $redirect) = $this->user->checkAuthAndRedirect('user');
if ($redirect) {
return $redirect;
}
$profiles = $user->profiles;
return Theme::make('site/user/index', compact('user', 'profiles'));
}
示例6: index
public function index()
{
$minigraph_data = array();
$minigraph_data['account_created'] = Dashboard::graph('account_created');
$minigraph_data['login'] = Dashboard::graph('login');
$minigraph_data['activity'] = Dashboard::graph('activity');
$minigraph_data['activity_unique'] = Dashboard::graph('activity', '5', true);
View::share('minigraph_data', $minigraph_data);
View::share('minigraph_json', json_encode($minigraph_data));
$widgets = Dashboard::widgets();
View::share('widgets', $widgets);
$results = Dashboard::online();
View::share('whosonline', $results);
Dashboard::googleGraph($minigraph_data);
return Theme::make('admin/dashboard/index');
}
示例7: emailmass
public function emailmass()
{
$ids = explode(',', rtrim(Input::get('ids'), ','));
$multi = array();
$selected = array();
if (is_array($ids) && count($ids) > 0) {
foreach ($ids as $id) {
$user = $this->user->find($id);
if (!empty($user)) {
$multi[$id] = $user->email;
$selected = $id;
}
}
}
$title = Lang::get('core.email');
$mode = 'edit';
$templates = LCP::emailTemplates();
return Theme::make('admin/users/send_email', compact('title', 'mode', 'multi', 'selected', 'templates'));
}
示例8: get
public function get()
{
$ids = explode(',', rtrim(Input::get('ids'), ','));
$mergefrom = '';
$mergelist = array();
if (is_array($ids) && count($ids) > 0) {
foreach ($ids as $id) {
$user = $this->user->find($id);
if (!empty($user)) {
if ($mergefrom) {
$mergelist[$id] = $user->email;
} else {
$mergefrom = $user->email;
}
}
}
}
return Theme::make('admin/users/confirm_merge', compact('mergelist', 'mergefrom'));
}
示例9: getEdit
public function getEdit($post)
{
$templates = $this->post->templates();
$parents = $this->post->parents();
return Theme::make('admin/blogs/create_edit', compact('post', 'templates', 'parents'));
}
示例10: getEdit
/**
* Show the form for editing the specified resource.
*
* @param $post
* @return Response
*/
public function getEdit($department)
{
$admins = Support::getAdmins();
$title = Lang::get('l4cp-support::core.department_update');
return Theme::make('l4cp-support::departments/create_edit', compact('department', 'title', 'admins'));
}
示例11: setupLayout
/**
* Setup the layout used by the controller.
*
* @return void
*/
protected function setupLayout()
{
if (!is_null($this->layout)) {
$this->layout = Theme::make($this->layout);
}
}
示例12: getIndex
public function getIndex($search)
{
$results = Search::Query($search);
return Theme::make('admin/search', compact('results'));
}
示例13: getEdit
public function getEdit($comment)
{
return Theme::make('admin/comments/edit', compact('comment'));
}
示例14: getContactUs
public function getContactUs()
{
return Theme::make('site/contact-us');
}
示例15: getEdit
/**
* Show the form for editing the specified resource.
*
* @param $map
* @return Response
*/
public function getEdit($map)
{
if (!empty($map)) {
$permissions = $this->permission->preparePermissionsForDisplay($map->perms()->get());
} else {
return Api::to(array('error', Lang::get('admin/maps/messages.does_not_exist'))) ?: Redirect::to('admin/maps')->with('error', Lang::get('admin/maps/messages.does_not_exist'));
}
$title = Lang::get('admin/maps/title.role_update');
return Theme::make('admin/maps/edit', compact('map', 'permissions', 'title'));
}