【功能优化】积木报表:使用 refreshToken 认证,解决无法刷新访问令牌的问题
							parent
							
								
									86c33e1f68
								
							
						
					
					
						commit
						2d245d1fe7
					
				| 
						 | 
				
			
			@ -6,9 +6,10 @@
 | 
			
		|||
  </ContentWrap>
 | 
			
		||||
</template>
 | 
			
		||||
<script lang="ts" setup>
 | 
			
		||||
import { getAccessToken } from '@/utils/auth'
 | 
			
		||||
import { getRefreshToken } from '@/utils/auth'
 | 
			
		||||
 | 
			
		||||
defineOptions({ name: 'JimuReport' })
 | 
			
		||||
 | 
			
		||||
const src = ref(import.meta.env.VITE_BASE_URL + '/jmreport/list?token=' + getAccessToken())
 | 
			
		||||
// 使用 getRefreshToken() 方法,而不使用 getAccessToken() 方法的原因:积木报表无法方便的刷新访问令牌
 | 
			
		||||
const src = ref(import.meta.env.VITE_BASE_URL + '/jmreport/list?token=' + getRefreshToken())
 | 
			
		||||
</script>
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue