瀏覽代碼

[global] User : affichage du nom de famille en premier

refactoring
Guillaume Bourgeois 4 年之前
父節點
當前提交
c0af859b1e
共有 2 個檔案被更改,包括 2 行新增6 行删除
  1. +1
    -5
      backend/views/distribution/report.php
  2. +1
    -1
      common/models/Order.php

+ 1
- 5
backend/views/distribution/report.php 查看文件

@@ -68,11 +68,7 @@ foreach ($pointsSaleArray as $pointSale) {
$strUser = '';

// username
if ($order->user) {
$strUser = $order->user->name . " " . $order->user->lastname;
} else {
$strUser = $order->username;
}
$strUser = $order->getStrUser() ;
if(strlen($order->comment_point_sale))
{

+ 1
- 1
common/models/Order.php 查看文件

@@ -486,7 +486,7 @@ class Order extends ActiveRecordCommon
public function getStrUser()
{
if (isset($this->user)) {
return Html::encode($this->user->name . ' ' . $this->user->lastname);
return Html::encode($this->user->lastname . ' ' . $this->user->name);
} elseif (strlen($this->username)) {
return Html::encode($this->username);
} else {

Loading…
取消
儲存