Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
SPSH-698: Personenkontexte bearbeiten: Weitere Zuordnung hinzufügen (#…
…524) * SPSH-658: Umbau des Personenkontextes nach DDD Richtlinien * Create personenkontext factory and validity checks * SPSH-658: Erste Iteration für die Filterung be der Rollenabfrage des eingeloggten Admins. * Fix dependencies * SPSH-658: Undone the first implementation for filtering roles, implemented the first draft for checking roles assignment. * More permission checks * SPSH-658: Extra Prüfung für die Systemrechte bei der Anlage eines Personenkontextes. * SPSH-658: Tests wegen Dependencies & setups fixen. * SPSH-658: Fixed Lint Warnungen * SPSH-658: Fixed more tests * SPSH-658: Fixed more tests * SPSH-658: Fixed integration tests für den Personenkontext-Controller * Move logic to permissions * Fix tests * Fix more tests * Fix remaining non-api-tests * Allow logged in user to see all personenkontexte of another user if authorized * Fix more tests * Fix all tests * Merge remote-tracking branch 'origin/main' into spsh-606 * More code coverage * SPSH-658: Unittests für den Personenkontext Aggregate, neue Error Klassen & OrganisationRepository, & Integrationtests für dbiam-personenkontext.repo * Fix tests * SPSH-658: Fixed unittests wegen merge conflicts * move param and response files in personenkontext/api * Add Repo to person module * fix imports * add PersonenkontexteUpdate as aggreate * Mock keycloak in integration test * Cover createAuthorized in tests * Fix personenkontext.uc tests * SPSH-658: Specification for landes-admin implemented and extra check for the creation of personenkontext. * Fix personenkontext tests * Fix tests * add validation for Personenkontexte-Update aggregate * add test for PersonenkontexteUpdate and corresponding classes * SPSH-658: Changed the logic for the extra check for the permission of the current admin by the creation of the personenkontext. Refactored the OrganisationMatchesRollenart from the personenkontext-anlage in an helper class. * SPSH-658: Fixed lint issues * add exception-filter for PersonenkontexteUpdateErrors * SPSH-658: Refactored the Personenkontext aggregate and changed the exception type for the check for the OrganisationMatchesRollenart * Fix repo tests * SPSH-658: Fixed tests for Personenkontext * Add error to mapper * Cover dbiam-personenkontext.repo * Cover organisation-repository * Fix dbiam-personenkontext-controller coverage * Remove unused code * SPSH-658: Corrected the unit tests for personenkontext * Fix tests * SPSH-658: Implemented unit-tests for the organisation-matches-rollenart * Revert test timeout * Fix OutOfMemory * adjust PersonenkontexteUpdate to handle addtions of PK * SPSH-606: Added a partial Personenkontext for the tests in order to fix the memory issue. * adjust deletion of Personenkontext to be native * adjust delete-method in PersonenkonteUpdate * remove unused method * adjust PersonenKontext.rolleId to reference Rolle * SPSH-731: Implemented the restriction of roles that can be viewed for the creation of personenkontext, and made the parameter rollenName for the endpoint /GET/api/personenkontext/rollen optional * SPSH-658: PR Review * Rename createAuthorized * SPSH-606: Fixed tests due to the error resulting from the sequence of setup data * SPSH-731: Implemented integration tests for the DbiamPersonenkontextFilterController * SPSH-731: Implemented unit tests for the PersonenkontextAnlage * fix automapper issues in test * adjust PersonenkontexteUpdate and tests * add PersonenkontexteUpdate-event * adjust events for Personenkontext * adjust tests for LdapEventHandler * SPSH-732: Implemented a new endpoint that checks the validity of personenkontext before saving the person and the personenkontext. * SPSH-732: Undid the extra method for checkReferences in Personenkontext * add DbiamPersonenUebersicht aggregate and implement persion check for PK-retrieval * SPSH-732: Refactored error codes for FE. * SPSH-732: Updated the payload for the request POST api/dbiam/personen * move publishing of events for Personenkontext and Orga into the repos * SPSH-732: Implemented unit tests * SPSH-732: Fixed lint * SPSH-732: Fixed dependency issue for the dbiam person controller * SPSH-732: Implemented the integration tests * SPSH-732: Fixed tests for Keycloak * adjusted DbiamPersonenkontext controller and tests * SPSH-732: Added more unit tests and removed unused specifications * SPSH-732: Fixed KC issues for the integration tests * SPSH-732: Fixed the KC issue for the integration tests * SPSH-732: PR review * fixed linting * Event published after creating the kontext hold personId, OrgaId and RolleId * Introduced the workflow controller * Enhanced new error class that is thrown at commit time. * Added necessary classes to the person module * Fixed linting * Fixed response and test * Search by string is possible for both ssk and rolle now * fixed test and renamed aggregate * Fixed tests * remvoed log statement * Handled error in commit endpoint and fixed test * Catch error in the commit controller * can commit method now also returns errors instead of boolean to propagate errors to controlelr * Fixed person service test * fix * test for commit method * more tests * fixed test * Covered all lines for workflow aggregate * Test for find method * errors test * covered more lines * fixed linting * covered badrequestexception line * Fixed tests * Fixed test * covered last line * added types to test for the orga and rolle to match * Test for handling request with no orgaId * trigger rollen method if orga is provided * made use of class properties instead of method parameters * added initiazer to test * last test * fixed lint * modified rollen logic * fixed test * added roles to array in test * Fixed test * fixed litning * return orgas also if the orgaId was provided * fixed tests after merge * linting * added test for error * another test for error * changed path to workflow and added description of the API * Not considering child orgas while fetching for rollen. * Sorting Rollen b y name, Orgas by kennng And Name and Klassen by name * Removed unncesseary assertions as now orgas are sorted and can't be compared to unsorted orgas * tests for sorting * covered last line * added another Rolle to the spec to sort * fixed assert * test for undefined name while sorting * test for undefined kennung and undefined rolle * fixed assertion * test for undefined everything * more coverage * couple more tests to reach 100% coverage * undefined kennung but present name * test * removed the only * check for rollen * remove check for rollen * changed the logic for sorting * more test for sorting * test * linting * fixed linting * last test * linting * SPSH-698: Refactoring, moved the creation of persons with personenkontext in the PersonenkontextModule * SPSH-698: Renamed the route of the POST method createPersonWithKontext to fix integration tests. * SPSH-698: Fixed the issue with integration tests failing in the pipeline due to KC test-container. * SPSH-698: PR Review * SPSH-698: Removed the sort unit test for the organisation.uc.spec * SPSH-698: Added unit tests for the limit parameter & updated the logic for returned allowedRollen when the limit is set. * SPSH-698: Changed the endpoint for the request CreatePersonWithPersonenkontext * SPSH-698: Changed the logic for the findAllSchulstrukturknoten() method. * SPSH-698: Implemented the query filter for requesting organisations from the DB and updated the unit tests * SPSH-698: Fixed KC issues * SPSH-698: Fixed integration tests failing due modules setup * SPSH-698: Moved the OrganisationScope for querying the DB from the domain to the repository. * SPSH-698: PR Review 2 --------- Co-authored-by: Phael Mouko <[email protected]> Co-authored-by: Marvin Rode <[email protected]> Co-authored-by: Marvin Rode (Cap) <[email protected]> Co-authored-by: Haby-Phael Mouko <[email protected]> Co-authored-by: godtierbatuhan <[email protected]> Co-authored-by: Youssef Bouchara <[email protected]>
- Loading branch information