Difference between revisions of "Appendix: Keywords"
(Created page with "In templates, it is possible to make use of keywords.<br/> Through these keywords, validated fields (that are not empty) can be used when the templates on the invoice are appl...") |
(No difference)
|
Revision as of 13:21, 5 September 2014
In templates, it is possible to make use of keywords.
Through these keywords, validated fields (that are not empty) can be used when the templates on the invoice are applied.
Keywords can only be used in text fields (Remarks on header level, Description on posting level), eventually in combination with fixed text.
1 Examples
Following examples are usefull:
Incoming: fe. invoice date = 28/08/2014, supplier = Belgacom
Consumption #{HEADERFIELD(SUPPCODE,NAME)} #{HEADERFIELD(INVDATE,yyyy)} —> Consumption Belgacom 2014
Consumption #{HEADERFIELD(INVDATE,yyyy)} —> Consumption 2014
Consumption #{HEADERFIELD(INVDATE,yyyy,-1y)} —> Consumption 2013
Consumption #{HEADERFIELD(INVDATE,yyyy,+1y)} —> Consumption 2015
Consumption #{HEADERFIELD(INVDATE,MM-yyyy)} —> Consumption 8-2014
Consumption month #{HEADERFIELD(INVDATE,MM,-1M)} —> Consumption month 7
Consumption month #{HEADERFIELD(INVDATE,MM)} —> Consumption month 8
Consumption month #{HEADERFIELD(INVDATE,MM,+1M)} —> Consumption month 9
Consumption #{HEADERFIELD(YEAR,CODE)} —> Consumption 2014
Outgoing: fe. invoice date = 28/08/2014, customer = Belgacom
Consumption #{HEADERFIELD(CUSTCODE,NAME)} #{HEADERFIELD(INVDATE,yyyy)} —> Consumption Belgacom 2014
When an incorrect keyword is given, an error will occur when the template is applied. |
Case sensitive! |
2 Date formats
Day = d
Month = M
Year = y
Hour = H
Minutes = m
End of month: EOM
Begin of month: BOM
3 list keywords
On several objects, keywords can be used on all the fields in the system.
Keyword function | Parameter 1 | Parameter 2 | Parameter 3 | Example |
---|---|---|---|---|
HEADERFIELD | SUPPCODE | CODE | Only incoming! #{HEADERFIELD(SUPPCODE,CODE)} --> 6 | |
SUPPCODE | NAME | Only incoming! #{HEADERFIELD(SUPPCODE,NAME)} --> Belgacom | ||
SUPPVATID | Only incoming! #{HEADERFIELD(SUPPVATID)} | |||
CUSTCODE | CODE | Only outgoing! #{HEADERFIELD(CUSTCODE,CODE)} --> 6 | ||
CUSTCODE | NAME | Only outgoing! #{HEADERFIELD(CUSTCODE,NAME)} --> Belgacom | ||
CUSTVATID | Only outgoing! #{HEADERFIELD(CUSTVATID)} | |||
JOURNAL | CODE | #{HEADERFIELD(JOURNAL,CODE)} | ||
JOURNAL | NAME | #{HEADERFIELD(JOURNAL,NAME)} | ||
INVOICENR | #{HEADERFIELD(INVOICENR)} | |||
INVDATE | dateformat | calculation | #{HEADERFIELD(INVDATE,yyyy,+1y)} --> 05/09/2014 becomes 2015 | |
COMMENT1 | #{HEADERFIELD(COMMENT1)} | |||
OGM | #{HEADERFIELD(OGM)} | |||
NETAMNT | #{HEADERFIELD(NETAMNT)} --> 100.00 | |||
VATAMNT | #{HEADERFIELD(VATAMNT)} --> 21.00 | |||
TOTAMNT | #{HEADERFIELD(TOTAMNT)} --> 121.00 | |||
CURRENCY | CODE | #{HEADERFIELD(CURRENCY,CODE)} --> EUR | ||
CURRENCY | NAME | #{HEADERFIELD(CURRENCY,NAME)} --> Euro | ||
YEAR | CODE | #{HEADERFIELD(YEAR,CODE)} | ||
YEAR | NAME | #{HEADERFIELD(YEAR,NAME)} | ||
TECHNICALFIELD | SCANBATCH | #{TECHNICALFIELD(SCANBATCH)} | ||
SCANUSER | #{TECHNICALFIELD(SCANUSER)} | |||
SCANNINGDATE | dateformat | calculation | #{TECHNICALFIELD(SCANNINGDATE,yyyyMMdd,EOM)} --> 05/09/2014 becomes 20140930 | |
INCOMINGDATE | dateformat | calculation | #{TECHNICALFIELD(INCOMINGDATE,yyyyMMdd,BOM)} --> 05/09/2014 becomes 20140901 | |
COMPANYNAME() | #{COMPANYNAME()} | |||
USERNAME() | #{USERNAME()} | |||
USERREALNAME() | #{USERREALNAME()} | |||
CURRENTDATE() | dateformat | calculation | #{CURRENTDATE(yyyyMMdd)} --> system date |