Dans cet article
In Banana Accounting javascript extensions, when referring to tables and columns, you must always use the correct nameXml.
Each table and each column has a proper nameXml. With the nameXml, tables and columns can be accessed to read the data they contain.
All columns of Items table are shown below with their nameXml.
Items table
The Items table is used to enter all the inventory items which need to be managed.
All nameXml of the table columns are listed below:
- SysCod
- Links
This column is used to indicate the link to an external file. - Section
- Group
This column is used to create a total row using the grouping system. - ItemsId
This column is used to indicate the item identifier. - Description
This column is used to indicate a text description of the item. - Notes
This column is used to indicate a personal note. - Gr
This column is used to indicate the grouping for each item, specifying which totalization group it belongs to. - Disable
- Account
This column is linked with the Account column of Accounts table. It is used to indicate the account used in the Transactions table. - VatCode
This column is linked with the VatCode column of VatCodes table. It is used to indicate the VAT code to use. - ReferenceUnit
This column is used to indicate an abbreviation to define the type to which the quantity refers. - SellingPrice
This column is used to indicate the unit sale price. - Cost
This column is used to indicate the unit cost price. - QuantityBegin
This column is used to indicate the initial quantity amount of the item. - UnitPriceBegin
This column is used to indicate the initial unit price of the item. - ValueBegin
This column is used to indicate the initial quantity multiplied by Price Begin. - QuantityCurrent
This column is used to indicate the current quantity. - UnitPriceCurrent
This column is used to indicate the current price of the item. - ValueCurrent
This column is used to indicate the current quantity multiplied by current price.
For the multy-currency accounting file type, there are additional columns for the Items table. The nameXml of the additional columns are listed below:
- Currency
- ValueBeginCurrency
- ExchangeBegin
- CurrencyCurrentValue
- ExchangeCurrent
Items columns structure
The list of columns is shown below in JSON format, with also additional information for each column.
{
"nameXml": "Items",
"columns": [
{
"nameXml": "SysCod",
"alignment": "left",
"dataType": "text",
"decimal": "",
"description": "",
"excludeFromPrinting": "",
"header": "SysCod",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": "",
"editable": "",
"width": 100
},
{
"nameXml": "Links",
"alignment": "left",
"dataType": "links",
"decimal": "",
"description": "Links to external documents",
"excludeFromPrinting": "",
"header": "Links",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": "",
"editable": true,
"width": 600
},
{
"nameXml": "Section",
"alignment": "left",
"dataType": "text",
"decimal": "",
"description": "",
"excludeFromPrinting": "",
"header": "Section",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": "",
"editable": true,
"width": 120
},
{
"nameXml": "Group",
"alignment": "left",
"dataType": "text",
"decimal": "",
"description": " Group name",
"excludeFromPrinting": "",
"header": " Group",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": true,
"editable": true,
"width": 100
},
{
"nameXml": "ItemsId",
"alignment": "right",
"dataType": "text",
"decimal": "",
"description": "Items Id",
"excludeFromPrinting": "",
"header": "Item",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": true,
"editable": true,
"width": 150
},
{
"nameXml": "Description",
"alignment": "left",
"dataType": "text",
"decimal": "",
"description": "",
"excludeFromPrinting": "",
"header": "Description",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": true,
"editable": true,
"width": 600
},
{
"nameXml": "Notes",
"alignment": "left",
"dataType": "text",
"decimal": "",
"description": "Notes",
"excludeFromPrinting": "",
"header": "Notes",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": "",
"editable": true,
"width": 600
},
{
"nameXml": "Gr",
"alignment": "center",
"dataType": "text",
"decimal": "",
"description": "Sum in the indicated Group",
"excludeFromPrinting": "",
"header": "Sum In",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": true,
"editable": true,
"width": 125
},
{
"nameXml": "Disable",
"alignment": "left",
"dataType": "text",
"decimal": "",
"description": "Disable account or group",
"excludeFromPrinting": "",
"header": "Disable",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": "",
"editable": true,
"width": 100
},
{
"nameXml": "Account",
"alignment": "left",
"dataType": "text",
"decimal": "",
"description": "Account number",
"excludeFromPrinting": "",
"header": "Account",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": true,
"editable": true,
"width": 125
},
{
"nameXml": "VatCode",
"alignment": "left",
"dataType": "text",
"decimal": "",
"description": "VAT/Sales tax code",
"excludeFromPrinting": "",
"header": "VAT code",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": true,
"editable": true,
"width": 125
},
{
"nameXml": "ReferenceUnit",
"alignment": "center",
"dataType": "text",
"decimal": "",
"description": "Reference unit",
"excludeFromPrinting": "",
"header": "Unit",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": true,
"editable": true,
"width": 100
},
{
"nameXml": "SellingPrice",
"alignment": "right",
"dataType": "amount",
"decimal": 4,
"description": "Selling price",
"excludeFromPrinting": "",
"header": "Selling",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": true,
"editable": true,
"width": 125
},
{
"nameXml": "Cost",
"alignment": "right",
"dataType": "amount",
"decimal": 4,
"description": "Product cost",
"excludeFromPrinting": "",
"header": "Cost",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": true,
"editable": true,
"width": 125
},
{
"nameXml": "QuantityBegin",
"alignment": "right",
"dataType": "amount",
"decimal": 4,
"description": "Begin quantity",
"excludeFromPrinting": "",
"header": "Begin Qt.",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": "",
"editable": true,
"width": 125
},
{
"nameXml": "UnitPriceBegin",
"alignment": "right",
"dataType": "amount",
"decimal": 4,
"description": "Begin unit price",
"excludeFromPrinting": "",
"header": "Price Begin",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": "",
"editable": true,
"width": 125
},
{
"nameXml": "ValueBegin",
"alignment": "right",
"dataType": "amount",
"decimal": 2,
"description": "Value begin",
"excludeFromPrinting": "",
"header": "Value Begin",
"header2": "CHF",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": "",
"editable": "",
"width": 250
},
{
"nameXml": "QuantityCurrent",
"alignment": "right",
"dataType": "amount",
"decimal": 4,
"description": "Current quantity",
"excludeFromPrinting": "",
"header": "Current Qt.",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": "",
"editable": "",
"width": 125
},
{
"nameXml": "UnitPriceCurrent",
"alignment": "right",
"dataType": "amount",
"decimal": 4,
"description": "Current unit price",
"excludeFromPrinting": "",
"header": "Price Current",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": "",
"editable": true,
"width": 125
},
{
"nameXml": "ValueCurrent",
"alignment": "right",
"dataType": "amount",
"decimal": 2,
"description": "Value current",
"excludeFromPrinting": "",
"header": "Value Current",
"header2": "CHF",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": "",
"editable": "",
"width": 250
}
]
}
For the multy-currency accounting file type, there are additional columns.
The list of the additional columns is shown below in JSON format, with also the information for each column.
{
"nameXml": "Currency",
"alignment": "left",
"dataType": "text",
"decimal": "",
"description": "Currency",
"excludeFromPrinting": "",
"header": "Currency",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": true,
"editable": true,
"width": 268
},
{
"nameXml": "ValueBeginCurrency",
"alignment": "right",
"dataType": "amount",
"decimal": 2,
"description": "Value begin currecy",
"excludeFromPrinting": "",
"header": "V. begin currency",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": "",
"editable": "",
"width": 250
},
{
"nameXml": "ExchangeBegin",
"alignment": "right",
"dataType": "number",
"decimal": 12,
"description": "Exchange begin",
"excludeFromPrinting": "",
"header": "Exch. begin",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": "",
"editable": true,
"width": 250
},
{
"nameXml": "CurrencyCurrentValue",
"alignment": "right",
"dataType": "amount",
"decimal": 2,
"description": "Currency current value",
"excludeFromPrinting": "",
"header": "Currency V.",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": true,
"editable": "",
"width": 250
},
{
"nameXml": "ExchangeCurrent",
"alignment": "right",
"dataType": "number",
"decimal": 12,
"description": "Exchange current",
"excludeFromPrinting": "",
"header": "Exchange",
"header2": "",
"style": {
"objectName": "",
"backgroundColor": "",
"color": "",
"fontSize": 10,
"bold": false,
"italic": false
},
"visible": "",
"editable": true,
"width": 250
}