fix #119
This commit is contained in:
parent
f47886ccf0
commit
7153da14eb
1 changed files with 11 additions and 3 deletions
|
|
@ -7,13 +7,21 @@ export const useProjectsStore = defineStore('projects', () => {
|
|||
const projects = ref([]);
|
||||
|
||||
const currentProjects = computed(() => {
|
||||
return projects.value.filter((project) => project.status === 'listed');
|
||||
return projects.value
|
||||
.filter((project) => project.status === 'listed')
|
||||
.sort((a, b) => new Date(b.modified) - new Date(a.modified));
|
||||
});
|
||||
|
||||
const draftProjects = computed(() => {
|
||||
return projects.value.filter((project) => project.status === 'draft');
|
||||
return projects.value
|
||||
.filter((project) => project.status === 'draft')
|
||||
.sort((a, b) => new Date(b.modified) - new Date(a.modified));
|
||||
});
|
||||
|
||||
const archivedProjects = computed(() => {
|
||||
return projects.value.filter((project) => project.status === 'unlisted');
|
||||
return projects.value
|
||||
.filter((project) => project.status === 'unlisted')
|
||||
.sort((a, b) => new Date(b.modified) - new Date(a.modified));
|
||||
});
|
||||
|
||||
const api = useApiStore();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue