@davoodmehraban89 / Factor-easy-2 Mirror · read-only / commits / 3985588
Fork 0

سامانه صدور فاکتور و حسابداری

Mirrored from https://github.com/davoodmehraban89/Factor-easy.git

Synced Dec 4, 09:15 UTC

fix(company): enforce active-company scope through js/phase5-enterprise.js runtime paths

davoodmehraban89 committed Oct 14, 2026 at 11:39 UTC 398558800444014d0d2c5698c84d6cdedbf2cc39
1 file changed +1 -1
js/phase5-enterprise.js
+1 -1
@@ -1,6 +1,6 @@
1 /* Phase 5 — complementary ERP: inventory, assets, FX, analytics, import/backup and integration outbox */
2 const P5_LABELS={opening:'افتتاحیه',adjustment_in:'تعدیل افزایشی',adjustment_out:'تعدیل کاهشی',transfer:'انتقال'};
3 -function p5Owned(k){const cid=afCompanyId();return(datastore[k]||[]).filter(x=>x.ownerUserId===currentUser?.id&&(!x.companyId||x.companyId===cid))}
3 +function p5Owned(k){return finoraScopedRows(k)}
4 function getMyWarehouses(){return p5Owned('warehouses')} function getMyStockMovements(){return p5Owned('stockMovements')}
5 function getMyInventoryCounts(){return p5Owned('inventoryCounts')} function getMyFixedAssets(){return p5Owned('fixedAssets')}
6 function getMyAssetDepreciations(){return p5Owned('assetDepreciations')} function getMyCurrencies(){return p5Owned('currencies')}