Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
M2 content provisioning
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TechDivision Public
M2 content provisioning
Commits
0573fbca
Commit
0573fbca
authored
1 month ago
by
Eduarda Lentz Rodrigues da Silva
Browse files
Options
Downloads
Patches
Plain Diff
ZERO-162 Added new information to get data from database
parent
99a0c114
No related branches found
Branches containing commit
No related tags found
1 merge request
!46
ZERO-162-changes
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Model/Query/GetChangedBlockIdentifiers.php
+10
-1
10 additions, 1 deletion
Model/Query/GetChangedBlockIdentifiers.php
with
10 additions
and
1 deletion
Model/Query/GetChangedBlockIdentifiers.php
+
10
−
1
View file @
0573fbca
...
...
@@ -27,13 +27,21 @@ class GetChangedBlockIdentifiers
*/
private
GetBlockEntryByKey
$getBlockEntryByKey
;
/**
* @var GetCmsBlockByTitle
*/
private
GetCmsBlockByTitle
$getCmsBlockByTitle
;
/**
* @param GetBlockEntryByKey $getBlockEntryByKey
* @param GetCmsBlockByTitle $getCmsBlockByTitle
*/
public
function
__construct
(
GetBlockEntryByKey
$getBlockEntryByKey
,
GetCmsBlockByTitle
$getCmsBlockByTitle
)
{
$this
->
getBlockEntryByKey
=
$getBlockEntryByKey
;
$this
->
getCmsBlockByTitle
=
$getCmsBlockByTitle
;
}
/**
...
...
@@ -50,7 +58,8 @@ class GetChangedBlockIdentifiers
// Get Block content from code
$codeFileContent
=
$file
[
'content'
];
// Get Block content from database
$dbBlockContent
=
$this
->
getBlockEntryByKey
->
get
(
$file
[
'key'
])
->
getContent
();
$dbBlock
=
$this
->
getCmsBlockByTitle
->
execute
(
$file
[
'title'
]);
$dbBlockContent
=
$dbBlock
[
'content'
];
}
catch
(
LocalizedException
$e
)
{
return
'ERROR: '
.
$e
->
getMessage
();
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment