using System.ComponentModel;
using System.ComponentModel.DataAnnotations;

namespace RB_MES_APICore.Models
{
    public class AuthorizationInfo
    {
        [Key]
        public int FID { get; set; }

        [Required]
        [DisplayName("开放平台appKey")]
        public string? FAppKey { get; set; }

        [Required]
        [DisplayName("开放平台appSecret")]
        public string? FAppSecret { get; set; }

        [Required]
        [DisplayName("用户临时授权码")]
        public string? FAuthCode { get; set; }

        [DisplayName("AppTicket")]
        public string? FAppTicket { get; set; }

        [DisplayName("用户编码")]
        public string? FUserCode { get; set; }

        [DisplayName("用户永久授权码")]
        public string? FUserAuthPermanentCode { get; set; }

        [DisplayName("应用凭证")]
        public string? FAppAccessToken { get; set; }

        [DisplayName("企业临时授权码")]
        public string? FOrgAuthTempCode { get; set; }

        [DisplayName("企业永久授权码")]
        public string? FOrgAuthPermanentCode { get; set; }

        [DisplayName("企业凭证")]
        public string? FOrgAccessToken { get; set; }

        [DisplayName("Token")]
        public string? FToken { get; set; }

        public DateTime FStartDate { get; set; } = DateTime.Now.Date;

        public DateTime FExpireDate { get; set; } = DateTime.Now.AddDays(6);
    }
}
