Refactor portal template scheduling (#6613)
* Refactor portal template scheduling
Move schedule from profile to template in profile
new function to fetch template events
add a notification day and when trigger
* add table columns to support portal notifications
service functions to support fetch template events fix
* This commit is work torwards our portal bug fix.
Plan is that on doc create save, the new rendered template is duplicated and saved separate in table
so data version is same as template version. Any further edits will call this template but only save form data henceforth.
- create new service class from download document script as it is needed to render in php
* Many chamges for new save workflow.
* fix signature in audit for admin signing.
new flatted document fucntion for reporting
* add new style directives to allow style tags to pass purifier.
refactor style repace in render
* add allow delete for admin to clean up abandoned or deem invalid audits
allow flatten doc save from interface. have to do this for legacy, history and reports.
* add file upload to portal
* clean up and review fixes
20 files changed: