package com.ghy.payment.service.impl;

import com.ghy.common.core.text.Convert;
import com.ghy.payment.domain.FinancialMaster;
import com.ghy.payment.mapper.FinancialMasterMapper;
import com.ghy.payment.service.FinancialMasterService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * 商品模块实现类
 *
 * @author clunt
 */
@Service
public class FinancialMasterServiceImpl implements FinancialMasterService {

    @Resource
    private FinancialMasterMapper financialMasterMapper;

    @Override
    public int insertFinancialMaster(FinancialMaster financialMaster) {
        return financialMasterMapper.insertFinancialMaster(financialMaster);
    }

    @Override
    public int updateFinancialMaster(FinancialMaster financialMaster) {
        return financialMasterMapper.updateFinancialMaster(financialMaster);
    }

    @Override
    public List<FinancialMaster> selectFinancialMasterList(FinancialMaster financialMaster) {
        return financialMasterMapper.selectFinancialMasterList(financialMaster);
    }

    @Override
    public FinancialMaster selectById(Long financialMasterId) {
        return financialMasterMapper.selectById(financialMasterId);
    }

    @Override
    public int deleteFinancialMasterByIds(String ids) {
        Long[] financialMasterIds = Convert.toLongArray(ids);
        return financialMasterMapper.deleteFinancialMasterByIds(financialMasterIds);
    }

}
