Jump to content
thirty bees forum

Steve

Members
  • Posts

    155
  • Joined

  • Last visited

Everything posted by Steve

  1. @the-rampage-rado Is it also possible to completely delete the payment step? I could change some code if that's needed.
  2. So the company I currently work for fixes cars for others. When a car is damaged, that goes to our company (with humans doing all the work). This costs a lot of time. I'm currently building the webshop to make it more automated. We want to display the real prices, but without letting the customer pay. (The company is B2B and we'd like to still make payments through human documentation/communication) but ordering and invoices will go through the shop. How can I achieve this?
  3. @traumflug So a theme developer doesn't have to worry about compatibility with addons? A Panda theme works with all thirtybees/prestashop (1.6) addons? Edit: Already got an answer from the theme devs, it should work!
  4. @traumflug One last question. How do I know if 1.6 addons are compatible with 1.6 themes? Like panda (or transformer) theme for example. Are all themes and addons compatible if they're the same version? (Im interested in Product Arrangement module and the one what is this thread is about) Thanks!
  5. But it’s a 80-Euro-gamble, right? Yes it is, I'll most likely buy it and I will update when I tested it.
  6. @wakabayashi The website will be B2B and I need to display extra costs/fees to the cart/checkout/invoice etc. But the developer said the module (https://addons.prestashop.com/nl/prijsbeheer/12794-options-fees-taxes-and-discounts-shipping-cost.html) won't work with TB, but he hasn't tested it. Do you personally think it should work with TB? I can atleast find out and avoid lots of coding. Thanks!
  7. @traumflug Yes I did. When I go to back office -> Price Rules -> Catalog Price Rules and I add a negative discount it says 'The reduction field is invalid.'
  8. So I was interested in buying this module: https://addons.prestashop.com/nl/prijsbeheer/12794-options-fees-taxes-and-discounts-shipping-cost.html However, the dev said that it's not compatible with TB. Does anyone know if there is another addon that is very similar and that is compatible with TB? BTW I have been thinking. Is it possible to reverse discounts (- minus from the total price) from 'Price Rules', to fees (+plus from the total price) with some coding? Thanks!
  9. I'm currently following @Traumflug 's wiki about controllers. I have two questions: How do I add content to the controller? Do I need to change code in AdminMyController.php? If so, what code? Or do I need to make a .tpl file? How can I make a search bar where I can search for every product in my store to add in my controller? Could anyone point me in a general direction or files that I could take as a example? Because I'm not sure if I have the right ones opened for that. Thanks!
  10. @datakick Makes sense haha! Thanks.
  11. @traumflug I've another questions. Why is in the tab 'Price Rules' my module still called 'Updater'? I can't seem to fix that. I've changed const MAIN_CONTROLLER = 'AdminMy'; To: const MAIN_CONTROLLER = 'Fees'; And: $tab->name[$lang['id_lang']] = $this->l('Updater'); To: $tab->name[$lang['id_lang']] = $this->l('Fees'); But it still doesn't change te name? I already cleared the cache and I have deleted class_index.php but without luck. Thanks! (Here is all the code again if you need it) fees.php: ``` <?php if (!defined('TBVERSION_')) exit; class Fees extends Module { const MAIN_CONTROLLER = 'Fees'; public function __construct() { $this->name = 'fees'; $this->tab = 'front_office_features'; $this->version = '1.0.0'; $this->author = 'Stefan'; $this->need_instance = 0; $this->bootstrap = true; parent::__construct(); $this->displayName = $this->l('Fees'); $this->description = $this->l('Give extra fees to products'); $this->tb_versions_compliancy = '> 1.0.0'; $this->ps_versions_compliancy = array('min' => '1.6', 'max' => '1.6.99.99'); } public function install() { $success = parent::install(); if ($success) { try { $tab = new Tab(); $tab->module = $this->name; $tab->class_name = static::MAIN_CONTROLLER; $tab->id_parent = Tab::getIdFromClassName('AdminPriceRule'); $langs = Language::getLanguages(); foreach ($langs as $lang) { $tab->name[$lang['id_lang']] = $this->l('Fees'); } $success = $tab->save(); } catch (Exception $e) { $success = false; } } return $success; } public function uninstall() { $success = true; $tabs = Tab::getCollectionFromModule($this->name); foreach ($tabs as $tab) { $success = $success && $tab->delete(); } return $success && parent::uninstall(); } } ``` AdminMyController.php: ``` <?php if (!defined('TBVERSION_')) { exit; } class AdminMyController extends ModuleAdminController { public function __construct() { $this->bootstrap = true; parent::__construct(); } public function initContent() { $this->page_header_toolbar_title = $this->l('Controller - Fees'); parent::initContent(); } } ```
  12. @traumflug That did it, thanks!
  13. @traumflug Hey, Thanks for your reply. I'm currently following your guide containing information about adding controllers. But my controller tab still says controller not found. Here is MyModule.php 'fees.php' in my case ``` <?php if (!defined('TBVERSION_')) exit; class fees extends Module { const MAIN_CONTROLLER = 'AdminMy'; public function __construct() { $this->name = 'fees'; $this->tab = 'front_office_features'; $this->version = '1.0.0'; $this->author = 'Stefan'; $this->need_instance = 0; $this->bootstrap = true; parent::__construct(); $this->displayName = $this->l('Fees'); $this->description = $this->l('Give extra fees to products'); $this->tb_versions_compliancy = '> 1.0.0'; $this->ps_versions_compliancy = array('min' => '1.6', 'max' => '1.6.99.99'); } public function install() { $success = parent::install(); if ($success) { try { $tab = new Tab(); $tab->module = $this->name; $tab->class_name = static::MAIN_CONTROLLER; $tab->id_parent = Tab::getIdFromClassName('AdminPriceRule'); $langs = Language::getLanguages(); foreach ($langs as $lang) { $tab->name[$lang['id_lang']] = $this->l('Updater'); } $success = $tab->save(); } catch (Exception $e) { $success = false; } } return $success; } public function uninstall() { $success = true; $tabs = Tab::getCollectionFromModule($this->name); foreach ($tabs as $tab) { $success = $success && $tab->delete(); } return $success && parent::uninstall(); } } ``` Here is MyAdminController.php code (and yes I did put in in controllers/admin/AdminMyController.php): ``` <?php if (!defined('TBVERSION_')) { exit; } class AdminMyController extends ModuleAdminController { public function __construct() { $this->bootstrap = true; parent::__construct(); } public function initContent() { $this->page_header_toolbar_title = $this->l('My Controller'); parent::initContent(); } } ``` The tab is also named 'Updater' instead of 'My' like the screenshot from your tutorial btw, no idea if that matters though. Do you perhaps know why it doesn't work?
  14. @lesley The product in TB is supposed to have the fee though, the module only makes it possible to hover over the product (in an image) to add it in my cart. So I'm probably making a module that makes it possible to add fees to products. I don't think TB can do that by default.
  15. Hey, I'm interested in making my own module for thirty bees, is there documentation available for that? Or should I use this page from PrestaShop? Thanks!
  16. Does anyone know if this is possible?
  17. @datakick I will take a look, thanks.
  18. @lesley Hey thanks for the quick reply! Is it completely out of the question? Even with some coding or something?
  19. Hey, Is it possible to send an invoice in PDF form to multiple email adresses when an order is made? So when a customer order a product it sends an invoice to different emails (the customer's email and a another one that I want it to send it to) Thanks!
  20. Hey, I will probably use this module is the near future: https://addons.prestashop.com/en/page-customization/24867-product-arrangement.html Here is the demo I made: https://addons.prestashop.com/demo/FO16852.html (if you get redirected to the home page, go to New Arrivals > Product Arrangement - Bus) I want to be able to give specific fees to specific products on the vehicle. Is that possible? So for example: I want the number 8 backplate to have an extra fee of let's say €100 and letting the buyer know when he/she check's out/when he adds the product to the cart. (The shop will be B2B orientated.) Thanks!
  21. Hey, To add the image mapper to TB I followed these instructions from @lesley @lesley said in Using <area> tag with an image in thirty bees?: Follow these instructions, http://doc.prestashop.com/display/PS16/Building+Image+Maps That will enable the scenes from the backend. Then you will need to add the relevant code to your theme. You will need to make your theme has this reference, https://github.com/PrestaShop/PrestaShop/blob/1.6.1.x/themes/default-bootstrap/category.tpl#L33 and this file, https://github.com/PrestaShop/PrestaShop/blob/1.6.1.x/themes/default-bootstrap/scenes.tpl When I did that and added an image map, it wouldn't save the image map. I got this error in the console: ``` scenes.js:131 Uncaught TypeError: Cannot read property 'remove' of null at HTMLInputElement.afterTextInserted (scenes.js:131) at HTMLInputElement.dispatch (jquery-1.11.0.min.js:3) at HTMLInputElement.r.handle (jquery-1.11.0.min.js:3) at Object.trigger (jquery-1.11.0.min.js:3) at Object.e.event.trigger (jquery-migrate-1.2.1.min.js:2) at HTMLInputElement. (jquery-1.11.0.min.js:3) at Function.each (jquery-1.11.0.min.js:2) at e.fn.init.each (jquery-1.11.0.min.js:2) at e.fn.init.trigger (jquery-1.11.0.min.js:3) at selectCurrent (jquery.autocomplete.js:219) at HTMLUListElement. (jquery.autocomplete.js:581) at HTMLUListElement.dispatch (jquery-1.11.0.min.js:3) at HTMLUListElement.r.handle (jquery-1.11.0.min.js:3) I fixed that by changing line 131 from: window.lastEditedItem.remove(); //line 131 ``` To: if (!!window.lastEditedItem) Now it saves the image map like it should, but it doesn't select the part that I chose but it chooses a random place. Example: This is what I want to map: https://imgur.com/a/1g4lcCv However, when I hover over the images, nothing happens: https://imgur.com/a/Xt5Y4Xh I only get the candle linked once I hover in-between the vehicles: https://imgur.com/a/LKRh0hz Does anyone have a clue why it doesn't work correctly? I've got another question: 1. Why does the picture that I want to map duplicate itself and gets posted twice above my category?: https://imgur.com/a/TYs7X8Z (The image map doesn't work when I hover inside the product itself, so when I go to the candle page for example, it doesn't work. Could that be because of the next and previous picture feature of TB?) P.S: This is an error that I get on the image mapper page in the console: https://imgur.com/a/oeTtxqS (here I get the same error 24 times) Uncaught ReferenceError: doUpdate is not defined at _46 (eval at <anonymous> (jquery.imgareaselect.js:1), <anonymous>:1:5924) at dispatch (jquery-1.11.0.min.js:3) at r.handle (jquery-1.11.0.min.js:3) The weird thing is, I get the same error rapidly once I make the console bigger or smaller with my mouse. https://imgur.com/a/i2jRoW9 (here is the same error 57 times, because I changed the size of the console) Could that be the problem? Thanks!
  22. @traumflug Noted. Will change if any big big hiccups occur. Thanks!
  23. Do you mean the three dots by the top post (my thread starter)? Because I don't see the 'solved' button there. I just edited the title in the meantime.
×
×
  • Create New...