using Nirvana.Common;
using System;
using System.Threading.Tasks;
using Waste.Domain;

namespace Waste.Application
{
    /// <summary>
    /// 设备管理
    /// </summary>
    public interface IDeviceService
    {
        /// <summary>
        /// 设备列表
        /// </summary>
        /// <param name="param"></param>
        /// <returns></returns>
        Task<PageParms<DeviceList>> GetListAsync(QueryParams param);

        /// <summary>
        /// 设备信息提交
        /// </summary>
        /// <param name="role"></param>
        /// <returns></returns>
        Task<ResultInfo> SubmitFormAsync(DeviceSubmit role);

        /// <summary>
        /// 详情
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        Task<DeviceSubmit> DetailAsync(Guid id);

        /// <summary>
        /// 设备批量操作
        /// </summary>
        /// <param name="deviceBatchModel"></param>
        /// <returns></returns>
        Task<ResultInfo> BatchSetAsync(DeviceBatchModel deviceBatchModel);

        /// <summary>
        /// 设备详情数据
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        Task<DeviceDetailS2Dto> DeviceDetailAsync(Guid id);

        /// <summary>
        /// 设备状态修改
        /// </summary>
        /// <param name="id">设备ID</param>
        /// <param name="status">设备状态,0-停用,1-正常,2-激活</param>
        /// <returns></returns>
        Task<ResultInfo> SetStatusAsync(Guid id, int status);

        /// <summary>
        /// 配置设备推送信息
        /// </summary>
        /// <param name="input"></param>
        /// <returns></returns>
        Task<ResultInfo> SetConfigAsync(DeviceConfigC2SDto input);

        /// <summary>
        /// 批量配置千灯镇商户推送
        /// </summary>
        /// <returns></returns>
        Task SetQDConfig();

        /// <summary>
        /// 获取设备配置详情
        /// </summary>
        /// <param name="id">设备ID</param>
        /// <returns></returns>
        Task<W_DeviceConfig> GetConfigAsync(Guid id);
    }
}