Book Contents

Book Index

Contracts

Book Contents

Book Index

Sales contract

Process number: SML002

Script Id. number: FSML001

File: SaleContract.PAS

Script description: The function exports data from a sales contract to a Word template. The template location can be set with the TemplateFileName parameter.

Address in the tree: [Contracts]

Script parameters:

OwnContactPerson - 0

Number of own contact person, in the document Represented by

TemplateFileName - SupportFiles\Lang5\SaleContract.dotx

File name of the document template with path

Linked Graphics K2_SKRIPT

Information for users who will edit templates:

If custom templates for contracts are created, the defined variables from the sample template can be transferred to these templates, and they will be filled in the same way as in the sample template SaleContract.dotx. After opening the template and pressing Alt + F9, the document variables are displayed in the form e.g. {DOCVARIABLE ContractAbbr \*MERGEFORMAT}. By copying these variables, they can be transferred to the template.

List of all document variables. On the right is information on which fields fill the variable.

Document variables:

ContractAbbr - ContractHeaderRID.Abbr,

ContractMaturityDays - MaturityDays,

ContractPenalty - InterestPercentage + InterestPercentageUnitCalc,

ContractValidFrom - ValidFrom,

ContractConclusionDate - ContractConclusionDate,

OwnCompanyName - GetCompanies.GetItemByCompanyId(CurrentCompanyID).Name,

OwnCompanyRegNumber - GetCompanies.GetItemByCompanyId(CurrentCompanyID).IDNo,

OwnCompanyAddress - GetCompanies.GetItemByCompanyId(CurrentCompanyID).Address,

OwnCompanyTown - GetCompanies.GetItemByCompanyId(CurrentCompanyID).TownPart,

OwnEntityType - ContractTypeRID.OwnEntityTypeId.LangCodeCalc,

OwnBankAccount - OwnBankAccountId.BankAccountCalc + '/' + OwnBankAccountId.BankCodeNumberCalc,

OwnBankName - OwnBankAccountId.BankNameCalc,

OwnContactPerson (script parameter, link to contact persons) - OwnContactPerson.FullNameCalc,

TradingPartnerName - TradingPartnerId.Name_ver,

TradingPartnerCompanyRegNumber - IDNoFullCalc,

TradingPartnerAddress - TradingPartnerId.AddressId_ver.OneLineCalc,

TradingPartnerTown - TradingPartnerId.AddressId_ver.TownPartId.Name,

TradingPartnerContactPerson - TradingPartnerContactPersonId.FullNameTitleCalc,

TradingPartnerEntityType - ContractTypeRID.PartnerEntityTypeId.LangCodeCalc,

ContractItemList and ContractItemTable - contract items, where the items are displayed as a table in which the item name is ItemName and the item price is ContractNetPriceC + Currency.

Registry of contracts

Publishing in the registry of contracts - settings

Process number:

Script ID No.: FSML002

File: CNT_ContractPublishSettings.PAS

Script description: Script for setting up the sending of contracts to the registry of contracts. A more detailed description is in the chapter Publishing in the registry of contracts - settings.

Address in the tree: [Contracts] [Registry of contracts]

Script parameters:

No parameters.

 

Contract publishing

Process number:

Script ID No.: FSML003

File: CNT_ContractPublish.PAS

Script description: Function for publishing a contract in the registry of contracts. A more detailed description is in the chapter Publishing a contract.

Address in the tree: [Contracts] [Registry of contracts]

Script parameters:

No parameters.

 

Processing responses from the Registry of contracts

Process number:

Script ID No.: FSML004

File: POR_ContractPublishing.PAS

Script description: The function links the received mail document with the contract document. A more detailed description is in the chapter Processing responses from the Registry of contracts.

Address in the tree: [Contracts] [Registry of contracts]

Script parameters:

No parameters.

 

Contract unpublishing

Process number:

Script ID No.: FSML005

File: CNT_ContractCancel.PAS

Script description: The function makes a contract inaccessible in the registry of contracts. A more detailed description is in the chapter Making a contract inaccessible.

Address in the tree: [Contracts] [Registry of contracts]

Script parameters:

No parameters.