-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
24 changed files
with
1,743 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
<template> | ||
<el-breadcrumb separator="/"> | ||
<el-breadcrumb-item :to="{ path: '/' }">Goliac</el-breadcrumb-item> | ||
<el-breadcrumb-item :to="{ path: '/repositories' }">repositories</el-breadcrumb-item> | ||
</el-breadcrumb> | ||
<el-divider /> | ||
|
||
<el-row> | ||
<el-col :span="20" :offset="2"> | ||
<el-row> | ||
<el-table | ||
:data="repositories" | ||
:stripe="true" | ||
:highlight-current-row="false" | ||
v-on:row-click="goToRepository" | ||
:default-sort="{ prop: 'name', order: 'descending' }" | ||
> | ||
<el-table-column prop="name" align="left" label="Repository name" sortable /> | ||
<el-table-column prop="public" align="left" label="Public" /> | ||
<el-table-column prop="archived" align="left" label="Archived" /> | ||
</el-table> | ||
</el-row> | ||
</el-col> | ||
</el-row> | ||
</template> | ||
|
||
<script> | ||
import Axios from "axios"; | ||
import constants from "@/constants"; | ||
import helpers from "@/helpers/helpers"; | ||
const { handleErr } = helpers; | ||
const { API_URL } = constants; | ||
export default { | ||
name: "RepositoriesApp", | ||
components: { | ||
}, | ||
data() { | ||
return { | ||
repositories: [], | ||
}; | ||
}, | ||
created() { | ||
this.getRepositories() | ||
}, | ||
methods: { | ||
goToRepository(row) { | ||
this.$router.push({ name: "repository", params: { repositoryId: row.name } }); | ||
}, | ||
getRepositories() { | ||
Axios.get(`${API_URL}/repositories`).then(response => { | ||
let repositories = response.data; | ||
this.repositories = repositories | ||
}, handleErr.bind(this)); | ||
}, | ||
} | ||
}; | ||
</script> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,120 @@ | ||
<template> | ||
<el-breadcrumb separator="/"> | ||
<el-breadcrumb-item :to="{ path: '/' }">Goliac</el-breadcrumb-item> | ||
<el-breadcrumb-item :to="{ path: '/repositories' }">repositories</el-breadcrumb-item> | ||
<el-breadcrumb-item>{{ repositoryid }} repository</el-breadcrumb-item> | ||
</el-breadcrumb> | ||
<el-divider /> | ||
|
||
<el-row> | ||
<el-col :span="20" :offset="2"> | ||
<el-card> | ||
<template #header> | ||
<div class="card-header"> | ||
<el-text>{{repositoryid}} repository</el-text> | ||
</div> | ||
</template> | ||
<div class="flex-container"> | ||
<el-text>Public : </el-text> | ||
<el-text>{{ repository.public}}</el-text> | ||
</div> | ||
<div class="flex-container"> | ||
<el-text>Archived : </el-text> | ||
<el-text>{{ repository.archived}}</el-text> | ||
</div> | ||
</el-card> | ||
</el-col> | ||
</el-row> | ||
|
||
<el-row> | ||
| ||
</el-row> | ||
|
||
<el-row> | ||
<el-col :span="20" :offset="2"> | ||
<el-card> | ||
<el-text>Team with write access</el-text> | ||
<el-table | ||
:data="writers" | ||
:stripe="true" | ||
:highlight-current-row="false" | ||
v-on:row-click="goToTeam" | ||
:default-sort="{ prop: 'name', order: 'descending' }" | ||
> | ||
<el-table-column prop="name" align="left" label="Team Name" sortable /> | ||
|
||
</el-table> | ||
</el-card> | ||
</el-col> | ||
</el-row> | ||
|
||
<el-row> | ||
| ||
</el-row> | ||
|
||
<el-row> | ||
<el-col :span="20" :offset="2"> | ||
<el-card> | ||
<el-text>Team with read access</el-text> | ||
|
||
<el-table | ||
:data="readers" | ||
:stripe="true" | ||
:highlight-current-row="false" | ||
v-on:row-click="goToTeam" | ||
:default-sort="{ prop: 'name', order: 'descending' }" | ||
> | ||
<el-table-column prop="name" align="left" label="Team Name" sortable /> | ||
|
||
</el-table> | ||
</el-card> | ||
</el-col> | ||
</el-row> | ||
</template> | ||
|
||
<script> | ||
import Axios from "axios"; | ||
import constants from "@/constants"; | ||
import helpers from "@/helpers/helpers"; | ||
const { handleErr } = helpers; | ||
const { API_URL } = constants; | ||
export default { | ||
name: "RepositoryApp", | ||
components: { | ||
}, | ||
computed: { | ||
repositoryid() { | ||
return this.$route.params.repositoryId; | ||
}, | ||
}, | ||
data() { | ||
return { | ||
repository: {}, | ||
readers: [], | ||
writers: [], | ||
}; | ||
}, | ||
created() { | ||
this.getRepository() | ||
}, | ||
methods: { | ||
goToTeam(row) { | ||
this.$router.push({ name: "team", params: { teamId: row.name } }); | ||
}, | ||
getRepository() { | ||
Axios.get(`${API_URL}/repositories/${this.repositoryid}`).then(response => { | ||
let repository = response.data; | ||
this.repository = repository | ||
this.readers=repository.readers | ||
this.writers=repository.writers | ||
}, handleErr.bind(this)); | ||
}, | ||
} | ||
}; | ||
</script> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.