You are viewing limited content. For full access, please sign in.

Question

Question

Set date fields based on a date

asked on January 14, 2022

Hello,

We are creating an overtime request form and would like to dynamically display a start and end date of the future pay period based on the submission date in the current pay period. As well as, display a deadline date when someone can submit form, which would always be the Wednesday before the start of the future pay period.

For example:

Current pay period is 01/09/22 - 01/22/22.

Future pay period is 01/23/22 - 02/05/22.

Deadline date would be 01/19/22.

If I am filling out the form today (01/14/22) would like to display start date as 01/23/22 and end date as 02/05/22. Deadline date as 01/19/22. 

I have read through date and calendar topics but nothing like our situation. Any insight on how to set this up would be greatly appreciated.

Thank you in advance!

0 0

Replies

replied on January 14, 2022

Since you are using biweekly pay periods you're going to have to get the pay period beginning and end from an external source (you can't simply say Sunday through Saturday).  If you can't do a lookup against the payroll application, then you can either create a special purpose SQL table, or store a baseline "first pay period of the year" begin and end date.  Fortunately, date fields can be manipulated with whole day arithmetic.

0 0
replied on January 14, 2022

 

 

 

0 0
replied on January 19, 2022

Hi @james @████████ - thank you for your reply. Doing a look up to a table makes sense. Going to give it a try!

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.