Commit efdc7465 authored by David黄金龙's avatar David黄金龙

统一编码

parent e9e7e7aa
...@@ -44,9 +44,9 @@ class AppDelegate: UIResponder, UIApplicationDelegate, WXApiDelegate { ...@@ -44,9 +44,9 @@ class AppDelegate: UIResponder, UIApplicationDelegate, WXApiDelegate {
preloadOP() preloadOP()
//微信注册app //微信注册app
WXApi.registerApp("wx06b21f3c7a5ba594", universalLink: "https://www.galaxy-immi.com/app1/") WXApi.registerApp(YhConstant.Wechat.appKey, universalLink: YhConstant.Wechat.universalLink)
WXApi.startLog(by: .detail) { string in WXApi.startLog(by: .detail) { string in
print("\(string)") printLog(string)
} }
// 一键登录 // 一键登录
...@@ -102,7 +102,7 @@ extension AppDelegate { ...@@ -102,7 +102,7 @@ extension AppDelegate {
private func thirdSetting() -> Void { private func thirdSetting() -> Void {
//1.数据解析 //1.数据解析
#if DEBUG #if DEBUG
SmartConfig.debugMode = .none
#elseif TESTNEV #elseif TESTNEV
SmartConfig.debugMode = .none SmartConfig.debugMode = .none
#else #else
...@@ -111,11 +111,11 @@ extension AppDelegate { ...@@ -111,11 +111,11 @@ extension AppDelegate {
//2.bugly参数设置 //2.bugly参数设置
#if DEBUG #if DEBUG
Bugly.start(withAppId: "3b10faa43e") Bugly.start(withAppId: YhConstant.Bugly.appidForTest)
#elseif TESTNEV #elseif TESTNEV
Bugly.start(withAppId: "3b10faa43e") Bugly.start(withAppId: YhConstant.Bugly.appidForTest)
#else #else
Bugly.start(withAppId: "5dc2acc53e") Bugly.start(withAppId: YhConstant.Bugly.appidForRelease)
#endif #endif
} }
......
...@@ -38,7 +38,7 @@ extension AppDelegate: JPUSHRegisterDelegate { ...@@ -38,7 +38,7 @@ extension AppDelegate: JPUSHRegisterDelegate {
let isProduction = true let isProduction = true
#endif #endif
JPUSHService.setup(withOption:launchOptions, JPUSHService.setup(withOption:launchOptions,
appKey:"c6a9e10575b85ee90f3e8afe", appKey:YhConstant.Jpush.appKey,
channel:"appStore", channel:"appStore",
apsForProduction: isProduction) apsForProduction: isProduction)
} }
......
...@@ -14,26 +14,20 @@ class YHAnalytics { ...@@ -14,26 +14,20 @@ class YHAnalytics {
// 分析初始化 // 分析初始化
static func analyticsStart(launchOptions: [UIApplication.LaunchOptionsKey: Any]?) { static func analyticsStart(launchOptions: [UIApplication.LaunchOptionsKey: Any]?) {
#if DEBUG #if DEBUG
let options = SAConfigOptions.init(serverURL: "https://importsensors.galaxy-immi.com/sa?project=default", launchOptions: launchOptions) let options = SAConfigOptions.init(serverURL: YhConstant.SensorsAnalytics.urlForTest, launchOptions: launchOptions)
//开启log //开启log
options.enableLog = true options.enableLog = true
SensorsAnalyticsSDK.sharedInstance()?.set(["evn" : "test"]) SensorsAnalyticsSDK.sharedInstance()?.set(["evn" : "test"])
#elseif TESTENV #elseif TESTENV
let options = SAConfigOptions.init(serverURL: "https://importsensors.galaxy-immi.com/sa?project=default", launchOptions: launchOptions) let options = SAConfigOptions.init(serverURL: YhConstant.SensorsAnalytics.urlForTest, launchOptions: launchOptions)
//开启log //开启log
options.enableLog = true options.enableLog = true
SensorsAnalyticsSDK.sharedInstance()?.set(["evn" : "test"]) SensorsAnalyticsSDK.sharedInstance()?.set(["evn" : "test"])
#else #else
let options = SAConfigOptions.init(serverURL: "url地址,由管理员提供", launchOptions: launchOptions) let options = SAConfigOptions.init(serverURL: YhConstant.SensorsAnalytics.urlForRelease, launchOptions: launchOptions)
//开启log //开启log
options.enableLog = false options.enableLog = false
SensorsAnalyticsSDK.sharedInstance()?.set(["evn" : "production"]) SensorsAnalyticsSDK.sharedInstance()?.set(["evn" : "production"])
#endif #endif
/** /**
......
...@@ -161,21 +161,36 @@ func goTabBarBy(tabType : tabBarPageType) { ...@@ -161,21 +161,36 @@ func goTabBarBy(tabType : tabBarPageType) {
class YhConstant { class YhConstant {
// MARK: - 登录信息 // MARK: - 登录信息
static let KLoginedInfoKey = "KLoginedInfoKey" static let KLoginedInfoKey = "KLoginedInfoKey"
//登录后的用户信息
static let kLoginUserInfo = "loginUserInfo"
} }
extension YhConstant { extension YhConstant {
//登录后的用户信息 // MARK: - bugly
static let kLoginUserInfo = "loginUserInfo" struct Bugly {
static let appidForTest = "3b10faa43e"
static let appidForRelease = "5dc2acc53e"
}
// MARK: - 友盟相关 // MARK: - 神策
struct Wechat { struct SensorsAnalytics {
static let appKey = "wx57b2a7469d15ff8f" static let urlForTest = "https://importsensors.galaxy-immi.com/sa?project=default"
static let AppSecret = "e0a351290c66c05f85c54a31b213c1aa" static let urlForRelease = "https://importsensors.galaxy-immi.com/sa?project=production_1"
}
// MARK: - 极光推送
struct Jpush {
static let appKey = "c6a9e10575b85ee90f3e8afe"
} }
struct UM { // MARK: - 微信相关
static let appKey = "5a77b807a40fa30f0300008b" struct Wechat {
static let appKey = "wx06b21f3c7a5ba594"
static let universalLink = "https://www.galaxy-immi.com/app1/"
} }
// MARK: - 支付宝 // MARK: - 支付宝
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment