Questions tagged [quoteitem]
The quoteitem tag has no usage guidance.
178
questions
0
votes
0
answers
9
views
Issue - Request to access cookie or storage on “<URL>” was blocked because it came from a tracker and content blocking is enabled
The "Add Quote" button in Magento 2.4 is not opening the quote form, and the console shows the following warning message:
"Request to access cookie or storage on 'https://googleads.g....
0
votes
0
answers
30
views
Setting value on product which is adde to cart?
Magento 2.4.6
Is there a way to set a value on the item which is added to the cart which can be accessed anywhere else, like in templates for example?
I am listening to the ...
0
votes
1
answer
88
views
$quote->getAllVisibleItems() giving same product data on every iteration
I have added some products in cart pragmatically when i Iterate on quote it iterates but on each iteration it is giving same product data
$quote = $this->quoteRepository->get( $quote->getId()...
0
votes
1
answer
67
views
magento 2: debug to addtocart simple product for one qty in stock
I am trying to figure out the flow add to cart item.
Note: before add to cart my cart is empty
I have a simple product and it has one qty and product inStock is yes, it does not go prepare function in ...
1
vote
1
answer
195
views
Duplicate cart items
community!
Bumped into an issue - duplicate items in a cart.
In the quote table, I have multiple quotes for the same customer. Items_count is increased like an exponent, eg 2, 3, 6, 178, 192. In the ...
1
vote
2
answers
349
views
How to change the Product NAME and SKU permanently in quote_item table when it is added to cart?
How to do this? I am using checkout_cart_product_add_after event.
EDIT:
After I did it like this
<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-...
0
votes
0
answers
150
views
How Quote Works in Magento 2 and Data is inserted into Quote and Quote Item Table?
I want to know how Quote system works and how data is inserted into quote tables and how api retrieves data.Everything about quote by pure coding point of view i know that quote is cart object later ...
1
vote
0
answers
268
views
Magento 2.3.7-p3 Unable to save extension attribute to Quote Item
I want to show customers how many 'points' they could be making, per quote item, on each item row of the basket. Using extension attributes, this is what I have:
di.xml
<type name="Magento\...
2
votes
1
answer
270
views
Magento2 quote item row total rounding issue
We are facing issue in quote_item table with row_total column in which its not rounding prices of items. for example please check below screenshot:
14.2250 should be 14.23
15.9750 should be 15.98
We ...
0
votes
1
answer
1k
views
How to add custom column value in quote_item table magento 2
i have added new custom column in quote_item table. i want to add the value in that custom column by item_id in controller.
i have item_id 16,17,18 of quote 3 and i want to add value in custom column ...
0
votes
0
answers
430
views
Magento 2 : Update the product name while adding into the cart
I want to add something with the product name dynamically while adding to the cart. Each product have different concatenation with product name. And that product name should be updated on everywhere ...
0
votes
0
answers
130
views
How to add bundle product to cart using Magento\Quote\Model\Quote\ItemFactory
I want to add bundle products to the cart using \Magento\Quote\Model\Quote\ItemFactory. I have tried the below code and it is working fine.
/** @var \Magento\Quote\Model\Quote\Item $quoteItem */
$...
0
votes
0
answers
112
views
How to get description of a Magento\Quote\Model\Quote\Item object?
Magento 2.3
I am having troubles getting the description of a Magento\Quote\Model\Quote\Item object. I tried using $item->getDescription(), but it returns nothing.
Any ideas?
0
votes
0
answers
176
views
Magento 2 : From where the total discount from cart is returned
I need to know from where the total discount after all validation & calculation is returned for a cart ?
I need to get total discount for a cart/quote.
0
votes
1
answer
123
views
Updating configurable product throws error We can\'t find the quote item. Magento 2
Basically I am trying to update configurable product which has been successfully added to the shopping cart. I can see record of added configurable product item in my database quote, quote_item , ...
0
votes
1
answer
539
views
how to get child item object while adding to cart?
I wanna put customize the code with qty while adding to cart product.
For that I have created Plugin Magento\Quote\Model\Quote\Item and used addQty() method,but in this method I call quoteItem object. ...
0
votes
2
answers
162
views
Magento 1.9 can not remove product fom quote
I have some problem with removing product from quote.
I observe "Add to cart" with "checkout_cart_product_add_after" event and there simply do this:
$quote->removeItem($...
1
vote
0
answers
176
views
Magento2 negotiable quote save programatically
How to create and save the negotiable quote programatically in M2.
Can any one provide some example with dummy data / (or) provide me the test script with simple example please
Thanks
0
votes
1
answer
702
views
How to change Quote Item attributes after adding it to cart?
I want to change almost all the quote item attributes after adding it to care like name,price,sku and almost everything. As we have a requirement where at the runtime only we will decide this ...
0
votes
1
answer
492
views
Magento2 - I want to show custom quote item field to checkout page
I want to show custom quote item field to Checkout Page.
I don't know how would I do that. I've added one custom drop down to Cart page and selected value I saved in quote_item table now I want that ...
0
votes
0
answers
186
views
Remove custom options only from cart item
I want to remove only the custom options added with the cart item without removing the product. Is there any solution for this? I am using Magento 2.3.4 version.
0
votes
1
answer
41
views
Magento 2.3.5 - Remove product groups in the cart programmatically
I'm trying to remove simple and virtual products in groups through a custom form I created.
The code is this and it seems to work but in reality when you reload the page the minicart does not update ...
1
vote
2
answers
473
views
Can not get quote item in custom class
class Productinfo extends \Magento\Framework\View\Element\Template
{
protected $checkoutSession;
protected $quoteFactory;
protected $collection;
/**
* Constructor
*
* @param \Magento\...
1
vote
0
answers
466
views
Remove Item from Cart using before add product Plugin
I'm using magento 2.3 and i'm trying to Remove an especifc Item from Cart, using beforAddProduct Plugin.
The problem is that i don't know how to remove the Item from Cart.
It shows the following error:...
0
votes
2
answers
933
views
Magento 2: Prevent add to cart or qty increase if a product already exists in cart
I want a feature where if a customer tries to add a product which already exists in cart then it should prevent it from adding again or qty increase. Instead I want to show a message that 'The product ...
1
vote
0
answers
82
views
Magento2: How to separate quote?
Like, I have 5 items in my Cart.
It means there is 1 row in quote table. Which contains parent ID.
And, 5 rows in quote_item which describe all 5 items.
I want separate 3 items from these 5 in ...
1
vote
0
answers
2k
views
Add a quote item with a buy request
I would like to get product price with options price using a custom module that calculates product price by formula, i like to use the function without adding the product to the cart.
The function ...
2
votes
1
answer
609
views
I can't understand difference between quote/quoteitems and order/order Items Magento 2.3
I can't Understand the difference between Order And Quote or Order Items And Quote Items please explain what is it and how it works
0
votes
0
answers
163
views
How to show the cart products in email template - Magento 2.3.4
How to show the cart products in the email template i can't loop into email template, and i can't pass the products into email template, I want send mail with the current cart products so I'am working ...
0
votes
2
answers
1k
views
Get Quote_item table data
How can I fetch the data in the quote_item table for a specific item ? I'm trying to get the product name with "gift" at the end.
1
vote
2
answers
263
views
Can't copy data from quote_item to sales_order_item
I have a custom value (In a Magento 2.3.3 installation )that gets added to the quote_item table when I add an item to the basket. When I go to checkout I want to pass that value to the same-named ...
1
vote
1
answer
191
views
Fetching Quote Items of Inactive Cart (Abandoned cart)
I am trying to fetch all the items of a Quote.
First i am load the quote using \Magento\Quote\Api\CartRepositoryInterface
with get() method i am getting Magento\Quote\Api\Data\CartInterface
using ...
1
vote
0
answers
94
views
quoteCartRepositoryV1 serach by nested field
I would apply searchCriteria to /V1/carts/search in order to get all carts which contain specific sku. I've performed this query
https://shop.dicanio.it/rest/all/V1/carts/search?[filterGroups][0][...
0
votes
1
answer
210
views
Unable to get cart item when FPC is enabled Magento 2.3.2
I'm trying to get all cart items in a custom block but unable to get all items, it's throwing an error:
Fatal error: Uncaught Error: Call to a member function getAllItems()
on null in
Block ...
0
votes
1
answer
159
views
Magento 2 - Get all options from a quote item
I need to get all the configurable items related to an item in the cart. For example, if the cart item is of a size "XL", then I need to get all the other options like "S", "M" and "L" together with ...
1
vote
0
answers
202
views
What is replacement of this function for converting order item to quote item
As magento/module-checkout/Model/Cart class is deprecated
/**
* Shopping cart model
*
* @api
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
* @deprecated 100.1.0 Use \Magento\Quote\Model\...
0
votes
1
answer
752
views
How to get is_active column value from quote table ? Magento2
I want to get the value of the is_active column through the method $this-> getQuoteCollection ($customerId) -> getLastItem (), I used getColumnValues('is_active'), but it doesn't return the last ...
0
votes
2
answers
3k
views
Magetno 2: update custom column values for quote item during add to cart
I am calling ajax request and performing add to cart functionality.
Here is my controller code,
use Magento\Framework\App\Action\Action;
use Magento\Framework\App\Action\Context;
use Magento\...
0
votes
1
answer
18
views
Magento 2: How to decrements item qty?
I want to decrements item qty programmatically.
$item = $this->cart->getQuote()->getItemById($itemId);
$qty = $item->getQty();
if($qty > 0) {
$newqty = ($qty - 1);
...
1
vote
1
answer
3k
views
Magento 2 Add extension attributes in Quote Item
I want to add custom attribute in quote items Magento\Quote\Api\Data\CartItemExtensionInterface
<extension_attributes for="Magento\Quote\Api\Data\CartItemExtensionInterface">
<attribute ...
0
votes
3
answers
2k
views
Magento 2 Unable to set custom Price in cart item by API
I'm trying to add an item by API.every thing are working except item price
It's Magento Bug that not take price from API
https://devdocs.magento.com/redoc/2.3/admin-rest-api.html#operation/...
1
vote
2
answers
2k
views
Item not deleting from quote in Magento2
I have used observer to delete the quote item.
Used this event controller_action_predispatch_checkout_index_index
This is the code of my etc/events.xml.
<event name="...
2
votes
1
answer
2k
views
How to get product price from \Magento\Quote\Model\Cart\Totals\Item $item
I need to get the product price from \Magento\Quote\Model\Cart\Totals\Item $item.
I tried this but it doesn't work
/** @var \Magento\Quote\Model\Cart\Totals\Item $item */
$item->getProduct()-&...
0
votes
0
answers
76
views
Get custom attribute from product in ToOrderItem convert method
I'm implementing a plugin for Magento\Quote\Model\Quote\Item\ToOrderItem
public function aroundConvert(\Magento\Quote\Model\Quote\Item\ToOrderItem $subject,
\Closure $proceed,
\...
0
votes
2
answers
3k
views
Get data from Quote_items table in Magento 2
I am new to Magento 2 so I do not understand much about select data from the table in Localhost also which file I need to create
I want to display data from Quote_item table
in the .phtml file, and ...
2
votes
0
answers
231
views
Why cart ID is null even though i can see the id from \Magento\Checkout\Helper\Cart
I am trying to get the cart value, i can get the quote id when i do x-debug.
if i try to get the id i get NULL
Anyone know why i get this
2
votes
3
answers
751
views
Display data from Quote_item error
I have tried to display the data from Quote_item table in the database to file .phtml but it shows this error
the code in Magento/MyHistory/Block/View.php
<?php
namespace Magento\History\Block;...
5
votes
2
answers
6k
views
How to Delete Quote item Based on the condition in magento 2
I have requirement like below.
I need to read all quote items and their sku, against the custom table,
If value matched, need to delete that quote item and update qty 1 for remaining items but this ...
0
votes
1
answer
2k
views
How to update custom column value in quote_item table magento 2
Actually i created custom column in quote_item and trying to update the value once
product added to the cart programmatically magento2 custom module
using Model.
If Anyone have idea please ...
0
votes
1
answer
1k
views
Update all quote items with qty 1 in magento2
I am trying to update all the quote item qty as soon as we navigated to the cart page.
by using below code.
$quote = $this->checkoutSession->getQuote();
$quoteItems = $quote->...