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

Commit

Permalink
fix: POS Date Order. (#1781)
Browse files Browse the repository at this point in the history
  • Loading branch information
EdwinBetanc0urt authored Dec 18, 2023
1 parent 7ee697c commit c1393eb
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 15 deletions.
34 changes: 19 additions & 15 deletions src/components/ADempiere/Form/VPOS2/FooterOrder/InfoOrder.vue
Original file line number Diff line number Diff line change
@@ -1,17 +1,19 @@
<!--
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 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 <https:www.gnu.org/licenses/>.
ADempiere-Vue (Frontend) for ADempiere ERP & CRM Smart Business Solution
Copyright (C) 2018-Present E.R.P. Consultores y Asociados, C.A.
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 <https:www.gnu.org/licenses/>.
-->

<template>
Expand All @@ -38,7 +40,7 @@ along with this program. If not, see <https:www.gnu.org/licenses/>.
{{ $t('form.pos.order.date') + ':' }}
</span>
<b style="float: right">
{{ infoOrder.dateOrdered }}
{{ translateDate({ value: infoOrder.dateOrdered, format: 'onlyDate' }) }}
</b>
</el-col>
<el-col :span="24">
Expand Down Expand Up @@ -183,6 +185,7 @@ import store from '@/store'

// Utils and Helper Methods
import { isEmptyValue } from '@/utils/ADempiere'
import { translateDate } from '@/utils/ADempiere/formatValue/dateFormat'
import { formatPrice, formatQuantity } from '@/utils/ADempiere/formatValue/numberFormat'

export default defineComponent({
Expand Down Expand Up @@ -268,7 +271,8 @@ export default defineComponent({
formatPrice,
changeSeller,
displayAmount,
formatQuantity
formatQuantity,
translateDate
}
}
})
Expand Down
3 changes: 3 additions & 0 deletions src/utils/ADempiere/valueUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,9 @@ export const isEmptyValue = function(value) {
if (String(value).trim() === '-1') {
return true
}
if (String(value) === '0001-01-01T00:00:00Z') {
return true
}

let isEmpty = false
const typeOfValue = getTypeOfValue(value)
Expand Down

0 comments on commit c1393eb

Please sign in to comment.