{"action":"created","issue":{"url":"https://api.github.com/repos/OrchardCMS/OrchardCore/issues/4963","repository_url":"https://api.github.com/repos/OrchardCMS/OrchardCore","labels_url":"https://api.github.com/repos/OrchardCMS/OrchardCore/issues/4963/labels{/name}","comments_url":"https://api.github.com/repos/OrchardCMS/OrchardCore/issues/4963/comments","events_url":"https://api.github.com/repos/OrchardCMS/OrchardCore/issues/4963/events","html_url":"https://github.com/OrchardCMS/OrchardCore/issues/4963","id":533722576,"node_id":"MDU6SXNzdWU1MzM3MjI1NzY=","number":4963,"title":"UpdateContentItem Global Method Doesn't Alter DisplayText","user":{"login":"jeffolmstead","id":1848585,"node_id":"MDQ6VXNlcjE4NDg1ODU=","avatar_url":"https://avatars0.githubusercontent.com/u/1848585?v=4","gravatar_id":"","url":"https://api.github.com/users/jeffolmstead","html_url":"https://github.com/jeffolmstead","followers_url":"https://api.github.com/users/jeffolmstead/followers","following_url":"https://api.github.com/users/jeffolmstead/following{/other_user}","gists_url":"https://api.github.com/users/jeffolmstead/gists{/gist_id}","starred_url":"https://api.github.com/users/jeffolmstead/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jeffolmstead/subscriptions","organizations_url":"https://api.github.com/users/jeffolmstead/orgs","repos_url":"https://api.github.com/users/jeffolmstead/repos","events_url":"https://api.github.com/users/jeffolmstead/events{/privacy}","received_events_url":"https://api.github.com/users/jeffolmstead/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2019-12-06T03:23:14Z","updated_at":"2019-12-06T18:33:17Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"The change on #4631 made it so data was persisted to the database which is great. Using this, I have a Script that I use in a workflow which \r\n\r\n1. Calls a query to get a content item\r\n2. Sets the properties to update the TitlePart\r\n3. Calls updateContentItem method\r\n\r\nEverything works BUT the DisplayText is not updated as a result. Without setting the \"DisplayText\", whenever the content is next edited Title will show whatever is in the \"DisplayText\" and not in the Title part stored in \"Content\". However, the user on the front end will see rendered out what is in the TitlePart (assuming they get it from \"Content\" via Liquid). Here is my script that retrieves the content item, updates it, but fails to update the DisplayText:\r\n\r\n```\r\nvar parameters = {};\r\nparameters[\"contentItemId\"] = \"4ep0v7jh3naxz2s3acps6pq3df\";\r\nvar contentItems = executeQuery('GetContentItem', parameters);\r\nvar contentItem = contentItems[0];\r\nvar properties = {\r\n  \"TitlePart\": {\r\n    \"Title\": \"I changed the Title\"\r\n  }\r\n};\r\nupdateContentItem(contentItem, properties);\r\n```"},"comment":{"url":"https://api.github.com/repos/OrchardCMS/OrchardCore/issues/comments/562687472","html_url":"https://github.com/OrchardCMS/OrchardCore/issues/4963#issuecomment-562687472","issue_url":"https://api.github.com/repos/OrchardCMS/OrchardCore/issues/4963","id":562687472,"node_id":"MDEyOklzc3VlQ29tbWVudDU2MjY4NzQ3Mg==","user":{"login":"jeffolmstead","id":1848585,"node_id":"MDQ6VXNlcjE4NDg1ODU=","avatar_url":"https://avatars0.githubusercontent.com/u/1848585?v=4","gravatar_id":"","url":"https://api.github.com/users/jeffolmstead","html_url":"https://github.com/jeffolmstead","followers_url":"https://api.github.com/users/jeffolmstead/followers","following_url":"https://api.github.com/users/jeffolmstead/following{/other_user}","gists_url":"https://api.github.com/users/jeffolmstead/gists{/gist_id}","starred_url":"https://api.github.com/users/jeffolmstead/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jeffolmstead/subscriptions","organizations_url":"https://api.github.com/users/jeffolmstead/orgs","repos_url":"https://api.github.com/users/jeffolmstead/repos","events_url":"https://api.github.com/users/jeffolmstead/events{/privacy}","received_events_url":"https://api.github.com/users/jeffolmstead/received_events","type":"User","site_admin":false},"created_at":"2019-12-06T18:33:17Z","updated_at":"2019-12-06T18:33:17Z","author_association":"CONTRIBUTOR","body":"@Skrypt I didn't know TitlePart had been deprecated / removed. The issue is that \"DIsplayText\" does not appear in the \"Content\" (at least that I know of). Only \"TitlePart\" shows up so that is the only property you are able to update on the merge. Does that make sense? We would need to grant access to editing other fields on the ContentItem instead of just Content if you want the user to be in control. "}}
{"actor":{"display_login":"jeffolmstead"}}