ATF - server side script to set a future date always.

tiasha123
Tera Contributor

Hi, 

I have a requirement in atf to set the date field to be always in future using server side script .

How can we achieve this ?

 

Thanks , 

Tiasha

1 ACCEPTED SOLUTION

Hi @tiasha123 

 

No Server side script is required.

Shaqeel_0-1726818288696.png

 

Directly use the code like this.

 

Regards

Shaqeel


***********************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting "Accept as Solution" and " Helpful." This action benefits both the community and me.

***********************************************************************************************************************





Regards

Shaqeel

View solution in original post

6 REPLIES 6

Shaqeel
Mega Sage

Hi @tiasha123 

 

Use javascript: gs.daysAgo(-1); Tomorrow

 

javascript: gs.daysAgo(1); Yesterday

 

javascript: gs.daysAgo(-31); 31 days in future

 

javascript: gs.daysAgo(31); 31 days in past

 

javascript: gs.nowDateTime(); today

 

 

You can use directly on field using set field value.

 

Regards

Shaqeel


***********************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting "Accept as Solution" and " Helpful." This action benefits both the community and me.

***********************************************************************************************************************





Regards

Shaqeel

Hi @Shaqeel ,

Does this mean , first in the implementation date - I will manually add a date and then in the next step , will use a server side script ?

Hi @tiasha123 

 

No Server side script is required.

Shaqeel_0-1726818288696.png

 

Directly use the code like this.

 

Regards

Shaqeel


***********************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting "Accept as Solution" and " Helpful." This action benefits both the community and me.

***********************************************************************************************************************





Regards

Shaqeel

Hi @Shaqeel ,

It worked . thank you.