Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fixed the soap request envelop generation part when request has compl…
…ex Type as root. (#849) added request-response-samples as part of test
- Loading branch information
1 parent
6e07b5d
commit 448c903
Showing
7 changed files
with
269 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 30 additions & 0 deletions
30
test/request-response-samples/createData__should_generate_complex_type_request/request.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
{ | ||
"ModelCRUDRequest":{ | ||
"ModelCRUD":{ | ||
"serviceType":"CreateInterest", | ||
"TableName":"WTC_EmployeeInterest", | ||
"RecordID":0, | ||
"Filter":"", | ||
"Action":"Create", | ||
"DataRow":{ | ||
"field":[{ | ||
"attributes":{"column":"C_BPartner_ID"}, | ||
"val":"1001047" | ||
},{ | ||
"attributes":{"column":"Interest"}, | ||
"val":"Cooking" | ||
}] | ||
} | ||
}, | ||
"ADLoginRequest":{ | ||
"user":"WTCAdmin", | ||
"pass":"WTCAdmin", | ||
"lang":"192", | ||
"ClientID":11, | ||
"RoleID":102, | ||
"OrgID":1000001, | ||
"WarehouseID":1000000, | ||
"stage":0 | ||
} | ||
} | ||
} |
34 changes: 34 additions & 0 deletions
34
test/request-response-samples/createData__should_generate_complex_type_request/request.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:tns="http://3e.pl/ADInterface"> | ||
<soap:Body> | ||
<tns:createData> | ||
<tns:ModelCRUDRequest> | ||
<ModelCRUD> | ||
<serviceType>CreateInterest</serviceType> | ||
<TableName>WTC_EmployeeInterest</TableName> | ||
<RecordID>0</RecordID> | ||
<Filter></Filter> | ||
<Action>Create</Action> | ||
<DataRow> | ||
<tns:field column="C_BPartner_ID"> | ||
<val>1001047</val> | ||
</tns:field> | ||
<tns:field column="Interest"> | ||
<val>Cooking</val> | ||
</tns:field> | ||
</DataRow> | ||
</ModelCRUD> | ||
<ADLoginRequest> | ||
<user>WTCAdmin</user> | ||
<pass>WTCAdmin</pass> | ||
<lang>192</lang> | ||
<ClientID>11</ClientID> | ||
<RoleID>102</RoleID> | ||
<OrgID>1000001</OrgID> | ||
<WarehouseID>1000000</WarehouseID> | ||
<stage>0</stage> | ||
</ADLoginRequest> | ||
</tns:ModelCRUDRequest> | ||
</tns:createData> | ||
</soap:Body> | ||
</soap:Envelope> |
6 changes: 6 additions & 0 deletions
6
test/request-response-samples/createData__should_generate_complex_type_request/response.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"StandardResponse":{ | ||
"attributes":{"RecordID":"1000027"} | ||
} | ||
|
||
} |
8 changes: 8 additions & 0 deletions
8
test/request-response-samples/createData__should_generate_complex_type_request/response.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> | ||
<soap:Body> | ||
<ns1:createDataResponse xmlns:ns1="http://3e.pl/ADInterface"> | ||
<StandardResponse RecordID="1000027" xmlns="http://3e.pl/ADInterface"/> | ||
</ns1:createDataResponse> | ||
</soap:Body> | ||
</soap:Envelope> |
159 changes: 159 additions & 0 deletions
159
test/request-response-samples/createData__should_generate_complex_type_request/soap.wsdl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,159 @@ | ||
<wsdl:definitions xmlns:soapenc12="http://www.w3.org/2003/05/soap-encoding" xmlns:tns="http://3e.pl/ADInterface" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap11="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:soapenc11="http://schemas.xmlsoap.org/soap/encoding/" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope" targetNamespace="http://3e.pl/ADInterface"> | ||
<script id="tinyhippos-injected"/> | ||
<wsdl:types> | ||
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:tns="http://3e.pl/ADInterface" elementFormDefault="qualified" targetNamespace="http://3e.pl/ADInterface"> | ||
|
||
<xsd:complexType name="Field"> | ||
<xsd:sequence> | ||
<xsd:element name="Tab" type="tns:Tab"/> | ||
<xsd:element name="lookupInfo" type="tns:LookupInfo"/> | ||
<xsd:element name="Description" type="xsd:string"/> | ||
<xsd:element name="Help" type="xsd:string"/> | ||
<xsd:element name="ColumnSQL" type="xsd:string"/> | ||
<xsd:element name="DisplayLogic" type="xsd:string"/> | ||
<xsd:element name="ReadOnlyLogic" type="xsd:string"/> | ||
<xsd:element maxOccurs="1" minOccurs="0" name="lookup" type="tns:LookupValues"/> | ||
</xsd:sequence> | ||
<xsd:attribute name="Name" type="xsd:string"/> | ||
<xsd:attribute name="WindowNo" type="xsd:int"/> | ||
<xsd:attribute name="TabNo" type="xsd:int"/> | ||
<xsd:attribute name="AD_Window_ID" type="xsd:int"/> | ||
<xsd:attribute name="tabReadOnly" type="xsd:boolean"/> | ||
<xsd:attribute name="isProcess" type="xsd:boolean"/> | ||
<xsd:attribute name="ColumnName" type="xsd:string"/> | ||
<xsd:attribute name="Header" type="xsd:string"/> | ||
<xsd:attribute name="displayType" type="xsd:int"/> | ||
<xsd:attribute name="AD_Column_ID" type="xsd:int"/> | ||
<xsd:attribute name="DisplayLength" type="xsd:int"/> | ||
<xsd:attribute name="IsSameLine" type="xsd:boolean"/> | ||
<xsd:attribute name="IsDisplayed" type="xsd:boolean"/> | ||
<xsd:attribute name="DefaultValue" type="xsd:string"/> | ||
<xsd:attribute name="IsMandatory" type="xsd:boolean"/> | ||
<xsd:attribute name="IsReadOnly" type="xsd:boolean"/> | ||
<xsd:attribute name="IsUpdateable" type="xsd:boolean"/> | ||
<xsd:attribute name="IsAlwaysUpdateable" type="xsd:boolean"/> | ||
<xsd:attribute name="IsHeading" type="xsd:boolean"/> | ||
<xsd:attribute name="IsFieldOnly" type="xsd:boolean"/> | ||
<xsd:attribute name="IsEncryptedField" type="xsd:boolean"/> | ||
<xsd:attribute name="IsEncryptedColumn" type="xsd:boolean"/> | ||
<xsd:attribute name="IsSelectionColumn" type="xsd:boolean"/> | ||
<xsd:attribute name="SortNo" type="xsd:int"/> | ||
<xsd:attribute name="FieldLength" type="xsd:int"/> | ||
<xsd:attribute name="VFormat" type="xsd:string"/> | ||
<xsd:attribute name="ValueMin" type="xsd:string"/> | ||
<xsd:attribute name="ValueMax" type="xsd:string"/> | ||
<xsd:attribute name="FieldGroup" type="xsd:string"/> | ||
<xsd:attribute name="IsKey" type="xsd:boolean"/> | ||
<xsd:attribute name="IsParent" type="xsd:boolean"/> | ||
<xsd:attribute name="Callout" type="xsd:string"/> | ||
<xsd:attribute name="AD_Process_ID" type="xsd:int"/> | ||
<xsd:attribute name="ObscureType" type="xsd:string"/> | ||
<xsd:attribute name="ValidationCode" type="xsd:string"/> | ||
<xsd:attribute name="AD_Reference_Value_ID" type="xsd:int"/> | ||
<xsd:attribute name="isRange" type="xsd:boolean"/> | ||
<xsd:attribute name="DefaultValue2" type="xsd:string"/> | ||
</xsd:complexType> | ||
<xsd:complexType name="DataRow"> | ||
<xsd:sequence> | ||
<xsd:element maxOccurs="unbounded" minOccurs="0" name="field" type="tns:DataField"/> | ||
</xsd:sequence> | ||
</xsd:complexType> | ||
<!-- | ||
int WindowNo, int AD_Window_ID, int AD_Menu_ID, int TabNo, int PrevTabNo, int PrevRecNo, boolean getData, int RowStart, int RowCount) | ||
--> | ||
<xsd:element name="ADLoginRequest" type="tns:ADLoginRequest"/> | ||
<xsd:element name="ADLoginResponse" type="tns:ADLoginResponse"/> | ||
<xsd:complexType name="ADLoginRequest"> | ||
<xsd:sequence> | ||
<xsd:element name="user" type="xsd:string"/> | ||
<xsd:element name="pass" type="xsd:string"/> | ||
<xsd:element name="lang" type="xsd:string"/> | ||
<xsd:element name="ClientID" type="xsd:int"/> | ||
<xsd:element name="RoleID" type="xsd:int"/> | ||
<xsd:element name="OrgID" type="xsd:int"/> | ||
<xsd:element name="WarehouseID" type="xsd:int"/> | ||
<xsd:element name="stage" type="xsd:int"/> | ||
</xsd:sequence> | ||
</xsd:complexType> | ||
<xsd:complexType name="ADLoginResponse"> | ||
<xsd:sequence> | ||
<xsd:element name="status" type="xsd:int"/> | ||
<xsd:element name="roles" type="tns:LookupValues"/> | ||
<xsd:element name="langs" type="tns:LookupValues"/> | ||
<xsd:element name="orgs" type="tns:LookupValues"/> | ||
<xsd:element name="clients" type="tns:LookupValues"/> | ||
<xsd:element name="warehouses" type="tns:LookupValues"/> | ||
</xsd:sequence> | ||
</xsd:complexType> | ||
<xsd:complexType name="StandardResponse"> | ||
<xsd:sequence> | ||
<xsd:element name="Error" type="xsd:string"/> | ||
</xsd:sequence> | ||
<xsd:attribute name="IsError" type="xsd:boolean"/> | ||
<xsd:attribute name="RecordID" type="xsd:int"/> | ||
</xsd:complexType> | ||
<xsd:element name="Location" type="tns:Location"/> | ||
<xsd:element name="StandardResponse" type="tns:StandardResponse"/> | ||
|
||
|
||
<xsd:element name="ModelCRUDRequest" type="tns:ModelCRUDRequest"/> | ||
<xsd:complexType name="ModelCRUD"> | ||
<xsd:sequence> | ||
<xsd:element name="serviceType" type="xsd:string"/> | ||
<xsd:element name="TableName" type="xsd:string"/> | ||
<xsd:element name="RecordID" type="xsd:int"/> | ||
<xsd:element name="Filter" type="xsd:string"/> | ||
<xsd:element name="Action"> | ||
<xsd:simpleType> | ||
<xsd:restriction base="xsd:string"> | ||
<xsd:enumeration value="Create"/> | ||
<xsd:enumeration value="Read"/> | ||
<xsd:enumeration value="Update"/> | ||
<xsd:enumeration value="Delete"/> | ||
</xsd:restriction> | ||
</xsd:simpleType> | ||
</xsd:element> | ||
<xsd:element maxOccurs="1" minOccurs="0" name="DataRow" type="tns:DataRow"/> | ||
</xsd:sequence> | ||
</xsd:complexType> | ||
<xsd:complexType name="ModelCRUDRequest"> | ||
<xsd:sequence> | ||
<xsd:element maxOccurs="1" minOccurs="1" name="ModelCRUD" type="tns:ModelCRUD"/> | ||
<xsd:element maxOccurs="1" minOccurs="1" name="ADLoginRequest" type="tns:ADLoginRequest"/> | ||
</xsd:sequence> | ||
</xsd:complexType> | ||
</xsd:schema> | ||
</wsdl:types> | ||
<wsdl:message name="createDataRequest"> | ||
<wsdl:part name="ModelCRUDRequest" element="tns:ModelCRUDRequest"/> | ||
</wsdl:message> | ||
<wsdl:message name="createDataResponse"> | ||
<wsdl:part name="StandardResponse" element="tns:StandardResponse"/> | ||
</wsdl:message> | ||
<wsdl:portType name="ModelADServicePortType"> | ||
<wsdl:operation name="createData"> | ||
<wsdl:input name="createDataRequest" message="tns:createDataRequest"/> | ||
<wsdl:output name="createDataResponse" message="tns:createDataResponse"/> | ||
</wsdl:operation> | ||
</wsdl:portType> | ||
<wsdl:binding name="ModelADServiceHttpBinding" type="tns:ModelADServicePortType"> | ||
<wsdlsoap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> | ||
<wsdl:operation name="createData"> | ||
<wsdlsoap:operation soapAction=""/> | ||
<wsdl:input name="createDataRequest"> | ||
<wsdlsoap:body use="literal" namespace="http://3e.pl/ADInterface"/> | ||
</wsdl:input> | ||
<wsdl:output name="createDataResponse"> | ||
<wsdlsoap:body use="literal" namespace="http://3e.pl/ADInterface"/> | ||
</wsdl:output> | ||
</wsdl:operation> | ||
|
||
</wsdl:binding> | ||
<wsdl:service name="ModelADService"> | ||
<wsdl:port name="ModelADServiceHttpPort" binding="tns:ModelADServiceHttpBinding"> | ||
<wsdlsoap:address location="http://localhost:1509"/> | ||
</wsdl:port> | ||
</wsdl:service> | ||
</wsdl:definitions> |