Questions tagged [commerce]

One of the modules that implements an eCommerce framework and ecosystem is the Drupal Commerce module.

Filter by
Sorted by
Tagged with
0
votes
0answers
8 views

Custom payment form for a custom payment method type [on hold]

I have a custom payment method and I want to had a custom payment form. The payment happens on site and I don't use credit card. I want something like a manual payment but with a payment form to ...
0
votes
1answer
7 views

Create a text field product attribute [on hold]

I am building a website on Drupal 8 with Commerce 2. In a previous version of the website, I used Commerce Product Option (https://www.drupal.org/project/commerce_option) to create fillable text ...
-4
votes
0answers
13 views

Classified advertisements website [on hold]

Can any of the Drupal software used to develop a classified advertisements website? If yes, which module(s) is (are) required? Best wishes, Alfredo
0
votes
1answer
22 views

Unable to add Quantity in Stock in Drupal Commerce 8 using Commerce Stock Module

I have enabled Commerce Stock Modules and its submodules 1. Commerce Stock API 2. Commerce Stock Field 3. Commerce Stock Local Storage 4. Commerce Stock UI Created a Product Type ABC and added a ...
0
votes
1answer
12 views

Views Add Link to product field missing

I have a search results View which list the (Commerce) products. I show the title and the image fields. I those fields to wrap in a custom <a> link tag. When I am adding fields, I miss the 'Link ...
2
votes
2answers
86 views

Allow some products to be sold only in bundles (groups) with some other products

I'm making a commerce site with Drupal 8 and Drupal commerce and I have a not so common request. Some of the products should be available to buy only in groups (bundles) with some other products. E.g. ...
-2
votes
0answers
12 views

How to bulk compute a computed field [on hold]

I added a computed field to an existing commerce product type. Now I want to bulk compute the field for all products. How can this be achieved? I'm using Drupal 8
0
votes
0answers
9 views

How do I retrieve tagged nodes as well as untagged?

I have a View, "Product Reviews", that retrieves all Product Review nodes (custom content type) that are tagged to the Product you're currently viewing. So, if you're on the page for Product XYZ, this ...
0
votes
1answer
19 views

Following Drupal 8 Commerce custom offer tutorial, but getting “name already in use” error

I am following the tutorial for creating a custom offer at the official Drupal 8 Commerce documentation. But I'm getting an error that I pasted below when I click on any of the conditions, and none ...
0
votes
0answers
20 views

Creating block of category 'commerce' to show shopping cart contents

I am new to drupal, and am trying to create a commerce page. I have created a basic page, and I am now trying to add a block which lists the products in the shopping cart. I am using an existing ...
0
votes
0answers
21 views

PHP Incomplete class Object Error on creating a custom Checkout flow Plugin in Drupal 8

I have created the custom checkout flow plugin in drupal 8. And added the required steps in it as per the the commerce2 documentation. See the code below. <?php namespace Drupal\commerce_custom\...
0
votes
0answers
7 views

How to change the product title shown on Commerce Registration pane on checkout

My question is linked to Commerce Registration during the checkout in the page where the user adds his information. Commerce Registration shows the product title instead of the product display title ...
0
votes
1answer
11 views

Hooking into page specific instance of checkout flow form

I'm working on manipulating the buttons used for the checkout flow of using D8 Commerce 2. I'm using MYMODULE_form_commerce_checkout_flow_multistep_default_alter but its changing both the form buttons ...
0
votes
1answer
51 views

Print custom product variation field in order email confirmation

Added custom field ('field_secretkey') under Commerce - Product variation (admin/commerce/config/product-variation-types). I am able to get this value in Orders view by adding the "Product variation"...
-3
votes
0answers
19 views

Not complete checkout process with payflow link

I am using Payflow link module for paid user registration. When i checkout and enter all details.and click on Pay Now link, I return to my website but order not created and payment also not completed. ...
-1
votes
0answers
6 views

Display the field after payment of the product

i using commerce 2 (drupal 8 ). I have a product that I'm going to show field after pay in product?
0
votes
0answers
20 views

Get price value in Webform submission

I'm trying to create a webform that has an entity selection element linked to an entity reference view that has a selection of products from the commerce module listed. So far this has all been ...
0
votes
1answer
35 views

Checking for string in variable fails in twig

I'm working on a twig template for use with a commerce product. Each product has a term applied to it like "Green Ball", "Yellow Ball", "Red Block", and "Purple Block". I'm trying to take the ...
0
votes
0answers
14 views

Commerce 2 onReturn order must stay at it's current state

I'm working on a new type of payment gateway with these steps: 1. The client is redirected to the payment gateway. 2. Client returns from payment gateway with payment information BUT THE PAYMENT CAN ...
0
votes
0answers
19 views

Creating a Product Display Catalog via taxonomy Drupal 8

I need to create a catalog system for a product range from taxonomy in Drupal 8 My taxonomy is structured like this : - Product Category 1 -- Sub Cat 1 -- Product 1 -- Product 2 ...
0
votes
2answers
62 views

How to prevent programmatically created blocks from caching

I've been working with Drupal 7 for a couple of years but am new to Drupal 8, and am just getting into building custom modules. What I have built is a module that alters Drupal Commerce in order to ...
0
votes
0answers
9 views

Setting up Drupal commerce orders being sent to company erp system

I am new to Drupal and therefore bear with me. This might be a really simple question. Instead of using any of the payment functionality in drupal Commerce 2x i want the order to be sent to my ...
-1
votes
0answers
16 views

Custom offsite payment module (redirection)

I've created a small module to add a custom payment method to my drupal commerce website, but I have a problem with the redirection to the offsite platform. Here is my payment method infos : ...
0
votes
0answers
6 views

How do I email the file?

I am trying to send files 'purchased' with commerce file as HTML mail. I've created a rule that loops over the line items (commerce-order:commerce-line-items). I would like to get access to the ...
1
vote
1answer
14 views

Handling anonymous orders in custom commerce module

Drupal: 8.7.2 Commerce: 2.13 I have a custom module set up that adds the following functionality to Commerce: It prevents the user from adding more than one item to their cart. If they try to add a ...
0
votes
0answers
7 views

How can I make volume (tier) discount across multiple products variants

I'm looking for a solution to make it possible to give the customer a volume discount if he buys product A or product B. I tried with the module "Commerce pricelist" https://www.drupal.org/project/...
0
votes
0answers
10 views

How to mix preset amounts and a user entered amount in commerce

I am implementing donations functionality with Drupal commerce 2.x I have found a patch that allows for a direct checkout form (kind of "buy now" button) https://www.drupal.org/project/commerce/...
1
vote
1answer
25 views

Custom checkout pane for order comments not saving

I've created a custom checkout pane for commerce 2.x, Drupal version 8.7.x. I've added a textfield called field_order_notes on the order entity. The pane works, and I can run $this->order->set('...
-1
votes
1answer
41 views

Other twig syntax in templates

In some twig templates of the commerce modules, I can see the use of an alternate syntax: Ex. in commerce-cart-flyout-offcanvas-contents-items.html.twig : <% _.each(cart.order_items, function(...
0
votes
0answers
17 views

Altering Shipping/Billing address inline entity form

Now that Drupal 8 Commerce moved to Inline Entity Form approach. I am having trouble of altering Address for fields for the checkout... In the past I could do this: function ...
0
votes
1answer
23 views

How to change order currency in cart/checkout page?

I want to change the price of the order in the cart/checkout page. Let's say I have a product ABC with $100(USD) and I added that in cart. But after adding I want to change the currency to EUR and ...
1
vote
0answers
37 views

How can I round up price matrix percentage to two decimals?

I'm looking for a way to round the percentage from Drupal 8 Commerce Shipping Price Matrix module to cents in USD. Is this possible? I found this function in the commerce_shipping_price_matrix/src/ ...
0
votes
0answers
16 views

Error: Class 'Drupal\Component\Render\FormattableMarkup' not found in custome_module()

I have been working to insert a edit link for each row in a table for that... function my_sub() { $results = db_query("SELECT * FROM {my_form}"); $header = array(t('NAME'), t('EMAIL-ID'), t('...
0
votes
1answer
49 views

Capture amount on order state change

I would like to know if it is possible to capture payments by subscribing to order transition events. Example: Transaction mode: Authorize only On order placed - Capture some amount (application fee)...
0
votes
0answers
19 views

Displaying Field Collection Items of a Commerce Product in Twig

I'm trying to display field values within a field collection for a commerce product. In my product template file I'm simply outputting {{ product.field_components }} then using a separate field ...
0
votes
0answers
15 views

Reserve stock on order complete not working

I am working on Commerce 2.x and I am trying to reduce the stock value when someone adds an item in the cart. When I check the stock config there is an option to check the Reserve the stock on order ...
0
votes
1answer
15 views

Rules to clear commerce cart on adding new item of a different product type

I've several product type with corresponding product displays. The scenario is a case where there is only a product type per time on the cart. That is, you cannot have multiple product types at the ...
0
votes
0answers
11 views

Accessing submitted values in Drupal commerce checkout form alter

I have added a checkbox to the Drupal commerce checkout form using hook_form_alter. I have also added a submit handler to the form but when I try to use $form_state->getValues() in the submit ...
0
votes
1answer
7 views

How do you get Product Variation Type fields and display modes to show up when displaying Products in a View?

I've created a Product Variation Type for all my products, all of which have the following custom fields: Display Title, Subtitle, and Top Rated Product? (boolean checkbox): When setting up a View to ...
1
vote
0answers
18 views

Need to add SKU to order confirmation email - Commerce 2

I have been able to customize the order confirmation email twig file for a client to some degree, however when it comes to adding the SKU for each item ordered I cannot find a way to have it populate. ...
0
votes
0answers
25 views

Commerce Dunning and how to send notification to users with credit cards expiring soon

I am using Drupal Commerce with Commerce Card on File and the Commerce Recurring Framework to bill recurring payments. There is a desire to send email notifications to users stating their credit ...
0
votes
0answers
13 views

Ubercart 7x Migration to Commerce 8.x with Drush?

I've been experimenting with upgrading an Ubercart 7.x site to Commerce 8.x and I haven't had much luck so far. The migration process times out when using the migrate UI, so I've tried re-running the ...
0
votes
0answers
17 views

How to print contact email in the receipt email?

I've got a question regarding receipt emails. I saw the doc about customization of receipt emails espacially the available theme_hooks. I'll need to get the contact info (email) in the receipt email....
0
votes
0answers
23 views

Commerce 2: Custom Checkout Pane Plugin

I'm fairly new to OOP and am trying to create a custom checkout pane. I need to collect some input from the buyer at this point. I have figured out how to add the questions to the Order Information ...
0
votes
1answer
28 views

Pay order only after it been placed and validated

I need to create a following workflow for the store checkout: The user adds a product(s) to a cart. The user goes to checkout. During checkout, the user can register or authenticate on site. This is ...
0
votes
1answer
41 views

“Add to Cart” button/from in template (form ID from Node ID)?

I'm working on a website made with D7 and the Commerce Module, with a "Products" view (for the Product content type) having this relationship field: (Products referenced by field_info_prodotto) ...
0
votes
0answers
6 views

Show widget of count product only on the one view mode of product

How to show widget of count product only on the one view mode of product? Example: Show on the full mode, but hide on the teaser mode.
0
votes
0answers
11 views

How to implement a price resolved Commerce 2 adjust the prices of items already in the cart?

I have a custom PriceResolverInterface to calculate discounts based on quantities. However, the returned, adjusted price only affects the item(s) currently being added to the cart and does not adjust ...
0
votes
0answers
24 views

Custom CSS for Entity Print Views

I need to print Cart form view in drupal 8 site. I have installed Entity Print & Entity Print Views. I can generate pdf successfully using tcpdf pdf file or debug version does not considering css. ...
0
votes
1answer
19 views

Add product - price and sku field missing

When I want to add a product, the field price and SKU are missing. Running on Drupal 8.7.1 on MAMP on macOS and PHP 7.1.23 Any idea?