feat: implement purchase receipt items management with create, update, find, and delete functionalities

feat: add purchase receipts management with create, update, find, and delete functionalities

feat: implement sales invoice items management with create, update, find, and delete functionalities

feat: add sales invoices management with create, update, find, and delete functionalities

feat: implement stock adjustments management with create, update, find, and delete functionalities

feat: add stock balance retrieval functionality

feat: implement stock movements management with create, update, find, and delete functionalities
This commit is contained in:
2025-12-09 13:59:07 +03:30
parent a782d61890
commit 807f6c2087
98 changed files with 26109 additions and 501 deletions
+18
View File
@@ -0,0 +1,18 @@
SELECT
`sm`.`productId` AS `productId`,
`sm`.`id` AS `movement_id`,
`sm`.`type` AS `type`,
`sm`.`quantity` AS `quantity`,
`sm`.`fee` AS `fee`,
`sm`.`totalCost` AS `totalCost`,
`sb`.`quantity` AS `balance_quantity`,
`sb`.`avgCost` AS `balance_avg_cost`,
`sm`.`createdAt` AS `createdAt`
FROM
(
`pos`.`Stock_Movements` `sm`
LEFT JOIN `pos`.`stock_balance` `sb` ON((`sb`.`ProductId` = `sm`.`productId`))
)
ORDER BY
`sm`.`productId`,
`sm`.`createdAt`