mirror of
https://github.com/Karaka-Management/oms-Admin.git
synced 2026-02-15 20:18:40 +00:00
Automated formatting changes
This commit is contained in:
parent
6a6824f12e
commit
7876697de2
|
|
@ -315,7 +315,7 @@ final class ApiController extends Controller
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
$account = AccountMapper::get()->where('id', (int) $request->getData('user'))->execute();
|
$account = AccountMapper::get()->where('id', (int) $request->getData('user'))->execute();
|
||||||
$account->generatePassword($pass = StringRng::generateString(10, 14, '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ!@#$%^&*()_-+=/\\{}<>?'));
|
$account->generatePassword($pass = StringRng::generateString(10, 14, '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ!@#$%^&*()_-+=/\\{}<>?'));
|
||||||
|
|
||||||
AccountMapper::update()->execute($account);
|
AccountMapper::update()->execute($account);
|
||||||
|
|
|
||||||
|
|
@ -33,20 +33,20 @@ final class AccountPermissionMapper extends DataMapperFactory
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
public const COLUMNS = [
|
public const COLUMNS = [
|
||||||
'account_permission_id' => ['name' => 'account_permission_id', 'type' => 'int', 'internal' => 'id'],
|
'account_permission_id' => ['name' => 'account_permission_id', 'type' => 'int', 'internal' => 'id'],
|
||||||
'account_permission_account' => ['name' => 'account_permission_account', 'type' => 'int', 'internal' => 'account'],
|
'account_permission_account' => ['name' => 'account_permission_account', 'type' => 'int', 'internal' => 'account'],
|
||||||
'account_permission_unit' => ['name' => 'account_permission_unit', 'type' => 'int', 'internal' => 'unit'],
|
'account_permission_unit' => ['name' => 'account_permission_unit', 'type' => 'int', 'internal' => 'unit'],
|
||||||
'account_permission_app' => ['name' => 'account_permission_app', 'type' => 'string', 'internal' => 'app'],
|
'account_permission_app' => ['name' => 'account_permission_app', 'type' => 'string', 'internal' => 'app'],
|
||||||
'account_permission_module' => ['name' => 'account_permission_module', 'type' => 'string', 'internal' => 'module'],
|
'account_permission_module' => ['name' => 'account_permission_module', 'type' => 'string', 'internal' => 'module'],
|
||||||
'account_permission_from' => ['name' => 'account_permission_from', 'type' => 'string', 'internal' => 'from'],
|
'account_permission_from' => ['name' => 'account_permission_from', 'type' => 'string', 'internal' => 'from'],
|
||||||
'account_permission_category' => ['name' => 'account_permission_category', 'type' => 'int', 'internal' => 'category'],
|
'account_permission_category' => ['name' => 'account_permission_category', 'type' => 'int', 'internal' => 'category'],
|
||||||
'account_permission_element' => ['name' => 'account_permission_element', 'type' => 'int', 'internal' => 'element'],
|
'account_permission_element' => ['name' => 'account_permission_element', 'type' => 'int', 'internal' => 'element'],
|
||||||
'account_permission_component' => ['name' => 'account_permission_component', 'type' => 'int', 'internal' => 'component'],
|
'account_permission_component' => ['name' => 'account_permission_component', 'type' => 'int', 'internal' => 'component'],
|
||||||
'account_permission_hasread' => ['name' => 'account_permission_hasread', 'type' => 'bool', 'internal' => 'hasRead'],
|
'account_permission_hasread' => ['name' => 'account_permission_hasread', 'type' => 'bool', 'internal' => 'hasRead'],
|
||||||
'account_permission_hascreate' => ['name' => 'account_permission_hascreate', 'type' => 'bool', 'internal' => 'hasCreate'],
|
'account_permission_hascreate' => ['name' => 'account_permission_hascreate', 'type' => 'bool', 'internal' => 'hasCreate'],
|
||||||
'account_permission_hasmodify' => ['name' => 'account_permission_hasmodify', 'type' => 'bool', 'internal' => 'hasCreate'],
|
'account_permission_hasmodify' => ['name' => 'account_permission_hasmodify', 'type' => 'bool', 'internal' => 'hasCreate'],
|
||||||
'account_permission_hasdelete' => ['name' => 'account_permission_hasdelete', 'type' => 'bool', 'internal' => 'hasDelete'],
|
'account_permission_hasdelete' => ['name' => 'account_permission_hasdelete', 'type' => 'bool', 'internal' => 'hasDelete'],
|
||||||
'account_permission_haspermission' => ['name' => 'account_permission_haspermission', 'type' => 'bool', 'internal' => 'hasPermission'],
|
'account_permission_haspermission' => ['name' => 'account_permission_haspermission', 'type' => 'bool', 'internal' => 'hasPermission'],
|
||||||
];
|
];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
|
|
@ -33,20 +33,20 @@ final class GroupPermissionMapper extends DataMapperFactory
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
public const COLUMNS = [
|
public const COLUMNS = [
|
||||||
'group_permission_id' => ['name' => 'group_permission_id', 'type' => 'int', 'internal' => 'id'],
|
'group_permission_id' => ['name' => 'group_permission_id', 'type' => 'int', 'internal' => 'id'],
|
||||||
'group_permission_group' => ['name' => 'group_permission_group', 'type' => 'int', 'internal' => 'group'],
|
'group_permission_group' => ['name' => 'group_permission_group', 'type' => 'int', 'internal' => 'group'],
|
||||||
'group_permission_unit' => ['name' => 'group_permission_unit', 'type' => 'int', 'internal' => 'unit'],
|
'group_permission_unit' => ['name' => 'group_permission_unit', 'type' => 'int', 'internal' => 'unit'],
|
||||||
'group_permission_app' => ['name' => 'group_permission_app', 'type' => 'string', 'internal' => 'app'],
|
'group_permission_app' => ['name' => 'group_permission_app', 'type' => 'string', 'internal' => 'app'],
|
||||||
'group_permission_module' => ['name' => 'group_permission_module', 'type' => 'string', 'internal' => 'module'],
|
'group_permission_module' => ['name' => 'group_permission_module', 'type' => 'string', 'internal' => 'module'],
|
||||||
'group_permission_from' => ['name' => 'group_permission_from', 'type' => 'string', 'internal' => 'from'],
|
'group_permission_from' => ['name' => 'group_permission_from', 'type' => 'string', 'internal' => 'from'],
|
||||||
'group_permission_category' => ['name' => 'group_permission_category', 'type' => 'int', 'internal' => 'category'],
|
'group_permission_category' => ['name' => 'group_permission_category', 'type' => 'int', 'internal' => 'category'],
|
||||||
'group_permission_element' => ['name' => 'group_permission_element', 'type' => 'int', 'internal' => 'element'],
|
'group_permission_element' => ['name' => 'group_permission_element', 'type' => 'int', 'internal' => 'element'],
|
||||||
'group_permission_component' => ['name' => 'group_permission_component', 'type' => 'int', 'internal' => 'component'],
|
'group_permission_component' => ['name' => 'group_permission_component', 'type' => 'int', 'internal' => 'component'],
|
||||||
'group_permission_hasread' => ['name' => 'group_permission_hasread', 'type' => 'bool', 'internal' => 'hasRead'],
|
'group_permission_hasread' => ['name' => 'group_permission_hasread', 'type' => 'bool', 'internal' => 'hasRead'],
|
||||||
'group_permission_hascreate' => ['name' => 'group_permission_hascreate', 'type' => 'bool', 'internal' => 'hasCreate'],
|
'group_permission_hascreate' => ['name' => 'group_permission_hascreate', 'type' => 'bool', 'internal' => 'hasCreate'],
|
||||||
'group_permission_hasmodify' => ['name' => 'group_permission_hasmodify', 'type' => 'bool', 'internal' => 'hasCreate'],
|
'group_permission_hasmodify' => ['name' => 'group_permission_hasmodify', 'type' => 'bool', 'internal' => 'hasCreate'],
|
||||||
'group_permission_hasdelete' => ['name' => 'group_permission_hasdelete', 'type' => 'bool', 'internal' => 'hasDelete'],
|
'group_permission_hasdelete' => ['name' => 'group_permission_hasdelete', 'type' => 'bool', 'internal' => 'hasDelete'],
|
||||||
'group_permission_haspermission' => ['name' => 'group_permission_haspermission', 'type' => 'bool', 'internal' => 'hasPermission'],
|
'group_permission_haspermission' => ['name' => 'group_permission_haspermission', 'type' => 'bool', 'internal' => 'hasPermission'],
|
||||||
];
|
];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
|
|
@ -100,19 +100,19 @@ final class LocalizationMapper extends DataMapperFactory
|
||||||
'mapper' => CountryMapper::class,
|
'mapper' => CountryMapper::class,
|
||||||
'external' => 'l11n_country',
|
'external' => 'l11n_country',
|
||||||
'by' => 'code2',
|
'by' => 'code2',
|
||||||
'column' => 'code2'
|
'column' => 'code2',
|
||||||
],
|
],
|
||||||
'language' => [
|
'language' => [
|
||||||
'mapper' => LanguageMapper::class,
|
'mapper' => LanguageMapper::class,
|
||||||
'external' => 'l11n_language',
|
'external' => 'l11n_language',
|
||||||
'by' => 'code2',
|
'by' => 'code2',
|
||||||
'column' => 'code2'
|
'column' => 'code2',
|
||||||
],
|
],
|
||||||
'currency' => [
|
'currency' => [
|
||||||
'mapper' => CurrencyMapper::class,
|
'mapper' => CurrencyMapper::class,
|
||||||
'external' => 'l11n_currency',
|
'external' => 'l11n_currency',
|
||||||
'by' => 'code',
|
'by' => 'code',
|
||||||
'column' => 'code'
|
'column' => 'code',
|
||||||
],
|
],
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -115,7 +115,6 @@ final class PermissionQueryBuilder
|
||||||
*/
|
*/
|
||||||
public function groups(array $groups) : self
|
public function groups(array $groups) : self
|
||||||
{
|
{
|
||||||
|
|
||||||
$this->groups = $groups;
|
$this->groups = $groups;
|
||||||
|
|
||||||
return $this;
|
return $this;
|
||||||
|
|
@ -204,7 +203,6 @@ final class PermissionQueryBuilder
|
||||||
/**
|
/**
|
||||||
* Set permission flags
|
* Set permission flags
|
||||||
*
|
*
|
||||||
*
|
|
||||||
* @param int $permission Permission flags
|
* @param int $permission Permission flags
|
||||||
*
|
*
|
||||||
* @return self
|
* @return self
|
||||||
|
|
|
||||||
|
|
@ -177,7 +177,7 @@ return ['Admin' => [
|
||||||
'Website' => 'Internet side',
|
'Website' => 'Internet side',
|
||||||
'Weight' => 'Vægt',
|
'Weight' => 'Vægt',
|
||||||
'Zip' => 'Zip.',
|
'Zip' => 'Zip.',
|
||||||
'i:LoginRetries' => 'Mængden af tilladte retries (-1 = ubegrænset)',
|
'i:LoginRetries' => "Mængden af \u{200b}\u{200b}tilladte retries (-1 = ubegrænset)",
|
||||||
'i:PasswordChangeInterval' => 'Interval, hvor passager skal ændres (-1 = aldrig)',
|
'i:PasswordChangeInterval' => 'Interval, hvor passager skal ændres (-1 = aldrig)',
|
||||||
'i:PasswordHistory' => 'Ny adgangskode skal være forskellig fra de sidste N-adgangskoder',
|
'i:PasswordHistory' => 'Ny adgangskode skal være forskellig fra de sidste N-adgangskoder',
|
||||||
'i:PasswordRegex' => 'Adgangskode krav til brugere',
|
'i:PasswordRegex' => 'Adgangskode krav til brugere',
|
||||||
|
|
|
||||||
|
|
@ -12,13 +12,12 @@
|
||||||
*/
|
*/
|
||||||
declare(strict_types=1);
|
declare(strict_types=1);
|
||||||
|
|
||||||
use phpOMS\Message\Http\HttpHeader;
|
|
||||||
use phpOMS\Router\RouteVerb;
|
use phpOMS\Router\RouteVerb;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var \phpOMS\Views\View $this
|
* @var \phpOMS\Views\View $this
|
||||||
*/
|
*/
|
||||||
$hooks = $this->getData('hooks') ?? [];
|
$hooks = $this->getData('hooks') ?? [];
|
||||||
$module = $this->getData('module') ?? '';
|
$module = $this->getData('module') ?? '';
|
||||||
|
|
||||||
echo $this->getData('nav')->render();
|
echo $this->getData('nav')->render();
|
||||||
|
|
@ -94,8 +93,8 @@ echo $this->getData('nav')->render();
|
||||||
++$c;
|
++$c;
|
||||||
?>
|
?>
|
||||||
<tr>
|
<tr>
|
||||||
<td><label class="checkbox" for="iActive-<?= $c ?>">
|
<td><label class="checkbox" for="iActive-<?= $c; ?>">
|
||||||
<input id="iActive-<?= $c ?>" type="checkbox" name="active_route" value="<?= $this->printHtml($uri); ?>"<?= true ? ' checked' : ''; ?>>
|
<input id="iActive-<?= $c; ?>" type="checkbox" name="active_route" value="<?= $this->printHtml($uri); ?>"<?= true ? ' checked' : ''; ?>>
|
||||||
<span class="checkmark"></span>
|
<span class="checkmark"></span>
|
||||||
</label>
|
</label>
|
||||||
<td><?= $app; ?>
|
<td><?= $app; ?>
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,6 @@
|
||||||
*/
|
*/
|
||||||
declare(strict_types=1);
|
declare(strict_types=1);
|
||||||
|
|
||||||
use phpOMS\Message\Http\HttpHeader;
|
|
||||||
use phpOMS\Router\RouteVerb;
|
use phpOMS\Router\RouteVerb;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -94,8 +93,8 @@ echo $this->getData('nav')->render();
|
||||||
++$c;
|
++$c;
|
||||||
?>
|
?>
|
||||||
<tr>
|
<tr>
|
||||||
<td><label class="checkbox" for="iActive-<?= $c ?>">
|
<td><label class="checkbox" for="iActive-<?= $c; ?>">
|
||||||
<input id="iActive-<?= $c ?>" type="checkbox" name="active_route" value="<?= $this->printHtml($uri); ?>"<?= true ? ' checked' : ''; ?>>
|
<input id="iActive-<?= $c; ?>" type="checkbox" name="active_route" value="<?= $this->printHtml($uri); ?>"<?= true ? ' checked' : ''; ?>>
|
||||||
<span class="checkmark"></span>
|
<span class="checkmark"></span>
|
||||||
</label>
|
</label>
|
||||||
<td><?= $app; ?>
|
<td><?= $app; ?>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user