Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
kohinos
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
9
Issues
9
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
cooperatic-mlc
kohinos
Commits
37824fac
Commit
37824fac
authored
Mar 14, 2019
by
Julien Jorry
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix for create list admin menu
parent
187549fb
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
30 additions
and
4 deletions
+30
-4
sonata_admin.yaml
config/packages/sonata_admin.yaml
+2
-1
services.yaml
config/services.yaml
+1
-0
GalleryAdmin.php
src/Admin/GalleryAdmin.php
+20
-0
MediaAdmin.php
src/Admin/MediaAdmin.php
+7
-3
No files found.
config/packages/sonata_admin.yaml
View file @
37824fac
...
@@ -178,7 +178,7 @@ sonata_admin:
...
@@ -178,7 +178,7 @@ sonata_admin:
items
:
items
:
-
route
:
adherent_create
-
route
:
adherent_create
label
:
Ajouter
label
:
Ajouter
-
admin.adherent.gerer
roles
:
[
'
ROLE_SUPER_ADMIN'
,
'
ROLE_ADMIN_ADHERENT_GERER_ALL'
,
'
ROLE_ADMIN_ADHERENT_GERER_CREATE'
]
-
admin.adherent.gerer
-
admin.adherent.gerer
-
admin.adherent.cotisations
-
admin.adherent.cotisations
sonata.admin.group.prestataire
:
sonata.admin.group.prestataire
:
...
@@ -189,6 +189,7 @@ sonata_admin:
...
@@ -189,6 +189,7 @@ sonata_admin:
items
:
items
:
-
route
:
prestataire_create
-
route
:
prestataire_create
label
:
Ajouter
label
:
Ajouter
roles
:
[
'
ROLE_SUPER_ADMIN'
,
'
ROLE_ADMIN_PRESTATAIRE_GERER_ALL'
,
'
ROLE_ADMIN_PRESTATAIRE_GERER_CREATE'
]
-
admin.prestataire.gerer
-
admin.prestataire.gerer
-
admin.prestataire.cotisations
-
admin.prestataire.cotisations
-
admin.groupepresta.gerer
-
admin.groupepresta.gerer
...
...
config/services.yaml
View file @
37824fac
...
@@ -8,6 +8,7 @@ parameters:
...
@@ -8,6 +8,7 @@ parameters:
locale
:
'
en'
locale
:
'
en'
sonata.user.admin.user.controller
:
'
App\Controller\CRUD\CRUDController'
sonata.user.admin.user.controller
:
'
App\Controller\CRUD\CRUDController'
sonata.media.admin.media.class
:
'
App\Admin\MediaAdmin'
sonata.media.admin.media.class
:
'
App\Admin\MediaAdmin'
sonata.media.admin.gallery.class
:
'
App\Admin\GalleryAdmin'
# PARAMETRES DE L'APPLICATION DE GESTION DE MONNAIE LOCALE COMPLEMENTAIRE
# PARAMETRES DE L'APPLICATION DE GESTION DE MONNAIE LOCALE COMPLEMENTAIRE
app.mlc_title
:
'
Outil
de
gestion
de
monnaie
locale
complémentaire'
# Nom complet (< 100 caractères)
app.mlc_title
:
'
Outil
de
gestion
de
monnaie
locale
complémentaire'
# Nom complet (< 100 caractères)
...
...
src/Admin/GalleryAdmin.php
0 → 100644
View file @
37824fac
<?php
namespace
App\Admin
;
use
Sonata\AdminBundle\Object\Metadata
;
use
Sonata\MediaBundle\Admin\GalleryAdmin
as
BaseGalleryAdmin
;
use
Sonata\MediaBundle\Provider\MediaProviderInterface
;
/**
* Administration des galleries de medias (image, document...)
*
* LOCO : Outil de gestion de Monnaie Locale Complémentaire
* @author Julien Jorry <julien.jorry@gmail.com>
*/
class
GalleryAdmin
extends
BaseGalleryAdmin
{
// public function getDashboardActions()
// {
// return [];
// }
}
src/Admin/MediaAdmin.php
View file @
37824fac
...
@@ -13,9 +13,6 @@ use Sonata\MediaBundle\Provider\MediaProviderInterface;
...
@@ -13,9 +13,6 @@ use Sonata\MediaBundle\Provider\MediaProviderInterface;
*/
*/
class
MediaAdmin
extends
BaseMediaAdmin
class
MediaAdmin
extends
BaseMediaAdmin
{
{
/**
* {@inheritdoc}
*/
public
function
getObjectMetadata
(
$object
)
public
function
getObjectMetadata
(
$object
)
{
{
$provider
=
$this
->
pool
->
getProvider
(
$object
->
getProviderName
());
$provider
=
$this
->
pool
->
getProvider
(
$object
->
getProviderName
());
...
@@ -27,4 +24,11 @@ class MediaAdmin extends BaseMediaAdmin
...
@@ -27,4 +24,11 @@ class MediaAdmin extends BaseMediaAdmin
return
new
Metadata
(
$object
->
getName
(),
$object
->
getDescription
(),
$url
);
return
new
Metadata
(
$object
->
getName
(),
$object
->
getDescription
(),
$url
);
}
}
// public function getDashboardActions()
// {
// // $actions = parent::getDashboardActions();
// // unset($actions['list']);
// return [];
// }
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment