fix billing process

This commit is contained in:
Dennis Eichhorn 2023-04-08 04:36:26 +02:00
parent 14974812ba
commit f5ba564d30
2 changed files with 25 additions and 19 deletions

View File

@ -8,9 +8,11 @@ assignees: ''
--- ---
# Bug Description # Bug Description
A clear and concise description of what the bug is. A clear and concise description of what the bug is.
# How to Reproduce # How to Reproduce
Steps to reproduce the behavior: Steps to reproduce the behavior:
1. Go to '...' 1. Go to '...'
@ -19,16 +21,20 @@ Steps to reproduce the behavior:
4. See error 4. See error
# Expected Behavior # Expected Behavior
A clear and concise description of what you expected to happen. A clear and concise description of what you expected to happen.
# Screenshots # Screenshots
If applicable, add screenshots to help explain your problem. If applicable, add screenshots to help explain your problem.
# System Information # System Information
- System: [e.g. PC or iPhone11, ...]
- OS: [e.g. iOS] - System: [e.g. PC or iPhone11, ...]
- Browser [e.g. chrome, safari] - OS: [e.g. iOS]
- KarakaVersion [e.g. 22] - Browser [e.g. chrome, safari]
- KarakaVersion [e.g. 22]
# Additional Information # Additional Information
Add any other context about the problem here. Add any other context about the problem here.

View File

@ -108,7 +108,7 @@ final class ApiController extends Controller
private function validateEmployeeFromAccountCreate(RequestAbstract $request) : array private function validateEmployeeFromAccountCreate(RequestAbstract $request) : array
{ {
$val = []; $val = [];
if (($val['profiles'] = empty($request->getData('profiles')))) { if (($val['profiles'] = !$request->hasData('profiles'))) {
return $val; return $val;
} }
@ -177,7 +177,7 @@ final class ApiController extends Controller
private function validateEmployeeNewCreate(RequestAbstract $request) : array private function validateEmployeeNewCreate(RequestAbstract $request) : array
{ {
$val = []; $val = [];
if (($val['name1'] = empty($request->getData('name1')))) { if (($val['name1'] = !$request->hasData('name1'))) {
return $val; return $val;
} }
@ -248,11 +248,11 @@ final class ApiController extends Controller
private function validateEmployeeHistoryCreate(RequestAbstract $request) : array private function validateEmployeeHistoryCreate(RequestAbstract $request) : array
{ {
$val = []; $val = [];
if (($val['employee'] = empty($request->getData('employee'))) if (($val['employee'] = !$request->hasData('employee'))
|| ($val['start'] = empty($request->getData('start'))) || ($val['start'] = !$request->hasData('start'))
|| ($val['unit'] = empty($request->getData('unit'))) || ($val['unit'] = !$request->hasData('unit'))
|| ($val['department'] = empty($request->getData('department'))) || ($val['department'] = !$request->hasData('department'))
|| ($val['position'] = empty($request->getData('position'))) || ($val['position'] = !$request->hasData('position'))
) { ) {
return $val; return $val;
} }
@ -320,10 +320,10 @@ final class ApiController extends Controller
private function validateEmployeeWorkHistoryCreate(RequestAbstract $request) : array private function validateEmployeeWorkHistoryCreate(RequestAbstract $request) : array
{ {
$val = []; $val = [];
if (($val['employee'] = empty($request->getData('employee'))) if (($val['employee'] = !$request->hasData('employee'))
|| ($val['start'] = empty($request->getData('start'))) || ($val['start'] = !$request->hasData('start'))
|| ($val['title'] = empty($request->getData('title'))) || ($val['title'] = !$request->hasData('title'))
|| ($val['name'] = empty($request->getData('name'))) || ($val['name'] = !$request->hasData('name'))
) { ) {
return $val; return $val;
} }
@ -396,10 +396,10 @@ final class ApiController extends Controller
private function validateEmployeeEducationHistoryCreate(RequestAbstract $request) : array private function validateEmployeeEducationHistoryCreate(RequestAbstract $request) : array
{ {
$val = []; $val = [];
if (($val['employee'] = empty($request->getData('employee'))) if (($val['employee'] = !$request->hasData('employee'))
|| ($val['start'] = empty($request->getData('start'))) || ($val['start'] = !$request->hasData('start'))
|| ($val['title'] = empty($request->getData('title'))) || ($val['title'] = !$request->hasData('title'))
|| ($val['name'] = empty($request->getData('name'))) || ($val['name'] = !$request->hasData('name'))
) { ) {
return $val; return $val;
} }