提交 1c4f5745 编写于 作者: L Leonard Wang

修复关于我们中的提交时间

上级 3420a9de
......@@ -86,7 +86,7 @@
<el-timeline-item
v-for="(item,index) in dataTimeline"
:key="index"
timestamp="2018/4/12"
:timestamp="item.from"
placement="top"
>
<el-card>
......@@ -116,6 +116,7 @@ export default {
<script setup>
import { ref } from 'vue'
import { Commits, Members } from '@/api/github'
import {formatTimeToStr} from "@/utils/date";
const page = ref(0)
const loadMore = () => {
......@@ -129,7 +130,7 @@ const loadCommits = () => {
data.forEach((element) => {
if (element.commit.message) {
dataTimeline.value.push({
from: new Date(element.commit.author.date),
from: formatTimeToStr(element.commit.author.date, 'yyyy-MM-dd'),
title: element.commit.author.name,
showDayAndMonth: true,
message: element.commit.message,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册