diff --git a/src/components/ADempiere/DataTable/Components/CellDisplayInfo.vue b/src/components/ADempiere/DataTable/Components/CellDisplayInfo.vue
index 611023035a4..47690ae48f3 100644
--- a/src/components/ADempiere/DataTable/Components/CellDisplayInfo.vue
+++ b/src/components/ADempiere/DataTable/Components/CellDisplayInfo.vue
@@ -34,7 +34,7 @@
/> -->
@@ -191,16 +191,16 @@ export default defineComponent({
value: currentValue,
currency: props.dataRow[DISPLAY_COLUMN_PREFIX + CURRENCY],
displayedValue: props.dataRow[displayColumnName.value],
- displayType: props.fieldAttributes.displayType
+ displayType: props.fieldAttributes.display_type
})
})
const cellCssClass = computed(() => {
let classCss = ''
- if (isNumberField(props.fieldAttributes.displayType) || props.fieldAttributes.componentPath === 'FieldNumber') {
+ if (isNumberField(props.fieldAttributes.display_type) || props.fieldAttributes.componentPath === 'FieldNumber') {
classCss = ' cell-align-right '
}
- if (props.fieldAttributes.isColumnDocumentStatus || props.fieldAttributes.displayType === IMAGE.id) {
+ if (props.fieldAttributes.isColumnDocumentStatus || props.fieldAttributes.display_type === IMAGE.id) {
classCss = ' cell-align-center '
}
return classCss
diff --git a/src/components/ADempiere/DataTable/Components/CellEditInfo.vue b/src/components/ADempiere/DataTable/Components/CellEditInfo.vue
index f9ec48929a7..fc565fab47b 100644
--- a/src/components/ADempiere/DataTable/Components/CellEditInfo.vue
+++ b/src/components/ADempiere/DataTable/Components/CellEditInfo.vue
@@ -116,7 +116,7 @@ export default defineComponent({
})
const isRowChangeEdited = computed(() => {
- if ([BINARY_DATA.id, IMAGE.id].includes(props.fieldAttributes.displayType)) {
+ if ([BINARY_DATA.id, IMAGE.id].includes(props.fieldAttributes.display_type)) {
return false
}
if (props.dataRow.isEditRow && !isReadOnly.value) {
diff --git a/src/components/ADempiere/FieldDefinition/FieldAccountingCombination/tableQueryCriteria2.vue b/src/components/ADempiere/FieldDefinition/FieldAccountingCombination/tableQueryCriteria2.vue
index 62518ed0904..10391876df6 100644
--- a/src/components/ADempiere/FieldDefinition/FieldAccountingCombination/tableQueryCriteria2.vue
+++ b/src/components/ADempiere/FieldDefinition/FieldAccountingCombination/tableQueryCriteria2.vue
@@ -45,7 +45,7 @@
:span="6"
>
{
- // return field.displayType === field.displayType === CHAR.id
+ // return field.display_type === CHAR.id
return field.identifierSequence > 0
})
.sort((fieldA, fieldB) => {
@@ -251,12 +251,12 @@ export default {
// }
// find on identifier columns
for (const field of this.storedIdentifierColumns) {
- const { columnName, displayColumnName, displayType } = field
+ const { columnName, displayColumnName, display_type } = field
const currentValue = formatField({
value: row[columnName],
displayedValue: row[displayColumnName],
- displayType
+ displayType: display_type
})
const valueToCompare = String(currentValue).toLowerCase()
@@ -344,12 +344,12 @@ export default {
// generate with identifier columns
this.storedIdentifierColumns.forEach(field => {
- const { columnName, displayColumnName, displayType } = field
+ const { columnName, displayColumnName, display_type } = field
const currentValue = formatField({
value: row[columnName],
displayedValue: row[displayColumnName],
- displayType
+ displayType: display_type
})
if (isEmptyValue(currentValue)) {
diff --git a/src/components/ADempiere/FieldDefinition/FieldSelect/index.vue b/src/components/ADempiere/FieldDefinition/FieldSelect/index.vue
index 91845a9ccf7..97ab794f143 100644
--- a/src/components/ADempiere/FieldDefinition/FieldSelect/index.vue
+++ b/src/components/ADempiere/FieldDefinition/FieldSelect/index.vue
@@ -91,7 +91,7 @@ export default {
isFiltrable() {
if (this.isMobile) {
- if (LIST.id === this.metadata.displayType) {
+ if (LIST.id === this.metadata.display_type) {
return false
}
}
@@ -352,17 +352,17 @@ export default {
}
},
remoteSearch(searchQuery = '') {
- const results = this.localSearch(searchQuery)
- if (isEmptyValue(searchQuery) ||
- (!isEmptyValue(searchQuery) && (isEmptyValue(results) || results.length < 3))) {
- clearTimeout(this.timeOut)
- this.timeOut = setTimeout(() => {
- this.loadListFromServer(searchQuery)
- }, 500)
- return
- }
+ // const results = this.localSearch(searchQuery)
+ // if (isEmptyValue(searchQuery) ||
+ // (!isEmptyValue(searchQuery) && (isEmptyValue(results) || results.length < 3))) {
+ clearTimeout(this.timeOut)
+ this.timeOut = setTimeout(() => {
+ this.loadListFromServer(searchQuery)
+ }, 500)
+ // return
+ // }
// use this, if remote is enabled, local search not working
- this.optionsList = results
+ // this.optionsList = results
},
localSearch(searchQuery = '') {
if (isEmptyValue(searchQuery)) {
diff --git a/src/components/ADempiere/FieldDefinition/FieldText.vue b/src/components/ADempiere/FieldDefinition/FieldText.vue
index 71e2aa27431..2c524004117 100644
--- a/src/components/ADempiere/FieldDefinition/FieldText.vue
+++ b/src/components/ADempiere/FieldDefinition/FieldText.vue
@@ -1,19 +1,19 @@
@@ -86,7 +86,7 @@ export default {
computed: {
cssClassCustomField() {
- if (this.metadata.displayType === TEXT.id) {
+ if (this.metadata.display_type === TEXT.id) {
return ' custom-field-textarea '
}
return ' custom-field-text '
@@ -102,7 +102,7 @@ export default {
// String, Url, FileName...
let typeInput = 'text'
// Display Type 'Text' (14)
- if (this.metadata.displayType === TEXT.id) {
+ if (this.metadata.display_type === TEXT.id) {
typeInput = 'textarea'
}
if (this.metadata.isEncrypted) {
diff --git a/src/components/ADempiere/FieldDefinition/index.vue b/src/components/ADempiere/FieldDefinition/index.vue
index 893285c4a2b..6af958269c9 100644
--- a/src/components/ADempiere/FieldDefinition/index.vue
+++ b/src/components/ADempiere/FieldDefinition/index.vue
@@ -179,7 +179,7 @@ export default {
if (['FieldTextLong', 'FieldImage'].includes(this.field.componentPath)) {
return 'field-text-long'
}
- if ([TEXT.id].includes(this.field.displayType)) {
+ if ([TEXT.id].includes(this.field.display_type)) {
return 'field-text-area'
}
return 'field-standard'
@@ -365,7 +365,7 @@ export default {
},
isOnlyField() {
- return this.field.isFieldOnly || [BUTTON.id].includes(this.field.displayType)
+ return this.field.isFieldOnly || [BUTTON.id].includes(this.field.display_type)
},
currentTab() {
if (this.isEmptyValue(this.parentUuid) || !this.containerManager.getPanel) {
@@ -435,7 +435,7 @@ export default {
// assined field with prop
this.field = this.metadataField
if (this.field.isCustomField && !this.field.componentPath) {
- let componentReference = evalutateTypeField(this.field.displayType)
+ let componentReference = evalutateTypeField(this.field.display_type)
if (isEmptyValue(componentReference)) {
componentReference = {
componentPath: 'FieldText'
diff --git a/src/components/ADempiere/FieldDefinition/indexApiComposition.vue b/src/components/ADempiere/FieldDefinition/indexApiComposition.vue
index 6657e8c496f..70936b1c7e5 100644
--- a/src/components/ADempiere/FieldDefinition/indexApiComposition.vue
+++ b/src/components/ADempiere/FieldDefinition/indexApiComposition.vue
@@ -139,7 +139,7 @@ export default defineComponent({
if (['FieldTextLong', 'FieldImage'].includes(field.value.componentPath)) {
return 'field-text-long'
}
- if ([TEXT.id].includes(field.value.displayType)) {
+ if ([TEXT.id].includes(field.value.display_type)) {
return 'field-text-area'
}
return 'field-standard'
@@ -282,7 +282,7 @@ export default defineComponent({
// assined field with prop
if (field.value.isCustomField && !field.value.componentPath) {
- let componentReference = evalutateTypeField(field.value.displayType)
+ let componentReference = evalutateTypeField(field.value.display_type)
if (isEmptyValue(componentReference)) {
componentReference = {
componentPath: 'FieldText'
diff --git a/src/components/ADempiere/FieldDefinition/mixin/mixinWithDisplayColumn.js b/src/components/ADempiere/FieldDefinition/mixin/mixinWithDisplayColumn.js
index 0b02d66956d..f7ce3506c0f 100644
--- a/src/components/ADempiere/FieldDefinition/mixin/mixinWithDisplayColumn.js
+++ b/src/components/ADempiere/FieldDefinition/mixin/mixinWithDisplayColumn.js
@@ -101,9 +101,9 @@ export default {
}
}
- const { displayColumnName: columnName, containerUuid, inTable, displayType } = this.metadata
+ const { displayColumnName: columnName, containerUuid, inTable, display_type } = this.metadata
- if (isEmptyValue(this.value) && displayType === IMAGE.id) {
+ if (isEmptyValue(this.value) && display_type === IMAGE.id) {
return undefined
}
diff --git a/src/components/ADempiere/Form/VPOS/BusinessPartner/AddNewFieldLocation/fieldsList.js b/src/components/ADempiere/Form/VPOS/BusinessPartner/AddNewFieldLocation/fieldsList.js
index e05dbab69e0..cf19edf2d08 100644
--- a/src/components/ADempiere/Form/VPOS/BusinessPartner/AddNewFieldLocation/fieldsList.js
+++ b/src/components/ADempiere/Form/VPOS/BusinessPartner/AddNewFieldLocation/fieldsList.js
@@ -1,18 +1,20 @@
-// ADempiere-Vue (Frontend) for ADempiere ERP & CRM Smart Business Solution
-// Copyright (C) 2017-Present E.R.P. Consultores y Asociados, C.A.
-// Contributor(s): Yamel Senih ysenih@erpya.com www.erpya.com
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see .
+/**
+ * ADempiere-Vue (Frontend) for ADempiere ERP & CRM Smart Business Solution
+ * Copyright (C) 2017-Present E.R.P. Consultores y Asociados, C.A. www.erpya.com
+ * Contributor(s): Edwin Betancourt EdwinBetanc0urt@outlook.com https://github.com/EdwinBetanc0urt
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
import language from '@/lang'
@@ -61,7 +63,7 @@ export default [
isCustomField: true,
is_updateable: true,
size: 24,
- displayType: 19,
+ display_type: 19,
sequenceFields: 'C',
index: 4,
isMandatory: true
diff --git a/src/components/ADempiere/Form/VPOS/BusinessPartner/BillingFieldLocation/fieldsList.js b/src/components/ADempiere/Form/VPOS/BusinessPartner/BillingFieldLocation/fieldsList.js
index e05dbab69e0..cf19edf2d08 100644
--- a/src/components/ADempiere/Form/VPOS/BusinessPartner/BillingFieldLocation/fieldsList.js
+++ b/src/components/ADempiere/Form/VPOS/BusinessPartner/BillingFieldLocation/fieldsList.js
@@ -1,18 +1,20 @@
-// ADempiere-Vue (Frontend) for ADempiere ERP & CRM Smart Business Solution
-// Copyright (C) 2017-Present E.R.P. Consultores y Asociados, C.A.
-// Contributor(s): Yamel Senih ysenih@erpya.com www.erpya.com
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see .
+/**
+ * ADempiere-Vue (Frontend) for ADempiere ERP & CRM Smart Business Solution
+ * Copyright (C) 2017-Present E.R.P. Consultores y Asociados, C.A. www.erpya.com
+ * Contributor(s): Edwin Betancourt EdwinBetanc0urt@outlook.com https://github.com/EdwinBetanc0urt
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
import language from '@/lang'
@@ -61,7 +63,7 @@ export default [
isCustomField: true,
is_updateable: true,
size: 24,
- displayType: 19,
+ display_type: 19,
sequenceFields: 'C',
index: 4,
isMandatory: true
diff --git a/src/components/ADempiere/Form/VPOS/BusinessPartner/billingAddressFieldLocation/fieldsList.js b/src/components/ADempiere/Form/VPOS/BusinessPartner/billingAddressFieldLocation/fieldsList.js
index e05dbab69e0..cf19edf2d08 100644
--- a/src/components/ADempiere/Form/VPOS/BusinessPartner/billingAddressFieldLocation/fieldsList.js
+++ b/src/components/ADempiere/Form/VPOS/BusinessPartner/billingAddressFieldLocation/fieldsList.js
@@ -1,18 +1,20 @@
-// ADempiere-Vue (Frontend) for ADempiere ERP & CRM Smart Business Solution
-// Copyright (C) 2017-Present E.R.P. Consultores y Asociados, C.A.
-// Contributor(s): Yamel Senih ysenih@erpya.com www.erpya.com
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see .
+/**
+ * ADempiere-Vue (Frontend) for ADempiere ERP & CRM Smart Business Solution
+ * Copyright (C) 2017-Present E.R.P. Consultores y Asociados, C.A. www.erpya.com
+ * Contributor(s): Edwin Betancourt EdwinBetanc0urt@outlook.com https://github.com/EdwinBetanc0urt
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
import language from '@/lang'
@@ -61,7 +63,7 @@ export default [
isCustomField: true,
is_updateable: true,
size: 24,
- displayType: 19,
+ display_type: 19,
sequenceFields: 'C',
index: 4,
isMandatory: true
diff --git a/src/components/ADempiere/Form/VPOS/BusinessPartner/fieldsListSearch.js b/src/components/ADempiere/Form/VPOS/BusinessPartner/fieldsListSearch.js
index 98616f70917..f150db57f6b 100644
--- a/src/components/ADempiere/Form/VPOS/BusinessPartner/fieldsListSearch.js
+++ b/src/components/ADempiere/Form/VPOS/BusinessPartner/fieldsListSearch.js
@@ -1,18 +1,21 @@
-// ADempiere-Vue (Frontend) for ADempiere ERP & CRM Smart Business Solution
-// Copyright (C) 2017-Present E.R.P. Consultores y Asociados, C.A.
-// Contributor(s): Elsio Sanchez elsiosanches@gmail.com https://github.com/elsiosanches
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
+/**
+ * ADempiere-Vue (Frontend) for ADempiere ERP & CRM Smart Business Solution
+ * Copyright (C) 2018-Present E.R.P. Consultores y Asociados, C.A. www.erpya.com
+ * Contributor(s): Elsio Sanchez elsiosanchez15@outlook.com https://github.com/elsiosanchez
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see .
import language from '@/lang'
// List of fields to send in search
@@ -26,7 +29,7 @@ export default [
size: 6,
name: language.t('form.pos.order.BusinessPartnerCreate.searchValue'),
componentPath: 'FieldText',
- displayType: 10,
+ display_type: 10,
isMandatory: false,
isCustomField: true
}
diff --git a/src/components/ADempiere/Form/VPOS/BusinessPartner/shippingFieldLocation/fieldsList.js b/src/components/ADempiere/Form/VPOS/BusinessPartner/shippingFieldLocation/fieldsList.js
index e05dbab69e0..cf19edf2d08 100644
--- a/src/components/ADempiere/Form/VPOS/BusinessPartner/shippingFieldLocation/fieldsList.js
+++ b/src/components/ADempiere/Form/VPOS/BusinessPartner/shippingFieldLocation/fieldsList.js
@@ -1,18 +1,20 @@
-// ADempiere-Vue (Frontend) for ADempiere ERP & CRM Smart Business Solution
-// Copyright (C) 2017-Present E.R.P. Consultores y Asociados, C.A.
-// Contributor(s): Yamel Senih ysenih@erpya.com www.erpya.com
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see .
+/**
+ * ADempiere-Vue (Frontend) for ADempiere ERP & CRM Smart Business Solution
+ * Copyright (C) 2017-Present E.R.P. Consultores y Asociados, C.A. www.erpya.com
+ * Contributor(s): Edwin Betancourt EdwinBetanc0urt@outlook.com https://github.com/EdwinBetanc0urt
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
import language from '@/lang'
@@ -61,7 +63,7 @@ export default [
isCustomField: true,
is_updateable: true,
size: 24,
- displayType: 19,
+ display_type: 19,
sequenceFields: 'C',
index: 4,
isMandatory: true
diff --git a/src/components/ADempiere/Form/VPOS/Collection/index.vue b/src/components/ADempiere/Form/VPOS/Collection/index.vue
index 41d33c514dc..8aafeb77990 100644
--- a/src/components/ADempiere/Form/VPOS/Collection/index.vue
+++ b/src/components/ADempiere/Form/VPOS/Collection/index.vue
@@ -430,7 +430,6 @@ import { processOrder } from '@/api/ADempiere/form/point-of-sales.js'
// Constants
import fieldsListCollection from './fieldsListCollection.js'
-import { FIELDS_DECIMALS } from '@/utils/ADempiere/references'
import { REPORT_VIEWER_NAME } from '@/utils/ADempiere/constants/report'
// Utils and Helper Methods
@@ -1197,14 +1196,6 @@ export default {
conversionDate: this.formatDateToSend(this.currentPointOfSales.currentOrder.dateOrdered)
})
},
- formatNumber({ displayType, number }) {
- let fixed = 0
- // Amount, Costs+Prices, Number
- if (FIELDS_DECIMALS.includes(displayType)) {
- fixed = 2
- }
- return new Intl.NumberFormat().format(number.toFixed(fixed))
- },
formatPrice,
sumCash(cash) {
let sum = 0
diff --git a/src/components/ADempiere/Form/VPOS/containerManagerPos.js b/src/components/ADempiere/Form/VPOS/containerManagerPos.js
index 717b567e3b6..23eed0ff34e 100644
--- a/src/components/ADempiere/Form/VPOS/containerManagerPos.js
+++ b/src/components/ADempiere/Form/VPOS/containerManagerPos.js
@@ -47,9 +47,9 @@ export function isMandatoryField({ isMandatory, isMandatoryFromLogic }) {
return isMandatory || isMandatoryFromLogic
}
-export function isDisplayedField({ displayType, is_displayed, isDisplayedFromLogic }) {
+export function isDisplayedField({ display_type, is_displayed, isDisplayedFromLogic }) {
// // button field not showed
- // if (isHiddenField(displayType)) {
+ // if (isHiddenField(display_type)) {
// return false
// }
// verify if field is active
diff --git a/src/components/ADempiere/FormDefinition/VBankStatementMatch/containerManagerFrom.ts b/src/components/ADempiere/FormDefinition/VBankStatementMatch/containerManagerFrom.ts
index b78b122dc7f..1c74a117e0b 100644
--- a/src/components/ADempiere/FormDefinition/VBankStatementMatch/containerManagerFrom.ts
+++ b/src/components/ADempiere/FormDefinition/VBankStatementMatch/containerManagerFrom.ts
@@ -18,9 +18,9 @@
// import { isHiddenField } from '@/utils/ADempiere/references'
-export const isDisplayedField = function({ displayType, is_displayed }) {
+export const isDisplayedField = function({ display_type, is_displayed }) {
// // button field not showed
- // if (isHiddenField(displayType)) {
+ // if (isHiddenField(display_type)) {
// return false
// }
// verify if field is active
diff --git a/src/components/ADempiere/PanelInfo/Component/RecordDashboard/chartFilter.vue b/src/components/ADempiere/PanelInfo/Component/RecordDashboard/chartFilter.vue
index a59396c88a9..7e592518c81 100644
--- a/src/components/ADempiere/PanelInfo/Component/RecordDashboard/chartFilter.vue
+++ b/src/components/ADempiere/PanelInfo/Component/RecordDashboard/chartFilter.vue
@@ -129,8 +129,8 @@ export default defineComponent({
* Methods
*/
- function isBoolean({ displayType }) {
- return displayType === YES_NO.id
+ function isBoolean({ display_type }) {
+ return display_type === YES_NO.id
}
function isRangeField({ is_range, columnName }) {
diff --git a/src/components/ADempiere/RecordAccess/recordAccess.js b/src/components/ADempiere/RecordAccess/recordAccess.js
index 233a0941a4b..4cce2e534a6 100644
--- a/src/components/ADempiere/RecordAccess/recordAccess.js
+++ b/src/components/ADempiere/RecordAccess/recordAccess.js
@@ -1,25 +1,27 @@
-// ADempiere-Vue (Frontend) for ADempiere ERP & CRM Smart Business Solution
-// Copyright (C) 2017-Present E.R.P. Consultores y Asociados, C.A.
-// Contributor(s): Yamel Senih ysenih@erpya.com www.erpya.com
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see .
+/**
+ * ADempiere-Vue (Frontend) for ADempiere ERP & CRM Smart Business Solution
+ * Copyright (C) 2018-Present E.R.P. Consultores y Asociados, C.A. www.erpya.com
+ * Contributor(s): Edwin Betancourt EdwinBetanc0urt@outlook.com https://github.com/EdwinBetanc0urt
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see .
+ */
import language from '@/lang'
-// api request methods
+// API Request Methods
import { setRecordAccess } from '@/api/ADempiere/actions/record-access.js'
-// utils and helpers methods
+// Utils and Helpers Methods
import { isLookup } from '@/utils/ADempiere/references'
import { showMessage } from '@/utils/ADempiere/notification.js'
@@ -95,7 +97,7 @@ export default {
},
getIdentifiersList() {
return this.identifiersList
- .filter(item => !isLookup(item.displayType))
+ .filter(item => !isLookup(item.display_type))
},
listRecordAccess() {
return this.$store.getters.getRecordAccess
diff --git a/src/store/modules/ADempiere/calloutManager.js b/src/store/modules/ADempiere/calloutManager.js
index f9b12dfe6bb..d9e895f035c 100644
--- a/src/store/modules/ADempiere/calloutManager.js
+++ b/src/store/modules/ADempiere/calloutManager.js
@@ -78,14 +78,14 @@ const calloutManager = {
const field = fieldsList.find(fieldItem => fieldItem.columnName === columnName)
let currentDisplayType = null
if (!isEmptyValue(field)) {
- currentDisplayType = field.displayType
+ currentDisplayType = field.display_type
} else {
// find on parent tab (first tab)
const parentField = fieldsListParent.find(fieldItem => {
return fieldItem.columnName === columnName
})
if (!isEmptyValue(parentField)) {
- currentDisplayType = parentField.displayType
+ currentDisplayType = parentField.display_type
}
}
if (getTypeOfValue(currentValue) !== 'OBJECT') {
diff --git a/src/store/modules/ADempiere/data/actions.js b/src/store/modules/ADempiere/data/actions.js
index f838ef7d21f..03b9d1f320a 100644
--- a/src/store/modules/ADempiere/data/actions.js
+++ b/src/store/modules/ADempiere/data/actions.js
@@ -383,7 +383,7 @@ const actions = {
tableName: field.tableName,
columnName: field.columnName,
callout: field.callout,
- displayType: field.displayType,
+ displayType: field.display_type,
value: newValue,
withOutColumnNames,
row,
diff --git a/src/store/modules/ADempiere/dictionary/browser/actions.js b/src/store/modules/ADempiere/dictionary/browser/actions.js
index d5819f3b1bb..07da55aeda6 100644
--- a/src/store/modules/ADempiere/dictionary/browser/actions.js
+++ b/src/store/modules/ADempiere/dictionary/browser/actions.js
@@ -87,7 +87,7 @@ export default {
browserDefinition.fieldsList.forEach(fieldItem => {
browserDefinition.elementsList[fieldItem.columnName] = fieldItem.elementName
browserDefinition.columnsList[fieldItem.elementName] = fieldItem.columnName
- if (isLookup(fieldItem.displayType)) {
+ if (isLookup(fieldItem.display_type)) {
browserDefinition.elementsList[DISPLAY_COLUMN_PREFIX + fieldItem.columnName] = DISPLAY_COLUMN_PREFIX + fieldItem.elementName
browserDefinition.columnsList[DISPLAY_COLUMN_PREFIX + fieldItem.elementName] = DISPLAY_COLUMN_PREFIX + fieldItem.columnName
}
diff --git a/src/store/modules/ADempiere/dictionary/browser/getters.js b/src/store/modules/ADempiere/dictionary/browser/getters.js
index 2392c103d18..5d22a5d002f 100644
--- a/src/store/modules/ADempiere/dictionary/browser/getters.js
+++ b/src/store/modules/ADempiere/dictionary/browser/getters.js
@@ -99,7 +99,7 @@ export default {
columnName
})
- if (fieldItem.is_range && !isNumberField(fieldItem.displayType)) {
+ if (fieldItem.is_range && !isNumberField(fieldItem.display_type)) {
const valueTo = rootGetters.getValueOfField({
containerUuid,
columnName: fieldItem.columnNameTo
@@ -141,7 +141,7 @@ export default {
fieldsList.forEach(fieldItem => {
// default operator
- const { is_info_only, columnName, columnNameTo, operator, displayType } = fieldItem
+ const { is_info_only, columnName, columnNameTo, operator, display_type } = fieldItem
if (is_info_only) {
return false
}
@@ -167,7 +167,7 @@ export default {
return
}
// TODO: Improve conditions
- if (FIELDS_DATE.includes(displayType)) {
+ if (FIELDS_DATE.includes(display_type)) {
if (MULTIPLE_VALUES_OPERATORS_LIST.includes(operator)) {
values = contextValue
} else if (RANGE_VALUE_OPERATORS_LIST.includes(operator)) {
diff --git a/src/store/modules/ADempiere/dictionary/process/getters.js b/src/store/modules/ADempiere/dictionary/process/getters.js
index 15827e37a34..89bc7f008c1 100644
--- a/src/store/modules/ADempiere/dictionary/process/getters.js
+++ b/src/store/modules/ADempiere/dictionary/process/getters.js
@@ -109,7 +109,7 @@ export default {
if (fieldItem.is_info_only) {
return false
}
- const { columnName, displayType } = fieldItem
+ const { columnName, display_type } = fieldItem
const isMandatory = isMandatoryField(fieldItem)
if (!isMandatory) {
// evaluate displayed fields
@@ -123,10 +123,10 @@ export default {
columnName
})
- const isDateField = FIELDS_DATE.includes(displayType)
- const isDecimalField = FIELDS_DECIMALS.includes(displayType)
+ const isDateField = FIELDS_DATE.includes(display_type)
+ const isDecimalField = FIELDS_DECIMALS.includes(display_type)
- if (fieldItem.is_range && !isNumberField(fieldItem.displayType)) {
+ if (fieldItem.is_range && !isNumberField(fieldItem.display_type)) {
const valueTo = rootGetters.getValueOfField({
containerUuid,
columnName: fieldItem.columnNameTo
diff --git a/src/store/modules/ADempiere/dictionary/report/getters.js b/src/store/modules/ADempiere/dictionary/report/getters.js
index 7c99fa5c52e..e2e5339a499 100644
--- a/src/store/modules/ADempiere/dictionary/report/getters.js
+++ b/src/store/modules/ADempiere/dictionary/report/getters.js
@@ -120,7 +120,7 @@ export default {
if (fieldItem.is_info_only) {
return false
}
- const { columnName, displayType } = fieldItem
+ const { columnName, display_type } = fieldItem
const isMandatory = isMandatoryField(fieldItem)
if (!isMandatory) {
// evaluate displayed fields
@@ -134,10 +134,10 @@ export default {
columnName
})
- const isDateField = FIELDS_DATE.includes(displayType)
- const isDecimalField = FIELDS_DECIMALS.includes(displayType)
+ const isDateField = FIELDS_DATE.includes(display_type)
+ const isDecimalField = FIELDS_DECIMALS.includes(display_type)
- if (fieldItem.is_range && !isNumberField(fieldItem.displayType)) {
+ if (fieldItem.is_range && !isNumberField(display_type)) {
const valueTo = rootGetters.getValueOfField({
containerUuid: uuid,
columnName: fieldItem.columnNameTo
diff --git a/src/store/modules/ADempiere/dictionary/window/getters.js b/src/store/modules/ADempiere/dictionary/window/getters.js
index 49cbf85090f..3bf746b8c13 100644
--- a/src/store/modules/ADempiere/dictionary/window/getters.js
+++ b/src/store/modules/ADempiere/dictionary/window/getters.js
@@ -261,7 +261,7 @@ export default {
attributesObject[columnName] = parsedDefaultValue
// add display column to default
- if (isAddDisplayColumn && isSupportLookup(fieldItem.displayType) || fieldItem.displayType === ID.id) {
+ if (isAddDisplayColumn && isSupportLookup(fieldItem.display_type) || fieldItem.display_type === ID.id) {
const { displayColumnName } = fieldItem
let displayedValue
if (!isEmptyValue(parsedDefaultValue)) {
@@ -380,7 +380,7 @@ export default {
}
// Yes/No field always boolean value
const { default_value } = fieldItem
- const isYesNo = fieldItem.displayType === YES_NO.id
+ const isYesNo = fieldItem.display_type === YES_NO.id
if (isMandatory && (isEmptyValue(default_value) && !isYesNo)) {
if (isTable) {
return true
diff --git a/src/store/modules/ADempiere/panel/actions.js b/src/store/modules/ADempiere/panel/actions.js
index f58ba80f361..3f182580d5e 100644
--- a/src/store/modules/ADempiere/panel/actions.js
+++ b/src/store/modules/ADempiere/panel/actions.js
@@ -53,7 +53,7 @@ const actions = {
columnName: itemField.columnName,
displayColumnName: itemField.displayColumnName,
identifierSequence: itemField.identifierSequence,
- displayType: itemField.displayType,
+ display_type: itemField.display_type,
componentPath: itemField.componentPath
})
}
@@ -686,7 +686,7 @@ const actions = {
})
}
// update displayed value for field
- if (isLookup(field.displayType)) {
+ if (isLookup(field.display_type)) {
commit('updateValueOfField', {
parentUuid,
containerUuid,
diff --git a/src/store/modules/ADempiere/panel/getters.js b/src/store/modules/ADempiere/panel/getters.js
index 5e01055581e..510cdcd1adc 100644
--- a/src/store/modules/ADempiere/panel/getters.js
+++ b/src/store/modules/ADempiere/panel/getters.js
@@ -341,7 +341,7 @@ const getters = {
}
// add display column to default
- if (isSupportLookup(fieldItem.displayType)) {
+ if (isSupportLookup(fieldItem.display_type)) {
const { displayColumnName } = fieldItem
let displayedValue
if (!isEmptyValue(parsedDefaultValue)) {
@@ -570,7 +570,7 @@ const getters = {
return parsedValueComponent({
columnName,
componentPath: parameterItem.componentPath,
- displayType: parameterItem.displayType,
+ displayType: parameterItem.display_type,
isMandatory: isMandatoryGenerated,
value: itemValue
})
diff --git a/src/store/modules/ADempiere/persistence.js b/src/store/modules/ADempiere/persistence.js
index 91071d6b6cf..4ade14f5e2d 100644
--- a/src/store/modules/ADempiere/persistence.js
+++ b/src/store/modules/ADempiere/persistence.js
@@ -147,8 +147,8 @@ const persistence = {
oldValue = defaultValueGenerated
}
- if (isSupportLookup(field.displayType) || IMAGE.id === field.displayType ||
- (['DocAction', 'Record_ID'].includes(columnName) && BUTTON.id === field.displayType)) {
+ if (isSupportLookup(field.display_type) || IMAGE.id === field.display_type ||
+ (['DocAction', 'Record_ID'].includes(columnName) && BUTTON.id === field.display_type)) {
let displayedValue
if (!isEmptyValue(currentRecord)) {
displayedValue = currentRecord[field.displayColumnName]
@@ -182,7 +182,7 @@ const persistence = {
dispatch('startCallout', {
parentUuid,
containerUuid,
- displayType: field.displayType,
+ displayType: field.display_type,
callout: field.callout,
columnName,
value,
diff --git a/src/store/modules/ADempiere/windowManager.js b/src/store/modules/ADempiere/windowManager.js
index 5b59e5a9fde..0098952baac 100644
--- a/src/store/modules/ADempiere/windowManager.js
+++ b/src/store/modules/ADempiere/windowManager.js
@@ -1080,7 +1080,7 @@ const windowManager = {
return
}
// TODO: Improve conditions
- if (FIELDS_DATE.includes(field.displayType)) {
+ if (FIELDS_DATE.includes(field.display_type)) {
if (MULTIPLE_VALUES_OPERATORS_LIST.includes(operator)) {
values = contextValue
} else if (RANGE_VALUE_OPERATORS_LIST.includes(operator)) {
diff --git a/src/utils/ADempiere/contextUtils/contextField.js b/src/utils/ADempiere/contextUtils/contextField.js
index 11b7858b1dc..1e6bd3e8192 100644
--- a/src/utils/ADempiere/contextUtils/contextField.js
+++ b/src/utils/ADempiere/contextUtils/contextField.js
@@ -137,7 +137,7 @@ export function getContextDefaultValue({
columnName,
elementName,
componentPath,
- displayType,
+ display_type,
default_value,
isMandatory,
isColumnReadOnlyForm,
@@ -202,11 +202,11 @@ export function getContextDefaultValue({
parsedDefaultValue = default_value
}
if (isEmptyValue(parsedDefaultValue)) {
- if (isNumberField(displayType)) {
+ if (isNumberField(display_type)) {
if (isMandatory) {
parsedDefaultValue = 0
}
- } else if (isIdentifierField(displayType)) {
+ } else if (isIdentifierField(display_type)) {
parsedDefaultValue = -1
}
}
@@ -216,7 +216,7 @@ export function getContextDefaultValue({
parsedDefaultValue = parsedValueComponent({
columnName,
componentPath,
- displayType,
+ displayType: display_type,
isMandatory,
value: parsedDefaultValue
})
diff --git a/src/utils/ADempiere/dictionary/browser.js b/src/utils/ADempiere/dictionary/browser.js
index d8d6e7af09f..e0bdeb4b2b2 100644
--- a/src/utils/ADempiere/dictionary/browser.js
+++ b/src/utils/ADempiere/dictionary/browser.js
@@ -39,9 +39,9 @@ import { convertStringToBoolean } from '@/utils/ADempiere/formatValue/booleanFor
/**
* Is displayed field in panel query criteria
*/
-export function isDisplayedField({ displayType, is_query_criteria, displayLogic, isDisplayedFromLogic }) {
+export function isDisplayedField({ display_type, is_query_criteria, displayLogic, isDisplayedFromLogic }) {
// button field not showed
- if (isHiddenField(displayType)) {
+ if (isHiddenField(display_type)) {
return false
}
@@ -52,7 +52,7 @@ export function isDisplayedField({ displayType, is_query_criteria, displayLogic,
* Default showed field from user
*/
export function evaluateDefaultFieldShowed({
- displayType, is_query_criteria,
+ display_type, is_query_criteria,
isShowedFromUser, is_displayed_as_panel,
default_value, parsedDefaultValue, displayLogic,
isMandatory, isMandatoryFromLogic, mandatory_logic
@@ -64,7 +64,7 @@ export function evaluateDefaultFieldShowed({
return true
}
const isMandatoryGenerated = isMandatoryField({
- displayType, is_query_criteria, isMandatory, isMandatoryFromLogic, mandatory_logic
+ display_type, is_query_criteria, isMandatory, isMandatoryFromLogic, mandatory_logic
})
if (isMandatoryGenerated) {
return true
@@ -80,8 +80,8 @@ export function evaluateDefaultFieldShowed({
* @param {boolean} isMandatoryFromLogic
* @returns {boolean}
*/
-export function isMandatoryField({ displayType, is_query_criteria, isMandatory, isMandatoryFromLogic, mandatory_logic }) {
- if (displayType === BUTTON.id) {
+export function isMandatoryField({ display_type, is_query_criteria, isMandatory, isMandatoryFromLogic, mandatory_logic }) {
+ if (display_type === BUTTON.id) {
return false
}
return is_query_criteria && (isMandatory || (!isEmptyValue(mandatory_logic) && isMandatoryFromLogic))
@@ -92,7 +92,7 @@ export function isReadOnlyField({ is_query_criteria, operator, isReadOnlyFromLog
}
export function evaluateDefaultColumnShowed({
- is_key, displayType, is_displayed,
+ is_key, display_type, is_displayed,
isShowedTableFromUser, is_displayed_as_table,
isMandatory, isMandatoryFromLogic, mandatory_logic
}) {
@@ -101,7 +101,7 @@ export function evaluateDefaultColumnShowed({
}
// const isDisplayedColumnGenerated = isDisplayedColumn({
// is_key,
- // displayType,
+ // display_type,
// isDisplayed,
// isMandatory,
// isMandatoryFromLogic,
@@ -111,7 +111,7 @@ export function evaluateDefaultColumnShowed({
// return
// }
// const isMandatoryGenerated = isMandatoryColumn({
- // displayType, isMandatory, isMandatoryFromLogic, mandatory_logic
+ // display_type, isMandatory, isMandatoryFromLogic, mandatory_logic
// })
// if (isMandatoryGenerated) {
// return true
@@ -124,17 +124,17 @@ export function evaluateDefaultColumnShowed({
/**
* Is displayed column in table multi record
*/
-export function isDisplayedColumn({ displayType, is_displayed, is_key }) {
+export function isDisplayedColumn({ display_type, is_displayed, is_key }) {
// column check to selection or button field not showed
- if (is_key || isHiddenField(displayType)) {
+ if (is_key || isHiddenField(display_type)) {
return false
}
return is_displayed
}
-export function isMandatoryColumn({ displayType, isMandatory, isMandatoryFromLogic, mandatory_logic }) {
- if (displayType === BUTTON.id) {
+export function isMandatoryColumn({ display_type, isMandatory, isMandatoryFromLogic, mandatory_logic }) {
+ if (display_type === BUTTON.id) {
return false
}
return isMandatory || (!isEmptyValue(mandatory_logic) && isMandatoryFromLogic)
diff --git a/src/utils/ADempiere/dictionary/form/index.js b/src/utils/ADempiere/dictionary/form/index.js
index deca370e510..896f2a7ad6b 100644
--- a/src/utils/ADempiere/dictionary/form/index.js
+++ b/src/utils/ADempiere/dictionary/form/index.js
@@ -48,15 +48,15 @@ export function changeFieldShowedFromUser({ containerUuid, fieldsShowed = [] })
/**
* Is displayed field
- * @param {number} displayType
+ * @param {number} display_type
* @param {boolean} is_displayed
* @param {string} displayLogic
* @param {boolean} isDisplayedFromLogic
* @returns {boolean}
*/
-export function isDisplayedField({ displayType, is_displayed, displayLogic, isDisplayedFromLogic }) {
+export function isDisplayedField({ display_type, is_displayed, displayLogic, isDisplayedFromLogic }) {
// fields not showed
- if (isHiddenField(displayType)) {
+ if (isHiddenField(display_type)) {
return false
}
diff --git a/src/utils/ADempiere/dictionary/panel.js b/src/utils/ADempiere/dictionary/panel.js
index 2882e5ba533..b6c3b65a1b9 100644
--- a/src/utils/ADempiere/dictionary/panel.js
+++ b/src/utils/ADempiere/dictionary/panel.js
@@ -178,7 +178,7 @@ export function generatePanelAndFields({
columnName,
displayColumnName: fieldDefinition.displayColumnName,
identifierSequence: fieldDefinition.identifierSequence,
- displayType: fieldDefinition.displayType,
+ display_type: fieldDefinition.display_type,
componentPath
})
}
diff --git a/src/utils/ADempiere/dictionary/process.js b/src/utils/ADempiere/dictionary/process.js
index a8aeb36bb7a..aefbfea9a8b 100644
--- a/src/utils/ADempiere/dictionary/process.js
+++ b/src/utils/ADempiere/dictionary/process.js
@@ -35,16 +35,16 @@ export const CONTAINER_PROCESS_PREFIX = 'process_'
/**
* Is displayed field parameter in process/report panel
- * @param {number} displayType
+ * @param {number} display_type
* @param {boolean} isActive
* @param {boolean} is_displayed
* @param {string} displayLogic
* @param {boolean} isDisplayedFromLogic
* @returns {boolean}
*/
-export function isDisplayedField({ displayType, is_displayed, display_logic, isDisplayedFromLogic }) {
+export function isDisplayedField({ display_type, is_displayed, display_logic, isDisplayedFromLogic }) {
// button field not showed
- if (isHiddenField(displayType)) {
+ if (isHiddenField(display_type)) {
return false
}
@@ -56,7 +56,7 @@ export function isDisplayedField({ displayType, is_displayed, display_logic, isD
* Default showed field from user
*/
export function evaluateDefaultFieldShowed({
- default_value, displayType, parsedDefaultValue,
+ default_value, display_type, parsedDefaultValue,
isShowedFromUser, is_displayed_as_panel,
is_mandatory, display_logic
}) {
@@ -67,7 +67,7 @@ export function evaluateDefaultFieldShowed({
return true
}
const isMandatoryGenerated = isMandatoryField({
- displayType, is_mandatory
+ display_type, is_mandatory
})
if (isMandatoryGenerated) {
return true
@@ -84,8 +84,8 @@ export function evaluateDefaultFieldShowed({
* @param {boolean} isMandatory
* @returns {boolean}
*/
-export function isMandatoryField({ displayType, isMandatory }) {
- if (displayType === BUTTON.id) {
+export function isMandatoryField({ display_type, isMandatory }) {
+ if (display_type === BUTTON.id) {
return false
}
return isMandatory
diff --git a/src/utils/ADempiere/dictionary/window/index.js b/src/utils/ADempiere/dictionary/window/index.js
index c996c351741..e925d104147 100644
--- a/src/utils/ADempiere/dictionary/window/index.js
+++ b/src/utils/ADempiere/dictionary/window/index.js
@@ -162,9 +162,9 @@ export function isEditableRecord({ parentUuid, containerUuid }) {
/**
* Is displayed field in panel single record
*/
-export function isDisplayedField({ is_displayed, display_logic, isDisplayedFromLogic, displayType }) {
+export function isDisplayedField({ is_displayed, display_logic, isDisplayedFromLogic, display_type }) {
// // button field not showed
- // if (isHiddenField(displayType)) {
+ // if (isHiddenField(display_type)) {
// return false
// }
@@ -185,7 +185,7 @@ export function evaluateDefaultFieldShowed({
is_key, is_parent, columnName,
default_value, parsedDefaultValue,
isShowedFromUser, is_displayed_as_panel,
- displayType, displayLogic,
+ display_type, displayLogic,
isMandatory, mandatory_logic, isMandatoryFromLogic
}) {
if (!isEmptyValue(is_displayed_as_panel)) {
@@ -208,12 +208,12 @@ export function evaluateDefaultFieldShowed({
}
const isMandatoryGenerated = isMandatoryField({
- is_key, columnName, displayType, isMandatory, mandatory_logic, isMandatoryFromLogic
+ is_key, columnName, display_type, isMandatory, mandatory_logic, isMandatoryFromLogic
})
- const isEmpty = isEmptyValue(parsedDefaultValue) || (isDecimalField(displayType) && parsedDefaultValue === 0)
+ const isEmpty = isEmptyValue(parsedDefaultValue) || (isDecimalField(display_type) && parsedDefaultValue === 0)
if (isEmpty && isMandatoryGenerated && !is_parent) {
// Yes/No field always boolean value (as default value)
- if (displayType === YES_NO.id) {
+ if (display_type === YES_NO.id) {
// Business Partner Window
if (parentUuid === 'a520de12-fb40-11e8-a479-7a0060f0aa01') {
// Customer Tab
@@ -273,7 +273,7 @@ export function evaluateDefaultColumnShowed({
parentUuid, containerUuid,
is_key, is_parent, columnName,
default_value, parsedDefaultValue,
- displayType, isShowedTableFromUser, is_displayed_as_table,
+ display_type, isShowedTableFromUser, is_displayed_as_table,
isMandatory, mandatory_logic, isMandatoryFromLogic
}) {
if (!isEmptyValue(is_displayed_as_table)) {
@@ -293,12 +293,12 @@ export function evaluateDefaultColumnShowed({
}
const isMandatoryGenerated = isMandatoryColumn({
- is_key, columnName, displayType, isMandatory, mandatory_logic, isMandatoryFromLogic
+ is_key, columnName, display_type, isMandatory, mandatory_logic, isMandatoryFromLogic
})
- const isEmpty = isEmptyValue(parsedDefaultValue) || (isDecimalField(displayType) && parsedDefaultValue === 0)
+ const isEmpty = isEmptyValue(parsedDefaultValue) || (isDecimalField(display_type) && parsedDefaultValue === 0)
if (isEmpty && isMandatoryGenerated && !is_parent) {
// Yes/No field always boolean value (as default value)
- if (displayType === YES_NO.id) {
+ if (display_type === YES_NO.id) {
return false
}
return true
@@ -334,8 +334,8 @@ export function evaluateDefaultColumnShowed({
* @param {boolean} isMandatoryFromLogic
* @returns {boolean}
*/
-export function isMandatoryField({ is_key, columnName, displayType, isMandatory, mandatory_logic, isMandatoryFromLogic }) {
- if (displayType === BUTTON.id) {
+export function isMandatoryField({ is_key, columnName, display_type, isMandatory, mandatory_logic, isMandatoryFromLogic }) {
+ if (display_type === BUTTON.id) {
return false
}
@@ -383,9 +383,9 @@ export function isReadOnlyField({ is_read_only, read_only_logic, isReadOnlyFromL
/**
* Is displayed column in table multi record
*/
-export function isDisplayedColumn({ is_displayed, is_displayed_grid, isDisplayedFromLogic, is_key, displayType, display_logic }) {
+export function isDisplayedColumn({ is_displayed, is_displayed_grid, isDisplayedFromLogic, is_key, display_type, display_logic }) {
// key or button field not showed
- if (is_key || isHiddenField(displayType)) {
+ if (is_key || isHiddenField(display_type)) {
return false
}
@@ -394,7 +394,7 @@ export function isDisplayedColumn({ is_displayed, is_displayed_grid, isDisplayed
(isEmptyValue(display_logic) || isDisplayedFromLogic)
}
-export function isMandatoryColumn({ is_key, columnName, displayType, is_mandatory, mandatory_logic, isMandatoryFromLogic }) {
+export function isMandatoryColumn({ is_key, columnName, display_type, is_mandatory, mandatory_logic, isMandatoryFromLogic }) {
const notMandatoryRender = [
VALUE, DOCUMENT_NO, 'M_AttributeSetInstance_ID'
]
@@ -406,7 +406,7 @@ export function isMandatoryColumn({ is_key, columnName, displayType, is_mandator
return false
}
- if (displayType === BUTTON.id) {
+ if (display_type === BUTTON.id) {
return false
}
return is_mandatory || (!isEmptyValue(mandatory_logic) && isMandatoryFromLogic)
@@ -498,7 +498,7 @@ export const createNewRecord = {
if (field.isVirtualColumn || field.is_key) {
return false
}
- if ([ID.id, LOCATION_ADDRESS.id].includes(field.displayType)) {
+ if ([ID.id, LOCATION_ADDRESS.id].includes(field.display_type)) {
return false
}
// Ignore Standard Values
@@ -1713,10 +1713,10 @@ export const containerManager = {
},
isDisplayedField,
- isDisplayedDefault: ({ isMandatory, is_parent, default_value, displayType, parsedDefaultValue }) => {
+ isDisplayedDefault: ({ isMandatory, is_parent, default_value, display_type, parsedDefaultValue }) => {
if (isMandatory && !is_parent && isEmptyValue(default_value)) {
// Yes/No field always boolean value (as default value)
- if (displayType === YES_NO.id) {
+ if (display_type === YES_NO.id) {
return false
}
return true
@@ -1724,10 +1724,10 @@ export const containerManager = {
return false
},
isDisplayedColumn,
- isDisplayedDefaultTable: ({ isMandatory, is_parent, default_value, displayType, parsedDefaultValue }) => {
+ isDisplayedDefaultTable: ({ isMandatory, is_parent, default_value, display_type, parsedDefaultValue }) => {
if (isMandatory && !is_parent && isEmptyValue(default_value)) {
// Yes/No field always boolean value (as default value)
- if (displayType === YES_NO.id) {
+ if (display_type === YES_NO.id) {
return false
}
return true
diff --git a/src/utils/ADempiere/lookupFactory.js b/src/utils/ADempiere/lookupFactory.js
index 9181126ff68..774189665b8 100644
--- a/src/utils/ADempiere/lookupFactory.js
+++ b/src/utils/ADempiere/lookupFactory.js
@@ -200,9 +200,9 @@ export function createFieldFromDefinition({
definition = {}
}) {
if (!isEmptyValue(definition)) {
- if (isEmptyValue(definition.displayType)) {
- definition.displayType = CHAR.id
- } else if (definition.displayType === TABLE_DIRECT.id &&
+ if (isEmptyValue(definition.display_type)) {
+ definition.display_type = CHAR.id
+ } else if (definition.display_type === TABLE_DIRECT.id &&
isEmptyValue(definition.tableName) &&
columnName.indexOf('_ID') > 0) {
definition.tableName = columnName.replace('_ID', '')
@@ -238,12 +238,12 @@ export function createFieldFromDefinition({
// Default template for injected fields
export function getFieldTemplate(overwriteDefinition) {
- let displayType = CHAR.id // String reference (10)
- if (!isEmptyValue(overwriteDefinition.displayType)) {
- displayType = overwriteDefinition.displayType
+ let display_type = CHAR.id // String reference (10)
+ if (!isEmptyValue(overwriteDefinition.display_type)) {
+ display_type = overwriteDefinition.display_type
}
- const componentReference = evalutateTypeField(displayType)
+ const componentReference = evalutateTypeField(display_type)
// set size from displayed, max 24
let size = DEFAULT_SIZE
@@ -278,7 +278,7 @@ export function getFieldTemplate(overwriteDefinition) {
name: '',
fieldGroupType: ''
},
- displayType,
+ display_type,
componentPath: componentReference.componentPath,
size,
isFieldOnly: false,