Implemented new set article mechanism for unscannable articles

This commit is contained in:
Dennis Nemec
2026-01-10 20:20:28 +01:00
parent 1848f47e7f
commit 2436177c95
17 changed files with 334 additions and 46 deletions

View File

@ -0,0 +1,23 @@
import 'package:json_annotation/json_annotation.dart';
part 'set_article_amount_request.g.dart';
@JsonSerializable(fieldRename: FieldRename.snake)
class SetArticleAmountRequestDTO {
SetArticleAmountRequestDTO({
required this.articleId,
required this.deliveryId,
required this.amount,
this.reason
});
String deliveryId;
int amount;
String articleId;
String? reason;
factory SetArticleAmountRequestDTO.fromJson(Map<String, dynamic> json) =>
_$SetArticleAmountRequestDTOFromJson(json);
Map<dynamic, dynamic> toJson() => _$SetArticleAmountRequestDTOToJson(this);
}

View File

@ -0,0 +1,21 @@
import 'package:hl_lieferservice/dto/basic_response.dart';
import 'package:json_annotation/json_annotation.dart';
part 'set_article_amount_response.g.dart';
@JsonSerializable(fieldRename: FieldRename.snake)
class SetArticleAmountResponseDTO extends BasicResponseDTO {
SetArticleAmountResponseDTO({
required super.succeeded,
required super.message,
this.noteId
});
String? noteId;
factory SetArticleAmountResponseDTO.fromJson(Map<String, dynamic> json) =>
_$SetArticleAmountResponseDTOFromJson(json);
@override
Map<dynamic, dynamic> toJson() => _$SetArticleAmountResponseDTOToJson(this);
}