當前位置: 首頁>>代碼示例>>PHP>>正文


PHP ShowMapper::with方法代碼示例

本文整理匯總了PHP中Sonata\AdminBundle\Show\ShowMapper::with方法的典型用法代碼示例。如果您正苦於以下問題:PHP ShowMapper::with方法的具體用法?PHP ShowMapper::with怎麽用?PHP ShowMapper::with使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Sonata\AdminBundle\Show\ShowMapper的用法示例。


在下文中一共展示了ShowMapper::with方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: configureShowFields

 protected function configureShowFields(ShowMapper $showMapper)
 {
     $showMapper->with('tabs.client.basic_data');
     $showMapper->add('enabled', null, array('label' => 'client.enabled'));
     $showMapper->add('name', null, array('label' => 'client.name'));
     $showMapper->add('email', null, array('label' => 'client.email'));
     $showMapper->add('phone', null, array('label' => 'client.phone'));
     $showMapper->end();
     $showMapper->with('tabs.client.invoice_data');
     $showMapper->add('invoice_name', null, array('label' => 'client.invoice_name'));
     $showMapper->add('invoice_nip', null, array('label' => 'client.invoice_nip'));
     $showMapper->add('invoice_address', null, array('label' => 'client.invoice_address'));
 }
開發者ID:siciarek,項目名稱:ad-rotator-bundle,代碼行數:13,代碼來源:ClientAdmin.php

示例2: testReorder

 public function testReorder()
 {
     $this->assertEquals(array(), $this->admin->getShowGroups());
     $fieldDescription1 = $this->getFieldDescriptionMock('fooName1', 'fooLabel1');
     $fieldDescription2 = $this->getFieldDescriptionMock('fooName2', 'fooLabel2');
     $fieldDescription3 = $this->getFieldDescriptionMock('fooName3', 'fooLabel3');
     $fieldDescription4 = $this->getFieldDescriptionMock('fooName4', 'fooLabel4');
     $this->showMapper->with('Group1');
     $this->showMapper->add($fieldDescription1);
     $this->showMapper->add($fieldDescription2);
     $this->showMapper->add($fieldDescription3);
     $this->showMapper->add($fieldDescription4);
     $this->assertEquals(array('Group1' => array('collapsed' => false, 'fields' => array('fooName1' => 'fooName1', 'fooName2' => 'fooName2', 'fooName3' => 'fooName3', 'fooName4' => 'fooName4'), 'description' => false, 'translation_domain' => null, 'class' => false, 'name' => 'Group1')), $this->admin->getShowGroups());
     $this->showMapper->reorder(array('fooName3', 'fooName2', 'fooName1', 'fooName4'));
     // print_r is used to compare order of items in associative arrays
     $this->assertEquals(print_r(array('Group1' => array('collapsed' => false, 'class' => false, 'description' => false, 'translation_domain' => null, 'name' => 'Group1', 'fields' => array('fooName3' => 'fooName3', 'fooName2' => 'fooName2', 'fooName1' => 'fooName1', 'fooName4' => 'fooName4'))), true), print_r($this->admin->getShowGroups(), true));
 }
開發者ID:saberyounis,項目名稱:Sonata-Project,代碼行數:17,代碼來源:ShowMapperTest.php

示例3: configureShowFields

 protected function configureShowFields(ShowMapper $showMapper)
 {
     $showMapper->with('Article')->add('title')->add('authors')->add('keyword')->add('abstract')->add('stateEnd')->add('createAt')->add('topics')->end()->with('Reviewers')->add('reviewers')->end();
 }
開發者ID:aulasoftwarelibre,項目名稱:fastconfer,代碼行數:4,代碼來源:ArticleAdmin.php

示例4: configureShowFields

 protected function configureShowFields(ShowMapper $showMapper)
 {
     $showMapper->with('Social')->end();
 }
開發者ID:FlorianKromer,項目名稱:TNCY-English,代碼行數:4,代碼來源:UserAdmin.php

示例5: configureShowFields

 /**
  * {@inheritdoc}
  */
 protected function configureShowFields(ShowMapper $showMapper)
 {
     $showMapper->with('General')->add('username')->add('email')->end();
 }
開發者ID:CrazyConnect,項目名稱:WasteWatcherApi,代碼行數:7,代碼來源:UserAdmin.php

示例6: configureShowFields

 /**
  * {@inheritdoc}
  */
 protected function configureShowFields(ShowMapper $showMapper)
 {
     $showMapper->with('General')->add('username')->add('email')->end()->with('Groups')->add('groups')->end()->with('Profile')->add('dateOfBirth')->add('firstname')->add('lastname')->add('gender')->add('phone')->end()->with('Security')->add('token')->add('twoStepVerificationCode')->end();
 }
開發者ID:WildCodeSchool,項目名稱:projet-wildresa,代碼行數:7,代碼來源:UserAdmin.php

示例7: configureShowFields

 protected function configureShowFields(ShowMapper $showMapper)
 {
     // Fields to be shown on show action
     $showMapper->with('Marque')->add('name', null, array('label' => 'Nom'))->add('slug')->add('templates', null, array('label' => 'Liste des templates'))->end();
 }
開發者ID:Cartesia,項目名稱:01,代碼行數:5,代碼來源:BrandAdmin.php

示例8: configureShowFields

 protected function configureShowFields(ShowMapper $showMapper)
 {
     $showMapper->with('General')->add('nom')->add('description')->add('charte', 'string', array('template' => 'IuchBundle:Charte:show.html.twig'))->add('service')->add('obligatoire')->end();
 }
開發者ID:luciemannechez,項目名稱:projet-intranet_hopital,代碼行數:4,代碼來源:CharteAdmin.php

示例9: configureShowFields

 /**
  * @param ShowMapper $showMapper
  */
 protected function configureShowFields(ShowMapper $showMapper)
 {
     $showMapper->with('Package General Description')->add('id')->add('packagename')->add('packageAliasname')->add('paperlitId')->end()->with('Package Details')->add('ismagazine')->add('isFasttrack')->add('isSkoar')->add('isDvD1')->add('isDvD2')->add('isDgt')->end()->with('Other Details')->add('duration')->add('coverPrice')->add('youPay')->add('benefit')->end()->with('Package Start and End Date')->add('startFromDate')->add('endDate')->end()->with('Set Priority, Status and Image Details')->add('priority')->add('status')->add('image');
 }
開發者ID:manudatta12,項目名稱:POC,代碼行數:7,代碼來源:EmagazinePackageAdmin.php

示例10: configureShowFields

 protected function configureShowFields(ShowMapper $showMapper)
 {
     $showMapper->with('Général')->add('user')->add('nom')->end()->with('Entrée')->add('date_donnee')->add('nombre_donne')->end()->with('Sortie')->add('date_rendu')->add('nombre_rendu')->end();
 }
開發者ID:luciemannechez,項目名稱:projet-intranet_hopital,代碼行數:4,代碼來源:TenueAdmin.php

示例11: configureShowFields

 protected function configureShowFields(ShowMapper $show)
 {
     $show->with('Computer Info')->add('name', null, array("label" => "field.name"))->add('mac', null, array("label" => "field.mac"))->add('port', null, array("label" => "field.port"))->add('broadcast_ip', null, array("label" => "field.broadcast_ip"))->add('ping_ip', null, array("label" => "field.ping_ip"))->add('ping_port', null, array("label" => "field.ping_port"))->end();
 }
開發者ID:dem3trio,項目名稱:wakeonlan-php,代碼行數:4,代碼來源:ComputerAdmin.php

示例12: configureShowFields

 /**
  * {@inheritdoc}
  */
 protected function configureShowFields(ShowMapper $showMapper)
 {
     $showMapper->with('General')->add('id')->add('title')->add('created_at', null, array('label' => 'Créé le', 'format' => 'd/m/Y à H\\hi'))->add('updated_at', null, array('label' => 'Modifié le', 'format' => 'd/m/Y à H\\hi'))->add('campaign')->add('base_detail')->end();
 }
開發者ID:StanFrag,項目名稱:CCM-Stage,代碼行數:7,代碼來源:BaseAdmin.php

示例13: configureShowFields

 /**
  * {@inheritdoc}
  */
 protected function configureShowFields(ShowMapper $showMapper)
 {
     $authorizationChecker = $this->getConfigurationPool()->getContainer()->get('security.authorization_checker');
     $showMapper->with('General', ['class' => 'col-md-6', 'name' => 'user.general'])->add('username')->add('email')->end()->with('Profile', ['class' => 'col-md-6', 'name' => 'user.profile'])->add('firstname')->add('lastname')->end();
     if ($authorizationChecker->isGranted('ROLE_ADMIN')) {
         $showMapper->with('Groups', ['class' => 'col-md-12', 'name' => 'security.groups'])->add('groups')->end();
     }
 }
開發者ID:glavweb,項目名稱:rest-demo-app,代碼行數:11,代碼來源:UserAdmin.php

示例14: configureShowFields

 /**
  * @param \Sonata\AdminBundle\Show\ShowMapper $showMapper
  * 
  * @return void
  */
 protected function configureShowFields(ShowMapper $showMapper)
 {
     $showMapper->with('General', array('class' => 'col-md-10'))->add('titre')->add('contenu')->end()->with('Activé sur', array('class' => 'col-md-2'))->add('expertise')->add('atelier')->end()->with('Images')->add('images', 'sonata_type_admin', array('associated_property' => 'path', 'template' => 'PBBijouterieBundle:Admin:images.html.twig', 'required' => false))->end()->with('Video Youtube')->add('video')->end();
 }
開發者ID:TristanBaoui,項目名稱:PB,代碼行數:9,代碼來源:ArticleAdmin.php

示例15: configureShowFields

 protected function configureShowFields(ShowMapper $showMapper)
 {
     $showMapper->with('Général')->add('user', null, array('label' => 'Utilisateur'))->add('rendu', null, array('label' => 'Rendu'))->add('perdu_vol', null, array('label' => 'Perdu/volé'))->add('type')->end()->with('Entrée/Sortie')->add('date_remise', 'date', array('label' => 'Date de remise', 'format' => 'd/m/Y'))->add('date_rendu', 'date', array('label' => 'Date de rendu', 'format' => 'd/m/Y'))->end()->with('Informations complémentaires')->add('intervenant')->add('commentaire')->end();
 }
開發者ID:WildCodeSchool,項目名稱:projet-intranet_hopital,代碼行數:4,代碼來源:MaterielAdmin.php


注:本文中的Sonata\AdminBundle\Show\ShowMapper::with方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。