整票提交

zth
lijingjia 3 weeks ago
parent 7d9574efa7
commit 4906218734

@ -261,13 +261,6 @@
type: String,
default: null,
},
//
printData: {
type: Array,
default: () => {
return []
}
},
//
create: {
type: Function,
@ -319,7 +312,7 @@
const saveFlag = ref(false)
const copyFlag = ref(false)
const openPrint = () => {
dsPrint.value.init(props.printData)
dsPrint.value.init()
}
//
const copyHandle = async () => {

@ -925,7 +925,7 @@ import { Item } from 'ant-design-vue/lib/menu'
if (v === 1) {
let flag = false
selectData.forEach((item) => {
item = clearCopyRow(Item)
item = clearCopyRow(item)
if (props.tbType == 'receive') {
item.feeType = 2
} else {

@ -128,7 +128,7 @@
//
const printData = ref([])
const init = (v) => {
printData.value = v
printData.value = v || []
visible.value = true
if (v && v.length) {
// ids
@ -213,11 +213,13 @@
visible.value = false
}
//
/* (2)
1. 打印表格数据通过数据调取接口获取打印数据然后跳转打印单
2. 通过数据源打印
*/
const toPrint = (item, type) => {
console.log(item)
//
if (item.templateCode == 'BOOKING' && !printData.value) {
if (item.templateCode == 'BOOKING' && printData.value.length == 0) {
const postData = {
pageCondition: {
pageIndex: 1,
@ -225,8 +227,8 @@
sortConditions: [],
},
queryCondition: JSON.stringify([
{ FieldName: 'BusinessId', FieldValue: props.bookingData.id, ConditionalType: 1 },
]),
{ FieldName: 'BusinessId', FieldValue: props.bookingData.id, ConditionalType: 1 }
])
}
GetList(postData).then((res) => {
const ids = res.data.map((item) => {
@ -265,6 +267,7 @@
})
})
} else {
// 使
if (item.isUseDataSource) {
const userStore = useUserStore()
const postData = {

@ -141,12 +141,13 @@
import { useMessage } from '/@/hooks/web/useMessage'
import { GetFees, Audit, SetInvoiceEnabled, AuditByBiz } from '../api'
import { Divider } from 'ant-design-vue'
import FeeActionBar from './feeActionBar.vue'
import AlterNewValue from './AlterNewValue.vue'
import { numberThousandFormat } from '/@/utils/commonUtil'
// import FeeActionBar from './feeActionBar.vue'
// import AlterNewValue from './AlterNewValue.vue'
import { useModal } from '/@/components/Modal'
import FeeRejectModal from './feeRejectModal.vue'
import { formatTableData } from '/@/hooks/web/common'
import emitter from '/@/utils/Bus'
// import { formatTableData } from '/@/hooks/web/common'
// import emitter from '/@/utils/Bus'
import { useRoute } from 'vue-router'
const route = useRoute()
//
@ -182,13 +183,13 @@
dataIndex: 'RMB',
title: 'RMB',
align: 'left',
minWidth: 70
width: 80
},
{
dataIndex: 'USD',
title: 'USD',
align: 'left',
minWidth: 70
width: 80
},
{
dataIndex: 'customerFullName',
@ -218,7 +219,7 @@
dataIndex: 'exchangeRate',
title: '汇率',
align: 'left',
width: 40
width: 80
}
]
}
@ -244,7 +245,7 @@
//
const columns = feeColumns(1)
columns[0].children.forEach(column => {
if (['RMB', 'USD', 'other'].includes(column.dataIndex)) {
if (['RMB', 'USD'].includes(column.dataIndex)) {
console.log(column)
// 0
sums[column.dataIndex] = 0
@ -275,7 +276,7 @@
//
const columns = feeColumns(2)
columns[0].children.forEach(column => {
if (['RMB', 'USD', 'other'].includes(column.dataIndex)) {
if (['RMB', 'USD'].includes(column.dataIndex)) {
console.log(column)
// 0
sums[column.dataIndex] = 0
@ -346,12 +347,11 @@
}
item.items.forEach(row => {
if (row.currency == 'RMB') {
row['RMB'] = row.amount
row['RMB'] = numberThousandFormat(row.amount, 2, false)
} else if (row.currency == 'USD') {
row['USD'] = row.amount
} else {
row['other'] = row.amount
row['USD'] = numberThousandFormat(row.amount, 2, false)
}
row.exchangeRate = numberThousandFormat(row.exchangeRate, 6, false)
//
if (row.feeType === 1) {
RData.value.push(row)

@ -65,10 +65,10 @@
<FeeTable ref="mainFeeTable" :status="status"></FeeTable>
<!-- 费用统计 -->
<div class="fee-statistic" :class="{'approve-fee-statustic': status == 'BILL_RECV_AUDIT' || status == 'BILL_PAY_AUDIT'}">
<span class="item">RMB利润<span class="item-val" :class="{ warnText: statisticData.profitCNY < 0 }">{{ statisticData.profitCNY }}</span></span>
<span class="item">USD利润<span class="item-val" :class="{ warnText: statisticData.profitUSD < 0 }">{{ statisticData.profitUSD }}</span></span>
<span class="item">合计利润<span class="item-val" :class="{ warnText: statisticData.payableTotal < 0 }">{{ statisticData.payableTotal }}</span></span>
<span class="item">利润率<span class="item-val">{{ statisticData.profitMargin }}</span></span>
<span class="item">RMB利润<span class="item-val" :class="{ warnText: statisticData.profitCNY < 0 }">{{ statisticData.profitCNY || '-' }}</span></span>
<span class="item">USD利润<span class="item-val" :class="{ warnText: statisticData.profitUSD < 0 }">{{ statisticData.profitUSD || '-' }}</span></span>
<span class="item">合计利润<span class="item-val" :class="{ warnText: statisticData.profitTotal < 0 }">{{ statisticData.profitTotal || '-' }}</span></span>
<span class="item">利润率<span class="item-val">{{ statisticData.profitMargin || '-' }}</span></span>
</div>
<ApproveBtns
agreeText="费用确认"
@ -206,9 +206,8 @@
GetStat(postData).then(res => {
const { data } = res
if (data.profitCNY) data.profitCNY = data.profitCNY.toLocaleString()
if (data.payableUSD) data.payableUSD = data.payableUSD.toLocaleString()
// if (data.profitCNY) data.profitCNY = data.profitCNY.toLocaleString()
if (data.payableTotal) data.payableTotal = data.payableTotal.toLocaleString()
if (data.profitUSD) data.profitUSD = data.profitUSD.toLocaleString()
if (data.profitTotal) data.profitTotal = data.profitTotal.toLocaleString()
statisticData.value = data
})
}

@ -77,8 +77,8 @@
return false
}
for(let i = 0; i < select.length; i++) {
if (select[i].status !== 0) {
return createMessage.warning('仅允许删除未提交状态的数据!')
if (!(select[i].status == 0 || select[i].status == 3)) {
return createMessage.warning('仅允许删除未提交、驳回状态的数据!')
}
}
const ids = select.map((item) => {

@ -225,13 +225,12 @@
const openGoodsNameModel = () => {
goodsNameVisible.value = true
const data = getFieldsValue2()
console.log(data)
let gData = [{}]
if (data?.ctnGoodsInfo?.length != 0) gData = data.ctnGoodsInfo
if (data.ctnGoodsInfo && data?.ctnGoodsInfo?.length != 0) gData = data.ctnGoodsInfo
console.log(gData)
ctnGoodsInfo.value = gData
}
const handleOk = () => {
console.log(ctnGoodsInfo.value)
setFieldsValue2({
ctnGoodsInfo: ctnGoodsInfo.value
})
@ -679,6 +678,7 @@
}
//
const handleCreate = (arr) => {
console.log(arr)
arr.push({})
}
//

Loading…
Cancel
Save