feat(stock): stok kategorileri, ürün tipleri, hareketler ve FIFO SKT
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -7,6 +7,7 @@ import { getDb } from "@/lib/db/mongo";
|
||||
import { connectMongoose } from "@/lib/db/mongoose";
|
||||
import { toObjectId } from "@/lib/object-id";
|
||||
import { installDefaultCategories } from "@/features/categories/service";
|
||||
import { installDefaultStockCategories } from "@/features/stock/service";
|
||||
import { HouseholdModel } from "@/models/household";
|
||||
import { HouseholdMemberModel } from "@/models/household-member";
|
||||
import type { HouseholdSettings } from "@/shared/schemas/household";
|
||||
@@ -324,6 +325,8 @@ export async function adminCreateHousehold(
|
||||
);
|
||||
// Varsayılan Türkçe kategori seti aynı transaction'da (Bölüm 6.2).
|
||||
await installDefaultCategories(household!._id, actor, session);
|
||||
// Varsayılan stok kategorileri (gider eşlemesi yukarıdaki kategorilerden).
|
||||
await installDefaultStockCategories(household!._id, actor, session);
|
||||
});
|
||||
return ok({ id: createdId });
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user