mirror of
https://github.com/xinnan-tech/xiaozhi-esp32-server.git
synced 2026-07-29 04:03:56 +08:00
删除多余代码
This commit is contained in:
@@ -19,30 +19,15 @@ public class VoiceDTO implements Serializable {
|
|||||||
|
|
||||||
@Schema(description = "音色名称")
|
@Schema(description = "音色名称")
|
||||||
private String name;
|
private String name;
|
||||||
|
|
||||||
@Schema(description = "音频播放地址")
|
@Schema(description = "音频播放地址")
|
||||||
private String voiceDemo;
|
private String voiceDemo;
|
||||||
|
|
||||||
// 添加双参数构造函数,保持向后兼容
|
// 添加双参数构造函数,保持向后兼容
|
||||||
public VoiceDTO(String id, String name) {
|
public VoiceDTO(String id, String name) {
|
||||||
this.id = id;
|
this.id = id;
|
||||||
this.name = name;
|
this.name = name;
|
||||||
this.voiceDemo = null;
|
this.voiceDemo = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
// 为了兼容性,添加其他可能的音频字段别名
|
|
||||||
@Schema(hidden = true)
|
|
||||||
public String getDemoUrl() {
|
|
||||||
return voiceDemo;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Schema(hidden = true)
|
|
||||||
public String getAudioUrl() {
|
|
||||||
return voiceDemo;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Schema(hidden = true)
|
|
||||||
public String getReferenceAudio() {
|
|
||||||
return voiceDemo;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user