Jump to content

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

Forname Surname In Recent Orders Rate Topic   - - - - -

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

Posted 04 April 2019 - 09:37 AM #1

Hi All,

 

This will probably sound like a really basic question but I'm not sure where I need to make this change.

I would like to change the order of the name on the admin backend, under "Recent Orders". Presently, it is listed as "surname forename" but I would prefer to display it as "forename surname" 

 

 



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

Posted 04 April 2019 - 01:20 PM #2

design/backend/templates/views/index/index.tpl

 

replace

 

{$order.lastname} {$order.firstname}
 

 

with

 

{$order.firstname} {$order.lastname}
 

 

Then clear cache


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
  • 156 posts

Posted 04 April 2019 - 01:47 PM #3

Thanks eCom! I'll try this shortly. I just want to confirm the path 

 

 

design/backend/templates/views/index/index.tpl

is still correct if I am using the old admin-panel addon?



 
  • orangegirl
  • Support engineer
  • CS-Cart Support
  • Join Date: 08-Jan 08
  • 589 posts

Posted 05 April 2019 - 07:26 AM #4

Ghiyas, then the path will be

 

design/backend/templates/addons/old_adminpanel/overrides/views/index/index.tpl


Kate Lazarevskaya,
CS-Cart Support Engineer
CS-Cart Knowledge Base | CS-Cart Reference Guide

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

Posted 05 April 2019 - 08:00 AM #5

Amazing, thank you! That worked great! 

Could you also advise how I can swap them around in the "orders" and "customers" area? What files do I need to edit?



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

Posted 05 April 2019 - 01:25 PM #6

Try

 

design/backend/templates/addons/old_adminpanel/overrides/views/orders/manage.tpl

 

and

 

design/backend/templates/addons/old_adminpanel/overrides/views/profiles/manage.tpl


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 руб.


 
  • The Tool
  • Been Here Way Too Long Member
  • Members
  • Join Date: 30-Mar 07
  • 3829 posts

Posted 06 April 2019 - 05:28 PM #7

Also on the abandoned cart page:

/design/backend/templates/views/cart/cart_list.tpl



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

Posted 08 April 2019 - 07:47 AM #8

Also on the abandoned cart page:

/design/backend/templates/views/cart/cart_list.tpl

 

How would I go about editing that file? Would I need to change it from:

        {if $customer.user_data.email}<a href="{"profiles.update?user_id=`$customer.user_id`"|fn_url}" class="underlined">{if $customer.firstname || $customer.lastname}{$customer.lastname} {$customer.firstname}{else}{$customer.user_data.email}{/if}</a>{if $customer.phone}<br />{__('phone')} <bdi>{$customer.phone}</bdi>{/if}{else}{__("unregistered_customer")} {if $customer.lastname || $customer.firstname}<p>{$customer.lastname} {$customer.firstname} {if $customer.email}({$customer.email}){/if}{if $customer.phone}<br />{__('phone')} {$customer.phone}{/if}{/if}</p>{/if}

to: 

        {if $customer.user_data.email}<a href="{"profiles.update?user_id=`$customer.user_id`"|fn_url}" class="underlined">{if $customer.firstname || $customer.lastname}{$customer.firstname} {$customer.lastname}{else}{$customer.user_data.email}{/if}</a>{if $customer.phone}<br />{__('phone')} <bdi>{$customer.phone}</bdi>{/if}{else}{__("unregistered_customer")} {if $customer.firstname || $customer.lastname}<p>{$customer.firstname} {$customer.lastname} {if $customer.email}({$customer.email}){/if}{if $customer.phone}<br />{__('phone')} {$customer.phone}{/if}{/if}</p>{/if}


 
  • The Tool
  • Been Here Way Too Long Member
  • Members
  • Join Date: 30-Mar 07
  • 3829 posts

Posted 08 April 2019 - 11:31 AM #9

        {if $customer.user_data.email}<a href="{"profiles.update?user_id=`$customer.user_id`"|fn_url}" class="underlined">{if $customer.firstname || $customer.lastname}{$customer.firstname} {$customer.lastname}{else}{$customer.user_data.email}{/if}</a>{if $customer.phone}<br />{__('phone')} <bdi>{$customer.phone}</bdi>{/if}{else}{__("unregistered_customer")} {if $customer.lastname || $customer.firstname}<p>{$customer.firstname} {$customer.lastname} {if $customer.email}({$customer.email}){/if}{if $customer.phone}<br />{__('phone')} {$customer.phone}{/if}{/if}</p>{/if}


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

Posted 09 April 2019 - 07:29 AM #10

        {if $customer.user_data.email}<a href="{"profiles.update?user_id=`$customer.user_id`"|fn_url}" class="underlined">{if $customer.firstname || $customer.lastname}{$customer.firstname} {$customer.lastname}{else}{$customer.user_data.email}{/if}</a>{if $customer.phone}<br />{__('phone')} <bdi>{$customer.phone}</bdi>{/if}{else}{__("unregistered_customer")} {if $customer.lastname || $customer.firstname}<p>{$customer.firstname} {$customer.lastname} {if $customer.email}({$customer.email}){/if}{if $customer.phone}<br />{__('phone')} {$customer.phone}{/if}{/if}</p>{/if}

 

Thanks TheTool! That worked perfectly, not sure why it's set to lastname firstname by default but it's difficult to change to firstname lastname (instead of having a setting on the backend) but I'm sure someone here can enlighten me?



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

Posted 09 April 2019 - 01:20 PM #11

Thanks TheTool! That worked perfectly, not sure why it's set to lastname firstname by default but it's difficult to change to firstname lastname (instead of having a setting on the backend) but I'm sure someone here can enlighten me?

 

The answer is simple. Such format is popular in Russia


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
  • 156 posts

Posted 11 April 2019 - 09:43 AM #12

The answer is simple. Such format is popular in Russia

 

That makes sense but the  firstname lastname format is popular in other countries, so it would have been nice if it was easy to change (with a dropdown option in Appearance) instead of having to change multiple files. Maybe one day this will be implemented by the CS-Cart team



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

Posted 11 April 2019 - 01:15 PM #13

You can put your request to the bug tracker as feature request. But I do not think that they will add this feature in the nearest releases


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 руб.