mirror of
				https://github.com/paperless-ngx/paperless-ngx.git
				synced 2025-10-30 03:56:23 -05:00 
			
		
		
		
	Show errors on document save
This commit is contained in:
		| @@ -1411,7 +1411,7 @@ | |||||||
|         </context-group> |         </context-group> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/services/toast.service.ts</context> |           <context context-type="sourcefile">src/app/services/toast.service.ts</context> | ||||||
|           <context context-type="linenumber">32</context> |           <context context-type="linenumber">35</context> | ||||||
|         </context-group> |         </context-group> | ||||||
|       </trans-unit> |       </trans-unit> | ||||||
|       <trans-unit id="6886003843406464884" datatype="html"> |       <trans-unit id="6886003843406464884" datatype="html"> | ||||||
| @@ -2645,11 +2645,36 @@ | |||||||
|           <context context-type="linenumber">195</context> |           <context context-type="linenumber">195</context> | ||||||
|         </context-group> |         </context-group> | ||||||
|       </trans-unit> |       </trans-unit> | ||||||
|  |       <trans-unit id="5758784066858623886" datatype="html"> | ||||||
|  |         <source>Error retrieving metadata</source> | ||||||
|  |         <context-group purpose="location"> | ||||||
|  |           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> | ||||||
|  |           <context context-type="linenumber">305</context> | ||||||
|  |         </context-group> | ||||||
|  |       </trans-unit> | ||||||
|  |       <trans-unit id="2374084708811774419" datatype="html"> | ||||||
|  |         <source>Error retrieving suggestions</source> | ||||||
|  |         <context-group purpose="location"> | ||||||
|  |           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> | ||||||
|  |           <context context-type="linenumber">319</context> | ||||||
|  |         </context-group> | ||||||
|  |       </trans-unit> | ||||||
|  |       <trans-unit id="448882439049417053" datatype="html"> | ||||||
|  |         <source>Error saving document</source> | ||||||
|  |         <context-group purpose="location"> | ||||||
|  |           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> | ||||||
|  |           <context context-type="linenumber">432</context> | ||||||
|  |         </context-group> | ||||||
|  |         <context-group purpose="location"> | ||||||
|  |           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> | ||||||
|  |           <context context-type="linenumber">476</context> | ||||||
|  |         </context-group> | ||||||
|  |       </trans-unit> | ||||||
|       <trans-unit id="9021887951960049161" datatype="html"> |       <trans-unit id="9021887951960049161" datatype="html"> | ||||||
|         <source>Confirm delete</source> |         <source>Confirm delete</source> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> |           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> | ||||||
|           <context context-type="linenumber">489</context> |           <context context-type="linenumber">505</context> | ||||||
|         </context-group> |         </context-group> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/components/manage/management-list/management-list.component.ts</context> |           <context context-type="sourcefile">src/app/components/manage/management-list/management-list.component.ts</context> | ||||||
| @@ -2660,35 +2685,35 @@ | |||||||
|         <source>Do you really want to delete document "<x id="PH" equiv-text="this.document.title"/>"?</source> |         <source>Do you really want to delete document "<x id="PH" equiv-text="this.document.title"/>"?</source> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> |           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> | ||||||
|           <context context-type="linenumber">490</context> |           <context context-type="linenumber">506</context> | ||||||
|         </context-group> |         </context-group> | ||||||
|       </trans-unit> |       </trans-unit> | ||||||
|       <trans-unit id="6691075929777935948" datatype="html"> |       <trans-unit id="6691075929777935948" datatype="html"> | ||||||
|         <source>The files for this document will be deleted permanently. This operation cannot be undone.</source> |         <source>The files for this document will be deleted permanently. This operation cannot be undone.</source> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> |           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> | ||||||
|           <context context-type="linenumber">491</context> |           <context context-type="linenumber">507</context> | ||||||
|         </context-group> |         </context-group> | ||||||
|       </trans-unit> |       </trans-unit> | ||||||
|       <trans-unit id="719892092227206532" datatype="html"> |       <trans-unit id="719892092227206532" datatype="html"> | ||||||
|         <source>Delete document</source> |         <source>Delete document</source> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> |           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> | ||||||
|           <context context-type="linenumber">493</context> |           <context context-type="linenumber">509</context> | ||||||
|         </context-group> |         </context-group> | ||||||
|       </trans-unit> |       </trans-unit> | ||||||
|       <trans-unit id="1844801255494293730" datatype="html"> |       <trans-unit id="1844801255494293730" datatype="html"> | ||||||
|         <source>Error deleting document: <x id="PH" equiv-text="JSON.stringify(error)"/></source> |         <source>Error deleting document: <x id="PH" equiv-text="JSON.stringify(error)"/></source> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> |           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> | ||||||
|           <context context-type="linenumber">509</context> |           <context context-type="linenumber">525</context> | ||||||
|         </context-group> |         </context-group> | ||||||
|       </trans-unit> |       </trans-unit> | ||||||
|       <trans-unit id="7362691899087997122" datatype="html"> |       <trans-unit id="7362691899087997122" datatype="html"> | ||||||
|         <source>Redo OCR confirm</source> |         <source>Redo OCR confirm</source> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> |           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> | ||||||
|           <context context-type="linenumber">529</context> |           <context context-type="linenumber">545</context> | ||||||
|         </context-group> |         </context-group> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/components/document-list/bulk-editor/bulk-editor.component.ts</context> |           <context context-type="sourcefile">src/app/components/document-list/bulk-editor/bulk-editor.component.ts</context> | ||||||
| @@ -2699,14 +2724,14 @@ | |||||||
|         <source>This operation will permanently redo OCR for this document.</source> |         <source>This operation will permanently redo OCR for this document.</source> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> |           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> | ||||||
|           <context context-type="linenumber">530</context> |           <context context-type="linenumber">546</context> | ||||||
|         </context-group> |         </context-group> | ||||||
|       </trans-unit> |       </trans-unit> | ||||||
|       <trans-unit id="5641451190833696892" datatype="html"> |       <trans-unit id="5641451190833696892" datatype="html"> | ||||||
|         <source>This operation cannot be undone.</source> |         <source>This operation cannot be undone.</source> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> |           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> | ||||||
|           <context context-type="linenumber">531</context> |           <context context-type="linenumber">547</context> | ||||||
|         </context-group> |         </context-group> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/components/document-list/bulk-editor/bulk-editor.component.ts</context> |           <context context-type="sourcefile">src/app/components/document-list/bulk-editor/bulk-editor.component.ts</context> | ||||||
| @@ -2737,7 +2762,7 @@ | |||||||
|         <source>Proceed</source> |         <source>Proceed</source> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> |           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> | ||||||
|           <context context-type="linenumber">533</context> |           <context context-type="linenumber">549</context> | ||||||
|         </context-group> |         </context-group> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/components/document-list/bulk-editor/bulk-editor.component.ts</context> |           <context context-type="sourcefile">src/app/components/document-list/bulk-editor/bulk-editor.component.ts</context> | ||||||
| @@ -2764,7 +2789,7 @@ | |||||||
|         <source>Redo OCR operation will begin in the background. Close and re-open or reload this document after the operation has completed to see new content.</source> |         <source>Redo OCR operation will begin in the background. Close and re-open or reload this document after the operation has completed to see new content.</source> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> |           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> | ||||||
|           <context context-type="linenumber">541</context> |           <context context-type="linenumber">557</context> | ||||||
|         </context-group> |         </context-group> | ||||||
|       </trans-unit> |       </trans-unit> | ||||||
|       <trans-unit id="8008978164775353960" datatype="html"> |       <trans-unit id="8008978164775353960" datatype="html"> | ||||||
| @@ -2773,7 +2798,7 @@ | |||||||
|               )"/></source> |               )"/></source> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> |           <context context-type="sourcefile">src/app/components/document-detail/document-detail.component.ts</context> | ||||||
|           <context context-type="linenumber">552,554</context> |           <context context-type="linenumber">568,570</context> | ||||||
|         </context-group> |         </context-group> | ||||||
|       </trans-unit> |       </trans-unit> | ||||||
|       <trans-unit id="6857598786757174736" datatype="html"> |       <trans-unit id="6857598786757174736" datatype="html"> | ||||||
| @@ -4991,7 +5016,7 @@ | |||||||
|         <source>Information</source> |         <source>Information</source> | ||||||
|         <context-group purpose="location"> |         <context-group purpose="location"> | ||||||
|           <context context-type="sourcefile">src/app/services/toast.service.ts</context> |           <context context-type="sourcefile">src/app/services/toast.service.ts</context> | ||||||
|           <context context-type="linenumber">36</context> |           <context context-type="linenumber">43</context> | ||||||
|         </context-group> |         </context-group> | ||||||
|       </trans-unit> |       </trans-unit> | ||||||
|       <trans-unit id="3852289441366561594" datatype="html"> |       <trans-unit id="3852289441366561594" datatype="html"> | ||||||
|   | |||||||
| @@ -301,6 +301,9 @@ export class DocumentDetailComponent | |||||||
|         }, |         }, | ||||||
|         error: (error) => { |         error: (error) => { | ||||||
|           this.metadata = null |           this.metadata = null | ||||||
|  |           this.toastService.showError( | ||||||
|  |             $localize`Error retrieving metadata` + ': ' + error.toString() | ||||||
|  |           ) | ||||||
|         }, |         }, | ||||||
|       }) |       }) | ||||||
|     this.documentsService |     this.documentsService | ||||||
| @@ -312,6 +315,9 @@ export class DocumentDetailComponent | |||||||
|         }, |         }, | ||||||
|         error: (error) => { |         error: (error) => { | ||||||
|           this.suggestions = null |           this.suggestions = null | ||||||
|  |           this.toastService.showError( | ||||||
|  |             $localize`Error retrieving suggestions` + ': ' + error.toString() | ||||||
|  |           ) | ||||||
|         }, |         }, | ||||||
|       }) |       }) | ||||||
|     this.title = this.documentTitlePipe.transform(doc.title) |     this.title = this.documentTitlePipe.transform(doc.title) | ||||||
| @@ -422,6 +428,11 @@ export class DocumentDetailComponent | |||||||
|         error: (error) => { |         error: (error) => { | ||||||
|           this.networkActive = false |           this.networkActive = false | ||||||
|           this.error = error.error |           this.error = error.error | ||||||
|  |           this.toastService.showError( | ||||||
|  |             $localize`Error saving document` + | ||||||
|  |               ': ' + | ||||||
|  |               (error.message ?? error.toString()) | ||||||
|  |           ) | ||||||
|         }, |         }, | ||||||
|       }) |       }) | ||||||
|   } |   } | ||||||
| @@ -461,6 +472,11 @@ export class DocumentDetailComponent | |||||||
|         error: (error) => { |         error: (error) => { | ||||||
|           this.networkActive = false |           this.networkActive = false | ||||||
|           this.error = error.error |           this.error = error.error | ||||||
|  |           this.toastService.showError( | ||||||
|  |             $localize`Error saving document` + | ||||||
|  |               ': ' + | ||||||
|  |               (error.message ?? error.toString()) | ||||||
|  |           ) | ||||||
|         }, |         }, | ||||||
|       }) |       }) | ||||||
|   } |   } | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 shamoon
					shamoon