Answers.Body: <p>This is due to the change made in this PR - <a href="https://github.com/civicrm/civicrm-core/pull/11998" rel="noreferrer">https://github.com/civicrm/civicrm-core/pull/11998</a>. </p>
  
  <p>I raised this on Mattermost some time ago. See <a href="https://chat.civicrm.org/civicrm/pl/d58c9nuowbfemeneizbe57cxqy" rel="noreferrer">https://chat.civicrm.org/civicrm/pl/d58c9nuowbfemeneizbe57cxqy</a>. It says -</p>
  
  <blockquote>
    <p>Seems default assignee is a required field on Case Type Form(as per this change). Was this intentional? I was unable to save <a href="https://dmaster.demo.civicrm.org/civicrm/a/#/caseType/1" rel="noreferrer">https://dmaster.demo.civicrm.org/civicrm/a/#/caseType/1</a> until I filled out default assignees for all the activities listed under standard timeline ‍♂️ </p>
  </blockquote>
  
  <p>But unfortunately haven't got any reply for the same.</p>
  
  <p>To fix this  -</p>
  
  <ul>
  <li>Remove the <code>required</code> word from <a href="https://github.com/civicrm/civicrm-core/pull/11998/files#diff-41433018ebe60fe2771f21569e4778c2R80" rel="noreferrer">this line of the PR</a> and the following element. You should be able to save case type without selecting any value in the default assignee.</li>
  </ul>
  
  <p>OR</p>
  
  <ul>
  <li>Add values to the default assignee for all the activities.</li>
  </ul>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-08-22T22:34:36.783Z
Answers.Text: can you explain why i didn't observe this on dmaster? was i trying the wrong steps
Answers.UserDisplayName: petednz - fuzion
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-08-24T07:27:57.890Z
Answers.Text: You can simply replicate this by navigating to https://dmaster.demo.civicrm.org/civicrm/a/#/caseType/1. Save button will be disabled until you select default assignees for all the activity types in `Standard . Timeline`.
Answers.UserDisplayName: jitendra - fuzion
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-08-22T08:45:50.337Z
Answers.LastActivityDate: 2018-08-22T08:45:50.337Z
Answers.UserDisplayName: jitendra - fuzion
Answers.Body: <p>I created the feature.</p>
  
  <p>How come the upgrader didn't run? Did something break? Do you have a specific error message available?</p>
  
  <p>I didn't set the main select as required, but it seems that since the options are missing, then the required field that is supposed to be hidden shows up and stops you from saving the case type.</p>
  
  <p>I'll create a new PR that will handle missing options for this field, but it would be good to understand why the options are not available in the first place.</p>
  
  <p>Please feel free to message me with any details you may have.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-09-18T12:14:35.517Z
Answers.Text: Is the intention that these are Required before one is able to Create a new Case Type - or edit one of the default Case Types? I don't remember a discussion about making such a change. If it is not intended that these are now required then can this get fixed. If the decision is these are to be Required then can you pls figure out what should be done to ensure that folk get clear instructions both in Documentation and via Alerts/Warnings on the screen to avoid frustrations?
Answers.UserDisplayName: petednz - fuzion
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-09-18T12:15:09.983Z
Answers.Text: commenting because I still observe this behaviour on dmaster
Answers.UserDisplayName: petednz - fuzion
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-09-18T12:20:19.797Z
Answers.Text: oh - now reading that you are not intending it to be required - hopefully you can get the PR done soon to fix this
Answers.UserDisplayName: petednz - fuzion
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-08-24T00:08:55.170Z
Answers.LastActivityDate: 2018-08-24T00:08:55.170Z
Answers.UserDisplayName: René Olivo
Answers.Body: <p><strong>Short answer</strong>: The problem affects new clean installs on 5.4/5.5 but shouldn't affect upgraded sites. To quickly fix a new site, you can run <a href="https://github.com/civicrm/cv" rel="nofollow noreferrer">cv</a> as follows:</p>
  
  <pre><code>cv ev 'CRM_Upgrade_Incremental_php_FiveFour::addActivityDefaultAssigneeOptions();'
  </code></pre>
  
  <p><strong>Long answer</strong>: As Jitendra pointed out, the change stems from <a href="https://github.com/civicrm/civicrm-core/pull/11998" rel="nofollow noreferrer">#11998</a>, which updated both the code/UI and the database. Of course, the PR went through some testing and passed. What gives? The testing focused on taking <em>an existing database</em> (perhaps a real site; perhaps just a local dev site) and <em>applying the change on top</em>. The PR worked because it defined an upgrade procedure for the database. However, in a <em>clean-install</em>, the database doesn't use the upgrade procedure. As a quick-fix, you can manually update the database. As longer term, we should issue a new version which automatically updates the database.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-09-19T19:24:01.320Z
Answers.LastActivityDate: 2018-09-19T19:24:01.320Z
Answers.UserDisplayName: Tim Otten
Body: <p>On fresh Install Civi 5.4, Core expect to have new option group called "Activity default assignee", but upgrade script not executed and not updated the option group table with "Activity default assignee" options.</p>
  
  <p>which cause null result in "Default Assignee" drop down on New case type and "Save" button has disabled because angular validation error.</p>
  
  <p><a href="https://i.sstatic.net/FuDRI.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/FuDRI.png" alt="enter image description here"></a></p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-08-21T19:16:02.367Z
Comments.Text: This didn't sound familiar so i compared to https://dmaster.demo.civicrm.org/civicrm/a/#/caseType/new and I do not see those fields. can you add more information or compare with demo to see what is different about your set up
Comments.UserDisplayName: petednz - fuzion
Tags: <civicase>
Title: CiviCRM 5.4, Unable to create case type (angular validation error)
ThreadText: # CiviCRM 5.4, Unable to create case type (angular validation error)
  
  (Asked by: username_0 on 2018-08-21)
  
  On fresh Install Civi 5.4, Core expect to have new option group called "Activity default assignee", but upgrade script not executed and not updated the option group table with "Activity default assignee" options.
  
  which cause null result in "Default Assignee" drop down on New case type and "Save" button has disabled because angular validation error.
  
  [![enter image description here](https://i.sstatic.net/FuDRI.png)](https://i.sstatic.net/FuDRI.png)
  
  **Tags:** civicase
  
  > **Comments:**
  > **username_1**: This didn't sound familiar so i compared to https://dmaster.demo.civicrm.org/civicrm/a/#/caseType/new and I do not see those fields. can you add more information or compare with demo to see what is different about your set up  
  
  ---
  
  ## 3 answers
  
  ### Answer by username_2 on 2018-08-22. Score: 5
  
  This is due to the change made in this PR - <https://github.com/civicrm/civicrm-core/pull/11998>.
  
  I raised this on Mattermost some time ago. See <https://chat.civicrm.org/civicrm/pl/d58c9nuowbfemeneizbe57cxqy>. It says -
  
  > Seems default assignee is a required field on Case Type Form(as per this change). Was this intentional? I was unable to save <https://dmaster.demo.civicrm.org/civicrm/a/#/caseType/1> until I filled out default assignees for all the activities listed under standard timeline ‍♂️
  
  But unfortunately haven't got any reply for the same.
  
  To fix this -
  
  * Remove the `required` word from [this line of the PR](https://github.com/civicrm/civicrm-core/pull/11998/files#diff-41433018ebe60fe2771f21569e4778c2R80) and the following element. You should be able to save case type without selecting any value in the default assignee.
  
  OR
  
  * Add values to the default assignee for all the activities.
  
  > **Comments:**
  > **username_1**: can you explain why i didn't observe this on dmaster? was i trying the wrong steps  
  > **username_2**: You can simply replicate this by navigating to https://dmaster.demo.civicrm.org/civicrm/a/#/caseType/1. Save button will be disabled until you select default assignees for all the activity types in `Standard . Timeline`.  
  
  ---
  
  ### Answer by username_3 on 2018-08-24. Score: 0
  
  I created the feature.
  
  How come the upgrader didn't run? Did something break? Do you have a specific error message available?
  
  I didn't set the main select as required, but it seems that since the options are missing, then the required field that is supposed to be hidden shows up and stops you from saving the case type.
  
  I'll create a new PR that will handle missing options for this field, but it would be good to understand why the options are not available in the first place.
  
  Please feel free to message me with any details you may have.
  
  > **Comments:**
  > **username_1**: Is the intention that these are Required before one is able to Create a new Case Type - or edit one of the default Case Types? I don't remember a discussion about making such a change. If it is not intended that these are now required then can this get fixed. If the decision is these are to be Required then can you pls figure out what should be done to ensure that folk get clear instructions both in Documentation and via Alerts/Warnings on the screen to avoid frustrations?  
  > **username_1**: commenting because I still observe this behaviour on dmaster  
  > **username_1**: oh - now reading that you are not intending it to be required - hopefully you can get the PR done soon to fix this  
  
  ---
  
  ### Answer by username_4 on 2018-09-19. Score: 0
  
  Short answer: The problem affects new clean installs on 5.4/5.5 but shouldn't affect upgraded sites. To quickly fix a new site, you can run cv as follows:
  cv ev 'CRM_Upgrade_Incremental_php_FiveFour::addActivityDefaultAssigneeOptions();'
  
  Long answer: As Jitendra pointed out, the change stems from #11998, which updated both the code/UI and the database. Of course, the PR went through some testing and passed. What gives? The testing focused on taking an existing database (perhaps a real site; perhaps just a local dev site) and applying the change on top. The PR worked because it defined an upgrade procedure for the database. However, in a clean-install, the database doesn't use the upgrade procedure. As a quick-fix, you can manually update the database. As longer term, we should issue a new version which automatically updates the database.
  
  
  ---
  
  