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


PHP ListMapper::add方法代码示例

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


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

示例1: 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

示例2: 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

示例3: configureListFields

 /**
  * {@inheritdoc}
  */
 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->addIdentifier('username')->add('email')->add('groups')->add('enabled', null, array('editable' => true));
     if ($this->isGranted('ROLE_ALLOWED_TO_SWITCH')) {
         $listMapper->add('impersonating', 'string', array('template' => 'NetworkingInitCmsBundle:Admin:Field/impersonating.html.twig'));
     }
     $listMapper->add('_action', 'actions', array('label' => ' ', 'actions' => array('edit' => array(), 'delete' => array())));
 }
开发者ID:lzdv,项目名称:init-cms-bundle,代码行数:11,代码来源:UserAdmin.php

示例4: 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

示例5: 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

示例6: configureListFields

 /**
  * {@inheritdoc}
  */
 public function configureListFields(ListMapper $list)
 {
     $list->addIdentifier('id');
     if (!$list->getAdmin()->isChild()) {
         $list->add('order');
     }
     $list->add('productType')->add('getStatusName', 'trans', array('name' => 'status', 'catalogue' => 'SonataOrderBundle', 'sortable' => 'status'))->add('getDeliveryStatusName', 'trans', array('name' => 'deliveryStatus', 'catalogue' => 'SonataOrderBundle', 'sortable' => 'deliveryStatus'))->add('getTotalWithVat', 'currency', array('currency' => $this->currencyDetector->getCurrency()->getLabel()))->add('getTotal', 'currency', array('currency' => $this->currencyDetector->getCurrency()->getLabel()));
 }
开发者ID:johnulist,项目名称:ecommerce-1,代码行数:11,代码来源:OrderElementAdmin.php

示例7: configureListFields

 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->addIdentifier('title', null, array('label' => 'Заголовок'));
     $listMapper->add('description', null, array('label' => 'Описание'));
     $listMapper->add('content', null, array('label' => 'Содержание'));
     $listMapper->add('createdAt', null, array('label' => 'Дата создания'));
     $listMapper->add('updatedAt', null, array('label' => 'Дата обновления'));
 }
开发者ID:svintuskbd,项目名称:symfony,代码行数:8,代码来源:PostAdmin.php

示例8: configureListFields

 /**
  * {@inheritdoc}
  */
 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->addIdentifier('name')->add('getStatusCode', 'text', array('label' => 'status_code', 'sortable' => 'status'));
     if (!$this->isChild()) {
         $listMapper->add('post');
     }
     $listMapper->add('email')->add('url')->add('message');
 }
开发者ID:BookWorld1,项目名称:nom,代码行数:11,代码来源:CommentAdmin.php

示例9: configureListFields

 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->addIdentifier('title', null, array('label' => 'Заголовок'))->add('draft');
     $listMapper->add('description', null, array('label' => 'Описание'));
     $listMapper->add('createdAt', null, array('label' => 'Дата создания'));
     $listMapper->add('updatedAt', null, array('label' => 'Дата обновления'));
     $listMapper->add('category', null, array('label' => 'Связанная категория'));
     $listMapper->add('slug', null, array('label' => 'Ссылка'));
 }
开发者ID:svintuskbd,项目名称:symfony,代码行数:9,代码来源:ArticleAdmin.php

示例10: configureListFields

 protected function configureListFields(ListMapper $listMapper)
 {
     $locales = $this->container->getParameter('ao_translation.locales');
     $listMapper->addIdentifier('id')->add('domain')->add('identification');
     foreach ($locales as $locale => $label) {
         $listMapper->add($locale, null, array('template' => 'AOTranslationBundle:MessageAdmin:translation.html.twig', 'label' => $label, 'code' => 'getLocaleTranslation', 'parameters' => array($locale)));
     }
     $listMapper->add('_action', 'actions', array('actions' => array('edit' => array(), 'delete' => array())));
 }
开发者ID:kminh,项目名称:AOTranslationBundle,代码行数:9,代码来源:MessageAdmin.php

示例11: configureListFields

 protected function configureListFields(ListMapper $mapper)
 {
     $mapper->addIdentifier('id', null, array('route' => array('name' => 'show')));
     $mapper->add('action');
     $mapper->add('objectId');
     $mapper->add('objectClass');
     $mapper->add('changeAt');
     $mapper->add('username');
 }
开发者ID:fcpauldiaz,项目名称:IbrowsLoggableBundle,代码行数:9,代码来源:ChangeSetAdmin.php

示例12: configureListFields

 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->addIdentifier('id');
     $listMapper->add('team1', 'sonata_type_model', array());
     $listMapper->add('team2', 'sonata_type_model', array());
     $listMapper->add('score1', 'text');
     $listMapper->add('score2', 'text');
     $listMapper->add('startTime', 'datetime');
 }
开发者ID:Euro2016,项目名称:Euro2016,代码行数:9,代码来源:GameAdmin.php

示例13: configureListFields

 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->addIdentifier('id');
     $listMapper->addIdentifier('getSaleOrderNumber', null, array('label' => 'order_number'));
     $listMapper->add('orderDate', null, array('label' => 'date'));
     if (!$listMapper->getAdmin()->isChild()) {
         $listMapper->addIdentifier('partner', null, array('by_reference' => false, 'label' => 'customer', 'admin_code' => 'app.customer'));
     }
     $listMapper->add('amountUntaxed', 'money', array('label' => 'amount_untaxed', 'currency' => 'CHF'))->add('amountTotal', 'money', array('label' => 'amount_total', 'currency' => 'CHF'))->add('state', 'colored_choice', array('choices' => SaleOrder::getStateChoices(), 'colors' => SaleOrder::getStateColors(), 'catalogue' => 'messages'))->add('_action', 'actions', array('actions' => array('edit' => array())));
 }
开发者ID:Nexotap,项目名称:Ivory,代码行数:10,代码来源:SaleOrderAdmin.php

示例14: configureListFields

 protected function configureListFields(ListMapper $listMapper)
 {
     $listMapper->add('firstname', null, array('label' => 'First name'))->add('lastname', null, array('label' => 'Last name'))->add('year', 'choice', array('label' => 'Year', 'choices' => self::getYearChoices()));
     if ($this->isGranted('EDIT')) {
         $listMapper->add('payment', 'choice', array('label' => 'Payment type', 'choices' => self::getPaymentChoices()));
     }
     $listMapper->add('deposit', null, array('label' => 'Deposit'));
     if ($this->isGranted('EDIT')) {
         $listMapper->add('mailing', 'boolean', array('label' => 'Mailing list', 'editable' => true))->add('_action', 'actions', array('actions' => array('edit' => array(), 'delete' => array())));
     }
 }
开发者ID:HenryTelecom,项目名称:wwwroot,代码行数:11,代码来源:MemberAdmin.php

示例15: 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


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