31 lines
953 B
JavaScript
31 lines
953 B
JavaScript
const USER_ENTRY_EVENT = 'User Entry';
|
|
const ENABLE_PASSAGE_MODE = 'Enable Passage Mode by Group 2';
|
|
const DISABLE_PASSAGE_MODE = 'Disable Passage Mode by Group 2';
|
|
|
|
const USER_LOCKED_DOOR = 'locked';
|
|
const USER_UNLOCKED_DOOR = 'unlocked';
|
|
|
|
const VALID_CSV_HEADERS = ['Date', 'Time', 'User No', 'Name', 'Event'];
|
|
|
|
const csvParserErrors = {
|
|
INVALID_HEADERS: 'Invalid headers',
|
|
INVALID_ENTRY_EXPECTED_USER: 'Invalid entry type. Expected user entry type',
|
|
INVALID_ENTRY_EXPECTED_PASSAGE_MODE: 'Invalid entry type. Expected enable/disable passage mode following user entry',
|
|
UNKNOWN_MEMBER: 'Member is not registered in OfficeRnD system',
|
|
};
|
|
|
|
const officeRnDAPIErrors = {
|
|
FAILED_TO_FETCH_MEMBERS: 'Failed to fetch members',
|
|
};
|
|
|
|
module.exports = {
|
|
VALID_CSV_HEADERS,
|
|
USER_ENTRY_EVENT,
|
|
ENABLE_PASSAGE_MODE,
|
|
DISABLE_PASSAGE_MODE,
|
|
USER_LOCKED_DOOR,
|
|
USER_UNLOCKED_DOOR,
|
|
csvParserErrors,
|
|
officeRnDAPIErrors,
|
|
};
|