Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions codbex-payments/codbex-payments.edm
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<property name="CompanyIBAN" description="" tooltip="" dataName="CUSTOMERPAYMENT_COMPANYIBAN" dataType="VARCHAR" dataLength="34" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="34" widgetIsMajor="true"></property>
<property name="CounterpartyIBAN" description="" tooltip="" dataName="CUSTOMERPAYMENT_COUNTERPARTYIBAN" dataType="VARCHAR" dataLength="34" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="34" widgetIsMajor="true"></property>
<property name="CounterpartyName" description="" tooltip="" dataName="CUSTOMERPAYMENT_COUNTERPARTYNAME" dataType="VARCHAR" dataLength="100" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="100" widgetIsMajor="true"></property>
<property name="Amount" description="" tooltip="" dataName="CUSTOMERPAYMENT_AMOUNT" dataType="DECIMAL" dataNullable="false" dataPrecision="16" dataScale="2" dataLength="18" isRequiredProperty="true" widgetType="NUMBER" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Amount" description="" tooltip="" dataName="CUSTOMERPAYMENT_AMOUNT" dataType="DECIMAL" dataNullable="false" dataPrecision="16" dataScale="2" dataLength="16" isRequiredProperty="true" widgetType="NUMBER" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Currency" description="" tooltip="" dataName="CUSTOMERPAYMENT_CURRENCY" dataType="INTEGER" dataNullable="false" isRequiredProperty="true" widgetType="DROPDOWN" widgetSize="" widgetLength="20" widgetIsMajor="true" widgetDropDownKey="Id" widgetDropDownValue="Code"></property>
<property name="Reason" description="" tooltip="" dataName="CUSTOMERPAYMENT_REASON" dataType="VARCHAR" dataLength="100" dataNullable="false" isRequiredProperty="true" widgetType="TEXTBOX" widgetSize="" widgetLength="100" widgetIsMajor="true"></property>
<property name="Description" description="" tooltip="" dataName="CUSTOMERPAYMENT_DESCRIPTION" dataType="VARCHAR" dataLength="100" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="100" widgetIsMajor="true"></property>
Expand All @@ -26,7 +26,7 @@
<property name="CompanyIBAN" description="" tooltip="" dataName="SUPPLIERPAYMENT_COMPANYIBAN" dataType="VARCHAR" dataLength="34" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="34" widgetIsMajor="true"></property>
<property name="CounterpartyIBAN" description="" tooltip="" dataName="SUPPLIERPAYMENT_COUNTERPARTYIBAN" dataType="VARCHAR" dataLength="34" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="34" widgetIsMajor="true"></property>
<property name="CounterpartyName" description="" tooltip="" dataName="SUPPLIERPAYMENT_COUNTERPARTYNAME" dataType="VARCHAR" dataLength="100" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="100" widgetIsMajor="true"></property>
<property name="Amount" description="" tooltip="" dataName="SUPPLIERPAYMENT_AMOUNT" dataType="DECIMAL" dataNullable="false" dataPrecision="16" dataScale="2" dataLength="18" isRequiredProperty="true" widgetType="NUMBER" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Amount" description="" tooltip="" dataName="SUPPLIERPAYMENT_AMOUNT" dataType="DECIMAL" dataNullable="false" dataPrecision="16" dataScale="2" dataLength="16" isRequiredProperty="true" widgetType="NUMBER" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Currency" description="" tooltip="" dataName="SUPPLIERPAYMENT_CURRENCY" dataType="INTEGER" dataNullable="false" isRequiredProperty="true" widgetType="DROPDOWN" widgetSize="" widgetLength="20" widgetIsMajor="true" widgetDropDownKey="Id" widgetDropDownValue="Code"></property>
<property name="Reason" description="" tooltip="" dataName="SUPPLIERPAYMENT_REASON" dataType="VARCHAR" dataLength="100" dataNullable="false" isRequiredProperty="true" widgetType="TEXTBOX" widgetSize="" widgetLength="100" widgetIsMajor="true"></property>
<property name="Description" description="" tooltip="" dataName="SUPPLIERPAYMENT_DESCRIPTION" dataType="VARCHAR" dataLength="100" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="100" widgetIsMajor="true"></property>
Expand All @@ -42,7 +42,7 @@
<property name="CompanyIBAN" description="" tooltip="" dataName="EMPLOYEEPAYMENT_COMPANYIBAN" dataType="VARCHAR" dataLength="34" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="34" widgetIsMajor="true"></property>
<property name="CounterpartyIBAN" description="" tooltip="" dataName="EMPLOYEEPAYMENT_COUNTERPARTYIBAN" dataType="VARCHAR" dataLength="34" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="34" widgetIsMajor="true"></property>
<property name="CounterpartyName" description="" tooltip="" dataName="EMPLOYEEPAYMENT_COUNTERPARTYNAME" dataType="VARCHAR" dataLength="100" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="100" widgetIsMajor="true"></property>
<property name="Amount" description="" tooltip="" dataName="EMPLOYEEPAYMENT_AMOUNT" dataType="DECIMAL" dataNullable="false" dataPrecision="16" dataScale="2" dataLength="18" isRequiredProperty="true" widgetType="NUMBER" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Amount" description="" tooltip="" dataName="EMPLOYEEPAYMENT_AMOUNT" dataType="DECIMAL" dataNullable="false" dataPrecision="16" dataScale="2" dataLength="16" isRequiredProperty="true" widgetType="NUMBER" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Currency" description="" tooltip="" dataName="EMPLOYEEPAYMENT_CURRENCY" dataType="INTEGER" dataNullable="false" isRequiredProperty="true" widgetType="DROPDOWN" widgetSize="" widgetLength="20" widgetIsMajor="true" widgetDropDownKey="Id" widgetDropDownValue="Code"></property>
<property name="Reason" description="" tooltip="" dataName="EMPLOYEEPAYMENT_REASON" dataType="VARCHAR" dataLength="100" dataNullable="false" isRequiredProperty="true" widgetType="TEXTBOX" widgetSize="" widgetLength="100" widgetIsMajor="true"></property>
<property name="Description" description="" tooltip="" dataName="EMPLOYEEPAYMENT_DESCRIPTION" dataType="VARCHAR" dataLength="100" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="100" widgetIsMajor="true"></property>
Expand All @@ -58,7 +58,7 @@
<property name="CompanyIBAN" description="" tooltip="" dataName="PAYMENTRECORD_COMPANYIBAN" dataType="VARCHAR" dataLength="34" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="34" widgetIsMajor="true"></property>
<property name="CounterpartyIBAN" description="" tooltip="" dataName="PAYMENTRECORD_COUNTERPARTYIBAN" dataType="VARCHAR" dataLength="34" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="34" widgetIsMajor="true"></property>
<property name="CounterpartyName" description="" tooltip="" dataName="PAYMENTRECORD_COUNTERPARTYNAME" dataType="VARCHAR" dataLength="100" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Amount" description="" tooltip="" dataName="PAYMENTRECORD_AMOUNT" dataType="DECIMAL" dataNullable="true" dataPrecision="16" dataScale="2" dataLength="18" widgetType="NUMBER" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Amount" description="" tooltip="" dataName="PAYMENTRECORD_AMOUNT" dataType="DECIMAL" dataNullable="true" dataPrecision="16" dataScale="2" dataLength="16" widgetType="NUMBER" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Currency" description="" tooltip="" dataName="PAYMENTRECORD_CURRENCY" dataType="INTEGER" dataNullable="true" widgetType="DROPDOWN" widgetSize="" widgetLength="20" widgetIsMajor="true" widgetDropDownKey="Id" widgetDropDownValue="Code"></property>
<property name="Reason" description="" tooltip="" dataName="PAYMENTRECORD_REASON" dataType="VARCHAR" dataLength="100" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Description" description="" tooltip="" dataName="PAYMENTRECORD_DESCRIPTION" dataType="VARCHAR" dataLength="100" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
Expand Down Expand Up @@ -151,7 +151,7 @@
<property name="Id" description="" tooltip="" dataName="PAYMENTADJUSTMENT_ID" dataType="INTEGER" dataNullable="true" dataPrimaryKey="true" dataAutoIncrement="true" widgetType="TEXTBOX" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Date" description="" tooltip="" dataName="PAYMENTADJUSTMENT_DATE" dataType="DATE" dataNullable="true" isRequiredProperty="true" widgetType="DATE" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Valor" description="" tooltip="" dataName="PAYMENTADJUSTMENT_VALOR" dataType="DATE" dataNullable="true" isRequiredProperty="true" widgetType="DATE" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Amount" description="" tooltip="" dataName="PAYMENTADJUSTMENT_AMOUNT" dataType="DECIMAL" dataNullable="true" dataPrecision="16" dataScale="2" dataLength="18" isRequiredProperty="true" widgetType="NUMBER" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Amount" description="" tooltip="" dataName="PAYMENTADJUSTMENT_AMOUNT" dataType="DECIMAL" dataNullable="true" dataPrecision="16" dataScale="2" dataLength="16" isRequiredProperty="true" widgetType="NUMBER" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Currency" description="" tooltip="" dataName="PAYMENTADJUSTMENT_CURRENCY" dataType="INTEGER" dataNullable="true" isRequiredProperty="true" widgetType="DROPDOWN" widgetSize="" widgetLength="20" widgetIsMajor="true" widgetDropDownKey="Id" widgetDropDownValue="Name"></property>
<property name="Company" description="" tooltip="" dataName="PAYMENTADJUSTMENT_COMPANY" dataType="INTEGER" dataNullable="true" isRequiredProperty="true" widgetType="DROPDOWN" widgetSize="" widgetLength="20" widgetIsMajor="true" widgetDropDownKey="Id" widgetDropDownValue="Name"></property>
<property name="Reason" description="" tooltip="" dataName="PAYMENTADJUSTMENT_REASON" dataType="VARCHAR" dataLength="100" dataNullable="true" widgetType="TEXTBOX" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
Expand Down
8 changes: 8 additions & 0 deletions codbex-payments/codbex-payments.gen
Original file line number Diff line number Diff line change
Expand Up @@ -741,6 +741,8 @@
"genFolderName": "codbex-methods"
}
],
"dataOrderBy": "DESC",
"dataOrderBySort": "Date",
"primaryKeys": [
"Id"
],
Expand Down Expand Up @@ -1544,6 +1546,8 @@
"genFolderName": "codbex-companies"
}
],
"dataOrderBy": "DESC",
"dataOrderBySort": "Date",
"primaryKeys": [
"Id"
],
Expand Down Expand Up @@ -2337,6 +2341,8 @@
"genFolderName": "codbex-companies"
}
],
"dataOrderBy": "DESC",
"dataOrderBySort": "Date",
"primaryKeys": [
"Id"
],
Expand Down Expand Up @@ -3183,6 +3189,8 @@
"genFolderName": "codbex-companies"
}
],
"dataOrderBy": "DESC",
"dataOrderBySort": "Date",
"primaryKeys": [
"Id"
],
Expand Down
10 changes: 5 additions & 5 deletions codbex-payments/codbex-payments.model
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@
"widgetType": "TEXTBOX"
},
{
"dataLength": "18",
"dataLength": "16",
"dataName": "CUSTOMERPAYMENT_AMOUNT",
"dataNullable": "false",
"dataPrecision": "16",
Expand Down Expand Up @@ -375,7 +375,7 @@
"widgetType": "TEXTBOX"
},
{
"dataLength": "18",
"dataLength": "16",
"dataName": "SUPPLIERPAYMENT_AMOUNT",
"dataNullable": "false",
"dataPrecision": "16",
Expand Down Expand Up @@ -611,7 +611,7 @@
"widgetType": "TEXTBOX"
},
{
"dataLength": "18",
"dataLength": "16",
"dataName": "EMPLOYEEPAYMENT_AMOUNT",
"dataNullable": "false",
"dataPrecision": "16",
Expand Down Expand Up @@ -847,7 +847,7 @@
"widgetType": "TEXTBOX"
},
{
"dataLength": "18",
"dataLength": "16",
"dataName": "PAYMENTRECORD_AMOUNT",
"dataNullable": "true",
"dataPrecision": "16",
Expand Down Expand Up @@ -1845,7 +1845,7 @@
"widgetType": "DATE"
},
{
"dataLength": "18",
"dataLength": "16",
"dataName": "PAYMENTADJUSTMENT_AMOUNT",
"dataNullable": "true",
"dataPrecision": "16",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ export interface CustomerPaymentEntityOptions {
},
$select?: (keyof CustomerPaymentEntity)[],
$sort?: string | (keyof CustomerPaymentEntity)[],
$order?: 'asc' | 'desc',
$order?: 'ASC' | 'DESC',
$offset?: number,
$limit?: number,
}
Expand Down Expand Up @@ -295,19 +295,14 @@ export class CustomerPaymentRepository {
private readonly dao;

constructor(dataSource = "DefaultDB") {
this.dao = daoApi.create(CustomerPaymentRepository.DEFINITION, null, dataSource);
this.dao = daoApi.create(CustomerPaymentRepository.DEFINITION, undefined, dataSource);
}

public findAll(options?: CustomerPaymentEntityOptions): CustomerPaymentEntity[] {
// @ts-ignore
if (options.$sort === undefined) {
// @ts-ignore
options.$sort = "";
public findAll(options: CustomerPaymentEntityOptions = {}): CustomerPaymentEntity[] {
if (options.$sort === undefined && options.$order === undefined) {
options.$sort = "Date";
options.$order = "DESC";
}
// @ts-ignore
options.$sort += "Date,";
// @ts-ignore
options.$order = "DESC";
return this.dao.list(options).map((e: CustomerPaymentEntity) => {
EntityUtils.setDate(e, "Date");
EntityUtils.setDate(e, "Valor");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ export interface EmployeePaymentEntityOptions {
},
$select?: (keyof EmployeePaymentEntity)[],
$sort?: string | (keyof EmployeePaymentEntity)[],
$order?: 'asc' | 'desc',
$order?: 'ASC' | 'DESC',
$offset?: number,
$limit?: number,
}
Expand Down Expand Up @@ -267,19 +267,14 @@ export class EmployeePaymentRepository {
private readonly dao;

constructor(dataSource = "DefaultDB") {
this.dao = daoApi.create(EmployeePaymentRepository.DEFINITION, null, dataSource);
this.dao = daoApi.create(EmployeePaymentRepository.DEFINITION, undefined, dataSource);
}

public findAll(options?: EmployeePaymentEntityOptions): EmployeePaymentEntity[] {
// @ts-ignore
if (options.$sort === undefined) {
// @ts-ignore
options.$sort = "";
public findAll(options: EmployeePaymentEntityOptions = {}): EmployeePaymentEntity[] {
if (options.$sort === undefined && options.$order === undefined) {
options.$sort = "Date";
options.$order = "DESC";
}
// @ts-ignore
options.$sort += "Date,";
// @ts-ignore
options.$order = "DESC";
return this.dao.list(options).map((e: EmployeePaymentEntity) => {
EntityUtils.setDate(e, "Date");
EntityUtils.setDate(e, "Valor");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ export interface PaymentAdjustmentEntityOptions {
},
$select?: (keyof PaymentAdjustmentEntity)[],
$sort?: string | (keyof PaymentAdjustmentEntity)[],
$order?: 'asc' | 'desc',
$order?: 'ASC' | 'DESC',
$offset?: number,
$limit?: number,
}
Expand Down Expand Up @@ -176,10 +176,10 @@ export class PaymentAdjustmentRepository {
private readonly dao;

constructor(dataSource = "DefaultDB") {
this.dao = daoApi.create(PaymentAdjustmentRepository.DEFINITION, null, dataSource);
this.dao = daoApi.create(PaymentAdjustmentRepository.DEFINITION, undefined, dataSource);
}

public findAll(options?: PaymentAdjustmentEntityOptions): PaymentAdjustmentEntity[] {
public findAll(options: PaymentAdjustmentEntityOptions = {}): PaymentAdjustmentEntity[] {
return this.dao.list(options).map((e: PaymentAdjustmentEntity) => {
EntityUtils.setDate(e, "Date");
EntityUtils.setDate(e, "Valor");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ export interface PaymentRecordEntityOptions {
},
$select?: (keyof PaymentRecordEntity)[],
$sort?: string | (keyof PaymentRecordEntity)[],
$order?: 'asc' | 'desc',
$order?: 'ASC' | 'DESC',
$offset?: number,
$limit?: number,
}
Expand Down Expand Up @@ -305,19 +305,14 @@ export class PaymentRecordRepository {
private readonly dao;

constructor(dataSource = "DefaultDB") {
this.dao = daoApi.create(PaymentRecordRepository.DEFINITION, null, dataSource);
this.dao = daoApi.create(PaymentRecordRepository.DEFINITION, undefined, dataSource);
}

public findAll(options?: PaymentRecordEntityOptions): PaymentRecordEntity[] {
// @ts-ignore
if (options.$sort === undefined) {
// @ts-ignore
options.$sort = "";
public findAll(options: PaymentRecordEntityOptions = {}): PaymentRecordEntity[] {
if (options.$sort === undefined && options.$order === undefined) {
options.$sort = "Date";
options.$order = "DESC";
}
// @ts-ignore
options.$sort += "Date,";
// @ts-ignore
options.$order = "DESC";
return this.dao.list(options).map((e: PaymentRecordEntity) => {
EntityUtils.setDate(e, "Date");
EntityUtils.setDate(e, "Valor");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export interface PaymentRecordDirectionEntityOptions {
},
$select?: (keyof PaymentRecordDirectionEntity)[],
$sort?: string | (keyof PaymentRecordDirectionEntity)[],
$order?: 'asc' | 'desc',
$order?: 'ASC' | 'DESC',
$offset?: number,
$limit?: number,
}
Expand Down Expand Up @@ -92,10 +92,10 @@ export class PaymentRecordDirectionRepository {
private readonly dao;

constructor(dataSource = "DefaultDB") {
this.dao = daoApi.create(PaymentRecordDirectionRepository.DEFINITION, null, dataSource);
this.dao = daoApi.create(PaymentRecordDirectionRepository.DEFINITION, undefined, dataSource);
}

public findAll(options?: PaymentRecordDirectionEntityOptions): PaymentRecordDirectionEntity[] {
public findAll(options: PaymentRecordDirectionEntityOptions = {}): PaymentRecordDirectionEntity[] {
return this.dao.list(options);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export interface PaymentStatusEntityOptions {
},
$select?: (keyof PaymentStatusEntity)[],
$sort?: string | (keyof PaymentStatusEntity)[],
$order?: 'asc' | 'desc',
$order?: 'ASC' | 'DESC',
$offset?: number,
$limit?: number,
}
Expand Down Expand Up @@ -92,10 +92,10 @@ export class PaymentStatusRepository {
private readonly dao;

constructor(dataSource = "DefaultDB") {
this.dao = daoApi.create(PaymentStatusRepository.DEFINITION, null, dataSource);
this.dao = daoApi.create(PaymentStatusRepository.DEFINITION, undefined, dataSource);
}

public findAll(options?: PaymentStatusEntityOptions): PaymentStatusEntity[] {
public findAll(options: PaymentStatusEntityOptions = {}): PaymentStatusEntity[] {
return this.dao.list(options);
}

Expand Down
Loading