-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
[4.2] Inject the db into the MVC layer #37095
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 4 commits
Commits
Show all changes
25 commits
Select commit
Hold shift + click to select a range
03f9a54
Inject the db into the MVC layer
laoneo f25b5e0
Set db only on model
laoneo 6c925fc
cs
laoneo 575abf4
Merge branch '4.2-dev' into j4/db/inject
laoneo 69ebb28
Remove interface from factory
laoneo 67cdd83
Merge branch '4.2-dev' into j4/db/inject
laoneo 461b3f0
Merge branch '4.2-dev' into j4/db/inject
laoneo 26a0a37
Use the framework package instead
laoneo 98f51a1
convert app model
laoneo bb7381c
revert
laoneo 66c5deb
correct exception
laoneo b324c76
stabilize
laoneo 7d0a0b2
ensure db
laoneo d2770d0
fallback to container
laoneo d7d6a21
deprecate notices
laoneo df29fd9
Merge branch '4.2-dev' into j4/db/inject
laoneo 2a9709b
Merge branch '4.2-dev' into j4/db/inject
laoneo 17fc1d5
Merge remote-tracking branch 'upstream/4.2-dev' into j4/db/inject
laoneo f42728c
conflict
laoneo d489b24
Merge branch '4.2-dev' into j4/db/inject
laoneo b385e58
Merge branch '4.2-dev' into j4/db/inject
laoneo 5be349e
use the not deprecated function
laoneo 9ca07e5
Add unit test
laoneo 4a66003
typo
laoneo fb71497
Merge branch '4.2-dev' into j4/db/inject
roland-d File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,32 @@ | ||
| <?php | ||
| /** | ||
| * Joomla! Content Management System | ||
| * | ||
| * @copyright (C) 2022 Open Source Matters, Inc. <https://www.joomla.org> | ||
| * @license GNU General Public License version 2 or later; see LICENSE.txt | ||
| */ | ||
|
|
||
| namespace Joomla\CMS\MVC\Model; | ||
|
|
||
| \defined('_JEXEC') or die; | ||
|
|
||
| use Joomla\Database\DatabaseInterface; | ||
|
|
||
| /** | ||
| * Interface to be implemented by classes depending on a database. | ||
| * | ||
| * @since __DEPLOY_VERSION__ | ||
| */ | ||
| interface DatabaseAwareInterface | ||
| { | ||
| /** | ||
| * Set the database to use. | ||
| * | ||
| * @param DatabaseInterface $db The database to use. | ||
| * | ||
| * @return void | ||
| * | ||
| * @since __DEPLOY_VERSION__ | ||
| */ | ||
| public function setDbo(DatabaseInterface $db = null): void; | ||
| } | ||
laoneo marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.