|
@ -3,18 +3,18 @@ |
|
|
<div class="filter-container"> |
|
|
<div class="filter-container"> |
|
|
<sticky style="margin-bottom: 10px;"> |
|
|
<sticky style="margin-bottom: 10px;"> |
|
|
<div class="sub-navbar"> |
|
|
<div class="sub-navbar"> |
|
|
<el-button type="primary" icon="el-icon-printer" @click="batchPrintZjd"> |
|
|
|
|
|
打印转交单 |
|
|
|
|
|
</el-button> |
|
|
|
|
|
<el-button v-show="hasPerm('zjd:QRZJ')" type="warning" icon="el-ok" @click="createZjdShow"> |
|
|
<el-button v-show="hasPerm('zjd:QRZJ')" type="warning" icon="el-ok" @click="createZjdShow"> |
|
|
确认转交单 |
|
|
确认转交单 |
|
|
</el-button> |
|
|
</el-button> |
|
|
<el-button v-show="hasPerm('zjd:CXZJ')" type="danger" icon="el-cancel" @click="revokeZjd"> |
|
|
<el-button v-show="hasPerm('zjd:CXZJ')" type="danger" icon="el-cancel" @click="revokeZjd"> |
|
|
撤回转交单 |
|
|
撤回转交单 |
|
|
</el-button> |
|
|
</el-button> |
|
|
<el-button type="success" icon="el-icon-printer" @click="viewPrintZjd"> |
|
|
<!-- <el-button type="success" icon="el-icon-printer" @click="viewPrintZjd"> |
|
|
预览转交单 |
|
|
预览转交单 |
|
|
</el-button> |
|
|
</el-button> |
|
|
|
|
|
<el-button type="primary" icon="el-icon-printer" @click="batchPrintZjd"> |
|
|
|
|
|
打印转交单 |
|
|
|
|
|
</el-button>--> |
|
|
</div> |
|
|
</div> |
|
|
</sticky> |
|
|
</sticky> |
|
|
<el-form> |
|
|
<el-form> |
|
@ -271,10 +271,6 @@ export default { |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
revokeZjd() { |
|
|
revokeZjd() { |
|
|
if (this.multipleSelection.length !== 1) { |
|
|
|
|
|
this.$message({ message: '请选中单条数据进行操作。', type: 'warning' }) |
|
|
|
|
|
return false |
|
|
|
|
|
} |
|
|
|
|
|
for (let i = 0; i < this.multipleSelection.length; i++) { |
|
|
for (let i = 0; i < this.multipleSelection.length; i++) { |
|
|
if (this.multipleSelection[i].state) { |
|
|
if (this.multipleSelection[i].state) { |
|
|
this.$message({ message: '存在已确认的转交单,请勿重新操作。', type: 'warning' }) |
|
|
this.$message({ message: '存在已确认的转交单,请勿重新操作。', type: 'warning' }) |
|
@ -283,17 +279,15 @@ export default { |
|
|
} |
|
|
} |
|
|
// 撤销操作 |
|
|
// 撤销操作 |
|
|
this.api({ |
|
|
this.api({ |
|
|
url: '/zjd/revokeZjd', |
|
|
url: '/zjd/revoke', |
|
|
method: 'get', |
|
|
method: 'post', |
|
|
params: { |
|
|
data: { |
|
|
zjdId: this.multipleSelection[0].id |
|
|
zjdIds: this.multipleSelection.map(row => row.id) |
|
|
|
|
|
}, |
|
|
|
|
|
paramsSerializer: function(data) { |
|
|
|
|
|
return require('qs').stringify(data, { indices: false }) |
|
|
} |
|
|
} |
|
|
}).then(data => { |
|
|
}).then(data => { |
|
|
if (data.returnCode === undefined) { |
|
|
|
|
|
this.$message({ message: data, type: 'success' }) |
|
|
|
|
|
} else { |
|
|
|
|
|
this.$message({ message: data.returnMsg, type: 'warning' }) |
|
|
|
|
|
} |
|
|
|
|
|
this.getList() |
|
|
this.getList() |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
@ -343,26 +337,15 @@ export default { |
|
|
this.$message({ message: '请选择至少一条数据进行打印!', type: 'error' }) |
|
|
this.$message({ message: '请选择至少一条数据进行打印!', type: 'error' }) |
|
|
return false |
|
|
return false |
|
|
} |
|
|
} |
|
|
this.api({ |
|
|
this.preview({ |
|
|
url: '/zjd/printZjdBatch', |
|
|
url: '/print/generatePdfZjd', |
|
|
method: 'get', |
|
|
method: 'get', |
|
|
params: { |
|
|
params: { |
|
|
zjdIds: this.$refs.list.selection.map(zjd => { |
|
|
zjdId: this.$refs.list.selection[0].id |
|
|
return zjd.id |
|
|
|
|
|
}).join(',') |
|
|
|
|
|
} |
|
|
} |
|
|
}).then(data => { |
|
|
}).then(data => { |
|
|
this.preview({ |
|
|
data = data.replace(/\\/g, '/') |
|
|
url: '/print/generatePdfView', |
|
|
window.open(data) |
|
|
method: 'post', |
|
|
|
|
|
data: { |
|
|
|
|
|
list: data, |
|
|
|
|
|
viewType: 'ZJD' |
|
|
|
|
|
} |
|
|
|
|
|
}).then(data => { |
|
|
|
|
|
data = data.replace(/\\/g, '/') |
|
|
|
|
|
window.open(data) |
|
|
|
|
|
}) |
|
|
|
|
|
}) |
|
|
}) |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|