SysUserView.cs 2.93 KB
using Hh.Mes.Common.Infrastructure;
using Hh.Mes.POJO.Entity;
using SqlSugar;
using System;
using System.ComponentModel.DataAnnotations.Schema;

namespace Hh.Mes.Pojo.System
{
    public  class SysUserView
    {
        /// <summary>
        /// Id
        /// </summary>
        [SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
        [Column("id")]
        public int Id { get; set; }

        /// <summary>
        /// 创建者
        /// </summary>
        [Column("createBy")]
        public string CreateBy { get; set; }

        /// <summary>
        /// 创建时间
        /// </summary>
        [Column("createTime")]
        public DateTime? CreateTime { get; set; }

        /// <summary>
        /// 更新者
        /// </summary>
        [Column("updateBy")]
        public string UpdateBy { get; set; }

        /// <summary>
        /// 更新时间
        /// </summary>
        [Column("updateTime")]
        public DateTime? UpdateTime { get; set; }

        /// <summary>
        /// </summary>
        /// <returns></returns>
        public string Account { get; set; }

        /// <summary>
        /// </summary>
        /// <returns></returns>
        public string PassWord { get; set; }

        /// <summary>
        /// 组织名称
        /// </summary>
        /// <returns></returns>
        public string Name { get; set; }

        /// <summary>
        /// </summary>
        /// <returns></returns>
        public int Sex { get; set; }

        /// <summary>
        /// 当前状态
        /// </summary>
        /// <returns></returns>
        public int Status { get; set; }

        /// <summary>
	    /// 人脸id
	    /// </summary>
        public string FaceID { get; set; }
        /// <summary>
	    /// 图片
	    /// </summary>
        public string FacePicture { get; set; }
        /// <summary>
	    /// 工卡id
	    /// </summary>
        public string Idcard { get; set; }

        /// <summary>
	    /// 图片
	    /// </summary>
        public string PhoneNumber { get; set; }

        /// <summary>
        /// 组织类型
        /// </summary>
        /// <returns></returns>
        public int Type { get; set; }

        /// <summary>
        /// 所属组织名称,多个可用,分隔
        /// </summary>
        /// <value>The organizations.</value>
        public string Organizations { get; set; }
        public string Roles { get; set; }
        public string RoleIds { get; set; }
        public string OrganizationIds { get; set; }

        public static implicit operator SysUserView(SysUser user)
        {
            return user.MapTo<SysUserView>();
        }

        public static implicit operator SysUser(SysUserView view)
        {
            return view.MapTo<SysUser>();
        }

        public SysUserView()
        {
            Organizations = string.Empty;
            OrganizationIds = string.Empty;
            Roles = string.Empty;
            RoleIds = string.Empty;
        }
    }
}