feat: add core backend modules, inventory services, and patch scripts for AI Pharmacy API

This commit is contained in:
2026-09-15 11:15:15 +05:30
parent 22a03043ea
commit 1f9378d96c
41 changed files with 1413 additions and 130 deletions
+20
View File
@@ -0,0 +1,20 @@
import { pool } from './src/db/pool';
async function run() {
try {
const batchNo = "FIX-act_admin";
await pool.query(`
INSERT INTO batches (batch_no, tenant_id, product_id, expiry, qty_on_hand, purchase_price)
VALUES ($1, $2, $3, $4, $5, $6)
ON CONFLICT DO NOTHING
`, [batchNo, 'act_admin', 'prd_1789110114931', '2028-12-31', 5000, 10.00]);
console.log(`Added 5000 stock for act_admin`);
} catch (e) {
console.error(e);
} finally {
process.exit();
}
}
run();