| | |
| | | showSelect: false, |
| | | select: false, |
| | | do: [ |
| | | // { |
| | | // id: 'handleWeave', |
| | | // font: '在线编制', |
| | | // type: 'text', |
| | | // method: 'handleWeave', |
| | | // disabFun: (row, index) => { |
| | | // return row.isExamine != null |
| | | // } |
| | | // }, |
| | | { |
| | | id: 'handleWeave', |
| | | font: '在线编制', |
| | | type: 'text', |
| | | method: 'handleWeave', |
| | | disabFun: (row, index) => { |
| | | return row.isExamine != null |
| | | } |
| | | }, |
| | | { |
| | | id: 'download', |
| | | font: '下载', |
| | |
| | | } |
| | | ], |
| | | linkEvent: { |
| | | // code: { |
| | | // method: 'selectAllByOne' |
| | | // } |
| | | code: { |
| | | method: 'selectAllByOne' |
| | | } |
| | | }, |
| | | tagField: { |
| | | isRatify: { |
| | |
| | | this.upIndex++ |
| | | }, |
| | | async handleWeave(row) { |
| | | // this.value = await file.convertFileToHtml(row.url) |
| | | // this.claimVisible = true; |
| | | this.$axios.post(this.$api.insReport.wordToHtml, { |
| | | path: row.urlS ? row.urlS : row.url |
| | | }).then(res => { |
| | | if (res.code === 200) { |
| | | // console.log(11111111,res.data) |
| | | this.value = res.data |
| | | .replace(/<a [^>]*>/g, "") |
| | | .replace(/<\/a>/g, "") |
| | | .replace(/ /g, " "); |
| | | this.claimVisible = true; |
| | | const userName = JSON.parse(localStorage.getItem("user")).name; |
| | | //参考vabOnlyOffice组件参数配置 |
| | | const { href } = this.$router.resolve({ |
| | | path: `/wordEdit`, |
| | | query: { |
| | | url: this.javaApi + "/word/" + row.entrustCode + ".docx", |
| | | isEdit: true, |
| | | fileType: "docx", |
| | | title: row.entrustCode + ".docx", |
| | | lang: 'zh-CN', |
| | | isPrint: true, |
| | | user: { id: 1, name: userName}, |
| | | editUrl: this.javaApi + "/insReport/onlyOffice/save?fileName=" + row.entrustCode + ".docx" |
| | | } |
| | | }).catch(error => { |
| | | console.error(error) |
| | | }) |
| | | window.open(href, '_blank'); |
| | | }, |
| | | // 权限分配 |
| | | getPower(radio) { |
| | |
| | | // console.log(this.$refs.Word.getValue()) |
| | | }, |
| | | async selectAllByOne(row) { |
| | | console.log(row, await file.convertFileToHtml(row.url)); |
| | | const userName = JSON.parse(localStorage.getItem("user")).name; |
| | | //参考vabOnlyOffice组件参数配置 |
| | | const { href } = this.$router.resolve({ |
| | | path: `/wordEdit`, |
| | | query: { |
| | | url: this.javaApi + "/word/" + row.entrustCode + ".docx", |
| | | isEdit: "false", |
| | | fileType: "docx", |
| | | title: row.entrustCode + ".docx", |
| | | lang: 'zh-CN', |
| | | isPrint: true, |
| | | user_id: 1, |
| | | user_name: userName |
| | | } |
| | | }) |
| | | window.open(href, '_blank'); |
| | | console.log(`output->row`,row) |
| | | }, |
| | | download(row) { |
| | | let url = row.urlS ? row.urlS : row.url; |