Page 1 of 1

Improving affiliate info for 1.5.4.1

Posted: Tue May 28, 2013 2:14 am
by Jorge Luiz
Hi,

I'm trying to put some extra columns in transaction to make it more clear to me (admin) and to affiliates.
It seems simple but I don't have the expertise to do that without any help.
As I think it can help many other people, here I'm.

I made some changes in Admin area - Sales > affiliate > tab > transaction.

Here is a printscreen of the columns I have created:
ADMIN.png

ADMIN.png (35.51 KiB) Viewed 930 times

Here are the modifications:
-------------------------------------------------------------------------------------------
admin/view/template/sale/affiliate_transaction.tpl (add)
(12)
<td class="left"><?php echo $column_customer; ?></td>
<td class="left"><?php echo $column_order_total; ?></td>
<td class="left"><?php echo $column_commission; ?></td>

(24)
<td class="left">&nbsp;</td>
<td class="left">&nbsp;</td>
<td class="left">&nbsp;</td>

(31)
<td class="left">&nbsp;</td>
<td class="left">&nbsp;</td>
<td class="left">&nbsp;</td>

-------------------------------------------------------------------------------------------
admin/language/portuguese-br/sale/affiliate.php (add)
(23)
$_['column_customer'] = 'Cliente';
$_['column_order_total'] = 'Valor da Compra';
$_['column_commission'] = 'Comissão';

-------------------------------------------------------------------------------------------
admin/controller/sale/affiliate.php (add)
(1024)
$this->data['column_customer'] = $this->language->get('column_customer');
$this->data['column_order_total'] = $this->language->get('column_order_total');
$this->data['column_commission'] = $this->language->get('column_commission');
_____________________________________________________________________________________________________


I also added two columns in affiliates area - Affiliate panel > transactions.
Here is the printscreen:
Afiliatearea.png

Afiliatearea.png (29.43 KiB) Viewed 930 times

Here are the modifications:
-------------------------------------------------------------------------------------------
catalog/view/theme/default/template/affiliate/transaction.tpl (add)
(15)
<td class="left"><?php echo $column_order_total; ?></td>
<td class="left"><?php echo $column_commission; ?></td>
(25)
<td class="left">&nbsp;</td>
<td class="left">&nbsp;</td>

-------------------------------------------------------------------------------------------
catalog/language/portuguese-br/affiliate/transaction.php (add)
(9)
$_['column_order_total'] = 'Valor da Compra';
$_['column_commission'] = 'Comissão';

-------------------------------------------------------------------------------------------
catalog/controller/affiliate/transaction.php (add)
(43)
$this->data['column_order_total'] = $this->language->get('column_order_total');
$this->data['column_commission'] = $this->language->get('column_commission');
_____________________________________________________________________________________________________

My intention is to make it work.
I see that there are not those fields into transactions table in the Database.
Is it the simplest way to do that, putting those fields on there?

Any tip, any clue, any help, any good intention is accepted!

Re: Improving affiliate info for 1.5.4.1

Posted: Tue May 28, 2013 3:51 pm
by rph
Use the order_id in affiliate_transaction to grab the data you need from the order / order_total tables.

Re: Improving affiliate info for 1.5.4.1

Posted: Wed Oct 16, 2013 12:51 pm
by ajie.kurniyawan
Hi, I need to do this too.. anyone can you help to make it work?