contractor Posted October 12, 2011 Share Posted October 12, 2011 Buna ziua, Folosesc doi curieri si trei metode de plata . Cum as putea atribui fiecarui curier o anumita metoda de plata din cele disponibile ? As dori ca in functie de curierul ales de client sa fie disponibile doar anumite modalitati de plata . Cine ma poate ajuta cu problema mentionata, i-as fi vesnic recunoscator ! Link to comment Share on other sites More sharing options...
valentin.g Posted October 14, 2011 Share Posted October 14, 2011 cred ca as putea sa te ajut. ai siteul online ? Link to comment Share on other sites More sharing options...
contractor Posted October 16, 2011 Author Share Posted October 16, 2011 Da , site-ul este online : www.construct-online.ro . Link to comment Share on other sites More sharing options...
valentin.g Posted October 16, 2011 Share Posted October 16, 2011 e mai greu asa cu OPC dar nu imposibil. Link to comment Share on other sites More sharing options...
lucadezmir Posted November 12, 2011 Share Posted November 12, 2011 helou Domnilor, ma intereseaza si pe mine, extrem de mult, o asemenea configurare. apreciez orice indicatie si sugestie mersi mult, Luca Link to comment Share on other sites More sharing options...
valentin.g Posted November 12, 2011 Share Posted November 12, 2011 toate modulele de plata au un fisier payment.tpl care afiseaza optiuni de plata: <p class="payment_module"> <a href="{$this_path_ssl}validation.php" title="{l s='Pay with cash on delivery (COD)' mod='cashondelivery'}"> <img src="{$this_path}cashondelivery.gif" alt="{l s='Pay with cash on delivery (COD)' mod='cashondelivery'}" style="float:left;" /> <br />{l s='Pay with cash on delivery (COD)' mod='cashondelivery'} <br />{l s='You pay for the merchandise upon delivery' mod='cashondelivery'} <br style="clear:both;" /> </a> </p> se modifica aceste fisiere si adaugam clasa curierID unde ID este numarul de identificare al curierului (vezi curieri) <p class="payment_module curier3"> in acest expl am atasat metoda de plata la curierul cu id-ul 3 acum mai trebuie facuta o functie jQuery care va ascunde restul curierilor. Link to comment Share on other sites More sharing options...
lucadezmir Posted November 14, 2011 Share Posted November 14, 2011 mersi valentin.g am notiuni de baza, atat cat sa modific in fisiere si sa lucrez cu baze de date, daca mi se explica detaliat cum daca poti sa-mi detaliezi, e suuuper, daca nu, o sa angajez un programator... oricum, cred ca un tutorial mai detaliat ar fi benefic si pentru altii, ma uit la numarul de vizionari al acestui subiect... Luca Link to comment Share on other sites More sharing options...
valentin.g Posted November 15, 2011 Share Posted November 15, 2011 Modificarile sunt pentru Cos cumparaturi in 5 steps si Presta 1.4 PASUL 1 Back Office > Shipping > Carriers se definesc mai intai curierii cu tot ce trebuie si apoi sa copie ID-urile fiecaruia ATENTIE! daca mai tarziu modificati un curier acest ID se schimba automat PASUL2 pentru fiecare modul de plata este un fisier TPL care afiseaza optiunea de plata, modificam acest fisier si adaugam aici carui curier ii asociem metoda de plata. de expl pentru Cash on Delivery avem payment.tpl <p class="payment_module curier3 curier1"> ... </p> in acest exemplu am asociat 2 curieri: curier3 si curier1 cu metoda Cash on Delivery. PASUL3 modificam din tema corespunzatoare fisierul order-payment.tpl si adaugam la final {if !$opc} <script type="text/javascript"> // <![CDATA[ $(document).ready(function() { var curier = 'curier{$curier_id}'; $('#HOOK_PAYMENT p.payment_module').each(function(){ if (!($(this).hasClass(curier))) $(this).remove(); }) }); //]]> </script> {/if} PASUL4 modificam controllers/ParentOrderControler.php protected function _assignPayment() { self::$smarty->assign(array( 'curier_id' => self::$cart->id_carrier, 'HOOK_TOP_PAYMENT' => Module::hookExec('paymentTop'), 'HOOK_PAYMENT' => Module::hookExecPayment() )); } Link to comment Share on other sites More sharing options...
lucadezmir Posted November 18, 2011 Share Posted November 18, 2011 valentin.g mersi inca o data o sa incerc si o sa revin cu un feedback legat de implementare... Link to comment Share on other sites More sharing options...
Cornel_M Posted October 25, 2012 Share Posted October 25, 2012 (edited) Are cineva solutia si pentru presta 1.5.1 cu OPC ? am incercat pasii de mai sus, la pasul 3 am modificat order-opc.tpl si nu e nicio schimbare. in varianta cu 5 pasi functioneaza si in 1.5.1 Edited October 25, 2012 by Cornel_M (see edit history) 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