Skip to main content
Information about a connection to the ERP system.

Constructors

NSQuoteAlternative()

Initializes a new instance of the NSQuoteAlternative class.

Methods

GetDescription()

Returns: CRMScript.Global.String - The tool-tip to use in the user interface (on the tab, for instance). Example:

GetDiscountAmount()

Returns: CRMScript.Global.Float - The discount the sales rep specifies, in whatever currency the sale is in.
Both the two ‘DiscountPercent’ and ‘DiscountAmount’ shall be filled out, but the UserValueOverride field must be set to the field the user actually changed. If this field is filled out by the user, it overrides the discount suggested by the connector. If the user has not filled any values, the system will copy the ERP discount amount value into this field.
Example:

GetDiscountPercent()

Returns: CRMScript.Global.Float - The discount the sales rep specifies, in percent. ‘12%’ is represented as ‘12’.
Both the two ‘DiscountPercent’ and ‘DiscountAmount’ shall be filled out, but the UserValueOverride field must be set to the field the user actually changed. If this field is filled out by the user, it overrides the discount suggested by the connector. If the user has not filled any values, the system will copy the ERP discount percent value into this field.
Example:

GetEarningAmount()

Returns: CRMScript.Global.Float - Earning on this alternative, as an absolute amount. Example:

GetEarningPercent()

Returns: CRMScript.Global.Float - The earning on this alternative, in percent of total. The Percentage is given in integer form, ‘12%’ is represented as ‘12’. Example:

GetERPDiscountAmount()

Can be overridden by the user in the field ‘DiscountPercent’ or ‘DiscountAmount’. Both the two ‘ERPDiscountPercent’ and ‘ERPDiscountAmount’ shall be filled out. If UserValueOverride is ‘None’, then the ERPDiscountAmount shall be copied into DiscountAmount and ERPDiscountPercent into DiscountPercent.
Returns: CRMScript.Global.Float - The discount the system calculates based on customer /amount / whatever. Example:

GetERPDiscountPercent()

Returns: CRMScript.Global.Float - The discount the system calculates based on customer /amount / whatever. The Percentage is given in integer form, ‘12%’ is represented as ‘12’.
Can be overridden by the sales rep in the field ‘DiscountPercent’ or ‘DiscountAmount’. Both the two ‘ERPDiscountPercent’ and ‘ERPDiscountAmount’ shall be filled out. If UserValueOverride is ‘None’, then the ERPDiscountAmount shall be copied into DiscountAmount and ERPDiscountPercent into DiscountPercent.
Example:

GetERPQuoteAlternativeKey()

Returns: CRMScript.Global.String - Key that identifies this alternative in the ERP system, if it exists there. Example:

GetExtraField1()

Returns: CRMScript.Global.String - Optional information added by Quote Connector; usable in the quote document merge process. Example:

GetExtraField2()

Returns: CRMScript.Global.String - Optional information added by Quote Connector; usable in the quote document merge process. Example:

GetExtraField3()

Returns: CRMScript.Global.String - Optional information added by Quote Connector; usable in the quote document merge process. Example:

GetExtraField4()

Returns: CRMScript.Global.String - Optional information added by Quote Connector; usable in the quote document merge process. Example:

GetExtraField5()

Returns: CRMScript.Global.String - Optional information added by Quote Connector; usable in the quote document merge process. Example:

GetName()

Returns: CRMScript.Global.String - Name of Alternative. Shown in tab in user interface, intentionally kept short. Example:

GetQuoteAlternativeId()

Returns: CRMScript.Global.Integer - Primary key. Example:

GetQuoteVersionId()

Returns: CRMScript.Global.Integer - The version that owns this alternative (the chain is Sale 1->1 Quote 1->+ QuoteVersion 1->+ QuoteAlternative. Example:

GetReason()

Returns: CRMScript.Global.String - If there was a problem, this field contains a localized explanation of the problem and possible steps to fix it that the user can be shown. Example:

GetStatus()

Returns: CRMScript.Global.Integer - If there was a problem with for instance calculation, this field is set to warning or error. See <xref href=“CRMScript.NetServer.QuoteStatus” data-throw-if-not-resolved=“false”></xref>. Example:

GetSubTotal()

Returns: CRMScript.Global.Float - Value to help the user interface, is computed by summing the total price of the quote lines, and NOT by summing their subtotals. Example:

GetTotalPrice()

Returns: CRMScript.Global.Float - Sum of the QuoteLines.TotalPrice, AlternativeDiscount or QuoteLines.TotalCost + Earning based on what, if anything, the user has entered last. Shall be calculated by the connector. Example:

GetUserValueOverride()

Returns: CRMScript.Global.Integer - Has the pre-calculated (from ERP) price information been overridden, and how. See <xref href=“CRMScript.NetServer.ValueOverride” data-throw-if-not-resolved=“false”></xref>.
If the user has filled out the discountpercentage field, then the UserValueOverride field is set to OverridePercent. (The DiscountAmount, EarningPercent, EarningAmount and TotalPrice fields are calculated based on the discountPercent.)
Example:

GetVAT()

Returns: CRMScript.Global.Float - Tax/VAT, THIS IS AN AMOUNT, available as a merge field in the quote document.
The SuperOffice quote connector will calculate this field based on the vat PERCENTAGES on the individual lines; other connectors may implement other algorithms at will.
Example:

GetVATInfo()

Returns: CRMScript.Global.String - Extra info about VAT that the connector might insert.
This field has no business logic in the CRM code, but is available as a merge field in the quote documents.
Example:

SetDescription(String)

Returns: CRMScript.Global.Void Example:

SetDiscountAmount(Float)

Returns: CRMScript.Global.Void
If this field is filled out by the user, it overrides the discount suggested by the connector. If the user has not filled any values, the system will copy the ERP discount amount value into this field.
Example:

SetDiscountPercent(Float)

Returns: CRMScript.Global.Void
If this field is filled out by the user, it overrides the discount suggested by the connector. If the user has not filled any values, the system will copy the ERP discount percent value into this field.
Example:

SetEarningAmount(Float)

Returns: CRMScript.Global.Void Example:

SetEarningPercent(Float)

Returns: CRMScript.Global.Void Example:

SetERPDiscountAmount(Float)

Returns: CRMScript.Global.Void
Can be overridden by the user in the field ‘DiscountPercent’ or ‘DiscountAmount’. Both the two ‘ERPDiscountPercent’ and ‘ERPDiscountAmount’ shall be filled out. If UserValueOverride is ‘None’, then the ERPDiscountAmount shall be copied into DiscountAmount and ERPDiscountPercent into DiscountPercent.
Example:

SetERPDiscountPercent(Float)

Returns: CRMScript.Global.Void
Can be overridden by the sales rep in the field ‘DiscountPercent’ or ‘DiscountAmount’. Both the two ‘ERPDiscountPercent’ and ‘ERPDiscountAmount’ shall be filled out. If UserValueOverride is ‘None’, then the ERPDiscountAmount shall be copied into DiscountAmount and ERPDiscountPercent into DiscountPercent.
Example:

SetERPQuoteAlternativeKey(String)

Returns: CRMScript.Global.Void Example:

SetExtraField1(String)

Returns: CRMScript.Global.Void Example:

SetExtraField2(String)

Returns: CRMScript.Global.Void Example:

SetExtraField3(String)

Returns: CRMScript.Global.Void Example:

SetExtraField4(String)

Returns: CRMScript.Global.Void Example:

SetExtraField5(String)

Returns: CRMScript.Global.Void Example:

SetName(String)

Returns: CRMScript.Global.Void Example:

SetQuoteAlternativeId(Integer)

Returns: CRMScript.Global.Void Example:

SetQuoteVersionId(Integer)

Returns: CRMScript.Global.Void Example:

SetReason(String)

Returns: CRMScript.Global.Void Example:

SetStatus(Integer)

Returns: CRMScript.Global.Void Example:

SetSubTotal(Float)

Returns: CRMScript.Global.Void Example:

SetTotalPrice(Float)

Returns: CRMScript.Global.Void Example:

SetUserValueOverride(Integer)

Returns: CRMScript.Global.Void
If the user has filled out the discountpercentage field, then the UserValueOverride field is set to OverridePercent. (The DiscountAmount, EarningPercent, EarningAmount and TotalPrice fields are calculated based on the discountPercent.)
Example:

SetVAT(Float)

Returns: CRMScript.Global.Void
The SuperOffice quote connector will calculate this field based on the vat PERCENTAGES on the individual lines; other connectors may implement other algorithms at will.
Example:

SetVATInfo(String)

Returns: CRMScript.Global.Void
This field has no business logic in the CRM code, but is available as a merge field in the quote documents.
Example: