Setting the user-defined email and phone validation

You can set up the user define data in M3 Mobility Core Toolbox to allow M3 CLM validate if the required data in a field is an email or a phone number.

  1. Select System Configuration > Dialog design.
  2. Select filter.
  3. Navigate to Dialog Layout.
  4. Right-click Properties and select Set User Defined Data..
  5. Specify these user defined data:
    Sample regex for email validation:
    @ValidateFields={"RegEx": ["^(([^<>()\\[\\]\\.,;:\\s@\"]+(\\.[^<>()\\[\\]\\.,;:\\s@\"]+)*)|(\".+\"))@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\])|(([a-zA-Z\\-0-9]+\\.)+[a-zA-Z]{2,}))$"],"ErrorMessage":"ValidationError_InvalidEmail"
    }
    
    
    Note: You can modify the default regex according to your business needs.
    Sample format for phone validation:
    @FormatField={
        "Format": ["+nnnnnnnnnnnn"]
    }

    When creating a phone format, ensure that the number of characters complies with the number of characters required by M3. n represents the number between 0 to 9, while M3 validates the length depending on the number of n in the format. To create a phone format, you can also add a plus sign (+), left and right brackets (), or a dash (-). You can also add multiple phone formats by adding commas in between the phone formats as show in this example:

    "Phone": {"Format": ["+(420)-nnn-nnn-nnnn",”+(nn)-nnn-nnn”]}

    If the phone validation is based on a country, see the section on how to set up a code event in Code maintenance.