package com.gyee.frame.service.ticket;

import com.gyee.frame.model.ticket.Wfaction;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;
import java.util.Map;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author chenmh
 * @since 2020-07-21
 */
public interface WfactionService extends IService<Wfaction> {

    /**
     * 查询下一步的操作步骤
     *
     * @param status
     * @param startNodeId
     * @param version
     * @param wfName
     * @return
     */
    Map<String, Object> listAction(int status, double startNodeId, double version, String wfName);

    /**
     * 根据待办任务的id查询
     *
     * @param nodeId
     * @param version
     * @param wfName
     * @return
     */
    List<Wfaction> getAction(double nodeId, double version, String wfName);

    /**
     * 流程启动需要的开始id
     *
     * @param wfName
     * @return
     */
    Wfaction initAction(String wfName);

    /**
     * 查询工作票更新需要的状态
     *
     * ACTIONTYPE -- 更改状态
     *
     * @param  startNodeId
     * @param endNodeId
     * @return
     */
    Wfaction getActionStatus(double startNodeId, double endNodeId);
}
