| | |
| | | package com.ruoyi.framework.config; |
| | | |
| | | import cn.dev33.satoken.SaManager; |
| | | import cn.dev33.satoken.config.SaTokenConfig; |
| | | import com.github.xiaoymin.knife4j.spring.annotations.EnableKnife4j; |
| | | import com.ruoyi.common.utils.StringUtils; |
| | | import com.ruoyi.common.utils.spring.SpringUtils; |
| | |
| | | |
| | | @Autowired |
| | | private SwaggerProperties swaggerProperties; |
| | | @Autowired |
| | | private SaTokenConfig saTokenConfig; |
| | | |
| | | /** |
| | | * 创建API |
| | |
| | | */ |
| | | private List<SecurityScheme> securitySchemes() { |
| | | List<SecurityScheme> apiKeyList = new ArrayList<SecurityScheme>(); |
| | | String header = SaManager.getConfig().getTokenName(); |
| | | String header = saTokenConfig.getTokenName(); |
| | | apiKeyList.add(new ApiKey(header, header, In.HEADER.toValue())); |
| | | return apiKeyList; |
| | | } |