Zeiterfassungs Update

* neue Migration für Personaladministration (Aktive Verrechnung)
 * Verrechnung Anpassungen Black P.
 * superexpertEnabled Implementation Verrechnung/Personaladministration
 * Personaladministration (Aktive Verrechnung/Zeiterfassung Enddatum)
This commit is contained in:
Spitzer Daniel
2024-04-01 17:35:38 +02:00
parent 83b01ce931
commit c3ebfdfd2a
9 changed files with 112 additions and 15 deletions

View File

@@ -40,6 +40,7 @@ class TimerecordingBillingController extends mfBaseController
$month = strtotime("01." . $month);
$timerecordingsEmolyees = TimerecordingEmployeeModel::getAll();
foreach ($timerecordingsEmolyees as $timerecordingsEmolyee) {
if ($timerecordingsEmolyee->bmd_active == 0) continue;
$user = new User($timerecordingsEmolyee->user_id);
$employee_number = (string)$user->getFlag('employee_number');
$timerecordingReport = new TimerecordingReportController();
@@ -125,6 +126,7 @@ class TimerecordingBillingController extends mfBaseController
$companybmd = "1";
$timerecordingsEmolyees = TimerecordingEmployeeModel::getAll();
foreach ($timerecordingsEmolyees as $timerecordingsEmolyee) {
if ($timerecordingsEmolyee->bmd_active == 0) continue;
$user = new User($timerecordingsEmolyee->user_id);
$employee_number = (string)$user->getFlag('employee_number');
$employeetypesbmd = TimerecordingEmployeeModel::$employeetypesbmd;

View File

@@ -114,13 +114,21 @@ class TimerecordingEmployeeController extends mfBaseController
$data['holidays'] = trim($r->holidays);
$data['plushours'] = $plushours;
$data['startdate'] = strtotime($r->startdate);
$data['enddate'] = strtotime($r->enddate);
$data['type'] = trim($r->type);
$data['bmd_active'] = trim($r->bmd_active);
$data['overtime'] = $overtime;
#
if (!$data['overtime']) {
$data['overtime'] = 0;
}
if (!$data['bmd_active']) {
$data['bmd_active'] = 0;
}
if (!$data['enddate']) {
$data['enddate'] = null;
}
if ($r->birthday) {
$data['birthday'] = strtotime($r->birthday);

View File

@@ -16,6 +16,8 @@ class TimerecordingEmployeeModel
private $overtime_timestamp;
private $bpahours;
private $startdate;
private $enddate;
private $bmd_active;
private $birthday;
public static $employeetypesbmd = array('1' => '1000', '2' => '1200', '3' => '1400');

View File

@@ -411,6 +411,7 @@ class TimerecordingReportController extends mfBaseController
$overtime_now = $employee[0]->overtime_now;
$auto_workinghours = $employee[0]->auto_workinghours;
$startdate = $employee[0]->startdate;
$bpahours = $employee[0]->bpahours;
}
$workinghours = TimerecordingEmployeeWorkingHourModel::search(['user_id' => $user_id]);
$holidays = TimerecordingHolidayModel::getAll();
@@ -775,6 +776,8 @@ class TimerecordingReportController extends mfBaseController
$json['time']['plushours'] = sprintf('%02dh:%02dm', floor($plusHours / 3600), floor($plusHours / 60 % 60));
$json['time']['plushours_now'] = $plusHours_now;
$json['time']['plushours_noworder'] = $plusHours_noworder;
$json['time']['bpahours'] = sprintf('%02dh:%02dm', floor($bpahours / 3600), floor($bpahours / 60 % 60));
$json['time']['overtime_now'] = sprintf('%02dh:%02dm', floor($overtime_now / 3600), floor($overtime_now / 60 % 60));
$json['time']['overtime_noworder'] = $overtime_now;
$json['time']['homeoffice'] = $homeofficesum;