Skip to content
This repository has been archived by the owner on Nov 25, 2024. It is now read-only.

Commit

Permalink
Fix: Size Column Table Window (#2919)
Browse files Browse the repository at this point in the history
* Fix: Size Column Table Windown

* Fix: Size Column Table Windown
  • Loading branch information
Ricargame authored Nov 4, 2024
1 parent 9826d84 commit fe00a09
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/components/ADempiere/DataTable/Windows/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -619,9 +619,15 @@ export default defineComponent({
}

function widthColumn(fieldAttributes) {
const { name, display_type } = fieldAttributes
const { name, display_type, columnName } = fieldAttributes
const size = 8
const lenght = name.length
if (['C_BPartner_ID', 'C_Project_ID', 'C_BankAccount_ID'].includes(columnName)) {
return 300
}
if (columnName === 'M_Product_ID') {
return 400
}
const sum = (lenght * size) + 50
if (isBooleanField(display_type)) {
if (sum < 140) return 140
Expand All @@ -648,7 +654,6 @@ export default defineComponent({
loadSelection()
}
})

watch(selectionsList, (newValue, oldValue) => {
if (!isEmptyValue(newValue)) {
const row = newValue.at()
Expand Down

0 comments on commit fe00a09

Please sign in to comment.