Post by bogdanus91 » Thu Feb 20, 2014 6:44 pm

Hello all. I just created a row in table customer. I have a module that writes information their. It works fine, but I cannot display this field in template here is what I have changed:
catalog/model/account/customer.php

Code: Select all

$sql = "SELECT *, CONCAT(c.firstname, ' ', c.lastname,' ',c.competition_rate,c) AS name, cg.name AS customer_group FROM " . DB_PREFIX . "customer c LEFT JOIN " . DB_PREFIX . "customer_group cg ON (c.customer_group_id = cg.customer_group_id) ";

catalog/view/template/default/ommon/header.php

Code: Select all

<?php echo $competition_rate; ?>
catalog/controller/common/header.php

Code: Select all

$this->data['text_logged'] = sprintf($this->language->get('text_logged'), $this->url->link('account/account', '', 'SSL'), $this->customer->getFirstName(),$this->customer->getcompetition_rate(), $this->url->link('account/logout', '', 'SSL'));
		
And I am getting the following

Fatal error: Call to undefined method Customer::getcompetition_rate() in C:\xampp\htdocs\sport\catalog\controller\common\header.php on line 76

What am I missing? Please help!

Newbie

Posts

Joined
Wed Jul 10, 2013 5:08 pm
Who is online

Users browsing this forum: No registered users and 19 guests