How can PHP take the shopping cart ID array sent by pist and classify these shopping carts according to the stores they belong to? For example, if [1,2,3,4,5] shopping cart items are posted, 1 and 2 belong to store A. , 3 and 4 belong to store B, and 5 belongs to store C. Then according to the three major categories of ABC stores, the shopping cart products under the respective stores are formatted into json format and output
How can PHP take the shopping cart ID array sent by pist and classify these shopping carts according to the stores they belong to? For example, if [1,2,3,4,5] shopping cart items are posted, 1 and 2 belong to store A. , 3 and 4 belong to store B, and 5 belongs to store C. Then according to the three major categories of ABC stores, the shopping cart products under the respective stores should be formatted into json format and output