package com.sooka.system.service.impl;

import java.util.List;

import com.sooka.common.core.text.Convert;
import com.sooka.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.sooka.system.mapper.TGuijiHealthcommissionXxMapper;
import com.sooka.system.domain.TGuijiHealthcommissionXx;
import com.sooka.system.service.ITGuijiHealthcommissionXxService;

/**
 * 献血者信息Service业务层处理
 *
 * @author lei
 * @date 2021-11-09
 */
@Service
public class TGuijiHealthcommissionXxServiceImpl extends Guiji_Base_Service implements ITGuijiHealthcommissionXxService
{
    @Autowired
    private TGuijiHealthcommissionXxMapper tGuijiHealthcommissionXxMapper;

    /**
     * 查询献血者信息
     *
     * @param id 献血者信息ID
     * @return 献血者信息
     */
    @Override
    public TGuijiHealthcommissionXx selectTGuijiHealthcommissionXxById(String id)
    {
        return tGuijiHealthcommissionXxMapper.selectTGuijiHealthcommissionXxById(id);
    }

    /**
     * 查询献血者信息列表
     *
     * @param tGuijiHealthcommissionXx 献血者信息
     * @return 献血者信息
     */
    @Override
    public List<TGuijiHealthcommissionXx> selectTGuijiHealthcommissionXxList(TGuijiHealthcommissionXx tGuijiHealthcommissionXx)
    {
        List ls = tGuijiHealthcommissionXxMapper.selectTGuijiHealthcommissionXxList(tGuijiHealthcommissionXx);
        tGuijiHealthcommissionXx.setInterfaceinfoId("485efd9c-330a-4a11-9f84-c51e2234dd04");
        tGuijiHealthcommissionXx.setInterfaceinfoName("共享-血站-献血者信息");
        tGuijiHealthcommissionXx.setInterfacetype("platform_interfacetype_1");
        add_log(tGuijiHealthcommissionXx);

        return ls;
    }

    /**
     * 新增献血者信息
     *
     * @param tGuijiHealthcommissionXx 献血者信息
     * @return 结果
     */
    @Override
    public int insertTGuijiHealthcommissionXx(TGuijiHealthcommissionXx tGuijiHealthcommissionXx)
    {
        tGuijiHealthcommissionXx.setCreateTime(DateUtils.getNowDate());
        return tGuijiHealthcommissionXxMapper.insertTGuijiHealthcommissionXx(tGuijiHealthcommissionXx);
    }

    /**
     * 修改献血者信息
     *
     * @param tGuijiHealthcommissionXx 献血者信息
     * @return 结果
     */
    @Override
    public int updateTGuijiHealthcommissionXx(TGuijiHealthcommissionXx tGuijiHealthcommissionXx)
    {
        return tGuijiHealthcommissionXxMapper.updateTGuijiHealthcommissionXx(tGuijiHealthcommissionXx);
    }

    /**
     * 删除献血者信息对象
     *
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    @Override
    public int deleteTGuijiHealthcommissionXxByIds(String ids)
    {
        return tGuijiHealthcommissionXxMapper.deleteTGuijiHealthcommissionXxByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除献血者信息信息
     *
     * @param id 献血者信息ID
     * @return 结果
     */
    @Override
    public int deleteTGuijiHealthcommissionXxById(String id)
    {
        return tGuijiHealthcommissionXxMapper.deleteTGuijiHealthcommissionXxById(id);
    }
}
