n20-common-lib 1.2.23 → 1.2.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "n20-common-lib",
3
- "version": "1.2.23",
3
+ "version": "1.2.24",
4
4
  "private": false,
5
5
  "main": "src/index.js",
6
6
  "scripts": {
@@ -13,9 +13,17 @@
13
13
  <el-divider direction="vertical" />
14
14
  <!-- eslint-disable-next-line vue/no-v-html -->
15
15
  <h3 class="header-title" v-html="headerTitle"></h3>
16
+ <el-tooltip
17
+ class="set-user-btn"
18
+ effect="dark"
19
+ content="帮组文档"
20
+ placement="top-start"
21
+ >
22
+ <i class="el-icon-info" @click="openHelp"></i>
23
+ </el-tooltip>
16
24
 
17
25
  <el-dropdown
18
- class="set-user-drop"
26
+ class="m-l-m"
19
27
  trigger="click"
20
28
  placement="bottom"
21
29
  size="medium"
@@ -160,6 +168,7 @@
160
168
  import dialogWrap from '../../Dialog/index.vue'
161
169
  import changePwd from './changePwd.vue'
162
170
  import noticePop from './noticePop.vue'
171
+ import axios from '../../../utils/axios'
163
172
 
164
173
  import getJsonc from '../../../assets/getJsonc'
165
174
  import realUrl from '../../../assets/realUrl'
@@ -288,6 +297,22 @@ export default {
288
297
  this.rolesList = userInfo.roles || []
289
298
  }
290
299
  },
300
+ // 打开帮助文档
301
+ openHelp() {
302
+ axios
303
+ .get(`/bems/1.0/userManual`, {}, { responseType: 'blob' })
304
+ .then((res) => {
305
+ if (!res.size) {
306
+ this.$message.error('暂无帮助文档,请联系管理员!')
307
+ return
308
+ }
309
+ let url = window.URL.createObjectURL(res)
310
+ let win = window.open(url, '帮助文档')
311
+ setTimeout(function () {
312
+ win.document.title = '帮助文档'
313
+ }, 1000)
314
+ })
315
+ },
291
316
  setUserFn(c) {
292
317
  switch (c) {
293
318
  case 'setLang':