Merge branch 'dev' of http://yun.pashanhoo.com:9090/bdc/bdcdj-web into dev
Showing
3 changed files
with
25 additions
and
19 deletions
... | @@ -2,7 +2,7 @@ | ... | @@ -2,7 +2,7 @@ |
2 | /* | 2 | /* |
3 | * @Description: 此文件主要创建 axios 实例,然后添加请求拦截器和响应拦截器 | 3 | * @Description: 此文件主要创建 axios 实例,然后添加请求拦截器和响应拦截器 |
4 | * @Autor: renchao | 4 | * @Autor: renchao |
5 | * @LastEditTime: 2023-06-13 16:28:57 | 5 | * @LastEditTime: 2023-06-13 17:16:13 |
6 | */ | 6 | */ |
7 | import axios from 'axios' | 7 | import axios from 'axios' |
8 | import Router from '@/router' | 8 | import Router from '@/router' |
... | @@ -34,14 +34,6 @@ service.interceptors.request.use( | ... | @@ -34,14 +34,6 @@ service.interceptors.request.use( |
34 | } else { | 34 | } else { |
35 | config.headers.delete('Authorization') | 35 | config.headers.delete('Authorization') |
36 | } | 36 | } |
37 | } else { | ||
38 | const token = Cookies.get('ACCESS_TOKEN') | ||
39 | // 添加请求头 | ||
40 | if (token) { | ||
41 | config.headers['Authorization'] = 'Bearer ' + token | ||
42 | } else { | ||
43 | config.headers.delete('Authorization') | ||
44 | } | ||
45 | } | 37 | } |
46 | return config | 38 | return config |
47 | }, | 39 | }, | ... | ... |
1 | <!-- | 1 | <!-- |
2 | * @Description: | 2 | * @Description: |
3 | * @Autor: renchao | 3 | * @Autor: renchao |
4 | * @LastEditTime: 2023-06-12 15:18:07 | 4 | * @LastEditTime: 2023-06-14 09:25:12 |
5 | --> | 5 | --> |
6 | <template> | 6 | <template> |
7 | <div class="rlPopup"> | 7 | <div class="rlPopup"> |
... | @@ -109,8 +109,18 @@ | ... | @@ -109,8 +109,18 @@ |
109 | * @author: renchao | 109 | * @author: renchao |
110 | */ | 110 | */ |
111 | handleOpenScan () { | 111 | handleOpenScan () { |
112 | this.isScan = true | 112 | this.isScan = !this.isScan |
113 | this.scanTitle = '关闭高拍仪' | 113 | if (this.isScan) { |
114 | this.$message({ | ||
115 | message: '正在启动程序请稍等', | ||
116 | type: 'success' | ||
117 | }) | ||
118 | setTimeout(() => { | ||
119 | this.scanTitle = '关闭高拍仪' | ||
120 | }, 4000) | ||
121 | } else { | ||
122 | this.scanTitle = '打开高拍仪' | ||
123 | } | ||
114 | }, | 124 | }, |
115 | /** | 125 | /** |
116 | * @description: 拍照 | 126 | * @description: 拍照 | ... | ... |
1 | <!-- | 1 | <!-- |
2 | * @Description: | 2 | * @Description: |
3 | * @Autor: renchao | 3 | * @Autor: renchao |
4 | * @LastEditTime: 2023-06-13 15:05:35 | 4 | * @LastEditTime: 2023-06-14 09:01:30 |
5 | --> | 5 | --> |
6 | <template> | 6 | <template> |
7 | <div> | 7 | <div> |
... | @@ -198,16 +198,20 @@ | ... | @@ -198,16 +198,20 @@ |
198 | var httpurl = "http://127.0.0.1:33088/"; | 198 | var httpurl = "http://127.0.0.1:33088/"; |
199 | var url = httpurl + "function=get_idcard&readnew=0" | 199 | var url = httpurl + "function=get_idcard&readnew=0" |
200 | axios.post(url).then(res => { | 200 | axios.post(url).then(res => { |
201 | if (res.data.code == 1) { | 201 | if (res.data.code == 0) { |
202 | this.$message({ | ||
203 | message: res.data.message, | ||
204 | type: 'warning' | ||
205 | }) | ||
206 | } else { | ||
207 | let data = res.data.IDCardInfo | 202 | let data = res.data.IDCardInfo |
208 | row.sqrmc = data.name | 203 | row.sqrmc = data.name |
209 | row.zjzl = 1 | 204 | row.zjzl = 1 |
210 | row.zjh = data.cardID | 205 | row.zjh = data.cardID |
206 | this.$message({ | ||
207 | message: '读取成功!', | ||
208 | type: 'success' | ||
209 | }) | ||
210 | } else { | ||
211 | this.$message({ | ||
212 | message: res.data.message, | ||
213 | type: 'warning' | ||
214 | }) | ||
211 | } | 215 | } |
212 | }) | 216 | }) |
213 | }, | 217 | }, | ... | ... |
-
Please register or sign in to post a comment