mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-30 21:40:43 +02:00
[ticket/11103] Create user loader class, update for DIC
Create a very basic user loader class to handle querying/storing user data in a centralized location. Use DIC collection service for notification types/methods. Cleanup unused dependencies. Fix some other issues. PHPBB3-11103
This commit is contained in:
@@ -1,12 +1,24 @@
|
||||
services:
|
||||
notification.type_collection:
|
||||
class: phpbb_di_service_collection
|
||||
arguments:
|
||||
- @service_container
|
||||
tags:
|
||||
- { name: service_collection, tag: notification.type }
|
||||
|
||||
notification.method_collection:
|
||||
class: phpbb_di_service_collection
|
||||
arguments:
|
||||
- @service_container
|
||||
tags:
|
||||
- { name: service_collection, tag: notification.method }
|
||||
|
||||
notification.type.approve_post:
|
||||
class: phpbb_notification_type_approve_post
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -20,11 +32,9 @@ services:
|
||||
notification.type.approve_topic:
|
||||
class: phpbb_notification_type_approve_topic
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -38,11 +48,9 @@ services:
|
||||
notification.type.bookmark:
|
||||
class: phpbb_notification_type_bookmark
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -56,11 +64,9 @@ services:
|
||||
notification.type.disapprove_post:
|
||||
class: phpbb_notification_type_disapprove_post
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -74,11 +80,9 @@ services:
|
||||
notification.type.disapprove_topic:
|
||||
class: phpbb_notification_type_disapprove_topic
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -92,11 +96,9 @@ services:
|
||||
notification.type.pm:
|
||||
class: phpbb_notification_type_pm
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -110,11 +112,9 @@ services:
|
||||
notification.type.post:
|
||||
class: phpbb_notification_type_post
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -128,11 +128,9 @@ services:
|
||||
notification.type.post_in_queue:
|
||||
class: phpbb_notification_type_post_in_queue
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -146,11 +144,9 @@ services:
|
||||
notification.type.quote:
|
||||
class: phpbb_notification_type_quote
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -164,11 +160,9 @@ services:
|
||||
notification.type.report_pm:
|
||||
class: phpbb_notification_type_report_pm
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -182,11 +176,9 @@ services:
|
||||
notification.type.report_pm_closed:
|
||||
class: phpbb_notification_type_report_pm_closed
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -200,11 +192,9 @@ services:
|
||||
notification.type.report_post:
|
||||
class: phpbb_notification_type_report_post
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -218,11 +208,9 @@ services:
|
||||
notification.type.report_post_closed:
|
||||
class: phpbb_notification_type_report_post
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -236,11 +224,9 @@ services:
|
||||
notification.type.topic:
|
||||
class: phpbb_notification_type_topic
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -254,11 +240,9 @@ services:
|
||||
notification.type.topic_in_queue:
|
||||
class: phpbb_notification_type_topic_in_queue
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -272,11 +256,9 @@ services:
|
||||
notification.method.email:
|
||||
class: phpbb_notification_method_email
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
@@ -288,11 +270,9 @@ services:
|
||||
notification.method.jabber:
|
||||
class: phpbb_notification_method_jabber
|
||||
arguments:
|
||||
- @notification_manager
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
|
@@ -97,14 +97,12 @@ services:
|
||||
notification_manager:
|
||||
class: phpbb_notification_manager
|
||||
arguments:
|
||||
- @container
|
||||
- @notification.type_collection
|
||||
- @notification.method_collection
|
||||
- @service_container
|
||||
- @user_loader
|
||||
- @dbal.conn
|
||||
- @cache.driver
|
||||
- @template
|
||||
- @ext.manager
|
||||
- @user
|
||||
- @auth
|
||||
- @config
|
||||
- %core.root_path%
|
||||
- %core.php_ext%
|
||||
- %tables.notifications%
|
||||
@@ -151,3 +149,11 @@ services:
|
||||
|
||||
user:
|
||||
class: phpbb_user
|
||||
|
||||
user_loader:
|
||||
class: phpbb_user_loader
|
||||
arguments:
|
||||
- @dbal.conn
|
||||
- %core.root_path%
|
||||
- %core.php_ext%
|
||||
- %tables.users%
|
||||
|
@@ -3,3 +3,4 @@ parameters:
|
||||
tables.ext: %core.table_prefix%ext
|
||||
tables.notifications: %core.table_prefix%notifications
|
||||
tables.user_notifications: %core.table_prefix%user_notifications
|
||||
tables.users: %core.table_prefix%users
|
||||
|
Reference in New Issue
Block a user