|
@@ -11,7 +11,7 @@
|
|
<div style="height: calc(100% - 80px);">
|
|
<div style="height: calc(100% - 80px);">
|
|
{{works}}
|
|
{{works}}
|
|
|
|
|
|
- <el-button type="primary" @click="downloadFirstAuditTpl">离职证明</el-button>
|
|
|
|
|
|
+ <el-button type="primary" @click="departFreemarker">离职证明</el-button>
|
|
</div>
|
|
</div>
|
|
<template #footer>
|
|
<template #footer>
|
|
<span class="dialog-footer">
|
|
<span class="dialog-footer">
|
|
@@ -28,25 +28,26 @@
|
|
data () {
|
|
data () {
|
|
return {
|
|
return {
|
|
works: '',
|
|
works: '',
|
|
|
|
+ handoverId: '',
|
|
visible: false,
|
|
visible: false,
|
|
loading: false,
|
|
loading: false,
|
|
isAdmin: false,
|
|
isAdmin: false,
|
|
}
|
|
}
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
- init (works) {
|
|
|
|
|
|
+ init (works,handoverId) {
|
|
this.visible = true
|
|
this.visible = true
|
|
this.works = works
|
|
this.works = works
|
|
|
|
+ this.handoverId = handoverId
|
|
},
|
|
},
|
|
close () {
|
|
close () {
|
|
this.visible = false
|
|
this.visible = false
|
|
},
|
|
},
|
|
- downloadFirstAuditTpl () {
|
|
|
|
- // this.$utils.downloadExcel('/sys/project/import/template')
|
|
|
|
|
|
+ departFreemarker () {
|
|
this.loading = true
|
|
this.loading = true
|
|
- enrollmentRegistrationService.downloadFile().then((res) => {
|
|
|
|
|
|
+ enrollmentRegistrationService.downloadDepartFile(this.handoverId).then((res) => {
|
|
// 将二进制流文件写入excel表,以下为重要步骤
|
|
// 将二进制流文件写入excel表,以下为重要步骤
|
|
- this.$utils.downloadWord(res, '门禁卡开通注意事项')
|
|
|
|
|
|
+ this.$utils.downloadWord(res, '离职证明.doc')
|
|
this.loading = false
|
|
this.loading = false
|
|
}).catch(function (err) {
|
|
}).catch(function (err) {
|
|
this.loading = false
|
|
this.loading = false
|