package com.huimv.admin.repo.primary;


import com.huimv.admin.domain.primary.SysGroupEntity;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;


public interface SysGroupEntityRepository extends JpaRepository<SysGroupEntity, Integer>, JpaSpecificationExecutor<SysGroupEntity> {
    @Query(nativeQuery = true , value = "SELECT * FROM sys_group WHERE group_name like %?1% order by ?#{#pageable}")
    Page<SysGroupEntity> findByGroupNameLike(String searchStr, Pageable pageable);
}