|
@@ -1,5 +1,6 @@
|
|
package com.lantone.common.config;
|
|
package com.lantone.common.config;
|
|
|
|
|
|
|
|
+import com.lantone.common.constant.AuthConstant;
|
|
import com.lantone.common.domain.SwaggerProperties;
|
|
import com.lantone.common.domain.SwaggerProperties;
|
|
import org.springframework.beans.factory.annotation.Value;
|
|
import org.springframework.beans.factory.annotation.Value;
|
|
import org.springframework.context.annotation.Bean;
|
|
import org.springframework.context.annotation.Bean;
|
|
@@ -61,8 +62,9 @@ public class BaseSwaggerConfig {
|
|
private List<ApiKey> securitySchemes() {
|
|
private List<ApiKey> securitySchemes() {
|
|
//设置请求头信息
|
|
//设置请求头信息
|
|
List<ApiKey> result = new ArrayList<>();
|
|
List<ApiKey> result = new ArrayList<>();
|
|
- ApiKey apiKey = new ApiKey("Authorization", "Authorization", "header");
|
|
|
|
- result.add(apiKey);
|
|
|
|
|
|
+ result.add(new ApiKey("token(前缀:" + AuthConstant.JWT_TOKEN_PREFIX + ")", AuthConstant.JWT_TOKEN_HEADER, "header"));
|
|
|
|
+ result.add(new ApiKey("当前医院id", AuthConstant.HOSPITAL_ID_HEADER, "header"));
|
|
|
|
+ result.add(new ApiKey("当前系统id", AuthConstant.SOFTWARE_ID_HEADER, "header"));
|
|
return result;
|
|
return result;
|
|
}
|
|
}
|
|
|
|
|