Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 11/18/2019 in all areas

  1. Hey @Mike Rockett! I'm wondering if there's some way to add support for URL segments in the module. Any chance you might've figured this out already? ? Basically in my use case there are pages that list items below them, yet those items actually live outside of the publicly viewable page tree. It's a no-brainer that they wont work right out of the box, but what I'm wondering is if we could somehow – hook or some template setting or something – inform MarkupSitemap of these "non-pages", and add them to the sitemap. I had a quick look at the codebase, and I'm wondering if this could be achieved by an optional hook in MarkupSitemap::addPages, perhaps by passing $page and $url to a hookable method after calling $this->urlSet->addUrl($url)? Seems that this way I could add a custom round of iteration and also add those URL segments as new URLs to the URL set ?
    3 points
  2. I just found this developer oriented browser which has me excited: https://sizzy.co/ I'm about to play around with it but wow, it looks like it could increase my productivity quite a bit!
    2 points
  3. There are the php functions json_encode and json_decode. You can use one to add it to the session, and the other to read it from the session. (Sorry, on mobile. Therefore no links or examples here. )
    2 points
  4. @JeevanisM I don't think that your issue is relative to module. You can try to use https://processwire.com/blog/posts/introducing-tracy-debugger/#mail-interceptor-panel to see how fast PW sends mail.
    2 points
  5. Snipcart looks nice (though I've not tried it). I looked at it & the 2% of transactions fees on top of payment gateway fees put me off, plus only a few payment gateways are supported. I've used Foxy.io (Foxy Cart) with ProcessWire on a site & it works really well*. Fees are low (approx £16/month) & loads of payment gateways are supported. I'm happy so post/share code if anyone needs it. *Big thanks go to both @netcarver an @Macrura for helping me with some of the datafeed integrations back to ProcessWire.
    2 points
  6. Also, take a look at the WireHttp docs, particularly WireHttp::getJSON() - this method can make your code more streamlined. ?
    1 point
  7. JSON is just a string so you can save it to $session as a string: Or you could decode the JSON to an associative array and then save that array to session. The core wireDecodeJson() function is a handy shortcut to force the JSON to decode as associative arrays rather than objects.
    1 point
  8. About to purchase it now that I have a new computer because on my old one it just couldn't handle!
    1 point
  9. I was getting the impression the discussion was more "in general", not PW-admin-specific. (concerning our so-called "frontend" product we ship to clients) There's always a lot you can optimize one way or another. With the specific tools / methods I briefly mentioned, you could certainly optimize a few milliseconds per page load in the admin. But the major bottlenecks would still be there. So, in brief - no, not worth to optimize in this regard (imho). Of all CMS backends I have come across, PW is already faster than most. The crucial thing of any "backend" kind of web-app is: You don't want anything to cache your current view when it shouldn't. If you just edited a page and went back to that same page, you expect to view the latest / current view. I can imagine that a (drastic, i.e. from-the-ground-up) refactoring of the entire PW admin, with a framework like Angular (Vue, React...) would significantly speed things up. But that's a completely new topic, far from trivial, and would really mean a LOT of refactoring... As someone once mentioned, PW admin loads all template and field infos, plus role-/access-based stuff on load. And this takes a lot of time. Of course you could cache that in order to save a few milliseconds, but then again - an admin web view needs the latest state, always. Without completely switching to a modern SPA framework and radical code-rewrite, I don't see much (noticeable) benefits from just using resource hints. The DOM itself is one of the biggest show-stoppers here...
    1 point
  10. Hi @Peejay, did you run the Additional steps / Install Snipcart products package in SnipWire module settings? This step installs product templates, files, fields and some demo pages required to build a Snipcart product catalogue. This additional step is needed to prevent unintended deletion of your Snipcart products catalogue when main module is uninstalled. In the current alpha version this isn't yet checked by SnipWire. If you did already run the additional step with an earlier SnipWire version there will be fields missing which were added in a later version. So you will need to re-run this step. The missing resources(fields, templates, pages, ...) will then be installed. Existing ones won't be touched! To re-run this step, you will need to edit/remove a key in database directly: DB table: "modules" -> find entry with class "SnipWire" -> edit the "data" field and remove the Json key: "product_package":true (be sure to leave a valid Json string - you will need to also remove the corresponding comma : {"api_key":"YOUR_LIVE_API_KEY","api_key_test":"ODQzZTc1MjktZGQxNy00YmUzLWFkMWYtZDE3MDQ2YTk1ODNjNjM2ODE3NTg5NzUyNDQxOTc0","api_key_secret":"YOUR_LIVE_API_KEY_SECRET","api_key_secret_test":"","snipcart_environment":"0","single_page_shop":"","single_page_shop_page":1,"credit_cards":["visa","mastercard","amex"],"currencies":["eur","usd"],"show_cart_automatically":1,"shipping_same_as_billing":1,"show_continue_shopping":1,"split_firstname_and_lastname":1,"snipcart_debug":1,"snipcart_css_path":"https:\/\/cdn.snipcart.com\/themes\/2.0\/base\/snipcart.min.css","snipcart_css_integrity":"","snipcart_js_path":"https:\/\/cdn.snipcart.com\/scripts\/2.0\/snipcart.js","snipcart_js_integrity":"","include_jquery":"","jquery_js_path":"https:\/\/code.jquery.com\/jquery-3.3.1.min.js","jquery_js_integrity":"sha256-FgpCb\/KJQlLNfOu91ta32o\/NMZxltwRo8QtmkMRdAu8=","excluded_templates":["promailer-email","promailer-subscribe"],"cart_image_width":65,"cart_image_height":65,"cart_image_quality":70,"cart_image_hidpi":1,"cart_image_hidpiQuality":50,"cart_image_cropping":1,"data_item_name_field":"title","uninstall":"","submit_save_module":"Submit","taxes_included":1,"webhooks_endpoint":"\/webhooks\/snipcart","include_snipcart_css":1,"taxes":"[{\"name\":\"20% VAT\",\"numberForInvoice\":\"\",\"rate\":\"0.20\",\"appliesOnShipping\":[]},{\"name\":\"10% VAT\",\"numberForInvoice\":\"\",\"rate\":\"0.10\",\"appliesOnShipping\":[]},{\"name\":\"10% VAT (Shipping)\",\"numberForInvoice\":\"\",\"rate\":\"0.10\",\"appliesOnShipping\":[\"1\"]}]","snipwire_debug":1,"data_item_categories_field":"snipcart_item_categories","product_package":true} After the key is removed, visit the SnipCart module settings again and re-run the product package installer! In the release version of SnipCart, this will be handled automatically. On each update it will check if there are new fields or other resources to be installed. Hope this helps! p.s. You could also completely uninstall the SnipCart module and then reinstall - this should also activate the product package installer link! -- Martin
    1 point
  11. Made some changes to the navigation, and the weird issue @bernhard picked up, thanks so far everyone. @JeevanisM I am currently working on that now, will share something soon.
    1 point
  12. UPDATE 2019-11-15 In the last 3 weeks I (nearly) finished the complete order handling for store merchants (ProcessWire backend). This includes the following features: search for orders filter orders extensive overview of all order details download of invoices resend invoices to customers refund amounts to customers ... all right from within your ProcessWire backend! That doesn't sound like much, but it was a good piece of work. ? Here is a short clip to demonstrate the new features:
    1 point
  13. Hey, @JeevanisM! Seems to be the same question as here. Please be patient and do not doublepost. That would probably do more harm than good (to receive a nice and thorough answer).
    1 point
  14. Hey, @JeevanisM! You use an Integer Field for the phone number. Maybe that field cannot store such a big number as 9446196667? Test it with a 123 to check. I guess you should store a phone number in some other field any way. Text would be ok (with some frontend and server validation). There are dedicated fields for this as well like this one.
    1 point
  15. That's where Dart comes in :-). Have a look at the docs and examples. With Dart alone, you can build anything from backend servers, console programs and anything in between. Erm, no you don't. Look at the real world examples/showcase. We are talking Alibaba, Reflectly, Hamilton Musical, and the likes. For iOS we have Cupertino Material design. I am not saying these alone are enough to go by but so far, and I have done extensive research, I have yet to come across anyone mentioning that they have to maintain two code bases. In fact, they all say quite the opposite - they have done away with two code bases and their UI renders exactly as they intended in their targeted platforms. How so? The only thing I don't like so far is the styling and structure baked right inside the widgets. I think flutter had the advantage of learning from other solutions and picking the best bits and improving on the not-so-good bits. I am not a zealot (yet :-)), but the more I dive deeper into Dart and Flutter, the more I get convinced that Google got this one right :-).
    1 point
  16. I had a need to do this and there were some requests in the Table forum so... LimitTable A module for ProcessWire CMS/CMF. Allows limits and restrictions to be placed on selected Profields Table fields. For any Table field you can limit the number of rows that may be added and also prevent the use of drag-sorting and the trashing of rows. If a limit has been defined then there is an option to show all (empty) rows up to that limit. This module does not support paginated Table fields. Usage Install the LimitTable module. The module configuration screen should be self-explanatory. You can add rows in the module config as needed using the "Add another row" button. Please note that limits and restrictions are applied with CSS/JS so should not be considered tamper-proof. Module config: The effect of the above config in Page Edit. The empty rows up to the limit are shown because "Show all rows" is checked. https://github.com/Toutouwai/LimitTable https://processwire.com/modules/limit-table/
    1 point
×
×
  • Create New...