Setup Ordering
Submitted by Guest on Fri, 18/05/2012 - 11:52
I am attempting to setup ordering from within openvpms myself.
Stock management is working fine,
but the location setup with the online account seems to have me stumped.
We order through Provet as I am sure others do
I rang provet IT and had them activate my account on thier end
I input my account and then use
https://vethub.provet.com.au/OrderService.svc?wsdl as the service URL
however it returns
ESCIA-0004: Failed to connect to web service https://vethub.provet.com.au/orderservice.svc?wsdl
IF I access the URL via browser I get a the following file:
<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:tns="http://tempuri.org/"xmlns:wsa="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"xmlns:wsap="http://schemas.xmlsoap.org/ws/2004/08/addressing/policy" xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl"xmlns:msc="http://schemas.microsoft.com/ws/2005/12/wsdl/contract" xmlns:wsa10="http://www.w3.org/2005/08/addressing"xmlns:wsx="http://schemas.xmlsoap.org/ws/2004/09/mex" xmlns:wsam="http://www.w3.org/2007/05/addressing/metadata" name="OrderService"targetNamespace="http://tempuri.org/"><wsp:Policy wsu:Id="WSHttpBinding_IOrderService_policy"><wsp:ExactlyOne><wsp:All><sp:TransportBinding xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"><wsp:Policy><sp:TransportToken><wsp:Policy><sp:HttpsToken RequireClientCertificate="false"/></wsp:Policy></sp:TransportToken><sp:AlgorithmSuite><wsp:Policy><sp:Basic256/></wsp:Policy></sp:AlgorithmSuite><sp:Layout><wsp:Policy><sp:Strict/></wsp:Policy></sp:Layout><sp:IncludeTimestamp/></wsp:Policy></sp:TransportBinding><sp:EndorsingSupportingTokens xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"><wsp:Policy><sp:SecureConversationToken sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient"><wsp:Policy><sp:BootstrapPolicy><wsp:Policy><sp:SignedParts><sp:Body/><sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing"/><sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing"/><sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing"/><sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing"/><sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing"/><sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing"/><sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing"/></sp:SignedParts><sp:EncryptedParts><sp:Body/></sp:EncryptedParts><sp:TransportBinding><wsp:Policy><sp:TransportToken><wsp:Policy><sp:HttpsToken RequireClientCertificate="false"/></wsp:Policy></sp:TransportToken><sp:AlgorithmSuite><wsp:Policy><sp:Basic256/></wsp:Policy></sp:AlgorithmSuite><sp:Layout><wsp:Policy><sp:Strict/></wsp:Policy></sp:Layout><sp:IncludeTimestamp/></wsp:Policy></sp:TransportBinding><sp:SignedSupportingTokens><wsp:Policy><sp:UsernameToken sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient"><wsp:Policy><sp:WssUsernameToken10/></wsp:Policy></sp:UsernameToken></wsp:Policy></sp:SignedSupportingTokens><sp:Wss11><wsp:Policy/></sp:Wss11><sp:Trust10><wsp:Policy><sp:MustSupportIssuedTokens/><sp:RequireClientEntropy/><sp:RequireServerEntropy/></wsp:Policy></sp:Trust10></wsp:Policy></sp:BootstrapPolicy></wsp:Policy></sp:SecureConversationToken></wsp:Policy></sp:EndorsingSupportingTokens><sp:Wss11 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"><wsp:Policy/></sp:Wss11><sp:Trust10 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"><wsp:Policy><sp:MustSupportIssuedTokens/><sp:RequireClientEntropy/><sp:RequireServerEntropy/></wsp:Policy></sp:Trust10><wsaw:UsingAddressing/></wsp:All></wsp:ExactlyOne></wsp:Policy><wsdl:types><xsd:schema targetNamespace="http://tempuri.org/Imports"><xsd:import schemaLocation="https://vethub.provet.com.au/OrderService.svc?xsd=xsd0" namespace="http://tempuri.org/"/><xsd:import schemaLocation="https://vethub.provet.com.au/OrderService.svc?xsd=xsd1"namespace="http://schemas.microsoft.com/2003/10/Serialization/"/><xsd:import schemaLocation="https://vethub.provet.com.au/OrderService.svc?xsd=xsd2"namespace="http://schemas.datacontract.org/2004/07/Provet.VetHub.Supplier.Models"/></xsd:schema></wsdl:types><wsdl:message name="IOrderService_PlaceOrder_InputMessage"><wsdl:part name="parameters" element="tns:PlaceOrder"/></wsdl:message><wsdl:message name="IOrderService_PlaceOrder_OutputMessage"><wsdl:part name="parameters" element="tns:PlaceOrderResponse"/></wsdl:message><wsdl:portType name="IOrderService"><wsdl:operation name="PlaceOrder"><wsdl:input wsaw:Action="http://tempuri.org/IOrderService/PlaceOrder" message="tns:IOrderService_PlaceOrder_InputMessage"/><wsdl:output wsaw:Action="http://tempuri.org/IOrderService/PlaceOrderResponse" message="tns:IOrderService_PlaceOrder_OutputMessage"/></wsdl:operation></wsdl:portType><wsdl:binding name="WSHttpBinding_IOrderService" type="tns:IOrderService"><wsp:PolicyReference URI="#WSHttpBinding_IOrderService_policy"/><soap12:binding transport="http://schemas.xmlsoap.org/soap/http"/><wsdl:operation name="PlaceOrder"><soap12:operation soapAction="http://tempuri.org/IOrderService/PlaceOrder" style="document"/><wsdl:input><soap12:body use="literal"/></wsdl:input><wsdl:output><soap12:body use="literal"/></wsdl:output></wsdl:operation></wsdl:binding><wsdl:service name="OrderService"><wsdl:port name="WSHttpBinding_IOrderService" binding="tns:WSHttpBinding_IOrderService"><soap12:address location="https://vethub.provet.com.au/OrderService.svc"/><wsa10:EndpointReference><wsa10:Address>https://vethub.provet.com.au/OrderService.svc</wsa10:Address><Identity xmlns="http://schemas.xmlsoap.org/ws/2006/02/addressingidentity"><Dns>localhost</Dns></Identity></wsa10:EndpointReference></wsdl:port></wsdl:service></wsdl:definitions>
Any tips or should I ring Provet IT back and run through it with them, anyone got a good contact there to deal with.
Re: Setup Ordering
That wsdl doesn't look right to me. I would expect the targetNamespace to be:
targetNamespace="http://openvpms.org/esci"
Not:
targetNamespace="http://tempuri.org/"
Also, make sure they've given you the correct URL. The URL you configure OpenVPMS with should be that of the registry service, not the order service.
-Tim
Re: Setup Ordering
Yeah I wondered about that, some research produced the fact that Tempuri.org was an old domain that visual studio defaulted the webapp target namespace too, apparently Msoft discontinued paying for the domain 2 years ago or something.
I'll ring my supplier and try and get someone who has a clue...
Ben
Re: Setup Ordering
They gave me the wrong URL....go figure
the new URL allows the Test to work fine but I get the following error on attempting to finalize an invoice.
the direct error message is
Invalid account or account is not configured; nested exception is javax.xml.ws.soap.SOAPFaultException: Invalid account or account is not configured
but the registration url works fine and the username and password are correct.
Any help directing me to the source would be appreciated. I am actually assuming this is a provet error.
Ben
Re: Setup Ordering
Hi Ben,
Yes, seen this before. This is an error returned by Provet's internal systems. They just need to turn a switch on somewhere I believe. :-)
Cheers Tony
Re: Setup Ordering
Yeah that was what I though, Ive called them 3 times about it tho and they swear that everything is configured as it should be.
Here is where I am:
I have input the correct service url, account number, username and password in Open. The test button works
I cannot print orders. I dont have an order report configured
I cannot send orders the error above appears
When I check the inbox for deliveries or orders nothing returns despite the fact that provet says there are orders present.
Any other tests I can try
Ben
Re: Setup Ordering
The test button just verifies that the services can be accessed.
You will need to manually configure the order report. In the distribution there are two templates that need to be configured in the reports/ directory:
As far as other tests go, you can try the inbox.bat script, which enables you to list the contents of an inbox.
This is included in the ESCI integration package, available at http://repository.openvpms.org/releases/org/openvpms/openvpms-esci-package/1.0-beta-3/openvpms-esci-package-1.0-beta-3.zip
Instructions on its use are located in the included documentation.
Alternatively, contact me off list and I can take a look at it for you.
-Tim