chore(app): сгенерированный Dart-клиент
just gen-client — покрывает links, cashflow-broker, ручные цены, imports/pending, goals/income/rebalance/tax/benchmarks.
This commit is contained in:
@@ -0,0 +1,205 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
|
||||
// ignore_for_file: unused_element
|
||||
import 'package:copy_with_extension/copy_with_extension.dart';
|
||||
import 'package:json_annotation/json_annotation.dart';
|
||||
|
||||
part 'trade_out.g.dart';
|
||||
|
||||
|
||||
@CopyWith()
|
||||
@JsonSerializable(
|
||||
checked: true,
|
||||
createToJson: true,
|
||||
disallowUnrecognizedKeys: false,
|
||||
explicitToJson: true,
|
||||
)
|
||||
class TradeOut {
|
||||
/// Returns a new [TradeOut] instance.
|
||||
TradeOut({
|
||||
|
||||
required this.action,
|
||||
|
||||
required this.amountRub,
|
||||
|
||||
required this.blockedByCash,
|
||||
|
||||
required this.instrumentId,
|
||||
|
||||
required this.lot,
|
||||
|
||||
required this.name,
|
||||
|
||||
required this.price,
|
||||
|
||||
required this.priceCurrency,
|
||||
|
||||
required this.suggestedQty,
|
||||
|
||||
required this.ticker,
|
||||
});
|
||||
|
||||
@JsonKey(
|
||||
|
||||
name: r'action',
|
||||
required: true,
|
||||
includeIfNull: false,
|
||||
)
|
||||
|
||||
|
||||
final String action;
|
||||
|
||||
|
||||
|
||||
/// decimal as string
|
||||
@JsonKey(
|
||||
|
||||
name: r'amount_rub',
|
||||
required: true,
|
||||
includeIfNull: false,
|
||||
)
|
||||
|
||||
|
||||
final String amountRub;
|
||||
|
||||
|
||||
|
||||
@JsonKey(
|
||||
|
||||
name: r'blocked_by_cash',
|
||||
required: true,
|
||||
includeIfNull: false,
|
||||
)
|
||||
|
||||
|
||||
final bool blockedByCash;
|
||||
|
||||
|
||||
|
||||
@JsonKey(
|
||||
|
||||
name: r'instrument_id',
|
||||
required: true,
|
||||
includeIfNull: false,
|
||||
)
|
||||
|
||||
|
||||
final int instrumentId;
|
||||
|
||||
|
||||
|
||||
@JsonKey(
|
||||
|
||||
name: r'lot',
|
||||
required: true,
|
||||
includeIfNull: true,
|
||||
)
|
||||
|
||||
|
||||
final int? lot;
|
||||
|
||||
|
||||
|
||||
@JsonKey(
|
||||
|
||||
name: r'name',
|
||||
required: true,
|
||||
includeIfNull: false,
|
||||
)
|
||||
|
||||
|
||||
final String name;
|
||||
|
||||
|
||||
|
||||
/// decimal as string
|
||||
@JsonKey(
|
||||
|
||||
name: r'price',
|
||||
required: true,
|
||||
includeIfNull: true,
|
||||
)
|
||||
|
||||
|
||||
final String? price;
|
||||
|
||||
|
||||
|
||||
@JsonKey(
|
||||
|
||||
name: r'price_currency',
|
||||
required: true,
|
||||
includeIfNull: true,
|
||||
)
|
||||
|
||||
|
||||
final String? priceCurrency;
|
||||
|
||||
|
||||
|
||||
/// decimal as string
|
||||
@JsonKey(
|
||||
|
||||
name: r'suggested_qty',
|
||||
required: true,
|
||||
includeIfNull: true,
|
||||
)
|
||||
|
||||
|
||||
final String? suggestedQty;
|
||||
|
||||
|
||||
|
||||
@JsonKey(
|
||||
|
||||
name: r'ticker',
|
||||
required: true,
|
||||
includeIfNull: false,
|
||||
)
|
||||
|
||||
|
||||
final String ticker;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is TradeOut &&
|
||||
other.action == action &&
|
||||
other.amountRub == amountRub &&
|
||||
other.blockedByCash == blockedByCash &&
|
||||
other.instrumentId == instrumentId &&
|
||||
other.lot == lot &&
|
||||
other.name == name &&
|
||||
other.price == price &&
|
||||
other.priceCurrency == priceCurrency &&
|
||||
other.suggestedQty == suggestedQty &&
|
||||
other.ticker == ticker;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
action.hashCode +
|
||||
amountRub.hashCode +
|
||||
blockedByCash.hashCode +
|
||||
instrumentId.hashCode +
|
||||
(lot == null ? 0 : lot.hashCode) +
|
||||
name.hashCode +
|
||||
(price == null ? 0 : price.hashCode) +
|
||||
(priceCurrency == null ? 0 : priceCurrency.hashCode) +
|
||||
(suggestedQty == null ? 0 : suggestedQty.hashCode) +
|
||||
ticker.hashCode;
|
||||
|
||||
factory TradeOut.fromJson(Map<String, dynamic> json) => _$TradeOutFromJson(json);
|
||||
|
||||
Map<String, dynamic> toJson() => _$TradeOutToJson(this);
|
||||
|
||||
@override
|
||||
String toString() {
|
||||
return toJson().toString();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user