mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-12-09 16:25:33 +01:00
option to truncate content on /documents endpoint
This commit is contained in:
parent
1e11c12d96
commit
3c48ce0225
4 changed files with 19 additions and 2 deletions
|
|
@ -119,6 +119,9 @@ export class DocumentCardLargeComponent implements OnInit {
|
|||
}
|
||||
|
||||
get contentTrimmed() {
|
||||
return this.document.content.substr(0, 500)
|
||||
return (
|
||||
this.document.content.substr(0, 500) +
|
||||
(this.document.content.length > 500 ? '...' : '')
|
||||
)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -213,7 +213,8 @@ export class DocumentListViewService {
|
|||
this.currentPageSize,
|
||||
activeListViewState.sortField,
|
||||
activeListViewState.sortReverse,
|
||||
activeListViewState.filterRules
|
||||
activeListViewState.filterRules,
|
||||
{ truncate_content: true }
|
||||
)
|
||||
.subscribe({
|
||||
next: (result) => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue