
venditdevs
Members-
Posts
37 -
Joined
-
Last visited
Profile Information
-
Location
Netherlands
-
Activity
Developer
Recent Profile Visitors
566 profile views
venditdevs's Achievements
-
venditdevs started following Strange db problems! Urgent help needed. , Add to cart Spinner problem , Problem Prestashop 1.7.6.2 and (1) onKernelRequest in admin.php and 6 others
-
@bourat, Are you using a Sendcloud plugin on your website? Or did you use it on that site while that problem occured?
-
Hi All, We have a strange problem and hoping anyone know whats the issue. We get strange message "forbidden" when we try to edit translations and instantly get logged out. Page is empy and message is only "forbidden". This comes from the file /src/adapter/security/admin.php. //if employee loggdin in legacy context, authenticate him into sf2 security context if (isset($this->legacyContext->employee) && $this->legacyContext->employee->isLoggedBack()) { $user = $this->userProvider->loadUserByUsername($this->legacyContext->employee->email); $token = new UsernamePasswordToken($user, null, 'admin', $user->getRoles()); $this->securityTokenStorage->setToken($token); return true; } First time entering page we enter this if statement, then it set some vars and return true. It looks like the second time its variables are not set ( isset($this->legacyContext->employee) && $this->legacyContext->employee->isLoggedBack() ) and then it skips the progress and return a false later in the file and where it redirect to the login page. Some problem we have with editing products, which also results in same error in the same file. When i commend out the if statement it works! But after saving we still get logged out. We tried disabling all overrides and modules already without any luck. Also updating Prestashop to the latest version didn't help.
-
The code works for most of the time but sometimes it creates a new id_customization for every textfield. So textfield_1 has e.g. id_customization = 3 and textfield_2 has e.g. id_customization = 4 when they should haven been both id_customization = 3 Can't put my finger on it. Bug in Presta?
-
Original file can be found here: /ADMINFOLDER/themes/default/template/controllers/modules/list.tpl
-
Hi everyone, I'm pulling my hair out right now. We are integrating multistore in our module that connects our POS system to Prestashop. We want to add categories through import. That is working BUT ...all categories are added to ALL shops instead of the id_shop we are importing into. Does any of you know how we can manage that through the category object? The AdminCategoryController doesn't answer my questions With best regards, Vincent
-
Validate.js Postcode validation always fail. Countries is empty
venditdevs replied to venditdevs's topic in Core developers
After 2 days i've finally found it i think. In another theme js file i've found this line in a function : countries = countriesPS Commented it and it works now. -
Hi, In validate.js there is this code: function validate_field(that) { if ($(that).hasClass('is_required') || $(that).val().length) { if ($(that).attr('data-validate') == 'isPostCode') { var selector = '#id_country'; if ($(that).attr('name') == 'postcode_invoice') selector += '_invoice'; var id_country = $(selector + ' option:selected').val(); if (typeof(countriesNeedZipCode[id_country]) != 'undefined' && typeof(countries[id_country]) != 'undefined') var result = window['validate_'+$(that).attr('data-validate')]($(that).val(), countriesNeedZipCode[id_country], countries[id_country]['iso_code']); } else if($(that).attr('data-validate')) var result = window['validate_' + $(that).attr('data-validate')]($(that).val()); if (result) $(that).parent().removeClass('form-error').addClass('form-ok'); else $(that).parent().addClass('form-error').removeClass('form-ok'); } } $(document).on('focusout', 'input.validate, textarea.validate', function() { validate_field(this); }); But the validation fails on empty var 'countries' when you need to check on postcode/zipcode If i do this: $(document).on('focusout', 'input.validate, textarea.validate', function() { console.log(countries); validate_field(this); }); It gives an empty array If i do this: $(document).ready(function(){ console.log(countries); $(document).on('focusout', 'input.validate, textarea.validate', function() { console.log(countries); validate_field(this); }); }); It gives me 1 filled array(the first) and 1 empty (the second) If i set a console.log to output 'countries' in the validate_field function it also logs an empty array. Seems to be failing on all our Prestashop installations ( with various different templates ) Any help/fix would be appreciated.
-
Hi, There is an annoying problem when you edit a carrier. If you change something in the settings of a carrier and you save it the carrier gets a new ID. This is a problem because customers of ours use a module where you set some custom settings for a carrier based on carrier ID. A carrier id must not change when you EDIT ther carrier. This is really strange and very undesirable behaviour. Tested it with prestashop 1.6.0.X and 1.6.1.X. All the same. Anyone have a solution? With kind regards
-
Strange db problems! Urgent help needed.
venditdevs replied to eomer's topic in Installing PrestaShop for the first time
I can't delete the tabel...it isn't there......but error still exists. [EDIT] It is fixed when you disable DEV mode in defines.inc.php -
Strange db problems! Urgent help needed.
venditdevs replied to eomer's topic in Installing PrestaShop for the first time
Same problem here after canceling a payment [PrestaShopDatabaseException] Table 'ps_product_reductions' already exists CREATE TEMPORARY TABLE `ps_product_reductions` (id_product INT UNSIGNED NOT NULL DEFAULT 0, id_product_attribute INT UNSIGNED NOT NULL DEFAULT 0) ENGINE=MEMORY at line 791 in file classes/db/Db.php 786. if ($webservice_call && $errno) { 787. $dbg = debug_backtrace(); 788. WebserviceRequest::getInstance()->setError(500, ' '.$this->getMsgError().'. From '.(isset($dbg[3]['class']) ? $dbg[3]['class'] : '').'->'.$dbg[3]['function'].'() Query was : '.$sql, 97); 789. } elseif (_PS_DEBUG_SQL_ && $errno && !defined('PS_INSTALLATION_IN_PROGRESS')) { 790. if ($sql) { 791. throw new PrestaShopDatabaseException($this->getMsgError().'<br /><br /><pre>'.$sql.'</pre>'); 792. } 793. 794. throw new PrestaShopDatabaseException($this->getMsgError()); 795. } 796. } •DbCore->displayError - [line 425 - classes/db/Db.php] - [1 Arguments] •DbCore->query - [line 601 - classes/db/Db.php] - [1 Arguments] •DbCore->execute - [line 2379 - classes/Product.php] - [2 Arguments] •ProductCore::getRandomSpecial - [line 104 - modules/blockspecials/blockspecials.php] - [1 Arguments] •BlockSpecials->hookRightColumn - [line 587 - classes/Hook.php] - [1 Arguments] •HookCore::coreCallHook - [line 544 - classes/Hook.php] - [3 Arguments] •HookCore::exec - [line 582 - classes/controller/FrontController.php] - [2 Arguments] •FrontControllerCore->initContent - [line 34 - modules/paynl_paymentmethods/controllers/front/return.php] •paynl_paymentmethodsReturnModuleFrontController->initContent - [line 189 - classes/controller/Controller.php] •ControllerCore->run - [line 367 - classes/Dispatcher.php] •DispatcherCore->dispatch - [line 28 - index.php] I will delete the column manually and see if i can reproduce -
Addition: Yes you can uncheck the category but it isn't deactivated, it's just removed from the category shop table. Not very usefull if you want to enable it again by a module because you have no reference;)
-
Hi fred-vinapresta, Yes you can, but you can't disable them temporarly for that shop. If i want to disable them for a specific store i will have to remove them...that's something i ( and the customer) don't want. We want to disable it end re-enable it when we need it to.