TicketUserServices

<back to all web services

WeeklyPayoutPreviewRequest

Requires Authentication
Requires any of the roles:Admin, Admin
The following routes are available for this service:
POST/payouts/weekly/preview
GET POST/payouts/weekly/sheet
import 'package:servicestack/servicestack.dart';

class WeeklyPayoutPreviewRow implements IConvertible
{
    int? eventId;
    String? eventName;
    DateTime? timeOfEvent;
    String? deild;
    String? eventOwnerName;
    int? eventOwnerId;
    String? teamNumber;
    String? kennitala;
    String? bankAccount;
    String? bankGender;
    int? grossAmount;
    int? amount;

    WeeklyPayoutPreviewRow({this.eventId,this.eventName,this.timeOfEvent,this.deild,this.eventOwnerName,this.eventOwnerId,this.teamNumber,this.kennitala,this.bankAccount,this.bankGender,this.grossAmount,this.amount});
    WeeklyPayoutPreviewRow.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        eventId = json['eventId'];
        eventName = json['eventName'];
        timeOfEvent = JsonConverters.fromJson(json['timeOfEvent'],'DateTime',context!);
        deild = json['deild'];
        eventOwnerName = json['eventOwnerName'];
        eventOwnerId = json['eventOwnerId'];
        teamNumber = json['teamNumber'];
        kennitala = json['kennitala'];
        bankAccount = json['bankAccount'];
        bankGender = json['bankGender'];
        grossAmount = json['grossAmount'];
        amount = json['amount'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'eventId': eventId,
        'eventName': eventName,
        'timeOfEvent': JsonConverters.toJson(timeOfEvent,'DateTime',context!),
        'deild': deild,
        'eventOwnerName': eventOwnerName,
        'eventOwnerId': eventOwnerId,
        'teamNumber': teamNumber,
        'kennitala': kennitala,
        'bankAccount': bankAccount,
        'bankGender': bankGender,
        'grossAmount': grossAmount,
        'amount': amount
    };

    getTypeName() => "WeeklyPayoutPreviewRow";
    TypeContext? context = _ctx;
}

class WeeklyPayoutMissingBank implements IConvertible
{
    String? eventOwnerName;
    int? eventOwnerId;
    String? teamNumber;
    int? eventId;
    String? eventName;
    DateTime? timeOfEvent;
    String? deild;
    int? amount;
    String? reason;

    WeeklyPayoutMissingBank({this.eventOwnerName,this.eventOwnerId,this.teamNumber,this.eventId,this.eventName,this.timeOfEvent,this.deild,this.amount,this.reason});
    WeeklyPayoutMissingBank.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        eventOwnerName = json['eventOwnerName'];
        eventOwnerId = json['eventOwnerId'];
        teamNumber = json['teamNumber'];
        eventId = json['eventId'];
        eventName = json['eventName'];
        timeOfEvent = JsonConverters.fromJson(json['timeOfEvent'],'DateTime',context!);
        deild = json['deild'];
        amount = json['amount'];
        reason = json['reason'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'eventOwnerName': eventOwnerName,
        'eventOwnerId': eventOwnerId,
        'teamNumber': teamNumber,
        'eventId': eventId,
        'eventName': eventName,
        'timeOfEvent': JsonConverters.toJson(timeOfEvent,'DateTime',context!),
        'deild': deild,
        'amount': amount,
        'reason': reason
    };

    getTypeName() => "WeeklyPayoutMissingBank";
    TypeContext? context = _ctx;
}

class WeeklyPayoutPreviewResult implements IConvertible
{
    DateTime? runDate;
    DateTime? windowFromInclusive;
    DateTime? windowToInclusive;
    String? sheetTitle;
    int? totalAmount;
    int? rowCount;
    List<WeeklyPayoutPreviewRow>? rows;
    List<WeeklyPayoutMissingBank>? missingBankInfo;
    List<WeeklyPayoutMissingBank>? skipped;
    String? sheetCsv;
    String? missingBankCsv;
    String? si080Preview;
    int? statusCode;
    String? message;

    WeeklyPayoutPreviewResult({this.runDate,this.windowFromInclusive,this.windowToInclusive,this.sheetTitle,this.totalAmount,this.rowCount,this.rows,this.missingBankInfo,this.skipped,this.sheetCsv,this.missingBankCsv,this.si080Preview,this.statusCode,this.message});
    WeeklyPayoutPreviewResult.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        runDate = JsonConverters.fromJson(json['runDate'],'DateTime',context!);
        windowFromInclusive = JsonConverters.fromJson(json['windowFromInclusive'],'DateTime',context!);
        windowToInclusive = JsonConverters.fromJson(json['windowToInclusive'],'DateTime',context!);
        sheetTitle = json['sheetTitle'];
        totalAmount = json['totalAmount'];
        rowCount = json['rowCount'];
        rows = JsonConverters.fromJson(json['rows'],'List<WeeklyPayoutPreviewRow>',context!);
        missingBankInfo = JsonConverters.fromJson(json['missingBankInfo'],'List<WeeklyPayoutMissingBank>',context!);
        skipped = JsonConverters.fromJson(json['skipped'],'List<WeeklyPayoutMissingBank>',context!);
        sheetCsv = json['sheetCsv'];
        missingBankCsv = json['missingBankCsv'];
        si080Preview = json['si080Preview'];
        statusCode = json['statusCode'];
        message = json['message'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'runDate': JsonConverters.toJson(runDate,'DateTime',context!),
        'windowFromInclusive': JsonConverters.toJson(windowFromInclusive,'DateTime',context!),
        'windowToInclusive': JsonConverters.toJson(windowToInclusive,'DateTime',context!),
        'sheetTitle': sheetTitle,
        'totalAmount': totalAmount,
        'rowCount': rowCount,
        'rows': JsonConverters.toJson(rows,'List<WeeklyPayoutPreviewRow>',context!),
        'missingBankInfo': JsonConverters.toJson(missingBankInfo,'List<WeeklyPayoutMissingBank>',context!),
        'skipped': JsonConverters.toJson(skipped,'List<WeeklyPayoutMissingBank>',context!),
        'sheetCsv': sheetCsv,
        'missingBankCsv': missingBankCsv,
        'si080Preview': si080Preview,
        'statusCode': statusCode,
        'message': message
    };

    getTypeName() => "WeeklyPayoutPreviewResult";
    TypeContext? context = _ctx;
}

class WeeklyPayoutPreviewRequest implements IConvertible
{
    DateTime? asOf;
    DateTime? from;
    DateTime? to;

    WeeklyPayoutPreviewRequest({this.asOf,this.from,this.to});
    WeeklyPayoutPreviewRequest.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        asOf = JsonConverters.fromJson(json['asOf'],'DateTime',context!);
        from = JsonConverters.fromJson(json['from'],'DateTime',context!);
        to = JsonConverters.fromJson(json['to'],'DateTime',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'asOf': JsonConverters.toJson(asOf,'DateTime',context!),
        'from': JsonConverters.toJson(from,'DateTime',context!),
        'to': JsonConverters.toJson(to,'DateTime',context!)
    };

    getTypeName() => "WeeklyPayoutPreviewRequest";
    TypeContext? context = _ctx;
}

TypeContext _ctx = TypeContext(library: 'stubbur_app.azurewebsites.net', types: <String, TypeInfo> {
    'WeeklyPayoutPreviewRow': TypeInfo(TypeOf.Class, create:() => WeeklyPayoutPreviewRow()),
    'WeeklyPayoutMissingBank': TypeInfo(TypeOf.Class, create:() => WeeklyPayoutMissingBank()),
    'WeeklyPayoutPreviewResult': TypeInfo(TypeOf.Class, create:() => WeeklyPayoutPreviewResult()),
    'List<WeeklyPayoutPreviewRow>': TypeInfo(TypeOf.Class, create:() => <WeeklyPayoutPreviewRow>[]),
    'List<WeeklyPayoutMissingBank>': TypeInfo(TypeOf.Class, create:() => <WeeklyPayoutMissingBank>[]),
    'WeeklyPayoutPreviewRequest': TypeInfo(TypeOf.Class, create:() => WeeklyPayoutPreviewRequest()),
});

Dart WeeklyPayoutPreviewRequest DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml

HTTP + XML

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /payouts/weekly/preview HTTP/1.1 
Host: stubbur-app.azurewebsites.net 
Accept: application/xml
Content-Type: application/xml
Content-Length: length

<WeeklyPayoutPreviewRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/TicketUserServices.ServiceModel">
  <AsOf>0001-01-01T00:00:00</AsOf>
  <From>0001-01-01T00:00:00</From>
  <To>0001-01-01T00:00:00</To>
</WeeklyPayoutPreviewRequest>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<WeeklyPayoutPreviewResult xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/TicketUserServices.ServiceModel">
  <Message>String</Message>
  <MissingBankCsv>String</MissingBankCsv>
  <MissingBankInfo>
    <WeeklyPayoutMissingBank>
      <Amount>0</Amount>
      <Deild>String</Deild>
      <EventId>0</EventId>
      <EventName>String</EventName>
      <EventOwnerId>0</EventOwnerId>
      <EventOwnerName>String</EventOwnerName>
      <Reason>String</Reason>
      <TeamNumber>String</TeamNumber>
      <TimeOfEvent>0001-01-01T00:00:00</TimeOfEvent>
    </WeeklyPayoutMissingBank>
  </MissingBankInfo>
  <RowCount>0</RowCount>
  <Rows>
    <WeeklyPayoutPreviewRow>
      <Amount>0</Amount>
      <BankAccount>String</BankAccount>
      <BankGender>String</BankGender>
      <Deild>String</Deild>
      <EventId>0</EventId>
      <EventName>String</EventName>
      <EventOwnerId>0</EventOwnerId>
      <EventOwnerName>String</EventOwnerName>
      <GrossAmount>0</GrossAmount>
      <Kennitala>String</Kennitala>
      <TeamNumber>String</TeamNumber>
      <TimeOfEvent>0001-01-01T00:00:00</TimeOfEvent>
    </WeeklyPayoutPreviewRow>
  </Rows>
  <RunDate>0001-01-01T00:00:00</RunDate>
  <SheetCsv>String</SheetCsv>
  <SheetTitle>String</SheetTitle>
  <Si080Preview>String</Si080Preview>
  <Skipped>
    <WeeklyPayoutMissingBank>
      <Amount>0</Amount>
      <Deild>String</Deild>
      <EventId>0</EventId>
      <EventName>String</EventName>
      <EventOwnerId>0</EventOwnerId>
      <EventOwnerName>String</EventOwnerName>
      <Reason>String</Reason>
      <TeamNumber>String</TeamNumber>
      <TimeOfEvent>0001-01-01T00:00:00</TimeOfEvent>
    </WeeklyPayoutMissingBank>
  </Skipped>
  <StatusCode>0</StatusCode>
  <TotalAmount>0</TotalAmount>
  <WindowFromInclusive>0001-01-01T00:00:00</WindowFromInclusive>
  <WindowToInclusive>0001-01-01T00:00:00</WindowToInclusive>
</WeeklyPayoutPreviewResult>