John:
Your explanation of the process is not very clear. Is Company A buying all of the inventory for both companies and then transferring (selling I would assume as there has to be an accounting transaction) inventory to Company B? Company A needs to create receivable and Company B needs to create a payable.
Is this process directly linked (every time Company A buys inventory some is transferred to Company B or does the transfers occur randomly?
I have created similar solutions for my clients and may be able to help you out. Feel free to contact me directly if you would like to discuss this further.