christianfutterlieb / backend_roles Goto Github PK
View Code? Open in Web Editor NEWLicense: GNU General Public License v2.0
License: GNU General Public License v2.0
Hi,
I just stumbled upon this extension and I really like the idea behind it. Keeping backend usergroups synchronized via dev/stage and prod is a real pain. I just wanted to share my ideas/ complaints about the current usage and usability. Please correct me, if I am just using it "the wrong way" or I didn't get "your" idea behind it.
If I map a backend role to a backend usergroup, than normally that usergroup cannot be configured anymore through the backend ui - unless you disable the checkbox/ switch in the main extension configuration/ settings of the extension.
Wouldn't it be nicer to have one YAML (or PHP) file for each role <-> usergroup mapping instead of one big file?
Something like ./config/backend-roles/<identifier>.yaml
or ./config/backend-roles/<usergroup-uid>.yaml
(latter would allow sync without an additional identifier, but would be less "readable")?! So something similar to the sites configuration backend module.
Then the extension could be used to write/ update the usergroup configuration to this file directly and not only serve the current configuration as download. That would allow to adjust the backend usergroup configuration in the same way as it's done right now in general via backend ui. So an integrator could do the work of configuring the backend usergroups and then simply export all usergoup configurations to their respective file.
These files could then be used to synchronize the settings with staging and production systems. So the CLI command also would only need to check, whether a matching file is available or not.
That above mentioned checkbox/ switch then could be enabled on production and/ or staging sites. But even if not, so that a manual override of usergroup settings in production/ staging environments would still be allowed, I don't see any problems here. Sure any future deployment which would trigger the synchronization of roles <-> usegroups would overwrite this former manual override via backend ui. But that should be covered by the development team to update missing access rights in the role yaml files via local development environment and than push that to VCS for the next release.
Any thoughts?
After installing the extension, I get this error:
Symfony\Component\DependencyInjection\Exception\RuntimeException
Cannot autowire service "AawTeam\BackendRoles\Command\SynchronizeCommand": argument "$name" of method "__construct()" is type-hinted "string", you should configure its value explicitly.
I use TYPO3 11.5.30 and PHP 8.1.21
Add a new functionality to calculate the sync status of a be_groups
record.
The sync status can be one of:
Status | Description |
---|---|
not-synced |
The be_groups record has no role definition |
out-of-sync |
The be_groups record does not have the same definitions as its assigned role |
sync-ok |
The be_groups record has the same definitions as its assigned role |
The status is made visible as iconOverlay of the be_groups icon. Note: integrate with existing overlays (hidden, starttime, endtime, ?). If it does not integrate well enough (say: interferes too much with the existing TYPO3 icon/overlays), it will just displayed it in the overview list of the Backend Module
in /var/www/html/vendor/typo3/cms-core/Classes/Utility/ArrayUtility.php line 182
in /var/www/html/vendor/typo3/cms-core/Classes/Utility/ArrayUtility.php line 145
in /var/www/html/vendor/christianfutterlieb/backend_roles/Classes/Role/Definition/Formatter.php line 237
at AawTeam\BackendRoles\Role\Definition\Formatter->formatFromDbToArray(array('uid' => 1, 'pid' => 0, 'tstamp' => 1571402400, 'title' => 'redakteur', 'non_exclude_fields' => 'tt_address:hidden,tt_address:module_sys_dmail_html,tt_address:module_sys_dmail_category,tt_address:title,pages:description,pages:media,pages:hidden,pages:keywords,pages:shortcut_mode,pages:tx_realurl_pathsegment,pages:starttime,pages:endtime,pages:subtitle,pages:urltype,pages:doktype,pages:url,tx_powermail_domain_model_answers:sys_language_uid,tx_powermail_domain_model_answers:l10n_parent,tx_commerce_article_prices:uid_article,tx_commerce_article_prices:price_gross,tx_commerce_articles:prices,tx_commerce_articles:title,tx_commerce_articles:l18n_parent,tx_twwcpressreview_domain_model_article:files,tx_twwcpressreview_domain_model_article:date,tx_twwcpressreview_domain_model_article:hidden,tx_twwcpressreview_domain_model_article:text,tx_twwcpressreview_domain_model_article:sys_language_uid,tx_twwcpressreview_domain_model_article:starttime,tx_twwcpressreview_domain_model_article:endtime,tx_twwcpressreview_domain_model_article:title,tx_twwcpressreview_domain_model_article:l10n_parent,tx_seminars_attendances:account_number,tx_seminars_attendances:account_owner,tx_seminars_attendances:attendees_names,tx_seminars_attendances:additional_persons,tx_seminars_attendances:address,tx_seminars_attendances:background_knowledge,tx_seminars_attendances:bank_code,tx_seminars_attendances:city,tx_seminars_attendances:company,tx_seminars_attendances:country,tx_seminars_attendances:currency,tx_seminars_attendances:datepaid,tx_seminars_attendances:email,tx_seminars_attendances:hidden,tx_seminars_attendances:registration_queue,tx_seminars_attendances:method_of_payment,tx_seminars_attendances:name,tx_seminars_attendances:seats,tx_seminars_attendances:twwc_seminar_payment_information,tx_seminars_attendances:price,tx_seminars_attendances:telephone,tx_seminars_attendances:total_price,tx_twwcgallery_domain_model_category:hidden,tx_twwcgallery_domain_model_category:sys_language_uid,tx_twwcgallery_domain_model_category:title,tx_twwcgallery_domain_model_category:l10n_parent,sys_category:hidden,sys_category:sys_language_uid,sys_category:l10n_parent,tx_twwcimagedownloader_domain_model_container:files,tx_twwcimagedownloader_domain_model_container:hidden,tx_twwcimagedownloader_domain_model_container:sys_language_uid,tx_twwcimagedownloader_domain_model_container:starttime,tx_twwcimagedownloader_domain_model_container:endtime,tx_twwcimagedownloader_domain_model_container:l10n_parent,sys_dmail:renderedsize,sys_dmail:issent,sys_dmail:scheduled,tx_powermail_domain_model_fields:own_marker_select,tx_powermail_domain_model_fields:marker,tx_powermail_domain_model_fields:hidden,tx_powermail_domain_model_fields:auto_marker,tx_powermail_domain_model_fields:sys_language_uid,tx_powermail_domain_model_fields:mandatory,tx_powermail_domain_model_fields:sender_email,tx_powermail_domain_model_fields:sender_name,tx_powermail_domain_model_fields:l10n_parent,tx_powermail_domain_model_fields:validation,tx_powermail_domain_model_fields:validation_configuration,tx_twwcimagedownloader_domain_model_file:file,tx_twwcimagedownloader_domain_model_file:hidden,tx_twwcimagedownloader_domain_model_file:sys_language_uid,tx_twwcimagedownloader_domain_model_file:thumbnail,tx_twwcimagedownloader_domain_model_file:title,tx_twwcimagedownloader_domain_model_file:l10n_parent,tx_twwcgallery_domain_model_file:categories,tx_twwcgallery_domain_model_file:hidden,tx_twwcgallery_domain_model_file:sys_language_uid,tx_twwcgallery_domain_model_file:starttime,tx_twwcgallery_domain_model_file:endtime,tx_twwcgallery_domain_model_file:l10n_parent,sys_file_metadata:title,sys_file_reference:description,sys_file_reference:alternative,sys_file_reference:link,sys_file_reference:title,tx_powermail_domain_model_forms:hidden,tx_powermail_domain_model_forms:sys_language_uid,tx_powermail_domain_model_forms:starttime,tx_powermail_domain_model_forms:endtime,tx_powermail_domain_model_forms:l10n_parent,tx_twwcgastro_domain_model_gastro:address,tx_twwcgastro_domain_model_gastro:categories,tx_twwcgastro_domain_model_gastro:hidden,tx_twwcgastro_domain_model_gastro:image,tx_twwcgastro_domain_model_gastro:logo,tx_twwcgastro_domain_model_gastro:room_reservation,tx_twwcgastro_domain_model_gastro:rooms,tx_twwcgastro_domain_model_gastro:slogen,tx_twwcgastro_domain_model_gastro:reservation,tx_twwcgastro_domain_model_gastro:title,tx_twwcgastro_domain_model_gastro:type,tx_twwcgastro_domain_model_gastro:website,tx_powermail_domain_model_mails:answers,tx_powermail_domain_model_mails:marketing_browser_language,tx_powermail_domain_model_mails:crdate,tx_powermail_domain_model_mails:body,tx_powermail_domain_model_mails:hidden,tx_powermail_domain_model_mails:sys_language_uid,tx_powermail_domain_model_mails:subject,tx_powermail_domain_model_mails:marketing_page_funnel,tx_powermail_domain_model_mails:receiver_mail,tx_powermail_domain_model_mails:marketing_referer_domain,tx_powermail_domain_model_mails:marketing_referer,tx_powermail_domain_model_mails:form,tx_powermail_domain_model_mails:sender_mail,tx_powermail_domain_model_mails:sender_name,tx_powermail_domain_model_mails:user_agent,tx_powermail_domain_model_mails:spam_factor,tx_powermail_domain_model_mails:starttime,tx_powermail_domain_model_mails:endtime,tx_powermail_domain_model_mails:time,tx_powermail_domain_model_mails:uid,tx_powermail_domain_model_mails:marketing_mobile_device,tx_powermail_domain_model_mails:marketing_country,tx_powermail_domain_model_mails:marketing_frontend_language,tx_twwcgooglemap_domain_model_marker:hidden,tx_twwcgooglemap_domain_model_marker:image,tx_twwcgooglemap_domain_model_marker:lat,tx_twwcgooglemap_domain_model_marker:lon,tx_twwcgooglemap_domain_model_marker:website,tx_twwcmeal_domain_model_meal:hidden,tx_twwcmeal_domain_model_meal:sys_language_uid,tx_twwcmeal_domain_model_meal:price,tx_twwcmeal_domain_model_meal:l10n_parent,tt_news:archivedate,tt_news:author,tt_news:imagecaption,tt_news:category,tt_news:datetime,tt_news:news_files,tt_news:hidden,tt_news:image,tt_news:sys_language_uid,tt_news:short,tt_news:l18n_parent,tt_news_cat:parent_category,tx_seminars_organizers:email_footer,pages:backend_layout_next_level,pages:backend_layout,pages:tx_twwcpages_class,pages:description,pages:tx_realurl_exclude,pages:media,pages:nav_hide,pages:hidden,pages:keywords,pages:layout,pages:l18n_cfg,pages:tx_realurl_pathoverride,pages:shortcut_mode,pages:tx_realurl_pathsegment,pages:starttime,pages:endtime,pages:subtitle,pages:target,pages:doktype,tt_content:spaceAfter,tt_content:altText,tt_content:spaceBefore,tt_content:table_border,tt_content:image_zoom,tt_content:colPos,tt_content:tx_gridelements_children,tt_content:tx_fed_fcefile,tt_content:section_frame,tt_content:image_frames,tt_content:tx_gridelements_container,tt_content:tx_gridelements_columns,tt_content:tx_gridelements_backend_layout,tt_content:imageheight,tt_content:hidden,tt_content:sectionIndex,tt_content:sys_language_uid,tt_content:image_link,tt_content:starttime,tt_content:endtime,tt_content:subheader,tt_content:titleText,tt_content:l18n_parent,tt_content:header_layout,tt_content:imagewidth,tt_content:pi_flexform;powermail_pi1;receiver;settings.flexform.receiver.body,tt_content:pi_flexform;powermail_pi1;sender;settings.flexform.sender.body,tt_content:pi_flexform;powermail_pi1;receiver;settings.flexform.receiver.email,tt_content:pi_flexform;powermail_pi1;receiver;settings.flexform.receiver.name,tt_content:pi_flexform;powermail_pi1;sender;settings.flexform.sender.email,tt_content:pi_flexform;powermail_pi1;sender;settings.flexform.sender.name,tt_content:pi_flexform;powermail_pi1;receiver;settings.flexform.receiver.subject,tt_content:pi_flexform;powermail_pi1;sender;settings.flexform.sender.subject,tt_content:pi_flexform;powermail_pi1;thx;settings.flexform.thx.body,tx_powermail_domain_model_pages:sys_language_uid,tx_powermail_domain_model_pages:l10n_parent,tx_commerce_products:images,tx_commerce_products:sys_language_uid,tx_commerce_products:l18n_parent,tx_seminars_seminars:allows_multiple_registrations,tx_seminars_seminars:categories,tx_seminars_seminars:hidden,tx_seminars_seminars:image,tx_seminars_seminars:attendees_max,tx_seminars_seminars:attendees_min,tx_seminars_seminars:needs_registration,tx_seminars_seminars:price_regular,tx_seminars_seminars:price_special,tx_seminars_seminars:starttime,tx_seminars_seminars:endtime,tx_seminars_seminars:subtitle,tx_seminars_seminars:teaser,tx_commerce_supplier:city,tx_commerce_supplier:email,tx_commerce_supplier:phone,tx_commerce_supplier:street,tx_commerce_supplier:title,tx_commerce_supplier:zip,tx_twwcmeal_domain_model_category:hidden,tx_twwcmeal_domain_model_category:sys_language_uid,tx_twwcmeal_domain_model_category:starttime,tx_twwcmeal_domain_model_category:endtime,tx_twwcmeal_domain_model_category:l10n_parent,fe_users:address,fe_users:city,fe_users:tx_commerce_tt_address_id,fe_users:tx_commerce_orders,fe_users:tx_commerce_user_state_id,fe_users:country,fe_users:twwc_seminar_refno,fe_users:email,fe_users:twwc_seminar_age,fe_users:image,fe_users:last_name,fe_users:middle_name,fe_users:name,fe_users:telephone,fe_users:tx_extbase_type,fe_users:twwc_seminar_seats,fe_users:twwc_commerce_theme,fe_users:title', 'explicit_allowdeny' => 'CONCAT(explicit_allowdeny
,`,tt_content:CType:textmedia', 'allowed_languages' => '', 'custom_options' => '', 'db_mountpoints' => '1,1673,79,610,1575,695,431,525,1427,976,865,1100,1355,2219,780,2960,3511,5442,66,53,3120,3113,3347,3786,4040,4159,4245,4322,4321,4492,4493,4652,4937,5782,3309', 'pagetypes_select' => '1,4,3,254', 'tables_select' => 'pages,sys_category,sys_file,sys_file_collection,sys_file_metadata,sys_file_reference,sys_file_storage,fe_users,pages_language_overlay,tt_content,tx_seminars_seminars,tx_seminars_attendances,tx_twwcpressreview_domain_model_article,tx_twwcmeal_domain_model_category,tx_twwcmeal_domain_model_meal,tx_twwcimagedownloader_domain_model_container,tx_twwcimagedownloader_domain_model_file,tx_commerce_supplier,tx_powermail_domain_model_answers,tx_powermail_domain_model_fields,tx_powermail_domain_model_forms,tx_powermail_domain_model_mails,tx_powermail_domain_model_pages,sys_dmail,sys_dmail_category,sys_dmail_group,tt_address,tt_news,tt_news_cat,tx_twwcgooglemap_domain_model_marker,tx_twwcgallery_domain_model_file,tx_twwcgallery_domain_model_category,tt_address_group', 'tables_modify' => 'pages,sys_category,sys_file,sys_file_collection,sys_file_metadata,sys_file_reference,sys_file_storage,fe_users,tt_content,tx_seminars_seminars,tx_seminars_attendances,tx_seminars_sites,tx_seminars_organizers,tx_seminars_categories,tx_twwcpressreview_domain_model_article,tx_twwcmeal_domain_model_category,tx_twwcmeal_domain_model_meal,tx_twwcimagedownloader_domain_model_container,tx_twwcimagedownloader_domain_model_file,tx_twwcgastro_domain_model_gastro,tx_commerce_article_prices,tx_commerce_articles,tx_commerce_attribute_values,tx_commerce_attributes,tx_commerce_categories,tx_commerce_products,tx_commerce_supplier,tx_powermail_domain_model_fields,tx_powermail_domain_model_forms,tx_powermail_domain_model_mails,tx_powermail_domain_model_pages,sys_dmail,sys_dmail_category,sys_dmail_group,tt_address,tt_news,tt_news_cat,tx_twwcgooglemap_domain_model_marker,tx_twwcgallery_domain_model_file,tx_twwcgallery_domain_model_category,tt_address_group', 'crdate' => 1342083451, 'groupMods' => 'web,web_layout,web_list,web_txseminarsM2,web_txttnewsM1,web_powermail,media_management,txcommerceM1_category,user,user_setup,txdirectmailM1,txdirectmailM1_txdirectmailM2,txdirectmailM1_txdirectmailM3,txdirectmailM1_txdirectmailM4,txdirectmailM1_txdirectmailM5', 'file_mountpoints' => '1', 'hidden' => 0, 'description' => '', 'deleted' => 0, 'TSconfig' => 'admPanel{ enable.edit = 0 module.edit.forceNoPopup = 0 module.edit.forceDisplayIcons = 0 module.edit.forceDisplayFieldIcons = 0 hide = 1 } options{ clearCache.pages = 1 clearCache.realurl = 1 clearCache.all = 1 saveDocNew.pages = 1 saveDocNew = 1 RTEkeyList( formatblock,table,bold,unorderedlist,copy,cut,paste,undo,redo,chMode, link,textstylelabel, textstyle, blockstylelabel, blockstyle, insertcharacter, removeformat,toggleborders,tableproperties, tablerestyle, rowproperties, rowinsertabove, rowinsertunder, rowdelete, rowsplit, columnproperties, columninsertbefore, columninsertafter, columndelete, columnsplit, cellproperties, cellinsertbefore, cellinsertafter, celldelete, cellsplit, cellmerge ) } mod.web_list { clickTitleMode = edit alternateBgColors = 1 } ', 'subgroup' => '2', 'workspace_perms' => 1, 'file_permissions' => 'readFolder,writeFolder,addFolder,renameFolder,moveFolder,deleteFolder,readFile,writeFile,addFile,renameFile,moveFile,copyFile,unzipFile,deleteFile,replaceFile', 'category_perms' => '', 'mfa_providers' => null, 'availableWidgets' => null, 'tx_backendroles_role_identifier' => ''))
in /var/www/html/vendor/christianfutterlieb/backend_roles/Classes/Role/Definition/Formatter.php line 197
at AawTeam\BackendRoles\Role\Definition\Formatter->formatFromDbToArray(array('uid' => 15, 'pid' => 0, 'tstamp' => 1459859158, 'title' => 'centro', 'non_exclude_fields' => null, 'explicit_allowdeny' => null, 'allowed_languages' => '', 'custom_options' => null, 'db_mountpoints' => '2793', 'pagetypes_select' => '', 'tables_select' => null, 'tables_modify' => null, 'crdate' => 1355824118, 'groupMods' => null, 'file_mountpoints' => '', 'hidden' => 0, 'description' => '', 'deleted' => 0, 'TSconfig' => '', 'subgroup' => '6', 'workspace_perms' => 0, 'file_permissions' => 'readFolder,writeFolder,addFolder,renameFolder,moveFolder,deleteFolder,readFile,writeFile,addFile,renameFile,moveFile,copyFile,unzipFile,deleteFile,replaceFile', 'category_perms' => '', 'mfa_providers' => null, 'availableWidgets' => null, 'tx_backendroles_role_identifier' => ''))
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.