public function create(StoreOffer $request): JsonResource 	{ 		$productPrice = $totalWeight = 0;  		$offer = Order::create([ 			'is_r1' => $request->boolean('is_r1'), 			'vat_number' => $request->vat_number, 			'company_name' => $request->company_name, 			'email' => $request->email, 			'full_name' => $request->full_name, 			'phone' => $request->phone,  			'delivery_country' => $request->delivery_country, 			'delivery_city' => $request->delivery_city, 			'delivery_address' => $request->delivery_address, 			'delivery_zip_code' => $request->delivery_zip_code,  			'billable_country' => $request->billable_country, 			'billable_city' => $request->billable_city, 			'billable_address' => $request->billable_address, 			'billable_zip_code' => $request->billable_zip_code,  			'description' => $request->description,  			'is_offer' => true, 		]);  		foreach ($request->items as $item) { 			$item_object = OrderItem::getItemModel($item);  			if (!$item_object) { 				continue; 			}  			$offer->orderItems()->create([ 				'item_id' => $item_object->id, 				'item_type' => $item_object->getBillableItemType(), 				'price' => $item_object->getPrice(), 				'quantity' => $item['quantity'], 				'label' => $item_object->getItemName(), 			]);  			$productPrice += $item_object->getPrice() * $item['quantity']; 			$totalWeight += $item['quantity'] * $item_object->weight; 		}  		// 1. shipping price 		$shippingPrice = Order::checkDeliveryServiceAndCalculateShipping($request->delivery_country, $request->delivery_zip_code, $request->items, $totalWeight);  		// 2. product price + shipping price 		$finalPrice = $productPrice + $shippingPrice;  		$offer->update([ 			'price' => $finalPrice, 			'shipping_price' => $shippingPrice, 		]);  		$offer->handleOfferMail();  		return new OrderSingleResource($offer); 	}