Separate Shopping Carts by Seller Setup on 1C-Bitrix Marketplace
When a buyer adds items from different sellers, the question arises: how to process the order? Single order (like on Wildberries) or multiple separate ones (like on Avito)? Both variants are achievable on Bitrix but require different approaches.
Option 1: Visually Separate Carts, Single Payment
The b_sale_basket is unified in the database, but the interface groups items by seller's UF_VENDOR_ID. Buyer sees sections "Seller A" and "Seller B" with separate totals. Payment is one transaction for total amount.
During checkout, one b_sale_order is created, but sub-orders for each seller are generated in background (table mp_sub_orders). Sellers see only their sub-orders.
Visual separation implementation in sale.basket.basket component template: in template.php group $arResult['ITEMS'] by UF_VENDOR_ID before display:
$itemsByVendor = [];
foreach ($arResult['ITEMS'] as $item) {
$vendorId = CIBlockElement::GetByID($item['PRODUCT_ID'])->GetNext()['UF_VENDOR_ID'];
$itemsByVendor[$vendorId][] = $item;
}
Pros: one payment, better UX for buyer. Cons: more complex to split amounts on partial cancellation.
Option 2: Separate Orders for Each Seller
On checkout, system creates separate b_sale_order for each seller. Buyer receives multiple order confirmations and makes multiple payments (or one via aggregator with split).
Implementation via custom checkout handler: standard CSaleOrder::Add() flow is replaced with custom handler that splits basket by UF_VENDOR_ID and creates multiple orders in loop.
Pros: each order is independent, easier status and refund management. Cons: inconvenient for buyer with many sellers.
Delivery with Separate Carts
With single cart and multiple sellers, delivery becomes complex: each seller may have different methods and costs. Possible approaches:
- Unified delivery by marketplace (platform aggregates all items)
- Separate delivery choice for each seller (buyer chooses separately)
- Pickup from marketplace location (common)
Delivery configuration for specific scheme — separate task.
Timeline
Visual cart separation without changing order logic — 3–5 days. Full separation with separate order creation — 1–2 weeks. With custom delivery logic by sellers — up to 3 weeks.







