//
//  RDSRoomModel.h
//  Temperature
//
//  Created by RD on 2022/11/30.
//

#import "FFDataBaseModel.h"
#import "RDSDeviceHeader.h"

NS_ASSUME_NONNULL_BEGIN

@interface RDSRoomModel : FFDataBaseModel

//{
//"control_number" = "";
//duration = 0;
//"fan_speed" = 0;
//"fan_value" = 0;
//"home_id" = 1t7svi01jj7cooma3lun6c0100gbaxdn;
//"home_name" = "";
//humidity = 0;
//"is_master" = 0;
//mode = 0;
//name = "\U623f\U95f41";
//power = 0;
//"record_id" = 1t7svi02ksccoq9g3qy8k9a1204g9h2i;
//"set_temp" = 0;
//temperature = 0;
//"timer_status" = 0;
//"user_id" = "";
//}

@property (nonatomic, strong) NSString *name;           //名称
@property (nonatomic, strong) NSString *type;           //
@property (nonatomic, strong) NSString *record_id;      // 记录id
@property (nonatomic, strong) NSString *control_number; // 分控编号
@property (nonatomic, strong) NSString *code;           // 设备类型 code
@property (nonatomic, strong) NSString *device_type_name;
@property (nonatomic, strong) NSString *icon;



@property (nonatomic, strong) NSString *home_name;      // 家名称
@property (nonatomic, strong) NSString *home_id;        // 家id
@property (nonatomic, strong) NSString *user_id;        //

// 设备状态
@property (nonatomic, assign) RDSDeviceType deviceType;

@property (nonatomic, assign) BOOL is_master;           // 是否是主控
@property (nonatomic, assign) int air_quality;          // 空气质量 pm2.5
@property (nonatomic, assign) int temperature;          // 温度
@property (nonatomic, assign) int humidity;             // 湿度
@property (nonatomic, assign) int co2;                  // co2
@property (nonatomic, assign) int set_temp;             // 当前设置的温度
@property (nonatomic, assign) BOOL power;               // 主控状态
@property (nonatomic, assign) BOOL new_fan;             // 新风开关
@property (nonatomic, assign) int mode;                 // 模式（1：制冷2：制热 3：除湿 4：送风 5：新风 6：加湿）
@property (nonatomic, assign) int fan_speed;            // 风速（1，2，3，4，5）
@property (nonatomic, assign) BOOL sleep_mode;          // 睡眠模式是否开启（true 和 false）
@property (nonatomic, assign) int fan_value;            // 风阀档位
@property (nonatomic, assign) BOOL timer_status;        // 定时状态
@property (nonatomic, strong) NSNumber *duration;       // 定时时长
@property (nonatomic, assign) BOOL is_online;           // 在线状态


+ (void)rds_getRoomListFinished:(void(^)(NSError *error))finished;
+ (void)rds_delRoomId:(NSString *)record_id finished:(void(^)(NSError *error))finished;

/// 获取房间详情
- (void)rds_getRoomDetailFinished:(void(^)(NSError *error))finished;

/// 获取房间实时状态
- (void)rds_getRoomStatusFinished:(void(^)(NSError *error))finished;
@end

NS_ASSUME_NONNULL_END
