Skip to content

Commit

Permalink
Merge branch 'master' into group-permission
Browse files Browse the repository at this point in the history
  • Loading branch information
YuryRybakSoftensity committed Jul 17, 2020
2 parents de81020 + aa61ab2 commit f795d10
Show file tree
Hide file tree
Showing 22 changed files with 2,109 additions and 1,345 deletions.
64 changes: 64 additions & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,28 @@ All notable changes to this project will be documented in this file
The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/)

## 2.0.0-rc.7
### Fixed
- FOR-2708: Remove resource from action if it was not found on import.
- FJS-1049: Fixed CSV export of components with minimized schema.
- Fixed setting of formRevision property on import when revisions are enabled.

## 2.0.0-rc.5-6
### Changed
- Updated logging functionality.

## 2.0.0-rc.1-4
### Changed
- Merge changes from 1.x

## 2.0.0-beta.10
### Changed
- Update formio.js to 4.1.0-rc.13

## 2.0.0-beta.9
### Changed
- retagging

## 2.0.0-beta.8
### Added
- Additional options to fetch wrapper.
Expand Down Expand Up @@ -57,6 +79,48 @@ and this project adheres to [Semantic Versioning](http://semver.org/)
- Upgrade mongodb@3.5.4, async@3.2.0
- Upgrade ResourceJS@2.0.0

## 1.90.3
### Changed
- Fixed setting of formRevision property on import when revisions are enabled.

## 1.90.2
### Changed
- Cherry pick email fix for large emails.

## 1.90.1
### Changed
- Resource.js library to 2.3.1 to revert change in aggregation.

## 1.90.0
### Fixed
- A bad revert.

## 1.89.0
### Changed
- Revert "Added a middleware for loading a full form schema for use component settings.

## 1.88.0
### Fixed
- FOR-2707: Fixes an issue where the PATCH request was being failed if a form has a nested form as reference.
- Server crashes when a bad query is passed to ResourceJS
- Added a middleware for loading a full form schema for use component settings.

## 1.87.0
### Fixed
- Export of form controllers.

## 1.86.0
### Fixed
- FJS-704: Address Refactor Issues
- Refactored for the verbose health endpoint
- Fixed Form Controller export.

### Added
- Support Extra form fields exporting

### Changed
- Upgraded formio-workers@1.14.8, mongodb@3.5.9, mongoose@5.9.19, nodemailer@6.4.10, formiojs@4.10.2, fs-extra@9.0.1, resourcejs@2.2.0, mocha@8.0.1

## 1.85.0
### Changed
- FJS-953: Fixed getting error when exporting scv with time inside dataGrid
Expand Down
17 changes: 17 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,16 @@ module.exports = function(config) {
}
};

router.formio.audit = (event, req, ...info) => {
if (config.audit) {
const result = router.formio.hook.alter('audit', info, event, req);

if (result) {
console.log(...result);
}
}
};

/**
* Initialize the formio server.
*/
Expand Down Expand Up @@ -82,6 +92,13 @@ module.exports = function(config) {
// Add the database connection to the router.
router.formio.db = db;

// Ensure we do not have memory leaks in core renderer
router.use((req, res, next) => {
util.Formio.forms = {};
util.Formio.cache = {};
next();
});

// Establish our url alias middleware.
if (!router.formio.hook.invoke('init', 'alias', router.formio)) {
router.use(router.formio.middleware.alias);
Expand Down
Loading

0 comments on commit f795d10

Please sign in to comment.