package com.qmth.sop.business.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.qmth.sop.business.entity.TFFlowApprove;
import com.qmth.sop.business.mapper.TFFlowApproveMapper;
import com.qmth.sop.business.service.TFFlowApproveService;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 * 流程审核表 服务实现类
 * </p>
 *
 * @author wangliang
 * @since 2023-07-17
 */
@Service
public class TFFlowApproveServiceImpl extends ServiceImpl<TFFlowApproveMapper, TFFlowApprove> implements TFFlowApproveService {

    /**
     * 根据crmNo查询flowId
     *
     * @param crmNo
     * @return
     */
    @Override
    public List<Long> findFlowIdByCrmNo(String crmNo) {
        return this.baseMapper.findFlowIdByCrmNo(crmNo);
    }

    /**
     * 根据crmNo查找sop在途的流程数
     *
     * @param crmNo
     * @return
     */
    @Override
    public int findFlowPassageSopByCrmNo(String crmNo) {
        return this.baseMapper.findFlowPassageSopByCrmNo(crmNo);
    }
}
