mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2026-11-03 21:39:22 +00:00
22 lines
597 B
TypeScript
22 lines
597 B
TypeScript
import { Injectable } from '@angular/core'
|
|
import { Observable } from 'rxjs'
|
|
import { StoragePath } from 'src/app/data/storage-path'
|
|
import { AbstractNameFilterService } from './abstract-name-filter-service'
|
|
|
|
@Injectable({
|
|
providedIn: 'root',
|
|
})
|
|
export class StoragePathService extends AbstractNameFilterService<StoragePath> {
|
|
constructor() {
|
|
super()
|
|
this.resourceName = 'storage_paths'
|
|
}
|
|
|
|
public testPath(path: string, documentID: number): Observable<any> {
|
|
return this.http.post<string>(`${this.getResourceUrl()}test/`, {
|
|
path,
|
|
document: documentID,
|
|
})
|
|
}
|
|
}
|