![]() Server : Apache System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64 User : corals ( 1002) PHP Version : 7.4.33 Disable Function : exec,passthru,shell_exec,system Directory : /home/corals/old/vendor/dvdoug/boxpacker/docs/ |
Limited supply boxes ==================== In standard/basic use, BoxPacker will assume you have an adequate enough supply of each box type on hand to cover all eventualities i.e. your warehouse will be very well stocked and the concept of "running low" is not applicable. However, if you only have limited quantities of boxes available and you have accurate stock control information, you can feed this information into BoxPacker which will then take it into account so that it won't suggest a packing which would take you into negative stock. To do this, have your box objects implement the ``BoxPacker\LimitedSupplyBox`` interface which has a single additional method over the standard ``BoxPacker\Box`` namely ``getQuantityAvailable()``. The library will automatically detect this and use the information accordingly.