Browse Source

发票5位小数

hella_online_20240829
王宇飞 6 months ago
parent
commit
bdca660f1d
  1. 2
      src/views/login/components/LoginForm.vue
  2. 10
      src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/index.vue
  3. 14
      src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/supplierinvoiceRequestMain.data.ts

2
src/views/login/components/LoginForm.vue

@ -212,7 +212,7 @@
// //
const handleLogin = async (params) => { const handleLogin = async (params) => {
console.log('登录-185') console.log('登录-185')
if(getSystermUpdateAlert()=='true'){ if(getSystermUpdateAlert()=='true'||getSystermUpdateAlert()===true){
await ElMessageBox.alert( await ElMessageBox.alert(
'<strong>系统迁移,请移步至</strong>' + '<strong>系统迁移,请移步至</strong>' +
`<a href=${getSystermUpdateUrl()} target="_blank">${getSystermUpdateUrl()}</a>`, `<a href=${getSystermUpdateUrl()} target="_blank">${getSystermUpdateUrl()}</a>`,

10
src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/index.vue

@ -32,7 +32,7 @@
</el-button> </el-button>
</template> </template>
<template #differencePrice="{row}"> <template #differencePrice="{row}">
<span :class="{'red-text':row.differencePrice!=0}">{{ Number(row.differencePrice).toFixed(4) }}</span> <span :class="{'red-text':row.differencePrice!=0}">{{ Number(row.differencePrice).toFixed(5) }}</span>
</template> </template>
<template #action="{ row,$index }"> <template #action="{ row,$index }">
<ButtonBase :Butttondata="butttondata(row,$index)" @button-base-click="buttonTableClick($event,row)" /> <ButtonBase :Butttondata="butttondata(row,$index)" @button-base-click="buttonTableClick($event,row)" />
@ -115,7 +115,7 @@
<template #selectionsActionspoLine="{selections}"> <template #selectionsActionspoLine="{selections}">
<div style="text-align: left;margin-right:10px"> <div style="text-align: left;margin-right:10px">
系统未税金额:{{Number(selections.reduce((prev, item) => prev + Number(Number(Number(Number(item['purchasePrice']).toFixed(4))*item['invoicableQuantity']).toFixed(2)),0)).toFixed(2)}} 系统未税金额:{{Number(selections.reduce((prev, item) => prev + Number(Number(Number(Number(item['purchasePrice']).toFixed(5))*item['invoicableQuantity']).toFixed(2)),0)).toFixed(2)}}
</div> </div>
</template> </template>
<!-- <template #foorter> <!-- <template #foorter>
@ -124,7 +124,7 @@
</div> </div>
</template> --> </template> -->
<template v-slot="{row}"> <template v-slot="{row}">
<el-input :disabled="true" :class="{'is-red': row['singlePrice'] - row['purchasePrice'] > 0}" :modelValue="((row['singlePrice']) - (row['purchasePrice'])).toFixed(4)"/> <el-input :disabled="true" :class="{'is-red': row['singlePrice'] - row['purchasePrice'] > 0}" :modelValue="((row['singlePrice']) - (row['purchasePrice'])).toFixed(5)"/>
</template> </template>
</BasicForm> </BasicForm>
@ -200,7 +200,7 @@
:sumFormDataByForm ="(formRef,formModel)=>{ :sumFormDataByForm ="(formRef,formModel)=>{
const {singlePrice=0,purchasePrice=0} = formModel const {singlePrice=0,purchasePrice=0} = formModel
formRef.value.setValues({ formRef.value.setValues({
differencePrice:Number((Number(singlePrice)-Number(purchasePrice)).toFixed(4)) differencePrice:Number((Number(singlePrice)-Number(purchasePrice)).toFixed(5))
}) })
}" }"
:isBasic="false" :isBasic="false"
@ -1033,7 +1033,7 @@ const handleImport = () => {
const submitForm = async (formType, submitData) => { const submitForm = async (formType, submitData) => {
let data = {...submitData} let data = {...submitData}
tableData.value.forEach((item) => { tableData.value.forEach((item) => {
item.differencePrice = Number((Number(item?.singlePrice)-Number(item?.purchasePrice)).toFixed(4)) item.differencePrice = Number((Number(item?.singlePrice)-Number(item?.purchasePrice)).toFixed(5))
}) })
data.subList = tableData.value // data.subList = tableData.value //
console.log('data',data) console.log('data',data)

14
src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/supplierinvoiceRequestMain.data.ts

@ -1472,7 +1472,7 @@ export const SupplierinvoiceRequestDetailMain = useCrudSchemas(reactive<CrudSche
])) ]))
const singlePriceFormart = (row, column, cellValue) => { const singlePriceFormart = (row, column, cellValue) => {
cellValue= Number(cellValue).toFixed(4) cellValue= Number(cellValue).toFixed(5)
cellValue = cellValue + '' || '' cellValue = cellValue + '' || ''
let x = cellValue.split('.') let x = cellValue.split('.')
@ -1693,13 +1693,13 @@ export const SupplierinvoiceRequestDetail = useCrudSchemas(reactive<CrudSchema[]
component: 'InputNumber', component: 'InputNumber',
componentProps: { componentProps: {
min: 0, min: 0,
precision: 4, precision: 5,
} }
}, },
tableForm: { tableForm: {
type: 'InputNumber', type: 'InputNumber',
min: 0, min: 0,
precision: 4, precision: 5,
} }
}, },
{ {
@ -1714,14 +1714,14 @@ export const SupplierinvoiceRequestDetail = useCrudSchemas(reactive<CrudSchema[]
componentProps: { componentProps: {
disabled: true, disabled: true,
min: 0, min: 0,
precision: 4, precision: 5,
} }
}, },
tableForm:{ tableForm:{
type: 'InputNumber', type: 'InputNumber',
disabled: true, disabled: true,
min: 0, min: 0,
precision: 4, precision: 5,
} }
}, },
{ {
@ -1735,14 +1735,14 @@ export const SupplierinvoiceRequestDetail = useCrudSchemas(reactive<CrudSchema[]
componentProps: { componentProps: {
disabled: true, disabled: true,
min: 0, min: 0,
precision: 4, precision: 5,
} }
}, },
tableForm:{ tableForm:{
type: 'slot', type: 'slot',
disabled: true, disabled: true,
min: 0, min: 0,
precision: 4, precision: 5,
} }
}, },
{ {

Loading…
Cancel
Save