Questions tagged [quote]

Denotes questions related to the quote on Magento (creation, management, modification, relations)

Filter by
Sorted by
Tagged with
3 votes
2 answers
2k views

Load customer Quote Error in magento 2.1 EE

Once the customer is logged in or creating account, Load Customer Quote Error is getting. Can you please help me solve this ? Thank you
2 votes
2 answers
1k views

How to update record using multiple conditions in CollectionFactory magento 2

I am trying to update the record but it creates a new record. Collection factory <?php namespace Webkul\Mpquotesystem\Block; use Webkul\Mpquotesystem\Model\ResourceModel\Quoteconversation; ...
0 votes
1 answer
1k views

Bundle product in quote

Would be someone please be so kind and explained me structure of bundle products? I need to retrieve products in quote no matter if they belong to bundle or not, but if I get bundle product's item, ...
0 votes
2 answers
1k views

How to get cart items using customer id in magento 1.9

I am trying to get the cart items for particular customer id. I am getting products but it's displaying in two times. For example: If the cart has two products here it's displaying four products, ...
6 votes
1 answer
2k views

Adding products to cart programmatically with custom price in controller: Magento 2

I am having a module that is creating quotes using the Magento quote module. It is using the \Magento\Quote\Model\QuoteFactory for creating the quotes. Now I have added a button "Proceed to ...
4 votes
3 answers
5k views

When Quote id generated in magento?

I’m working with Magento and trying to understand when the quote ID is generated. Specifically, I want to know whether it is generated when a customer gets registered or when a customer adds a product ...
9 votes
3 answers
2k views

Magento 2: How to get discount price for each cart rule in quote

I need to get all discounted price from each cart rule which is applied on current quote. I am getting applied rule ids from $quote->getAppliedRuleIds() and I am getting total discounted amount but ...
1 vote
1 answer
2k views

Magento 2 : Save quote

What is the Difference between $this->quoteRepository->save($quote); & $quote->save(); In below code public function aroundApply_shipping( \StripeIntegration\Payments\Api\...
1 vote
2 answers
3k views

How to save order comment programmatically in magento2?

1)I'm creating custom order comment text box in sales->order->create new order . 2) Created order_comment column in sales_ order grid/quote. 3) I need to save order comment text box value into db....
5 votes
1 answer
4k views

How to get quote and update total through AJAX Magento 1.9

In cart page when postal code is entered and pressed get quote button then it submits one form and shows the rate of that postal code after that update button appears and clicking on that updates the ...
1 vote
1 answer
3k views

Magento 2 : How Can I Update Quote Total

I am creating functionality for additional donation. I am trying to add donation amount in quote total but it will not reflect. This my code portion of that part : <?php namespace ...
4 votes
3 answers
2k views

Magento 2: What is the best way to observe cart change to modify cart item in magento 2?

I'm using Magento v2.3.4 and i want to modify the cart item, if there is an update on the cart (add to cart, update cart item, and remove cart item). Currently I'm using plugin for quote collectTotals(...
0 votes
2 answers
3k views

Magento 2: Create order from quote without quote submit

I want to create order from quote programmatically without submit quote. Because if customer redirect to failure page then we have one button like Make payment which redirect to customer on checkout ...
3 votes
2 answers
3k views

How to reload the quote or cart in Magento 2

I am working on ajax cart. When i update the cart qty, I am trying to reload the quote but its not loading properly $this->cart->getQuote()->getShippingAddress()->collectShippingRates()-&...
4 votes
1 answer
1k views

Magento2 SOAP API for multi-store

Background: I am planning to use Magento2 web-service using SOAP. This will be for Mobile App where customer are allowed to add to cart then checkout. The store will be a multi-store website where ...
3 votes
1 answer
4k views

Can't Access Quote from checkout session after returning from payment Gateway

I am building payment gateway extension and i am facing small issue to get the quote object after control return from payment Gateway. Let me explain you in detail. I am using below funtion to ...
2 votes
1 answer
2k views

magento 2 remove shipping amount from cart total

I want to remove shipping amount from cart page because we do not provide estimate shipping amount calculation block. Also, when customer add product to cart then its display grand total without ...
2 votes
0 answers
304 views

Magento 2 update quote StoreId ($quote->setStoreId()) or Store ($quote->setStore()) not working

Try to catch the quote items, it's working fine. But when quote is not in default website, the request is empty. How to change website ID or store ID in quote request? Did try with: $quote->...
2 votes
3 answers
6k views

How to get quote Id using sales_quote_collect_totals_after events

I have create a programmatically order. But when submit order sales_quote_collect_totals_after events fire before save collect totals. Here is my code : $storeId = Mage::app()->getStore()->...
0 votes
1 answer
2k views

Extract total tax amount from Quote when using TaxJar

I have run into an issue with a Magento 1.9 instance that uses TaxJar. I am trying to extract the total tax on the Quote. With a standard Magento 1.9 instance, I can get the total tax as follows $tax ...
1 vote
1 answer
2k views

Magento 2 : How to update Quote Customer?

I want to move all cart items of a current customer with another customer(move all cart items to another customer cart items). In other words, I want to share One Customer Cart items with another ...
2 votes
1 answer
2k views

Quote with no items - add to cart error

I'm facing this strange issue on add to cart action: sometime after I checkout (with a registered customer) correctly my order, if I try to purchase another item I got the following error: Call to a ...
2 votes
1 answer
3k views

How to change Tax percentage during checkout

We would like to change the Tax percentage on my current order during checkout. Current setup: Magento 2.1.4 Magestore OneStepCheckout Current challenge: We currently ask our customers some ...
0 votes
1 answer
4k views

Magento 2 : No such entity with %fieldName

I am getting this error any thoughts, why this error appearing ? "message": "No such entity with %fieldName = %fieldValue", "parameters": { "fieldName&...
3 votes
1 answer
2k views

How to create duplicate new quote from old order quote Magento 1.7?

I want to create a new order programmatically by copying an existing order's quote. Here is what I have tried: <?php ini_set('display_errors', 1); ini_set('display_startup_errors', 1); ...
2 votes
2 answers
1k views

Magento 2 - setCustomPrice() does not work after Quote Item Update

I've been struggling with this issue for the past few weeks now. My goal is to set a custom price for an item after I edit them on Cart. Basically, I'm using an observer on the event ...
1 vote
1 answer
2k views

Magento2 set custom shipping amount when create order programatically

We have created a custom shipping method using the custom module and trying to save the shipping amount based on the subtotal ex: if subtotal < 25 shipping amount is $5 if subtotal > 25 shipping ...
5 votes
1 answer
2k views

Update quote item price without using custom price

We are developing a custom module which applies custom tier prices by product category. Our solution works on frontend checkout so far and consists of observing the sales_quote_item_set_product event ...
2 votes
2 answers
3k views

Can I change the taxes on a quote item in magento2 programmatically?

I need to change the tax rate on quote items in a magento2 checkout process that is entirely done programmatically. What I've found from various resources here on stackoverflow is that is possible to ...
1 vote
1 answer
2k views

How to get current Cart_id/quote_id in plugin file Magento 2?

namespace Asm\Setsellerid\Plugin; use Magento\Quote\Model\Cart\Totals\ItemConverter; use Magento\Quote\Api\Data\TotalsItemExtensionFactory; class Item { /** * @var TotalsItemExtensionFactory ...
0 votes
1 answer
1k views

Add value for custom quote item attribute using REST api

I want to add value for custom quote attribute using rest api. This attribute is not a product attribute. I have created a database column in quote_item table. Also created the plugin on class Magento\...
0 votes
1 answer
2k views

Magento 2: Change quote base currency programmatically?

I am creating orders programmatically in Magento 2. I wanted to change the order base currency. The current currency is my custom currency, irrespective of currency available in Store as I don't want ...
0 votes
2 answers
54 views

i am fetching the data from database and display in magento admin grid, and the grid display blank

I have tried all of my thinking, I don't understand why the grid displays a blank Controller namespace StateDrives\RequestQuote\Controller\Adminhtml\Bulkquote; use Magento\Backend\App\Action; use ...
0 votes
1 answer
2k views

Restore quote in magento2

I have canceled the current order like use Magento\Sales\Model\OrderFactory; $order = $this->orderFactory->create()->loadByIncrementId($order->getIncrementId()); $order->cancel()->...
1 vote
1 answer
27 views

Itemcollection get latest updated_at item - Magento 2.4

We use the following code, to get the last item that was most recent updated. $itemsCollection = $cart->getQuote()->getItemsCollection(); $itemsCollection->getSelect()->order('updated_at ...
5 votes
1 answer
9k views

Getting No such entity with cartId = {quoteId} on Guest Checkout issue

I saw several posts about this issue, with getting the following error message: No such entity with cartId = {quoteId} but none of them worked for me :( Or I didn't find exactly what is the cause of ...
1 vote
0 answers
52 views

Magento 2 - How can I update the cart summary totals when quote grand total is modified

I have a controller that is called by ajax in the cart page. A gift card amount is passed to the controller and a function then updates the quote grand total based on that amount. protected ...
6 votes
1 answer
634 views

Multiple currency not working with custom price quote - Magento 2

I created quote with custom price from Magento admin, it works fine but it does not work multiple currency. e.g) I created quote to customer with custom price $10 (USD currency), when customer checks ...
0 votes
2 answers
1k views

Magento 1 - Error adding product to quote: This product is currently out of stock [duplicate]

Trying to add product to a Quote and getting message that it is Out of Stock event though I set it to In Stock. I have tried several things but here is the current code: $product = Mage::getModel('...
0 votes
1 answer
242 views

magento 2 How to store Customer Address custom attribute value quote_address table column

I have created customer address type custom attribute and it's value store as custom attribute now I want to store this value on quote address column. I have create observer ...
0 votes
2 answers
78 views

REST API PUT /V1/carts/mine

Trough the rest API I'm trying to achieve that customers can save their cart/quote and have another new active one. For that I'm trying to figure what PUT /V1/carts/mine does, as the docs states that ...
0 votes
0 answers
184 views

Magento 2 How to update quote totals information from admin

Magento 2.4.5-p1 version using. We want to give custom discount via our custom module Using this code - <?php namespace Namespce\Modulename\Controller\Adminhtml\Quote; use Magento\Backend\App\...
0 votes
0 answers
258 views

Magento 2 : Graphql setShippingAddressesOnCart default query duplicates the addresses in quote_address table

I'm using Magento version 2.4.5-p1 And I'm trying to setShippingAddressesOnCart using graphql for logged-in customers. This is the default Magento setShippingAddressesOnCart query I'm using but it's ...
1 vote
0 answers
122 views

Coupon code is not saving at quote table in magento 2

I upgraded my website from 2.3.6-p1 to 2.4.5-p1 . After that when i applied the cart rule with coupon code, it shows the error that The coupon code "GHSDYFEWFCER" is not valid. When ...
1 vote
1 answer
173 views

Magento 2 - Customer sometimes receiving 503 Error when performing random actions on the cart

I'm experiencing an issue where customers are intermittently receiving a 503 error (maintenance flag) when performing certain actions on the cart in Magento 2. For example, in one scenario, a guest ...
4 votes
2 answers
5k views

Magento 2 : how to convert custom quote field to order field

I added a new field "management_fee" on table "quote" properly. I add this field on "sales_order" field too. I would like to update this field on sales_order table while quote is converting to order. ...
0 votes
1 answer
1k views

When will predispatch event be called?

I want to know, if controller_action_predispatch_checkout_cart_add will only be called, when a product is added to cart from product page, or if this event will also be called, when I add a ...
0 votes
1 answer
131 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
979 views

Extension_attribute value save in DB in magento 2

I am using Magento 2.3.4, and i created custom attibute in quote_item 'up_flag'. and throgh rest api i am passing the value of "up_flag": Post request Body for V1/carts/mine/items: {"...
0 votes
1 answer
1k views

how to get customer selected shipping method code from quote in magento2

how to get shipping method carrier code as $rate->getCarrier() from quote.

1
2 3 4 5
13