提交 5e8ac75d authored 作者: yueweilu's avatar yueweilu

重复请求

上级 38c0ec84
......@@ -20,7 +20,7 @@ class UserNotesDesController extends GetxController {
@override
void onReady() {
onRefresh();
// onRefresh();
super.onReady();
}
......@@ -85,11 +85,14 @@ class UserNotesDesController extends GetxController {
for(NoteModel noteModel in result){
if(noteModel.noteContent!=null && noteModel.noteContent!.audio != null){
if(noteModel.noteContent!.audio!.isNotEmpty){
for(MediaModel? mediaModel in noteModel.noteContent!.audio!){
Duration? duration = await audioPlayer.setUrl(mediaModel?.content??'');
mediaModel?.duration = Tools.formatDuration(duration!);
await Future.forEach(noteModel.noteContent!.audio!, (MediaModel? mediaModel) async {
if (mediaModel != null && mediaModel.content != null) {
Duration? duration = await audioPlayer.setUrl(mediaModel.content!);
if (duration != null) {
mediaModel.duration = Tools.formatDuration(duration);
}
}
});
}
}
}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论