mirror of
https://github.com/Xevion/paperless-mobile.git
synced 2025-12-15 04:12:30 -06:00
feat: Make label fields less restrictive, improve change detection in document edit page
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import 'package:equatable/equatable.dart';
|
||||
import 'package:json_annotation/json_annotation.dart';
|
||||
import 'package:paperless_api/src/converters/local_date_time_json_converter.dart';
|
||||
import 'package:paperless_api/src/models/document_model.dart';
|
||||
@@ -6,7 +7,7 @@ part 'field_suggestions.g.dart';
|
||||
|
||||
@LocalDateTimeJsonConverter()
|
||||
@JsonSerializable(fieldRename: FieldRename.snake)
|
||||
class FieldSuggestions {
|
||||
class FieldSuggestions with EquatableMixin {
|
||||
final int? documentId;
|
||||
final Iterable<int> correspondents;
|
||||
final Iterable<int> tags;
|
||||
@@ -95,4 +96,13 @@ class FieldSuggestions {
|
||||
_$FieldSuggestionsFromJson(json);
|
||||
|
||||
Map<String, dynamic> toJson() => _$FieldSuggestionsToJson(this);
|
||||
|
||||
@override
|
||||
List<Object?> get props => [
|
||||
documentId,
|
||||
correspondents,
|
||||
tags,
|
||||
documentTypes,
|
||||
dates,
|
||||
];
|
||||
}
|
||||
|
||||
@@ -203,7 +203,7 @@ class StoragePath extends Label {
|
||||
const StoragePath({
|
||||
super.id,
|
||||
required super.name,
|
||||
required this.path,
|
||||
this.path = '',
|
||||
super.slug,
|
||||
super.match,
|
||||
super.matchingAlgorithm,
|
||||
|
||||
Reference in New Issue
Block a user