/* Options: Date: 2025-06-02 06:33:24 Version: 8.40 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://active-ewebservice.biz/aeservices30/api //GlobalNamespace: //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: SaleInfoRequest.* //ExcludeTypes: //DefaultImports: package:servicestack/servicestack.dart */ import 'package:servicestack/servicestack.dart'; // @DataContract class BaseRequest implements IConvertible { /** * This is your AIM API Key provided by Tri-Tech */ // @DataMember // @ApiMember(DataType="string", Description="This is your AIM API Key provided by Tri-Tech", IsRequired=true, Name="ApiKey", ParameterType="header") String? ApiKey; // @DataMember // @ApiMember(DataType="string", Name="OAuthToken", ParameterType="header") String? OAuthToken; BaseRequest({this.ApiKey,this.OAuthToken}); BaseRequest.fromJson(Map json) { fromMap(json); } fromMap(Map json) { ApiKey = json['ApiKey']; OAuthToken = json['OAuthToken']; return this; } Map toJson() => { 'ApiKey': ApiKey, 'OAuthToken': OAuthToken }; getTypeName() => "BaseRequest"; TypeContext? context = _ctx; } // @DataContract class BaseSecureRequest extends BaseRequest implements IConvertible { /** * */ // @DataMember // @ApiMember(DataType="string", Description="", Name="Token", ParameterType="Header") String? Token; /** * */ // @DataMember // @ApiMember(DataType="string", Description="", Name="DeviceId", ParameterType="Header") String? DeviceId; /** * */ // @DataMember // @ApiMember(DataType="string", Description="", IsRequired=true, Name="AppId", ParameterType="Header") String? AppId; BaseSecureRequest({this.Token,this.DeviceId,this.AppId}); BaseSecureRequest.fromJson(Map json) { fromMap(json); } fromMap(Map json) { super.fromMap(json); Token = json['Token']; DeviceId = json['DeviceId']; AppId = json['AppId']; return this; } Map toJson() => super.toJson()..addAll({ 'Token': Token, 'DeviceId': DeviceId, 'AppId': AppId }); getTypeName() => "BaseSecureRequest"; TypeContext? context = _ctx; } // @DataContract class DiscountFromPriceLevel implements IConvertible { // @DataMember String? BasePriceLevel; // @DataMember double? DisountPercentage; DiscountFromPriceLevel({this.BasePriceLevel,this.DisountPercentage}); DiscountFromPriceLevel.fromJson(Map json) { fromMap(json); } fromMap(Map json) { BasePriceLevel = json['BasePriceLevel']; DisountPercentage = JsonConverters.toDouble(json['DisountPercentage']); return this; } Map toJson() => { 'BasePriceLevel': BasePriceLevel, 'DisountPercentage': DisountPercentage }; getTypeName() => "DiscountFromPriceLevel"; TypeContext? context = _ctx; } // @DataContract class RecurringSaleDay implements IConvertible { // @DataMember String? Weekday; // @DataMember int? BeginHour; // @DataMember int? BeginMinute; // @DataMember int? EndHour; // @DataMember int? EndMinute; RecurringSaleDay({this.Weekday,this.BeginHour,this.BeginMinute,this.EndHour,this.EndMinute}); RecurringSaleDay.fromJson(Map json) { fromMap(json); } fromMap(Map json) { Weekday = json['Weekday']; BeginHour = json['BeginHour']; BeginMinute = json['BeginMinute']; EndHour = json['EndHour']; EndMinute = json['EndMinute']; return this; } Map toJson() => { 'Weekday': Weekday, 'BeginHour': BeginHour, 'BeginMinute': BeginMinute, 'EndHour': EndHour, 'EndMinute': EndMinute }; getTypeName() => "RecurringSaleDay"; TypeContext? context = _ctx; } // @DataContract class RecurringSaleInfo implements IConvertible { // @DataMember List? Days; RecurringSaleInfo({this.Days}); RecurringSaleInfo.fromJson(Map json) { fromMap(json); } fromMap(Map json) { Days = JsonConverters.fromJson(json['Days'],'List',context!); return this; } Map toJson() => { 'Days': JsonConverters.toJson(Days,'List',context!) }; getTypeName() => "RecurringSaleInfo"; TypeContext? context = _ctx; } // @DataContract class SaleRecord implements IConvertible { // @DataMember int? SadPk; // @DataMember int? SkuPk; // @DataMember int? SaqPk; // @DataMember String? Model; // @DataMember String? SKU; // @DataMember int? LocationId; // @DataMember DateTime? StartDate; // @DataMember DateTime? EndDate; // @DataMember int? CustomerAccount; // @DataMember int? CustomerDefaultId; // @DataMember String? Condition; // @DataMember DiscountFromPriceLevel? DiscountFromPriceLevel; // @DataMember String? DiscountByPriceLevel; // @DataMember double? DiscountBySetPrice; // @DataMember double? DiscountByAmount; // @DataMember RecurringSaleInfo? RecurringSale; SaleRecord({this.SadPk,this.SkuPk,this.SaqPk,this.Model,this.SKU,this.LocationId,this.StartDate,this.EndDate,this.CustomerAccount,this.CustomerDefaultId,this.Condition,this.DiscountFromPriceLevel,this.DiscountByPriceLevel,this.DiscountBySetPrice,this.DiscountByAmount,this.RecurringSale}); SaleRecord.fromJson(Map json) { fromMap(json); } fromMap(Map json) { SadPk = json['SadPk']; SkuPk = json['SkuPk']; SaqPk = json['SaqPk']; Model = json['Model']; SKU = json['SKU']; LocationId = json['LocationId']; StartDate = JsonConverters.fromJson(json['StartDate'],'DateTime',context!); EndDate = JsonConverters.fromJson(json['EndDate'],'DateTime',context!); CustomerAccount = json['CustomerAccount']; CustomerDefaultId = json['CustomerDefaultId']; Condition = json['Condition']; DiscountFromPriceLevel = JsonConverters.fromJson(json['DiscountFromPriceLevel'],'DiscountFromPriceLevel',context!); DiscountByPriceLevel = json['DiscountByPriceLevel']; DiscountBySetPrice = JsonConverters.toDouble(json['DiscountBySetPrice']); DiscountByAmount = JsonConverters.toDouble(json['DiscountByAmount']); RecurringSale = JsonConverters.fromJson(json['RecurringSale'],'RecurringSaleInfo',context!); return this; } Map toJson() => { 'SadPk': SadPk, 'SkuPk': SkuPk, 'SaqPk': SaqPk, 'Model': Model, 'SKU': SKU, 'LocationId': LocationId, 'StartDate': JsonConverters.toJson(StartDate,'DateTime',context!), 'EndDate': JsonConverters.toJson(EndDate,'DateTime',context!), 'CustomerAccount': CustomerAccount, 'CustomerDefaultId': CustomerDefaultId, 'Condition': Condition, 'DiscountFromPriceLevel': JsonConverters.toJson(DiscountFromPriceLevel,'DiscountFromPriceLevel',context!), 'DiscountByPriceLevel': DiscountByPriceLevel, 'DiscountBySetPrice': DiscountBySetPrice, 'DiscountByAmount': DiscountByAmount, 'RecurringSale': JsonConverters.toJson(RecurringSale,'RecurringSaleInfo',context!) }; getTypeName() => "SaleRecord"; TypeContext? context = _ctx; } // @DataContract class BaseResponse implements IConvertible { /** * */ // @DataMember // @ApiMember(DataType="BaseResponseResult", Description="", Name="Status", ParameterType="body") BaseResponseResult? Status; BaseResponse({this.Status}); BaseResponse.fromJson(Map json) { fromMap(json); } fromMap(Map json) { Status = JsonConverters.fromJson(json['Status'],'BaseResponseResult',context!); return this; } Map toJson() => { 'Status': JsonConverters.toJson(Status,'BaseResponseResult',context!) }; getTypeName() => "BaseResponse"; TypeContext? context = _ctx; } // @DataContract class SaleInfoResponse extends BaseResponse implements IConvertible { // @DataMember List? SaleRecords; SaleInfoResponse({this.SaleRecords}); SaleInfoResponse.fromJson(Map json) { fromMap(json); } fromMap(Map json) { super.fromMap(json); SaleRecords = JsonConverters.fromJson(json['SaleRecords'],'List',context!); return this; } Map toJson() => super.toJson()..addAll({ 'SaleRecords': JsonConverters.toJson(SaleRecords,'List',context!) }); getTypeName() => "SaleInfoResponse"; TypeContext? context = _ctx; } /** * SaleInfoRequires active-e Inventory Service */ // @Route("/SaleInfo", "GET") // @DataContract class SaleInfoRequest extends BaseSecureRequest implements IReturn, IConvertible, IGet { // @DataMember int? LocationId; /** * If sent, only sales that are active during the sent Date/Time are returned. Otherwise, the current Date/Time is used */ // @DataMember // @ApiMember(Description="If sent, only sales that are active during the sent Date/Time are returned. Otherwise, the current Date/Time is used", Name="DateTime") DateTime? DateTime; SaleInfoRequest({this.LocationId,this.DateTime}); SaleInfoRequest.fromJson(Map json) { fromMap(json); } fromMap(Map json) { super.fromMap(json); LocationId = json['LocationId']; DateTime = JsonConverters.fromJson(json['DateTime'],'DateTime',context!); return this; } Map toJson() => super.toJson()..addAll({ 'LocationId': LocationId, 'DateTime': JsonConverters.toJson(DateTime,'DateTime',context!) }); createResponse() => SaleInfoResponse(); getResponseTypeName() => "SaleInfoResponse"; getTypeName() => "SaleInfoRequest"; TypeContext? context = _ctx; } TypeContext _ctx = TypeContext(library: 'active_ewebservice.biz', types: { 'BaseRequest': TypeInfo(TypeOf.Class, create:() => BaseRequest()), 'BaseSecureRequest': TypeInfo(TypeOf.Class, create:() => BaseSecureRequest()), 'DiscountFromPriceLevel': TypeInfo(TypeOf.Class, create:() => DiscountFromPriceLevel()), 'RecurringSaleDay': TypeInfo(TypeOf.Class, create:() => RecurringSaleDay()), 'RecurringSaleInfo': TypeInfo(TypeOf.Class, create:() => RecurringSaleInfo()), 'List': TypeInfo(TypeOf.Class, create:() => []), 'SaleRecord': TypeInfo(TypeOf.Class, create:() => SaleRecord()), 'BaseResponse': TypeInfo(TypeOf.Class, create:() => BaseResponse()), 'BaseResponseResult': TypeInfo(TypeOf.Class, create:() => BaseResponseResult()), 'SaleInfoResponse': TypeInfo(TypeOf.Class, create:() => SaleInfoResponse()), 'List': TypeInfo(TypeOf.Class, create:() => []), 'SaleInfoRequest': TypeInfo(TypeOf.Class, create:() => SaleInfoRequest()), });