diff --git a/public/css/edu-purge.css b/public/css/edu-purge.css index de4566eb..1ec10446 100644 --- a/public/css/edu-purge.css +++ b/public/css/edu-purge.css @@ -1760,6 +1760,14 @@ a.decoration { margin-bottom: 10px; } +.mb12 { + margin-bottom: 12px; +} + +.mb13 { + margin-bottom: 13px; +} + .mb14 { margin-bottom: 14px; } diff --git a/src/forge/Component/User.jsx b/src/forge/Component/User.jsx index 8cdd3e54..0d970173 100644 --- a/src/forge/Component/User.jsx +++ b/src/forge/Component/User.jsx @@ -3,11 +3,9 @@ import styled from 'styled-components'; import { Link } from 'react-router-dom'; export default ({ url , name , column , id , login })=>{ - console.log(url); - console.log(name); - console.log(id); const Img = styled.span` display:flex; + font-weight: bold; ${column && "flex-direction: column;text-align:center;"} align-items: center; & img{ @@ -18,7 +16,6 @@ export default ({ url , name , column , id , login })=>{ ${!column && ` & span{ margin-left:8px; - font-weight: bold; }` } `; diff --git a/src/forge/Main/CoderRootCommit.js b/src/forge/Main/CoderRootCommit.js index f4492bb1..50f2fb6a 100644 --- a/src/forge/Main/CoderRootCommit.js +++ b/src/forge/Main/CoderRootCommit.js @@ -20,6 +20,12 @@ function returnbar(str){ } return str; } + +function timeFormat(seconds) { + const time = new Date(seconds*1000); + return time.getFullYear()+"-"+(time.getMonth()+1)+"-"+time.getDate()+" "+(time.getHours()+1)+":"+time.getMinutes(); +} + //代码库--提交页面 class CoderRootCommit extends Component{ constructor(props){ @@ -37,8 +43,12 @@ class CoderRootCommit extends Component{ componentDidMount=()=>{ this.Init(); this.getBranchs(); + // goBack + // addEventListener } + // componentde + // 获取分支列表 getBranchs=()=>{ const { projectsId , owner } = this.props.match.params; @@ -91,7 +101,8 @@ class CoderRootCommit extends Component{ image_url:item.author && item.author.image_url, sha:item.sha, time_from_now:item.time_from_now, - message:item.message + message:item.message, + timestamp:item.timestamp }) }) this.setState({ @@ -117,6 +128,7 @@ class CoderRootCommit extends Component{ }) this.getCommitList(branchName , page , limit); } + render(){ const { commitDatas , dataCount , limit , page , isSpining , branchList } = this.state; const { projectDetail, commit_class , defaultBranch } = this.props; @@ -145,35 +157,25 @@ class CoderRootCommit extends Component{
{commit.message}
}
- {branchName}
+ {branchName}