When a field of a type is selected at a facade level, it inherits all the properties defined at the type level.

However, it is sometimes necessary to modify these properties to adapt the field to its context of use.

 

AmendedFields

To amend field properties Akwatype has the statement amendedFields { }

Most properties can be amended, excepted :

  • field type (String, Address ...)
  • whether the field is a list or not

 

Example of using amendedFields

facade PersonDTO on Person {
    
    amendedFields {
        name {
            label:"Local name"
            example"Smith"
            maxLength30
        }
        firstName {             label:"Local firstname"             example"Lea"             maxLength30                    }     }
    lastName:name     firstName }