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

Question

Question

Forms Submission closing date

asked on April 6, 2018

I am looking to set a closing date on a form submission.

The form is being made public but no forms will be accepted after a specific date.

Anyone know the best way to achieve this?

0 0

Answer

SELECTED ANSWER
replied on April 6, 2018 Show version history

One option would be to add a Calendar field and simply hide it. Set the default value to be the current date. Then using Field Rules you can show and hide different sections of the page, depending on the date that you set for them to show or hide.

You can also choose to simply hide the whole default page, but a notice of form close would be neater. I would also add some type of script to hide the submit button or something.

 

Give the Main Section a class of "mainPage" and then add this to the JavaScript Section

$( document ).ready(function() {
  
  if ($(".mainPage").is(":visible")) {

    $('.action-btn').show();

  }
  else
  {
    $('.action-btn').hide();
  }
  
});

 

cal1.PNG
currentDate.PNG
Default.PNG
CSS.PNG
cal1.PNG (9.48 KB)
Default.PNG (23.85 KB)
CSS.PNG (10.81 KB)
2 0
replied on April 10, 2018

This is exactly what i was looking for. I only need to prevent submissions after a certain date but with other forms in the process i couldn't unpublish the process!

Thanks alot!

0 0

Replies

replied on April 6, 2018 Show version history

I have done this through workflow. Using the date as a conditional I use a custom query to change the status of the form by un-publishing it. Here is the query that I use to publish/hide the form.

update [YOUR DATABASE HERE].[dbo].[cf_business_processes]
set [is_activated] = '0'
where [name] = 'YOUR FORM NAME HERE'

0 hides it and 1 publishes the form. By doing this I am able to insure that application periods are adhered to.

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

Sign in to reply to this post.