package cn.teammodel.repository;

import cn.teammodel.model.entity.news.News;
import com.azure.spring.data.cosmos.repository.CosmosRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * @author winter
 * @create 2023-11-28 17:39
 */
@Repository
public interface NewsRepository extends CosmosRepository<News, String> {
    News findNewsByIdAndCode(String id, String code);

    List<News> findAllByCode(String code);
    List<News> findAllByCodeAndPeriodId(String code, String periodId);
}
