-
Notifications
You must be signed in to change notification settings - Fork 38
Open
Description
Checklist before I submit this issue report
I confirm that:
- I have tested this with the latest version available
- I have read documentation @ http://metamodels.readthedocs.org/en/ or http://metamodels.readthedocs.org/de/
- I have checked the Contao community forums for references https://community.contao.org/
- 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)
| Key | Value | Comments |
|---|---|---|
| PHP version: | 5.6 | |
| Contao version: | 3.5.27 | |
| MetaModels version: | core master (a15) | |
| Installation via composer: | yes | |
| Installed MetaModels packages: | bundle_all | |
| DCG version: | master (b39) |
Steps to reproduce
- create attribute Alias with allwaysSave
- create input mask with readonly
- create and save items
look at contao-community-alliance/dc-general#350
at the "first save" (create) we doesn´t create the alias - we create the alias with the "second save" (update)
the MetaModels.php call the method modelSaved if is isAttributeSet true
core/src/MetaModels/MetaModel.php
Line 1035 in 08b5022
| if ($objItem->isAttributeSet($objAttribute->getColName())) { |
but at Item.php
Line 245 in 08b5022
| return array_key_exists($strAttributeName, $this->arrData); |
we have different keys at array
$this->arrData between create e.g.
Array ( [name] => a8 [vorname] => b8 [published] => 1 [tstamp] => 1496848172 [id] => 10 )
and update e.g.
Array ( [id] => 10 [pid] => 0 [sorting] => 0 [tstamp] => 1496848200 [name] => a8 [vorname] => b8 [email] => [published] => 1 [abteilung] => [alias] => )
Metadata
Metadata
Assignees
Labels
bugA bug! A bug! Fast, squish it!A bug! A bug! Fast, squish it!