mirror of
https://github.com/Karaka-Management/oms-HumanResourceManagement.git
synced 2026-01-23 17:38:40 +00:00
make members public
This commit is contained in:
parent
dd081073ab
commit
cd9958237f
|
|
@ -47,7 +47,7 @@ class EmployeeHistory implements \JsonSerializable, ArrayableInterface
|
|||
* @var int|Employee
|
||||
* @since 1.0.0
|
||||
*/
|
||||
private $employee = 0;
|
||||
public $employee = 0;
|
||||
|
||||
/**
|
||||
* Unit
|
||||
|
|
@ -55,7 +55,7 @@ class EmployeeHistory implements \JsonSerializable, ArrayableInterface
|
|||
* @var null|int|Unit
|
||||
* @since 1.0.0
|
||||
*/
|
||||
private $unit = null;
|
||||
public $unit = null;
|
||||
|
||||
/**
|
||||
* Department
|
||||
|
|
@ -63,7 +63,7 @@ class EmployeeHistory implements \JsonSerializable, ArrayableInterface
|
|||
* @var null|int|Department
|
||||
* @since 1.0.0
|
||||
*/
|
||||
private $department = null;
|
||||
public $department = null;
|
||||
|
||||
/**
|
||||
* Position
|
||||
|
|
@ -71,7 +71,7 @@ class EmployeeHistory implements \JsonSerializable, ArrayableInterface
|
|||
* @var null|int|Position
|
||||
* @since 1.0.0
|
||||
*/
|
||||
private $position = null;
|
||||
public $position = null;
|
||||
|
||||
/**
|
||||
* Files.
|
||||
|
|
|
|||
|
|
@ -15,6 +15,7 @@ declare(strict_types=1);
|
|||
|
||||
use Modules\HumanResourceManagement\Models\NullEmployeeHistory;
|
||||
use phpOMS\Uri\UriFactory;
|
||||
use Modules\Media\Models\NullMedia;
|
||||
|
||||
/**
|
||||
* @var \phpOMS\Views\View $this
|
||||
|
|
@ -42,7 +43,7 @@ echo $this->getData('nav')->render(); ?>
|
|||
<?php $c = 0; foreach ($employees as $key => $value) : ++$c;
|
||||
$url = UriFactory::build('{/prefix}humanresource/staff/profile?{?}&id=' . $value->getId()); ?>
|
||||
<tr tabindex="0" data-href="<?= $url; ?>">
|
||||
<td><a href="<?= $url; ?>"><img width="30" loading="lazy" class="profile-image"
|
||||
<td><a href="<?= $url; ?>"><img width="30" loading="lazy" class="profile-image"
|
||||
src="<?=
|
||||
$value->profile->image instanceof NullMedia ?
|
||||
UriFactory::build('Web/Backend/img/user_default_' . \mt_rand(1, 6) .'.png') :
|
||||
|
|
@ -51,9 +52,9 @@ echo $this->getData('nav')->render(); ?>
|
|||
<td data-label="<?= $this->getHtml('Name'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml(
|
||||
\sprintf('%3$s %2$s %1$s', $value->profile->account->name1, $value->profile->account->name2, $value->profile->account->name3)
|
||||
); ?></a>
|
||||
<td><?= $this->printHtml($value->getNewestHistory()->getUnit()->name); ?>
|
||||
<td><?= $this->printHtml($value->getNewestHistory()->getPosition()->name); ?>
|
||||
<td><?= $this->printHtml($value->getNewestHistory()->getDepartment()->name); ?>
|
||||
<td><?= $this->printHtml($value->getNewestHistory()->unit->name); ?>
|
||||
<td><?= $this->printHtml($value->getNewestHistory()->position->name); ?>
|
||||
<td><?= $this->printHtml($value->getNewestHistory()->department->name); ?>
|
||||
<td><?= !($value->getNewestHistory() instanceof NullEmployeeHistory) ? $this->getHtml('Active') : $this->getHtml('Inactive'); ?>
|
||||
<?php endforeach; ?>
|
||||
<?php if ($c === 0) : ?>
|
||||
|
|
|
|||
|
|
@ -61,13 +61,13 @@ echo $this->getData('nav')->render(); ?>
|
|||
<table class="list">
|
||||
<tr>
|
||||
<th><?= $this->getHtml('Position'); ?>
|
||||
<td itemprop="jobTitle"><?= $this->printHtml($recentHistory->getPosition()->name); ?>
|
||||
<td itemprop="jobTitle"><?= $this->printHtml($recentHistory->position->name); ?>
|
||||
<tr>
|
||||
<th><?= $this->getHtml('Department'); ?>
|
||||
<td itemprop="jobTitle"><?= $this->printHtml($recentHistory->getDepartment()->name); ?>
|
||||
<td itemprop="jobTitle"><?= $this->printHtml($recentHistory->department->name); ?>
|
||||
<tr>
|
||||
<th><?= $this->getHtml('Unit'); ?>
|
||||
<td itemprop="jobTitle"><?= $this->printHtml($recentHistory->getUnit()->name); ?>
|
||||
<td itemprop="jobTitle"><?= $this->printHtml($recentHistory->unit->name); ?>
|
||||
<tr>
|
||||
<th><?= $this->getHtml('Birthday'); ?>
|
||||
<td itemprop="birthDate">06.09.1934
|
||||
|
|
@ -121,9 +121,9 @@ echo $this->getData('nav')->render(); ?>
|
|||
<?php foreach ($history as $hist) : ?>
|
||||
<tr><td><?= $hist->getStart()->format('Y-m-d'); ?>
|
||||
<td><?= $hist->getEnd() === null ? '' : $hist->getEnd()->format('Y-m-d'); ?>
|
||||
<td><?= $this->printHtml($hist->getUnit()->name); ?>
|
||||
<td><?= $this->printHtml($hist->getDepartment()->name); ?>
|
||||
<td><?= $this->printHtml($hist->getPosition()->name); ?>
|
||||
<td><?= $this->printHtml($hist->unit->name); ?>
|
||||
<td><?= $this->printHtml($hist->department->name); ?>
|
||||
<td><?= $this->printHtml($hist->position->name); ?>
|
||||
<?php endforeach; ?>
|
||||
</table>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user