|
@@ -8,6 +8,9 @@
|
|
|
</div>
|
|
|
<div class="add-customer-btn">
|
|
|
<el-button size="small" style="margin-right: 8px"
|
|
|
+ :loading="saveLoading" :disabled="!form.id" @click="previewreportfun" >预 览
|
|
|
+ </el-button>
|
|
|
+ <el-button size="small" style="margin-right: 8px"
|
|
|
:loading="saveLoading" :disabled="!form.id" @click="DesignreportDialog = true" >报表设计
|
|
|
</el-button>
|
|
|
<el-button size="small" type="success" style="margin-right: 8px" v-if="form.status == 0 || form.status == 4" :disabled="!form.id"
|
|
@@ -219,7 +222,7 @@
|
|
|
</el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
- <el-col :span="10">
|
|
|
+ <el-col :span="8">
|
|
|
<el-form-item label="备注:" prop="remarks">
|
|
|
<el-input style="width: 100%;" v-model="form.remarks" type="textarea"
|
|
|
size="small" autocomplete="off"
|
|
@@ -227,8 +230,11 @@
|
|
|
</el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
- <el-col :span="4">
|
|
|
- <el-form-item label="" prop="billNo" label-width="50px">
|
|
|
+ <el-col :span="6">
|
|
|
+ <el-form-item label-width="50px">
|
|
|
+ <el-button size="small" type="warning" style="margin-right: 8px" :disabled="form.id"
|
|
|
+ :loading="saveLoading" @click="emptyConditionfun">一键清空
|
|
|
+ </el-button>
|
|
|
<el-button size="small" type="primary" style="margin-right: 8px" :disabled="form.id"
|
|
|
:loading="saveLoading" @click="retrievalfun">提取原业务信息
|
|
|
</el-button>
|
|
@@ -344,6 +350,24 @@
|
|
|
</span>
|
|
|
</el-dialog>
|
|
|
|
|
|
+ <!--预览-->
|
|
|
+ <el-dialog
|
|
|
+ title="打印"
|
|
|
+ :visible.sync="selectPrintingDialog"
|
|
|
+ append-to-body
|
|
|
+ width="70%"
|
|
|
+ :close-on-click-modal="false"
|
|
|
+ :destroy-on-close="true"
|
|
|
+ :close-on-press-escape="false"
|
|
|
+ v-dialog-drag>
|
|
|
+ <div>
|
|
|
+ <reportformsList ref="reportformsList" @reportRadio="reportRadio"></reportformsList>
|
|
|
+ </div>
|
|
|
+ <span slot="footer" class="dialog-footer">
|
|
|
+ <el-button size="small" @click="selectPrintingDialog = false;">取 消</el-button>
|
|
|
+ </span>
|
|
|
+ </el-dialog>
|
|
|
+
|
|
|
<!--费用打印-->
|
|
|
<reportContainer ref="reportContainer"></reportContainer>
|
|
|
</div>
|
|
@@ -365,9 +389,11 @@ import {
|
|
|
import TreeSelect from "@/components/iosbasic-data/TreeSelect.vue";
|
|
|
import {reportsGetReportData} from "@/api/iosBasicData/reports";
|
|
|
import reportContainer from "@/views/iosBasicData/report-container/report-container.vue";
|
|
|
+import reportformsList from "@/views/iosBasicData/SeafreightExportF/bills/assembly/reportformsList.vue";
|
|
|
+import {getList as getreportsList} from "@/api/iosBasicData/reports";
|
|
|
|
|
|
export default {
|
|
|
- components: {reportContainer, TreeSelect, reports, SearchQuery, amendsCostdetails, billgenerated},
|
|
|
+ components: {reportformsList, reportContainer, TreeSelect, reports, SearchQuery, amendsCostdetails, billgenerated},
|
|
|
data() {
|
|
|
return {
|
|
|
retrievePopupsType: false, // 检索完的弹窗
|
|
@@ -468,11 +494,11 @@ export default {
|
|
|
// 业务类型 数据
|
|
|
origSeaTypeData: [
|
|
|
{
|
|
|
- label: '海运出口',
|
|
|
+ label: '出口',
|
|
|
value: 'E'
|
|
|
},
|
|
|
{
|
|
|
- label: '海运进口',
|
|
|
+ label: '进口',
|
|
|
value: 'I'
|
|
|
}
|
|
|
],
|
|
@@ -530,6 +556,7 @@ export default {
|
|
|
},
|
|
|
]
|
|
|
},
|
|
|
+ selectPrintingDialog:false, // 预览弹窗
|
|
|
}
|
|
|
},
|
|
|
watch:{
|
|
@@ -548,12 +575,52 @@ export default {
|
|
|
},
|
|
|
},
|
|
|
methods: {
|
|
|
+ // 报表预览
|
|
|
+ previewreportfun(){
|
|
|
+ getreportsList(1,10,{
|
|
|
+ businessType:'AMEND',
|
|
|
+ classifyCode:'AMEND',
|
|
|
+ groupCode:'SE'
|
|
|
+ }).then(res=>{
|
|
|
+ if (res.data.data.records.length == 1) {
|
|
|
+ this.reportRadio(res.data.data.records[0])
|
|
|
+ }else {
|
|
|
+ this.saveLoading = true
|
|
|
+ this.selectPrintingDialog = true
|
|
|
+ this.saveLoading = false
|
|
|
+ let page = {
|
|
|
+ pageSize: 10,
|
|
|
+ currentPage: 1,
|
|
|
+ total: 0
|
|
|
+ }
|
|
|
+ this.$nextTick(()=>{
|
|
|
+ this.$refs.reportformsList.onLoad(page,{
|
|
|
+ businessType:'AMEND',
|
|
|
+ classifyCode:'AMEND',
|
|
|
+ groupCode:'SE'
|
|
|
+ })
|
|
|
+ })
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
// 打印表格选择
|
|
|
reportNodeClick(data){
|
|
|
this.reportformsObj = data
|
|
|
this.printingLoading = true
|
|
|
this.getFeeCenterCorpIdsfun()
|
|
|
},
|
|
|
+ // 预览里的打印
|
|
|
+ reportRadio(val){
|
|
|
+ // 获取报表数据
|
|
|
+ reportsGetReportData({
|
|
|
+ billId:this.form.id,
|
|
|
+ reportCode:val.classifyCode,
|
|
|
+ groupCode:val.groupCode,
|
|
|
+ type:'AMEND'
|
|
|
+ }).then(res=>{
|
|
|
+ this.handleReportPreview(val.url,res.data.data.data)
|
|
|
+ })
|
|
|
+ },
|
|
|
// 费用弹窗里的打印
|
|
|
dialogPreviewfun(row){
|
|
|
if (!this.reportformsObj.id){
|
|
@@ -651,12 +718,6 @@ export default {
|
|
|
arr = this.multipleChoiceDArr
|
|
|
} else {
|
|
|
arr = this.multipleChoiceCArr
|
|
|
- // for (let item of this.multipleChoiceCArr) {
|
|
|
- // item.amendSrcItemId = item.id
|
|
|
- // delete item.id
|
|
|
- // this.form.feeCenterList.unshift(item)
|
|
|
- // }
|
|
|
- // this.form.feeCenterList.unshift(...this.multipleChoiceCArr)
|
|
|
}
|
|
|
for (let item of arr) {
|
|
|
item.amendSrcItemId = item.id
|
|
@@ -733,7 +794,7 @@ export default {
|
|
|
delete item.voucherDate
|
|
|
delete item.voucherNo
|
|
|
delete item.voucherStatus
|
|
|
- this.form.feeCenterList.unshift(item)
|
|
|
+ this.form.feeCenterList.unshift(JSON.parse(JSON.stringify(item)))
|
|
|
}
|
|
|
this.editType = true
|
|
|
},
|
|
@@ -1073,8 +1134,27 @@ export default {
|
|
|
})
|
|
|
})
|
|
|
},
|
|
|
+ // 清空搜索条件
|
|
|
+ emptyConditionfun(){
|
|
|
+ this.$confirm("您确定要清空搜索条件吗?", {
|
|
|
+ confirmButtonText: "确定",
|
|
|
+ cancelButtonText: "取消",
|
|
|
+ type: "warning"
|
|
|
+ }).then(res=>{
|
|
|
+ this.form = {
|
|
|
+ voucherDate: dateFormat(new Date(), "yyyy-MM-dd") + ' 00:00:00', // 制单日期 默认 当天,
|
|
|
+ feeCenterListD: [],
|
|
|
+ feeCenterListC: [],
|
|
|
+ feeCenterList:[]
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
// 检索
|
|
|
retrievalfun() {
|
|
|
+ // 判断是否有客户名称
|
|
|
+ if (this.form.corpCnName) {
|
|
|
+ return this.$message.warning('请先一键清空数据之后再进行提取信息')
|
|
|
+ }
|
|
|
if (!this.form.mblno && !this.form.hblno && !this.form.refno && !this.form.bookingNo) {
|
|
|
return this.$message.warning('请填写至少一项检索条件')
|
|
|
}
|