<commit_before>package xml.circumstances

import models.domain.{CircumstancesDeclaration, CircumstancesReportChange, Claim}
import scala.xml.NodeSeq
import xml.XMLHelper._
import models.domain.Claim
import scala.Some

/**
 * Created by neddakaltcheva on 3/13/14.
 */
object Claimant {
  def xml(circs :Claim): NodeSeq = {
    val reportChange = circs.questionGroup[CircumstancesReportChange].getOrElse(CircumstancesReportChange())

    <ClaimantDetails>
      {question(<FullName/>, "fullName", encrypt(reportChange.fullName))}
      {question(<DateOfBirth/>,"dateOfBirth", reportChange.dateOfBirth)}
      {question(<NationalInsuranceNumber/>, "nationalInsuranceNumber", encrypt(reportChange.nationalInsuranceNumber))}
      {question(<ContactPreference/>,"furtherInfoContact", reportChange.furtherInfoContact)}
      {question(<WantsContactEmail/>,"wantsEmailContact", reportChange.wantsContactEmail)}
      {question(<Email/>,"mail.output", reportChange.email)}
    </ClaimantDetails>
  }
}
<commit_msg>CADS-382 : CASA Circs pdf for email contact details has an email label that matches new-claim and not circs.  It is not "Do you want an email to conform your change has been received" as per html on screen.<commit_after>package xml.circumstances

import models.domain.{CircumstancesDeclaration, CircumstancesReportChange, Claim}
import scala.xml.NodeSeq
import xml.XMLHelper._
import models.domain.Claim
import scala.Some

/**
 * Created by neddakaltcheva on 3/13/14.
 */
object Claimant {
  def xml(circs :Claim): NodeSeq = {
    val reportChange = circs.questionGroup[CircumstancesReportChange].getOrElse(CircumstancesReportChange())

    <ClaimantDetails>
      {question(<FullName/>, "fullName", encrypt(reportChange.fullName))}
      {question(<DateOfBirth/>,"dateOfBirth", reportChange.dateOfBirth)}
      {question(<NationalInsuranceNumber/>, "nationalInsuranceNumber", encrypt(reportChange.nationalInsuranceNumber))}
      {question(<ContactPreference/>,"furtherInfoContact", reportChange.furtherInfoContact)}
      {question(<WantsContactEmail/>,"wantsEmailContactCircs", reportChange.wantsContactEmail)}
      {question(<Email/>,"mail.output", reportChange.email)}
    </ClaimantDetails>
  }
}

{'fraction_non_alphanumeric': 0.1171945701357466, 'fraction_numerical': 0.0058823529411764705, 'mean_word_length': 5.782208588957055, 'pattern_counts': {'":': 0, '<': 19, '<?xml version=': 0, '>': 19, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 8}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7645379', 'n_tokens_mistral': 681, 'n_tokens_neox': 628, 'n_words': 125}