Skip to content

Tab Orientation user setting#285

Merged
rkrenn merged 6 commits intomasterfrom
taborientation
Mar 1, 2024
Merged

Tab Orientation user setting#285
rkrenn merged 6 commits intomasterfrom
taborientation

Conversation

@rkrenn
Copy link
Copy Markdown
Collaborator

@rkrenn rkrenn commented Mar 1, 2024

users can set the orientation of tabview tabs.

Summary by CodeRabbit

  • New Features
    • Added user preference for tab orientation (top/left/right) with inheritance and defaults.
    • Applied chosen orientation across tabbed pages (User, Staff, Proband, Trial, Inventory, Course, Mass Mail, Input Fields).
  • Chores
    • Added new labels and translations (EN/DE) for tab orientation.
    • Updated application settings to include default and preset values for tab orientation.
    • Database migration updated to support storing the new preference.

@rkrenn rkrenn merged commit b0b8451 into master Mar 1, 2024
@rkrenn
Copy link
Copy Markdown
Collaborator Author

rkrenn commented Aug 19, 2025

@CodeRabbit review full

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Aug 19, 2025

@rkrenn I'll perform a full review of the PR changes for the tab orientation user setting feature.

✅ Actions performed

Full review triggered.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Aug 19, 2025

Caution

Review failed

The pull request is closed.

Walkthrough

Adds a user-configurable Tab Orientation preference end-to-end: database schema column, VO copy/mapping, default/settings keys, session/model beans, localization entries, and UI bindings in multiple xhtml views. Also introduces bundle-localized helper methods in label classes and updates several UML profile files with ID/namespace remaps.

Changes

Cohort / File(s) Summary
DB schema versioning
core/db/schema-set-version.sql, core/db/schema-up-master.sql
New USERS column TAB_ORIENTATION (varchar 1024, nullable) with upgrade block to version 010801040; schema-set-version updated accordingly.
User tab orientation propagation
common/src/.../CommonUtil.java, core/src/.../DemoDataProvider.java
Copy tabOrientation between in/out user objects and in demo data assignment.
Session/model support
web/src/.../model/SessionScopeBean.java, web/src/.../model/shared/UserSettingsBeanBase.java, web/src/.../model/user/UserBean.java, web/src/.../model/user/UserSettingsBean.java
New getter in SessionScopeBean resolving effective tabOrientation (user or default). User beans gain get/set for tabOrientation and copy/init wiring; base adds abstract accessors and tooltip handling.
Settings and constants
web/src/.../util/DefaultSettings.java, web/src/.../util/SettingCodes.java, web/src/main/resources/.../settings.properties
Adds default_tab_orientation and user_tab_orientation_preset keys and corresponding constants; defaults set to "top".
Localization utilities
web/src/.../bundle/FacesBundle.java
Adds localized message/string helpers with locale resolution and default label.
Bundle-specific localization wrappers
web/src/.../bundle/Labels.java, .../CourseLabels.java, .../InputFieldLabels.java, .../InventoryLabels.java, .../MassMailLabels.java, .../Messages.java, .../ProbandLabels.java, .../StaffLabels.java, .../TrialLabels.java, .../UserLabels.java
Adds public static getMessageLocalized/getStringLocalized delegating to base helpers with class bundle name.
i18n resources (generic)
web/src/main/resources/org/phoenixctms/ctsms/web/labels*.properties
Adds left_label, right_label, top_label in default and de locales.
i18n resources (user settings)
web/src/main/resources/org/phoenixctms/ctsms/web/user/labels*.properties
Adds user_tab_orientation labels and tooltip in default and de locales.
UI binding updates
web/src/main/webapp/course/course.xhtml, .../inputfield/inputField.xhtml, .../inventory/inventory.xhtml, .../massmail/massMail.xhtml, .../proband/proband.xhtml, .../staff/staff.xhtml, .../trial/trial.xhtml, .../user/user.xhtml
p:tabView orientation now binds to #{sessionScopeBean.tabOrientation} instead of per-view size heuristics or fixed value.
User settings UI
web/src/main/webapp/META-INF/includes/shared/userSettingsBaseInput.xhtml
Adds tabOrientation setting with inheritance toggle and select (no selection, top, left, right), messages, and tooltips.
UML profile remaps (MagicDraw/AndroMDA)
mda/src/main/uml/UML_Standard_Profile.MagicDraw_Profile.DSL_Customization.profile.uml, .../UML_Standard_Profile.StandardProfileL3.profile.uml
Namespace/ID updates and reference re-pointing; no semantic element changes.
AndroMDA service profile expansion
mda/src/main/uml/andromda-common.andromda-service.profile.uml
Adds many stereotypes/enums and updates extensions; profile metadata adjusted.
AndroMDA profiles ID/order updates
mda/src/main/uml/andromda-presentation.profile.uml, .../andromda-process.profile.uml, .../andromda-webservice.profile.uml, .../andromda-xml.profile.uml
Broad XMI id changes and some extension-end reordering; semantics unchanged.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  participant UI as JSF Page (p:tabView)
  participant SB as SessionScopeBean
  participant US as UserSettingsBeanBase
  participant Set as Settings (Bundle)
  participant DB as Database (USERS)

  rect rgba(200,230,255,0.3)
  note over UI,S B: Render tab view
  UI->>SB: getTabOrientation()
  alt Logged-in & no OTP
    SB->>DB: fetch inherited user tabOrientation
    DB-->>SB: tabOrientation or null/empty
    alt non-empty
      SB-->>UI: user tabOrientation
    else empty
      SB->>Set: get default_tab_orientation
      Set-->>SB: "top"/configured
      SB-->>UI: default orientation
    end
  else Not logged-in / OTP
    SB->>Set: get default_tab_orientation
    Set-->>SB: "top"/configured
    SB-->>UI: default orientation
  end
  end
Loading
sequenceDiagram
  autonumber
  participant User as User Settings UI
  participant USB as UserSettingsBean
  participant CU as CommonUtil/Copy Flow
  participant DB as Database (USERS)

  rect rgba(220,255,220,0.3)
  note over User,USB: Update tab orientation
  User->>USB: setTabOrientation(value)
  USB->>CU: copyUserOutToIn / createUserOutFromIn
  CU->>CU: propagate tabOrientation between in/out
  USB->>DB: persist user with TAB_ORIENTATION
  DB-->>USB: OK
  end
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Possibly related PRs

Suggested reviewers

  • fladi
  • 01hasenberger

Poem

A rabbit taps tabs, left, right, top—
With whisker-twitched, configurable hop.
New labels bloom, settings align,
Beans pass the carrot down the line.
DB learns a fresh orientation—
Hop happy, tabs in formation! 🐇✨

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ast-grep (0.38.6)
common/src/main/java/org/phoenixctms/ctsms/util/CommonUtil.java
core/src/exec/java/org/phoenixctms/ctsms/executable/DemoDataProvider.java
web/src/main/java/org/phoenixctms/ctsms/web/model/SessionScopeBean.java

Tip

🔌 Remote MCP (Model Context Protocol) integration is now available!

Pro plan users can now connect to remote MCP servers from the Integrations page. Connect with popular remote MCPs such as Notion and Linear to add more context to your reviews and chats.


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

💡 Knowledge Base configuration:

  • MCP integration is disabled by default for public repositories
  • Jira integration is disabled by default for public repositories
  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between ae63421 and 48df6dc.

📒 Files selected for processing (42)
  • common/src/main/java/org/phoenixctms/ctsms/util/CommonUtil.java (1 hunks)
  • core/db/schema-set-version.sql (1 hunks)
  • core/db/schema-up-master.sql (1 hunks)
  • core/src/exec/java/org/phoenixctms/ctsms/executable/DemoDataProvider.java (1 hunks)
  • mda/src/main/uml/UML_Standard_Profile.MagicDraw_Profile.DSL_Customization.profile.uml (7 hunks)
  • mda/src/main/uml/UML_Standard_Profile.StandardProfileL3.profile.uml (1 hunks)
  • mda/src/main/uml/andromda-common.andromda-service.profile.uml (3 hunks)
  • mda/src/main/uml/andromda-presentation.profile.uml (6 hunks)
  • mda/src/main/uml/andromda-process.profile.uml (4 hunks)
  • mda/src/main/uml/andromda-webservice.profile.uml (7 hunks)
  • mda/src/main/uml/andromda-xml.profile.uml (5 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/bundle/CourseLabels.java (1 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/bundle/FacesBundle.java (2 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/bundle/InputFieldLabels.java (1 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/bundle/InventoryLabels.java (1 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/bundle/Labels.java (1 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/bundle/MassMailLabels.java (1 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/bundle/Messages.java (1 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/bundle/ProbandLabels.java (1 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/bundle/StaffLabels.java (1 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/bundle/TrialLabels.java (1 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/bundle/UserLabels.java (1 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/model/SessionScopeBean.java (1 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/model/shared/UserSettingsBeanBase.java (4 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/model/user/UserBean.java (5 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/model/user/UserSettingsBean.java (3 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/util/DefaultSettings.java (2 hunks)
  • web/src/main/java/org/phoenixctms/ctsms/web/util/SettingCodes.java (2 hunks)
  • web/src/main/resources/org/phoenixctms/ctsms/web/labels.properties (1 hunks)
  • web/src/main/resources/org/phoenixctms/ctsms/web/labels_de.properties (1 hunks)
  • web/src/main/resources/org/phoenixctms/ctsms/web/settings.properties (2 hunks)
  • web/src/main/resources/org/phoenixctms/ctsms/web/user/labels.properties (1 hunks)
  • web/src/main/resources/org/phoenixctms/ctsms/web/user/labels_de.properties (1 hunks)
  • web/src/main/webapp/META-INF/includes/shared/userSettingsBaseInput.xhtml (1 hunks)
  • web/src/main/webapp/course/course.xhtml (1 hunks)
  • web/src/main/webapp/inputfield/inputField.xhtml (1 hunks)
  • web/src/main/webapp/inventory/inventory.xhtml (1 hunks)
  • web/src/main/webapp/massmail/massMail.xhtml (1 hunks)
  • web/src/main/webapp/proband/proband.xhtml (1 hunks)
  • web/src/main/webapp/staff/staff.xhtml (1 hunks)
  • web/src/main/webapp/trial/trial.xhtml (1 hunks)
  • web/src/main/webapp/user/user.xhtml (1 hunks)
✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch taborientation

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR/Issue comments)

Type @coderabbitai help to get the list of available commands.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Status, Documentation and Community

  • Visit our Status Page to check the current availability of CodeRabbit.
  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

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.

1 participant