vxda Posted July 24, 2014 Share Posted July 24, 2014 Hi i got 2 products in my shop (im in developing stage)One product has price of 50.12, second 120 The one with price 120 will add to cart without a problem, the other one will not.Im working on ProcessWire 2.3.0.3. here is the error: Error: Exception: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '12, session_id = '47d81138ac1a7315664741263203c18aef6a7422' ON DUPLICATE KEY UPD' at line 1 (in C:\xampp\htdocs\projects\chemik\www\wire\core\Database.php line 118) #0 C:\xampp\htdocs\projects\chemik\www\site\modules\apeisa-Shop-for-ProcessWire-6a482d9\ShoppingCart.module(162): Database->query('INSERT INTO Sho...')#1 [internal function]: ShoppingCart->___addProductToCart(Object(Page), 1)#2 C:\xampp\htdocs\projects\chemik\www\wire\core\Wire.php(271): call_user_func_array(Array, Array)#3 C:\xampp\htdocs\projects\chemik\www\wire\core\Wire.php(229): Wire->runHooks('addProductToCar...', Array)#4 C:\xampp\htdocs\projects\chemik\www\site\modules\apeisa-Shop-for-ProcessWire-6a482d9\ShoppingCart.module(42): Wire->__call('addProductToCar...', Array)#5 C:\xampp\htdocs\projects\chemik\www\site\modules\apeisa-Shop-for-ProcessWire-6a482d9\ShoppingCart.module(42): ShoppingCa Cheers Link to comment Share on other sites More sharing options...
Macrura Posted July 25, 2014 Share Posted July 25, 2014 I don't take on too many ecommerce projects these days, however if I do, I keep it simple with ProcessWire + FoxyCart + OrderDesk. It's a simple but extremely flexible approach since ProcessWire makes it easy to build out a catalog that conforms to a site's unique catalog structure and product types without bending backwards and having to override a bunch of things. I'm interested to see what FoxyCart version 2 brings to the table. I'm also patiently awaiting Apeisa's system. Need any beta testers or perhaps some general feedback Apeisa? @jlahijani - awesome post - and that's my go-to setup (PW+FC+OD)... it's such a reliable, hassle-free, robust, simple setup - and i have 1 site that is PW+FC for over a year now and never had any issues; 2nd site with this is 8 months out, huge number of transactions per day, and whole things works flawlessly; I will look at your other suggestions, Spree and Sylius! it's all such a puzzle, this ecommerce situation... Link to comment Share on other sites More sharing options...
Macrura Posted July 25, 2014 Share Posted July 25, 2014 Thanks jlahijani for listing up those ecommerce systems. I have tried a few of them my self and ended up with OpenCart. @Pwired - i think also it depends on the market sector - Prestashop has a better-than-decent system for matrix products built in (meaning generating product variations based on attributes and inventory tracking, SKUs, images, as well as swatches for color, and selects for users on the front office), as well as some other features like returns, customer account management, re-ordering with 1 click... This is the main reason we're going with PS now; also there are just enough 3rd party modules that cover some difficult needs, such as complex delivery scheduling, social logins, tell a friend, loyalty rewards program, quickbooks integration, email marketing integration etc.. Link to comment Share on other sites More sharing options...
joey102030 Posted July 25, 2014 Share Posted July 25, 2014 @jlahijani and Macrura, have you had to deal with product discounts in FoxyCart? The main thing holding me back from using it more is their painfully complex and unintuitive discounting system Link to comment Share on other sites More sharing options...
Jonathan Lahijani Posted July 25, 2014 Share Posted July 25, 2014 @jlahijani and Macrura, have you had to deal with product discounts in FoxyCart? The main thing holding me back from using it more is their painfully complex and unintuitive discounting system I haven't had to deal with any complex product discounts yet. One competitor to FoxyCart that I haven't seen mentioned on the forums is called SnipCart. Similar concept (drop in cart), but it looks pretty slick and can manage orders in it as well (as opposed to using something like OrderDesk). Worth checking out, as well as the upcoming FoxyCart 2.0. Link to comment Share on other sites More sharing options...
Macrura Posted July 25, 2014 Share Posted July 25, 2014 @joey - do you mean coupons, or what kind of discounts do you mean? I've been able to setup easily all kinds of discounts using the attributes in the add to cart code, modified either server side, or with js, depending on what dictates the discount... @jlahijani - i'm looking at snipcart now for a project... but since i'm already used to foxycart, not sure if i can get my head around a new system fast enough for this upcoming launch... One thing to also consider is that Foxycart can accept multiple items added into the cart at one time, as well as being able to redirect to the cart/checkout without using the popup. So this opens up the possibility to simply use the processwire shop, and then switch out the final checkout button to send the contents of the PW cart to the foxycart for checkout; this would be good in many ways since you would have the SSL, PCI, huge range of supported payment processors, and all the other features of FC, and be able to use all of the shop-for-processwire features as your "pre-checkout/cart" Link to comment Share on other sites More sharing options...
peterfoeng Posted July 25, 2014 Share Posted July 25, 2014 Hi Macrura, can you share the ecommerce website you built with pw? * just a bit lazy to search around lol * Link to comment Share on other sites More sharing options...
Macrura Posted July 26, 2014 Share Posted July 26, 2014 hey peter - sure, here are the 2 sites running foxy: http://ohmspeaker.com http://www.katonahartcenter.com Link to comment Share on other sites More sharing options...
joey102030 Posted July 26, 2014 Share Posted July 26, 2014 @Macrura, yes I mean coupons... Ideally I'd want the ability for the client to manage the functionality on the PW side as much as possible. If they (or I) have to log in to FoxyCart to manage the codes, it kind of defeats the object in my mind. The simple ability to apply (for example) a 10% cart-wide discount would be fine, but this doesn't seem to be possible without a lot of work. I think the best situation is as you described, where you manage the cart functionality within PW and just pass the final figure over to FoxyCart for processing. The only downside with this is you don't get such a nicely laid-out summary in the receipt email. Link to comment Share on other sites More sharing options...
apeisa Posted July 28, 2014 Share Posted July 28, 2014 I have made some nice progress: DeliveryPost done, which asks post address + email.These DeliveryModules pretty much control the whole checkout process (and also adds some admin actions). This is the part of the shop that I guess will be most often customized. It also keeps things simple, when your needs are simple. module that hooks into DeliveryPost and adds shipping options order events (or order history - what has happened and when) Oh, and the module has a name: PadLoper (named after cute turtle species) Here are few teasers: 20 Link to comment Share on other sites More sharing options...
netcarver Posted July 28, 2014 Share Posted July 28, 2014 @apeisa Looking really good! 1 Link to comment Share on other sites More sharing options...
Pitbull Posted August 11, 2014 Share Posted August 11, 2014 hi to all and thank you! for help.. apeisa you made a fantastic module!! i test it in localhost in a multi language site and is working great, only one issue when i am not on default language from step placing order to step pay order i get this error: Error: Exception: Can't save page 0: /e30bc646cfd69e1c90d6c19b945a3ab3/: It has no parent assigned (in C:\wamp\www\processwire-shop\wire\core\Pages.php line 604)#0 [internal function]: Pages->___save(Object(Page), Array)#1 C:\wamp\www\processwire-shop\wire\core\Wire.php(359): call_user_func_array(Array, Array)#2 C:\wamp\www\processwire-shop\wire\core\Wire.php(317): Wire->runHooks('save', Array)#3 C:\wamp\www\processwire-shop\wire\core\Page.php(1113): Wire->__call('save', Array)#4 C:\wamp\www\processwire-shop\wire\core\Page.php(1113): Pages->save(Object(Page), Array)#5 C:\wamp\www\processwire-shop\site\modules\ApeisaShop\ShoppingCheckout.module(571): Page->save()#6 C:\wamp\www\processwire-shop\site\modules\ApeisaShop\ShoppingCheckout.module(224): ShoppingCheckout->createOrder()#7 C:\wamp\www\processwire-shop\site\modules\ApeisaShop\ShoppingCheckout.module(152): ShoppingCheckout->renderConfirmation()#8 C:\wamp\www\processwire-shop\site\templates\sc-checkout.php(16): Shoppi and stays at placing order step this only happend on non default language, in default is working fine. any ideas? Link to comment Share on other sites More sharing options...
apeisa Posted August 11, 2014 Share Posted August 11, 2014 Sorry, never really tried this with multilang site. @soma might have better understanding of these? This is probably the problematic line: https://github.com/apeisa/Shop-for-ProcessWire/blob/master/ShoppingCheckout.module#L546 Could that ->get() work differently on non-default lang? Link to comment Share on other sites More sharing options...
Pitbull Posted August 11, 2014 Share Posted August 11, 2014 thank you @apeisa!! lets wait for @soma... Link to comment Share on other sites More sharing options...
Soma Posted August 11, 2014 Share Posted August 11, 2014 I think it's because the non default languages aren't set active on the admin/shop/orders/ parent page. 1 Link to comment Share on other sites More sharing options...
Pitbull Posted August 11, 2014 Share Posted August 11, 2014 thank you Soma!! you are right it wasnt active, i did activate it, allso i check all other pages if set active and is all checked now. but now i get this error.. (when i am not in default language) Error: Exception: Can't save page 0: /en/wire/shop/orders/e4d79c0119d47b8a63b841402f3cd699/: It has an empty 'name' field (in C:\wamp\www\processwire-shop2\wire\core\Pages.php line 604) i notice that admin/shop/orders/ childrens when i create order the non default languages aren't set active, and they stay unpublish, and the title in default language is blank but non default language is filled. i really appreciate your help guys! Link to comment Share on other sites More sharing options...
Pitbull Posted August 12, 2014 Share Posted August 12, 2014 anyone? Link to comment Share on other sites More sharing options...
Soma Posted August 12, 2014 Share Posted August 12, 2014 Looks like apeisa shop isn't multilanguage compatible. I have forked the module long time ago and added/fixed some multilanguage related stuff, I remember, just so it works for me and my project(s). But I'm not really supporting it, so you are on your own kinda. There's also a dev branch. Link to comment Share on other sites More sharing options...
Pitbull Posted August 12, 2014 Share Posted August 12, 2014 hi soma and thank you! where can download the dev branch? sory i found it here https://github.com/somatonic/Shop-for-ProcessWire/tree/dev the version you have forked can work multi language checkout? for me it work fine! Link to comment Share on other sites More sharing options...
Pitbull Posted August 12, 2014 Share Posted August 12, 2014 soma thank you a million times!!! your dev version did the multilanguage work!!! Link to comment Share on other sites More sharing options...
alec Posted August 15, 2014 Share Posted August 15, 2014 Hello. I am using Apeisa shop cart for one of my project. And I need some help with displaying products on home page. When I use foreach loop I can only display fields from shop template. But I need to display "Add to cart" button. How to add $modules->get("ShoppingCart")->renderAddToCart(); in foreach loop. <?php $products = $pages->find("template=shop, limit=10"); echo "<div id='wrapper'>"; echo "<div id='list'>"; foreach($products as $product) { echo "<div class='item'> <div class='item-body'> <div class='cena'>{$product->sc_price} €</div> <span class='item_title'>{$product->title}</span> </div> </div>"; } ?> Link to comment Share on other sites More sharing options...
Soma Posted August 15, 2014 Share Posted August 15, 2014 Look at the module and the method https://github.com/apeisa/Shop-for-ProcessWire/blob/master/ShoppingCart.module#L78 See? There's options to set the "page" as the first argument. Link to comment Share on other sites More sharing options...
alec Posted August 15, 2014 Share Posted August 15, 2014 I see it, but how to call it in home template? When I list 10 products how to add "Add to cart" button in every listed product. Link to comment Share on other sites More sharing options...
Soma Posted August 15, 2014 Share Posted August 15, 2014 With that method you posted, and the first argument is the product page. echo $modules->get("ShoppingCart")->renderAddToCart($product); 2 Link to comment Share on other sites More sharing options...
alec Posted August 15, 2014 Share Posted August 15, 2014 Yes, that helped me. Thanks a lot Soma! I have better understanding of module class now, Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now