标题优化
This commit is contained in:
parent
b3df1c05d0
commit
ff78305aee
@ -161,6 +161,14 @@ abstract class AbstractExport implements WithEvents, WithTitle, ShouldAutoSize
|
|||||||
$title = Carbon::parse($conditions['month'])->format('Ym') . ' ' . $title;
|
$title = Carbon::parse($conditions['month'])->format('Ym') . ' ' . $title;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (($conditions = $this->conditions) && $conditions['company_id']) {
|
||||||
|
$title = $title . ' C' . $conditions['company_id'];
|
||||||
|
}
|
||||||
|
|
||||||
|
if (($conditions = $this->conditions) && $conditions['company_name']) {
|
||||||
|
$title = $conditions['company_name'] . ' ' . $title;
|
||||||
|
}
|
||||||
|
|
||||||
return $title ?? '列表';
|
return $title ?? '列表';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -121,6 +121,10 @@ class CompanyReportDetailExport extends AbstractExport implements FromQuery, Wit
|
|||||||
$title = Carbon::parse($conditions['month'])->format('Ym') . ' ' . $title;
|
$title = Carbon::parse($conditions['month'])->format('Ym') . ' ' . $title;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (($conditions = $this->conditions) && $conditions['company_id']) {
|
||||||
|
$title = $title . ' C' . $conditions['company_id'];
|
||||||
|
}
|
||||||
|
|
||||||
return $title ?? '列表';
|
return $title ?? '列表';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -80,6 +80,10 @@ class CompanyReportExport extends AbstractExport implements FromCollection, With
|
|||||||
$title = Carbon::parse($conditions['month'])->format('Ym') . ' ' . $title;
|
$title = Carbon::parse($conditions['month'])->format('Ym') . ' ' . $title;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (($conditions = $this->conditions) && $conditions['company_name']) {
|
||||||
|
$title = $conditions['company_name'] . ' ' . $title;
|
||||||
|
}
|
||||||
|
|
||||||
return $title ?? '列表';
|
return $title ?? '列表';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user