Rock
Rock copied to clipboard
Attributes don't save when creating a new Metric
A Picture Is worth a Thousand Words
Description
When creating a brand new Metric, attribute values do not save. The Metric gets saved with all the information except for its attributes that were thought to be assigned. A person has to edit the now existing metric to add the attribute values.
Steps to Reproduce
- Ensure that the Metric Entity Type has attributes. It does not matter what kind.
- Go to create a new Metric.
- Add an attribute value to the Metric's attributes.
- Click "Save". (The Attribute Value should not have saved)
- Click "Edit" to add the Attribute Value to the now existing Metric.
- Click "Save" to finally add the Attribute Value.
Expected behavior: Attribute values to be added to the new Metric on creation.
Actual behavior: The new Metric is created without any attribute values assigned.
Rock Version: [12.8, 13.6] Client Culture Setting: [en-US]
On further examination, it looks like the attribute value does save; however, it gets saved with EntityId = 0. So it saves to the database, but not to the Metric correctly. This was examined using the SQL Profiler.