diff --git a/app/forms/PropertyDetailsForms.scala b/app/forms/PropertyDetailsForms.scala index be859dd4..f6e69019 100644 --- a/app/forms/PropertyDetailsForms.scala +++ b/app/forms/PropertyDetailsForms.scala @@ -120,7 +120,7 @@ object PropertyDetailsForms { val propertyDetailsNewValuationForm: Form[PropertyDetailsNewValuation] = Form( mapping( - "revaluedValue" -> valueValidation.verifying(revaluedValueConstraint) + "revaluedValue" -> valueValidation.verifying(revaluedValueConstraint()) )(PropertyDetailsNewValuation.apply)(PropertyDetailsNewValuation.unapply) ) diff --git a/app/models/PropertyDetailsModels.scala b/app/models/PropertyDetailsModels.scala index eda43f03..1e4c49d8 100644 --- a/app/models/PropertyDetailsModels.scala +++ b/app/models/PropertyDetailsModels.scala @@ -22,8 +22,6 @@ import java.time.LocalDate import play.api.libs.functional.syntax._ import play.api.libs.json._ import play.api.libs.json.Reads._ -import play.api.libs.json.Writes._ -import uk.gov.hmrc.play.bootstrap.config.ServicesConfig sealed trait PeriodValidity diff --git a/app/utils/AtedUtils.scala b/app/utils/AtedUtils.scala index cd4a13b8..fdbcab18 100644 --- a/app/utils/AtedUtils.scala +++ b/app/utils/AtedUtils.scala @@ -17,11 +17,10 @@ package utils import config.ApplicationConfig -import models.{IsOwnedBefore2012, IsOwnedBefore2017, IsOwnedBefore2022, NotOwnedBeforePolicyYear, OwnedBeforePolicyYear, _} +import models.{IsOwnedBefore2012, IsOwnedBefore2017, IsOwnedBefore2022, NotOwnedBeforePolicyYear, _} import java.time.LocalDate import play.api.mvc.{AnyContent, Request} -import uk.gov.hmrc.play.bootstrap.config.ServicesConfig import utils.AtedConstants._ import scala.language.postfixOps diff --git a/app/views/propertyDetails/addressLookup.scala.html b/app/views/propertyDetails/addressLookup.scala.html index fb3198c5..cfee04de 100644 --- a/app/views/propertyDetails/addressLookup.scala.html +++ b/app/views/propertyDetails/addressLookup.scala.html @@ -71,7 +71,8 @@

@govukInput(Input( label = Label( content = Text(messages("ated.address-lookup.house-name")) - ) + ), + autocomplete = Some("address-line1") ).withFormField(searchForm("houseName") )) @@ -79,7 +80,8 @@

label = Label( content = Text(messages("ated.address-lookup.postcode")) ), - classes = "govuk-input--width-10" + classes = "govuk-input--width-10", + autocomplete = Some("postal-code") ).withFormField(searchForm("postcode") )) diff --git a/app/views/propertyDetails/propertyDetailsAddress.scala.html b/app/views/propertyDetails/propertyDetailsAddress.scala.html index f5bba90f..8916a912 100644 --- a/app/views/propertyDetails/propertyDetailsAddress.scala.html +++ b/app/views/propertyDetails/propertyDetailsAddress.scala.html @@ -88,34 +88,39 @@

@govukInput(Input( label = Label( content = Text(messages("ated.addressProperty.line_1")) - ) + ), + autocomplete = Some("address-line1") ).withFormField(propertyDetailsForm("line_1"))) @govukInput(Input( label = Label( content = Text(messages("ated.addressProperty.line_2")) - ) + ), + autocomplete = Some("address-line2") ).withFormField(propertyDetailsForm("line_2"))) @govukInput(Input( label = Label( content = Text(messages("ated.addressProperty.line_3")) ), - classes = "govuk-!-width-two-thirds" + classes = "govuk-!-width-two-thirds", + autocomplete = Some("address-line3") ).withFormField(propertyDetailsForm("line_3"))) @govukInput(Input( label = Label( content = Text(messages("ated.addressProperty.line_4")) ), - classes = "govuk-!-width-two-thirds" + classes = "govuk-!-width-two-thirds", + autocomplete = Some("address-level2") ).withFormField(propertyDetailsForm("line_4"))) @govukInput(Input( label = Label( content = Text(messages("ated.addressProperty.postcode")) ), - classes = "govuk-input--width-10" + classes = "govuk-input--width-10", + autocomplete = Some("postal-code") ).withFormField(propertyDetailsForm("postcode"))) @if(!fromConfirmAddressPage) { diff --git a/app/views/subcriptionData/correspondenceAddress.scala.html b/app/views/subcriptionData/correspondenceAddress.scala.html index c8756ccf..2d5590e6 100644 --- a/app/views/subcriptionData/correspondenceAddress.scala.html +++ b/app/views/subcriptionData/correspondenceAddress.scala.html @@ -70,10 +70,14 @@

@formHelper(action = controllers.subscriptionData.routes.CorrespondenceAddressController.submit) { @input(Input(inputType = "hidden").withFormField(correspondenceAddressForm("addressType"))) - @input(Input(label = Label(content = Text(messages("ated.addressLine1")))).withFormField(correspondenceAddressForm("addressLine1"))) - @input(Input(label = Label(content = Text(messages("ated.addressLine2")))).withFormField(correspondenceAddressForm("addressLine2"))) - @input(Input(label = Label(content = Text(messages("ated.addressLine3"))), classes = "govuk-!-width-two-thirds").withFormField(correspondenceAddressForm("addressLine3"))) - @input(Input(label = Label(content = Text(messages("ated.addressLine4"))), classes = "govuk-!-width-two-thirds").withFormField(correspondenceAddressForm("addressLine4"))) + @input(Input(label = Label(content = Text(messages("ated.addressLine1"))), + autocomplete = Some("address-line1")).withFormField(correspondenceAddressForm("addressLine1"))) + @input(Input(label = Label(content = Text(messages("ated.addressLine2"))), + autocomplete = Some("address-line2")).withFormField(correspondenceAddressForm("addressLine2"))) + @input(Input(label = Label(content = Text(messages("ated.addressLine3"))), + autocomplete = Some("address-line3"), classes = "govuk-!-width-two-thirds").withFormField(correspondenceAddressForm("addressLine3"))) + @input(Input(label = Label(content = Text(messages("ated.addressLine4"))), + autocomplete = Some("address-level2"), classes = "govuk-!-width-two-thirds").withFormField(correspondenceAddressForm("addressLine4"))) @select(Select( label = Label(content = Text(messages("ated.country"))), items = Seq(SelectItem(Some(""), "Select a country")) ++ listOfIsoCode.map { @@ -82,7 +86,8 @@

text = country) } ).withFormField(correspondenceAddressForm("countryCode"))) - @input(Input(label = Label(content = Text(messages("ated.postcode"))), classes = "govuk-input--width-10").withFormField(correspondenceAddressForm("postalCode"))) + @input(Input(label = Label(content = Text(messages("ated.postcode"))), + autocomplete = Some("postal-code"), classes = "govuk-input--width-10").withFormField(correspondenceAddressForm("postalCode"))) @button(Button(content = Text(messages("ated.save-changes")))) diff --git a/build.sbt b/build.sbt index 4f025bbf..be45b02b 100644 --- a/build.sbt +++ b/build.sbt @@ -10,7 +10,7 @@ import uk.gov.hmrc.versioning.SbtGitVersioning.autoImport.majorVersion val appName = "ated-frontend" ThisBuild / majorVersion := 3 -ThisBuild / scalaVersion := "2.13.14" +ThisBuild / scalaVersion := "2.13.15" lazy val appDependencies: Seq[ModuleID] = AppDependencies() lazy val plugins: Seq[Plugins] = Seq(play.sbt.PlayScala) diff --git a/project/AppDependencies.scala b/project/AppDependencies.scala index 51cff180..c3a5c99a 100644 --- a/project/AppDependencies.scala +++ b/project/AppDependencies.scala @@ -4,7 +4,7 @@ import play.sbt.PlayImport.* object AppDependencies { - val bootstrapVersion = "9.0.0" + val bootstrapVersion = "9.5.0" val compile: Seq[ModuleID] = Seq( ws, @@ -12,7 +12,7 @@ object AppDependencies { "uk.gov.hmrc" %% "play-partials-play-30" % "10.0.0", "uk.gov.hmrc" %% "domain-play-30" % "10.0.0", "uk.gov.hmrc" %% "http-caching-client-play-30" % "12.1.0", - "uk.gov.hmrc" %% "play-frontend-hmrc-play-30" % "10.5.0" + "uk.gov.hmrc" %% "play-frontend-hmrc-play-30" % "11.6.0" ) val test: Seq[ModuleID] = Seq( diff --git a/project/plugins.sbt b/project/plugins.sbt index d003c0ba..956a16a8 100644 --- a/project/plugins.sbt +++ b/project/plugins.sbt @@ -1,13 +1,13 @@ resolvers += "HMRC-open-artefacts-maven2" at "https://open.artefacts.tax.service.gov.uk/maven2" resolvers += Resolver.url("HMRC-open-artefacts-ivy", url("https://open.artefacts.tax.service.gov.uk/ivy2"))(Resolver.ivyStylePatterns) -addSbtPlugin("uk.gov.hmrc" % "sbt-auto-build" % "3.22.0") +addSbtPlugin("uk.gov.hmrc" % "sbt-auto-build" % "3.24.0") addSbtPlugin("uk.gov.hmrc" % "sbt-distributables" % "2.5.0") -addSbtPlugin("org.playframework" % "sbt-plugin" % "3.0.3") +addSbtPlugin("org.playframework" % "sbt-plugin" % "3.0.5") -addSbtPlugin("org.scoverage" %% "sbt-scoverage" % "2.0.12") +addSbtPlugin("org.scoverage" %% "sbt-scoverage" % "2.2.2") addSbtPlugin("org.scalastyle" %% "scalastyle-sbt-plugin" % "1.0.0" exclude("org.scala-lang.modules", "scala-xml_2.12")) diff --git a/test/views/propertyDetails/propertyDetailsNewValuationSpec.scala b/test/views/propertyDetails/propertyDetailsNewValuationSpec.scala index e9ad8dba..eb40d252 100644 --- a/test/views/propertyDetails/propertyDetailsNewValuationSpec.scala +++ b/test/views/propertyDetails/propertyDetailsNewValuationSpec.scala @@ -15,7 +15,7 @@ */ import config.ApplicationConfig -import forms.PropertyDetailsForms.{dateFirstOccupiedForm, propertyDetailsNewValuationForm} +import forms.PropertyDetailsForms.propertyDetailsNewValuationForm import models.StandardAuthRetrievals import org.jsoup.Jsoup import org.scalatestplus.mockito.MockitoSugar