{{(document.correspondent$ | async)?.name}}:
diff --git a/src-ui/src/app/components/document-list/document-card-small/document-card-small.component.scss b/src-ui/src/app/components/document-list/document-card-small/document-card-small.component.scss
index f64c3f112..9affa52ec 100644
--- a/src-ui/src/app/components/document-list/document-card-small/document-card-small.component.scss
+++ b/src-ui/src/app/components/document-list/document-card-small/document-card-small.component.scss
@@ -5,7 +5,7 @@
.doc-img {
object-fit: cover;
object-position: top left;
- height: 175px;
+ height: 180px;
mix-blend-mode: multiply;
}
@@ -34,6 +34,12 @@
display: block;
}
+.document-card-notes {
+ position: absolute;
+ right: 0;
+ top: 142px;
+}
+
.card-selected {
border-color:var(--bs-primary);
@@ -58,12 +64,6 @@
color: var(--bs-primary);
}
}
-
- .metadata-icon {
- width: 0.9rem;
- height: 0.9rem;
- padding: 0.05rem;
- }
}
.card-footer .btn {
diff --git a/src-ui/src/app/components/document-list/document-card-small/document-card-small.component.ts b/src-ui/src/app/components/document-list/document-card-small/document-card-small.component.ts
index 0aa7bd758..28b354154 100644
--- a/src-ui/src/app/components/document-list/document-card-small/document-card-small.component.ts
+++ b/src-ui/src/app/components/document-list/document-card-small/document-card-small.component.ts
@@ -74,11 +74,12 @@ export class DocumentCardSmallComponent extends ComponentWithPermissions {
}
getTagsLimited$() {
+ const limit = this.document.notes.length > 0 ? 6 : 7
return this.document.tags$.pipe(
map((tags) => {
- if (tags.length > 7) {
- this.moreTags = tags.length - 6
- return tags.slice(0, 6)
+ if (tags.length > limit) {
+ this.moreTags = tags.length - (limit - 1)
+ return tags.slice(0, limit - 1)
} else {
return tags
}
@@ -110,4 +111,8 @@ export class DocumentCardSmallComponent extends ComponentWithPermissions {
mouseLeaveCard() {
this.popover.close()
}
+
+ get notesEnabled(): boolean {
+ return this.settingsService.get(SETTINGS_KEYS.NOTES_ENABLED)
+ }
}
diff --git a/src-ui/src/app/components/document-list/document-list.component.html b/src-ui/src/app/components/document-list/document-list.component.html
index 25a75c1b6..70ff168f6 100644
--- a/src-ui/src/app/components/document-list/document-list.component.html
+++ b/src-ui/src/app/components/document-list/document-list.component.html
@@ -139,6 +139,12 @@
[currentSortReverse]="list.sortReverse"
(sort)="onSort($event)"
i18n>Title
+ Notes |
{{d.title | documentTitle}}
+ |
+
+
+
+ {{d.notes.length}}
+
+ |
{{(d.document_type$ | async)?.name}}
diff --git a/src-ui/src/app/components/document-list/document-list.component.ts b/src-ui/src/app/components/document-list/document-list.component.ts
index d4a654444..7847097bc 100644
--- a/src-ui/src/app/components/document-list/document-list.component.ts
+++ b/src-ui/src/app/components/document-list/document-list.component.ts
@@ -17,6 +17,7 @@ import {
import { FILTER_FULLTEXT_MORELIKE } from 'src/app/data/filter-rule-type'
import { PaperlessDocument } from 'src/app/data/paperless-document'
import { PaperlessSavedView } from 'src/app/data/paperless-saved-view'
+import { SETTINGS_KEYS } from 'src/app/data/paperless-uisettings'
import {
SortableDirective,
SortEvent,
@@ -29,6 +30,7 @@ import {
DOCUMENT_SORT_FIELDS_FULLTEXT,
} from 'src/app/services/rest/document.service'
import { SavedViewService } from 'src/app/services/rest/saved-view.service'
+import { SettingsService } from 'src/app/services/settings.service'
import { ToastService } from 'src/app/services/toast.service'
import { ComponentWithPermissions } from '../with-permissions/with-permissions.component'
import { FilterEditorComponent } from './filter-editor/filter-editor.component'
@@ -51,7 +53,8 @@ export class DocumentListComponent
private toastService: ToastService,
private modalService: NgbModal,
private consumerStatusService: ConsumerStatusService,
- public openDocumentsService: OpenDocumentsService
+ public openDocumentsService: OpenDocumentsService,
+ private settingsService: SettingsService
) {
super()
}
@@ -289,4 +292,8 @@ export class DocumentListComponent
trackByDocumentId(index, item: PaperlessDocument) {
return item.id
}
+
+ get notesEnabled(): boolean {
+ return this.settingsService.get(SETTINGS_KEYS.NOTES_ENABLED)
+ }
}
diff --git a/src-ui/src/app/components/document-comments/document-comments.component.html b/src-ui/src/app/components/document-notes/document-notes.component.html
similarity index 51%
rename from src-ui/src/app/components/document-comments/document-comments.component.html
rename to src-ui/src/app/components/document-notes/document-notes.component.html
index 576f46d79..f6c46cd47 100644
--- a/src-ui/src/app/components/document-comments/document-comments.component.html
+++ b/src-ui/src/app/components/document-notes/document-notes.component.html
@@ -1,27 +1,28 @@
- |