first of all, when picking materials, you can clearly identify which department it belongs to, and then directly record it. If it is unclear, you can set up a public department, or share it according to a certain proportion (for example, according to the proportion of product income or the proportion of product quantity). The accounting entries are all the same: main business cost --XX department loan: raw material loan: main business cost.