mirror of
https://github.com/marcogll/TaxHacker_s23.git
synced 2026-01-13 21:35:19 +00:00
feat: use structured output, import CSV, bugfixes
This commit is contained in:
@@ -11,6 +11,12 @@ export const getProjects = cache(async () => {
|
||||
})
|
||||
})
|
||||
|
||||
export const getProjectByCode = cache(async (code: string) => {
|
||||
return await prisma.project.findUnique({
|
||||
where: { code },
|
||||
})
|
||||
})
|
||||
|
||||
export const createProject = async (project: Prisma.ProjectCreateInput) => {
|
||||
if (!project.code) {
|
||||
project.code = codeFromName(project.name as string)
|
||||
|
||||
Reference in New Issue
Block a user