Transcribing a video about Drupal Commerce shipping options, I thought I might be on to something.
A couple of days later I tried to follow the instructions myself and soon discovered that the video describes a simple case, but that other modules exist on the Drupal.org site and here:
The trouble is that the ones for a shipping matrix by weight and destination or perhaps courier are not finished.
One has a dozen or so users.
One has sixty but writes that the project was halted; there is no user interface, bugs are acknowledged but it is for another maintainer to sort them.
Those of us who are not in the states obviously need this module more than shopping cart authors need to get them written. To me, a shopping cart is not past alpha release unless it can ship to the home country, part of the world, and the rest of the world on three different weight scales alongside a few more for different kinds of delivery. This is what I already have on my simple entry-level shopping cart from mals-e commerce which allows 5 types of delivery that can be subdivided according to price or a value that you add to each order form link for weight. Paypal's free shopping cart links probably offers something similar. If you pay a small subscription to mal's you get more options, but most settle for this entry level.
Obviously, to open source software developers in the states, it is OK to release something and watch people write additional modules that they explain as being un-finished because a project fell-though and they are short of time.
So: back to watching this video about how to sell things for $0 shipping in Colorado and $10 shipping in the rest of the world, which happens to be the USA. Until I can find an open source shopping cart system that started in Europe.
Finally
Commerce_Shipping [module] is coming of age!
I want to give you a quick tour of how to do some
things with commerce shipping.
What we're looking
at today is this
https://drupal.org/project/commerce_shipping
and what we are looking at is the 2.X branch (which as you see
is still a .dev release, but it's working pretty well). What
we are going to do is: we are going to work with that, and we
are going to work with the
So that's what we are going to work with. (and) [50" fifty
seconds into the video]
What we are going to
do is, first of all,
we are going to create a flat rate shipping class; we are
going to say that it costs $10 to ship. Then, after we
experiment with that,
we are going to create free shipping, for products that are
within Colorado. So we'll just go and change the rules, and we'll
have free shipping within Colorado, and $10 shipping outside
Colorado. So lets' give that a shot.
First of all go and enable the modules. So we
will go over and enable the modules here [from modules>list
he uses a filter to find "shipping" and "flat rate"
which are installed as part of the Kickstart distribution he's
using]. OK. Well. I'd already enabled them, but those are the
ones that you want, and you'll find them under Commerce (Shipping)
[picking from a grey-backed column on the left side of a page]
you'll want Flat Rate, Shipping, and Shipping UI. [Shipping User
Interface]
Later on, in another
podcast in another screencast, I will show you how to do UPS [United
Parcel Service] and in a further screen cast we'll do some more
complicated rules like "free shipping over $100" - that
kind of thing.
But in
this one, we're just going to do two shipping rates, one for within
Colorado and one for outside Colorado. We'll give that a
shot and see if we can make that work.
So the first thing we're going to do is: we'll go-over
to Store>Configuration>Shipping, and we're going to take
a look at what we have here: We have [three
tabs] -
All we are going to do today is
we're going to look at | Shipping Methods |, which is just there
[the visible tab] by default: Flat Rate [method] is what we've
got [by default], and | Shipping Services |. We can have one or more
Flat Rate Shipping Services. You could think of them as "shipping
instances", or whatever you want to call them.
[3'10"]
I'm going to say "add a flat rate service",
[does so] and I'm going to say... I am going to call it "Flat
Rate", and it's going to be $10. And now we have a new shipping
service, under the tab
Display
Title: flat rate... ... ... ... so this is all set-up. It
will automatically be available as a shipping method for any purchase
that we make. So let's go ahead and make a purchase. We'll
buy "product three" - how about that! Checkout.
And [add] shipping information.-I'm going to be in Palisade Colorado.
Fill this in here. Continue-on. We see that we are offered
Flat Rate Shipping. That is the only service that we have to find.
And we go for it. So, here we are [at the "review your order"
screen] - it's done exactly as we asked: it has added flat-rate
shipping $10 on to our charge. and... I've got no payment
required. I've got free payment. That's not something you'd want
on any site but I can have free payment on this one!
OK - so, Now.
I want $10 shipping
in the rest of the USA but in Colorado I want just free shipping.
So there is
What we need to do is create another
"free shipping" type.
We're going to Store>Configuration>Shipping, and we're going
to add another flat-rate service. We'll call it "free shipping
inside Colorado". [copies text for display title. leaves
description blank]. And... price is zero. [presses "save"]
And now we have another service: it's called "free shipping
inside Colerado"
What
we need to do now is remember that this is a Rules component [of
the Rules module]. Every rule has an
event, a
condition
[or condions] and an
action. [points to the Conditions and
Actions sections of the screen].
Events are what a rule
listens to, conditions decide whether it takes the action, and
actions which are things that we are going to do. We are already listening for the "rate shipping"
event, and we are going to say "should this rule apply to
us", in other words "should we select free shipping"
[5'19"]
...so I'm going to add a condition [from a long
drop-down menu including "Commerce Order" as a subheading
in bold], and it's going to be a Commerce Order address component
comparison. So there we go. The value that I want to compare against:
the address that I want to use is the shipping address.. The address
component that I want to compare is, first of all, I want to compare
the Country. I'll make sure we get the country in there. Otherwise,
there might be a "CO" abbreviation in some other country.
By the way, this is the two-character country code for the country
that I was talking about. So we have a condition for that.
Now we are going to add one for the State. We're going to do the
exact same thing again - Add a new condition> ORDER>Data
selector> commerce_order
It's
the shipping address that we want... [on the same page further
down]
ADDRESS COMPONENT>Value>Administrative
area (State / Province).
VALUE>Value
The two-letter code for Colerado is CO.
Save.
So now we have - er - two conditions
on there [in the Conditions ELEMENTS box] One is:
Is
the country US? The other is
Is the state Colerado?
Then we're going to add that there [in the Actions
ELEMENTS box below].
So now
we are going to go back and fix the other one so that we don't
offer free shipping.
So let's go ahead and do that: we're not
going to offer free shipping anytime that they are not shipping
to Colerado. So: Store>Configuration>Shipping>ShippingServices
And now we have to edit the flat rate - and this we don't want
to offer if they are outside Colerado.
So let's just say that we only
want to offer shipping in the US, because that's [ ] a separate
thing. So lets just go ahead and say [on Add a new condition]
ORDER>Data selector ...
and the value of the
administrative area [options are = / not = / contains] lets
say "equals" CO. And then we're going to say [with a
tick box just above the save button at the bottom of the page]
"Negate": [9'30"] This does not contain Colerado
so don't do it. Save.
Lets
go ahead and add the other condition, about the US.
Add
a new condition > Select the condition to add > drop down
menu
Commerce Cart > ?
...just
in case there is some other sort of thing [that has a CO abbreviation].
We'd probably take care of this another way, by offering a different
shipping [service] outside the US, [which would] just tell them
that we couldn't do it.
DATA SELECTOR > Country
>
OPERATOR > equals
...just
for now I am going to say "equals US"
We
are going to say that this [flat rate shipping rule] applies to
shipping that is in the US, but is outside Colerado.
[...]
And so now lets go-see if that
works: [10'35"]
...you'll see that it already
thinks that I'm in Colorado. No - it just doesn't know yet. It
didn't ahve any information. Now we know. Now lets try again.
Lets try shifting the state to Kentucky. ...and now it's offering
only the flat rate $10 ammount. So now it's doing what we told
it to do. The first time we tried this, we didn't have a way to
choose [where we are] at the checkout.
...Colerado: then we get free shipping.
Let's just take a look at what we've done. First
of all we've used Commerce_Shipping
[module] 2.X . We've used Commerce_Flat_Rate
- (
not the older (what do you call it?)... not the older Commerce_Shipping_Flat_Rate,
which is basically depricated now.
Using those
two, we have gone-in to Drupal admin (with Drupal Commerce enabled
and a Store menu on admin).
We have gone into Admin>Store>Configuration>Shipping
We have a flat rate SHIPPING METHOD.
We hae added two services. Let's take a look at the two services
we added. The two services are
Flat Rate (Machine name flat_rate), which is the $10 one,
and
free Shipping inside Colorado (Machine name free_shipping_inside_colerado),
which would be $0.
And then we added a Rules component to make sure that they
were chosen at the right time. So free shipping is chosen if
we are shipping to the US, and we are shipping to Colerado.
And we did the opposite on the other one.
So that's the basics! That's the first and easiest configuration
of flat rate shipping .
I will do a couple more
screen casts. I'll do one on Commerce_UPS, which is now working,
and I'll also do one on fancy rules. So, thanks for listening,
and see you in the issue queue and everywhere else! Thanks - bye
bye.
...teaches me that I'm not alone in finding Drupal a space hog for space cadets who do not pay for their own server space. Apparently this is a bad side to its good side - enough hooks for a knitting machine, each of which can open some memory-based function or other. I also read about its history. Recently a collection of modules which were sometimes supported or sometimes released as a favour to other savvy coders, then transforming into a platform for using Rules and Views modules. I was going to add a picture of a space hog, but that's a distraction and anyway it was mocked-up: the pig did not suffer. Do not send pigs into space.
By the way, why to americans say "sucks" for "bad"? Is this a macho thing? There's a strange convention that you search for X+sucks to find what's wrong with something.
On
the same page I discover that a system called Code Igniter with a
flexicart add-on is designed for cheapskate shopkeepers who play on
their computers. Maybe in a week or two I will find another web page
called "why code igniter is bad" (or kicks ass for bums or whatever americans say). Meanwhile there is a Bitnami windows
stack of programs to run it so here goes: it should have downloaded by now.
Oh: an hour later I am still making sense of Bitnami instructions. Apparently Code Igniter is not pre-installed in the same way as Wordpress or Drupal. There is some requirement to understand how these stacks of programs work in order to start it and see what it is, in order to understand how it works. Learning about software by trial and error is slow, sometimes.
A paid video about wordpress ecommerce mentions "so many people banging their heads against the wall in the forums" on some tricky point.
Free videos, made more quickly, do not even mention forums.
Forum posts cannot easily describe free videos either; they cannot write "the part about X at 6'32" doesn't make sense to me" because not many people would reply unless there is a transcript, and for some reason the videos such as Commerce Guy's videos on Vimeo do not have transcripts. This is a pity for
non-english speakers, who have trouble translating the less clear parts, and for
english speakers like me who have trouble asking for help in a forum and saying where stuck.
I have tried posting in Drupal Commerce forums and got no response. If I transcribe a video there, it looks a bit weird and out of place and probably gets deleted; if I post it here on a blog and link, it looks like an attempt at self publicity and gets ignored (or deleted). So the two ways of learning about Drupal Commerce do not interact; makers of videos do not know where their explanations are tricky, and writers on forums cannot help each other by referring to the right parts of videos.
I thought Wordpress was the simplest fresh start, but found that there is trouble in paradise too - Wordpress.tv/2013/02/18/justin-sainton-wordpress-e-commerce-2/
...tells me that at 4'49" "whatever e-commerce software you use, it's going to be awful in some way", but that e-commerce developing has the best rewards in happy customers when it goes right
The knack of combining various databases into a site for someone who wants to focus absolutely on shopping carts and not learn anything else is, well, asking for trouble when it gets complicated. In the US, tax is complicated for example.
In the UK, shipping is complicated. Royal Mail is not kind to plugin-writers,
so any free ones are likely to become out of date. And UK shopkeepers are mercantile people in a little country, unlikely to rule-out selling to Australia or Germany if an order comes-in. All that's needed is a matrix quote system for prices or weights verses zones. Royal Mail has three or four world zones, and you can add more if your products to the UK have different volumes or you use a courier as well. I have a separate post about Royal Mail's zones and prices for ecommerce developers.
Even if I buy a
textbook about a wordpress plugin or a good clear set of videos by on how to use Wordpress for Ecommerce and watch patiently while taking notes, I'm likely to
find an un-acknowledged gap where shipping options ought to be. Or an intended gap.
Wordpress has several
ecommerce plugins jostling for trade, but all the ones I have
discovered tend to charge for vital things like breathing or shopkeeping
or posting objects via special essential modules. So these programs are open source crippleware, hoping to make money by charging you for something essential.
On the other hand, wordpress users seem a lot more recognisable as real low-budget people than Drupal users. There are plenty of plugins for hosting your pictures on flickr or plus.google to save bandwidth and disk space. This saves money. This saves the amount you have to sell in a recession to break even. This keeps you fed when others fail.
Magento is another easy option, or so I thought, because nearly all my stallholding shopkeeping rivals use it.
I bet a packet of biscuits that it will have some kind of stock reporting system that can be used for wholesale customers as an essential, and for stock control as a desirable option.
I bet one of my hadgehogs that Shipping will probably be sane compared to other carts. You just fill-in a configuration column about how many countries you would like to ship to, and I haven't finished the instructions but I guess that everything might be included in the core program with no ifs and buts and demands for £50 software. I don't know if zones will be allowed, or if every customer has to scroll through a list of countries starting with American Samoa, but something will be available.
Instructions exist, by the way. You type your version and language into a site and it emails you a 250 page .pdf book to read beginning to end, or to page 45 in my case.
A nifty .php file will check whether your test server suits Magento,
and none of my 100% free accounts allowed it, but a nearly free one
called Freehostia Chocoloate passed the test. (Freehostia Chocolate is free if you have a spare mainstream domain). Officially is allows 250MB equalling 262,144,000
bytes of disc space. Five hours later my attempted FTP upload stopped
for lack of space after I tried uploading 6,396,182 bytes from Bitnami
as a first experiment. This was just the relevant-looking files in a
folder called Magento. This does not come-up in the easiest-to-find comparisons of shopping cart software.
Magento finds cheap servers a problem, as does Drupal. The programs are gross. My fast UK web server that I want to use for real shopkeeping has these price breaks for disc space. It's smaller than some free but slower ones. Prices are per year (developers please note that servers can be priced per year as well as per month) 0200MB £050 + 20% tax 0400MB £100 + 20% tax 0600MB £150 + 20% tax 1200MB £250 + 20% tax
Further Googling finds that Magento likes to cache a lot. It has complex internal tables. And I haven't yet seen a free plugin that lets you host your pictures on a free website. So, basically, I can see why I am still in business and some rivals who use Magento have been struggling a bit in a recession. Maybe that's why some of them are on slower servers.
As with other shopping cart software, enthusiasts who sell support or blog about the product seem unaware of why it's difficult or even doesn't work for so many users.
These are the problems for Drupal, made better or worse by evangelical support from people who give lectures or go to groups. It seems rude to someone who is saying "straight out of the box" in a lecture that the thing does not even turn-on for some parts of the audience. It seems rude to parts of the audience that a product does not work from available instructions, and incurs hidden costs.
Just for now I will experiment with Wordpress E-commerce but hope to come back when the first textbook writer dares put instructions in print. I have paid my deposit.
https://vimeo.com/40933753 - I hope this transcript is copied and improved by others. http://lbt.me/Wyw is another page on the same subject, mentioned on the module download page.
Hi!. I'm Bojan and I work for Commerce Guys. This is Commerce Module Tuesday. Today I will show you the Inline Entity Form Module.[included in some commerce kickstart installations]
It provides a complex widget for reference fields that allows to modify and delete reference entities inline, as well as at
For Drupal Commerce, this means that it solves two important use-cases.
First of all it unifies the management of product-displays and products, allowing you to handle both, from the product display, and edit pages.
Secondly, it also provides more flexible line-item functionality, giving you the ability to modify custom fields that you attach to the line items.
The management of Product Displays and Products
[there is a comment below which might make sense of this]
Let me show you what I mean. I have here a Commerce Kickstart 1 installation [the one with Product One, Product Two, Product Three on the front and a standard Drupal admin menu] , and I have already downloaded and enabled the Inline Entity Form module - the Beta 1 version. [which is included in Commerce Kickstart 2 by default].
Lets imagine for a moment that we are building a website for a company that sells T shirts.
I already went-ahead and created a new Store > Products + Add product type
product type called T shirt. Aside from the usual fields like Image and Price, it also has the Color and Size fields, which point to the vocabularies which hold the allowed colours and sizes for a T shirt.
In e-commerce language, a product can have several variations. So a sample T shirt can have a new variation for each of the combinations of Color and Size, and each of those variations has a different SKU [part number]. So in Drupal Commerce this means that for each variation, you create a new Product, and then you create a new Product Display that references all those variations, and allows the user to select the correct one. So I have four sizes and four colours. I need to go to the add product page [clicks "create T shirt"] Store > Products Create Product a basic product type. Create T shirt
...and create sixteen different products. Then I would need to go to the... Products > Actions > Add a product Add Product Display
...page, and reference the sixteen products that I have created.
The product display field looks like this, at the bottom of the product page. I can't find it on the page though. This is where, for me, the video is ambiguous and I do not know how to follow it in order to set-up shop, even after transcribing it carefully. It is better than average among the videos transcribed here, but I guess that the people making the videos do not know where they make sense or don't make sense, and that's why there is often a bit that's impossible to follow for some people watching.
Product Choose the product(s) to display for sale on this node by SKY. Enter multiple SKUs using a comma separated list.
I'm going to go to Structure > Content Types > Product Display > Manage Fields (which is 2nd tab) &
you will see here (4th line) that we have a Product Reference Field. I am going to edit it.
The first thing is that I am going to change the label to Product Variations because it is slightly more user-friendly in my opinion. We are going to delete the help text because it is not going to be shown anyway.
And I am going to limit the product types that can be referenced to T Shirts alone,
Product types that can be referenced
Widget type
Done.
So:
36'36" Let's go ahead and add a new product display now. [does so on screen]
You will see when you scroll-down that, instead of having a simple product reference field, I now have the complex vision that is provided by the inline product entity form. I have a product-variation inline-form opened by default. And that form contains three groups for all the product information. So,
in the first group, I have product atributes,
in the second group I have the SKU, [types on in] the price, and then any other custom fields that might be added under 'attributes', and
in the third group I have variation image. [uploads image]
So I click
...and the first variation is there.
Let me go-ahead and add a few more.
[does so]
So: all of my variations are now here.
I have added all of them from the same screen: not leaving the product display add-product page, and not needing to know anything about Drupal Commerce architecture underneath.
If I need to, of course, I can delete a specific variation. For example this one
And of course I can edit the ones that I have already added
Clicking the edit button opens a form right below the row being edited, and allows me to change the inforation that I want to change. [changes a price on screen as an example].
So, I go ahead and save that [using a button at the bottom of the screen]
5'32" And you will see that it now works!
And I also want to make it possible for the user to reference multiple product types. In which case they can go back and enable the...
Product types that can be referenced Product
...product as well. And now when I go back, [clicking to another browser tab] you will see that the widget has changed.
Instead of just having an "add variation" button, I also have a drop-down option to select the appropriate product type. If I click "select product" and click "add", I will get an add form for this product type. Which for example does not have any attribute fields. Different product types have different attributes, which are not shown in the table itself. Instead I have the variation title. And this one is automatically generated by the ???? form, by taking the node title and appending any attributes, if they exist.
6'30"
Of course, you can turn this functionality off if you want to. So...
I can, once again, go to the INLINE ENTITY FORM field set, and disable auto-generating of the product title.
INLINE ENTITY FORM: COMMERCE PRODUCT Auto generate the product title
And now when I go back to the same Store > Orders
page, you will see that the widget has changed it. [the culumns for each line shown under the EDIT tab are
LABEL, UNIT PRICE, QUANTITY, TOTAL OPERATIONS, with
showing in the last column. I now have a proper edit button allowing me to change all the information on this line item, including the print name field. I can also add new items, and fill-in all the relevant information.