package com.ruoyi.ss.businessRecord.service;

import com.ruoyi.ss.businessRecord.domain.SmBusinessRecord;
import com.ruoyi.ss.businessRecord.domain.SmBusinessRecordQuery;
import com.ruoyi.ss.businessRecord.domain.SmBusinessRecordVo;
import com.ruoyi.dashboard.domain.vo.BriefVo;

import java.util.Date;
import java.util.List;

/**
 * 经营记录Service接口
 *
 * @author ruoyi
 * @date 2024-03-19
 */
public interface ISmBusinessRecordService
{
    /**
     * 查询经营记录
     *
     * @param id 经营记录主键
     * @return 经营记录
     */
    public SmBusinessRecordVo selectSmBusinessRecordById(Long id);

    /**
     * 查询经营记录列表
     *
     * @param smBusinessRecord 经营记录
     * @return 经营记录集合
     */
    public List<SmBusinessRecordVo> selectSmBusinessRecordList(SmBusinessRecordQuery smBusinessRecord);

    /**
     * 新增经营记录
     *
     * @param smBusinessRecord 经营记录
     * @return 结果
     */
    public int insertSmBusinessRecord(SmBusinessRecord smBusinessRecord);

    /**
     * 修改经营记录
     *
     * @param smBusinessRecord 经营记录
     * @return 结果
     */
    public int updateSmBusinessRecord(SmBusinessRecord smBusinessRecord);

    /**
     * 批量删除经营记录
     *
     * @param ids 需要删除的经营记录主键集合
     * @return 结果
     */
    public int deleteSmBusinessRecordByIds(Long[] ids);

    /**
     * 删除经营记录信息
     *
     * @param id 经营记录主键
     * @return 结果
     */
    public int deleteSmBusinessRecordById(Long id);

    /**
     * 查询当天最后一条数据
     */
    SmBusinessRecordVo selectLatestByDate(Date date);

    /**
     * 查询每天最后一条数据
     * @param startDate 开始日期
     * @param endDate 结束日期
     */
    List<SmBusinessRecordVo> selectDailyLatest(Date startDate, Date endDate);

    /**
     * 查询实时数据
     * @return
     */
    BriefVo selectBrief();

    /**
     * 记录数据
     */
    void record();

}
