| Requires any of the roles: | Admin, TeamAdmin | Requires the permission: | Tickets.Add |
| POST | /EventSeating/ReseatWithinEvent |
|---|
import 'package:servicestack/servicestack.dart';
class MoveConfirmedSeatFailure implements IConvertible
{
int? fromSeatId;
int? toSeatId;
String? reason;
MoveConfirmedSeatFailure({this.fromSeatId,this.toSeatId,this.reason});
MoveConfirmedSeatFailure.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
fromSeatId = json['fromSeatId'];
toSeatId = json['toSeatId'];
reason = json['reason'];
return this;
}
Map<String, dynamic> toJson() => {
'fromSeatId': fromSeatId,
'toSeatId': toSeatId,
'reason': reason
};
getTypeName() => "MoveConfirmedSeatFailure";
TypeContext? context = _ctx;
}
class ReseatWithinEventResult implements IConvertible
{
bool? ok;
int? statusCode;
String? message;
String? direction;
double? priceDifference;
bool? reconciliationSkipped;
int? reconciliationLogId;
double? refundAmount;
String? refundPaymentReference;
List<int>? movedSeatIds;
List<MoveConfirmedSeatFailure>? failures;
ReseatWithinEventResult({this.ok,this.statusCode,this.message,this.direction,this.priceDifference,this.reconciliationSkipped,this.reconciliationLogId,this.refundAmount,this.refundPaymentReference,this.movedSeatIds,this.failures});
ReseatWithinEventResult.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
ok = json['ok'];
statusCode = json['statusCode'];
message = json['message'];
direction = json['direction'];
priceDifference = JsonConverters.toDouble(json['priceDifference']);
reconciliationSkipped = json['reconciliationSkipped'];
reconciliationLogId = json['reconciliationLogId'];
refundAmount = JsonConverters.toDouble(json['refundAmount']);
refundPaymentReference = json['refundPaymentReference'];
movedSeatIds = JsonConverters.fromJson(json['movedSeatIds'],'List<int>',context!);
failures = JsonConverters.fromJson(json['failures'],'List<MoveConfirmedSeatFailure>',context!);
return this;
}
Map<String, dynamic> toJson() => {
'ok': ok,
'statusCode': statusCode,
'message': message,
'direction': direction,
'priceDifference': priceDifference,
'reconciliationSkipped': reconciliationSkipped,
'reconciliationLogId': reconciliationLogId,
'refundAmount': refundAmount,
'refundPaymentReference': refundPaymentReference,
'movedSeatIds': JsonConverters.toJson(movedSeatIds,'List<int>',context!),
'failures': JsonConverters.toJson(failures,'List<MoveConfirmedSeatFailure>',context!)
};
getTypeName() => "ReseatWithinEventResult";
TypeContext? context = _ctx;
}
class ReseatMovePair implements IConvertible
{
int? fromSeatId;
int? toSeatId;
int? toOwnerTicketTypeId;
ReseatMovePair({this.fromSeatId,this.toSeatId,this.toOwnerTicketTypeId});
ReseatMovePair.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
fromSeatId = json['fromSeatId'];
toSeatId = json['toSeatId'];
toOwnerTicketTypeId = json['toOwnerTicketTypeId'];
return this;
}
Map<String, dynamic> toJson() => {
'fromSeatId': fromSeatId,
'toSeatId': toSeatId,
'toOwnerTicketTypeId': toOwnerTicketTypeId
};
getTypeName() => "ReseatMovePair";
TypeContext? context = _ctx;
}
class ReseatWithinEventRequest implements IConvertible
{
int? eventId;
List<ReseatMovePair>? moves;
double? expectedPriceDifference;
bool? skipReconciliation;
String? reason;
String? idempotencyKey;
int? userId;
ReseatWithinEventRequest({this.eventId,this.moves,this.expectedPriceDifference,this.skipReconciliation,this.reason,this.idempotencyKey,this.userId});
ReseatWithinEventRequest.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
eventId = json['eventId'];
moves = JsonConverters.fromJson(json['moves'],'List<ReseatMovePair>',context!);
expectedPriceDifference = JsonConverters.toDouble(json['expectedPriceDifference']);
skipReconciliation = json['skipReconciliation'];
reason = json['reason'];
idempotencyKey = json['idempotencyKey'];
userId = json['userId'];
return this;
}
Map<String, dynamic> toJson() => {
'eventId': eventId,
'moves': JsonConverters.toJson(moves,'List<ReseatMovePair>',context!),
'expectedPriceDifference': expectedPriceDifference,
'skipReconciliation': skipReconciliation,
'reason': reason,
'idempotencyKey': idempotencyKey,
'userId': userId
};
getTypeName() => "ReseatWithinEventRequest";
TypeContext? context = _ctx;
}
TypeContext _ctx = TypeContext(library: 'stubbur_app.azurewebsites.net', types: <String, TypeInfo> {
'MoveConfirmedSeatFailure': TypeInfo(TypeOf.Class, create:() => MoveConfirmedSeatFailure()),
'ReseatWithinEventResult': TypeInfo(TypeOf.Class, create:() => ReseatWithinEventResult()),
'List<MoveConfirmedSeatFailure>': TypeInfo(TypeOf.Class, create:() => <MoveConfirmedSeatFailure>[]),
'ReseatMovePair': TypeInfo(TypeOf.Class, create:() => ReseatMovePair()),
'ReseatWithinEventRequest': TypeInfo(TypeOf.Class, create:() => ReseatWithinEventRequest()),
'List<ReseatMovePair>': TypeInfo(TypeOf.Class, create:() => <ReseatMovePair>[]),
});
Dart ReseatWithinEventRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /EventSeating/ReseatWithinEvent HTTP/1.1
Host: stubbur-app.azurewebsites.net
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
eventId: 0,
moves:
[
{
fromSeatId: 0,
toSeatId: 0,
toOwnerTicketTypeId: 0
}
],
expectedPriceDifference: 0,
skipReconciliation: False,
reason: String,
idempotencyKey: String,
userId: 0
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
ok: False,
statusCode: 0,
message: String,
direction: String,
priceDifference: 0,
reconciliationSkipped: False,
reconciliationLogId: 0,
refundAmount: 0,
refundPaymentReference: String,
movedSeatIds:
[
0
],
failures:
[
{
fromSeatId: 0,
toSeatId: 0,
reason: String
}
]
}