当前位置: 首页>>代码示例>>PHP>>正文


PHP Datagrid\ListMapper类代码示例

本文整理汇总了PHP中Sonata\AdminBundle\Datagrid\ListMapper的典型用法代码示例。如果您正苦于以下问题:PHP ListMapper类的具体用法?PHP ListMapper怎么用?PHP ListMapper使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了ListMapper类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: configureListFields

 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->addIdentifier('id');
     $listMapper->add('type.name');
     $listMapper->add('year.year');
     $listMapper->add('comment');
 }
开发者ID:colinbleach,项目名称:JamJar,代码行数:7,代码来源:JamJarAdmin.php

示例2: configureListFields

 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->addIdentifier('id')->add('username')->add('email')->add('lastIp')->add('location')->add('groups')->add('_action', 'actions', array('actions' => array('edit' => array(), 'delete' => array()), "label" => 'actions'));
     if ($this->isGranted('ROLE_ALLOWED_TO_SWITCH')) {
         $listMapper->add('impersonating', 'string', array('template' => 'SonataAdminBundle:Admin:Field/impersonating.html.twig'));
     }
 }
开发者ID:c4d3r,项目名称:mcsuite-application-eyeofender,代码行数:7,代码来源:UserAdmin.php

示例3: configureListFields

 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper
         ->addIdentifier('id', 'text')
         ->addIdentifier('title', 'text')
     ;
 }
开发者ID:xxspartan16,项目名称:BMS-Market,代码行数:7,代码来源:StaticContentAdmin.php

示例4: configureListFields

 /**
  * Список
  *
  * @param ListMapper $listMapper
  */
 protected function configureListFields(ListMapper $listMapper)
 {
     if ($this->useModel()) {
         $listMapper->add('Model')->add('ObjectId')->add('Locale');
     }
     $listMapper->add('OldUrlShort', null, array('label' => 'Старый адрес'))->add('NewUrlShort', null, array('label' => 'Новый адрес'))->add('_action', 'actions', array('actions' => array('edit' => array(), 'delete' => array())));
 }
开发者ID:it-blaster,项目名称:redirect-bundle,代码行数:12,代码来源:RedirectAdmin.php

示例5: configureListFields

 /**
  * {@inheritdoc}
  */
 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->addIdentifier('username')->add('email')->add('groups')->add('enabled', null, array('editable' => true))->add('locked', null, array('editable' => true))->add('createdAt');
     if ($this->isGranted('ROLE_ALLOWED_TO_SWITCH')) {
         $listMapper->add('impersonating');
     }
 }
开发者ID:lyssal,项目名称:utilisateur-bundle,代码行数:10,代码来源:UtilisateurAdmin.php

示例6: configureListFields

 /**
  * @param \Sonata\AdminBundle\Datagrid\ListMapper $list
  */
 public function configureListFields(ListMapper $list)
 {
     if (!$this->isChild()) {
         $list->addIdentifier('id')->addIdentifier('product', null, array('admin_code' => 'sonata.product.admin.product'));
     }
     $list->addIdentifier('code')->add('enabled')->add('perItem')->add('countryCode')->add('zone');
 }
开发者ID:sonata-project,项目名称:ecommerce,代码行数:10,代码来源:DeliveryAdmin.php

示例7: configureListFields

 /**
  * {@inheritdoc}
  */
 public function configureListFields(ListMapper $list)
 {
     if (!$this->isChild()) {
         $list->addIdentifier('id')->addIdentifier('product', null, array('admin_code' => 'sonata.product.admin.product'));
     }
     $list->addIdentifier('category');
 }
开发者ID:johnulist,项目名称:ecommerce-1,代码行数:10,代码来源:ProductCategoryAdmin.php

示例8: configureListFields

 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->addIdentifier('username')->add('email')->add('groups')->add('facebookName', array(), array('label' => 'Fb Name'))->add('gender', array(), array('label' => 'Gender'))->add('locale', array(), array('label' => 'Language'))->add('biography', array(), array('label' => 'Biography'))->add('enabled', null, array('editable' => true));
     if ($this->isGranted('ROLE_ALLOWED_TO_SWITCH')) {
         $listMapper->add('impersonating', 'string', array('template' => 'SonataUserBundle:Admin:Field/impersonating.html.twig'));
     }
 }
开发者ID:manudatta12,项目名称:POC,代码行数:7,代码来源:UserAdmin.php

示例9: configureListFields

 /**
  * {@inheritdoc}
  */
 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->addIdentifier('username')->add('email')->add('groups')->add('enabled', null, array('editable' => true))->add('locked', null, array('editable' => true))->add('createdAt');
     if ($this->isGranted('ROLE_ALLOWED_TO_SWITCH')) {
         $listMapper->add('impersonating', 'string', array('template' => 'SonataUserBundle:Admin:Field/impersonating.html.twig'));
     }
 }
开发者ID:PartFire,项目名称:SonataUserBundle,代码行数:10,代码来源:UserAdmin.php

示例10: configureListFields

 /**
  * {@inheritdoc}
  */
 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->addIdentifier('username')->add('email', null, array('footable' => array('attr' => array('data-breakpoints' => array('xs', 'sm')))))->add('enabled', null, array('editable' => true, 'footable' => array('attr' => array('data-breakpoints' => array('xs')))))->add('locked', null, array('editable' => true, 'footable' => array('attr' => array('data-breakpoints' => array('xs')))))->add('createdAt', null, array('footable' => array('attr' => array('data-breakpoints' => array('xs', 'sm', 'md')))));
     if ($this->isGranted('ROLE_ALLOWED_TO_SWITCH')) {
         $listMapper->add('impersonating', 'string', array('template' => 'BrueryUserBundle:Admin:Field/impersonating.html.twig', 'footable' => array('attr' => array('data-breakpoints' => array('all')))));
     }
 }
开发者ID:bruery,项目名称:platform,代码行数:10,代码来源:UserAdmin.php

示例11: configureListFields

 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->addIdentifier('id')->add('getPeriod', null, array('format' => 'M. Y'));
     if (!$listMapper->getAdmin()->isChild()) {
         $listMapper->addIdentifier('employee');
     }
     $listMapper->add('getPayoff')->add('createdAt')->add('_action', 'actions', array('actions' => array('show' => array(), 'edit' => array(), 'print' => array('template' => 'CRUD/list__action_print.html.twig'))));
 }
开发者ID:Nexotap,项目名称:Ivory,代码行数:8,代码来源:PayrollAdmin.php

示例12: configureListFields

 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->addIdentifier('id')->add('startDate', null, array('label' => 'first_day', 'format' => 'd. M. Y'))->add('endDate', null, array('label' => 'last_day', 'format' => 'd. M. Y'));
     if (!$listMapper->getAdmin()->isChild()) {
         $listMapper->addIdentifier('employee');
     }
     $listMapper->add('days', null, array('label' => 'days'))->add('stateName', null, array('template' => 'CRUD/list_string_translated.html.twig'))->add('comment')->add('createdAt')->add('_action', 'actions', array('actions' => array('show' => array(), 'edit' => array(), 'print' => array('template' => 'CRUD/list__action_print.html.twig'))));
 }
开发者ID:Nexotap,项目名称:Ivory,代码行数:8,代码来源:VacationAdmin.php

示例13: configureListFields

 /**
  * {@inheritdoc}
  */
 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->addIdentifier('id');
     if (interface_exists('Sonata\\ClassificationBundle\\Model\\CategoryInterface')) {
         $listMapper->add('category');
     }
     $listMapper->add('permalink', 'text')->add('numComments')->add('isCommentable', 'boolean', array('editable' => true));
 }
开发者ID:saberyounis,项目名称:Sonata-Project,代码行数:11,代码来源:ThreadAdmin.php

示例14: configureListFields

 protected function configureListFields(ListMapper $listMapper)
 {
     if (!$this->hasParentFieldDescription()) {
         // this Admin is not embedded
         $listMapper->add('saleOrder');
     }
     $listMapper->addIdentifier('productNumber', null, array('label' => 'product_number'))->add('shortName', null, array('label' => 'name'))->add('basePrice', null, array('label' => 'base_price'))->add('_action', 'actions', array('actions' => array('edit' => array())));
 }
开发者ID:Nexotap,项目名称:Ivory,代码行数:8,代码来源:SaleOrderLineAdmin.php

示例15: configureListFields

 /**
  * @param ListMapper $listMapper
  */
 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->add('aliasShort', null, array('sortable' => false));
     foreach ($this->getConfigurationPool()->getContainer()->getParameter('it_blaster_translation.locales') as $locale) {
         $listMapper->add('title' . $locale, null, array('label' => $locale, 'sortable' => false, 'editable' => true));
     }
     $listMapper->add('_action', 'actions', array('label' => 'Редактирование', 'actions' => array('edit' => array(), 'delete' => array())));
 }
开发者ID:it-blaster,项目名称:translation-bundle,代码行数:11,代码来源:TranslationAdmin.php


注:本文中的Sonata\AdminBundle\Datagrid\ListMapper类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。