Commit graph

3003 commits

Author SHA1 Message Date
Dillon-Brown
4fd431d97d Add ViewDefinition API
- Add initial ViewDefinition entity for list-view.
- Add ViewDefinitionHandler.
- Add ViewDefinitionDataProvider.
- Add ViewDefinitionProviderInterface.
- Add ViewDefinitionsHandlerTest.

Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:36 +01:00
Clemente Raposo
be1e0ca5cf Add url detail field component
- Add Component for detail mode
- Register components in dynamic components manifest
- Add sample usage to list view
- Add karma/jasmine tests
2021-03-30 19:21:36 +01:00
Clemente Raposo
066560dd40 Add global search
- Add global search service
- Enable global search on action bar
- Adjust global search input and button within action bar
- Add karma/jasmine tests
2021-03-30 19:21:36 +01:00
Dillon-Brown
c450c4f6ab Update imports to use single quotes
Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:36 +01:00
Clemente Raposo
feb9175f22 Add date and datetime detail field components
- Add base date time component with common methods
- Add Components
- Register components in dynamic components manifest
- Add sample usage to list view
- Add karma/jasmine tests
2021-03-30 19:21:36 +01:00
Clemente Raposo
21a831e9f3 Add date and time format config and preference mappers
- Update SystemConfigHander
-- Add ability to map config name
-- Add ability to map config value
-- Add SystemConfigMappers.php to store config mappers

- Update UserPreferenceHandler
-- Add ability to map preference name
-- Add ability to map preference value
-- Add UserPreferencesMappers to store preferences mappers

- Configure config mappers for date format
- Configure preference mappers for time format

- Update unit tests
2021-03-30 19:21:36 +01:00
Dillon-Brown
fceea32f83 Rename facade references to store
Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:36 +01:00
Clemente Raposo
369adbc4d0 Add Detail Mode Phone Field Component
- Add detail mode phone component
- Add component to generic field manifest
- Add sample to list view
- Add jasmine / karma tests
2021-03-30 19:21:35 +01:00
Clemente Raposo
013d5c2919 Configure eslint typescript imports
- Fix false positive errors on eslist ts imports
- Add eslint-import-resolver-alias
-- Add typescript path aliases as eslint alias
- Add eslint-import-resolver-typescript
2021-03-30 19:21:35 +01:00
Clemente Raposo
0e6b81c2b4 Rename facades folder to store
- Update folder name
- Update imports to use @store alias
- Update tsconfig @store alias
2021-03-30 19:21:35 +01:00
Dillon-Brown
9197335343 Create a UnitTester bootstrap and update existing tests
- Add UnitTester to hook into codeception login when executing tests.
- Create _beforeSuite and _before methods to reduce code duplication and improve performance.
- Add static closures where possible for better scoping and performance.
- Fix missing typehints/PHPDocs.

Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:35 +01:00
Clemente Raposo
6d976caac7 Fix module navigation jasmine test 2021-03-30 19:21:35 +01:00
Clemente Raposo
133a0e014b Adjust Varchar field component
- Use detail instead of list as base implementation
- Remove record. edit will be implemented later on.
- Use Base field component
- Add unit tests
2021-03-30 19:21:35 +01:00
Clemente Raposo
6db4a85634 Add int and float field detail implementation
- Add base field class
- Add base number class
- Add int field detail mode component
- Add float field detail mode component
-- Format using user preferences or system config
-- Add NumberFormatPipe to format using preferences
- Add fields to manifest
- Add sample to list view
- Add jasmine tests
2021-03-30 19:21:35 +01:00
Clemente Raposo
5036e8c85b Display list view module action menu items
- Update button component
-- Update model to support passing a click handler
-- Update html
-- Add unit tests

- Add ModuleNavigation Service
-- Groups module and module action navigation actions
-- Change Navbar and other components to use this service

- Update action menu
-- Retrieve menu action information
-- Retrieve labels
-- Render buttons
2021-03-30 19:21:35 +01:00
Clemente Raposo
4da2aa3bba Display list view module title
- Change List and ListHeader components to grab data and pass it down
- Update ModuleTitle component to title as input and display it
- Update and add jasmine test for these components
2021-03-30 19:21:35 +01:00
Clemente Raposo
16de3551f2 Setup new list view route 2021-03-30 19:21:35 +01:00
Dillon-Brown
e81e24a32d Update application rebuild commands to use new folder structure
Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:35 +01:00
Dillon-Brown
2d42d40ce7 Create generic varchar component for list-view data
Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:35 +01:00
Dillon-Brown
00bc515320 Fix typeRoot pathing in tsconfig.json
Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:35 +01:00
Dillon-Brown
46b06f3035 Update the logout component to use a logout language string
- Import language languageFacade into logout component
- Add logout-link-model.ts
- Add logout-model.ts
- Update the logout component HTML to use an async pipe

Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:35 +01:00
Clemente Raposo
d567ec9baf Adjust classic view iframe sizing
- adjust sizing to fix
-- slight pixel difference after the action bar
-- before the footer
2021-03-30 19:21:35 +01:00
Clemente Raposo
dcc814dc24 Add legacy theme compile step to readme 2021-03-30 19:21:35 +01:00
Clemente Raposo
fb359cd5f6 Add ClassicView redirection exclusions
- Add configurable exclusions by module / action on the backend
-- Add ClassicViewRoutingExclusionsHandler to grab these from legacy
-- Expose these as system configs to the frontend
- Update redirect check to classic view
-- Do not re-direct when same route (example, for listview filtering)
-- Do not re-direct when route is excluded
-- Do not re-direct when not able to convert route
- Update unit tests
2021-03-30 19:21:35 +01:00
Clemente Raposo
e228f0891c Add create action bar links
- Replace hardcoded labels with translations
- Replace hardcoded html with dynamic list
- Add router links to related create views.
- Fix wrong usage of div instead of ul
2021-03-30 19:21:35 +01:00
Dillon-Brown
5ceaf98172 Update navbar to use front-end route converter
Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:35 +01:00
Clemente Raposo
f10cc2812f Display selected module on navbar
- Add current module and action to AppState
- Calculate current module and action in BaseModuleResolver
-- Add logic to show current module as active on
--- import and find duplicates
- Update legacy handler method to retrieve available modules
-- Also send invisible modules, to
--- Allow to display invisible modules as the selected module
-- Update module name mape
- Retrieve number of navbar items from backed

- Fix grouped tab links
- Simplify navbar abstract by simplifying parameters
-- passing language map instead of individual language
-- passing navigation object instead of individual parts
- Create smaller components for repeated parts of navbar
-- grouped-menu-item
-- menu-item
-- menu-item-link
-- menu-item-list
-- home-menu-item
-- home-menu-recently-viewed

- Removing "jsdoc/no-types" from eslint
-- To avoid conflicts with jsdoc/require-param-type
2021-03-30 19:21:35 +01:00
Dillon-Brown
3672c445e7 Create a UserChecker for pre/post authentication security
- Implement UserChecker to check user deletion status on pre/post auth.
- Modify LoginFormAuthenticator to use Symfony/Security to fetch user data.
- Add Security Exceptions: UserDeletedException, UserNotFoundException.
- Set the security firewall to run the UserChecker.
- Update User Entity with deleted getter.

Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:35 +01:00
Dillon-Brown
81c1768af8 Update session expiration logic
- Fix a duplicate session expiry message
- Update application logic to handle request chaining

Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:35 +01:00
Clemente Raposo
d9e27111d3 Re-direct login routes to home page whe user is logged in
- Add login auth guard
-- Check if session is active on front end, if so go to home page
-- Check if session is active on backed, if so go to home page
-- Otherwise stay on login
- Add loaded flag to AppStateFacade to:
-- Know if the page has already been loaded
-- Avoid doing an extra request to the backed if we logged out on the frontend
- Enable angular router onSameUrlNavigation to:
-- Allow refreshing pages
-- Properly updating url when trying to go from home to login, which goes back to home
2021-03-30 19:21:35 +01:00
Clemente Raposo
00d8330f39 Add session status check to classic view
- Check session when moving between classic views
-- Update backend session-status entry point to also check legacy session
- Check if classic view iframe was re-directed to login page
- Logout user in the above
- Add conditional redirect to auth service logout
- Add key based loading to fix issues with loading on logout.
- Update jasmine tests
2021-03-30 19:21:34 +01:00
Clemente Raposo
b2c30d9c98 Fix multiple submission errors on login component
- Add button-loading directive to update button according to loading state
-- Add ability to listen to AppStateFacade loading state
-- Add ability to listen to loading input from parent component
- Add jasmine unit tests

- Fix action-name-mapper jasmine unit tests
2021-03-30 19:21:34 +01:00
Dillon-Brown
145ee25dc5 Update FieldDefinitionHandlerTest to remove starting the legacy app
- This fixes an issue with trying to destroy a non-existing session

Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:34 +01:00
Dillon-Brown
76744d36b7 Add module vardef entity and data providers
Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:34 +01:00
Clemente Raposo
5d6aa45391 Add Route conversion on legacy
- Add legacy handler to access RouteConverter
- Add legacy handler to access ModuleNameMapper
- Add legacy handler to access ActionNameMapper
- Remove action and module name maps from Suite8 side

- Update frontend route converter to check for suite 8 routes
-- When link is a suite 8 route does not convert

- Add LegacyScopeState to allow for nested legacy handler calls
-- Add abstract getHandlerKey to base LegacyHandler
-- Implement getHandlerKey on all legacy handlers

- Update legacy handler init and close methods to use scope state
-- Check if withing an already open legacy handler scope
2021-03-30 19:21:34 +01:00
Clemente Raposo
3931ce40fa Add Route conversion on legacy - Legacy changes
- Move RouteConverter to legacy
- Move ModuleNameMapper to legacy
- Move ActionNameMapper to legacy
- Add smarty function to convert links
- Convert legacy links into Suite 8 links
-- Change mvc_utils::ajaxLink for most common links
-- Change ListViewGeneric links for list view links
-- Change DashletGenericDisplay for common dashlet links
2021-03-30 19:21:34 +01:00
Clemente Raposo
c1ef13322a Add legacy non-view actions re-direction
- Listen to legacy non-view calls on the LegacyRedirectListener
- Add LegacyNonViewActionRedirectHandler to re-direct to legacy
-- Using 307 re-direction response to support post re-direction
- Add unit test for LegacyNonViewActionRedirectHandler
2021-03-30 19:21:34 +01:00
Clemente Raposo
6c3e266b5d Add legacy api re-direction
- Listen to legacy api calls on the LegacyRedirectListener
- Add LegacyApiRedirectHandler to re-direct to legacy endpoint
-- Using 307 re-direction response to support post re-direction
-- Using api_paths.yaml with the configuration with paths to check

- Setup API tests using codeception
-- Add helper methods to login in v4 and v8 API
- Add Api test to create account using v4 api
- Add Api test to create account using v8 api
- Add unit test for LegacyApiRedirectHandler
2021-03-30 19:21:34 +01:00
Clemente Raposo
2a489cbc7e Add fallback value to frontend action name mapper
- When not mapped, fallback to provided value
- Add ShowDuplicates to action_name_map
2021-03-30 19:21:34 +01:00
Clemente Raposo
023ae68e38 Adjust ClassicView Iframe auto-resizing calculations
- Update initial adjustements to use same calculations
- Update calc to use window height when content is smaller
2021-03-30 19:21:34 +01:00
Clemente Raposo
e575f5d36d Update Action Name Map
- map about action
2021-03-30 19:21:34 +01:00
Clemente Raposo
4a4372d1e1 Update user provider
- Minor fix: allow for null user first name and last name
2021-03-30 19:21:34 +01:00
Clemente Raposo
e147faf3a1 Implement ClassicView
- Change Classic view component to use Iframe to render legacy view for specified url
- Add Iframe page change observer to detect page changes and route to appropriate view
-- Move legacy to suite8 route conversion to the front end
- Add Iframe resize observer to re-adjust the iframe size according to its contents
- Expose module and action name maps to the frontend within thee system configs
- Add unit and karma tests and ajdust existing ones
- Add floating to messages alert
- Make classic view resolver extend the base metadata resolver
- Move all front end calls to the default_module config to a single place
- Map default module name to frontend name in the legacy handler
2021-03-30 19:21:34 +01:00
Dillon-Brown
aa242f970c Implement user action menu
Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:34 +01:00
Mac-Rae
f488ae2c8c Update readme to be more up-to-date
- Lose outdated img link
- Update licence to look within legacy
- Correct formatting with Requirements table
- Update installation to follow new changes
- Remove steps involving standalone database
2021-03-30 19:21:34 +01:00
Dillon-Brown
bc115670ba Add legacy user provider
- This changes the Symfony User entity to fetch the user from the legacy users table

Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:34 +01:00
Clemente Raposo
b5828346bf Add responsive styling for custom logo
- Add styling to display default logo and custom logo properly in desktop and responsive layouts
- Fix responsive layout for language
-- Adjust html
-- Adjust select css for login component
- Fix responsive layout for footer
2021-03-30 19:21:34 +01:00
Clemente Raposo
25f7d38fcd Add legacy suite configuration support for grouped tabs
- Add ability to fully start legacy app on legacy handlers
- Update Navbar and UserPreferences handler to start the legacy app after init
- Update Navbar and UserPreferences handler to implement the corresponding interfaces
-- Update corresponding Data providers to use the new interfaces

- Change Navbar legacy handler to take into account the tab configured preferences
-- based on the implementation used in Legacy SugarView

- Update UserPreferences to use the currently logged in user
-- remove hard coded user
-- get UserPreferences from the legacy User object instead of grabbing it directly from the db

- Add All entry to grouped tabs

- Adjust unit tests
2021-03-30 19:21:34 +01:00
Dillon-Brown
9d484ed4a4 Linkup footer back to top with authentication
Signed-off-by: Dillon-Brown <dillon.brown@salesagility.com>
2021-03-30 19:21:34 +01:00
Clemente Raposo
ca47dded0a Fix Password Recovery messages
- Catch missing exception
- Add extra exception handling on the backend and send error back to front end.
- Handler errors on the front-end and show message.
2021-03-30 19:21:34 +01:00