g40添加wifi不显示名字为空的wifi
This commit is contained in:
@@ -30,7 +30,7 @@ android {
|
|||||||
targetSdkVersion 35
|
targetSdkVersion 35
|
||||||
versionCode 2500
|
versionCode 2500
|
||||||
// versionName "2.5.0"
|
// versionName "2.5.0"
|
||||||
versionName "2.5.0-Beta1"
|
versionName "2.5.0-Beta4"
|
||||||
|
|
||||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
|
|
||||||
|
|||||||
@@ -128,7 +128,7 @@ interface INetworkService {
|
|||||||
@FormUrlEncoded
|
@FormUrlEncoded
|
||||||
@POST("user/login")
|
@POST("user/login")
|
||||||
suspend fun login(
|
suspend fun login(
|
||||||
@Field("phone") phone: String, @Field("password") password: String,
|
@Field("email") email: String, @Field("password") password: String,
|
||||||
@Field("languageCode") languageCode: String
|
@Field("languageCode") languageCode: String
|
||||||
): BaseResponse<UserBean>
|
): BaseResponse<UserBean>
|
||||||
|
|
||||||
|
|||||||
@@ -8,6 +8,7 @@ import android.net.wifi.ScanResult
|
|||||||
import android.net.wifi.WifiManager
|
import android.net.wifi.WifiManager
|
||||||
import android.os.Build
|
import android.os.Build
|
||||||
import android.provider.Settings
|
import android.provider.Settings
|
||||||
|
import android.text.TextUtils
|
||||||
import android.view.Gravity
|
import android.view.Gravity
|
||||||
import android.view.View
|
import android.view.View
|
||||||
import androidx.activity.result.contract.ActivityResultContracts
|
import androidx.activity.result.contract.ActivityResultContracts
|
||||||
@@ -297,13 +298,14 @@ class AddWifiPowerZone3Activity :
|
|||||||
wifi.SSID
|
wifi.SSID
|
||||||
}
|
}
|
||||||
bleWifi.name = wifiName.replace("\"", "")
|
bleWifi.name = wifiName.replace("\"", "")
|
||||||
wifiList.add(bleWifi)
|
if (!TextUtils.isEmpty(bleWifi.name))
|
||||||
|
wifiList.add(bleWifi)
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (wifiList.size > 0) {
|
if (wifiList.isNotEmpty()) {
|
||||||
showWifiData(wifiList)
|
showWifiData(wifiList)
|
||||||
} else {
|
} else {
|
||||||
showToast(R.string.txt_time_out_try_again, true)
|
showToast(R.string.txt_time_out_try_again, true)
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ import android.content.Intent
|
|||||||
import android.graphics.Paint
|
import android.graphics.Paint
|
||||||
import android.view.Gravity
|
import android.view.Gravity
|
||||||
import android.view.View
|
import android.view.View
|
||||||
|
import android.widget.RadioGroup
|
||||||
import androidx.activity.viewModels
|
import androidx.activity.viewModels
|
||||||
import com.abbidot.baselibrary.constant.EventName
|
import com.abbidot.baselibrary.constant.EventName
|
||||||
import com.abbidot.baselibrary.constant.MMKVKey
|
import com.abbidot.baselibrary.constant.MMKVKey
|
||||||
@@ -27,6 +28,7 @@ import com.abbidot.tracker.util.ViewUtil
|
|||||||
import com.abbidot.tracker.vm.GeoCoderViewModel
|
import com.abbidot.tracker.vm.GeoCoderViewModel
|
||||||
import com.abbidot.tracker.vm.GoogleLocationViewModel
|
import com.abbidot.tracker.vm.GoogleLocationViewModel
|
||||||
import com.abbidot.tracker.vm.SubscriptionManageViewModel
|
import com.abbidot.tracker.vm.SubscriptionManageViewModel
|
||||||
|
import com.abbidot.tracker.widget.TypefaceRoundButton
|
||||||
import com.google.android.material.bottomsheet.BottomSheetDialog
|
import com.google.android.material.bottomsheet.BottomSheetDialog
|
||||||
import kotlin.math.abs
|
import kotlin.math.abs
|
||||||
|
|
||||||
@@ -491,28 +493,28 @@ class SureSubscriptionPlanActivity :
|
|||||||
mViewBinding.apply {
|
mViewBinding.apply {
|
||||||
when (v!!) {
|
when (v!!) {
|
||||||
btnSureSubscribePlan1Continue -> {
|
btnSureSubscribePlan1Continue -> {
|
||||||
// if (AppUtils.isChina()) {
|
if (AppUtils.isChina()) {
|
||||||
// if (null == mRechargePayOptionsCn) {
|
if (null == mRechargePayOptionsCn) {
|
||||||
// mRechargePayOptionsCn = ViewUtil.instance.showBottomSheet(
|
mRechargePayOptionsCn = ViewUtil.instance.showBottomSheet(
|
||||||
// mContext,
|
mContext,
|
||||||
// R.layout.layout_recharge_pay_options_cn
|
R.layout.layout_recharge_pay_options_cn
|
||||||
// ).apply {
|
).apply {
|
||||||
// setOnClickListenerViews(findViewById<TypefaceRoundButton>(R.id.btn_pay_cn_chose_sure))
|
setOnClickListenerViews(findViewById<TypefaceRoundButton>(R.id.btn_pay_cn_chose_sure))
|
||||||
// findViewById<RadioGroup>(R.id.rg_pay_cn_chose)?.let {
|
findViewById<RadioGroup>(R.id.rg_pay_cn_chose)?.let {
|
||||||
// it.setOnCheckedChangeListener { _, checkedId ->
|
it.setOnCheckedChangeListener { _, checkedId ->
|
||||||
// when (checkedId) {
|
when (checkedId) {
|
||||||
// R.id.rb_pay_cn_chose_alipay -> mPayCnOption =
|
R.id.rb_pay_cn_chose_alipay -> mPayCnOption =
|
||||||
// ConstantInt.Type0
|
ConstantInt.Type0
|
||||||
//
|
|
||||||
// R.id.rb_pay_cn_chose_wxpay -> mPayCnOption =
|
R.id.rb_pay_cn_chose_wxpay -> mPayCnOption =
|
||||||
// ConstantInt.Type1
|
ConstantInt.Type1
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// return
|
return
|
||||||
// }
|
}
|
||||||
createOrder()
|
createOrder()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -214,7 +214,7 @@ class CreateAccountV2ThreeFragment : BaseFragment<FragmentCreateAccountV2ThreeBi
|
|||||||
password = Utils.get32Md5Value(password)
|
password = Utils.get32Md5Value(password)
|
||||||
var e = ""
|
var e = ""
|
||||||
var p = ""
|
var p = ""
|
||||||
val locale = Locale.getDefault()
|
Locale.getDefault()
|
||||||
if (AppUtils.isChina()) p = email
|
if (AppUtils.isChina()) p = email
|
||||||
else e = email
|
else e = email
|
||||||
// mUserViewModel.registerV2(
|
// mUserViewModel.registerV2(
|
||||||
@@ -222,7 +222,7 @@ class CreateAccountV2ThreeFragment : BaseFragment<FragmentCreateAccountV2ThreeBi
|
|||||||
// )
|
// )
|
||||||
setButtonEnabled(btnCreateAccountV2Signup, ConstantInt.Type0)
|
setButtonEnabled(btnCreateAccountV2Signup, ConstantInt.Type0)
|
||||||
mUserViewModel.registerV2(
|
mUserViewModel.registerV2(
|
||||||
it, e, p, password, name, locale.country.uppercase(), mWXCode
|
it, e, p, password, name, AppUtils.getCountry(), mWXCode
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -155,7 +155,6 @@ abstract class BaseBaiduMapFragment :
|
|||||||
.build()
|
.build()
|
||||||
// LogUtil.e("百度定位成功返回: ${loc.latitude}, ${loc.longitude}")
|
// LogUtil.e("百度定位成功返回: ${loc.latitude}, ${loc.longitude}")
|
||||||
setMyLocationData(locData)
|
setMyLocationData(locData)
|
||||||
locationSuccess(loc)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
onMapLoadOk(this)
|
onMapLoadOk(this)
|
||||||
@@ -215,6 +214,10 @@ abstract class BaseBaiduMapFragment :
|
|||||||
MyLocationData.Builder().latitude(it.latitude).longitude(it.longitude)
|
MyLocationData.Builder().latitude(it.latitude).longitude(it.longitude)
|
||||||
.build()
|
.build()
|
||||||
setMyLocationData(locData)
|
setMyLocationData(locData)
|
||||||
|
val bdLocation = BDLocation()
|
||||||
|
bdLocation.latitude = userGpsLat
|
||||||
|
bdLocation.longitude = userGpsLon
|
||||||
|
locationSuccess(bdLocation)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ import android.content.Context
|
|||||||
import android.content.pm.PackageManager
|
import android.content.pm.PackageManager
|
||||||
import android.graphics.Point
|
import android.graphics.Point
|
||||||
import android.location.Location
|
import android.location.Location
|
||||||
|
import android.location.LocationManager
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.view.LayoutInflater
|
import android.view.LayoutInflater
|
||||||
import android.view.View
|
import android.view.View
|
||||||
@@ -219,13 +220,16 @@ abstract class BaseGoogleMapFragment :
|
|||||||
|
|
||||||
XEventBus.observe(viewLifecycleOwner, EventName.LocationData) { loc: Location ->
|
XEventBus.observe(viewLifecycleOwner, EventName.LocationData) { loc: Location ->
|
||||||
setUserLocationData(loc.latitude, loc.longitude)
|
setUserLocationData(loc.latitude, loc.longitude)
|
||||||
locationSuccess(loc)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
val userGpsLat = MMKVUtil.getDouble(MMKVKey.UserGpsLat)
|
val userGpsLat = MMKVUtil.getDouble(MMKVKey.UserGpsLat)
|
||||||
val userGpsLon = MMKVUtil.getDouble(MMKVKey.UserGpsLon)
|
val userGpsLon = MMKVUtil.getDouble(MMKVKey.UserGpsLon)
|
||||||
if (userGpsLat != 0.0 || userGpsLon != 0.0) {
|
if (userGpsLat != 0.0 || userGpsLon != 0.0) {
|
||||||
setUserLocationData(userGpsLat, userGpsLon)
|
setUserLocationData(userGpsLat, userGpsLon)
|
||||||
|
val location = Location(LocationManager.GPS_PROVIDER)
|
||||||
|
location.latitude = userGpsLat
|
||||||
|
location.longitude = userGpsLon
|
||||||
|
locationSuccess(location)
|
||||||
}
|
}
|
||||||
|
|
||||||
onMapLoadOk(googleMap)
|
onMapLoadOk(googleMap)
|
||||||
|
|||||||
Reference in New Issue
Block a user