Announcement

Collapse
No announcement yet.

Add 1 month to date

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Add 1 month to date

    Hi all! Tell me how to add date + 1 month to the field1 and display this date in field2.

  • #2
    you can do it like below:

    PHP Code:
    field2 datetime\addMonths(field11); 

    This will add a 1 month to field1 (which i assume is a date type) and will be stored in field2 which also needs to be date type.

    read more here https://docs.espocrm.com/administrat...mula/datetime/
    Last edited by rabii; 12-11-2023, 12:59 PM.

    Comment


    • #3
      Besides what rabii advised for the second part of your question:
      You can use field with Foreign type https://docs.espocrm.com/administration/fields/#foreign.
      You can use Formula: field2 = field1;
      You can use BPMN or Workflow, specifying the change of the field1 field in the Conditions, and assigning the value of the field1 field to the filed2 field in the Actions.
      Last edited by victor; 12-11-2023, 12:29 PM.

      Comment


      • #4
        Thank you very much everyone, everything worked out!

        Comment

        Working...
        X