KamoCRM

Report leads available for products with no allotment

FixSecurityService
Shipped
21 ஆகஸ்ட், 2026 அன்று 1:47 AM UTC
Author
Kamo
Commit
8452e34

/manage built its whole response by looping over allotments, calling countAssignablePool once per row. But the Manage-Credits grid lists products from the vendor catalogue, not from allotments — so a product nobody held a credit rule for was displayed with 0 available leads no matter how full its pool was. Eleven newly created Farm products read 0 against pools of 11 to 6,730 leads; the one product that did have allotments reported correctly, which made it look like a data problem with the other ten thousand leads. Now also returns leadsByProduct, covering every product in the market, from a single grouped query.

All changes

Like what you see shipping?

All of it arrives in your workspace on its own. Start on the free plan and read this page again in a month.

Start Free ForeverView Pricing