using System.Collections.Generic;
using GxPress.Entity.WorkFlow;

namespace GxPress.Api.AdminControllers
{
    public partial class AdminFlowController
    {
        public class ListRequest
        {
            /// <summary>
            /// 审批类型
            /// </summary>
            public int ProcessId { get; set; }

            /// <summary>
            /// 状态
            /// </summary>
            public string State { get; set; }

            /// <summary>
            /// 提交时间
            /// </summary>
            public string StartDate { get; set; }

            /// <summary>
            /// 完成时间
            /// </summary>
            public string EndDate { get; set; }

            /// <summary>
            /// 关键词
            /// </summary>
            public string Keyword { get; set; }

            /// <summary>
            /// 当前页
            /// </summary>
            public int Page { get; set; }

            /// <summary>
            /// 每页显示多少项
            /// </summary>
            public int PerPage { get; set; }
        }

        public class TodoListResult
        {
            /// <summary>
            /// 当前页
            /// </summary>
            public int Count { get; set; }

            /// <summary>
            /// 每页显示多少项
            /// </summary>
            public IEnumerable<FlowTodoResult> Items { get; set; }
        }

        public class GetCountResult
        {
            /// <summary>
            /// 我审批的 - 待审批
            /// </summary>
            public int MyCheckingCount { get; set; }

            /// <summary>
            /// 我审批的 - 已审批
            /// </summary>
            public int MyCheckedCount { get; set; }

            /// <summary>
            /// 我发起的
            /// </summary>
            public int SubmittedCount { get; set; }

            /// <summary>
            /// 抄送我的 - 未读
            /// </summary>
            public int CcUnreadCount { get; set; }

            /// <summary>
            /// 抄送我的 - 全部
            /// </summary>
            public int CcAllCount { get; set; }
        }

        public class FlowTodoResult : FlowTodo
        {
            public string State { get; set; }
            /// <summary>
            /// 当前页
            /// </summary>
            public string Title { get; set; }

            public string AvatarUrl { get; set; }

            /// <summary>
            /// 每页显示多少项
            /// </summary>
            public List<string> Summaries { get; set; }
        }

        public class CheckRequest
        {
            /// <summary>
            /// 工作流Id
            /// </summary>
            public int FlowId { get; set; }

            /// <summary>
            /// 待办Id
            /// </summary>
            public int TodoId { get; set; }

            /// <summary>
            /// 是否审核通过
            /// </summary>
            public bool IsChecked { get; set; }

            /// <summary>
            /// 留言
            /// </summary>
            public string Message { get; set; }
        }

        public class ActionRequest
        {
            /// <summary>
            /// 工作流Id
            /// </summary>
            public int FlowId { get; set; }
        }
        public class DownloadResult
        {
            /// <summary>
            /// 下载地址
            /// </summary>
            public string DownloadUrl { get; set; }

            /// <summary>
            /// 预览
            /// </summary>
            public string PreviewUrl { get; set; }
        }
    }
}