This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
foreach($images as $image) | |
{ | |
if(!$this->show->hasImage($image)) $this->show->addImage($image); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$query = $qb->select(array('draft' => 'draft','thumbnail' => 'thumbnail')) | |
->from('App\Thumbnail\Thumbnail', 'thumbnail') | |
->from('App\Cropper\Image', 'image') | |
->from('App\Article\Draft', 'draft') | |
->where('thumbnail.image = image') | |
->andWhere('draft.image = image') | |
->getQuery(); | |
return $query->execute(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
abstract class ContentDao extends EntityDao | |
{ | |
protected $imageType; | |
public function __construct($imageType) | |
{ | |
$this->imageType = $imageType; | |
} | |
public function getImageType() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
array $result ( | |
array( | |
article => ArticleEntity, | |
thumbnail => ThumbnailEntity | |
), | |
array( | |
article => ArticleEntity, | |
thumbnail => ThumbnailEntity | |
), | |
array( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public function getUnpublished() | |
{ | |
$qb = $this->createQueryBuilder(); | |
$query = $qb->select(array('thumbnail','show')) | |
->from('\App\Thumbnail\Thumbnail','thumbnail') | |
->from('\App\Cropper\Image','image') | |
->from('\App\Entity\Content\Show', 'show') | |
->where('show.image = image') | |
->andWhere('thumbnail.image = image') | |
->getQuery(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
nette: | |
mailer: | |
smtp: | |
email: smtp.live.com | |
username: user | |
password: heslo | |
port: 587 | |
secure: tls | |
services: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @ORM\Entity(repositoryClass="ApplicantRepository") | |
*/ | |
class Applicant extends BaseEntity | |
{ | |
/** @var string | |
@ORM\Column(type="string") @ORM\Id*/ | |
protected $email; | |
/** |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$qb = $this->applicantRepository->createQueryBuilder() | |
->select('a','c','p') | |
->from('\App\model\entity\Applicant','a') | |
->leftJoin('\App\model\entity\Comment','c',Join::WITH,'c.applicant = a') | |
->leftJoin('\App\model\entity\Payment','p',Join::WITH,'p.applicant = a') | |
->getQuery(); | |
return $qb->getResult(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$('.ajax-load').click -> | |
url = $(this).data 'url' | |
$.nette.ajax | |
url: url, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if(this.headerRenderers[key]) | |
return this.headerRenderers[key](data); |