Documentation
Show / Hide Table of Contents

Connect Sales project

Overview

The sales project service is used to import sales project from an external system into the Evatic Database.

Service sequence description

For the sales project service, there are four methods.

  • Echo
  • CreateSalesProject
  • CreateSaleCalcHeading
  • CreateSaleOrderLine

The Echo method takes a string as in-parameter and returns a string, and can be used to verify the connection.

3-step import

Each of the three create methods takes a request data contract as an in-parameter and returns a response data contract.

  1. Start with the SalesProject.
    On a successful run, it will return a sales project no

  2. Insert SaleCalcHeading(s) Use the sales project no from the previous method response
    It will return a sale calc no to be used for the order lines.

  3. for each sale calc, insert the SaleOrderLine(s)
    This request data contract takes a list of order lines, so you can create multiple order lines with one method call.

If you want to input several calculations on a project, we suggest a loop:

CreateSalesProject(projectRequest)

foreach (calcHeadingRequest)  
    CreateSaleCalcHeading(calcHeadingRequest)  
        CreateSaleOrderLine  (orderLinesRequestForThisCalculation)

See more information about the sales project methods and data contracts here

Authentication example

When preparing service client for usage, it’s necessary to pass username and password. The general rule is that the user is authenticated with current ESH/ECMM database.


var serviceClient = new SalesProjectServiceClient(endPointName, serviceAddress);

serviceClient.ClientCredentials.UserName.UserName = serviceUser; //user from db

serviceClient.ClientCredentials.UserName.Password = servicePassword; //password

CONTACT INFORMATION

Asolvi AS Sluppenveien 25
N-7037 Trondheim
+47 73 80 22 00
Support
FOLLOW US

© Asolvi AS 2018