Jump to content

  • You cannot start a new topic
  • You cannot reply to this topic

Editing Variables? Rate Topic   - - - - -

 
  • Ghiyas
  • Senior Member
  • Trial users
  • Join Date: 07-Aug 17
  • 150 posts

Posted 30 August 2017 - 08:32 AM #1

I am currently editing the invoice template using the documents editor (using v4.5.2) and I was wondering if there is a way to edit a variable? Specifically, I would like to edit  {{ o.timestamp }} so it only shows the date (currently it give the date and time). Is this at all possible?

 

Many thanks!



 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 19379 posts

Posted 30 August 2017 - 01:17 PM #2

Date and time format is got from Settings. You can change format in the following file

 

app/Tygh/Tools/Formatter.php

$this->default_datetime_format = $this->settings['Appearance']['date_format'] . ', ' . $this->settings['Appearance']['time_format'];

GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.


 
  • Ghiyas
  • Senior Member
  • Trial users
  • Join Date: 07-Aug 17
  • 150 posts

Posted 30 August 2017 - 01:39 PM #3

Thank you eComLabs for the advice, as this did exactly what I needed. I removed ". ', ' . $this->settings['Appearance']['time_format']and it did remove the time stamp.  :grin:



 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 19379 posts

Posted 31 August 2017 - 06:08 AM #4

You are welcome!


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.