From 0142fb56c25b23989f441d527db348fbd2797b81 Mon Sep 17 00:00:00 2001
From: 18034727885 <973609879@qq.com>
Date: 星期五, 03 七月 2026 13:59:19 +0800
Subject: [PATCH] 修复问题
---
app/src/main/java/com/fangxinxing/xxfxx/ui/mine/WithdrawAccountActivity.kt | 39 +++++++++++++++++++++++----------------
1 files changed, 23 insertions(+), 16 deletions(-)
diff --git a/app/src/main/java/com/fangxinxing/xxfxx/ui/mine/WithdrawAccountActivity.kt b/app/src/main/java/com/fangxinxing/xxfxx/ui/mine/WithdrawAccountActivity.kt
index c1f0f2f..334f589 100644
--- a/app/src/main/java/com/fangxinxing/xxfxx/ui/mine/WithdrawAccountActivity.kt
+++ b/app/src/main/java/com/fangxinxing/xxfxx/ui/mine/WithdrawAccountActivity.kt
@@ -313,23 +313,30 @@
backImg = ""
}
showDialog()
- HttpManager.getInstance().post(Api.upImage, file,object : MyObserver(this@WithdrawAccountActivity){
- override fun success(responseString: String?) {
- val fromJson = gson.fromJson<StringBean>(responseString, StringBean::class.java)
- var url = fromJson.data
- if (!url.isNullOrEmpty()){
- if (requestCode == 2){
- frontImg = url
- GlideUtil.load(MyApplication.getInstance(), frontImg, iv_front,0)
+ HttpManager.getInstance().post(
+ Api.upImage,
+ file,
+ object : MyUploadObserver(this@WithdrawAccountActivity) {
+ override fun success(responseString: String) {
+ if (requestCode == 2) {
+ frontImg = responseString
+ GlideUtil.load(
+ MyApplication.getInstance(),
+ frontImg,
+ iv_front,
+ 0
+ )
+ } else {
+ backImg = responseString
+ GlideUtil.load(
+ MyApplication.getInstance(),
+ backImg,
+ iv_back,
+ 0
+ )
}
- else{
- backImg = url
- GlideUtil.load(MyApplication.getInstance(), backImg, iv_back,0)
- }
- }else
- toast(fromJson.msg ?: "上传失败")
- }
- })
+ }
+ })
upload(true,
Api.uploadImg,file){
--
Gitblit v1.7.1