packageuserio.repository;importorg.springframework.data.jpa.repository.JpaRepository;importorg.springframework.data.jpa.repository.Query;importuserio.model.App;importjava.math.BigInteger;importjava.util.List;publicinterfaceIOAppRepositoryextendsJpaRepository<App,Long>{@Query(value="select * from app where account in (select id from account where parent = ?1 or id = ?1) and del_flag is not true",nativeQuery=true)List<App>listAppByRootAccount(Longaccount);@Query(value="select count(*) from app where account in ?1 and create_time >= ?2 and create_time <= ?3",nativeQuery=true)BigIntegercountByAccount(List<Long>accountId,StringstartDate,StringendDate);@Query(value="select appkey from app where account in ?1",nativeQuery=true)List<String>findAppkeys(List<Long>accountId);}