Explorar el Código

Merge branch 'develop'

master
Fab hace 4 años
padre
commit
cb8f7fbfb2
Se han modificado 2 ficheros con 14 adiciones y 0 borrados
  1. +13
    -0
      ShopBundle/Repository/BaseRepository.php
  2. +1
    -0
      ShopBundle/Resources/views/backend/default/list-fields/field_datetime.html.twig

+ 13
- 0
ShopBundle/Repository/BaseRepository.php Ver fichero

@@ -36,6 +36,19 @@ class BaseRepository extends EntityRepository implements ServiceEntityRepository
return $qb->getQuery()->getResult();

}



public function findOneByOldUrl($url)
{
$qb = $this->createQueryBuilder('entity')
->where('entity.oldUrls LIKE :oldUrl')
->andWhere('entity.status = 1')
->setParameter(':oldUrl', '%'.$url.'%');

return $qb->getQuery()->getOneOrNullResult();
}

public function findByMerchantQuery() :QueryBuilder
{
return $this->createQueryBuilder('e')

+ 1
- 0
ShopBundle/Resources/views/backend/default/list-fields/field_datetime.html.twig Ver fichero

@@ -1,4 +1,5 @@
{#{{ value|date('U')}}#}

{% if field_options.format == "d/m/Y h:i A e" %}
{% set format = "d/m/Y H:i" %}
{% else %}

Cargando…
Cancelar
Guardar