| | |
| | | @change="handleQuery" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="项目名称:" prop="projectId"> |
| | | <el-select |
| | | v-model="searchForm.projectId" |
| | | placeholder="请选择项目" |
| | | clearable |
| | | filterable |
| | | style="width: 200px" |
| | | @change="handleQuery" |
| | | > |
| | | <el-option |
| | | v-for="item in projectOptions" |
| | | :key="item.id" |
| | | :label="item.no + ' - ' + item.title" |
| | | :value="item.id" |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="发货日期:" prop="shippingDateRange"> |
| | | <el-date-picker |
| | | v-model="searchForm.shippingDateRange" |
| | | type="daterange" |
| | | range-separator="至" |
| | | start-placeholder="开始日期" |
| | | end-placeholder="结束日期" |
| | | value-format="YYYY-MM-DD" |
| | | style="width: 240px" |
| | | @change="handleQuery" |
| | | clearable |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" @click="handleQuery"> 搜索</el-button> |
| | | </el-form-item> |
| | |
| | | <el-table-column |
| | | label="发货订单号" |
| | | prop="shippingNo" |
| | | show-overflow-tooltip |
| | | /> |
| | | <el-table-column |
| | | label="项目名称" |
| | | prop="projectName" |
| | | min-width="150" |
| | | show-overflow-tooltip |
| | | /> |
| | | <el-table-column |
| | |
| | | show-overflow-tooltip |
| | | width="130" |
| | | /> |
| | | <el-table-column label="退货单" align="center" width="140"> |
| | | <template #default="scope"> |
| | | <el-button v-if="scope.row.returnNoList && scope.row.returnNoList.length > 0" link type="primary" @click="openReturnNosDialog(scope.row)"> |
| | | 查看 {{ scope.row.returnNoList.length }} 个退货单 |
| | | </el-button> |
| | | <span v-else>--</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column fixed="right" label="操作" width="220" align="center"> |
| | | <template #default="scope"> |
| | | <!-- <el-button--> |
| | | <!-- link--> |
| | | <!-- type="primary"--> |
| | | <!-- :disabled="!isApproved(scope.row.status)"--> |
| | | <!-- @click="openForm('edit', scope.row)">发货--> |
| | | <!-- </el-button>--> |
| | | <el-button |
| | | link |
| | | type="primary" |
| | | :disabled="scope.row.status === '审核通过' || scope.row.status === '已发货'" |
| | | @click="openForm('edit', scope.row)">补充发货信息 |
| | | </el-button> |
| | | <el-button |
| | | link |
| | | type="primary" |
| | |
| | | @click="openDetail(scope.row)" |
| | | >详情 |
| | | </el-button> |
| | | <!-- <el-button--> |
| | | <!-- link--> |
| | | <!-- type="danger"--> |
| | | <!-- :disabled="isApproving(scope.row.status)"--> |
| | | <!-- @click="handleDeleteSingle(scope.row)"--> |
| | | <!-- >删除--> |
| | | <!-- </el-button>--> |
| | | <el-button |
| | | link |
| | | type="danger" |
| | | :disabled="scope.row.status === '已发货' || scope.row.status === '审核通过'" |
| | | @click="handleDeleteSingle(scope.row)" |
| | | >删除 |
| | | </el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row :gutter="30"> |
| | | <el-col :span="24"> |
| | | <el-form-item label="发货单据:" prop="shippingDocument"> |
| | | <el-input |
| | | v-model="form.shippingDocument" |
| | | placeholder="请输入发货单据" |
| | | clearable |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row :gutter="30"> |
| | | <el-col :span="8"> |
| | | <el-form-item label="是否对账:" prop="isReconciled"> |
| | | <el-switch v-model="form.isReconciled" :active-value="1" :inactive-value="0" /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="8"> |
| | | <el-form-item label="是否结算:" prop="isSettled"> |
| | | <el-switch v-model="form.isSettled" :active-value="1" :inactive-value="0" /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="8"> |
| | | <el-form-item label="是否已开票:" prop="isInvoiced"> |
| | | <el-switch v-model="form.isInvoiced" :active-value="1" :inactive-value="0" /> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row :gutter="30"> |
| | | <el-col :span="12" v-if="form.isReconciled === 1"> |
| | | <el-form-item label="对账单归档情况:" prop="statementArchivingStatus"> |
| | | <el-input |
| | | type="textarea" |
| | | v-model="form.statementArchivingStatus" |
| | | placeholder="请输入对账单归档情况" |
| | | clearable |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12" v-if="form.isSettled === 1"> |
| | | <el-form-item label="结算单归档情况:" prop="settlementArchivingStatus"> |
| | | <el-input |
| | | type="textarea" |
| | | v-model="form.settlementArchivingStatus" |
| | | placeholder="请输入结算单归档情况" |
| | | clearable |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </el-form> |
| | | <template #footer> |
| | | <div class="dialog-footer"> |
| | |
| | | <el-descriptions-item label="出库单号" :span="2">{{ |
| | | detailRow.outboundBatches || "--" |
| | | }}</el-descriptions-item> |
| | | <el-descriptions-item label="发货单据">{{ |
| | | detailRow.shippingDocument || "--" |
| | | }}</el-descriptions-item> |
| | | <el-descriptions-item label="是否对账">{{ |
| | | detailRow.isReconciled === 1 ? '是' : '否' |
| | | }}</el-descriptions-item> |
| | | <el-descriptions-item label="是否结算">{{ |
| | | detailRow.isSettled === 1 ? '是' : '否' |
| | | }}</el-descriptions-item> |
| | | <el-descriptions-item label="是否已开票">{{ |
| | | detailRow.isInvoiced === 1 ? '是' : '否' |
| | | }}</el-descriptions-item> |
| | | <el-descriptions-item label="对账单归档情况" :span="2">{{ |
| | | detailRow.statementArchivingStatus || "--" |
| | | }}</el-descriptions-item> |
| | | <el-descriptions-item label="结算单归档情况" :span="2">{{ |
| | | detailRow.settlementArchivingStatus || "--" |
| | | }}</el-descriptions-item> |
| | | </el-descriptions> |
| | | <el-table |
| | | :data="getDeliveryProductInfoList()" |
| | |
| | | </div> |
| | | </template> |
| | | </el-dialog> |
| | | |
| | | <!-- 退货单号弹框 --> |
| | | <el-dialog v-model="returnNosDialogVisible" title="退货单号列表" width="400px" @close="closeReturnNosDialog"> |
| | | <el-table :data="currentReturnNos" border size="small"> |
| | | <el-table-column label="序号" type="index" width="60" align="center" /> |
| | | <el-table-column label="退货单号" prop="returnNo" align="center" /> |
| | | </el-table> |
| | | <template #footer> |
| | | <div class="dialog-footer"> |
| | | <el-button @click="closeReturnNosDialog">关闭</el-button> |
| | | </div> |
| | | </template> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | getDeliveryDetail, |
| | | } from "@/api/salesManagement/deliveryLedger.js"; |
| | | import { delLedgerFile } from "@/api/salesManagement/salesLedger.js"; |
| | | import { listProject } from "@/api/projectManagement/project.js"; |
| | | import ImageUpload from "@/components/AttachmentUpload/image/index.vue"; |
| | | import ImagePreview from "@/components/AttachmentPreview/image/index.vue"; |
| | | |
| | |
| | | const selectedRows = ref([]); |
| | | const tableLoading = ref(false); |
| | | const salesOrderOptions = ref([]); |
| | | const projectOptions = ref([]); |
| | | const page = reactive({ |
| | | current: 1, |
| | | size: 100, |
| | |
| | | const detailRow = ref(null); |
| | | const detailProductList = ref([]); |
| | | |
| | | // 退货单号弹框 |
| | | const returnNosDialogVisible = ref(false); |
| | | const currentReturnNos = ref([]); |
| | | |
| | | const openReturnNosDialog = (row) => { |
| | | currentReturnNos.value = (row.returnNoList || []).map(no => ({ returnNo: no })); |
| | | returnNosDialogVisible.value = true; |
| | | }; |
| | | |
| | | const closeReturnNosDialog = () => { |
| | | returnNosDialogVisible.value = false; |
| | | currentReturnNos.value = []; |
| | | }; |
| | | |
| | | // 用户信息表单弹框数据 |
| | | const operationType = ref(""); |
| | | const dialogFormVisible = ref(false); |
| | | const data = reactive({ |
| | | searchForm: { |
| | | salesContractNo: "", // 销售订单号 |
| | | shippingCarNumber: "", // 车牌号 |
| | | expressNumber: "", // 快递单号 |
| | | salesContractNo: undefined, |
| | | shippingCarNumber: undefined, |
| | | expressNumber: undefined, |
| | | projectId: undefined, |
| | | shippingDateRange: [] |
| | | }, |
| | | form: { |
| | | id: null, |
| | |
| | | |
| | | const getList = () => { |
| | | tableLoading.value = true; |
| | | deliveryLedgerListPage({ ...searchForm.value, ...page }) |
| | | const params = { ...searchForm.value }; |
| | | if (params.shippingDateRange && params.shippingDateRange.length === 2) { |
| | | params.beginShippingDate = params.shippingDateRange[0]; |
| | | params.endShippingDate = params.shippingDateRange[1]; |
| | | } |
| | | delete params.shippingDateRange; |
| | | deliveryLedgerListPage({ ...params, ...page }) |
| | | .then((res) => { |
| | | tableLoading.value = false; |
| | | tableData.value = res.data.records || []; |
| | |
| | | |
| | | // 打开弹框 |
| | | const openForm = async (type, row) => { |
| | | // 发货:仅“审核通过”允许编辑 |
| | | if (type === "edit" && row && !isApproved(row.status)) { |
| | | proxy.$modal.msgWarning("只有审核通过的数据才可以发货"); |
| | | if (type === "edit" && row && (row.status === "审核通过" || row.status === "已发货")) { |
| | | proxy.$modal.msgWarning("该状态的数据不可以编辑发货信息"); |
| | | return; |
| | | } |
| | | |
| | |
| | | shippingCarNumber: row.shippingCarNumber ?? "", |
| | | expressCompany: row.expressCompany ?? "", |
| | | expressNumber: row.expressNumber ?? "", |
| | | shippingDocument: row.shippingDocument ?? "", |
| | | isReconciled: row.isReconciled ?? 0, |
| | | statementArchivingStatus: row.statementArchivingStatus ?? "", |
| | | isSettled: row.isSettled ?? 0, |
| | | settlementArchivingStatus: row.settlementArchivingStatus ?? "", |
| | | isInvoiced: row.isInvoiced ?? 0, |
| | | }; |
| | | deliveryFileList.value = row.storageBlobVOs || []; |
| | | } |
| | |
| | | type: "warning", |
| | | }) |
| | | .then(() => { |
| | | proxy.download("/shippingInfo/export", {}, "发货台账.xlsx"); |
| | | const params = { ...searchForm.value }; |
| | | if (params.shippingDateRange && params.shippingDateRange.length === 2) { |
| | | params.beginShippingDate = params.shippingDateRange[0]; |
| | | params.endShippingDate = params.shippingDateRange[1]; |
| | | } |
| | | delete params.shippingDateRange; |
| | | proxy.download("/shippingInfo/export", params, "发货台账.xlsx"); |
| | | }) |
| | | .catch(() => { |
| | | proxy.$modal.msg("已取消"); |
| | |
| | | }; |
| | | |
| | | onMounted(() => { |
| | | listProject({}).then(res => projectOptions.value = res.rows || res.data.records || res.data); |
| | | getList(); |
| | | }); |
| | | </script> |