package com.fs.company.service.impl;

import java.math.BigDecimal;
import java.util.List;
import com.fs.common.utils.DateUtils;
import com.fs.company.param.CompanyMoneyLogsParam;
import com.fs.company.param.CompanyStoreOrderMoneyLogsListParam;
import com.fs.company.vo.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.fs.company.mapper.CompanyMoneyLogsMapper;
import com.fs.company.domain.CompanyMoneyLogs;
import com.fs.company.service.ICompanyMoneyLogsService;

/**
 * 企业账户记录Service业务层处理
 *
 * @author fs
 * @date 2021-10-04
 */
@Service
public class CompanyMoneyLogsServiceImpl implements ICompanyMoneyLogsService
{
    @Autowired
    private CompanyMoneyLogsMapper companyMoneyLogsMapper;

    /**
     * 查询企业账户记录
     *
     * @param logsId 企业账户记录ID
     * @return 企业账户记录
     */
    @Override
    public CompanyMoneyLogs selectCompanyMoneyLogsById(Long logsId)
    {
        return companyMoneyLogsMapper.selectCompanyMoneyLogsById(logsId);
    }

    /**
     * 查询企业账户记录列表
     *
     * @param companyMoneyLogs 企业账户记录
     * @return 企业账户记录
     */
    @Override
    public List<CompanyMoneyLogs> selectCompanyMoneyLogsList(CompanyMoneyLogs companyMoneyLogs)
    {
        return companyMoneyLogsMapper.selectCompanyMoneyLogsList(companyMoneyLogs);
    }

    /**
     * 新增企业账户记录
     *
     * @param companyMoneyLogs 企业账户记录
     * @return 结果
     */
    @Override
    public int insertCompanyMoneyLogs(CompanyMoneyLogs companyMoneyLogs)
    {
        companyMoneyLogs.setCreateTime(DateUtils.getNowDate());
        return companyMoneyLogsMapper.insertCompanyMoneyLogs(companyMoneyLogs);
    }

    /**
     * 修改企业账户记录
     *
     * @param companyMoneyLogs 企业账户记录
     * @return 结果
     */
    @Override
    public int updateCompanyMoneyLogs(CompanyMoneyLogs companyMoneyLogs)
    {
        return companyMoneyLogsMapper.updateCompanyMoneyLogs(companyMoneyLogs);
    }

    /**
     * 批量删除企业账户记录
     *
     * @param logsIds 需要删除的企业账户记录ID
     * @return 结果
     */
    @Override
    public int deleteCompanyMoneyLogsByIds(Long[] logsIds)
    {
        return companyMoneyLogsMapper.deleteCompanyMoneyLogsByIds(logsIds);
    }

    /**
     * 删除企业账户记录信息
     *
     * @param logsId 企业账户记录ID
     * @return 结果
     */
    @Override
    public int deleteCompanyMoneyLogsById(Long logsId)
    {
        return companyMoneyLogsMapper.deleteCompanyMoneyLogsById(logsId);
    }

    @Override
    public List<CompanyMoneyLogsVO> selectCompanyMoneyLogsVOList(CompanyMoneyLogsParam companyMoneyLogs) {
        return companyMoneyLogsMapper.selectCompanyMoneyLogsVOList(companyMoneyLogs);
    }

    @Override
    public List<CompanyMoneyLogsVO> selectCompanyMoneyLogsMallVOList(CompanyMoneyLogsParam companyMoneyLogs) {
        return companyMoneyLogsMapper.selectCompanyMoneyLogsMallVOList(companyMoneyLogs);
    }

    @Override
    public List<CompanyMoneyLogsVO> selectCompanyMoneyLogsMallVO1List(CompanyMoneyLogsParam companyMoneyLogs) {
        return companyMoneyLogsMapper.selectCompanyMoneyLogsMallVO1List(companyMoneyLogs);
    }

    @Override
    public BigDecimal selectCompanyTotalMoneys(CompanyMoneyLogsParam companyMoneyLogs) {
        return companyMoneyLogsMapper.selectCompanyTotalMoneys(companyMoneyLogs);
    }

    @Override
    public List<CompanyMoneyLogsExportVO> selectCompanyMoneyLogsExportVOList(CompanyMoneyLogs companyMoneyLogs) {
        return companyMoneyLogsMapper.selectCompanyMoneyLogsExportVOList(companyMoneyLogs);
    }

    @Override
    public List<CompanyMoneyLogsExport1VO> selectCompanyMoneyLogsExport1VOList(CompanyMoneyLogs companyMoneyLogs) {
        return companyMoneyLogsMapper.selectCompanyMoneyLogsExport1VOList(companyMoneyLogs);
    }

    @Override
    public List<CompanyMoneyLogsExport2VO> selectCompanyMoneyLogsExport2VOList(CompanyMoneyLogs companyMoneyLogs) {
        return companyMoneyLogsMapper.selectCompanyMoneyLogsExport2VOList(companyMoneyLogs);
    }

    @Override
    public List<CompanyMoneyLogs> selectCompanyMoneyLogsByCompanyId(Long companyId, String minId) {
        return companyMoneyLogsMapper.selectCompanyMoneyLogsByCompanyId(companyId,minId);
    }

    @Override
    public List<CompanyStoreOrderMoneyLogsVO> selectCompanyStoreOrderMoneyLogsList(CompanyStoreOrderMoneyLogsListParam moneyLogsMap) {
        return companyMoneyLogsMapper.selectCompanyStoreOrderMoneyLogsList(moneyLogsMap);
    }
}
