Skip to main content

Questions tagged [quoteitem]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
2 answers
27 views

Magento 2.4: Save item option value in cart and retrieve it in order success

I have created a button for each product in the cart. Now I want to get the uploaded file URLs of each product from the cart and retrieve it in an email on order success. My controller: <?php ...
mechanic's user avatar
  • 440
0 votes
2 answers
32 views

Magento2 | Recover order increment id from Observer of an Reorder

For the reorder function, I added an Observer in my custom module that allows me to extract the quote_id. Actually my real goal is to get the increment id of the order I am reordering for. Currently ...
Jackom's user avatar
  • 493
0 votes
1 answer
20 views

Magento 2 - Change value Quote item when I add to cart via Reorder button

I am trying to change a custom value each time I add to the cart via the “reorder” button. Right now I am trying to do this in the file “Magento\Sales\Model\Reorder\Reorder.php” but without success. ...
Jackom's user avatar
  • 493
0 votes
2 answers
30 views

how to get quote item of the current quote?

how to get quote item of the current quote? i have already get the quote i'll share some code . $quote = $this->quoteFactory->create()->load(13); //echo "<pre>";print_r($...
Afnan Ahmad's user avatar
0 votes
0 answers
137 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 <URL> was blocked ...
saravankg's user avatar
0 votes
1 answer
175 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()...
Syed Hassan Zamir's user avatar
0 votes
1 answer
107 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 ...
Niraj Patel's user avatar
2 votes
1 answer
278 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 ...
vadim vadim's user avatar
2 votes
2 answers
436 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-...
Mohmad Ashik M A's user avatar
0 votes
0 answers
184 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 ...
Magento2-learner's user avatar
1 vote
0 answers
299 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\...
Surreal Disco's user avatar
2 votes
1 answer
313 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 ...
bhargav shastri's user avatar
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 ...
Divya Rawat's user avatar
0 votes
0 answers
477 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 ...
tanu's user avatar
  • 22
0 votes
0 answers
146 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 */ $...
Jancy Abraham's user avatar
0 votes
0 answers
116 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?
user4095519's user avatar
0 votes
0 answers
186 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.
NewDeveloper's user avatar
0 votes
1 answer
146 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 , ...
J. Doe's user avatar
  • 259
0 votes
1 answer
559 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. ...
Niraj Patel's user avatar
0 votes
2 answers
173 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($...
Franci Melink's user avatar
1 vote
0 answers
219 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
Nagaraju Kasa's user avatar
0 votes
1 answer
858 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 ...
Harshit Laddha's user avatar
0 votes
1 answer
521 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 ...
Ronak's user avatar
  • 476
0 votes
0 answers
201 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.
amesh's user avatar
  • 561
0 votes
1 answer
51 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 ...
Jackom's user avatar
  • 493
1 vote
2 answers
538 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\...
Tanmay's user avatar
  • 790
1 vote
0 answers
503 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:...
Rafael Fagundes's user avatar
0 votes
2 answers
1k 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 ...
Lokesh Naik's user avatar
1 vote
0 answers
83 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 ...
Ravi Soni's user avatar
  • 1,809
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 ...
tarek fellah's user avatar
2 votes
1 answer
747 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
Sabareesh's user avatar
  • 358
0 votes
0 answers
179 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 ...
Sabareesh's user avatar
  • 358
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.
Badong's user avatar
  • 101
1 vote
2 answers
309 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 ...
Martin Peasley's user avatar
1 vote
1 answer
197 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 ...
Avesh Naik's user avatar
  • 1,208
1 vote
0 answers
102 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][...
Claudio Pomo's user avatar
0 votes
1 answer
211 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 ...
Arunendra's user avatar
  • 7,458
0 votes
1 answer
161 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 ...
Joe_Coder's user avatar
1 vote
0 answers
211 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\...
Vishwas Bhatnagar's user avatar
0 votes
1 answer
814 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 ...
Robinio's user avatar
  • 771
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\...
Jafar Pinjar's user avatar
  • 1,949
0 votes
1 answer
19 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); ...
Masud Shaikh's user avatar
  • 1,189
2 votes
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 ...
Ketan Borada's user avatar
  • 2,613
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/...
Ketan Borada's user avatar
  • 2,613
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="...
Manjunath's user avatar
  • 177
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()-&...
summu's user avatar
  • 847
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, \...
user3109848's user avatar
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 ...
Kite Hany's user avatar
  • 235
2 votes
0 answers
263 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
jibin george's user avatar
2 votes
3 answers
794 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;...
Kite Hany's user avatar
  • 235