Skip to content

[ENHANCEMENT] structure tagging #260

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 4 commits into from
Sep 29, 2014
Merged

Conversation

dantleech
Copy link
Contributor

This PR allows structure tags to be defined in the structure template
file. These tags can subsequently be used by other bundles.

Tasks:

  • test coverage
  • Reviewed by Dan
  • gather feedback for my changes
  • submit changes to the documentation

Informations:

Q A
Tests pass? yes
Fixed tickets none - helps with the search PR
BC Breaks yes - get/setIndexName on structure has been removed
Doc

@dantleech dantleech force-pushed the feature/enhanced-structure-tagging branch from b8f66ee to 32ad6b8 Compare September 18, 2014 13:44
/**
* @expectedException \InvalidArgumentException
*/
public function testGetUndefinedStructureStructureTag()
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

StructureStructure

@danrot
Copy link
Contributor

danrot commented Sep 19, 2014

Why haven't you fixed the stuff you have mentioned in your comments? :-)

@dantleech
Copy link
Contributor Author

sorry, this is part of a larger part of work. its still WIP

@dantleech dantleech changed the title Feature/enhanced structure tagging [WIP] Feature/enhanced structure tagging Sep 19, 2014
@danrot danrot changed the title [WIP] Feature/enhanced structure tagging [WIP][FEATURE] enhanced structure tagging Sep 19, 2014
@dantleech dantleech force-pushed the feature/enhanced-structure-tagging branch from 32ad6b8 to fbc9f03 Compare September 22, 2014 07:49
@dantleech dantleech changed the title [WIP][FEATURE] enhanced structure tagging Enhanced structure tagging Sep 22, 2014
*/
public function setIndexName($indexName)
public function addStructureTag(StructureTag $structureTag)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So we are adding support for adding tags to structures.

@dantleech dantleech force-pushed the feature/enhanced-structure-tagging branch from fbc9f03 to 7d1d996 Compare September 22, 2014 11:52
@@ -667,7 +667,7 @@ private function changeState(
$oldState = $node->getPropertyValue($statePropertyName);

if ($oldState === $state) {
// do nothing
$structure->setNodeState($state);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The node state was not being set when there was no change, so media was not being indexed on updates.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

media was not updated? why that?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the media bundle integrates with the search. it uses the PRE_SAVE event and the node state is always TEST unless this line is here.

@dantleech dantleech force-pushed the feature/enhanced-structure-tagging branch from 7d1d996 to a48f847 Compare September 22, 2014 11:59
This PR allows structure tags to be defined in the structure template
file. These tags can subsequently be used by other bundles.

It also removes the unique priority constraint on tags and adds an
"addTag" method to the Property class.
@dantleech dantleech force-pushed the feature/enhanced-structure-tagging branch from a48f847 to 01c6eaf Compare September 22, 2014 12:01
@danrot danrot changed the title Enhanced structure tagging [ENHANCEMENT] structure tagging Sep 24, 2014
@@ -0,0 +1,40 @@
<?php

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

missing header

Daniel Rotter added 3 commits September 29, 2014 11:44
…/enhanced-structure-tagging

Conflicts:
	src/Sulu/Bundle/CoreBundle/Resources/config/content.xml
@danrot danrot merged commit 24e0266 into develop Sep 29, 2014
@danrot danrot deleted the feature/enhanced-structure-tagging branch September 29, 2014 14:00
chirimoya added a commit that referenced this pull request Oct 17, 2014
Fixed template loading with empty blocks
chirimoya added a commit that referenced this pull request Oct 31, 2014
Fixed template loading with empty blocks
alexander-schranz pushed a commit to alexander-schranz/sulu that referenced this pull request Nov 14, 2024
alexander-schranz pushed a commit to alexander-schranz/sulu that referenced this pull request Nov 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants