视图资源文件修改,心愿单上传数据修改

This commit is contained in:
18401019693 2023-04-03 15:39:12 +08:00
parent 153d5ff159
commit 325d7254f0
4 changed files with 12 additions and 14 deletions

View File

@ -43,14 +43,14 @@ public abstract class AbsActivity extends AppCompatActivity {
protected List<LifeCycleListener> mLifeCycleListeners;
protected boolean isFullWindow;
// @Override
// public Resources getResources() {
// Resources res = super.getResources();
// Configuration config = new Configuration();
// config.setToDefaults();
// res.updateConfiguration(config, res.getDisplayMetrics());
// return res;
// }
@Override
public Resources getResources() {
Resources res = super.getResources();
Configuration config = new Configuration();
config.setToDefaults();
res.updateConfiguration(config, res.getDisplayMetrics());
return res;
}
@Override

View File

@ -1,7 +1,5 @@
package com.yunbao.common.bean;
import androidx.room.Transaction;
import com.google.gson.annotations.Expose;
import com.google.gson.annotations.SerializedName;
@ -31,8 +29,8 @@ public class WishModel extends BaseModel {
private int giftType;
@SerializedName("price")
private int price;
@SerializedName("isShow")
private transient int isShow = -1;
@Expose(serialize = false)
private int isShow = -1;
public int getIsShow() {
return isShow;

View File

@ -105,7 +105,7 @@ public class LiveNewWishListFragment extends BaseFragment {
// 1. Gson构造器
GsonBuilder builder = new GsonBuilder();
// 2. 排除使用特定修饰符的字段
builder.excludeFieldsWithModifiers(Modifier.TRANSIENT);
builder.excludeFieldsWithoutExposeAnnotation();
// 3. 格式良好的输出
builder.setPrettyPrinting();
// 4. 创建Gson对象

View File

@ -291,7 +291,7 @@ public class LiveNewWishListPopup extends BottomPopupView {
// 1. Gson构造器
GsonBuilder builder = new GsonBuilder();
// 2. 排除使用特定修饰符的字段
builder.excludeFieldsWithModifiers(Modifier.TRANSIENT);
builder.excludeFieldsWithoutExposeAnnotation();
// 3. 格式良好的输出
builder.setPrettyPrinting();
// 4. 创建Gson对象