package com.ruoyi.mall.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.mall.mapper.MallPrintSettingMapper;
import com.ruoyi.mall.domain.MallPrintSetting;
import com.ruoyi.mall.service.IMallPrintSettingService;

/**
 * 订单打印设置Service业务层处理
 * 
 * @author ruoyi
 * @date 2022-08-03
 */
@Service
public class MallPrintSettingServiceImpl implements IMallPrintSettingService 
{
    @Autowired
    private MallPrintSettingMapper mallPrintSettingMapper;

    /**
     * 查询订单打印设置
     * 
     * @param printSettingId 订单打印设置主键
     * @return 订单打印设置
     */
    @Override
    public MallPrintSetting selectMallPrintSettingByPrintSettingId(Integer printSettingId)
    {
        return mallPrintSettingMapper.selectMallPrintSettingByPrintSettingId(printSettingId);
    }

    /**
     * 查询订单打印设置列表
     * 
     * @param mallPrintSetting 订单打印设置
     * @return 订单打印设置
     */
    @Override
    public List<MallPrintSetting> selectMallPrintSettingList(MallPrintSetting mallPrintSetting)
    {
        return mallPrintSettingMapper.selectMallPrintSettingList(mallPrintSetting);
    }

    /**
     * 新增订单打印设置
     * 
     * @param mallPrintSetting 订单打印设置
     * @return 结果
     */
    @Override
    public int insertMallPrintSetting(MallPrintSetting mallPrintSetting)
    {
        return mallPrintSettingMapper.insertMallPrintSetting(mallPrintSetting);
    }

    /**
     * 修改订单打印设置
     * 
     * @param mallPrintSetting 订单打印设置
     * @return 结果
     */
    @Override
    public int updateMallPrintSetting(MallPrintSetting mallPrintSetting)
    {
        return mallPrintSettingMapper.updateMallPrintSetting(mallPrintSetting);
    }

    /**
     * 批量删除订单打印设置
     * 
     * @param printSettingIds 需要删除的订单打印设置主键
     * @return 结果
     */
    @Override
    public int deleteMallPrintSettingByPrintSettingIds(Integer[] printSettingIds)
    {
        return mallPrintSettingMapper.deleteMallPrintSettingByPrintSettingIds(printSettingIds);
    }

    /**
     * 删除订单打印设置信息
     * 
     * @param printSettingId 订单打印设置主键
     * @return 结果
     */
    @Override
    public int deleteMallPrintSettingByPrintSettingId(Integer printSettingId)
    {
        return mallPrintSettingMapper.deleteMallPrintSettingByPrintSettingId(printSettingId);
    }
}
