package common.repository;

import common.model.AppCategory;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;

import java.util.List;

/**
 * Created by zxy on 2017/12/26.
 */
public interface AppCategoryRepository extends JpaRepository<AppCategory, Long>
{
    @Query(value="select `name` from app_category where level = ?1",nativeQuery=true)
    List<String> findCategoryByLevel(int level);
}
