using OASystem.Domain.Entities.System;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace OASystem.Domain.ViewModels.System
{
    public class MessageView : Sys_Message
    {
    }

    public class MessageUnreadTotalCountView
    {
        public int UnreadCount { get; set; } = 0;
    }

    /// <summary>
    /// 用于都消息返回视图
    /// </summary>
    public class MessageListView
    {
        public int RowNumber { get; set; }
        public int Id { get; set; }

        /// <summary>
        /// 消息类型
        /// </summary>
        public int Type { get; set; }

        /// <summary>
        /// 消息标题
        /// </summary>
        public string Title { get; set; }

        /// <summary>
        /// 消息内容
        /// </summary>
        public string Content { get; set; }

        /// <summary>
        /// 发布部门
        /// </summary>
        public string IssuerDep { get; set; }

        /// <summary>
        /// 发布者
        /// </summary>
        public string IssuerUser { get; set; }

        /// <summary>
        /// 发布时间
        /// </summary>
        public DateTime ReleaseTime { get; set; }


        /// <summary>
        /// 是否已读
        /// 0 未读 1 已读
        /// </summary>
        public int IsRead { get; set; }

        //public int DiId { get; set; }

        //public string Param { get; set; }
    }

    /// <summary>
    /// 用于都消息返回视图
    /// </summary>
    public class ReadbleMessageView
    {
        public int RowNumber { get; set; }
        public int Id { get; set; }

        /// <summary>
        /// 消息类型
        /// 1 公告消息
        /// 2 团组流程管控消息
        /// 3 团组业务操作消息
        /// 4费用
        /// </summary>
        public int Type { get; set; }

        /// <summary>
        /// 消息标题
        /// </summary>
        public string Title { get; set; }

        /// <summary>
        /// 消息内容
        /// </summary>
        public string Content { get; set; }

        /// <summary>
        /// 发布部门
        /// </summary>
        public string IssuerDep { get; set; }

        /// <summary>
        /// 发布者
        /// </summary>
        public string IssuerUser { get; set; }

        /// <summary>
        /// 发布时间
        /// </summary>
        public DateTime ReleaseTime { get; set; }

        public int DiId { get; set; }

        public string Param { get; set; }
    }

    public class ReadbleMessageView1 : ReadbleMessageView
    {
        public int IsRead { get; set; }
    }

    public class MessageInfoView 
    {
        /// <summary>
        /// 消息类型
        /// 1 公告消息
        /// 2 团组流程管控消息
        /// 3 团组业务操作消息
        /// 4费用
        /// </summary>
        public int Type { get; set; }

        /// <summary>
        /// 公司名称
        /// </summary>
        public string CompanyName { get; set; }

        /// <summary>
        /// 部门名称
        /// </summary>
        public string DepName { get; set; }

        /// <summary>
        /// 岗位名称
        /// </summary>
        public string JobName { get; set; }

        /// <summary>
        /// 发布人
        /// </summary>
        public string CnName { get; set; }

        /// <summary>
        /// 发布时间
        /// </summary>
        public DateTime ReleaseTime { get; set; }

        /// <summary>
        /// 消息标题
        /// </summary>
        public string Title { get; set; }

        /// <summary>
        /// 消息内容
        /// </summary>
        public string Content { get; set; }

        /// <summary>
        /// 是否已读
        /// 0 未读 1 已读
        /// </summary>
        public int IsRead { get; set; }

        /// <summary>
        /// 已读时间
        /// 1990-01-01 00:00:000 未读
        /// </summary>
        public DateTime ReadTime { get; set; }

        public int DiId { get; set; }

        public string Param { get; set; }
    }

    public class MessageTypeView 
    {

        public int Id { get; set; }
        /// <summary>
        /// 分类名称
        /// </summary>
        public string Name { get; set; }
        /// <summary>
        /// 未读条数
        /// </summary>
        public int UnReadCount { get; set; } = 0;
    }

    public class NotificationTypeView
    {
        /// <summary>
        /// 通知类型
        /// 1 操作通知
        /// 2 任务通知
        /// </summary>
        public int TypeId { get; set; }

        /// <summary>
        /// 消息类型id
        /// </summary>
        public List<int> MsgTypeIds { get; set; }
    }
}
