TenvioOrder class abstract

Available extensions
Annotations
  • @freezed

Constructors

TenvioOrder({required String id, required String ownerId, required Asset warehouse, required String warehouseId, String? qrCode, @TenvioOrderStatusConverter() required TenvioOrderStatus status, @TenvioDestinationTypeOrNullConverter() TenvioDestinationType? destinationType, Asset? destinationWarehouse, String? destinationWarehouseId, User? destinationUser, String? destinationUserId, TenvioUnregisteredUser? destinationUnregistered, @Default.new([]) List<String> notes, bool? requiresPhotos, bool? highPriority, List<User>? packers, List<String>? packersIds, List<TenvioItemQuantity>? itemQuantities, List<TenvioItem>? items, String? packedImage, List<TenvioPhotos>? statusPhotos, @TimestampOrNullConverter() DateTime? createdAt, @TimestampOrNullConverter() DateTime? updatedAt})
const
factory
TenvioOrder.fromJson(Map<String, dynamic> json)
factory

Properties

copyWith → $TenvioOrderCopyWith<TenvioOrder>
Create a copy of TenvioOrder with the given fields replaced by the non-null parameter values.
no setterinherited
createdAt DateTime?
createdAt Creation date of the order.
no setterinherited
destinationType TenvioDestinationType?
destinationType Type of the destination.
no setterinherited
destinationUnregistered TenvioUnregisteredUser?
destinationUnregisteredUser Unregistered user destination of the order.
no setterinherited
destinationUser User?
destinationUser User destination of the order.
no setterinherited
destinationUserId String?
destinationUserId ID of the user destination of the order.
no setterinherited
destinationWarehouse Asset?
destinationWarehouse Warehouse destination of the order.
no setterinherited
destinationWarehouseId String?
destinationWarehouseId ID of the warehouse destination of the order.
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
highPriority bool?
highhighPriority High priority indicator.
no setterinherited
id String
id ID of the order entity. This ID is unique along the system.
no setterinherited
itemQuantities List<TenvioItemQuantity>?
itemQuantities Items included in the order.
no setterinherited
items List<TenvioItem>?
items Items included in the order.
no setterinherited
notes List<String>
notes Notes of the order entity.
no setterinherited
orderId String
no setter
ownerId String
ownerId ID of the owner of the order.
no setterinherited
packedImage String?
packedImage URL of the packed image.
no setterinherited
packers List<User>?
packers Packers assigned to the order.
no setterinherited
packersIds List<String>?
packersIds IDs of packers assigned to the order.
no setterinherited
qrCode String?
qrCode is the QR code of the order. should contains the following URI: tenvio://orders/:id
no setterinherited
requiresPhotos bool?
requiresImages Requires images indicator.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
status TenvioOrderStatus
status Status of the order entity.
no setterinherited
statusPhotos List<TenvioPhotos>?
statusPhotos Status photos of the order.
no setterinherited
updatedAt DateTime?
updatedAt Last update date of the order.
no setterinherited
warehouse Asset
warehouse where the order is located.
no setterinherited
warehouseId String
warehouseId ID of the warehouse where the order is located.
no setterinherited

Methods

map<TResult extends Object?>(TResult $default(_TenvioOrder value)) → TResult

Available on TenvioOrder, provided by the TenvioOrderPatterns extension

A switch-like method, using callbacks.
mapOrNull<TResult extends Object?>(TResult? $default(_TenvioOrder value)?) → TResult?

Available on TenvioOrder, provided by the TenvioOrderPatterns extension

A variant of map that fallback to returning null.
maybeMap<TResult extends Object?>(TResult $default(_TenvioOrder value)?, {required TResult orElse()}) → TResult

Available on TenvioOrder, provided by the TenvioOrderPatterns extension

A variant of map that fallback to returning orElse.
maybeWhen<TResult extends Object?>(TResult $default(String id, String ownerId, Asset warehouse, String warehouseId, String? qrCode, TenvioOrderStatus status, TenvioDestinationType? destinationType, Asset? destinationWarehouse, String? destinationWarehouseId, User? destinationUser, String? destinationUserId, TenvioUnregisteredUser? destinationUnregistered, List<String> notes, bool? requiresPhotos, bool? highPriority, List<User>? packers, List<String>? packersIds, List<TenvioItemQuantity>? itemQuantities, List<TenvioItem>? items, String? packedImage, List<TenvioPhotos>? statusPhotos, DateTime? createdAt, DateTime? updatedAt)?, {required TResult orElse()}) → TResult

Available on TenvioOrder, provided by the TenvioOrderPatterns extension

A variant of when that fallback to an orElse callback.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Serializes this TenvioOrder to a JSON map.
inherited
toString() String
A string representation of this object.
inherited
when<TResult extends Object?>(TResult $default(String id, String ownerId, Asset warehouse, String warehouseId, String? qrCode, TenvioOrderStatus status, TenvioDestinationType? destinationType, Asset? destinationWarehouse, String? destinationWarehouseId, User? destinationUser, String? destinationUserId, TenvioUnregisteredUser? destinationUnregistered, List<String> notes, bool? requiresPhotos, bool? highPriority, List<User>? packers, List<String>? packersIds, List<TenvioItemQuantity>? itemQuantities, List<TenvioItem>? items, String? packedImage, List<TenvioPhotos>? statusPhotos, DateTime? createdAt, DateTime? updatedAt)) → TResult

Available on TenvioOrder, provided by the TenvioOrderPatterns extension

A switch-like method, using callbacks.
whenOrNull<TResult extends Object?>(TResult? $default(String id, String ownerId, Asset warehouse, String warehouseId, String? qrCode, TenvioOrderStatus status, TenvioDestinationType? destinationType, Asset? destinationWarehouse, String? destinationWarehouseId, User? destinationUser, String? destinationUserId, TenvioUnregisteredUser? destinationUnregistered, List<String> notes, bool? requiresPhotos, bool? highPriority, List<User>? packers, List<String>? packersIds, List<TenvioItemQuantity>? itemQuantities, List<TenvioItem>? items, String? packedImage, List<TenvioPhotos>? statusPhotos, DateTime? createdAt, DateTime? updatedAt)?) → TResult?

Available on TenvioOrder, provided by the TenvioOrderPatterns extension

A variant of when that fallback to returning null

Operators

operator ==(Object other) bool
The equality operator.
inherited