[IMP] dms: UX modernisation (kanban density + dashboard + side-pane preview + form heroes + portal grid + test coverage)#3
Open
dnplkndll wants to merge 184 commits into
Open
[IMP] dms: UX modernisation (kanban density + dashboard + side-pane preview + form heroes + portal grid + test coverage)#3dnplkndll wants to merge 184 commits into
dnplkndll wants to merge 184 commits into
Conversation
versions of muk_dms than 12.0.2.0.0. Tested from 1.2.4 version.
In v13, this test is programmed in such a way that the demo user is supposed to be able to copy that subdirectory: https://github.com/OCA/dms/blob/c3f802db43362127e70d8c7b4987fb71d4c1f01c/dms/tests/test_directory.py#L40 However, in OCA#7 that test was modified indicating that demo user didn't have permissions to do that: https://github.com/OCA/dms/blob/e3b6d8d24534f2a68bfb88e310cc70cefe46bb64/dms/tests/test_directory.py#L39 Rolling back that change to ensure premissions remain the same in both versions of the module. Also changing the directory to test to ensure it contains no SVG files, whose detection seems to differ among environments, and which have some specific permission restrictions that can make the modified test fail or pass. @Tecnativa TT25645
beb9548 to
cbef9f5
Compare
49b0325 to
4537378
Compare
4537378 to
35f61e8
Compare
35f61e8 to
9929ce9
Compare
…view, form heroes, portal) Backend (web) modernisation of the DMS file + directory views, layered on the 19.0 migration: - File kanban: comfortable/compact/list density tiers (persisted via a useStoredState hook), extension-accent file-type icons, directory-path subtitles, rounded author avatars, and inline quick-rename (double-click the name → Enter/Esc). - Directory kanban: a three-tile dashboard stat bar (files, storage, new-today) with inline sparklines, backed by get_dashboard_stats. - Side-pane preview: a split list/kanban + preview layout with a registry-based handler dispatch (image/pdf/text/markdown/video/audio + download fallback, with an extension→mimetype fallback for generic octet-stream). The pane has Preview / Details / Activity tabs — Details shows file metadata + tags, Activity mounts the standard chatter (messages, log notes, activities) since dms.file is a mail.thread. It refreshes in place when the on-screen record is renamed. - Form heroes for dms.file / dms.directory and a portal document grid. - Shared OWL hooks (useStoredState, useDmsPreviewState) for sibling reuse. 19.0 / OWL-forward conventions observed throughout: no owl event or ref directives in ir.ui.view arch (interactive UI lives in registered components / a dms_file_name view widget), t-out over t-esc, and this.-prefixed handler expressions in OWL templates.
…iles - Kanban now marks the file open in the side-pane preview with a primary rail + tint (o_dms_preview_selected_card), mirroring the list view's selected-row accent so the card↔pane mapping stays legible across densities. FileKanbanRecord.getRecordClasses() reads the reactive selectedId exposed on the dmsKanbanPreview env. - Directory dashboard stat tiles are now drill-downs (the native Odoo dashboard interaction): "Files" opens the file list, "New today" opens files created since local midnight; "Storage" stays display-only. DmsStatBar gains an onTileClick prop + clickable affordance.
d45c7a9 to
41843a7
Compare
…icon header, tighter comfortable cards - List view: remove the "Type" column (the Name column's extension-colored icon already conveys it; mimetype stays available via the optional column picker), reclaiming width. - Preview Details tab: lead with the file's icon/thumbnail (icon_url) + name as a visual anchor, matching Odoo's info-panel convention. - Comfortable kanban density: trim card padding/gap + thumb size so more cards fit without losing the comfortable feel (compact/list untouched).
41843a7 to
fec90a4
Compare
.eml files (stored as text/plain) routed to the raw-text iframe, showing
RFC822 source. Add an EmlPreview handler that parses the top-level headers
into a From/To/Subject/Date card and renders the best body part (HTML
preferred, else plain text) in a sandboxed iframe; handles single +
multipart/{mixed,alternative,related} with base64 / quoted-printable. The
pane remaps the .eml extension to message/rfc822 so the handler wins.
…coercion, sort-imports, regex)
b628ef8 to
171bd86
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Comprehensive UX modernisation of OCA
dmsfor 19.0, stacked on top of the in-flight OCA/dms#475 MIG. Fork-only — exists for runboat preview + stakeholder review while we iterate. Subsets will be split into focused upstream PRs once OCA#475 lands and the 19.0.1.0.0 wheel publishes.Base:
19.0-mig-dms· Head:19.0-imp-dms-ux· Stacked under #9 (Hoot tests), #7 (CI), and #8 (libreoffice preview).What the branch changes
comfortable/compact/list) with a floating toggle, per-density layout, selection persisted to localStorage._read_groupon indexedcreate_date(no snapshot table, no cron).registry.category("dms.preview_handlers"). Built-in handlers: image, PDF, audio, video, text, markdown, office-fallback, download-fallback. Score-based dispatch — sibling modules register at higher scores to override.useExternalListenerreplaces pairedonMounted/onWillUnmount; static class fields replace OWL 1 prototype assignments; booleant-att-*coerced to explicit'true'/'false'strings (U5); deadfile_kanban_controllerdeleted (U7).lg(991.98px).Architecture notes for reviewers
dms/static/src/js/components/preview/preview_registry.esm.js— each handler is{component, match, score}; catch-all download handler runs at-100so any registered handler wins.application/octet-stream(several MP4 variants),_effectiveMimetype()infile_preview_pane.esm.jsfalls back to a 25+ extension table.text/markdownin a sandboxed<iframe srcdoc>. XSS-safe via HTML escape + link-protocol allowlist.Preview
https://ledoent-dms-19-0-imp-dms-ux-pr3-<sha>.runboat.hz.ledoweb.comCI
GitHub Actions on the
ledoentorg is currently throttled by Actions abuse-detection. Runboat preview builds pass; local--test-enablepasses. See #7 for the CI-side observability work.