修改文档详情显示乱码的问题

This commit is contained in:
qq787203167
2022-03-25 12:17:24 +08:00
parent 4b983bf15c
commit b90ea6a981
3 changed files with 12 additions and 9 deletions
-1
View File
@@ -80,7 +80,6 @@
},
watch: {
$route: function(val) {
console.log(val)
this.$nextTick(() => {
this.$watermark.set(this.userInfo().username + ' ' + this.userInfo().realname)
})
-2
View File
@@ -1,6 +1,5 @@
let watermark = {}
let setWatermark = (str) => {
console.log(str)
let id = Date.parse(new Date())
if (document.getElementById(id) !== null) {
document.body.removeChild(document.getElementById(id))
@@ -20,7 +19,6 @@ let setWatermark = (str) => {
document.getElementsByClassName('detail-content')[0].style.background = 'url(' + can.toDataURL('image/png') + ') left top repeat'
}
console.log(id)
return id
}
@@ -2,14 +2,20 @@
<div class="doc-detail">
<div class="doc-detail-wrap">
<div class="doc-detail-header" style="position: fixed;top: 0">
<div class="doc-detail-title"
:title="this.$route.query.serial_number + ' '+this.$route.query.title + ' '+$t('StandardDetails')">
<div class="doc-detail-title">
<span style="line-height: 66px;display: inline-block;float: left">
<a-icon type="home" style="margin-right: 6px;"/>
</span>
<span>{{this.$route.query.serial_number}}</span>
<span>《{{this.$route.query.title}}》 </span>
<span> {{$t('StandardDetails')}}</span>
<a-tooltip placement="topLeft">
<template slot="title">
<span
v-html="this.$route.query.serial_number + ' '+this.$route.query.title + ' '+$t('StandardDetails')"></span>
</template>
<span v-html="$route.query.serial_number"></span>
<span v-html="'《'+ this.$route.query.title+'》'"></span>
<span> {{$t('StandardDetails')}}</span>
</a-tooltip>
</div>
<div class="doc-detail-right">
<div @click="UpdateLog" class="operator-text-text" :title="$t('UpdateLog')">
@@ -169,7 +175,7 @@
</template>
<script>
import { getAction, postAction, downFile, downloadFile } from '@/api/manage'
import { Base64 } from 'js-base64';
import { Base64 } from 'js-base64'
export default {
name: 'docIndex',