|
@@ -6,6 +6,28 @@
|
|
|
<template slot="subTitle">
|
|
|
<a id="billOfLadingDetail-back-btn" href="javascript:;" @click="handleBack"><a-icon type="left" /> 返回列表</a>
|
|
|
</template>
|
|
|
+ <!-- 操作区,位于 title 行的行尾 -->
|
|
|
+ <template slot="extra">
|
|
|
+ <a-button
|
|
|
+ key="3"
|
|
|
+ type="default"
|
|
|
+ class="button-info"
|
|
|
+ id="billOfLadingDetail-preview-btn"
|
|
|
+ @click="handlePrint('preview')">打印预览</a-button>
|
|
|
+ <a-button
|
|
|
+ key="2"
|
|
|
+ type="primary"
|
|
|
+ class="button-info"
|
|
|
+ id="billOfLadingDetail-print-btn"
|
|
|
+ @click="handlePrint('print')">快捷打印</a-button>
|
|
|
+ <a-divider type="vertical" />
|
|
|
+ <a-button
|
|
|
+ key="1"
|
|
|
+ type="primary"
|
|
|
+ class="button-warning"
|
|
|
+ id="billOfLadingDetail-export-btn"
|
|
|
+ @click="handlePrint('export')">导出Excel</a-button>
|
|
|
+ </template>
|
|
|
</a-page-header>
|
|
|
<a-form-model
|
|
|
ref="ruleForm"
|
|
@@ -117,7 +139,8 @@
|
|
|
<script>
|
|
|
import { commonMixin } from '@/utils/mixin'
|
|
|
import { STable, VSelect, Upload } from '@/components'
|
|
|
-import { pickUpDetail, pickUpDetailQueryList } from '@/api/pickUp'
|
|
|
+import { printFun, exportExcel } from '@/libs/JGPrint.js'
|
|
|
+import { pickUpDetail, pickUpDetailQueryList, pickUpExport, pickUpDetailPrint } from '@/api/pickUp'
|
|
|
import { getProcessInstance } from '@/api/expenseManagement'
|
|
|
export default {
|
|
|
name: 'ProductInfoEdit',
|
|
@@ -191,6 +214,21 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
+ // 打印预览/快捷打印
|
|
|
+ handlePrint (type) {
|
|
|
+ const _this = this
|
|
|
+ const params = { pickUpSn: this.$route.params.sn }
|
|
|
+ _this.spinning = true
|
|
|
+ // 导出
|
|
|
+ if (type == 'export') {
|
|
|
+ exportExcel(pickUpExport, params, '提货单', function () {
|
|
|
+ _this.spinning = false
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ // 打印或预览
|
|
|
+ printFun(pickUpDetailPrint, params, type, '提货单', () => { _this.spinning = false })
|
|
|
+ }
|
|
|
+ },
|
|
|
// 关联销售退货单
|
|
|
getReturnOrderList () {
|
|
|
pickUpDetailQueryList({ pickUpSn: this.$route.params.sn }).then(res => {
|