Questions tagged [plugin-craftcommerce]

Use this tag for questions relating to the Craft Commerce product.

Filter by
Sorted by
Tagged with
1
vote
1answer
17 views

LineItems not showing in CMS

I'm scratching my head. My orders are shown perfectly except for one product. I have no idea why so I looked at the Order object before saving and I can't seem to figure out why he won't show the ...
1
vote
2answers
36 views

Add product to cart using code in Craft Commerce plugin

I want to add a specific product to a cart using its ID. I have created a module which runs on Order::EVENT_BEFORE_ADD_LINE_ITEM event. Here I am able to capture the current cart using the below code $...
1
vote
1answer
13 views

Get UI elements of entry in front end

Is is possible to get UI-elements of Craft 3.5 in the front end? Specifically wanting to get hold of the headers I use to separate fields of products. This is my current code: {% set layout = product....
1
vote
1answer
16 views

Empty cart should remove coupon discounts in commerce

Is there anyway to remove all the discounts if cart becomes empty?
1
vote
2answers
42 views

Guest user registration using Commerce 3

I have just started using Craft Commerce (only Lite version currently) and I'm currently trying to get to grips with what is possible. My question is regarding subscriptions. The site that I'm working ...
1
vote
0answers
17 views

Is there a way to react to Control Panel changes to an order?

One of the major issues I have been having with my current project is how to reconcile changes to an order in the control panel (product amounts and the like). I thought I might be able to react to ...
1
vote
1answer
25 views

Free shipping discount on whole order doesn't appear as adjustment

TL;DR : Free shipping on order discounts don't appear as a discount (or any type of) adjuster. So how do I check if a free shipping discount has been applied? Sorry for the long post - hopefully it ...
1
vote
1answer
36 views

Force donation purchasable to replace donation of the same amount in cart

I'm using Craft Commerce Lite and the donation purchasable. I don't want users to ever be able to add more than one donation to the cart. Using the Lite edition stops users from being able to add ...
0
votes
0answers
10 views

How do I send a specific payment source to a subscription?

There doesn't seem to be a way to use a specific card when signing up for a subscription. it will automatically choose the last entered card the user has. I need a way of sending one of the craft....
1
vote
1answer
27 views

Restricting Payment Gatways by User Group using Commerce Pro?

Is it possible to restrict payment gateways on a per user group basis? e.g. Say you want a user group to assign users into from a certain country that cannot use PayPal, so you can offer them a ...
1
vote
1answer
23 views

Commerce Order Status History

I am trying to bring some of the order status history from my clients commerce shop orders into a web page. I seem to be able to get the Current/Previous Status (prevStatus/newStatus.name), but cannot ...
0
votes
0answers
22 views

Add billing address to user on registration

I am working on a craftcms + commerce project and I need to add a billing address to new user during its registration process. The idea is to have a billing address added to any newly registered user ...
1
vote
1answer
33 views

Is there a Zendesk plugin to fetch order information from Craft Commerce?

I'm looking for the same functionality as https://wordpress.org/plugins/mwb-zendesk-woo-order-sync/ but for craftCMS's Commerce plugin and not Wordpress's Woocommerce plugin. Basically, it would use ...
2
votes
1answer
29 views

Error on functions in queue: “Session does not exist in a console request.”

I get the following error on multiple order mails from Craft Commerce. The error points out to the lines where a macro is called: Email template parse error for email “New order”. Order: “e35f244”. ...
1
vote
1answer
35 views

Craft Commerce “state” dropdown field fails to populate with states for new customer addresses

I'm having an issue with addresses on Craft Commerce 3 (specifically the State field). When a new customer adds an address, the State field defaults to a text field (not the expected Select field). If ...
1
vote
2answers
18 views

Commerce Product - show shipping category in template

I have setup some Shipping Categories (8 weeks, 4 weeks etc) and these appear down the side bar of a product when editing in admin next to 'Shipping' . How do i bring this value out via a tag on a ...
0
votes
0answers
31 views

How to differentiate EVENT_BEFORE_UPDATE_SUBSCRIPTION events in Commerce 2/3

I'm listening for various subscription events to send emails to members. Right now, I'm dealing with subscriptions where a renewal payment fails. I'm specifically listening for ...
1
vote
1answer
22 views

Tax validation in Craft Commerce

We have a single page checkout where the items are selected and addressed added before going to a cart summary page showing amount owed and tax due. Was confused as to why certain codes were not ...
1
vote
1answer
22 views

Is there a way to control the order of appearance of shipping methods in Craft Commerce?

If there are multiple shipping methods available for an order, is there way to control the order in which they appear? The CP doesn't seem to offer a way to re-order them. I'm using something like the ...
1
vote
1answer
17 views

Adding an additional Download PDF to orders

Is there a hook or something I can use to add an additional Download PDF option to the Edit Order screen? It looks like a dropdown, but I can't find any docs on how to add to it.
1
vote
1answer
33 views

How to search by title OR tag using Craft CMS?

I want to do a search query so the product title or product tag name matches the keyword. below is my code. if I remove the tag related query, this code works as it looks into the product title only ...
1
vote
1answer
39 views

Make dimensions common for all variants in Craft Commerce

When I enable multiple variants for product type that has Dimensions and Weight, fields "Dimensions and Weight" become available for every single variant. Product is tablet and all variants ...
1
vote
1answer
23 views

Missing field validation on user account edit

I've been implementing a user account page with Craft Commerce and copied over the template found here: https://docs.craftcms.com/v3/dev/examples/user-profile-form.html#simple-profile The issue is ...
2
votes
1answer
111 views

Commerce: what is the purpose of a line item's snapshot?

Having nearly completed my first real Commerce project, I managed to utilize most of the features offered in Commerce 3. However, I never quite figured out what the use of a line item's snapshot is ...
0
votes
0answers
16 views

Showing Reverse Relationships in CP | Products < > Categories

My clients would like to be able to see what products (Artworks) are added to a category (Collection), and vice versa in the CP. Relating on the front end is fine, but on the backend there seems like ...
1
vote
2answers
114 views

Craft Commerce not sending E-Mails immediately

I have an e-mail problem at Craft Commerce. Emails are not sent at the time of purchase. The e-mail is only sent when you log in to the backend. I first thought it was a server queue problem. But ...
1
vote
2answers
80 views

Commerce: Remove tax adjuster from line item in plugin

I need to remove adjusters from each line item if a certain condition is not met. I see that in the CP you can manually remove them by editing the line item but hunting down this code in Commerce's ...
1
vote
2answers
48 views

How to show flash message for Commerce order when changing status on listing page?

If I change an order's status to "Cancelled" (my custom order status I created), I want to ensure that the CP editors provide a "Cancellation Reason" from a dropdown field in the order. I've set up a ...
1
vote
1answer
17 views

passing product info to another product

We have a commerce site that provides samples of its items. We have a single product that handles all the samples and displays them in a dropdown. What I'd like to do is have a link on the product ...
1
vote
1answer
25 views

Commerce custom field output

I have a custom field that allows customers to order a sample from a list of all products. It also allows a custom value to be entered for a custom color. I conditionally show/hide the fields with ...
1
vote
1answer
22 views

Get all orders which contains a certain product type

In want to print a list of orders: {% set orders = craft.orders.completed(true).limit(null).all() %} Now I want to make a list of orders with only the product.type XYZ. I tried to fabricate ...
1
vote
1answer
20 views

Passing variant info

We have products with multiple variants (varHeight). The variant information get passed to the cart successfully and order emails. However, they don't show up on the control panel. How can I get the ...
1
vote
1answer
18 views

Can you run two different Stripe accounts as two different gateways in Craft Commerce?

Does anyone know if there are any drawbacks/gotchas to having multiple Stripe gateways setup in commerce for Craft Subs? If I wanted to have two sites on my craft install and for them to both use ...
0
votes
0answers
34 views

Using Scout plugin Only send attribute value to algolia

I'm converting a plain text field to a dropdown. In doing so the dropdown now sends ALL the values of the attribute to algolia. Is there any way not to do this. I just want to send the Value. What I ...
0
votes
0answers
26 views

Commerce product slug creates duplicates - can they also be autogenerated?

The slug for products is generated from the Title, for example in my case "Green Shirt". Seems like these are not unique, and if I create a product later on, also called "Green Shirt", they both get "...
0
votes
0answers
15 views

Is it possible to get the user groups or categories that a sale applies to?

I have set up sales and discounts that apply to certain categories and certain user groups. Craft commerce "knows" which categories and user group this sale applies to and I can get a list of sales ...
1
vote
1answer
32 views

Friendly order number - start sequence at specific number

Folks: I'm having trouble getting my head around friendly order numbers and sequencing. The client has asked for his sequence to start at 11 000. I can set up a sequence that starts at 1 based on ...
1
vote
1answer
38 views

Environmental variables for Scout plugin in scout.php file

I was wondering if it was possible to add .env variable for the indices area in the scout.php file? I added this to my .env file SCOUT_INDICES = "search_SCOUT_DEV" Then this to my scout.php \rias\...
1
vote
1answer
91 views

Update Cart’s address ID from plugin

I want to try and stop Commerce 3 creating a new customer address if it’s a duplicate of an existing one. As an example, a store selling digital products has a checkout form that simply asks for the ...
1
vote
1answer
19 views

Show only products in stock - one variant only

In Craft Commerce, how can I show only products that are in stock when not using variants? For example, this query, but only show products with a stock with 1 or more: {% set productQuery = craft....
0
votes
0answers
26 views

Asset field in Commerce product variant - how to upload file to folder with product slug

I added asset field to commerce variant field layout. What value do I need to set in field settings "Upload Location" field? I tried to use {slug}, {owner.slug} and {owner.owner.slug}, but I got this ...
0
votes
0answers
28 views

Deleting primary commerce address throws error

When i try to delete a user address in Craft Commerce, I get an error thrown, saying the address id does not exist. However the address id being passed to the action is output from a loop of the ...
0
votes
0answers
15 views

Paypal Express, Commerce 3.0, more information on Paypal Invoice

Using Craft 3.4.9 and Commerce Pro 3.0.11 What's the best way to get more information onto a Paypal invoice so that I can match Paypal data with a Craft Commerce order? Does anyone have some success ...
1
vote
1answer
33 views

Show custom fields on cart

I'm trying to show custom fields on the cart but I'm missing something (and new to Commerce, so bear with me). When I output {% for lineItem in cart.lineItems %} within my {% for item in cart....
1
vote
1answer
30 views

product types with and without variants

I have two product types. One has variants. One has not. So I try to write an image tag that works for both. {% set imageThumb = item.defaultVariant.variantThumb.one() %} For the product with one ...
1
vote
1answer
73 views

Feed Me - importing Commerce variants from Google Sheets?

Is there a way to automagically create variants from a Google Sheet when importing via Feed Me? The docs at https://docs.craftcms.com/feed-me/v4/guides/importing-commerce-variants.html#setup-your-...
1
vote
1answer
30 views

Passing variants to cart in Commerce

I'm trying to pass variants to the cart page. They variant field I want to pass is 'varHeight'. I'm using: <form method="POST"> <input type="hidden" name="action" value="commerce/cart/...
2
votes
1answer
48 views

Is it possible to provide an option to pick up an order from the physical store in Craft Commerce?

We're setting up a Craft Commerce site and the merchant wants to give the option to the customer to pickup the order from their physical store instead of shipping it to a specified address. If the ...
1
vote
1answer
36 views

Is there a way to re-order states in Craft Commerce?

I'm setting up a Craft Commerce site and for some of the countries the user must specify a State. However, the order of states appears to be alphabetical. The problem is that the site's traffic ...
1
vote
1answer
38 views

Send payment requests

Is there a plugin/solution or something else in Craft so that I can basically: 1) Create a payment request in the CP and send it to a specified email? 2) The email contains a link to a payment form ...

1
2 3 4 5
15