如何将“Customer Id”列添加到 opencart 客户列表?
How to add column " Customer Id " to opencart customer list?
我使用 opencart 1.5.6.4 和 2.3
在管理面板和客户列表中没有客户 ID 列
你能帮我在列名之前添加这个吗?
between this place
感谢
对于 Opencart 2:
您需要编辑此文件:
admin/view/template/customer/customer_list.tpl
1)
查找:
<td class="text-left"><?php if ($sort == 'name') { ?>
前面加上:
<td class="text-left">Customer ID</td>
2)
查找:
<td class="text-left"><?php echo $customer['name']; ?></td>
前面加上:
<td class="text-left"><?php echo $customer['customer_id']; ?></td>
对于 Opencart 1:
此文件:
admin/view/template/sale/customer_list.tpl
1)
查找:
<td class="left"><?php if ($sort == 'name') { ?>
前面加上:
<td class="left">Customer ID</td>
2)
查找:
<td class="left"><?php echo $customer['name']; ?></td>
前面加上:
<td class="left"><?php echo $customer['customer_id']; ?></td>
要在步骤 1 中按 Opencart 2 的 ID 对客户进行排序,请添加此代码:
<td class="text-left">
<?php if ($sort == 'customer_id') { ?>
<a href="<?php echo $sort_customer_id; ?>" class="<?php echo strtolower($order); ?>">Customer ID</a>
<?php } else { ?>
<a href="<?php echo $sort_customer_id; ?>">Customer ID</a>
<?php } ?>
</td>
而不是:
<td class="text-left">Customer ID</td>
然后打开这个文件:
admin/controller/customer/customer.php
查找:
$data['sort_name'] = $this->url->link('customer/customer', 'token=' . $this->session->data['token'] . '&sort=name' . $url, true);
前面加上:
$data['sort_customer_id'] = $this->url->link('customer/customer', 'token=' . $this->session->data['token'] . '&sort=customer_id' . $url, true);
我使用 opencart 1.5.6.4 和 2.3 在管理面板和客户列表中没有客户 ID 列 你能帮我在列名之前添加这个吗? between this place 感谢
对于 Opencart 2: 您需要编辑此文件:
admin/view/template/customer/customer_list.tpl
1) 查找:
<td class="text-left"><?php if ($sort == 'name') { ?>
前面加上:
<td class="text-left">Customer ID</td>
2) 查找:
<td class="text-left"><?php echo $customer['name']; ?></td>
前面加上:
<td class="text-left"><?php echo $customer['customer_id']; ?></td>
对于 Opencart 1: 此文件:
admin/view/template/sale/customer_list.tpl
1) 查找:
<td class="left"><?php if ($sort == 'name') { ?>
前面加上:
<td class="left">Customer ID</td>
2) 查找:
<td class="left"><?php echo $customer['name']; ?></td>
前面加上:
<td class="left"><?php echo $customer['customer_id']; ?></td>
要在步骤 1 中按 Opencart 2 的 ID 对客户进行排序,请添加此代码:
<td class="text-left">
<?php if ($sort == 'customer_id') { ?>
<a href="<?php echo $sort_customer_id; ?>" class="<?php echo strtolower($order); ?>">Customer ID</a>
<?php } else { ?>
<a href="<?php echo $sort_customer_id; ?>">Customer ID</a>
<?php } ?>
</td>
而不是:
<td class="text-left">Customer ID</td>
然后打开这个文件:
admin/controller/customer/customer.php
查找:
$data['sort_name'] = $this->url->link('customer/customer', 'token=' . $this->session->data['token'] . '&sort=name' . $url, true);
前面加上:
$data['sort_customer_id'] = $this->url->link('customer/customer', 'token=' . $this->session->data['token'] . '&sort=customer_id' . $url, true);