Author Topic: Royal Mail - delivery times  (Read 5376 times)

Offline jesus_automatic

  • Jr. Member
  • **
  • Posts: 75
  • Karma: +5/-0
    • View Profile
Royal Mail - delivery times
« on: December 16, 2013, 08:31:23 AM »
Royal Mail shipping extension has an option to display delivery times. When checked it displays alongside the check box for that shipping method in checkout the text "Estimated time". There is no form to enter data on actual time (i.e 3-5 days)

Can someone point me to the file and method to put that text in?
Ive looked at
/extensions/default_royal_mail/storefront/model/extension/default_royal_mail.php and for second class post in line 180 it is calling for 'text_eta' but there is no reference to a value for this variable

if ($this->config->get('default_royal_mail_display_time')) {
                  $title .= ' (' . $this->language->get('text_eta') . ')';
               }               
      

I dont know where to look next.

Offline abolabo

  • core-developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 2046
  • Karma: +318/-13
  • web for all, all for web!
    • View Profile
    • AbanteCart
Re: Royal Mail - delivery times
« Reply #1 on: December 17, 2013, 07:41:12 AM »
public_html/extensions/default_royal_mail/storefront/language/english/default_royal_mail/default_royal_mail.xml
Code: [Select]
<definition>
    <key>text_eta</key>
    <value><![CDATA[Estimated Time:]]></value>
  </definition>
“No one is useless in this world who lightens the burdens of another.”
― Charles Dickens

Offline jesus_automatic

  • Jr. Member
  • **
  • Posts: 75
  • Karma: +5/-0
    • View Profile
Re: Royal Mail - delivery times
« Reply #2 on: December 20, 2013, 05:36:45 PM »
Thanks abolabo
I did look there first and looking at it again two things come to mind.
One, where in that line would I put in my text string. e.g. "3-5 days" (i'm sorry my knowledge of all code is limited)
Two, that definition appears to be general to the whole royal mail extension. I need different delivery times for the different delivery methods royal mail provide.

In the six months I have been working of this I have learnt so much, but most of the time I am still in the dark. Though, I do have a functioning website, and even a few customers.

Thank you for all your help

Offline junkyard

  • Full Member
  • ***
  • Posts: 127
  • Karma: +25/-0
    • View Profile
Re: Royal Mail - delivery times
« Reply #3 on: December 20, 2013, 08:47:05 PM »
hi, the value for this variable (text_eta) you can redefine in admin>system>localisation>language definitions:
sort it by key "text_eta" for the default_royal_mail_default_royal_mail block.
This, of course, will only allow you to define general Delivery Time for all delivery methods royal mail provide (e.g.  Estimated Time: 4-7 days) because as
you can see in public_html/extensions/default_royal_mail/storefront/model/extension/default_royal_mail.php
there is the same language variable (text_eta) for all royal_mail's IDs (methods). To display different text_eta's for the different RM's methods more php code
has to be written there (sort of new feature?), something that only developers like abolabo can help or consider for the implementation.

Offline jesus_automatic

  • Jr. Member
  • **
  • Posts: 75
  • Karma: +5/-0
    • View Profile
Re: Royal Mail - delivery times
« Reply #4 on: December 21, 2013, 05:52:55 PM »
Thanks Junkyard. I looked at the language definition, but as you say that applies to all RM delivery methods. Really I need separate times for different delivery methods. So the customer can choose to pay more for a quicker delivery. Its not critical of course, but next time a developer is looking at this extension they should include this feature.

 

Powered by SMFPacks Social Login Mod