Skip to content

Commit 4fe0686

Browse files
committed
Merge branch 'development' of github.com:goldenm-software/layrz_models into development
2 parents f17b911 + c06f58f commit 4fe0686

9 files changed

Lines changed: 569 additions & 131 deletions

File tree

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@
33
## 3.8.8
44

55
- Fixed `casesMonitorConfig` type in `Workspace` model to be a list of nullable `CaseMonitorCard?` instead of non-nullable `CaseMonitorCard`.
6+
- Added `AtsMdfe` model
7+
- Added `mdfeId`, `mdfe` and `mdfes` values in `AtsOperation` model
8+
- Added default values to `StockClosingInput` model
9+
- Added `ATS_INVOICE_SWAP` value in `ReferenceCategory` enum
610

711
## 3.8.7
812

lib/src/ats/ats.dart

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ part 'src/entries/entry_input.dart';
5151
// ATS Operations Models
5252
part 'src/operations/operation.dart';
5353
part 'src/operations/status.dart';
54+
part 'src/operations/ats_mdfe.dart';
5455

5556
// ATS Converters
5657
part 'src/converters/order_status.dart';

lib/src/ats/ats.freezed.dart

Lines changed: 444 additions & 87 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/src/ats/ats.g.dart

Lines changed: 65 additions & 33 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
part of '../../ats.dart';
2+
3+
/// A model class representing a ats mdfe entity.
4+
@freezed
5+
abstract class AtsMdfe with _$AtsMdfe {
6+
/// Creates a new [AtsMdfe] instance.
7+
factory AtsMdfe({
8+
/// The [id] parameter is the id of the ats mdfe entity.
9+
String? id,
10+
11+
/// The [manifestId] parameter is the manifestId of the ats mdfe entity.
12+
String? manifestId,
13+
14+
/// The [createdAt] parameter is the createdAt of the ats mdfe entity.
15+
@TimestampOrNullConverter() DateTime? createdAt,
16+
17+
/// The [updatedAt] parameter is the updatedAt of the ats mdfe entity.
18+
@TimestampOrNullConverter() DateTime? updatedAt,
19+
20+
/// The [operation] parameter is the operation of the ats mdfe entity.
21+
AtsOperation? operation,
22+
}) = _AtsMdfe;
23+
24+
/// Creates a new [AtsMdfe] instance from a JSON map.
25+
///
26+
/// The [json] parameter is the JSON map to create the instance from.
27+
factory AtsMdfe.fromJson(Map<String, dynamic> json) => _$AtsMdfeFromJson(json);
28+
}

lib/src/ats/src/operations/operation.dart

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,15 @@ abstract class AtsOperation with _$AtsOperation {
117117

118118
/// [terminalExitAt] is the timestamp of the terminal exit.
119119
@TimestampOrNullConverter() DateTime? terminalExitAt,
120+
121+
/// [mdfeId] is the ID of the MDF-e linked to the operation.
122+
String? mdfeId,
123+
124+
/// [mdfe] is the MDF-e linked to the operation.
125+
AtsMdfe? mdfe,
126+
127+
/// [mdfes] is the list of MDF-e linked to the operation.
128+
List<AtsMdfe>? mdfes,
120129
}) = _AtsOperation;
121130

122131
factory AtsOperation.fromJson(Map<String, dynamic> json) => _$AtsOperationFromJson(json);

lib/src/ats/src/stock_closing/input/stock_closing_input.dart

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -19,37 +19,37 @@ abstract class StockClosingInput with _$StockClosingInput {
1919
String? description,
2020

2121
/// The [totalVolume20] parameter is the totalVolume20 of the stock closing input.
22-
double? totalVolume20,
22+
@Default(0.0) double totalVolume20,
2323

2424
/// The [volume20Difference] parameter is the volume20Difference of the stock closing input.
25-
double? volume20Difference,
25+
@Default(0.0) double volume20Difference,
2626

2727
/// The [accountingVolumeDifference] parameter is the accountingVolumeDifference of the stock closing input.
28-
double? accountingVolumeDifference,
28+
@Default(0.0) double accountingVolumeDifference,
2929

3030
/// The [openingBalance20] parameter is the openingBalance20 of the stock closing input.
31-
double? openingBalance20,
31+
@Default(0.0) double openingBalance20,
3232

3333
/// The [totalEntries20] parameter is the totalEntries20 of the stock closing input.
34-
double? totalEntries20,
34+
@Default(0.0) double totalEntries20,
3535

3636
/// The [totalWithdrawals20] parameter is the totalWithdrawals20 of the stock closing input.
37-
double? totalWithdrawals20,
37+
@Default(0.0) double totalWithdrawals20,
3838

3939
/// The [closingBalance20] parameter is the closingBalance20 of the stock closing input.
40-
double? closingBalance20,
40+
@Default(0.0) double closingBalance20,
4141

4242
/// The [openingAccountingBalance] parameter is the openingAccountingBalance of the stock closing input.
43-
double? openingAccountingBalance,
43+
@Default(0.0) double openingAccountingBalance,
4444

4545
/// The [totalAccountingEntries] parameter is the totalAccountingEntries of the stock closing input.
46-
double? totalAccountingEntries,
46+
@Default(0.0) double totalAccountingEntries,
4747

4848
/// The [totalAccountingWithdrawals] parameter is the totalAccountingWithdrawals of the stock closing input.
49-
double? totalAccountingWithdrawals,
49+
@Default(0.0) double totalAccountingWithdrawals,
5050

5151
/// The [closingAccountingBalance] parameter is the closingAccountingBalance of the stock closing input.
52-
double? closingAccountingBalance,
52+
@Default(0.0) double closingAccountingBalance,
5353

5454
/// The [closingDetails] parameter is the closingDetails of the stock closing input.
5555
@Default([]) List<StockClosingTankInput> closingDetails,

lib/src/references/references.g.dart

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/src/references/src/category.dart

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -282,6 +282,12 @@ enum ReferenceCategory {
282282
/// Layrz API Reference: ATS_STORAGE_RECEPTION_ACCESS
283283
atsStorageReceptionAccess,
284284

285+
/// !ATS Reference
286+
/// [AllTank Systems] Access to swap invoice in purchase order
287+
/// Layrz API Reference: ATS_INVOICE_SWAP
288+
@JsonValue('ATS_INVOICE_SWAP')
289+
atsInvoiceSwap,
290+
285291
/// !Mappit Reference
286292
/// Defines the access to the Mappit module as a operator or mappit employee
287293
/// Layrz API Reference: MAPPIT_OPERATOR

0 commit comments

Comments
 (0)