diff --git a/modules/invoiceIn/back/model-config.json b/modules/invoiceIn/back/model-config.json index 467d6f7f9..f0745f53b 100644 --- a/modules/invoiceIn/back/model-config.json +++ b/modules/invoiceIn/back/model-config.json @@ -2,6 +2,9 @@ "InvoiceIn": { "dataSource": "vn" }, + "InvoiceInTax": { + "dataSource": "vn" + }, "InvoiceInDueDay": { "dataSource": "vn" }, diff --git a/modules/invoiceIn/back/models/invoice-in-tax.json b/modules/invoiceIn/back/models/invoice-in-tax.json new file mode 100644 index 000000000..6a7f5e8a9 --- /dev/null +++ b/modules/invoiceIn/back/models/invoice-in-tax.json @@ -0,0 +1,55 @@ +{ + "name": "InvoiceIn", + "base": "Loggable", + "log": { + "model": "InvoiceInLog" + }, + "options": { + "mysql": { + "table": "invoiceIn" + } + }, + "properties": { + "id": { + "id": true, + "type": "Number", + "description": "Identifier" + }, + "taxableBase": { + "type": "number" + }, + "foreignValue": { + "type": "number" + }, + "created": { + "type": "date" + } + }, + "relations": { + "sageWithholding": { + "type": "belongsTo", + "model": "SageWithholding", + "foreignKey": "withholdingSageFk" + }, + "invoiceIn": { + "type": "belongsTo", + "model": "InvoiceIn", + "foreignKey": "invoiceInFk" + }, + "expence": { + "type": "belongsTo", + "model": "Expence", + "foreignKey": "expenceFk" + }, + "tiposIva": { + "type": "belongsTo", + "model": "TiposIva", + "foreignKey": "taxTypeSageFk" + }, + "transactionTypeSage": { + "type": "belongsTo", + "model": "TiposTransacciones", + "foreignKey": "transactionTypeSageFk" + } + } +} \ No newline at end of file diff --git a/modules/invoiceIn/back/models/sageIvaType.json b/modules/invoiceIn/back/models/sageIvaType.json new file mode 100644 index 000000000..a687a5460 --- /dev/null +++ b/modules/invoiceIn/back/models/sageIvaType.json @@ -0,0 +1,30 @@ +{ + "name": "SageIvaType", + "options": { + "mysql": { + "table": "sage.TiposIva" + } + }, + "properties": { + "id": { + "id": true, + "type": "Number", + "description": "Identifier", + "mysql": { + "columnName": "CodigoIva" + } + }, + "description": { + "type": "string", + "mysql": { + "columnName": "Iva" + } + }, + "rate": { + "type": "number", + "mysql": { + "columnName": "PorcentajeIva" + } + } + } +} \ No newline at end of file diff --git a/modules/invoiceIn/back/models/sageTransactionType.json b/modules/invoiceIn/back/models/sageTransactionType.json new file mode 100644 index 000000000..8856fecbc --- /dev/null +++ b/modules/invoiceIn/back/models/sageTransactionType.json @@ -0,0 +1,24 @@ +{ + "name": "sageTransactionType", + "options": { + "mysql": { + "table": "sage.TiposTransacciones" + } + }, + "properties": { + "id": { + "id": true, + "type": "Number", + "description": "Identifier", + "mysql": { + "columnName": "CodigoTransaccion" + } + }, + "description": { + "type": "string", + "mysql": { + "columnName": "Transaccion" + } + } + } +} \ No newline at end of file