Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
B
book-app
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
EzijingWeb
book-app
Commits
f1271eae
提交
f1271eae
authored
3月 04, 2024
作者:
yueweilu
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
1、我的笔记才能删除
2、音频校验空数据 3、解析数据判空
上级
1921b708
隐藏空白字符变更
内嵌
并排
正在显示
6 个修改的文件
包含
20 行增加
和
9 行删除
+20
-9
mine.dart
lib/models/mine.dart
+3
-1
note_controller.dart
lib/pages/read_web/note_controller.dart
+8
-4
controller.dart
lib/pages/user_notes_des/controller.dart
+6
-4
high.dart
lib/pages/user_notes_des/widgets/high.dart
+1
-0
line.dart
lib/pages/user_notes_des/widgets/line.dart
+1
-0
note.dart
lib/pages/user_notes_des/widgets/note.dart
+1
-0
没有找到文件。
lib/models/mine.dart
浏览文件 @
f1271eae
...
...
@@ -366,7 +366,9 @@ class NoteModel {
content
=
json
[
'content'
];
positioning
=
json
[
'positioning'
];
// noteContent = json['note_content'];
noteContent
=
json
[
'note_content'
]
!=
null
?
NoteContentModel
.
fromJson
(
json
[
'note_content'
])
:
null
;
if
(
types
==
3
){
noteContent
=
json
[
'note_content'
]
!=
null
?
NoteContentModel
.
fromJson
(
json
[
'note_content'
])
:
null
;
}
color
=
json
[
'color'
];
chapterName
=
json
[
'chapter_name'
];
isMy
=
json
[
'is_my'
];
...
...
lib/pages/read_web/note_controller.dart
浏览文件 @
f1271eae
...
...
@@ -103,11 +103,13 @@ class NoteController extends GetxController {
);
for
(
NoteModel
noteModel
in
result
){
if
(
noteModel
.
noteContent
!.
audio
!.
isNotEmpty
){
for
(
MediaModel
mediaModel
in
noteModel
.
noteContent
!.
audio
!){
Duration
?
duration
=
await
just_audio
.
AudioPlayer
().
setUrl
(
mediaModel
.
content
??
''
);
if
(
noteModel
.
noteContent
!=
null
&&
noteModel
.
noteContent
!.
audio
!=
null
){
if
(
noteModel
.
noteContent
!.
audio
!.
isNotEmpty
){
for
(
MediaModel
?
mediaModel
in
noteModel
.
noteContent
!.
audio
!){
Duration
?
duration
=
await
just_audio
.
AudioPlayer
().
setUrl
(
mediaModel
?.
content
??
''
);
mediaModel
.
duration
=
Tools
.
formatDuration
(
duration
!);
mediaModel
?.
duration
=
Tools
.
formatDuration
(
duration
!);
}
}
}
}
...
...
@@ -127,6 +129,7 @@ class NoteController extends GetxController {
refreshController
.
resetFooter
();
}
catch
(
error
)
{
refreshController
.
finishRefresh
(
IndicatorResult
.
fail
);
Console
.
log
(
'error-----------------------
$error
'
);
}
}
...
...
@@ -139,6 +142,7 @@ class NoteController extends GetxController {
await
_getNotes
();
refreshController
.
finishLoad
();
}
catch
(
error
)
{
Console
.
log
(
'error-----------------------
$error
'
);
refreshController
.
finishLoad
(
IndicatorResult
.
fail
);
}
}
...
...
lib/pages/user_notes_des/controller.dart
浏览文件 @
f1271eae
...
...
@@ -77,11 +77,13 @@ class UserNotesDesController extends GetxController {
types:
tag
);
for
(
NoteModel
noteModel
in
result
){
if
(
noteModel
.
noteContent
!.
audio
!.
isNotEmpty
){
for
(
MediaModel
mediaModel
in
noteModel
.
noteContent
!.
audio
!){
Duration
?
duration
=
await
just_audio
.
AudioPlayer
().
setUrl
(
mediaModel
.
content
??
''
);
if
(
noteModel
.
noteContent
!=
null
&&
noteModel
.
noteContent
!.
audio
!=
null
){
if
(
noteModel
.
noteContent
!.
audio
!.
isNotEmpty
){
for
(
MediaModel
?
mediaModel
in
noteModel
.
noteContent
!.
audio
!){
Duration
?
duration
=
await
just_audio
.
AudioPlayer
().
setUrl
(
mediaModel
?.
content
??
''
);
mediaModel
.
duration
=
Tools
.
formatDuration
(
duration
!);
mediaModel
?.
duration
=
Tools
.
formatDuration
(
duration
!);
}
}
}
}
...
...
lib/pages/user_notes_des/widgets/high.dart
浏览文件 @
f1271eae
...
...
@@ -26,6 +26,7 @@ class BuildHigh extends StatelessWidget {
],
),
child:
Slidable
(
enabled:
model
.
isMy
==
1
?
true
:
false
,
endActionPane:
ActionPane
(
motion:
const
ScrollMotion
(),
children:
[
...
...
lib/pages/user_notes_des/widgets/line.dart
浏览文件 @
f1271eae
...
...
@@ -26,6 +26,7 @@ class BuildLine extends StatelessWidget {
],
),
child:
Slidable
(
enabled:
model
.
isMy
==
1
?
true
:
false
,
endActionPane:
ActionPane
(
motion:
const
ScrollMotion
(),
children:
[
...
...
lib/pages/user_notes_des/widgets/note.dart
浏览文件 @
f1271eae
...
...
@@ -31,6 +31,7 @@ class BuildNote extends StatelessWidget {
],
),
child:
Slidable
(
enabled:
model
.
isMy
==
1
?
true
:
false
,
endActionPane:
ActionPane
(
motion:
const
ScrollMotion
(),
children:
[
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论