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


PHP User::__construct方法代码示例

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


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

示例1: __construct

 public function __construct()
 {
     $this->packages = new ArrayCollection();
     $this->authors = new ArrayCollection();
     $this->createdAt = new \DateTime();
     parent::__construct();
 }
开发者ID:enriquesomolinos,项目名称:packagist,代码行数:7,代码来源:User.php

示例2: __construct

 public function __construct()
 {
     parent::__construct();
     $this->campaigns = new ArrayCollection();
     $this->tasks = new ArrayCollection();
     $this->files = new ArrayCollection();
 }
开发者ID:bogdy2p,项目名称:oviTiut,代码行数:7,代码来源:User.php

示例3: __construct

 public function __construct()
 {
     parent::__construct();
     if (empty($this->roles)) {
         $this->roles[] = 'ROLE_USER';
     }
 }
开发者ID:ancgate,项目名称:ldap_project,代码行数:7,代码来源:User.php

示例4: __construct

 public function __construct()
 {
     parent::__construct();
     $this->setEnabled(true);
     $this->setLocked(false);
     // your own logic
 }
开发者ID:anoopogt,项目名称:BWCMS,代码行数:7,代码来源:UserEntity.php

示例5: __construct

 /**
  * Creates a user
  */
 public function __construct()
 {
     parent::__construct();
     $this->lastLocation = new Location();
     $this->lastLocation->setLatitude(0);
     $this->lastLocation->setLongitude(0);
 }
开发者ID:rjagerman,项目名称:TuneMaps,代码行数:10,代码来源:User.php

示例6: __construct

 public function __construct()
 {
     parent::__construct();
     $this->isActive = true;
     // may not be needed, see section on salt below
     // $this->salt = md5(uniqid(null, true));
 }
开发者ID:asbag,项目名称:socialnetwork,代码行数:7,代码来源:User.php

示例7: __construct

 public function __construct()
 {
     parent::__construct();
     $this->created = new \DateTime();
     $this->activated = false;
     $this->enabled = true;
 }
开发者ID:alpixel,项目名称:AlpixelUserBundle,代码行数:7,代码来源:User.php

示例8: __construct

 public function __construct()
 {
     parent::__construct();
     // your own logic
     $this->groups = new \Doctrine\Common\Collections\ArrayCollection();
     $this->projects = new \Doctrine\Common\Collections\ArrayCollection();
     $this->tasks = new \Doctrine\Common\Collections\ArrayCollection();
 }
开发者ID:jarmas8611,项目名称:proyect,代码行数:8,代码来源:User.php

示例9: __construct

 public function __construct()
 {
     parent::__construct();
     // your own logic
     $this->locked = true;
     $this->applications = new ArrayCollection();
     $this->providers = new ArrayCollection();
 }
开发者ID:nuffer,项目名称:FundraisingDB,代码行数:8,代码来源:Fundraiser.php

示例10: __construct

 public function __construct()
 {
     parent::__construct();
     $this->friendWithMe = new \Doctrine\Common\Collections\ArrayCollection();
     $this->myFriends = new \Doctrine\Common\Collections\ArrayCollection();
     $this->apiKey = substr(str_shuffle('0123456789AZERTYUIOPQSDFGHJKLMWXCVBNazertyuiopqsdfghjklmwxcvbn'), 32);
     $this->roles = array('ROLE_USER');
 }
开发者ID:makanikki,项目名称:messenger-api,代码行数:8,代码来源:User.php

示例11: __construct

 public function __construct()
 {
     parent::__construct();
     $this->created = new \DateTime();
     $this->lastActivity = new \DateTime();
     $this->image = new \Ben\DoctorsBundle\Entity\image();
     $this->consultations = new \Doctrine\Common\Collections\ArrayCollection();
 }
开发者ID:gitter-badger,项目名称:Doctors,代码行数:8,代码来源:User.php

示例12: __construct

 public function __construct()
 {
     parent::__construct();
     $this->days = 10;
     $this->alertEmail = false;
     $this->alertDays = 1;
     $this->emailVisible = false;
     $this->homepage = 'Aucune';
 }
开发者ID:bionoir,项目名称:stxcroissants,代码行数:9,代码来源:User.php

示例13: __construct

 public function __construct()
 {
     parent::__construct();
     $this->email = null;
     // note: when saving the user manager will put the email canonical
     // to empty string hence why we removed the unique constraint,
     // to avoid error being thrown when registering a user only with
     // phone number
     $this->emailCanonical = null;
 }
开发者ID:kiddblizzard,项目名称:oauth2-symfony2-vagrant-fosuserbundle,代码行数:10,代码来源:User.php

示例14: __construct

 public function __construct()
 {
     parent::__construct();
     // your own logic
     //$this->entidad = new ArrayCollection();
     $this->rols = new ArrayCollection();
     $this->auditDeleted = false;
     $this->userInternoTipo = null;
     $this->auditDateIns = new \DateTime();
     $this->algorithm = 'sha512';
 }
开发者ID:UNCHenryMelara,项目名称:sca-mh-minsal,代码行数:11,代码来源:User.php

示例15: __construct

 public function __construct()
 {
     parent::__construct();
     /* @var $doctrine \Doctrine\Bundle\DoctrineBundle\Registry */
     $doctrine = \AppKernel::getStaticContainer()->get('doctrine');
     /* @var $em \Doctrine\ORM\EntityManager */
     $em = $doctrine->getManager();
     $this->setEnabled(true);
     $group = $em->getRepository('ApplicationSonataUserBundle:Group')->find(static::GroupId);
     if ($group) {
         $this->addGroup($group);
     }
 }
开发者ID:defan-marunchak,项目名称:eurotax,代码行数:13,代码来源:User.php


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