forked from github/dataease
fix: 仪表盘分享公共连接地址为localhost,无法访问
This commit is contained in:
parent
0142ec49e5
commit
b717b406b2
@ -24,8 +24,7 @@ import java.util.Map;
|
||||
@Service
|
||||
public class PanelLinkService {
|
||||
|
||||
@Value("${public-link-url:http://localhost:9528/link.html?link=}")
|
||||
private String baseUrl;
|
||||
private static final String baseUrl = "/link.html?link=";
|
||||
|
||||
@Value("${public-link-salt:DataEaseLinkSalt}")
|
||||
private String salt;
|
||||
|
@ -66,6 +66,11 @@ export default {
|
||||
defaultForm: { enablePwd: false, pwd: null, uri: null }
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
origin() {
|
||||
return window.location.origin
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.form = this.defaultForm
|
||||
this.currentGenerate()
|
||||
@ -76,7 +81,7 @@ export default {
|
||||
const { valid, enablePwd, pwd, uri } = res.data
|
||||
this.valid = valid
|
||||
this.form.enablePwd = enablePwd
|
||||
this.form.uri = uri
|
||||
this.form.uri = uri ? (this.origin + uri) : uri
|
||||
// 返回的密码是共钥加密后的 所以展示需要私钥解密一波
|
||||
pwd && (this.form.pwd = decrypt(pwd))
|
||||
})
|
||||
|
Loading…
Reference in New Issue
Block a user