|
|
@ -197,6 +197,7 @@ import { useGo } from '/@/hooks/web/usePage'
|
|
|
|
import { useUserStore } from '/@/store/modules/user'
|
|
|
|
import { useUserStore } from '/@/store/modules/user'
|
|
|
|
import { numberThousandFormat } from '/@/utils/commonUtil'
|
|
|
|
import { numberThousandFormat } from '/@/utils/commonUtil'
|
|
|
|
import { useMultipleTabStore } from '/@/store/modules/multipleTab'
|
|
|
|
import { useMultipleTabStore } from '/@/store/modules/multipleTab'
|
|
|
|
|
|
|
|
import moment from 'moment'
|
|
|
|
const tabStore = useMultipleTabStore()
|
|
|
|
const tabStore = useMultipleTabStore()
|
|
|
|
const userStore = useUserStore()
|
|
|
|
const userStore = useUserStore()
|
|
|
|
const go = useGo()
|
|
|
|
const go = useGo()
|
|
|
@ -253,6 +254,7 @@ const bankForm = [
|
|
|
|
componentProps: ({ formModel }) => {
|
|
|
|
componentProps: ({ formModel }) => {
|
|
|
|
return {
|
|
|
|
return {
|
|
|
|
options: bankListAll.value,
|
|
|
|
options: bankListAll.value,
|
|
|
|
|
|
|
|
allowClear: false,
|
|
|
|
mode: 'SECRET_COMBOBOX_MODE_DO_NOT_USE',
|
|
|
|
mode: 'SECRET_COMBOBOX_MODE_DO_NOT_USE',
|
|
|
|
fieldNames: {
|
|
|
|
fieldNames: {
|
|
|
|
label: 'invoiceHeader',
|
|
|
|
label: 'invoiceHeader',
|
|
|
@ -275,30 +277,22 @@ const bankForm = [
|
|
|
|
customerBankId: obj.id,
|
|
|
|
customerBankId: obj.id,
|
|
|
|
customerBankName: obj.bankName + obj.bankAccountNo,
|
|
|
|
customerBankName: obj.bankName + obj.bankAccountNo,
|
|
|
|
})
|
|
|
|
})
|
|
|
|
setFieldsValue({
|
|
|
|
|
|
|
|
usdCustomerBankId: '-',
|
|
|
|
|
|
|
|
usdCustomerBankName: '-',
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (obj.currency == 'USD') {
|
|
|
|
if (obj.currency == 'USD') {
|
|
|
|
setFieldsValue({
|
|
|
|
setFieldsValue({
|
|
|
|
usdCustomerBankId: obj.id,
|
|
|
|
usdCustomerBankId: obj.id,
|
|
|
|
usdCustomerBankName: obj.bankName + obj.bankAccountNo,
|
|
|
|
usdCustomerBankName: obj.bankName + obj.bankAccountNo,
|
|
|
|
})
|
|
|
|
})
|
|
|
|
setFieldsValue({
|
|
|
|
|
|
|
|
customerBankId: '-',
|
|
|
|
|
|
|
|
customerBankName: '-',
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (!obj && !e) {
|
|
|
|
if (!obj && !e) {
|
|
|
|
setFieldsValue({
|
|
|
|
setFieldsValue({
|
|
|
|
customerBankId: '-',
|
|
|
|
customerBankId: '',
|
|
|
|
customerBankName: '-',
|
|
|
|
customerBankName: '',
|
|
|
|
usdCustomerBankId: '-',
|
|
|
|
usdCustomerBankId: '',
|
|
|
|
usdCustomerBankName: '-',
|
|
|
|
usdCustomerBankName: '',
|
|
|
|
taxID: '-',
|
|
|
|
taxID: '',
|
|
|
|
customerAddTel: '-',
|
|
|
|
customerAddTel: '',
|
|
|
|
})
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -333,6 +327,7 @@ const bankForm = [
|
|
|
|
return {
|
|
|
|
return {
|
|
|
|
options: bankList.value,
|
|
|
|
options: bankList.value,
|
|
|
|
showSearch: true,
|
|
|
|
showSearch: true,
|
|
|
|
|
|
|
|
allowClear: false,
|
|
|
|
fieldNames: {
|
|
|
|
fieldNames: {
|
|
|
|
label: 'name',
|
|
|
|
label: 'name',
|
|
|
|
value: 'name',
|
|
|
|
value: 'name',
|
|
|
@ -341,7 +336,7 @@ const bankForm = [
|
|
|
|
if (obj) {
|
|
|
|
if (obj) {
|
|
|
|
obj.invoiceAddress = obj.invoiceAddress ? obj.invoiceAddress : ''
|
|
|
|
obj.invoiceAddress = obj.invoiceAddress ? obj.invoiceAddress : ''
|
|
|
|
obj.invoiceTel = obj.invoiceTel ? obj.invoiceTel : ''
|
|
|
|
obj.invoiceTel = obj.invoiceTel ? obj.invoiceTel : ''
|
|
|
|
obj.invoiceHeader = obj.invoiceHeader ? obj.invoiceHeader : '-'
|
|
|
|
obj.invoiceHeader = obj.invoiceHeader ? obj.invoiceHeader : ''
|
|
|
|
formModel.customerBankId = obj.id
|
|
|
|
formModel.customerBankId = obj.id
|
|
|
|
formModel.invoiceHeader = obj.invoiceHeader
|
|
|
|
formModel.invoiceHeader = obj.invoiceHeader
|
|
|
|
formModel.invoiceTel = obj.invoiceTel ? obj.invoiceTel : ''
|
|
|
|
formModel.invoiceTel = obj.invoiceTel ? obj.invoiceTel : ''
|
|
|
@ -349,11 +344,11 @@ const bankForm = [
|
|
|
|
formModel.customerAddTel = obj.invoiceAddress + ' ' + obj.invoiceTel
|
|
|
|
formModel.customerAddTel = obj.invoiceAddress + ' ' + obj.invoiceTel
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (!obj && !e) {
|
|
|
|
if (!obj && !e) {
|
|
|
|
formModel.customerBankId = '-'
|
|
|
|
formModel.customerBankId = ''
|
|
|
|
setFieldsValue({
|
|
|
|
setFieldsValue({
|
|
|
|
invoiceHeader: '-',
|
|
|
|
invoiceHeader: '',
|
|
|
|
taxID: '-',
|
|
|
|
taxID: '',
|
|
|
|
customerAddTel: '-'
|
|
|
|
customerAddTel: ''
|
|
|
|
})
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -374,6 +369,7 @@ const bankForm = [
|
|
|
|
field: 'usdCustomerBankName',
|
|
|
|
field: 'usdCustomerBankName',
|
|
|
|
label: 'USD开户行及账号',
|
|
|
|
label: 'USD开户行及账号',
|
|
|
|
colProps: { span: 24 },
|
|
|
|
colProps: { span: 24 },
|
|
|
|
|
|
|
|
allowClear: false,
|
|
|
|
component: 'Select',
|
|
|
|
component: 'Select',
|
|
|
|
componentProps: ({ formModel }) => {
|
|
|
|
componentProps: ({ formModel }) => {
|
|
|
|
return {
|
|
|
|
return {
|
|
|
@ -389,8 +385,8 @@ const bankForm = [
|
|
|
|
onChange: (e, obj) => {
|
|
|
|
onChange: (e, obj) => {
|
|
|
|
if (obj) {
|
|
|
|
if (obj) {
|
|
|
|
formModel.usdCustomerBankId = obj.id
|
|
|
|
formModel.usdCustomerBankId = obj.id
|
|
|
|
obj.invoiceAddress = obj.invoiceAddress ? obj.invoiceAddress : '-'
|
|
|
|
obj.invoiceAddress = obj.invoiceAddress ? obj.invoiceAddress : ''
|
|
|
|
obj.invoiceTel = obj.invoiceTel ? obj.invoiceTel : '-'
|
|
|
|
obj.invoiceTel = obj.invoiceTel ? obj.invoiceTel : ''
|
|
|
|
setFieldsValue({
|
|
|
|
setFieldsValue({
|
|
|
|
invoiceHeader: obj.invoiceHeader,
|
|
|
|
invoiceHeader: obj.invoiceHeader,
|
|
|
|
taxID: obj.invoiceTaxNo,
|
|
|
|
taxID: obj.invoiceTaxNo,
|
|
|
@ -398,12 +394,12 @@ const bankForm = [
|
|
|
|
})
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (!obj && !e) {
|
|
|
|
if (!obj && !e) {
|
|
|
|
formModel.usdCustomerBankId = '-'
|
|
|
|
// formModel.usdCustomerBankId = '-'
|
|
|
|
setFieldsValue({
|
|
|
|
// setFieldsValue({
|
|
|
|
invoiceHeader: '-',
|
|
|
|
// invoiceHeader: '-',
|
|
|
|
taxID: '-',
|
|
|
|
// taxID: '-',
|
|
|
|
customerAddTel: '-'
|
|
|
|
// customerAddTel: '-'
|
|
|
|
})
|
|
|
|
// })
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -457,7 +453,12 @@ const bottomForm = [
|
|
|
|
label: '申请日期',
|
|
|
|
label: '申请日期',
|
|
|
|
component: 'DatePicker',
|
|
|
|
component: 'DatePicker',
|
|
|
|
colProps: { span: 4 },
|
|
|
|
colProps: { span: 4 },
|
|
|
|
defaultValue: dayjs().format('YYYY-MM-DD'),
|
|
|
|
componentProps: (e) => {
|
|
|
|
|
|
|
|
return {
|
|
|
|
|
|
|
|
valueFormat: 'YYYY-MM-DD',
|
|
|
|
|
|
|
|
format: 'YYYY-MM-DD',
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
{
|
|
|
|
label: '客户名称',
|
|
|
|
label: '客户名称',
|
|
|
@ -601,97 +602,7 @@ const bottomForm = [
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
]
|
|
|
|
]
|
|
|
|
const bottomFormEdit = [
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
field: 'customer',
|
|
|
|
|
|
|
|
label: '',
|
|
|
|
|
|
|
|
component: 'DEdit',
|
|
|
|
|
|
|
|
show: false,
|
|
|
|
|
|
|
|
colProps: { span: 12 },
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
field: 'customerId',
|
|
|
|
|
|
|
|
label: '',
|
|
|
|
|
|
|
|
component: 'DEdit',
|
|
|
|
|
|
|
|
show: false,
|
|
|
|
|
|
|
|
colProps: { span: 12 },
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
field: 'createByName',
|
|
|
|
|
|
|
|
label: '申请人',
|
|
|
|
|
|
|
|
slot: 'createByNameSlot',
|
|
|
|
|
|
|
|
component: 'DEdit',
|
|
|
|
|
|
|
|
colProps: { span: 4 },
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
field: 'createTime',
|
|
|
|
|
|
|
|
label: '申请日期',
|
|
|
|
|
|
|
|
component: 'DEdit',
|
|
|
|
|
|
|
|
colProps: { span: 4 },
|
|
|
|
|
|
|
|
defaultValue: '',
|
|
|
|
|
|
|
|
componentProps: (e) => {
|
|
|
|
|
|
|
|
return {
|
|
|
|
|
|
|
|
valueFormat: 'YYYY-MM-DD',
|
|
|
|
|
|
|
|
format: 'YYYY-MM-DD',
|
|
|
|
|
|
|
|
onEdit: () => {
|
|
|
|
|
|
|
|
const { formActionType } = e
|
|
|
|
|
|
|
|
formActionType ? formActionType.linkageForm(e) : null
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
label: '客户名称',
|
|
|
|
|
|
|
|
field: 'customerName',
|
|
|
|
|
|
|
|
component: 'DEdit',
|
|
|
|
|
|
|
|
colProps: { span: 4 },
|
|
|
|
|
|
|
|
componentProps: (e) => {
|
|
|
|
|
|
|
|
const { formModel } = e
|
|
|
|
|
|
|
|
return {
|
|
|
|
|
|
|
|
onEdit: () => {
|
|
|
|
|
|
|
|
const { formActionType } = e
|
|
|
|
|
|
|
|
formActionType ? formActionType.linkageForm(e) : null
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
field: 'saleDeptId',
|
|
|
|
|
|
|
|
label: '',
|
|
|
|
|
|
|
|
component: 'Input',
|
|
|
|
|
|
|
|
show: false,
|
|
|
|
|
|
|
|
colProps: { span: 12 },
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
field: 'saleDeptName',
|
|
|
|
|
|
|
|
label: '所属分部',
|
|
|
|
|
|
|
|
component: 'DEdit',
|
|
|
|
|
|
|
|
colProps: { span: 4 },
|
|
|
|
|
|
|
|
componentProps: (e) => {
|
|
|
|
|
|
|
|
return {
|
|
|
|
|
|
|
|
onEdit: () => {
|
|
|
|
|
|
|
|
const { formActionType } = e
|
|
|
|
|
|
|
|
formActionType ? formActionType.linkageForm(e) : null
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
label: '代开客户',
|
|
|
|
|
|
|
|
field: 'autualCustomerName',
|
|
|
|
|
|
|
|
component: 'DEdit',
|
|
|
|
|
|
|
|
dynamicDisabled: false,
|
|
|
|
|
|
|
|
colProps: { span: 4 },
|
|
|
|
|
|
|
|
componentProps: (e) => {
|
|
|
|
|
|
|
|
return {
|
|
|
|
|
|
|
|
onEdit: () => {
|
|
|
|
|
|
|
|
const { formActionType } = e
|
|
|
|
|
|
|
|
formActionType ? formActionType.linkageForm(e) : null
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const route = useRoute()
|
|
|
|
const route = useRoute()
|
|
|
|
const { createMessage } = useMessage()
|
|
|
|
const { createMessage } = useMessage()
|
|
|
@ -718,6 +629,7 @@ const [
|
|
|
|
] = useForm({
|
|
|
|
] = useForm({
|
|
|
|
labelWidth: 100,
|
|
|
|
labelWidth: 100,
|
|
|
|
schemas: bottomForm,
|
|
|
|
schemas: bottomForm,
|
|
|
|
|
|
|
|
readonly: true,
|
|
|
|
showActionButtonGroup: false,
|
|
|
|
showActionButtonGroup: false,
|
|
|
|
})
|
|
|
|
})
|
|
|
|
const linkageForm = (e) => {
|
|
|
|
const linkageForm = (e) => {
|
|
|
@ -853,25 +765,9 @@ function init() {
|
|
|
|
createByName: userStore.getUserInfo ? userStore.getUserInfo.userName : '',
|
|
|
|
createByName: userStore.getUserInfo ? userStore.getUserInfo.userName : '',
|
|
|
|
})
|
|
|
|
})
|
|
|
|
feeTableRef.value.open()
|
|
|
|
feeTableRef.value.open()
|
|
|
|
|
|
|
|
bottomRsetFieldsValue({ createTime: dayjs().format('YYYY-MM-DD') })
|
|
|
|
}
|
|
|
|
}
|
|
|
|
// bankForm.forEach((item) => {
|
|
|
|
|
|
|
|
// if (item.show !== false && item.component !== 'Divider') {
|
|
|
|
|
|
|
|
// EditBankForm.forEach((item2) => {
|
|
|
|
|
|
|
|
// if (item.field == item2.field) {
|
|
|
|
|
|
|
|
// updateSchema(item2)
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// })
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// })
|
|
|
|
|
|
|
|
bottomForm.forEach((item) => {
|
|
|
|
|
|
|
|
if (item.show !== false && item.component !== 'Divider') {
|
|
|
|
|
|
|
|
bottomFormEdit.forEach((item2) => {
|
|
|
|
|
|
|
|
if (item.field == item2.field) {
|
|
|
|
|
|
|
|
updateSchemaBottom(item2)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
function handleWithdraw() {
|
|
|
|
function handleWithdraw() {
|
|
|
|
if (!loading.value) {
|
|
|
|
if (!loading.value) {
|
|
|
@ -908,17 +804,19 @@ function getDetail() {
|
|
|
|
form.value.statusText = res.data.statusText
|
|
|
|
form.value.statusText = res.data.statusText
|
|
|
|
form.value.status = res.data.status
|
|
|
|
form.value.status = res.data.status
|
|
|
|
form.value.applicationNO = res.data.applicationNO
|
|
|
|
form.value.applicationNO = res.data.applicationNO
|
|
|
|
|
|
|
|
form.value.currency = res.data.currency
|
|
|
|
details.value = res.data.details
|
|
|
|
details.value = res.data.details
|
|
|
|
feeTableRef.value.changeCust(res.data.customerId)
|
|
|
|
feeTableRef.value.changeCust(res.data.customerId)
|
|
|
|
amountArr.value = []
|
|
|
|
amountArr.value = []
|
|
|
|
|
|
|
|
totalRmb.value = 0
|
|
|
|
if (res.data.currency == 'RMB') {
|
|
|
|
if (res.data.currency == 'RMB') {
|
|
|
|
form.value.isRMB = true
|
|
|
|
form.value.isRMB = true
|
|
|
|
res.data.isRMB = true
|
|
|
|
res.data.isRMB = true
|
|
|
|
res.data.isYB = false
|
|
|
|
res.data.isYB = false
|
|
|
|
res.data.summaryItems.forEach(item => {
|
|
|
|
res.data.summaryItems.forEach(item => {
|
|
|
|
totalRmb.value += Number(item.amount)
|
|
|
|
totalRmb.value += Number(item.amount)
|
|
|
|
totalRmb.value = numberThousandFormat(totalRmb.value, 2, true)
|
|
|
|
|
|
|
|
})
|
|
|
|
})
|
|
|
|
|
|
|
|
totalRmb.value = numberThousandFormat(totalRmb.value, 2, false)
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
form.value.isYB = true
|
|
|
|
form.value.isYB = true
|
|
|
|
res.data.isRMB = false
|
|
|
|
res.data.isRMB = false
|
|
|
@ -1129,16 +1027,17 @@ function addLeftSave(arr, query, exchang, type) {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
const tempNameId = ref('')
|
|
|
|
const tempNameId = ref('')
|
|
|
|
function handleRender() {
|
|
|
|
function handleRender() {
|
|
|
|
let temp = null
|
|
|
|
if (tempNameId.value) {
|
|
|
|
|
|
|
|
let currency = null
|
|
|
|
tempList.value.forEach((item) => {
|
|
|
|
tempList.value.forEach((item) => {
|
|
|
|
if (item.id == tempNameId.value) {
|
|
|
|
if (item.id == tempNameId.value) {
|
|
|
|
temp = item.content
|
|
|
|
currency = item.currency
|
|
|
|
}
|
|
|
|
}
|
|
|
|
})
|
|
|
|
})
|
|
|
|
if (temp != null && temp != '') {
|
|
|
|
|
|
|
|
const data = {
|
|
|
|
const data = {
|
|
|
|
id: id.value,
|
|
|
|
id: id.value,
|
|
|
|
template: temp ? temp : null,
|
|
|
|
currency: currency,
|
|
|
|
|
|
|
|
templateId: tempNameId.value,
|
|
|
|
}
|
|
|
|
}
|
|
|
|
RenderTemplate(data).then((res) => {
|
|
|
|
RenderTemplate(data).then((res) => {
|
|
|
|
if (res.succeeded) {
|
|
|
|
if (res.succeeded) {
|
|
|
@ -1333,4 +1232,8 @@ function handleSelect(value) {
|
|
|
|
.orange {
|
|
|
|
.orange {
|
|
|
|
color: #ffa500;
|
|
|
|
color: #ffa500;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
:deep(.ds-form-onlyread) {
|
|
|
|
|
|
|
|
height: 19px !important;
|
|
|
|
|
|
|
|
}
|
|
|
|
</style>
|
|
|
|
</style>
|
|
|
|