Shopkit commerce plugin

New panel field for shipping tiers

Dashboard widget

Hello,

I am developing an eshop which sells music event tickets, and the payments need to go to different people (Paypal accounts for example), according to a ticket characteristic - the city the event is taking place.

Is this possible with Shopkit?

Thanks

This is not possible. Each shop can only have a single payment account. You might be able to develop a custom payment gateway to handle this scenario, but you will have to consider what happens when someone buys two tickets from different cities.

This is not a feature I plan to include in future versions of Shopkit.

Hi,

I am experimenting with shopkit but wondering how I should make a french-only shop?
In config.php, I set french as the only langage and the default.

Iā€™ve tried renaming all shopkitā€™s files to .fr.txt instead of .en.txt but I worry this would lead to more complex updates in the future. What should I do to make shopkit a single-langage shop manager?

I also have a problem with the ā€œShipping Methodā€ structure field, whilch loads a new page, but this is probably related to me renaming all those files to .fr.txt. Hereā€™s a screenshot of the new page that opens after I click on the ā€œnew entryā€.

Thanks!

Shopkit is hard-coded with English as the default language. I realize this isnā€™t ideal.

After renaming all the files to fr.txt, youā€™ll have to edit a handful of files in Shopkitā€™s core.

Iā€™ve added a new issue to the Github repo which lists all the places that en is hardcoded. These would need to be manually updated when you upgrade Shopkit.

The panel error is likely caused by French decimal formatting. Shopkit expects a dot (.) as the decimal point. The Github issue also lists the files which enforce this number format.

1 Like

Sounds good. Thanks for helping.

Would you advise for me to set up the shop as multilingual with english as the default and translating from there?

Iā€™ve also tried replacing the currency symbol with ā‚¬ (while in English) and this is what the shipping modal shows:

Setting the currency symbol after the price seems to break the modal completely.
Not sure what I should do. Should I edit in the modal and then change those options?

It looks like thereā€™s a bug in the rawPrice() function causing these display errors. Iā€™ve added it as another issue to Github.

This bug should only affect your panel view, not the actual calculation of shipping rates.

I would advise using the shop with English as default, then all your URLs will have to have /frā€¦ hopefully I can work out a better solution for this in a future release.

:pear: Major version update coming soon

Iā€™ve decided that the next release of Shopkit will be a major version update to v2.0. There are a bunch of big changes, including:

  • Unifying all settings under Site Options in the panel ā€“ this includes all settings that used to be in the Shop page, and all gateway config.php files
  • Abandoned cart tracking & transaction stats
  • A new WYSIWYG editor
  • A new theme
    • Easier to customize with custom.css (remove UIKit framework)
    • AJAX improvements
  • New frontend admin tools (one-click to create new categories & products)
  • More Details: https://github.com/samnabi/shopkit/milestone/17

Bugfixes only for the v1 branch

Shopkit v1.1.5 will be released at the same time as v2.0. This will be a bugfix release for the v1 branch. Future bugfix versions will be released as necessary, but the v1 branch will not get any new features.

I will continue to support the v1 branch with Kirby 2.4.x only. The v1 branch will not be updated for compatibility with Kirby 2.5.

v1 licenses are still good

Any licenses already purchased will be valid for use with v2, and the price for new licenses will remain the same.

Testers wanted

The changes for v2.0 are quite big, and I would greatly appreciate any beta testers. If you have an existing Shopkit site, or want to try setting up v2.0 for the first time, drop me a private message. One free license key to each person that helps me test this in beta :slight_smile:

3 Likes

Hello, me again :slight_smile: i was wondering wether it is possible to have different prices for different options, for now i see that the user can choose for example the color of the product but you cannot set a different price for each color. Thanx

1 Like

The idea of variants vs. options is pretty integral to how Shopkit works.

If you want to have different price points, they should each be a variant.

If you put variants within a select menu, thereā€™s nowhere for the options to go.

I think your design idea is best suited for a custom product.php template (located in /site/templates), which will override the default template.

alright. to explain my situation a bit more detailed:

i do a website for a typefoundry. they have a font ( the product ) and different Font Weights ( Variants ) but they also sell different versions of those, like the font as a webfont for 50k views or 100k views etc. ( what i thought could be the options ) ā€¦

do you know of a solution on how i could deal with this

thank u very much :slight_smile:

In your case, I would probably move everything up one level:

shop/
  typefaces/              # Category
    MGD Rotter/           # Category
      MGD Rotter Family/  # Product
        50k views         # Variant
        100k views        # Variant
        150k views        # Variant
      MGD Rotter Regular/    
        50k views
        100k views
        150k views
      MGD Rotter Italic/  
        50k views
        100k views
        150k views

What do you think of that approach?

1 Like

sounds like a reasonable solution, iā€™ll try, thank u very much !

1 Like

3 posts were split to a new topic: Canā€™t hide page in Panel

Is there a way to add multiple units of a single product to the cart?

Iā€™d like to implement a simple counter that allows the customer to add for example 3 units of the same product to the cart. Is this possible somehow?

found a solution with an extra input field :slight_smile:

The idea of a quantity selector in the product page is on my radar: https://github.com/samnabi/shopkit/issues/80

If youā€™d like to share your solution there, it will help me decide how to implement this feature.

Itā€™s not a very high priority for me at the moment, so this will not be available in v2.0.

foreach($category->children()->visible() as $product) {
			foreach($product->variants()->toStructure() as $variant) {
				//Overlay
				$block .= "<form class='' method='post' action='";
				$block .= url('shop/cart');
				$block .= "'>";
				//Input Fields
				$block .= "<input type='hidden' name='action' value='add'>";
				$block .= "<input type='hidden' name='quantity' value='1' class='overlay_val'>";
				$block .= "<input type='hidden' name='uri' value='";
				$block .= $product->uri();
				$block .= "'>";
				$block .= "<input type='hidden' name='variant' value='";
				$block .= str::slug($variant->name());
				$block .= "
				//Button
				$block .= "<div class='products_overlay_counter'>";
				$block .= "<a class='products_overlay_counter_down'>-</a>";
				$block .= "<span class='products_overlay_counter_num'>1</span>";
				$block .= "<a class='products_overlay_counter_up'>+</a>";
				$block .= "</div>";
				$block .= "<button";
				$block .= e(inStock($variant),'',' disabled');
				$block .= " class='products_overlay_bt' type='submit' property='offers' typeof='Offer'>";
				$block .= "<img class='products_overlay_bt_img' src='../assets/img/bestellen.svg'>";
				$block .= "</button>";
				//Close 
				$block .= "</form>";

				echo $block;
			}
		}
  1. Add an input field (named quantity) to the template and built a simple counter.

     var counter = function() {
     $('.products_overlay_counter_up').on('click', function (x) {
         target = $(this).siblings(".products_overlay_counter_num");
         target.html((parseInt($(target).html()) + 1));
         val = $(this).parent().siblings(".overlay_val");
         val.attr("value", (parseInt(val.attr("value")) + 1));
         console.log(val.attr("value"));
     });
     $('.products_overlay_counter_down').on('click', function (x) {
         if(parseInt($(".products_overlay_counter_num").html()) > 1) {
             target = $(this).siblings(".products_overlay_counter_num");
             target.html((parseInt($(target).html()) - 1));
             val = $(this).parent().siblings(".overlay_val");
             val.attr("value", (parseInt(val.attr("value")) - 1));
             console.log(val.attr("value"));
         }
     });
    

    }

  2. Update the counter with javascript.

As you can see, I am building a completely custom template, so Iā€™m not sure if this is much use to you at all.

A few questions:

  1. How can I get rid of the /panel redirect and the e-mail as username? Iā€™d like to operate a site without any user accounts, is this possible?

  2. Since I am developing a single page store, Iā€™d like to integrate the cart in a popup overlay. Iā€™d also like to integrate all the following steps of the checkout in that overlay. Is this possible somehow?

  1. Panel is completely separate to the frontend. you just need to rename/delete it and uā€™ve basically removed the backend.

iā€™m not a shopkit customer / user, but usually user accounts cannot be email as itā€™ll truncate @ and (dot) and put it into a safe string.

user accounts can be granted permissions if thatā€™s your worry because of getting rid of panel, otherwise there are several ways to deal without users at all, some of them are:

  • pdt payments which fullfill order on an email typed in during process ( session )
  • write another sort of information other than useraccount to disc ( subpage, raw text file etc )
  • work entirely via email such as bank-transfer with pre-payment where you send out instructions via email
  • cookies? not advised

imho user account makes sense if you have the full fledged system with invoicing and stuff. but site owner having only guest orders is annoying too.

  1. yet again no shopkit user here, generally speaking a single page checkout can be done in several ways as well, iā€™d also love to have a one page checkout, i could code it myself i wouldnā€™t want it as a popup overlay though, maybe some sort of sidebar or 50% width of viewport, the shop which was included at @getkirby twitter account just today had an awesome looking checkout screen. too bad here in germany we have very strict guidelines on how a checkout process has to look like and i would have to lie, but itā€™s very critical and it requires some research already.

in the end, i guess alot of things have to be adjusted on shopkit if you were to get it done in a one page scenario.