1 |
www |
1 |
<?php
|
|
|
2 |
$acl = $this->viewModel()->getRoot()->getVariable('acl');
|
|
|
3 |
$currentUser = $this->currentUserHelper();
|
|
|
4 |
$roleName = $currentUser->getUserTypeId();
|
|
|
5 |
|
|
|
6 |
$routeAdd = $this->url('profile/my-profiles/add');
|
|
|
7 |
$routeMyProfiles = $this->url('profile/my-profiles');
|
|
|
8 |
|
|
|
9 |
$allowAdd = $acl->isAllowed($roleName, 'profile/my-profiles/add') ? 1 : 0;
|
|
|
10 |
$allowEdit = $acl->isAllowed($roleName, 'profile/my-profiles/edit') ? 1 : 0;
|
|
|
11 |
$allowDelete = $acl->isAllowed($roleName, 'profile/my-profiles/delete') ? 1 : 0;
|
|
|
12 |
|
|
|
13 |
$publicNo = \LeadersLinked\Model\UserProfile::PUBLIC_NO;
|
|
|
14 |
|
|
|
15 |
// $this->inlineScript()->captureStart();
|
|
|
16 |
$js = <<<JS
|
|
|
17 |
const backendVars = {
|
|
|
18 |
allowAdd : "$allowAdd",
|
|
|
19 |
allowEdit: "$allowEdit",
|
|
|
20 |
allowDelete: "$allowDelete"
|
|
|
21 |
}
|
5070 |
stevensc |
22 |
|
|
|
23 |
const LABELS = {
|
|
|
24 |
ADD: 'LABEL_ADD',
|
|
|
25 |
MY_PROFILES: 'LABEL_MY_PROFILES',
|
|
|
26 |
MESSAGE: 'LABEL_MESSAGE',
|
|
|
27 |
APPROVE: 'LABEL_APPROVE',
|
|
|
28 |
REJECT: 'LABEL_REJECT',
|
|
|
29 |
MESSAGE: 'LABEL_MESSAGE',
|
|
|
30 |
ADMINISTRATE: 'LABEL_ADMINISTRATE',
|
|
|
31 |
UNFOLLOW: 'LABEL_UNFOLLOW',
|
|
|
32 |
BLOCK: 'LABEL_BLOCK',
|
|
|
33 |
UNBLOCK: 'LABEL_UNBLOCK',
|
|
|
34 |
CONECT: 'LABEL_CONECT',
|
|
|
35 |
CANCEL: 'LABEL_CANCEL',
|
|
|
36 |
LEAVE: 'LABEL_LEAVE',
|
|
|
37 |
NEW_PROFILE: 'LABEL_NEW_PROFILE',
|
|
|
38 |
PROFILE_MAME: 'LABEL_PROFILE_MAME',
|
|
|
39 |
CREATE_PROFILE: 'LABEL_CREATE_PROFILE',
|
|
|
40 |
}
|
|
|
41 |
|
1 |
www |
42 |
JS;
|
5070 |
stevensc |
43 |
|
1 |
www |
44 |
$this->inlineScript()->appendScript($js);
|
3517 |
stevensc |
45 |
$this->headLink()->appendStylesheet('/look-and-field/profile.css');
|
1 |
www |
46 |
$this->inlineScript()->appendFile('/react-bundles/my-profiles/my-profiles/myProfilesBundle.js');
|
|
|
47 |
?>
|
|
|
48 |
|
|
|
49 |
<div id="react-my-profiles" class="posts-section">
|
|
|
50 |
<div class="process-comm" id="paginator-process-comm">
|
|
|
51 |
<div class="spinner">
|
|
|
52 |
<div class="bounce1"></div>
|
|
|
53 |
<div class="bounce2"></div>
|
|
|
54 |
<div class="bounce3"></div>
|
|
|
55 |
</div>
|
|
|
56 |
</div>
|
|
|
57 |
</div>
|