U4-11250 - Refine names and availability support

Created by Stephan 18 Apr 2018, 16:46:53 Updated by Stephan 26 Apr 2018, 06:58:06

Is required for: U4-11173

Subtask of: U4-11106

Task U4-11128 has reached minimum viable product stage - moving remaining work to a new task, so that the first one can be merged and used asap.


Stephan 18 Apr 2018, 16:48:19

Copied from U4-11128:

Some questions remain open. See the fixme note in Can_SaveAndRead_Names(), for instance. Is there a dependency relation between InvariantNeutral and CultureNeutral? Should publishing values for a culture automatically publish the invariant values? Are we OK with the results of the test method? Etc.

What I still need to do:

  • test it all to ensure it works as intended
  • figure out variations questions mentioned above
  • implement a way to know when a culture was published
  • implement a way to know whether a culture is edited (draft != published)

Shannon Deminick 20 Apr 2018, 06:53:46

When this is complete, we will need to wire up the publish state of the Umbraco.Web.Models.ContentEditing.ContentVariation for the ContentItemDisplay

Shannon Deminick 20 Apr 2018, 06:54:36

And then we can proceed with this http://issues.umbraco.org/issue/U4-11173

Stephan 21 Apr 2018, 08:23:54

Happens in branch temp8-U4-11250 with PR https://github.com/umbraco/Umbraco-CMS/pull/2599

Do NOT merge the PR now! Work in progress!

Current state: moved all APIs from using integer languageId to string culture.

Stephan 24 Apr 2018, 14:53:12

Current state: implemented culture available / edited - see ContentServiceTests.Can_SaveRead_Variations() and VariationTests.ContentPublishVariations() for usage.

Now writing documentation, but moving the PR for review!

Stephan 24 Apr 2018, 15:45:25

@Shandem question: this PR does not change anything to the entity service - but I assume you would want the 'is culture edited' (and maybe 'is culture available') there too?

Robert Copilau 25 Apr 2018, 07:11:39

@zpqrtbnk, [this|http://issues.umbraco.org/issue/U4-11173] task requires at least "is culture edited" property otherwise, there is nothing to filter by when we only want to show languages that have pending changes in the publish dialog.

Stephan 25 Apr 2018, 07:25:25

we have content.IsCultureEdited("fr-FR-") thing indeed - is that ok?

Shannon Deminick 26 Apr 2018, 06:31:16

Code is reviewed, some minor questions asked on the PR, will chat to @zpqrtbnk today about DB structure to just understand what is going on. Ran the tests, they pass so i'm going to merge so this isn't holding anything up.

From here i'll need to merge this into my PR, refactor things to use string culture, fix unit tests, etc...

@robertcopilau For this task http://issues.umbraco.org/issue/U4-11173 , once this PR is merged, the code to do the model mapping for the ContentDisplay model and it's variants will need to be updated so that it will tag the correct published state for each variant. From there, you'll then be able to do the filtering.

Shannon Deminick 26 Apr 2018, 06:32:41

Have merged into temp8 branch.

Shannon Deminick 26 Apr 2018, 06:33:31

@zpqrtbnk is there anything we need to know about ensuring the DB migrations run against our existing DBs and or if we need to rebuild the content caches for this?

Stephan 26 Apr 2018, 06:58:06

have created appropriate migrations, so it should not be a problem unless I've made mistakes - new state-based migrations know where you are today, and will take you to the final state

content caches need to be rebuilt yes - oh, need to find a way to do it in migrations

Priority: Normal

Type: Task

State: Fixed


Difficulty: Normal


Backwards Compatible: True

Fix Submitted:

Affected versions:

Due in version:

Sprint: Sprint 83

Story Points: 3