Required role: | REGISUserRole |
POST | /DynamicsCRM/TaxReceipt/{guid}/Update |
---|
import 'package:servicestack/servicestack.dart';
import 'dart:typed_data';
class CRMNoteResponse implements IConvertible
{
String? subject;
String? text;
String? owner_first_name;
String? owner_last_name;
String? file_base64;
String? filename;
int? filesize;
String? mimetype;
DateTime? added_date;
CRMNoteResponse({this.subject,this.text,this.owner_first_name,this.owner_last_name,this.file_base64,this.filename,this.filesize,this.mimetype,this.added_date});
CRMNoteResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
subject = json['subject'];
text = json['text'];
owner_first_name = json['owner_first_name'];
owner_last_name = json['owner_last_name'];
file_base64 = json['file_base64'];
filename = json['filename'];
filesize = json['filesize'];
mimetype = json['mimetype'];
added_date = JsonConverters.fromJson(json['added_date'],'DateTime',context!);
return this;
}
Map<String, dynamic> toJson() => {
'subject': subject,
'text': text,
'owner_first_name': owner_first_name,
'owner_last_name': owner_last_name,
'file_base64': file_base64,
'filename': filename,
'filesize': filesize,
'mimetype': mimetype,
'added_date': JsonConverters.toJson(added_date,'DateTime',context!)
};
getTypeName() => "CRMNoteResponse";
TypeContext? context = _ctx;
}
class CRMTaxReceiptNoteResponse extends CRMNoteResponse implements IConvertible
{
String? guid;
String? receipt_template_name;
DateTime? receipt_sent_date;
DateTime? receipt_email_sent_date;
String? receipt_email_sent_to;
String? salutation;
String? first_name;
String? last_name;
String? receipt_email;
CRMTaxReceiptNoteResponse({this.guid,this.receipt_template_name,this.receipt_sent_date,this.receipt_email_sent_date,this.receipt_email_sent_to,this.salutation,this.first_name,this.last_name,this.receipt_email});
CRMTaxReceiptNoteResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
guid = json['guid'];
receipt_template_name = json['receipt_template_name'];
receipt_sent_date = JsonConverters.fromJson(json['receipt_sent_date'],'DateTime',context!);
receipt_email_sent_date = JsonConverters.fromJson(json['receipt_email_sent_date'],'DateTime',context!);
receipt_email_sent_to = json['receipt_email_sent_to'];
salutation = json['salutation'];
first_name = json['first_name'];
last_name = json['last_name'];
receipt_email = json['receipt_email'];
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'guid': guid,
'receipt_template_name': receipt_template_name,
'receipt_sent_date': JsonConverters.toJson(receipt_sent_date,'DateTime',context!),
'receipt_email_sent_date': JsonConverters.toJson(receipt_email_sent_date,'DateTime',context!),
'receipt_email_sent_to': receipt_email_sent_to,
'salutation': salutation,
'first_name': first_name,
'last_name': last_name,
'receipt_email': receipt_email
});
getTypeName() => "CRMTaxReceiptNoteResponse";
TypeContext? context = _ctx;
}
class CRMTaxReceiptUpdateRequest implements IConvertible
{
String? guid;
DateTime? email_sent_date;
String? email_sent_to;
CRMTaxReceiptUpdateRequest({this.guid,this.email_sent_date,this.email_sent_to});
CRMTaxReceiptUpdateRequest.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
guid = json['guid'];
email_sent_date = JsonConverters.fromJson(json['email_sent_date'],'DateTime',context!);
email_sent_to = json['email_sent_to'];
return this;
}
Map<String, dynamic> toJson() => {
'guid': guid,
'email_sent_date': JsonConverters.toJson(email_sent_date,'DateTime',context!),
'email_sent_to': email_sent_to
};
getTypeName() => "CRMTaxReceiptUpdateRequest";
TypeContext? context = _ctx;
}
TypeContext _ctx = TypeContext(library: 'data.regent_college.edu', types: <String, TypeInfo> {
'CRMNoteResponse': TypeInfo(TypeOf.Class, create:() => CRMNoteResponse()),
'CRMTaxReceiptNoteResponse': TypeInfo(TypeOf.Class, create:() => CRMTaxReceiptNoteResponse()),
'CRMTaxReceiptUpdateRequest': TypeInfo(TypeOf.Class, create:() => CRMTaxReceiptUpdateRequest()),
});
Dart CRMTaxReceiptUpdateRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /DynamicsCRM/TaxReceipt/{guid}/Update HTTP/1.1
Host: data.regent-college.edu
Accept: application/xml
Content-Type: application/xml
Content-Length: length
<CRMTaxReceiptUpdateRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/regis.DynamicsCRM.Requests">
<email_sent_date>0001-01-01T00:00:00</email_sent_date>
<email_sent_to>String</email_sent_to>
<guid>String</guid>
</CRMTaxReceiptUpdateRequest>
HTTP/1.1 200 OK Content-Type: application/xml Content-Length: length <CRMTaxReceiptNoteResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/regis.DynamicsCRM.Responses"> <added_date>0001-01-01T00:00:00</added_date> <file_base64>String</file_base64> <filename>String</filename> <filesize>0</filesize> <mimetype>String</mimetype> <owner_first_name>String</owner_first_name> <owner_last_name>String</owner_last_name> <subject>String</subject> <text>String</text> <first_name>String</first_name> <guid>String</guid> <last_name>String</last_name> <receipt_email>String</receipt_email> <receipt_email_sent_date>0001-01-01T00:00:00</receipt_email_sent_date> <receipt_email_sent_to>String</receipt_email_sent_to> <receipt_sent_date>0001-01-01T00:00:00</receipt_sent_date> <receipt_template_name>String</receipt_template_name> <salutation>String</salutation> </CRMTaxReceiptNoteResponse>