Commit a9e07d57 authored by Matija Obreza's avatar Matija Obreza
Browse files

Merge branch 'ui-401-some-institutes-have-null-last-updates-of-passport-data-date' into 'master'

Fix: Some institutes have NULL "Last updates of passport data" date

Closes genesys-ui#401

See merge request genesys-pgr/genesys-server!426
parents 5b1ed5d5 aed94d6c
......@@ -151,7 +151,7 @@ public interface AccessionRepository extends JpaRepository<Accession, Long>, Acc
@Query("select year(a.lastModifiedDate), month(a.lastModifiedDate), day(a.lastModifiedDate), a.institute.id, count(a) from Accession a group by year(a.lastModifiedDate), month(a.lastModifiedDate), day(a.lastModifiedDate), a.institute order by year(a.lastModifiedDate) desc, month(a.lastModifiedDate) desc, day(a.lastModifiedDate) desc, count(*) desc, a.institute.id")
public List<Object[]> lastUpdatedStatistics();
@Query("select year(a.lastModifiedDate), month(a.lastModifiedDate), day(a.lastModifiedDate), count(a) from Accession a where a.institute = ?1 group by year(a.lastModifiedDate), month(a.lastModifiedDate), day(a.lastModifiedDate) order by year(a.lastModifiedDate) desc, month(a.lastModifiedDate) desc, day(a.lastModifiedDate) desc")
@Query("select year(a.lastModifiedDate), month(a.lastModifiedDate), day(a.lastModifiedDate), count(a) from Accession a where a.institute = ?1 and a.lastModifiedDate is not null group by year(a.lastModifiedDate), month(a.lastModifiedDate), day(a.lastModifiedDate) order by year(a.lastModifiedDate) desc, month(a.lastModifiedDate) desc, day(a.lastModifiedDate) desc")
public List<Object[]> lastUpdatedStatistics(FaoInstitute faoInstitute);
@Query("select year(a.lastModifiedDate), count(a) from Accession a where a.institute = ?1 and a.historic = ?2 group by year(a.lastModifiedDate) order by year(a.lastModifiedDate) desc")
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment