mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-05-25 13:08:21 -05:00
Fix some small frontend things
This commit is contained in:
parent
2c05247d84
commit
8454182c72
@ -4769,14 +4769,14 @@
|
||||
<source>Create new workflow</source>
|
||||
<context-group purpose="location">
|
||||
<context context-type="sourcefile">src/app/components/common/edit-dialog/workflow-edit-dialog/workflow-edit-dialog.component.ts</context>
|
||||
<context context-type="linenumber">166</context>
|
||||
<context context-type="linenumber">172</context>
|
||||
</context-group>
|
||||
</trans-unit>
|
||||
<trans-unit id="5996779210524133604" datatype="html">
|
||||
<source>Edit workflow</source>
|
||||
<context-group purpose="location">
|
||||
<context context-type="sourcefile">src/app/components/common/edit-dialog/workflow-edit-dialog/workflow-edit-dialog.component.ts</context>
|
||||
<context context-type="linenumber">170</context>
|
||||
<context context-type="linenumber">176</context>
|
||||
</context-group>
|
||||
</trans-unit>
|
||||
<trans-unit id="6381578200008167206" datatype="html">
|
||||
|
@ -123,7 +123,7 @@
|
||||
<p class="small" i18n>Set scheduled trigger offset and which field to use.</p>
|
||||
<div class="row">
|
||||
<div class="col-4">
|
||||
<pngx-input-number i18n-title title="Offset" formControlName="schedule_offset_days" i18n-hint hint="Offset in days. Use 0 for immediate." [error]="error?.schedule_offset_days"></pngx-input-number>
|
||||
<pngx-input-number i18n-title title="Offset" formControlName="schedule_offset_days" i18n-hint hint="Offset in days. Use 0 for immediate." [showAdd]="false" [error]="error?.schedule_offset_days"></pngx-input-number>
|
||||
<pngx-input-check i18n-title title="Repeat" formControlName="schedule_is_recurring" i18n-hint hint="Repeat the trigger after the delay." [error]="error?.schedule_is_recurring"></pngx-input-check>
|
||||
</div>
|
||||
<div class="col-4">
|
||||
|
@ -120,6 +120,7 @@ export class WorkflowEditDialogComponent
|
||||
storagePaths: StoragePath[]
|
||||
mailRules: MailRule[]
|
||||
customFields: CustomField[]
|
||||
dateCustomFields: CustomField[]
|
||||
|
||||
expandedItem: number = null
|
||||
|
||||
@ -159,7 +160,12 @@ export class WorkflowEditDialogComponent
|
||||
customFieldsService
|
||||
.listAll()
|
||||
.pipe(first())
|
||||
.subscribe((result) => (this.customFields = result.results))
|
||||
.subscribe((result) => {
|
||||
this.customFields = result.results
|
||||
this.dateCustomFields = this.customFields?.filter(
|
||||
(f) => f.data_type === CustomFieldDataType.Date
|
||||
)
|
||||
})
|
||||
}
|
||||
|
||||
getCreateTitle() {
|
||||
@ -422,12 +428,6 @@ export class WorkflowEditDialogComponent
|
||||
return SCHEDULE_DATE_FIELD_OPTIONS
|
||||
}
|
||||
|
||||
get dateCustomFields() {
|
||||
return this.customFields?.filter(
|
||||
(f) => f.data_type === CustomFieldDataType.Date
|
||||
)
|
||||
}
|
||||
|
||||
getTriggerTypeOptionName(type: WorkflowTriggerType): string {
|
||||
return this.triggerTypeOptions.find((t) => t.id === type)?.name ?? ''
|
||||
}
|
||||
@ -448,7 +448,7 @@ export class WorkflowEditDialogComponent
|
||||
matching_algorithm: MATCH_NONE,
|
||||
match: '',
|
||||
is_insensitive: true,
|
||||
schedule_offset_days: null,
|
||||
schedule_offset_days: 0,
|
||||
schedule_is_recurring: false,
|
||||
schedule_date_field: ScheduleDateField.Added,
|
||||
schedule_date_custom_field: null,
|
||||
|
Loading…
x
Reference in New Issue
Block a user