diff --git a/grails-app/conf/application.groovy b/grails-app/conf/application.groovy index 00c9227b9..83af8ed75 100644 --- a/grails-app/conf/application.groovy +++ b/grails-app/conf/application.groovy @@ -201,7 +201,7 @@ abn.abnUrl= "https://abr.business.gov.au/json/AbnDetails.aspx?abn=" esp.activities.admin = 'ESP Annual Report Submission' reports.filterableActivityTypes = ['RLP Output Report', 'Wildlife Recovery Progress Report - WRR'] - +reports.initialScrollPositionDelay = 1000 risks.scheduleCheckingPeriod = 7 grails.mail.poolSize = 1 diff --git a/grails-app/views/activity/activityReport.gsp b/grails-app/views/activity/activityReport.gsp index 709feb804..f56b7569d 100644 --- a/grails-app/views/activity/activityReport.gsp +++ b/grails-app/views/activity/activityReport.gsp @@ -36,7 +36,8 @@ prepopUrlPrefix:"${grailsApplication.config.getProperty('grails.serverURL')}", useGoogleBaseMap: ${grails.util.Environment.current == grails.util.Environment.PRODUCTION}, unlockActivityUrl: "${createLink(controller:'activity', action:'ajaxUnlock')}/", - projectTargetsAndScoresUrl: "${createLink(controller:'project', action:'targetsAndScoresForActivity', id:activity.projectId, params:[activityId:activity.activityId])}" + projectTargetsAndScoresUrl: "${createLink(controller:'project', action:'targetsAndScoresForActivity', id:activity.projectId, params:[activityId:activity.activityId])}", + initialScrollPositionDelay: "${grailsApplication.config.getProperty('reports.initialScrollPositionDelay')} ?: '1000'" }, here = document.location.href; @@ -278,7 +279,9 @@ var $validationContainer = $('#validation-container'); $validationContainer.validationEngine('attach', {scroll: true}); - navigator.initialiseScrollPosition($validationContainer, activity.progress); + setTimeout(function() { + navigator.initialiseScrollPosition($validationContainer, activity.progress); + }, fcConfig.initialScrollPositionDelay); $('.imageList a[target="_photo"]').attr('rel', 'gallery').fancybox({ type: 'image',