28 lines
639 B
Dart
28 lines
639 B
Dart
class Config {
|
|
///获取环境
|
|
static String getEnv() {
|
|
const env = String.fromEnvironment('ENV', defaultValue: 'dev');
|
|
return env;
|
|
}
|
|
|
|
///获取接口地址
|
|
static String baseUrl() {
|
|
if (getEnv() == 'dev') {
|
|
return 'https://xueguang.test.tuzuu.com/api';
|
|
} else {
|
|
return 'https://xueguang.test.tuzuu.com/api';
|
|
}
|
|
}
|
|
|
|
/// 获取websocket地址
|
|
static String wsUrl() {
|
|
return "wss://xueguang.test.tuzuu.com/ws";
|
|
}
|
|
|
|
///网页域名地址
|
|
static String get webUrl => "http://xueguang.test.tuzuu.com";
|
|
|
|
///声网APPid
|
|
static String get swAppId => "011c2fd2e1854511a80c1aebded4eee7";
|
|
}
|