-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCCDNUserProfileBundle.php
95 lines (90 loc) · 4.73 KB
/
CCDNUserProfileBundle.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
<?php
/*
* This file is part of the CCDNUser ProfileBundle
*
* (c) CCDN (c) CodeConsortium <http://www.codeconsortium.com/>
*
* Available on github <http://www.github.com/codeconsortium/>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace CCDNUser\ProfileBundle;
use Symfony\Component\HttpKernel\Bundle\Bundle;
/**
*
* @category CCDNUser
* @package ProfileBundle
*
* @author Reece Fowell <reece@codeconsortium.com>
* @license http://opensource.org/licenses/MIT MIT
* @version Release: 1.0
* @link https://github.com/codeconsortium/CCDNUserProfileBundle
*
*/
class CCDNUserProfileBundle extends Bundle
{
/**
*
* @access public
*/
public function boot()
{
$twig = $this->container->get('twig');
$twig->addGlobal(
'ccdn_user_profile',
array(
'seo' => array(
'title_length' => $this->container->getParameter('ccdn_user_profile.seo.title_length'),
),
'member' => array(
'list' => array(
'layout_template' => $this->container->getParameter('ccdn_user_profile.member.list.layout_template'),
'members_per_page' => $this->container->getParameter('ccdn_user_profile.member.list.members_per_page'),
'member_since_datetime_format' => $this->container->getParameter('ccdn_user_profile.member.list.member_since_datetime_format'),
'requires_login' => $this->container->getParameter('ccdn_user_profile.member.list.requires_login'),
),
),
'profile' => array(
'fallback_avatar' => $this->container->getParameter('ccdn_user_profile.profile.fallback_avatar'),
'show' => array(
'bio' => array(
'layout_template' => $this->container->getParameter('ccdn_user_profile.profile.show.bio.layout_template'),
),
'overview' => array(
'layout_template' => $this->container->getParameter('ccdn_user_profile.profile.show.overview.layout_template'),
'last_login_datetime_format' => $this->container->getParameter('ccdn_user_profile.profile.show.overview.last_login_datetime_format'),
'member_since_datetime_format' => $this->container->getParameter('ccdn_user_profile.profile.show.overview.member_since_datetime_format'),
),
),
'edit' => array(
'personal' => array(
'layout_template' => $this->container->getParameter('ccdn_user_profile.profile.edit.personal.layout_template'),
'form_theme' => $this->container->getParameter('ccdn_user_profile.profile.edit.personal.form_theme'),
),
'avatar' => array(
'layout_template' => $this->container->getParameter('ccdn_user_profile.profile.edit.avatar.layout_template'),
'form_theme' => $this->container->getParameter('ccdn_user_profile.profile.edit.avatar.form_theme'),
),
'info' => array(
'layout_template' => $this->container->getParameter('ccdn_user_profile.profile.edit.info.layout_template'),
'form_theme' => $this->container->getParameter('ccdn_user_profile.profile.edit.info.form_theme'),
),
'bio' => array(
'layout_template' => $this->container->getParameter('ccdn_user_profile.profile.edit.bio.layout_template'),
'form_theme' => $this->container->getParameter('ccdn_user_profile.profile.edit.bio.form_theme'),
),
'contact' => array(
'layout_template' => $this->container->getParameter('ccdn_user_profile.profile.edit.contact.layout_template'),
'form_theme' => $this->container->getParameter('ccdn_user_profile.profile.edit.contact.form_theme'),
),
'signature' => array(
'layout_template' => $this->container->getParameter('ccdn_user_profile.profile.edit.signature.layout_template'),
'form_theme' => $this->container->getParameter('ccdn_user_profile.profile.edit.signature.form_theme'),
),
),
),
)
); // End Twig Globals.
}
}