Skip to content
This repository has been archived by the owner on Aug 3, 2024. It is now read-only.

Commit

Permalink
update dashboard to apiv3
Browse files Browse the repository at this point in the history
  • Loading branch information
Geometrically committed Mar 30, 2024
1 parent 3b0216c commit ae2d83c
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions pages/moderation/review.vue
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
>
<Avatar :src="project.icon_url" size="xs" no-shadow raised />
<span class="stacked">
<span class="title">{{ project.title }}</span>
<span class="title">{{ project.name }}</span>
<span>{{ $formatProjectType(project.inferred_project_type) }}</span>
</span>
</nuxt-link>
Expand Down Expand Up @@ -133,7 +133,7 @@ const projectsFiltered = computed(() =>
projects.value.filter(
(x) =>
projectType.value === 'all' ||
app.$getProjectTypeForUrl(x.project_type, x.loaders) === projectType.value
app.$getProjectTypeForUrl(x.project_types[0], x.loaders) === projectType.value
)
)
Expand Down Expand Up @@ -163,7 +163,7 @@ const projectTypes = computed(() => {
})
if (projects.value) {
const teamIds = projects.value.map((x) => x.team)
const teamIds = projects.value.map((x) => x.team_id)
const organizationIds = projects.value.filter((x) => x.organization).map((x) => x.organization)
const url = `teams?ids=${encodeURIComponent(JSON.stringify(teamIds))}`
Expand All @@ -177,7 +177,7 @@ if (projects.value) {
projects.value = projects.value.map((project) => {
project.owner = members.value
.flat()
.find((x) => x.team_id === project.team && x.role === 'Owner')
.find((x) => x.team_id === project.team_id && x.role === 'Owner')
project.org = orgs.value.find((x) => x.id === project.organization)
project.age = project.queued ? now - app.$dayjs(project.queued) : Number.MAX_VALUE
project.age_warning = ''
Expand All @@ -187,7 +187,7 @@ if (projects.value) {
project.age_warning = 'warning'
}
project.inferred_project_type = app.$getProjectTypeForUrl(
project.project_type,
project.project_types[0],
project.loaders
)
return project
Expand All @@ -201,7 +201,7 @@ async function goToProjects() {
await router.push({
name: 'type-id',
params: {
type: project.project_type,
type: project.project_types[0],
id: project.slug ? project.slug : project.id,
},
state: {
Expand Down

0 comments on commit ae2d83c

Please sign in to comment.