feat(ops): 工单取消后语音播报"当前工单已取消"
新增 VoiceTemplate.ORDER_CANCELLED 常量,handleCancelled 在自动调度 下一个任务之前先通过 TTS 队列播报取消通知,与完成流程保持一致。 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -123,6 +123,13 @@ public class CleanNotificationConstants {
|
||||
*/
|
||||
public static final String ORDER_COMPLETED = "太棒啦,工单已完成";
|
||||
|
||||
// ==================== 工单取消播报 ====================
|
||||
|
||||
/**
|
||||
* 工单取消播报
|
||||
*/
|
||||
public static final String ORDER_CANCELLED = "当前工单已取消";
|
||||
|
||||
// ==================== 待办增加播报 ====================
|
||||
|
||||
/**
|
||||
|
||||
@@ -404,7 +404,10 @@ public class CleanOrderEventListener {
|
||||
updateExt.setCompletedTime(LocalDateTime.now());
|
||||
cleanExtMapper.insertOnDuplicateKeyUpdate(updateExt);
|
||||
|
||||
// 2. 业务日志由 OrderLifecycleManagerImpl.cancelOrder() 统一记录,此处不重复
|
||||
// 2. 语音播报通知保洁员工单已取消
|
||||
if (deviceId != null) {
|
||||
playVoice(deviceId, CleanNotificationConstants.VoiceTemplate.ORDER_CANCELLED, orderId);
|
||||
}
|
||||
|
||||
// 3. 自动调度下一个等待任务(如果有 assignee)
|
||||
if (deviceId != null) {
|
||||
|
||||
Reference in New Issue
Block a user