情绪健康提醒 (设置 / 查询)
功能表:supportEmotionHealth
示例
Swift
// 设置
let param = IDOEmotionHealthReminderParamModel(...)
Cmds.emotionHealthReminder(param).send { rs in
if case .success(let obj) = rs {
// 成功
// obj is IDOEmotionHealthReminderReplyModel
}else {
// 失败
}
}
// 查询
Cmds.emotionHealthReminder().send { rs in
if case .success(let obj) = rs, obj.errorCode == 0 {
if (obj.errorCode == 0) {
// 成功
// obj is IDOEmotionHealthReminderReplyModel
}else {
// 失败
}
}else {
// 失败
}
}
Kotlin
// 设置
Cmds.emotionHealthReminder().send {
if (it.error.code == 0) {
// 成功
// it.res is IDOEmotionHealthReminderReplyModel
}else {
// 失败
}
}
// 查询
Cmds.emotionHealthReminder().send {
if (it.error.code == 0 && it.res?.errorCode == 0) {
// 成功
// it.res is IDOEmotionHealthReminderReplyModel
}else {
// 失败
}
}