diff --git a/Admin/Routes/Web/Api.php b/Admin/Routes/Web/Api.php index 3ffbde0..f6ab449 100755 --- a/Admin/Routes/Web/Api.php +++ b/Admin/Routes/Web/Api.php @@ -24,6 +24,7 @@ return [ [ 'dest' => '\Modules\Profile\Controller\ApiController:apiProfileCreate', 'verb' => RouteVerb::PUT, + 'csrf' => true, 'permission' => [ 'module' => ApiController::NAME, 'type' => PermissionType::CREATE, @@ -36,6 +37,7 @@ return [ [ 'dest' => '\Modules\Admin\Controller\ApiController:apiSettingsAccountLocalizationSet', 'verb' => RouteVerb::SET, + 'csrf' => true, 'permission' => [ 'module' => AdminApiController::NAME, 'type' => PermissionType::MODIFY, @@ -47,6 +49,7 @@ return [ [ 'dest' => '\Modules\Admin\Controller\ApiController:apiSettingsAccountPasswordSet', 'verb' => RouteVerb::SET, + 'csrf' => true, 'permission' => [ 'module' => AdminApiController::NAME, 'type' => PermissionType::MODIFY, @@ -58,6 +61,7 @@ return [ [ 'dest' => '\Modules\Profile\Controller\ApiController:apiSettingsAccountImageSet', 'verb' => RouteVerb::SET, + 'csrf' => true, 'permission' => [ 'module' => ApiController::NAME, 'type' => PermissionType::MODIFY, diff --git a/Admin/Routes/Web/Backend.php b/Admin/Routes/Web/Backend.php index 003cd6b..0d3dd75 100755 --- a/Admin/Routes/Web/Backend.php +++ b/Admin/Routes/Web/Backend.php @@ -57,7 +57,7 @@ return [ 'verb' => RouteVerb::GET, 'permission' => [ 'module' => BackendController::NAME, - 'type' => PermissionType::READ, + 'type' => PermissionType::CREATE, 'state' => PermissionCategory::PROFILE, ], ], diff --git a/Theme/Backend/Components/AccountGroupSelector/base.tpl.php b/Theme/Backend/Components/AccountGroupSelector/base.tpl.php index 3cfcfe4..0f9b4f7 100755 --- a/Theme/Backend/Components/AccountGroupSelector/base.tpl.php +++ b/Theme/Backend/Components/AccountGroupSelector/base.tpl.php @@ -14,7 +14,7 @@ } ]' formaction="">book
- diff --git a/Theme/Backend/profile-list.tpl.php b/Theme/Backend/profile-list.tpl.php index 49611a4..dd78bab 100755 --- a/Theme/Backend/profile-list.tpl.php +++ b/Theme/Backend/profile-list.tpl.php @@ -74,10 +74,12 @@ $next = empty($accounts) ? '{/base}/profile/list' : '{/base}/profile/list?{?
+ diff --git a/Theme/Backend/profile-view.tpl.php b/Theme/Backend/profile-view.tpl.php index b495e9c..3289fa1 100644 --- a/Theme/Backend/profile-view.tpl.php +++ b/Theme/Backend/profile-view.tpl.php @@ -15,22 +15,12 @@ declare(strict_types=1); use Modules\Admin\Models\ContactType; use phpOMS\Localization\ISO3166NameEnum; use phpOMS\Localization\ISO3166TwoEnum; -use phpOMS\Localization\ISO4217Enum; -use phpOMS\Localization\ISO639Enum; -use phpOMS\Localization\ISO8601EnumArray; -use phpOMS\Localization\TimeZoneEnumArray; -use phpOMS\System\File\Local\Directory; use phpOMS\Uri\UriFactory; -use phpOMS\Utils\Converter\AreaType; -use phpOMS\Utils\Converter\LengthType; -use phpOMS\Utils\Converter\SpeedType; -use phpOMS\Utils\Converter\TemperatureType; -use phpOMS\Utils\Converter\VolumeType; -use phpOMS\Utils\Converter\WeightType; /** @var \phpOMS\Views\View $this */ /** @var \Modules\Profile\Models\Profile $profile */ $profile = $this->data['account']; +$account = $profile->account; /** @var \Modules\Media\Models\Media[] $media */ $media = $this->data['media'] ?? []; @@ -80,7 +70,7 @@ echo $this->data['nav']->render(); {"key": 2, "type": "dom.click", "selector": "#iProfileUpload"} ] }]'>getHtml('Edit', '0', '0'); ?> -
" method="post">render(); request->header->account === $profile->account->id) : - $countryCodes = ISO3166TwoEnum::getConstants(); - $countries = ISO3166NameEnum::getConstants(); - $timezones = TimeZoneEnumArray::getConstants(); - $timeformats = ISO8601EnumArray::getConstants(); - $languages = ISO639Enum::getConstants(); - $currencies = ISO4217Enum::getConstants(); - $l11nDefinitions = Directory::list(__DIR__ . '/../../../../phpOMS/Localization/Defaults/Definitions'); - - $weights = WeightType::getConstants(); - $speeds = SpeedType::getConstants(); - $areas = AreaType::getConstants(); - $lengths = LengthType::getConstants(); - $volumes = VolumeType::getConstants(); - $temperatures = TemperatureType::getConstants(); ?> request->uri->fragment === 'c-tab-2' ? ' checked' : ''; ?>>
-
-
-
- -
getHtml('Localization'); ?>
-
-
- -
-
-
-
-
-
- -
- - -
- -
- - -
- -
- - -
-
-
- - -
- -
-
- -
-
-
getHtml('Time'); ?>
-
-
- - -
- -
-

getHtml('Timeformat'); ?>

-
- -
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
-
-
-
- -
-
-
getHtml('Numeric'); ?>
-
-
- - -
- -
- - -
- -
-

getHtml('Numberformat'); ?>

-
- -
-
-
- - -
-
- -
-
- - -
-
-
-
-
-
- -
-
-
getHtml('Precision'); ?>
-
-
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
-
-
-
- -
-
-
getHtml('Weight'); ?>
-
-
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
-
-
-
- -
-
-
getHtml('Speed'); ?>
-
-
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
-
-
-
- -
-
-
getHtml('Length'); ?>
-
-
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
-
-
-
- -
-
-
getHtml('Area'); ?>
-
-
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
-
-
-
- -
-
-
getHtml('Volume'); ?>
-
-
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
-
-
-
-
+
request->uri->fragment === 'c-tab-3' ? ' checked' : ''; ?>> @@ -671,7 +166,7 @@ echo $this->data['nav']->render();
-
+
getHtml('Password'); ?>