11.5禅道

feature-JimuReport-1106-yjl
lijingjia 3 weeks ago
parent b0bf774fe3
commit 5f3ac5831e

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

@ -178,6 +178,7 @@
import HColSet from '/@/components/HColSet/index.vue'
import { ApplyDeletion, GetPrintInfo, ApplyBusinessAudit, Withdraw, WithdrawBusiness } from './api'
import { useModal } from '/@/components/Modal'
import { clearCopyRow } from './components/hooks'
//
import DsPrint from '/@/components/Print/index.vue'
const [registerModal, { openModal }] = useModal()
@ -243,16 +244,7 @@
if (needCopy.length == 0) return createMessage.warning('请勾选要复制的费用!')
needCopy.forEach(item => {
item.selected = false
const deepCopyRow = JSON.parse(JSON.stringify(item))
deepCopyRow.id = ''
deepCopyRow.feeStatus = 1
deepCopyRow.feeStatusText = '录入状态'
deepCopyRow.settlementAmount = null
deepCopyRow.orderInvoiceAmount = null
deepCopyRow.invoiceAmountRest = null
deepCopyRow.invoiceAmount = null
deepCopyRow.auditOperator = null
deepCopyRow.auditDate = null
const deepCopyRow = clearCopyRow(JSON.parse(JSON.stringify(item)))
props.data.push(deepCopyRow)
})
}

@ -0,0 +1,26 @@
/*
* @Desc:
* @Author: lijj
* @Date: 2024-11-05 14:29:20
*/
// 复制数据,清空指定字段
export function clearCopyRow(obj) {
obj.id = null
obj.feeStatus = 1
obj.feeStatusText = '录入状态'
obj.settlementAmount = null
obj.orderInvoiceAmount = null
obj.invoiceAmountRest = null
obj.invoiceAmount = null
obj.auditOperator = null
obj.auditDate = null
obj.createByName = null
obj.createTime = null
obj.createBy = null
obj.debitNo = null
obj.updateTime = null
obj.updateByName = null
obj.updateBy = null
return obj
}

@ -64,6 +64,8 @@
//
import { GetSupplierAndClientListByCode } from '/@/api/common'
import { useMessage } from '/@/hooks/web/useMessage'
//
import { clearCopyRow } from './components/hooks'
//
import { getDictOption } from '/@/utils/dictUtil'
// handsontable hooks
@ -72,6 +74,7 @@
import { GetFeeCurrencyExchangeList } from '/@/views/fee/exchangeRate/api'
import { updateColumns } from '/@/hooks/web/common'
import { useAppStore } from '/@/store/modules/app'
import { Item } from 'ant-design-vue/lib/menu'
const appStore = useAppStore()
const { createMessage } = useMessage()
defineComponent({
@ -261,9 +264,10 @@
visible: true,
source: async (query, process) => {
if (unitDict.value && unitDict.value.length) {
const dict = unitDict.value.map((item) => {
let dict = unitDict.value.map((item) => {
return item.label
})
dict = Array.from(new Set(dict))
process(dict)
}
},
@ -612,7 +616,9 @@
if (props?.details?.ctnInfo && props?.details?.ctnInfo?.length) {
list.value[changes[0][0]]['unitText'] = props.details.ctnInfo[0].ctn
list.value[changes[0][0]]['unit'] = props.details.ctnInfo[0].ctnCode
list.value[changes[0][0]]['quantity'] = props.details.ctnInfo[0].ctnNum
GetUnitSelectInfo({ code: list.value[changes[0][0]]['unitText'], businessId: props.id, businessType: props.type }).then(res => {
list.value[changes[0][0]]['quantity'] = res.data.quantity
})
}
} else if (dict.defaultUnit == 'CNTR') {
//
@ -633,7 +639,12 @@
list.value[changes[0][0]]['quantity'] = res.data.quantity
})
} else {
list.value[changes[0][0]]['quantity'] = 0
if (list.value[changes[0][0]]['unit'] == 'Bill') {
// 1()
list.value[changes[0][0]]['quantity'] = 1
} else {
list.value[changes[0][0]]['quantity'] = 0
}
}
}
//
@ -914,9 +925,7 @@
if (v === 1) {
let flag = false
selectData.forEach((item) => {
item.id = ''
item.feeStatus = 1
item.feeStatusText = '录入状态'
item = clearCopyRow(Item)
if (props.tbType == 'receive') {
item.feeType = 2
} else {
@ -965,9 +974,7 @@
} else {
//
selectData.forEach((item) => {
item.id = ''
item.feeStatus = 1
item.feeStatusText = '录入状态'
item = clearCopyRow(Item)
item.selected = false
if (props.tbType == 'receive') {
item.feeType = 2

@ -130,7 +130,7 @@
const init = (v) => {
printData.value = v
visible.value = true
if (v) {
if (v && v.length) {
// ids
ids.value = v.map((item) => {
return item.id
@ -149,17 +149,17 @@
ConditionalList: [
{
Key: 1,
Value: { FieldName: 'carrierId', FieldValue: props.cid, ConditionalType: 0 },
Value: { FieldName: 'carrierId', FieldValue: props.cid, ConditionalType: 0 }
},
{
Key: 1,
Value: { FieldName: 'carrierId', FieldValue: 0, ConditionalType: 11 },
},
],
},
},
],
},
Value: { FieldName: 'carrierId', FieldValue: 0, ConditionalType: 11 }
}
]
}
}
]
}
]
// if (temCodes.length) {
// const ConditionalList = {
@ -264,6 +264,7 @@
})
})
} else {
console.log(item)
if (item.isUseDataSource) {
const userStore = useUserStore()
const postData = {

@ -10,12 +10,12 @@
<!-- 保存按钮组 -->
<ActionBar
:id="route.query.id"
code="sea_freight_export"
code="fee_payapplication"
name="hyck"
:save="save"
:submit="submit"
:delete="deleteItem"
:paramJsonStr="'{id:' + route.query.id + '}'"
:printData="feeData"
:showBtns="['save', 'delete', 'submit', 'print', 'next', 'last']"
layout="horizontal"
></ActionBar>

@ -664,15 +664,13 @@ export const formSchema3: FormSchema[] = [
label: '总件数',
field: 'pkgs',
component: 'Input',
colProps: { span: 12 },
dynamicDisabled: true,
colProps: { span: 12 }
},
{
label: '包装',
field: 'kindPkgsName',
component: 'Input',
colProps: { span: 12 },
dynamicDisabled: true,
colProps: { span: 12 }
},
{
label: '',

@ -455,7 +455,6 @@
res.data.stlDate = res.data.stlDate.split(' ')[0]
}
bookingDetails.value = res.data
console.log(bookingDetails.value)
//
inPageLoading.value = false
})
@ -567,6 +566,18 @@
}
}
}
// code
let serviceItem = ''
const seriveItems = RefrightContent.value.bookingServiceItem
if (seriveItems && seriveItems.length) {
const sitems = seriveItems.filter(item => {
return item.isYield == true
})
const codes = sitems.map(item => {
return item.projectCode
})
serviceItem = String(codes)
}
// post
const postData = {
...baseinfoForm,
@ -577,7 +588,10 @@
...customerForm,
...noteForm,
ediInfo: ediFrom,
ctnInfo
ctnInfo,
soRemark: ediFrom.soRemark,
closeDocRemark: ediFrom.closeDocRemark,
serviceItem
}
//
if (postData.closingDate && postData.closingDate.length == 13) {
@ -998,6 +1012,7 @@
Withdraw(postData).then(res => {
if (res.succeeded) {
createMessage.success('撤销成功!')
RefrightContent.value.getStatusServiceList(1, null)
}
init()
})
@ -1026,10 +1041,10 @@
businessType: '1',
taskTypeName: type || route.query.status
}
completeTask(type, true)
await completeTask(type, true)
if (type) postData['hasCabin'] = true
loading.value = true
await CreateTask(postData).then(res => {
CreateTask(postData).then(res => {
loading.value = false
if (!b) createMessage.success(res.message)
}).catch(() => {
@ -1181,12 +1196,16 @@
if (res.data) {
//
const shippingSpaceType = RefbasicInfo.value.formData.shippingSpaceType
if (shippingSpaceType == 'xc') {
if (shippingSpaceType == 'xc' && route.query.status == 'WAIT_ORDER_AUDIT') {
//
sspace.value.init()
} else {
//
seaExportTaskAudit(remark, true)
//
if (route.query.status == 'WAIT_ORDER_AUDIT') {
seaExportTaskAudit(remark, true)
} else {
seaExportTaskAudit(remark, false)
}
}
} else {
//
@ -1231,36 +1250,41 @@
return createMessage.warning('请填写订舱编号或主提单号!')
}
}
if (status == 'ORDER_AUDIT_REJECTED') {
SubmitAudit({
businessId: id.value,
businessType: 1,
taskTypeName: 'WAIT_ORDER_AUDIT'
}).then(res => {
tabStore.closeTabByKey(fullPath, router)
})
} else if (status == 'WAIT_SI_REJECT') {
SubmitAudit({
businessId: id.value,
businessType: 1,
taskTypeName: 'WAIT_SI'
}).then(res => {
tabStore.closeTabByKey(fullPath, router)
})
} else {
const postData = {
businessId: id.value,
businessType: 1,
taskTypeName: type || status,
taskStatus: 2,
autoCreateNext: true
return new Promise((resolve) => {
if (status == 'ORDER_AUDIT_REJECTED') {
SubmitAudit({
businessId: id.value,
businessType: 1,
taskTypeName: 'WAIT_ORDER_AUDIT'
}).then(res => {
resolve(res)
tabStore.closeTabByKey(fullPath, router)
})
} else if (status == 'WAIT_SI_REJECT') {
SubmitAudit({
businessId: id.value,
businessType: 1,
taskTypeName: 'WAIT_SI'
}).then(res => {
resolve(res)
tabStore.closeTabByKey(fullPath, router)
})
} else {
const postData = {
businessId: id.value,
businessType: 1,
taskTypeName: type || status,
taskStatus: 2,
autoCreateNext: true
}
if (type) postData.autoCreateNext = false
SetTaskStatus(postData).then(res => {
if (!b) createMessage.success('操作成功!')
resolve(res)
tabStore.closeTabByKey(fullPath, router)
})
}
if (type) postData.autoCreateNext = false
SetTaskStatus(postData).then(res => {
if (!b) createMessage.success('操作成功!')
tabStore.closeTabByKey(fullPath, router)
})
}
})
}
watch(
() => copyFlag,

@ -227,7 +227,7 @@
const data = getFieldsValue2()
console.log(data)
let gData = [{}]
if (data.ctnGoodsInfo.length != 0) gData = data.ctnGoodsInfo
if (data?.ctnGoodsInfo?.length != 0) gData = data.ctnGoodsInfo
ctnGoodsInfo.value = gData
}
const handleOk = () => {

@ -46,7 +46,11 @@
() => props.details,
(nval) => {
if (nval.ediInfo) {
setFieldsValue(nval.ediInfo)
setFieldsValue({
...nval.ediInfo,
soRemark: props.details.soRemark,
closeDocRemark: props.details.closeDocRemark
})
}
}
)
@ -73,7 +77,9 @@
})
})
setFieldsValue({
...props.details.ediInfo
...props.details.ediInfo,
soRemark: props.details.soRemark,
closeDocRemark: props.details.closeDocRemark
})
})
defineExpose({

@ -1490,11 +1490,9 @@
])
// 退
const returnCabin = () => {
// 退
const etd = props.details.etd
const now = new Date()
if (!props?.details?.isBooking || new Date(etd) < now) {
return createMessage.warning('未订舱或已开船不可退舱!')
// 退
if (!props?.details?.isBooking) {
return createMessage.warning('该订单暂未订舱!')
}
returnCabinFlag.value = true
}

@ -1116,7 +1116,9 @@
init,
open,
flag,
cancelGoodsStatus
cancelGoodsStatus,
getStatusServiceList,
bookingServiceItem
})
</script>
<style lang="less">

Loading…
Cancel
Save