core icon indicating copy to clipboard operation
core copied to clipboard

Property conditions broken when changing the tag alias

Open dmolineus opened this issue 5 years ago • 2 comments

Checklist before I submit this issue report

I confirm that:

  • [x] I have tested this with the latest version available
  • [x] I have read documentation @ http://metamodels.readthedocs.org/en/ or http://metamodels.readthedocs.org/de/
  • [x] I have checked the Contao community forums for references https://community.contao.org/
  • [x] I have checked existing issues for duplicates and found none @ https://github.com/MetaModels/core/issues?q=is%3Aissue

My environment is:

(Please fill in the actual values from your environment - check Contao Manager or use composer show)

Key Value Comments
PHP version: 7.2.10
Contao version: 4.9.3
MetaModels version: 2.2@dev
Installed MetaModels packages: core,attribute_tags,... Some more but not relevant
DCG version: 2.2@dev

Issue description

(Describe the problem you are having)

Steps to reproduce

  1. I have a tags attribute which uses the alias as alias field
  2. The tags field is also referenced as condition for tl_metamodel_dcasetting_condition of type conditionpropertycontainanyof
  3. I change the tag alias to id the property condition

Describe the behaviour of the application

Because of duplicate aliases I want to migrate to the id as alias field. If I change the tag alias to id the property conditions are broken because the serialized information of the property condition of type conditionpropertycontainanyof are not adjusted

Describe the expected behaviour of the application

  1. I have a tags attribute which uses the alias as alias field
  2. And I use the tags field as referenced field for property conditions of type conditionpropertycontainanyof.
  3. I expect that the property conditions still work / get autoadjusted when changing the property condition tag alias.

dmolineus avatar Jun 24 '20 15:06 dmolineus

Have we discussed in MM call ... Aliases should be unique anyway :D

zonky2 avatar Dec 01 '20 20:12 zonky2

see https://github.com/MetaModels/core/issues/904

zonky2 avatar May 25 '21 15:05 zonky2