juanmlg Posted April 27, 2018 Share Posted April 27, 2018 (edited) Hello, I need to see the customer's age in the back office order page, so I edited the view.tpl as: Quote <dl class="well list-detail"> <dt>{l s='Email'}</dt> <dd><a href="mailto:{$customer->email}"><i class="icon-envelope-o"></i> {$customer->email}</a></dd> <dt>{l s='Age'}</dt> <dd>{$customer->birthday}</dd> <dt>{l s='Account registered'}</dt> <dd class="text-muted"><i class="icon-calendar-o"></i> {dateFormat date=$customer->date_add full=true}</dd> <dt>{l s='Valid orders placed'}</dt> <dd><span class="badge">{$customerStats['nb_orders']|intval}</span></dd> <dt>{l s='Total spent since registration'}</dt> <dd><span class="badge badge-success">{displayPrice price=Tools::ps_round(Tools::convertPrice($customerStats['total_orders'], $currency), 2) currency=$currency->id}</span></dd> {if Configuration::get('PS_B2B_ENABLE')} <dt>{l s='Siret'}</dt> <dd>{$customer->siret}</dd> <dt>{l s='APE'}</dt> <dd>{$customer->ape}</dd> {/if} </dl> But now I see the birthday date (obv) but I don't know any variable for the age number. Can you please help me to get the age instead of birthday date? Maybe I need to use some maths? Thanks! Edited April 27, 2018 by juanmlg (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