Required role: | VeoliaAdmin |
GET | /contractversion/{contractversionid} |
---|
import 'package:servicestack/servicestack.dart';
abstract class ResponseBase
{
ResponseStatus? ResponseStatus;
ResponseBase({this.ResponseStatus});
ResponseBase.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
ResponseStatus = JsonConverters.fromJson(json['ResponseStatus'],'ResponseStatus',context!);
return this;
}
Map<String, dynamic> toJson() => {
'ResponseStatus': JsonConverters.toJson(ResponseStatus,'ResponseStatus',context!)
};
getTypeName() => "ResponseBase";
TypeContext? context = _ctx;
}
class ReviewStatus
{
static const ReviewStatus Draft = const ReviewStatus._(0);
static const ReviewStatus Commented = const ReviewStatus._(1);
static const ReviewStatus Accepted = const ReviewStatus._(2);
final int _value;
const ReviewStatus._(this._value);
int get value => _value;
static List<ReviewStatus> get values => const [Draft,Commented,Accepted];
}
class ContractVersionSimple implements IConvertible
{
int? Id;
int? ContractId;
int? Version;
bool? IsViewed;
ReviewStatus? Status;
ContractVersionSimple({this.Id,this.ContractId,this.Version,this.IsViewed,this.Status});
ContractVersionSimple.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
Id = json['Id'];
ContractId = json['ContractId'];
Version = json['Version'];
IsViewed = json['IsViewed'];
Status = JsonConverters.fromJson(json['Status'],'ReviewStatus',context!);
return this;
}
Map<String, dynamic> toJson() => {
'Id': Id,
'ContractId': ContractId,
'Version': Version,
'IsViewed': IsViewed,
'Status': JsonConverters.toJson(Status,'ReviewStatus',context!)
};
getTypeName() => "ContractVersionSimple";
TypeContext? context = _ctx;
}
abstract class BrowseFileResponseBase
{
int? Id;
int? FileContentId;
String? FileName;
int? Size;
BrowseFileResponseBase({this.Id,this.FileContentId,this.FileName,this.Size});
BrowseFileResponseBase.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
Id = json['Id'];
FileContentId = json['FileContentId'];
FileName = json['FileName'];
Size = json['Size'];
return this;
}
Map<String, dynamic> toJson() => {
'Id': Id,
'FileContentId': FileContentId,
'FileName': FileName,
'Size': Size
};
getTypeName() => "BrowseFileResponseBase";
TypeContext? context = _ctx;
}
class ContractDocumentType
{
static const ContractDocumentType Draft = const ContractDocumentType._(0);
static const ContractDocumentType Comment = const ContractDocumentType._(1);
final int _value;
const ContractDocumentType._(this._value);
int get value => _value;
static List<ContractDocumentType> get values => const [Draft,Comment];
}
class ContractFileSimple extends BrowseFileResponseBase implements IConvertible
{
int? ContractVersionId;
ContractDocumentType? DocumentType;
ContractFileSimple({this.ContractVersionId,this.DocumentType});
ContractFileSimple.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
ContractVersionId = json['ContractVersionId'];
DocumentType = JsonConverters.fromJson(json['DocumentType'],'ContractDocumentType',context!);
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'ContractVersionId': ContractVersionId,
'DocumentType': JsonConverters.toJson(DocumentType,'ContractDocumentType',context!)
});
getTypeName() => "ContractFileSimple";
TypeContext? context = _ctx;
}
class ContractVersionDetails extends ContractVersionSimple implements IConvertible
{
Map<String,String?>? Meta;
DateTime? ViewingDateTime;
DateTime? ReviewingDateTime;
List<ContractFileSimple>? ContractFiles;
ContractVersionDetails({this.Meta,this.ViewingDateTime,this.ReviewingDateTime,this.ContractFiles});
ContractVersionDetails.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
Meta = JsonConverters.toStringMap(json['Meta']);
ViewingDateTime = JsonConverters.fromJson(json['ViewingDateTime'],'DateTime',context!);
ReviewingDateTime = JsonConverters.fromJson(json['ReviewingDateTime'],'DateTime',context!);
ContractFiles = JsonConverters.fromJson(json['ContractFiles'],'List<ContractFileSimple>',context!);
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'Meta': Meta,
'ViewingDateTime': JsonConverters.toJson(ViewingDateTime,'DateTime',context!),
'ReviewingDateTime': JsonConverters.toJson(ReviewingDateTime,'DateTime',context!),
'ContractFiles': JsonConverters.toJson(ContractFiles,'List<ContractFileSimple>',context!)
});
getTypeName() => "ContractVersionDetails";
TypeContext? context = _ctx;
}
class ContractVersionDetailsExtended extends ContractVersionDetails implements IConvertible
{
int? TenderId;
int? UserId;
int? TenderUserId;
int? SupplierUserId;
ContractVersionDetailsExtended({this.TenderId,this.UserId,this.TenderUserId,this.SupplierUserId});
ContractVersionDetailsExtended.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
TenderId = json['TenderId'];
UserId = json['UserId'];
TenderUserId = json['TenderUserId'];
SupplierUserId = json['SupplierUserId'];
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'TenderId': TenderId,
'UserId': UserId,
'TenderUserId': TenderUserId,
'SupplierUserId': SupplierUserId
});
getTypeName() => "ContractVersionDetailsExtended";
TypeContext? context = _ctx;
}
class BrowseContractVersionByVeoliaAdminResponse extends ResponseBase implements IConvertible
{
ContractVersionDetailsExtended? ContractVersion;
BrowseContractVersionByVeoliaAdminResponse({this.ContractVersion});
BrowseContractVersionByVeoliaAdminResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
ContractVersion = JsonConverters.fromJson(json['ContractVersion'],'ContractVersionDetailsExtended',context!);
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'ContractVersion': JsonConverters.toJson(ContractVersion,'ContractVersionDetailsExtended',context!)
});
getTypeName() => "BrowseContractVersionByVeoliaAdminResponse";
TypeContext? context = _ctx;
}
class BrowseContractVersionByVeoliaAdmin implements IGet, IConvertible
{
int? ContractVersionId;
BrowseContractVersionByVeoliaAdmin({this.ContractVersionId});
BrowseContractVersionByVeoliaAdmin.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
ContractVersionId = json['ContractVersionId'];
return this;
}
Map<String, dynamic> toJson() => {
'ContractVersionId': ContractVersionId
};
getTypeName() => "BrowseContractVersionByVeoliaAdmin";
TypeContext? context = _ctx;
}
TypeContext _ctx = TypeContext(library: 'szallitoiportal_be.veolia.hu', types: <String, TypeInfo> {
'ResponseBase': TypeInfo(TypeOf.AbstractClass),
'ReviewStatus': TypeInfo(TypeOf.Enum, enumValues:ReviewStatus.values),
'ContractVersionSimple': TypeInfo(TypeOf.Class, create:() => ContractVersionSimple()),
'BrowseFileResponseBase': TypeInfo(TypeOf.AbstractClass),
'ContractDocumentType': TypeInfo(TypeOf.Enum, enumValues:ContractDocumentType.values),
'ContractFileSimple': TypeInfo(TypeOf.Class, create:() => ContractFileSimple()),
'ContractVersionDetails': TypeInfo(TypeOf.Class, create:() => ContractVersionDetails()),
'List<ContractFileSimple>': TypeInfo(TypeOf.Class, create:() => <ContractFileSimple>[]),
'ContractVersionDetailsExtended': TypeInfo(TypeOf.Class, create:() => ContractVersionDetailsExtended()),
'BrowseContractVersionByVeoliaAdminResponse': TypeInfo(TypeOf.Class, create:() => BrowseContractVersionByVeoliaAdminResponse()),
'BrowseContractVersionByVeoliaAdmin': TypeInfo(TypeOf.Class, create:() => BrowseContractVersionByVeoliaAdmin()),
});
Dart BrowseContractVersionByVeoliaAdmin DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /contractversion/{contractversionid} HTTP/1.1 Host: szallitoiportal-be.veolia.hu Accept: text/csv
HTTP/1.1 200 OK Content-Type: text/csv Content-Length: length {"ContractVersion":{"TenderId":0,"UserId":0,"TenderUserId":0,"SupplierUserId":0,"Meta":{"String":"String"},"ViewingDateTime":"0001-01-01T00:00:00.0000000","ReviewingDateTime":"0001-01-01T00:00:00.0000000","ContractFiles":[{"ContractVersionId":0,"DocumentType":0,"Id":0,"FileContentId":0,"FileName":"String","Size":0}],"Id":0,"ContractId":0,"Version":0,"IsViewed":false,"Status":0},"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}}}