Feat added internal notes
Runner Test / test (pull_request) Successful in 15s
Runner Test / test (push) Successful in 15s

This commit is contained in:
Jeighdy Tanamal
2026-09-24 15:54:28 -07:00
parent 79b485db56
commit bbf6a90e18
11 changed files with 141 additions and 8 deletions
+5
View File
@@ -96,6 +96,7 @@ export async function findOrderDetail(context: DatabaseContext, orderId: string)
id: header.order.id,
orderNumber: header.order.orderNumber,
status: header.order.status as OrderDetail["status"],
notes: header.order.notes,
createdAt: header.order.createdAt,
updatedAt: header.order.updatedAt,
customer: {
@@ -127,6 +128,10 @@ export async function updateOrderTimestamp(context: DatabaseContext, orderId: st
await context.db.update(orders).set({ updatedAt }).where(eq(orders.id, orderId));
}
export async function updateOrderNotes(context: DatabaseContext, orderId: string, notes: string, updatedAt: string) {
await context.db.update(orders).set({ notes, updatedAt }).where(eq(orders.id, orderId));
}
export async function updateOrderStatus(context: DatabaseContext, orderId: string, status: OrderDetail["status"], updatedAt: string) {
await context.db.update(orders).set({ status, updatedAt }).where(eq(orders.id, orderId));
}