| GET | /magazzino/articoli/elenco | ||
|---|---|---|---|
| GET | /magazzino/articoli/elenco/da/{FromId} |
import 'package:servicestack/servicestack.dart';
enum TipoArticolo
{
Semplice,
Matricola,
FuoriInventario,
Distinta,
}
abstract class FK
{
int? Id;
FK({this.Id});
FK.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
Id = json['Id'];
return this;
}
Map<String, dynamic> toJson() => {
'Id': Id
};
getTypeName() => "FK";
TypeContext? context = _ctx;
}
class FK_Gruppo extends FK implements IUniqueCodice, IConvertible
{
String? Codice;
FK_Gruppo({this.Codice});
FK_Gruppo.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
Codice = json['Codice'];
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'Codice': Codice
});
getTypeName() => "FK_Gruppo";
TypeContext? context = _ctx;
}
class FK_FamigliaMerceologica extends FK implements IUniqueCodice, IConvertible
{
String? Codice;
FK_FamigliaMerceologica({this.Codice});
FK_FamigliaMerceologica.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
Codice = json['Codice'];
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'Codice': Codice
});
getTypeName() => "FK_FamigliaMerceologica";
TypeContext? context = _ctx;
}
class FK_Marca extends FK implements IUniqueDescrizione, IConvertible
{
String? Descrizione;
FK_Marca({this.Descrizione});
FK_Marca.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
Descrizione = json['Descrizione'];
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'Descrizione': Descrizione
});
getTypeName() => "FK_Marca";
TypeContext? context = _ctx;
}
class FK_UdM extends FK implements IUniqueCodice, IUniqueDescrizione, IUniqueCodiceExport, IConvertible
{
String? Codice;
String? Descrizione;
String? CodiceExport;
FK_UdM({this.Codice,this.Descrizione,this.CodiceExport});
FK_UdM.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
Codice = json['Codice'];
Descrizione = json['Descrizione'];
CodiceExport = json['CodiceExport'];
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'Codice': Codice,
'Descrizione': Descrizione,
'CodiceExport': CodiceExport
});
getTypeName() => "FK_UdM";
TypeContext? context = _ctx;
}
class FK_AliquotaIVA extends FK implements IUniqueCodice, IUniqueCodiceExport, IConvertible
{
String? Codice;
String? CodiceExport;
FK_AliquotaIVA({this.Codice,this.CodiceExport});
FK_AliquotaIVA.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
Codice = json['Codice'];
CodiceExport = json['CodiceExport'];
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'Codice': Codice,
'CodiceExport': CodiceExport
});
getTypeName() => "FK_AliquotaIVA";
TypeContext? context = _ctx;
}
class FK_Conto extends FK implements IUniqueCodice, IUniqueCodiceExport, IConvertible
{
String? Codice;
String? CodiceExport;
FK_Conto({this.Codice,this.CodiceExport});
FK_Conto.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
Codice = json['Codice'];
CodiceExport = json['CodiceExport'];
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'Codice': Codice,
'CodiceExport': CodiceExport
});
getTypeName() => "FK_Conto";
TypeContext? context = _ctx;
}
class SchedaArticolo implements IConvertible
{
int? Id;
String? Codice;
TipoArticolo? TipoArticolo;
String? Descrizione;
String? Barcode;
String? DescrizioneEstesa;
double? LottoRiordino;
double? PrezzoAcquisto;
double? PrezzoVendita;
bool? IsEsclusoDaListe;
bool? IsNascondiInStampa;
FK_Gruppo? Gruppo;
FK_FamigliaMerceologica? FamigliaMerceologica;
FK_Marca? Marca;
FK_UdM? UdM;
FK_AliquotaIVA? AliquotaIVA;
FK_Conto? ContoAcquisto;
FK_Conto? ContoVendita;
SchedaArticolo({this.Id,this.Codice,this.TipoArticolo,this.Descrizione,this.Barcode,this.DescrizioneEstesa,this.LottoRiordino,this.PrezzoAcquisto,this.PrezzoVendita,this.IsEsclusoDaListe,this.IsNascondiInStampa,this.Gruppo,this.FamigliaMerceologica,this.Marca,this.UdM,this.AliquotaIVA,this.ContoAcquisto,this.ContoVendita});
SchedaArticolo.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
Id = json['Id'];
Codice = json['Codice'];
TipoArticolo = JsonConverters.fromJson(json['TipoArticolo'],'TipoArticolo',context!);
Descrizione = json['Descrizione'];
Barcode = json['Barcode'];
DescrizioneEstesa = json['DescrizioneEstesa'];
LottoRiordino = JsonConverters.toDouble(json['LottoRiordino']);
PrezzoAcquisto = JsonConverters.toDouble(json['PrezzoAcquisto']);
PrezzoVendita = JsonConverters.toDouble(json['PrezzoVendita']);
IsEsclusoDaListe = json['IsEsclusoDaListe'];
IsNascondiInStampa = json['IsNascondiInStampa'];
Gruppo = JsonConverters.fromJson(json['Gruppo'],'FK_Gruppo',context!);
FamigliaMerceologica = JsonConverters.fromJson(json['FamigliaMerceologica'],'FK_FamigliaMerceologica',context!);
Marca = JsonConverters.fromJson(json['Marca'],'FK_Marca',context!);
UdM = JsonConverters.fromJson(json['UdM'],'FK_UdM',context!);
AliquotaIVA = JsonConverters.fromJson(json['AliquotaIVA'],'FK_AliquotaIVA',context!);
ContoAcquisto = JsonConverters.fromJson(json['ContoAcquisto'],'FK_Conto',context!);
ContoVendita = JsonConverters.fromJson(json['ContoVendita'],'FK_Conto',context!);
return this;
}
Map<String, dynamic> toJson() => {
'Id': Id,
'Codice': Codice,
'TipoArticolo': JsonConverters.toJson(TipoArticolo,'TipoArticolo',context!),
'Descrizione': Descrizione,
'Barcode': Barcode,
'DescrizioneEstesa': DescrizioneEstesa,
'LottoRiordino': LottoRiordino,
'PrezzoAcquisto': PrezzoAcquisto,
'PrezzoVendita': PrezzoVendita,
'IsEsclusoDaListe': IsEsclusoDaListe,
'IsNascondiInStampa': IsNascondiInStampa,
'Gruppo': JsonConverters.toJson(Gruppo,'FK_Gruppo',context!),
'FamigliaMerceologica': JsonConverters.toJson(FamigliaMerceologica,'FK_FamigliaMerceologica',context!),
'Marca': JsonConverters.toJson(Marca,'FK_Marca',context!),
'UdM': JsonConverters.toJson(UdM,'FK_UdM',context!),
'AliquotaIVA': JsonConverters.toJson(AliquotaIVA,'FK_AliquotaIVA',context!),
'ContoAcquisto': JsonConverters.toJson(ContoAcquisto,'FK_Conto',context!),
'ContoVendita': JsonConverters.toJson(ContoVendita,'FK_Conto',context!)
};
getTypeName() => "SchedaArticolo";
TypeContext? context = _ctx;
}
class FK_Magazzino extends FK implements IUniqueDescrizione, IUniqueCodiceExport, IConvertible
{
String? Descrizione;
String? CodiceExport;
FK_Magazzino({this.Descrizione,this.CodiceExport});
FK_Magazzino.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
Descrizione = json['Descrizione'];
CodiceExport = json['CodiceExport'];
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'Descrizione': Descrizione,
'CodiceExport': CodiceExport
});
getTypeName() => "FK_Magazzino";
TypeContext? context = _ctx;
}
class Giacenza implements IConvertible
{
FK_Magazzino? Magazzino;
double? Quantita;
Giacenza({this.Magazzino,this.Quantita});
Giacenza.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
Magazzino = JsonConverters.fromJson(json['Magazzino'],'FK_Magazzino',context!);
Quantita = JsonConverters.toDouble(json['Quantita']);
return this;
}
Map<String, dynamic> toJson() => {
'Magazzino': JsonConverters.toJson(Magazzino,'FK_Magazzino',context!),
'Quantita': Quantita
};
getTypeName() => "Giacenza";
TypeContext? context = _ctx;
}
class FK_Listino extends FK implements IUniqueCodice, IUniqueDescrizione, IConvertible
{
String? Codice;
String? Descrizione;
FK_Listino({this.Codice,this.Descrizione});
FK_Listino.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
Codice = json['Codice'];
Descrizione = json['Descrizione'];
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'Codice': Codice,
'Descrizione': Descrizione
});
getTypeName() => "FK_Listino";
TypeContext? context = _ctx;
}
class FK_Articolo extends FK implements IUniqueCodice, IConvertible
{
String? Codice;
FK_Articolo({this.Codice});
FK_Articolo.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
Codice = json['Codice'];
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'Codice': Codice
});
getTypeName() => "FK_Articolo";
TypeContext? context = _ctx;
}
class VoceListino implements IConvertible
{
FK_Listino? Listino;
FK_Articolo? Articolo;
String? CodiceOrdine;
String? Barcode;
double? PrezzoAcquisto;
double? PrezzoVendita;
VoceListino({this.Listino,this.Articolo,this.CodiceOrdine,this.Barcode,this.PrezzoAcquisto,this.PrezzoVendita});
VoceListino.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
Listino = JsonConverters.fromJson(json['Listino'],'FK_Listino',context!);
Articolo = JsonConverters.fromJson(json['Articolo'],'FK_Articolo',context!);
CodiceOrdine = json['CodiceOrdine'];
Barcode = json['Barcode'];
PrezzoAcquisto = JsonConverters.toDouble(json['PrezzoAcquisto']);
PrezzoVendita = JsonConverters.toDouble(json['PrezzoVendita']);
return this;
}
Map<String, dynamic> toJson() => {
'Listino': JsonConverters.toJson(Listino,'FK_Listino',context!),
'Articolo': JsonConverters.toJson(Articolo,'FK_Articolo',context!),
'CodiceOrdine': CodiceOrdine,
'Barcode': Barcode,
'PrezzoAcquisto': PrezzoAcquisto,
'PrezzoVendita': PrezzoVendita
};
getTypeName() => "VoceListino";
TypeContext? context = _ctx;
}
class SchedaArticoloConDatiAggiuntivi implements IConvertible
{
SchedaArticolo? Scheda;
List<Giacenza>? Giacenze;
List<VoceListino>? Listini;
SchedaArticoloConDatiAggiuntivi({this.Scheda,this.Giacenze,this.Listini});
SchedaArticoloConDatiAggiuntivi.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
Scheda = JsonConverters.fromJson(json['Scheda'],'SchedaArticolo',context!);
Giacenze = JsonConverters.fromJson(json['Giacenze'],'List<Giacenza>',context!);
Listini = JsonConverters.fromJson(json['Listini'],'List<VoceListino>',context!);
return this;
}
Map<String, dynamic> toJson() => {
'Scheda': JsonConverters.toJson(Scheda,'SchedaArticolo',context!),
'Giacenze': JsonConverters.toJson(Giacenze,'List<Giacenza>',context!),
'Listini': JsonConverters.toJson(Listini,'List<VoceListino>',context!)
};
getTypeName() => "SchedaArticoloConDatiAggiuntivi";
TypeContext? context = _ctx;
}
class SchedeArticoloResponse implements IConvertible
{
List<SchedaArticoloConDatiAggiuntivi>? Risultati;
SchedeArticoloResponse({this.Risultati});
SchedeArticoloResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
Risultati = JsonConverters.fromJson(json['Risultati'],'List<SchedaArticoloConDatiAggiuntivi>',context!);
return this;
}
Map<String, dynamic> toJson() => {
'Risultati': JsonConverters.toJson(Risultati,'List<SchedaArticoloConDatiAggiuntivi>',context!)
};
getTypeName() => "SchedeArticoloResponse";
TypeContext? context = _ctx;
}
class SchedeArticolo implements IConvertible
{
int? FromId;
SchedeArticolo({this.FromId});
SchedeArticolo.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
FromId = json['FromId'];
return this;
}
Map<String, dynamic> toJson() => {
'FromId': FromId
};
getTypeName() => "SchedeArticolo";
TypeContext? context = _ctx;
}
TypeContext _ctx = TypeContext(library: 'link.dc8.unico3.cloud', types: <String, TypeInfo> {
'TipoArticolo': TypeInfo(TypeOf.Enum, enumValues:TipoArticolo.values),
'FK': TypeInfo(TypeOf.AbstractClass),
'FK_Gruppo': TypeInfo(TypeOf.Class, create:() => FK_Gruppo()),
'FK_FamigliaMerceologica': TypeInfo(TypeOf.Class, create:() => FK_FamigliaMerceologica()),
'FK_Marca': TypeInfo(TypeOf.Class, create:() => FK_Marca()),
'FK_UdM': TypeInfo(TypeOf.Class, create:() => FK_UdM()),
'FK_AliquotaIVA': TypeInfo(TypeOf.Class, create:() => FK_AliquotaIVA()),
'FK_Conto': TypeInfo(TypeOf.Class, create:() => FK_Conto()),
'SchedaArticolo': TypeInfo(TypeOf.Class, create:() => SchedaArticolo()),
'FK_Magazzino': TypeInfo(TypeOf.Class, create:() => FK_Magazzino()),
'Giacenza': TypeInfo(TypeOf.Class, create:() => Giacenza()),
'FK_Listino': TypeInfo(TypeOf.Class, create:() => FK_Listino()),
'FK_Articolo': TypeInfo(TypeOf.Class, create:() => FK_Articolo()),
'VoceListino': TypeInfo(TypeOf.Class, create:() => VoceListino()),
'SchedaArticoloConDatiAggiuntivi': TypeInfo(TypeOf.Class, create:() => SchedaArticoloConDatiAggiuntivi()),
'List<Giacenza>': TypeInfo(TypeOf.Class, create:() => <Giacenza>[]),
'List<VoceListino>': TypeInfo(TypeOf.Class, create:() => <VoceListino>[]),
'SchedeArticoloResponse': TypeInfo(TypeOf.Class, create:() => SchedeArticoloResponse()),
'List<SchedaArticoloConDatiAggiuntivi>': TypeInfo(TypeOf.Class, create:() => <SchedaArticoloConDatiAggiuntivi>[]),
'SchedeArticolo': TypeInfo(TypeOf.Class, create:() => SchedeArticolo()),
});
To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json
To embed the response in a jsonp callback, append ?callback=myCallback
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /magazzino/articoli/elenco HTTP/1.1 Host: unico3.link.api Accept: application/json
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length
{"Risultati":[{"Scheda":{"Id":0,"Codice":"String","TipoArticolo":"Semplice","Descrizione":"String","Barcode":"String","DescrizioneEstesa":"String","LottoRiordino":0,"PrezzoAcquisto":0,"PrezzoVendita":0,"IsEsclusoDaListe":false,"IsNascondiInStampa":false,"Gruppo":{"Codice":"String","Id":0},"FamigliaMerceologica":{"Codice":"String","Id":0},"Marca":{"Descrizione":"String","Id":0},"UdM":{"Codice":"String","Descrizione":"String","CodiceExport":"String","Id":0},"AliquotaIVA":{"Codice":"String","CodiceExport":"String","Id":0},"ContoAcquisto":{"Codice":"String","CodiceExport":"String","Id":0},"ContoVendita":{"Codice":"String","CodiceExport":"String","Id":0}},"Giacenze":[{"Magazzino":{"Descrizione":"String","CodiceExport":"String","Id":0},"Quantita":0}],"Listini":[{"Listino":{"Codice":"String","Descrizione":"String","Id":0},"Articolo":{"Codice":"String","Id":0},"CodiceOrdine":"String","Barcode":"String","PrezzoAcquisto":0,"PrezzoVendita":0}]}]}