using Hotline.Share.Dtos.FlowEngine.Workflow;
using Hotline.Share.Enums.FlowEngine;

namespace Hotline.Share.Dtos.FlowEngine;

public class NextStepOption : Kv
{
    /// <summary>
    /// 是否回到会签发起节点汇总
    /// </summary>
    public bool BackToCountersignEnd { get; set; }

    /// <summary>
    /// 是否需要填写真实办理人信息
    /// </summary>
    public bool InputRealHandler { get; set; }

    /// <summary>
    /// 流转方向
    /// </summary>
    public EFlowDirection? FlowDirection { get; set; }

    /// <summary>
    /// 模板配置节点类型
    /// </summary>
    public EStepType StepType { get; set; }

    /// <summary>
    /// 模板配置节点业务类型
    /// </summary>
    public EBusinessType BusinessType { get; set; }

    /// <summary>
    /// 办理对象类型
    /// </summary>
    public EHandlerType HandlerType { get; set; }

    public string Tag { get; set; }

    /// <summary>
    /// 节点部门等级(非部门等级办理时无效)
    /// </summary>
    public int? OrgLevel { get; set; }

    /// <summary>
    /// 节点下可选办理对象
    /// </summary>
    public IReadOnlyList<StepAssignInfo> Items { get; set; }
}

public class RecallStepOption : NextStepOption
{
    /// <summary>
    /// 该节点原办理对象
    /// </summary>
    public StepAssignInfo Handler { get; set; }
}

/// <summary>
/// 流程办理对象
/// </summary>
public class FlowStepHandler : Kv
{
    public string? UserId { get; set; }
    public string? Username { get; set; }
    public string? OrgId { get; set; }
    public string? OrgName { get; set; }
    public string? RoleId { get; set; }
    public string? RoleName { get; set; }
}