This commit is contained in:
zhenorzz 2022-03-21 14:08:27 +08:00
parent a783e6472d
commit 054474ce74
5 changed files with 15 additions and 15 deletions

View File

@ -115,7 +115,7 @@ func (FtpRepo) CommitLog(projectID int64, rows int) ([]CommitInfo, error) {
} }
func (ftpRepo FtpRepo) BranchLog(projectID int64, branch string, rows int) ([]CommitInfo, error) { func (ftpRepo FtpRepo) BranchLog(projectID int64, branch string, rows int) ([]CommitInfo, error) {
return []CommitInfo{{}}, nil return []CommitInfo{{Commit: "virtual"}}, nil
} }
func (ftpRepo FtpRepo) TagLog(projectID int64, rows int) ([]CommitInfo, error) { func (ftpRepo FtpRepo) TagLog(projectID int64, rows int) ([]CommitInfo, error) {

View File

@ -116,16 +116,16 @@ func (sftpRepo SftpRepo) Follow(project model.Project, _ string) error {
} }
func (SftpRepo) RemoteBranchList(url string) ([]string, error) { func (SftpRepo) RemoteBranchList(url string) ([]string, error) {
return []string{"master"}, nil return []string{"virtual"}, nil
} }
func (SftpRepo) BranchList(projectID int64) ([]string, error) { func (SftpRepo) BranchList(projectID int64) ([]string, error) {
return []string{"master"}, nil return []string{"virtual"}, nil
} }
func (SftpRepo) CommitLog(projectID int64, rows int) ([]CommitInfo, error) { func (SftpRepo) CommitLog(projectID int64, rows int) ([]CommitInfo, error) {
commitInfo := CommitInfo{ commitInfo := CommitInfo{
Branch: "master", Branch: "virtual",
Commit: "", Commit: "",
Author: "", Author: "",
Timestamp: time.Now().Unix(), Timestamp: time.Now().Unix(),
@ -137,7 +137,7 @@ func (SftpRepo) CommitLog(projectID int64, rows int) ([]CommitInfo, error) {
} }
func (sftpRepo SftpRepo) BranchLog(projectID int64, branch string, rows int) ([]CommitInfo, error) { func (sftpRepo SftpRepo) BranchLog(projectID int64, branch string, rows int) ([]CommitInfo, error) {
return []CommitInfo{{}}, nil return []CommitInfo{{Commit: "virtual"}}, nil
} }
func (sftpRepo SftpRepo) TagLog(projectID int64, rows int) ([]CommitInfo, error) { func (sftpRepo SftpRepo) TagLog(projectID int64, rows int) ([]CommitInfo, error) {

View File

@ -54,7 +54,7 @@
width="200" width="200"
show-overflow-tooltip show-overflow-tooltip
/> />
<el-table-column label="time" width="135" align="center"> <el-table-column label="time" width="155" align="center">
<template #default="scope"> <template #default="scope">
{{ parseTime(scope.row.timestamp) }} {{ parseTime(scope.row.timestamp) }}
</template> </template>

View File

@ -53,7 +53,7 @@
width="200" width="200"
show-overflow-tooltip show-overflow-tooltip
/> />
<el-table-column label="time" width="135" align="center"> <el-table-column label="time" width="155" align="center">
<template #default="scope"> <template #default="scope">
{{ parseTime(scope.row.timestamp) }} {{ parseTime(scope.row.timestamp) }}
</template> </template>

View File

@ -41,7 +41,7 @@
sortable="custom" sortable="custom"
prop="id" prop="id"
label="ID" label="ID"
width="80" width="70"
align="center" align="center"
/> />
<el-table-column <el-table-column
@ -52,18 +52,18 @@
sortable="custom" sortable="custom"
> >
<template #default="scope"> <template #default="scope">
<b v-if="scope.row.environment === 1" style="color: #f56c6c"> <span v-if="scope.row.environment === 1" style="color: #f56c6c">
{{ scope.row.name }} - {{ scope.row.name }} -
{{ $t(`envOption[${scope.row.environment || 0}]`) }} {{ $t(`envOption[${scope.row.environment || 0}]`) }}
</b> </span>
<b v-else-if="scope.row.environment === 3" style="color: #e6a23c"> <span v-else-if="scope.row.environment === 3" style="color: #e6a23c">
{{ scope.row.name }} - {{ scope.row.name }} -
{{ $t(`envOption[${scope.row.environment || 0}]`) }} {{ $t(`envOption[${scope.row.environment || 0}]`) }}
</b> </span>
<b v-else style="color: #909399"> <span v-else style="color: #909399">
{{ scope.row.name }} - {{ scope.row.name }} -
{{ $t(`envOption[${scope.row.environment || 0}]`) }} {{ $t(`envOption[${scope.row.environment || 0}]`) }}
</b> </span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
@ -123,7 +123,7 @@
<el-table-column <el-table-column
prop="updateTime" prop="updateTime"
:label="$t('time')" :label="$t('time')"
width="160" width="155"
align="center" align="center"
sortable="custom" sortable="custom"
/> />