mirror of
https://github.com/SkalaraAI/skbeta.git
synced 2025-04-09 15:00:18 -04:00
23 lines
999 B
TypeScript
23 lines
999 B
TypeScript
import { z } from "zod";
|
|
|
|
export const taskSchema = z.object({
|
|
id: z.string(),
|
|
name: z.string(),
|
|
description: z.string(),
|
|
project_id: z.string(), // Assuming project_id should also be included
|
|
project_name: z.string(),
|
|
project_description: z.string(),
|
|
project_stack: z.array(z.string()),
|
|
feature_id: z.string().nullable(),
|
|
feature_name: z.string().nullable(), // feature_name could be nullable if a task might not have a related feature
|
|
feature_description: z.string().nullable(), // same as feature_name
|
|
status: z.enum(["backlog", "todo", "in_progress", "done"]).optional(),
|
|
priority: z.string().nullable(),
|
|
order: z.number().int().optional(), // Assuming you want to keep the order field
|
|
due_date: z.string().nullable().optional(), // If due_date is used and should be in ISO string format
|
|
assignee: z.string().nullable(), // Assuming assignee is a string
|
|
// Add any other fields from the task table if necessary
|
|
});
|
|
|
|
export type Task = z.infer<typeof taskSchema>;
|