4.28 高质量运营修改评论发送

This commit is contained in:
jl-zhoujl2
2023-04-28 15:17:58 +08:00
parent a7e390941a
commit b2ec38ec08

View File

@ -77,6 +77,7 @@ const Detail: React.FC<DetailLocationProps> = (props) => {
})
}
const getCommentList = (reId: string, count: number) => {
if (listRef.current) { listRef.current.scrollTo({ top: 0 }); }
const array = [...new Array(count)].map(() => ({ loading: true, createrName: "", context: "", createTime: "" }));
setCommentList(array.concat(commentRef.current));
setLoading(true);
@ -118,7 +119,6 @@ const Detail: React.FC<DetailLocationProps> = (props) => {
} else if (data.length > 2) {
count = data.length + 2;
}
if (listRef.current) { listRef.current.scrollTo({ top: 0 }); }
getCommentList(reId, count);
}
}