Skip to content

feat(admin): #IMPULS-5903 add Screeb integration - #1077

Merged
damienromito merged 2 commits into
develop-b2schoolfrom
feat-IMPULS-5903-add-screeb-admin
Jul 10, 2026
Merged

feat(admin): #IMPULS-5903 add Screeb integration#1077
damienromito merged 2 commits into
develop-b2schoolfrom
feat-IMPULS-5903-add-screeb-admin

Conversation

@damienromito

@damienromito damienromito commented Jul 8, 2026

Copy link
Copy Markdown
Member

Description

Intègre le SDK Screeb (outil de feedback/enquêtes utilisateurs) dans le module admin (Angular 14), sur le même modèle que l'intégration déjà en place côté conversation.

  • Ajout de @screeb/sdk-angular et @screeb/sdk-browser (0.7.0) au module admin.
  • ScreebModule chargé avec autoInit: false, shouldLoad: false : aucun script Screeb n'est chargé au bootstrap. Le ScreebService pilote manuellement load()/init() une fois la conf de la plateforme connue.
  • Activation par plateforme via publicConf (screeb-app-id, screeb-allowed-profiles optionnel) exposée par GET /admin/conf/public, ajoutée dans template.j2.
  • Identité envoyée à Screeb = SHA-256(userId) tronqué à 16 caractères hexadécimaux (règle de confidentialité commune aux intégrations Screeb Edifice) — aucun identifiant réel transmis.
  • Mock de dev dans proxy-development.conf.js (clé SCREEB_APP_ID_DEV du .env) : la recette ne servira la clé sur /admin/conf/public qu'une fois ce template.j2 déployé.

Fixes

IMPULS-5903

Type of change

Please check options that are relevant.

  • Chore (PATCH)
  • Doc (PATCH)
  • Bug fix (PATCH)
  • New feature (MINOR)

Which packages changed?

Please check the name of the package you changed

  • admin
  • app-registry
  • archive
  • auth
  • cas
  • common
  • communication
  • conversation
  • directory
  • feeder
  • infra
  • portal
  • session
  • test
  • tests
  • timeline
  • workspace

Tests

  1. Renseigner SCREEB_APP_ID_DEV dans admin/src/main/ts/.env, lancer ng serve avec le proxy de développement.
  2. Vérifier dans les DevTools que le tag Screeb ne se charge que lorsque screeb-app-id est présent dans la réponse mockée de /admin/conf/public.
  3. Vérifier qu'aucun appel réseau vers Screeb n'a lieu quand la clé est absente/vide.
  4. Vérifier, si screeb-allowed-profiles est renseigné, que l'init est bien filtrée selon le profil de session.

Reminder

  • Security flaws

  • Performance impacts (think bulk !)

  • Unit tests were replayed

  • Unit tests were added and/or changed

  • I have updated the reminder for the version including my modifications

  • All done ! 😃

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a Screeb (user feedback/surveys) integration to the admin Angular 14 frontend, modeled after the existing conversation integration, with runtime-controlled enablement via the platform publicConf.

Changes:

  • Adds an ScreebService that conditionally loads/initializes Screeb based on /admin/conf/public and session profile.
  • Registers ScreebModule with autoInit: false / shouldLoad: false and triggers initialization from AppRootComponent.
  • Exposes Screeb configuration in admin’s template.j2, adds a dev proxy mock for /admin/conf/public, and introduces Screeb SDK dependencies.

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
admin/src/main/ts/src/app/core/services/screeb.service.ts Introduces a dedicated Screeb bridge service that loads/initializes Screeb based on platform public configuration.
admin/src/main/ts/src/app/core/core.module.ts Registers ScreebService in the core providers.
admin/src/main/ts/src/app/app.module.ts Adds ScreebModule.forRoot() configured for manual load/init.
admin/src/main/ts/src/app/app-root.component.ts Initializes Screeb after session retrieval, with error capture.
admin/src/main/ts/proxy-development.conf.js Adds a dev-only bypass to mock /admin/conf/public when SCREEB_APP_ID_DEV is set.
admin/src/main/ts/package.json Adds Screeb Angular + browser SDK dependencies.
admin/src/main/resources/template.j2 Adds publicConf keys for screeb-app-id and optional allowed profiles.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread admin/src/main/ts/src/app/core/services/screeb.service.ts Outdated
@sonarqubecloud

Copy link
Copy Markdown

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.

Comment thread admin/src/main/ts/src/app/app-root.component.ts

@jcbe-ode jcbe-ode left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK pour moi, à voir si Pascal a des retours.

// Screeb is loaded and initialized manually (see ScreebService): the app id is
// only known at runtime, from the platform publicConf, and no script must be
// loaded at all when Screeb is not enabled for the platform.
ScreebModule.forRoot({

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

forRoot fait partie des choses que je ne connais pas :)

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

comme au dessus, ça semble etre une methode pour declarer une dependance à la racine du module. (methode de Screeb dont les parametres permettent ici de ne pas charger Screeb automatiquement => c'est ici qu'on decide de le charger en fonction de la conf plateforme https://github.com/edificeio/entcore/blob/feat-IMPULS-5903-add-screeb-admin/admin/src/main/ts/src/app/app-root.component.ts#L100)

@damienromito
damienromito merged commit e4a3d02 into develop-b2school Jul 10, 2026
2 checks passed
@damienromito
damienromito deleted the feat-IMPULS-5903-add-screeb-admin branch July 10, 2026 12:40
damienromito added a commit that referenced this pull request Jul 13, 2026
* fead(admin):#IMPULS-5903 add screeb

* clean Screeb interface without useless method
pb-jo pushed a commit that referenced this pull request Jul 15, 2026
* fead(admin):#IMPULS-5903 add screeb

* clean Screeb interface without useless method
jenkinsEdificePublic pushed a commit that referenced this pull request Jul 20, 2026
* fead(admin):#IMPULS-5903 add screeb

* clean Screeb interface without useless method
damienromito added a commit that referenced this pull request Jul 24, 2026
* fead(admin):#IMPULS-5903 add screeb

* clean Screeb interface without useless method
damienromito added a commit that referenced this pull request Jul 24, 2026
* fead(admin):#IMPULS-5903 add screeb

* clean Screeb interface without useless method
damienromito added a commit that referenced this pull request Jul 24, 2026
* fead(admin):#IMPULS-5903 add screeb

* clean Screeb interface without useless method
damienromito added a commit that referenced this pull request Jul 24, 2026
* fead(admin):#IMPULS-5903 add screeb

* clean Screeb interface without useless method
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants