Answers.Body: <p>CiviCRM Custom fields configured as Data Type = Date all get added to Webform build tab as:</p>
  <pre><code>  civicrm_1_contact_1_cg22_custom_59:
      '#type': date
      '#data_type': Date
  </code></pre>
  <p>Ah you're then retyping that to a Date List field in the UI?</p>
  <p>Yep - I see the issue. This will require a code fix. This particular field mapping just doesn't exist yet.</p>
  <p>I do like the idea of supporting Date List type of fields and would be happy to welcome a code fix/PR or alternatively you can also sponsor this feature and either myself or one of my team can work on it.</p>
  <p>AD-hoc: ah it looks like one of our Partner/clients hit the same issue -&gt; Fuzion has submitted a PR -&gt; <a href="https://github.com/colemanw/webform_civicrm/pull/635" rel="nofollow noreferrer">https://github.com/colemanw/webform_civicrm/pull/635</a> - if you can help test/review this then we can get it merged quickly.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-10-27T23:39:43.493Z
Answers.LastActivityDate: 2021-10-29T16:14:37.690Z
Answers.LastEditDate: 2021-10-29T16:14:37.690Z
Answers.UserDisplayName: KarinG - Semper IT
Body: <p>I'm using CIVICRM Webform on Drupal 9,  I'm trying to capture some date fields using Date List and or Date/Time, instead of the regular Date field, because of some strange issues on older browsers, (probably because of HTML5 incompatibility)</p>
  <p>The month and the day are captured correctly, but the year is registering 0400, instead of the correct year.</p>
  <p>I've tried it for Birth Date and Custom Date Fields, and both are showing 0400 as the year.  The format is dd-mm-yyyy</p>
  <p>Any assistance would be appreciated.</p>
  <p>P.S. The webform result is capturing the correct year, but in CIVICRM it is not.</p>
  
Tags: <webform-civicrm><dates>
Title: Webform CIVICRM Date List and Date/Time doesn't capture year correctly
ThreadText: # Webform CIVICRM Date List and Date/Time doesn't capture year correctly
  
  (Asked by: username_0 on 2021-10-26)
  
  I'm using CIVICRM Webform on Drupal 9, I'm trying to capture some date fields using Date List and or Date/Time, instead of the regular Date field, because of some strange issues on older browsers, (probably because of HTML5 incompatibility)
  
  The month and the day are captured correctly, but the year is registering 0400, instead of the correct year.
  
  I've tried it for Birth Date and Custom Date Fields, and both are showing 0400 as the year. The format is dd-mm-yyyy
  
  Any assistance would be appreciated.
  
  P.S. The webform result is capturing the correct year, but in CIVICRM it is not.
  
  **Tags:** webform-civicrm, dates
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2021-10-27. Score: 2
  
  CiviCRM Custom fields configured as Data Type = Date all get added to Webform build tab as:
  
  ```
    civicrm_1_contact_1_cg22_custom_59:
      '#type': date
      '#data_type': Date
  
  ```
  
  Ah you're then retyping that to a Date List field in the UI?
  
  Yep - I see the issue. This will require a code fix. This particular field mapping just doesn't exist yet.
  
  I do like the idea of supporting Date List type of fields and would be happy to welcome a code fix/PR or alternatively you can also sponsor this feature and either myself or one of my team can work on it.
  
  AD-hoc: ah it looks like one of our Partner/clients hit the same issue -> Fuzion has submitted a PR -> <https://github.com/colemanw/webform_civicrm/pull/635> - if you can help test/review this then we can get it merged quickly.
  
  
  ---
  
  