mirror of
https://github.com/Karaka-Management/oms-Attribute.git
synced 2026-02-16 01:18:40 +00:00
fix billing process
This commit is contained in:
parent
e52ac9f05c
commit
7dbdceded9
14
.github/user_bug_report.md
vendored
14
.github/user_bug_report.md
vendored
|
|
@ -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.
|
||||||
|
|
|
||||||
|
|
@ -111,9 +111,9 @@ final class ApiController extends Controller
|
||||||
private function validateAttributeCreate(RequestAbstract $request) : array
|
private function validateAttributeCreate(RequestAbstract $request) : array
|
||||||
{
|
{
|
||||||
$val = [];
|
$val = [];
|
||||||
if (($val['type'] = empty($request->getData('type')))
|
if (($val['type'] = !$request->hasData('type'))
|
||||||
|| ($val['value'] = (empty($request->getData('value')) && empty($request->getData('custom'))))
|
|| ($val['value'] = (!$request->hasData('value') && !$request->hasData('custom')))
|
||||||
|| ($val['ref'] = empty($request->getData('ref')))
|
|| ($val['ref'] = !$request->hasData('ref'))
|
||||||
) {
|
) {
|
||||||
return $val;
|
return $val;
|
||||||
}
|
}
|
||||||
|
|
@ -181,8 +181,8 @@ final class ApiController extends Controller
|
||||||
private function validateAttributeTypeL11nCreate(RequestAbstract $request) : array
|
private function validateAttributeTypeL11nCreate(RequestAbstract $request) : array
|
||||||
{
|
{
|
||||||
$val = [];
|
$val = [];
|
||||||
if (($val['title'] = empty($request->getData('title')))
|
if (($val['title'] = !$request->hasData('title'))
|
||||||
|| ($val['type'] = empty($request->getData('type')))
|
|| ($val['type'] = !$request->hasData('type'))
|
||||||
) {
|
) {
|
||||||
return $val;
|
return $val;
|
||||||
}
|
}
|
||||||
|
|
@ -252,8 +252,8 @@ final class ApiController extends Controller
|
||||||
private function validateAttributeTypeCreate(RequestAbstract $request) : array
|
private function validateAttributeTypeCreate(RequestAbstract $request) : array
|
||||||
{
|
{
|
||||||
$val = [];
|
$val = [];
|
||||||
if (($val['title'] = empty($request->getData('title')))
|
if (($val['title'] = !$request->hasData('title'))
|
||||||
|| ($val['name'] = empty($request->getData('name')))
|
|| ($val['name'] = !$request->hasData('name'))
|
||||||
) {
|
) {
|
||||||
return $val;
|
return $val;
|
||||||
}
|
}
|
||||||
|
|
@ -337,8 +337,8 @@ final class ApiController extends Controller
|
||||||
private function validateAttributeValueCreate(RequestAbstract $request) : array
|
private function validateAttributeValueCreate(RequestAbstract $request) : array
|
||||||
{
|
{
|
||||||
$val = [];
|
$val = [];
|
||||||
if (($val['type'] = empty($request->getData('type')))
|
if (($val['type'] = !$request->hasData('type'))
|
||||||
|| ($val['value'] = empty($request->getData('value')))
|
|| ($val['value'] = !$request->hasData('value'))
|
||||||
) {
|
) {
|
||||||
return $val;
|
return $val;
|
||||||
}
|
}
|
||||||
|
|
@ -406,8 +406,8 @@ final class ApiController extends Controller
|
||||||
private function validateAttributeValueL11nCreate(RequestAbstract $request) : array
|
private function validateAttributeValueL11nCreate(RequestAbstract $request) : array
|
||||||
{
|
{
|
||||||
$val = [];
|
$val = [];
|
||||||
if (($val['title'] = empty($request->getData('title')))
|
if (($val['title'] = !$request->hasData('title'))
|
||||||
|| ($val['value'] = empty($request->getData('value')))
|
|| ($val['value'] = !$request->hasData('value'))
|
||||||
) {
|
) {
|
||||||
return $val;
|
return $val;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -61,7 +61,7 @@ final class ControllerTest extends \PHPUnit\Framework\TestCase
|
||||||
|
|
||||||
$permission = new AccountPermission();
|
$permission = new AccountPermission();
|
||||||
$permission->setUnit(1);
|
$permission->setUnit(1);
|
||||||
$permission->setApp('backend');
|
$permission->setApp(2);
|
||||||
$permission->setPermission(
|
$permission->setPermission(
|
||||||
PermissionType::READ
|
PermissionType::READ
|
||||||
| PermissionType::CREATE
|
| PermissionType::CREATE
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user