package com.chinaweal.aiccs.aiccs.business.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.chinaweal.aiccs.aiccs.business.entity.TSTwfTask;
import com.chinaweal.aiccs.aiccs.business.mapper.TSTwfTaskMapper;
import com.chinaweal.aiccs.aiccs.business.service.TSTwfTaskService;
import com.chinaweal.youfool.framework.springboot.mybatis.plus.BaseServiceImpl;
import org.springframework.stereotype.Service;

/**
 * <p>
 * 工作流任务表 服务实现类
 * </p>
 *
 * @author <a href="https://blog.lroyia.top">lroyia</a>
 * @since 2021-01-29
 */
@Service
public class TSTwfTaskServiceImpl extends BaseServiceImpl<TSTwfTaskMapper, TSTwfTask> implements TSTwfTaskService {

    @Override
    public TSTwfTask findTwfTaskByProcessID(String processId) {
        return getOne(new LambdaQueryWrapper<TSTwfTask>().eq(TSTwfTask::getProcessid, processId));
    }

    @Override
    public void deleteTwftaskByProcessid(String processId) {
        remove(new LambdaQueryWrapper<TSTwfTask>().eq(TSTwfTask::getProcessid, processId));
    }
}
