using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using YBDevice.Entity;

namespace YBDevice.Application.DeviceInfo
{
    /// <summary>
    /// 设备分配记录
    /// </summary>
    public class DeviceAllocListS2SDto: DeviceAllocListSCDto
    {
        /// <summary>
        /// 来源客户ID
        /// </summary>
        public int FromBusinessId { get; set; }
        /// <summary>
        /// 接收客户ID
        /// </summary>
        public int ToBusinessId { get; set; }
    }

    /// <summary>
    /// 设备分配记录
    /// </summary>
    public class DeviceAllocListSCDto
    {
        /// <summary>
        /// 来源客户
        /// </summary>
        public string FromBusiness { get; set; }
        /// <summary>
        /// 接收客户
        /// </summary>
        public string ToBusiness { get; set; }
        /// <summary>
        /// 操作时间
        /// </summary>
        public DateTime Time { get; set; }
        /// <summary>
        /// 分配类型
        /// </summary>
        public DeviceAllocType Type { get; set; }
        /// <summary>
        /// 操作名称
        /// </summary>
        public string OpName { get; set; }
    }

    /// <summary>
    /// 设备类型绑定的小程序数据提交
    /// </summary>
    public class DeviceAppC2SDto
    {
        /// <summary>
        /// 
        /// </summary>
        public Guid Id { get; set; }

        /// <summary>
        /// 设备类型编码,多个中间以,分隔
        /// </summary>
        [Required(ErrorMessage = "请先选择设备类型")]
        public string DevType { get; set; }

        /// <summary>
        /// 小程序appid
        /// </summary>
        [Required(ErrorMessage = "请先选择小程序")]
        public string AppId { get; set; }

    }
    /// <summary>
    /// 设备类型关联的小程序列表
    /// </summary>
    public class DeviceAppListS2CDto
    {
        /// <summary>
        /// 主键
        /// </summary>
        public Guid Id { get; set; }
        /// <summary>
        /// 设备类型
        /// </summary>
        public string DevType { get; set; }
        /// <summary>
        /// 小程序appid
        /// </summary>
        public string AppId { get; set; }
        /// <summary>
        /// 状态,0-不可用,1-可用
        /// </summary>
        public StatusType Status { get; set; }
        /// <summary>
        /// 小程序名称
        /// </summary>
        public string AppName { get; set; }
    }
    /// <summary>
    /// 设备类型关联的小程序删除
    /// </summary>
    public class DeviceAppDeleteC2SDto
    {
        /// <summary>
        /// 记录ID
        /// </summary>
        public Guid Id { get; set; }
    }
}
