Voici votre URL de partage https://sharemycode.io/c/434cdd6 (Cliquer pour copier) (Copié)

= $this->createQueryBuilder('A');
        $query = $qb->select('A.title, A.slug, A.cover, A.content')
            ->addSelect("CASE WHEN DATE_FORMAT(A.created_at, '%Y-%m-%d') >= '".$interval."' THEN 1 ELSE 0 END AS new")
            ->addSelect('P.bedroom, P.housing_size, P.persons, P.loyer, P.caution')
            ->addSelect('(SUM(T.note) / COUNT(T.id)) AS ratings')
            ->addSelect('HT.libelle AS housing_type')
            ->addSelect("CONCAT(SUBSTRING(G.nom, 1, 2), '', U.id, '', G.id, '', A.id) AS prefix")
            ->innerJoin(Property::class, 'P', 'WITH', 'A.id = P.announcement')
            ->leftJoin(PropertyTestimonials::class, 'T', 'WITH', 'A.id = T.announcement')
            ->leftJoin(HousingType::class, 'HT', 'WITH', 'HT.id = P.housing')
            ->innerJoin(User::class, 'U', 'WITH', 'A.user = U.id')
            ->innerJoin(Gestionnaire::class, 'G', 'WITH', 'G.user = U.id')

Informations

Cet extrait a été créé le 18 sept. 2023 à 17:46:49

Cet extrait expire le 18 oct. 2023 à 17:46:49

Langage : php

Logo php

Link

Voici votre URL de partage : https://sharemycode.io/c/434cdd6 Copié

Demander la suppression