AlbaApi

<back to all web services

ListResolveReqUpdated

The following routes are available for this service:
POST/listresolve/changelog
import 'package:servicestack/servicestack.dart';
import 'dart:typed_data';

class Entity implements IEntity, IConvertible
{
    String? id;

    Entity({this.id});
    Entity.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        id = json['id'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'id': id
    };

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

class ChangeHistory implements IConvertible
{
    String? updatedBy;
    DateTime? dateCreated;
    String? element;
    String? old;
    String? new;
    String? status;
    String? approvedBy;
    DateTime? dateApproved;

    ChangeHistory({this.updatedBy,this.dateCreated,this.element,this.old,this.new,this.status,this.approvedBy,this.dateApproved});
    ChangeHistory.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        updatedBy = json['updatedBy'];
        dateCreated = JsonConverters.fromJson(json['dateCreated'],'DateTime',context!);
        element = json['element'];
        old = json['old'];
        new = json['new'];
        status = json['status'];
        approvedBy = json['approvedBy'];
        dateApproved = JsonConverters.fromJson(json['dateApproved'],'DateTime',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'updatedBy': updatedBy,
        'dateCreated': JsonConverters.toJson(dateCreated,'DateTime',context!),
        'element': element,
        'old': old,
        'new': new,
        'status': status,
        'approvedBy': approvedBy,
        'dateApproved': JsonConverters.toJson(dateApproved,'DateTime',context!)
    };

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

class ChangeLog extends Entity implements IConvertible
{
    String? referenceId;
    String? country;
    String? language;
    String? section;
    String? itemCode;
    String? itemId;
    List<ChangeHistory>? history;

    ChangeLog({this.referenceId,this.country,this.language,this.section,this.itemCode,this.itemId,this.history});
    ChangeLog.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        super.fromMap(json);
        referenceId = json['referenceId'];
        country = json['country'];
        language = json['language'];
        section = json['section'];
        itemCode = json['itemCode'];
        itemId = json['itemId'];
        history = JsonConverters.fromJson(json['history'],'List<ChangeHistory>',context!);
        return this;
    }

    Map<String, dynamic> toJson() => super.toJson()..addAll({
        'referenceId': referenceId,
        'country': country,
        'language': language,
        'section': section,
        'itemCode': itemCode,
        'itemId': itemId,
        'history': JsonConverters.toJson(history,'List<ChangeHistory>',context!)
    });

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

class ListResolveReqUpdated implements IConvertible
{
    List<ChangeLog>? changeLogs;

    ListResolveReqUpdated({this.changeLogs});
    ListResolveReqUpdated.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        changeLogs = JsonConverters.fromJson(json['changeLogs'],'List<ChangeLog>',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'changeLogs': JsonConverters.toJson(changeLogs,'List<ChangeLog>',context!)
    };

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

TypeContext _ctx = TypeContext(library: 'hcbtas_q_albamfs_api.azurewebsites.net', types: <String, TypeInfo> {
    'Entity': TypeInfo(TypeOf.Class, create:() => Entity()),
    'ChangeHistory': TypeInfo(TypeOf.Class, create:() => ChangeHistory()),
    'ChangeLog': TypeInfo(TypeOf.Class, create:() => ChangeLog()),
    'List<ChangeHistory>': TypeInfo(TypeOf.Class, create:() => <ChangeHistory>[]),
    'ListResolveReqUpdated': TypeInfo(TypeOf.Class, create:() => ListResolveReqUpdated()),
    'List<ChangeLog>': TypeInfo(TypeOf.Class, create:() => <ChangeLog>[]),
});

Dart ListResolveReqUpdated 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 /listresolve/changelog HTTP/1.1 
Host: hcbtas-q-albamfs-api.azurewebsites.net 
Accept: application/xml
Content-Type: application/xml
Content-Length: length

<ListResolveReqUpdated xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/AlbaApi.ServiceModel">
  <ChangeLogs xmlns:d2p1="http://schemas.datacontract.org/2004/07/AlbaApi.Model">
    <d2p1:ChangeLog>
      <Id xmlns="http://schemas.datacontract.org/2004/07/TasSyd.Model.Base">String</Id>
      <d2p1:Country>String</d2p1:Country>
      <d2p1:History>
        <d2p1:ChangeHistory>
          <d2p1:ApprovedBy>String</d2p1:ApprovedBy>
          <d2p1:DateApproved>0001-01-01T00:00:00</d2p1:DateApproved>
          <d2p1:DateCreated>0001-01-01T00:00:00</d2p1:DateCreated>
          <d2p1:Element>String</d2p1:Element>
          <d2p1:New>String</d2p1:New>
          <d2p1:Old>String</d2p1:Old>
          <d2p1:Status>String</d2p1:Status>
          <d2p1:UpdatedBy>String</d2p1:UpdatedBy>
        </d2p1:ChangeHistory>
      </d2p1:History>
      <d2p1:ItemCode>String</d2p1:ItemCode>
      <d2p1:ItemId>String</d2p1:ItemId>
      <d2p1:Language>String</d2p1:Language>
      <d2p1:ReferenceId>String</d2p1:ReferenceId>
      <d2p1:Section>String</d2p1:Section>
    </d2p1:ChangeLog>
  </ChangeLogs>
</ListResolveReqUpdated>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<ChangeLog xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/AlbaApi.Model">
  <Id xmlns="http://schemas.datacontract.org/2004/07/TasSyd.Model.Base">String</Id>
  <Country>String</Country>
  <History>
    <ChangeHistory>
      <ApprovedBy>String</ApprovedBy>
      <DateApproved>0001-01-01T00:00:00</DateApproved>
      <DateCreated>0001-01-01T00:00:00</DateCreated>
      <Element>String</Element>
      <New>String</New>
      <Old>String</Old>
      <Status>String</Status>
      <UpdatedBy>String</UpdatedBy>
    </ChangeHistory>
  </History>
  <ItemCode>String</ItemCode>
  <ItemId>String</ItemId>
  <Language>String</Language>
  <ReferenceId>String</ReferenceId>
  <Section>String</Section>
</ChangeLog>