Skip to content

Commit d119c35

Browse files
authored
Merge pull request flipped-aurora#1183 from WangLeonard/bugfix/fix_commit_in_about
修复关于我们中的提交时间
2 parents 3420a9d + 1c4f574 commit d119c35

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

web/src/view/about/index.vue

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@
8686
<el-timeline-item
8787
v-for="(item,index) in dataTimeline"
8888
:key="index"
89-
timestamp="2018/4/12"
89+
:timestamp="item.from"
9090
placement="top"
9191
>
9292
<el-card>
@@ -116,6 +116,7 @@ export default {
116116
<script setup>
117117
import { ref } from 'vue'
118118
import { Commits, Members } from '@/api/github'
119+
import {formatTimeToStr} from "@/utils/date";
119120
const page = ref(0)
120121
121122
const loadMore = () => {
@@ -129,7 +130,7 @@ const loadCommits = () => {
129130
data.forEach((element) => {
130131
if (element.commit.message) {
131132
dataTimeline.value.push({
132-
from: new Date(element.commit.author.date),
133+
from: formatTimeToStr(element.commit.author.date, 'yyyy-MM-dd'),
133134
title: element.commit.author.name,
134135
showDayAndMonth: true,
135136
message: element.commit.message,

0 commit comments

Comments
 (0)