@(field: play.api.data.Field,
  args: Map[Symbol, Any],
  dateService: uk.gov.dvla.vehicles.presentation.common.services.DateService,
  showTodaysDateButton: Boolean = false,
  showTodaysDateButtonId: Option[String] = None,
  hintText: Option[String] = None)(implicit handler: views.html.helper.FieldConstructor, lang: Lang)

@import uk.gov.dvla.vehicles.presentation.common.views
@import uk.gov.dvla.vehicles.presentation.common.mappings.Date.TodaysDateId
@import views.html.widgets.dates.valtechDate
@import views.html.widgets.dateConstraintRequired
@import scala.language.postfixOps

@dateConstraintRequired(field, args) <!-- datePlaceholder -->

<script src="/assets/javascripts/autofill-todays-date.js" type="text/javascript"></script>
<div class="todays-date js-only">
    <button id="@TodaysDateId" type="button" class="button" onclick="AutoFillTodaysDate(@{dateService.today.day},
            @{dateService.today.month}, @{dateService.today.year}, '@{field.id}', '@{field.id}_day', '@{field.id}_month',
            '@{field.id}_year')">@Messages("use_todays_date.label")</button>
</div>

@valtechDate(field, "", hintText)

@(field: play.api.data.Field,
  args: Map[Symbol, Any],
  dateService: uk.gov.dvla.vehicles.presentation.common.services.DateService,
  showTodaysDateButton: Boolean = true,
  showTodaysDateButtonId: Option[String] = None,
  hintText: Option[String] = None)(implicit handler: views.html.helper.FieldConstructor, lang: Lang)

@import uk.gov.dvla.vehicles.presentation.common.views
@import uk.gov.dvla.vehicles.presentation.common.mappings.Date.TodaysDateId
@import views.html.widgets.dates.valtechDate
@import views.html.widgets.dateConstraintRequired
@import scala.language.postfixOps

@dateConstraintRequired(field, args) <!-- datePlaceholder -->

<script src="/assets/javascripts/autofill-todays-date.js" type="text/javascript"></script>
<div class="todays-date js-only">

    @if( showTodaysDateButton) {
    <button id="@TodaysDateId" type="button" class="button" onclick="AutoFillTodaysDate(@{dateService.today.day},
            @{dateService.today.month}, @{dateService.today.year}, '@{field.id}', '@{field.id}_day', '@{field.id}_month',
            '@{field.id}_year')">@Messages("use_todays_date.label")</button>
    }
</div>

@valtechDate(field, "", hintText)

Fix bug in today's date component
US2363: Fix bug in today's date component
