{
	"name": "table/external/moloni/order/order-credit_note.json",
	"table_name": "order",
	"table_prefix": "ord",
	"record_type": ["credit_note"],
	"local_table": "order",
	"local_record_type": "credit_note",
	"format": {
		"date": "%Y-%m-%dT%H:%M:%S%z"
	},
	"field": [
		{
			"field_name": "our_reference",
			"local_field": "order_id",
			"field_type": "text"
		},
		{
			"field_name": "json_data.fake_record_id",
			"local_field": "record_id",
			"field_type": "text",
			"writeable": false
		},
		{
			"field_name": "date",
			"local_field": "order_date",
			"field_type": "date"
		},
		{
			"field_name": "customer_id",
			"local_field": "co.json_data.transfer_id",
			"field_type": "integer"
		},
		{
			"field_name": "document_set_id",
			"local_field": "order_type",
			"field_type": "integer",
			"default_value": 438501
		},
		{
			"field_name": "your_reference",
			"local_field": "company_reference_number",
			"field_type": "text"
		},
		{
			"field_name": "status",
			"local_field": "order_state",
			"field_type": "integer",
			"local_field2": "json_data.status"
		},
		{
			"field_name": "lastmodified",
			"local_field": "modify_time",
			"field_type": "timestamp"
		},
		{
			"field_name": "gross_value",
			"local_field": "price_without_vat",
			"field_type": "double",
			"positive_value": true
		},
		{
			"field_name": "net_value",
			"local_field": "price_with_vat",
			"field_type": "double",
			"positive_value": true
		},
		{
			"field_name": "taxes_value",
			"local_field": "vat_price",
			"field_type": "number",
			"positive_value": true
		},
		{
			"field_name": "notes",
			"local_field": "note",
			"field_type": "string"
		},
		{
			"field_name": "associated_documents[1].associated_id",
			"local_field": "json_data.transfer_id",
			"field_type": "number"
		},
		{
			"field_name": "associated_documents[1].value",
			"local_field": "json_data.associated_documents_value",
			"field_type": "number",
			"default_value": "0"
		}
	]
}
