using System;
using System.Collections.Generic;
using CncModels.Dto;
using CncModels.Dto.Production;
using CncModels.Entity;

namespace CncRepository.Interface
{
    /// <summary>
    /// cnc_daily_production 产量仓储接口（业务库）
    /// </summary>
    public interface IDailyProductionRepository
    {
        DailyProduction GetById(int id);
        PagedResult<DailyProductionListItem> GetList(ProductionQuery query);
        List<DailyProduction> GetByMachineAndDate(int machineId, DateTime date);
        List<DailyProduction> GetByDateRange(DateTime startDate, DateTime endDate);
        decimal GetTotalByDateRange(DateTime startDate, DateTime endDate, int? workshopId);
        decimal GetTotalByWorkerAndDateRange(int workerId, DateTime startDate, DateTime endDate);
        List<DailyProduction> GetMachineRankByDateRange(DateTime startDate, DateTime endDate, int top);
        List<DailyProduction> GetWorkerRankByDateRange(DateTime startDate, DateTime endDate, int top);
    }
}
