|
@@ -1,140 +0,0 @@
|
|
|
-<template>
|
|
|
- <div class="outboundOrderDetail-wrap">
|
|
|
- <a-page-header :ghost="false" :backIcon="false" class="outboundOrderDetail-back" >
|
|
|
- <!-- 自定义的二级文字标题 -->
|
|
|
- <template slot="subTitle">
|
|
|
- <a id="outboundOrderDetail-back-btn" href="javascript:;" @click="handleBack"><a-icon type="left" /> 返回列表</a>
|
|
|
- </template>
|
|
|
- <!-- 操作区,位于 title 行的行尾 -->
|
|
|
- <!-- <template slot="extra">
|
|
|
- <a-button key="2" id="outboundOrderDetail-preview-btn">打印预览</a-button>
|
|
|
- <a-button key="1" type="primary" id="outboundOrderDetail-print-btn">快速打印</a-button>
|
|
|
- </template> -->
|
|
|
- </a-page-header>
|
|
|
- <!-- 基础信息 -->
|
|
|
- <a-card size="small" :bordered="false" class="outboundOrderDetail-cont">
|
|
|
- <a-collapse :activeKey="['1']">
|
|
|
- <a-collapse-panel key="1" header="基础信息">
|
|
|
- <a-descriptions size="small" :column="2">
|
|
|
- <a-descriptions-item label="客户名称">{{ detailData&&detailData.buyerName || '--' }}</a-descriptions-item>
|
|
|
- <a-descriptions-item label="收货地址">
|
|
|
- <span v-if="detailData&&detailData.salesBillExtEntity && (detailData.salesBillExtEntity.shippingAddrProvinceName || detailData.salesBillExtEntity.shippingAddrCityName || detailData.salesBillExtEntity.shippingAddrCountyName || detailData.salesBillExtEntity.shippingAddr)">
|
|
|
- {{ (detailData && detailData.salesBillExtEntity && detailData.salesBillExtEntity.shippingAddrProvinceName) ? detailData.salesBillExtEntity.shippingAddrProvinceName : '' }}
|
|
|
- {{ (detailData && detailData.salesBillExtEntity && detailData.salesBillExtEntity.shippingAddrCityName) ? detailData.salesBillExtEntity.shippingAddrCityName : '--' }}
|
|
|
- {{ (detailData && detailData.salesBillExtEntity && detailData.salesBillExtEntity.shippingAddrCountyName) ? detailData.salesBillExtEntity.shippingAddrCountyName : '--' }}
|
|
|
- {{ (detailData && detailData.salesBillExtEntity && detailData.salesBillExtEntity.shippingAddr) ? detailData.salesBillExtEntity.shippingAddr : '--' }}
|
|
|
- </span>
|
|
|
- <span v-else>--</span>
|
|
|
- </a-descriptions-item>
|
|
|
- <a-descriptions-item label="收款方式">{{ (detailData && detailData.salesBillExtEntity&&detailData.salesBillExtEntity.settleStyleSnDictValue) || '--' }}</a-descriptions-item>
|
|
|
- <a-descriptions-item label="收货人">{{ (detailData && detailData.salesBillExtEntity&&detailData.salesBillExtEntity.consigneeName) || '--' }}</a-descriptions-item>
|
|
|
- <a-descriptions-item label="收货电话">{{ (detailData && detailData.salesBillExtEntity&&detailData.salesBillExtEntity.consigneeTel) || '--' }}</a-descriptions-item>
|
|
|
- <a-descriptions-item label="备注">{{ (detailData && detailData.salesBillExtEntity&&detailData.salesBillExtEntity.remarks) || '--' }}</a-descriptions-item>
|
|
|
- <a-descriptions-item label="业务状态">{{ (detailData && detailData.billStatusDictValue) || '--' }}</a-descriptions-item>
|
|
|
- </a-descriptions>
|
|
|
- </a-collapse-panel>
|
|
|
- </a-collapse>
|
|
|
- </a-card>
|
|
|
- <a-card size="small" :bordered="false" class="outboundOrderDetail-cont">
|
|
|
- <!-- alert -->
|
|
|
- <a-alert type="info" style="margin-bottom: 10px;">
|
|
|
- <div slot="message">
|
|
|
- 本次下推数量:<strong>{{ totalOutQty }}</strong>
|
|
|
- </div>
|
|
|
- </a-alert>
|
|
|
- <!-- 列表 -->
|
|
|
- <s-table
|
|
|
- class="sTable"
|
|
|
- ref="table"
|
|
|
- size="small"
|
|
|
- :rowKey="(record) => record.id"
|
|
|
- :columns="columns"
|
|
|
- :data="loadData"
|
|
|
- bordered>
|
|
|
- <!-- 状态 -->
|
|
|
- <template slot="state" slot-scope="text, record">
|
|
|
- <a-tag :color="record.state==1?'green':'red'" >{{ record.state==1? '已出库': '未出库' }}</a-tag>
|
|
|
- </template>
|
|
|
- </s-table>
|
|
|
- </a-card>
|
|
|
- </div>
|
|
|
-</template>
|
|
|
-
|
|
|
-<script>
|
|
|
-import { STable } from '@/components'
|
|
|
-import { stockOutDetail, stockOutDetailList, stockOutDetailCount } from '@/api/stockOut'
|
|
|
-export default {
|
|
|
- components: { STable },
|
|
|
- data () {
|
|
|
- return {
|
|
|
- // 表头
|
|
|
- columns: [
|
|
|
- { title: '序号', dataIndex: 'no', width: 80, align: 'center', fixed: 'left' },
|
|
|
- { title: '产品编码', dataIndex: 'productCode', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
- { title: '产品名称', dataIndex: 'productName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
- { title: '原厂编码', dataIndex: 'productOrigCode', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
- { title: '单位', dataIndex: 'unit', width: 80, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
- { title: '本次出库数', dataIndex: 'outQty', width: 110, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } }
|
|
|
- ],
|
|
|
- // 加载数据方法 必须为 Promise 对象
|
|
|
- loadData: parameter => {
|
|
|
- this.disabled = true
|
|
|
- return stockOutDetailList(Object.assign(parameter, this.queryParam, { sn: this.$route.params.sn })).then(res => {
|
|
|
- const data = res.data
|
|
|
- const no = (data.pageNo - 1) * data.pageSize
|
|
|
- for (var i = 0; i < data.list.length; i++) {
|
|
|
- data.list[i].no = no + i + 1
|
|
|
- }
|
|
|
- this.disabled = false
|
|
|
- this.getDetailCount()
|
|
|
- return data
|
|
|
- })
|
|
|
- },
|
|
|
- detailData: null, // 详情数据
|
|
|
- totalOutQty: 0 // 下推数量
|
|
|
- }
|
|
|
- },
|
|
|
- methods: {
|
|
|
- // 返回列表
|
|
|
- handleBack () {
|
|
|
- this.$router.push({ path: '/salesManagement/outboundOrder/list', query: { closeLastOldTab: true } })
|
|
|
- },
|
|
|
- // 获取详情
|
|
|
- getDetail () {
|
|
|
- stockOutDetail({ sn: this.$route.params.sn }).then(res => {
|
|
|
- if (res.status == 200) {
|
|
|
- this.detailData = res.data
|
|
|
- } else {
|
|
|
- this.detailData = null
|
|
|
- }
|
|
|
- })
|
|
|
- },
|
|
|
- // 合计
|
|
|
- getDetailCount () {
|
|
|
- stockOutDetailCount({ sn: this.$route.params.sn }).then(res => {
|
|
|
- if (res.status == 200) {
|
|
|
- this.totalOutQty = res.data && res.data.totalOutQty || 0
|
|
|
- } else {
|
|
|
- this.totalOutQty = 0
|
|
|
- }
|
|
|
- })
|
|
|
- }
|
|
|
- },
|
|
|
- beforeRouteEnter (to, from, next) {
|
|
|
- next(vm => {
|
|
|
- vm.getDetail()
|
|
|
- })
|
|
|
- }
|
|
|
-}
|
|
|
-</script>
|
|
|
-
|
|
|
-<style lang="less">
|
|
|
- .outboundOrderDetail-wrap{
|
|
|
- .outboundOrderDetail-back{
|
|
|
- margin-bottom: 10px;
|
|
|
- }
|
|
|
- .outboundOrderDetail-cont{
|
|
|
- margin-bottom: 10px;
|
|
|
- }
|
|
|
- }
|
|
|
-</style>
|