From ab9e0ae52d360fbe512bfbd3205206fcf4221be9 Mon Sep 17 00:00:00 2001
From: Guo_shaoshan <2055829622@qq.com>
Date: 星期日, 09 四月 2023 10:41:46 +0800
Subject: [PATCH] 成长经历添加数据
---
app/src/main/java/com/application/zhangshi_app_android/ui/function/GrowthExperienceActivity.java | 67 ++++
app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperienceRelationshipRvAdapter.java | 124 ++++++++
app/src/main/java/com/application/zhangshi_app_android/data/source/http/ApiService.java | 7
app/src/main/res/layout/item_growth_experience_primary.xml | 9
app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperiencePrimaryRvAdapter.java | 141 ++++++++++
app/src/main/java/com/application/zhangshi_app_android/data/DataRepository.java | 8
app/src/main/java/com/application/zhangshi_app_android/ui/function/GrowthExperienceActivityViewModel.java | 88 ++++++
app/src/main/res/layout/item_growth_experience_holder_condition.xml | 10
app/src/main/java/com/application/zhangshi_app_android/bean/GrowthExperienceResponseBean.java | 14 +
app/src/main/res/layout/item_growth_experience_relationship.xml | 13
app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperienceHolderConditionRvAdapter.java | 124 ++++++++
app/src/main/java/com/application/zhangshi_app_android/bean/GrowthExperienceRequestBean.java | 20 +
app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperienceAbroadConditionRvAdapter.java | 123 ++++++++
app/src/main/res/layout/item_growth_experience_abroad_condition.xml | 11
app/src/main/java/com/application/zhangshi_app_android/bean/GrowthExperienceBean.java | 27 +
app/src/main/java/com/application/zhangshi_app_android/data/source/HttpDataSource.java | 8
app/src/main/java/com/application/zhangshi_app_android/data/source/http/HttpDataSourceImpl.java | 9
app/src/main/res/layout/activity_growth_experience.xml | 10
18 files changed, 793 insertions(+), 20 deletions(-)
diff --git a/app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperienceAbroadConditionRvAdapter.java b/app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperienceAbroadConditionRvAdapter.java
new file mode 100644
index 0000000..b6bf3c3
--- /dev/null
+++ b/app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperienceAbroadConditionRvAdapter.java
@@ -0,0 +1,123 @@
+package com.application.zhangshi_app_android.adapter;
+import android.content.Context;
+import android.content.Intent;
+import android.view.View;
+import android.view.animation.Animation;
+import android.view.animation.Transformation;
+import android.widget.FrameLayout;
+import com.android.app_base.base.adapter.BaseRVAdapter;
+import com.android.app_base.manager.AppManager;
+import com.application.zhangshi_app_android.R;
+import com.application.zhangshi_app_android.bean.GrowthExperienceBean;
+import com.application.zhangshi_app_android.databinding.ItemGrowthExperienceAbroadConditionBinding;
+import com.application.zhangshi_app_android.ui.function.GrowthExperienceActivity;
+import com.application.zhangshi_app_android.ui.function.GrowthExperienceActivityViewModel;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+
+/**
+ * @author Gss
+ * @date 2023.04.08. 17:08
+ * @desc 鎴愰暱缁忓巻(鍑哄浗(澧�)鎯呭喌) recyclerView 鐨� adapter
+ */
+public class GrowthExperienceAbroadConditionRvAdapter extends BaseRVAdapter<GrowthExperienceBean, ItemGrowthExperienceAbroadConditionBinding, GrowthExperienceAbroadConditionRvAdapter.ViewHolder> {
+
+ private GrowthExperienceActivityViewModel viewModel;
+
+ public GrowthExperienceAbroadConditionRvAdapter(Context context) {
+ super(context);
+ }
+
+ public GrowthExperienceAbroadConditionRvAdapter(Context context, GrowthExperienceActivityViewModel viewModel) {
+ super(context);
+ this.viewModel = viewModel;
+ }
+
+ @Override
+ protected int getLayoutId() {
+ return R.layout.item_growth_experience_abroad_condition;
+ }
+
+ @Override
+ protected ViewHolder getViewHolder(ItemGrowthExperienceAbroadConditionBinding itemBind) {
+ return new ViewHolder(itemBind);
+ }
+
+ @Override
+ protected void onBind(ViewHolder holder, int position) {
+ holder.getBinding().setBean(mDataList.get(position));
+ if (position % 2 != 0){
+ holder.getBinding().cardView.setCardBackgroundColor(mContext.getColor(R.color.color_card_blue));
+ }else {
+ holder.getBinding().cardView.setCardBackgroundColor(mContext.getColor(R.color.color_card_pink));
+ }
+ holder.getBinding().layoutTitle.setOnClickListener(new View.OnClickListener() {
+ @Override
+ public void onClick(View view) {
+ if (holder.isExpended){
+ int initialHeight = holder.getBinding().cardView.getMeasuredHeight();
+ int collapsedHeight = holder.getBinding().layoutTitle.getMeasuredHeight();
+ int distanceToCollapse = (int) (initialHeight - collapsedHeight);
+
+ Animation a = new Animation() {
+ @Override
+ protected void applyTransformation(float interpolatedTime, Transformation t) {
+ if (interpolatedTime == 1){
+ }
+ holder.getBinding().cardView.getLayoutParams().height = (int) (initialHeight - (distanceToCollapse * interpolatedTime));
+ holder.getBinding().cardView.requestLayout();
+ }
+
+ @Override
+ public boolean willChangeBounds() {
+ return true;
+ }
+ };
+ a.setDuration(500);
+ holder.getBinding().cardView.startAnimation(a);
+ holder.isExpended = false;
+ }else{
+ final int initialHeight = holder.getBinding().cardView.getMeasuredHeight();
+ holder.getBinding().cardView.measure(FrameLayout.LayoutParams.MATCH_PARENT, FrameLayout.LayoutParams.WRAP_CONTENT);
+ int targetHeight = holder.getBinding().cardView.getMeasuredHeight();
+ int distanceToExpand = targetHeight - initialHeight;
+ Animation a = new Animation() {
+ @Override
+ protected void applyTransformation(float interpolatedTime, Transformation t) {
+ if (interpolatedTime == 1){
+ }
+ holder.getBinding().cardView.getLayoutParams().height = (int) (initialHeight + (distanceToExpand * interpolatedTime));
+ holder.getBinding().cardView.requestLayout();
+ }
+
+ @Override
+ public boolean willChangeBounds() {
+ return true;
+ }
+ };
+ a.setDuration(500);
+ holder.getBinding().cardView.startAnimation(a);
+ holder.isExpended = true;
+ }
+ }
+ });
+ holder.getBinding().layoutContent.setOnClickListener(v -> {
+ AppManager.getAppManager().startActivity(
+ new Intent(getRecyclerView().getContext(), GrowthExperienceActivity.class)
+ .putExtra("bean",mDataList.get(position)));
+ });
+ }
+
+ public static class ViewHolder extends BaseViewHolder<ItemGrowthExperienceAbroadConditionBinding>{
+ private boolean isExpended;
+
+ public ViewHolder(ItemGrowthExperienceAbroadConditionBinding binding) {
+ super(binding);
+ }
+ }
+
+}
+
+
diff --git a/app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperienceHolderConditionRvAdapter.java b/app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperienceHolderConditionRvAdapter.java
new file mode 100644
index 0000000..008b3ed
--- /dev/null
+++ b/app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperienceHolderConditionRvAdapter.java
@@ -0,0 +1,124 @@
+package com.application.zhangshi_app_android.adapter;
+
+import android.content.Context;
+import android.content.Intent;
+import android.view.View;
+import android.view.animation.Animation;
+import android.view.animation.Transformation;
+import android.widget.FrameLayout;
+import com.android.app_base.base.adapter.BaseRVAdapter;
+import com.android.app_base.manager.AppManager;
+import com.application.zhangshi_app_android.R;
+import com.application.zhangshi_app_android.bean.GrowthExperienceBean;
+import com.application.zhangshi_app_android.databinding.ItemGrowthExperienceHolderConditionBinding;
+import com.application.zhangshi_app_android.ui.function.GrowthExperienceActivity;
+import com.application.zhangshi_app_android.ui.function.GrowthExperienceActivityViewModel;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+
+/**
+ * @author Gss
+ * @date 2023.04.08. 17:08
+ * @desc 鎴愰暱缁忓巻(鎸佹湁鍑哄叆澧冭瘉浠舵儏鍐�) recyclerView 鐨� adapter
+ */
+public class GrowthExperienceHolderConditionRvAdapter extends BaseRVAdapter<GrowthExperienceBean, ItemGrowthExperienceHolderConditionBinding, GrowthExperienceHolderConditionRvAdapter.ViewHolder> {
+
+ private GrowthExperienceActivityViewModel viewModel;
+
+ public GrowthExperienceHolderConditionRvAdapter(Context context) {
+ super(context);
+ }
+
+ public GrowthExperienceHolderConditionRvAdapter(Context context, GrowthExperienceActivityViewModel viewModel) {
+ super(context);
+ this.viewModel = viewModel;
+ }
+
+ @Override
+ protected int getLayoutId() {
+ return R.layout.item_growth_experience_holder_condition;
+ }
+
+ @Override
+ protected ViewHolder getViewHolder(ItemGrowthExperienceHolderConditionBinding itemBind) {
+ return new ViewHolder(itemBind);
+ }
+
+ @Override
+ protected void onBind(ViewHolder holder, int position) {
+ holder.getBinding().setBean(mDataList.get(position));
+ if (position % 2 != 0){
+ holder.getBinding().cardView.setCardBackgroundColor(mContext.getColor(R.color.color_card_blue));
+ }else {
+ holder.getBinding().cardView.setCardBackgroundColor(mContext.getColor(R.color.color_card_pink));
+ }
+ holder.getBinding().layoutTitle.setOnClickListener(new View.OnClickListener() {
+ @Override
+ public void onClick(View view) {
+ if (holder.isExpended){
+ int initialHeight = holder.getBinding().cardView.getMeasuredHeight();
+ int collapsedHeight = holder.getBinding().layoutTitle.getMeasuredHeight();
+ int distanceToCollapse = (int) (initialHeight - collapsedHeight);
+
+ Animation a = new Animation() {
+ @Override
+ protected void applyTransformation(float interpolatedTime, Transformation t) {
+ if (interpolatedTime == 1){
+ }
+ holder.getBinding().cardView.getLayoutParams().height = (int) (initialHeight - (distanceToCollapse * interpolatedTime));
+ holder.getBinding().cardView.requestLayout();
+ }
+
+ @Override
+ public boolean willChangeBounds() {
+ return true;
+ }
+ };
+ a.setDuration(500);
+ holder.getBinding().cardView.startAnimation(a);
+ holder.isExpended = false;
+ }else{
+ final int initialHeight = holder.getBinding().cardView.getMeasuredHeight();
+ holder.getBinding().cardView.measure(FrameLayout.LayoutParams.MATCH_PARENT, FrameLayout.LayoutParams.WRAP_CONTENT);
+ int targetHeight = holder.getBinding().cardView.getMeasuredHeight();
+ int distanceToExpand = targetHeight - initialHeight;
+ Animation a = new Animation() {
+ @Override
+ protected void applyTransformation(float interpolatedTime, Transformation t) {
+ if (interpolatedTime == 1){
+ }
+ holder.getBinding().cardView.getLayoutParams().height = (int) (initialHeight + (distanceToExpand * interpolatedTime));
+ holder.getBinding().cardView.requestLayout();
+ }
+
+ @Override
+ public boolean willChangeBounds() {
+ return true;
+ }
+ };
+ a.setDuration(500);
+ holder.getBinding().cardView.startAnimation(a);
+ holder.isExpended = true;
+ }
+ }
+ });
+ holder.getBinding().layoutContent.setOnClickListener(v -> {
+ AppManager.getAppManager().startActivity(
+ new Intent(getRecyclerView().getContext(), GrowthExperienceActivity.class)
+ .putExtra("bean",mDataList.get(position)));
+ });
+ }
+
+ public static class ViewHolder extends BaseViewHolder<ItemGrowthExperienceHolderConditionBinding>{
+ private boolean isExpended;
+
+ public ViewHolder(ItemGrowthExperienceHolderConditionBinding binding) {
+ super(binding);
+ }
+ }
+
+}
+
+
diff --git a/app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperiencePrimaryRvAdapter.java b/app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperiencePrimaryRvAdapter.java
new file mode 100644
index 0000000..3f003b1
--- /dev/null
+++ b/app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperiencePrimaryRvAdapter.java
@@ -0,0 +1,141 @@
+package com.application.zhangshi_app_android.adapter;
+
+import android.content.Context;
+import android.content.Intent;
+import android.view.LayoutInflater;
+import android.view.View;
+import android.view.ViewGroup;
+import android.view.animation.Animation;
+import android.view.animation.Transformation;
+import android.widget.FrameLayout;
+
+import androidx.annotation.NonNull;
+import androidx.databinding.DataBindingUtil;
+
+import com.android.app_base.base.adapter.BaseRVAdapter;
+import com.android.app_base.manager.AppManager;
+import com.application.zhangshi_app_android.R;
+import com.application.zhangshi_app_android.bean.GrowthExperienceBean;
+import com.application.zhangshi_app_android.databinding.ItemGrowthExperiencePrimaryBinding;
+import com.application.zhangshi_app_android.ui.function.GrowthExperienceActivity;
+import com.application.zhangshi_app_android.ui.function.GrowthExperienceActivityViewModel;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+
+/**
+ * @author Gss
+ * @date 2023.04.07. 21:31
+ * @desc 鎴愰暱缁忓巻(涓昏瀛︿範鍙婂伐浣滅粡鍘�) recyclerView 鐨� adapter
+ */
+public class GrowthExperiencePrimaryRvAdapter extends BaseRVAdapter<GrowthExperienceBean, ItemGrowthExperiencePrimaryBinding, GrowthExperiencePrimaryRvAdapter.ViewHolder> {
+
+ private GrowthExperienceActivityViewModel viewModel;
+ private List<GrowthExperienceBean> mDataList;
+
+ public GrowthExperiencePrimaryRvAdapter(Context context,List<GrowthExperienceBean> dataList) {
+ super(context);
+ mDataList = dataList;
+ }
+
+ public GrowthExperiencePrimaryRvAdapter(Context context, GrowthExperienceActivityViewModel viewModel) {
+ super(context);
+ this.viewModel = viewModel;
+ }
+
+ public GrowthExperiencePrimaryRvAdapter(GrowthExperienceActivity growthExperienceActivity) {
+ super(growthExperienceActivity);
+ }
+
+ public ViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
+ ItemGrowthExperiencePrimaryBinding itemBind = DataBindingUtil.inflate(LayoutInflater.from(parent.getContext()),getLayoutId(),parent,false);
+ return new ViewHolder(itemBind);
+ }
+ @Override
+ protected int getLayoutId() {
+ return R.layout.item_growth_experience_primary;
+ }
+
+ @Override
+ protected ViewHolder getViewHolder(ItemGrowthExperiencePrimaryBinding itemBind) {
+ return new ViewHolder(itemBind);
+ }
+
+ @Override
+ protected void onBind(ViewHolder holder, int position) {
+ holder.getBinding().setBean(mDataList.get(position));
+ if (position % 2 != 0){
+ holder.getBinding().cardView.setCardBackgroundColor(mContext.getColor(R.color.color_card_blue));
+ }else {
+ holder.getBinding().cardView.setCardBackgroundColor(mContext.getColor(R.color.color_card_pink));
+ }
+ holder.getBinding().layoutTitle.setOnClickListener(new View.OnClickListener() {
+ @Override
+ public void onClick(View view) {
+ if (holder.isExpended){
+ int initialHeight = holder.getBinding().cardView.getMeasuredHeight();
+ int collapsedHeight = holder.getBinding().layoutTitle.getMeasuredHeight();
+ int distanceToCollapse = (int) (initialHeight - collapsedHeight);
+
+ Animation a = new Animation() {
+ @Override
+ protected void applyTransformation(float interpolatedTime, Transformation t) {
+ if (interpolatedTime == 1){
+ }
+ holder.getBinding().cardView.getLayoutParams().height = (int) (initialHeight - (distanceToCollapse * interpolatedTime));
+ holder.getBinding().cardView.requestLayout();
+ }
+
+ @Override
+ public boolean willChangeBounds() {
+ return true;
+ }
+ };
+ a.setDuration(500);
+ holder.getBinding().cardView.startAnimation(a);
+ holder.isExpended = false;
+ }else{
+ final int initialHeight = holder.getBinding().cardView.getMeasuredHeight();
+ holder.getBinding().cardView.measure(FrameLayout.LayoutParams.MATCH_PARENT, FrameLayout.LayoutParams.WRAP_CONTENT);
+ int targetHeight = holder.getBinding().cardView.getMeasuredHeight();
+ int distanceToExpand = targetHeight - initialHeight;
+ Animation a = new Animation() {
+ @Override
+ protected void applyTransformation(float interpolatedTime, Transformation t) {
+ if (interpolatedTime == 1){
+ }
+ holder.getBinding().cardView.getLayoutParams().height = (int) (initialHeight + (distanceToExpand * interpolatedTime));
+ holder.getBinding().cardView.requestLayout();
+ }
+
+ @Override
+ public boolean willChangeBounds() {
+ return true;
+ }
+ };
+ a.setDuration(500);
+ holder.getBinding().cardView.startAnimation(a);
+ holder.isExpended = true;
+ }
+ }
+ });
+ holder.getBinding().layoutContent.setOnClickListener(v -> {
+ AppManager.getAppManager().startActivity(
+ new Intent(getRecyclerView().getContext(), GrowthExperienceActivity.class)
+ .putExtra("bean",mDataList.get(position)));
+ });
+ }
+
+ public static class ViewHolder extends BaseViewHolder<ItemGrowthExperiencePrimaryBinding>{
+ private boolean isExpended;
+ private ItemGrowthExperiencePrimaryBinding binding;
+
+ public ViewHolder(ItemGrowthExperiencePrimaryBinding binding) {
+ super(binding);
+ binding=ItemGrowthExperiencePrimaryBinding.inflate(LayoutInflater.from(itemBind.getContext()),(ViewGroup) itemBind,false);
+ }
+ }
+
+}
+
+
diff --git a/app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperienceRelationshipRvAdapter.java b/app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperienceRelationshipRvAdapter.java
new file mode 100644
index 0000000..0e36b9a
--- /dev/null
+++ b/app/src/main/java/com/application/zhangshi_app_android/adapter/GrowthExperienceRelationshipRvAdapter.java
@@ -0,0 +1,124 @@
+package com.application.zhangshi_app_android.adapter;
+
+import android.content.Context;
+import android.content.Intent;
+import android.view.View;
+import android.view.animation.Animation;
+import android.view.animation.Transformation;
+import android.widget.FrameLayout;
+import com.android.app_base.base.adapter.BaseRVAdapter;
+import com.android.app_base.manager.AppManager;
+import com.application.zhangshi_app_android.R;
+import com.application.zhangshi_app_android.bean.GrowthExperienceBean;
+import com.application.zhangshi_app_android.databinding.ItemGrowthExperienceRelationshipBinding;
+import com.application.zhangshi_app_android.ui.function.GrowthExperienceActivity;
+import com.application.zhangshi_app_android.ui.function.GrowthExperienceActivityViewModel;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+
+/**
+ * @author Gss
+ * @date 2023.04.08. 17:08
+ * @desc 鎴愰暱缁忓巻(瀹跺涵鎴愬憳鍙婁富瑕佺ぞ浼氬叧绯绘儏鍐�) recyclerView 鐨� adapter
+ */
+public class GrowthExperienceRelationshipRvAdapter extends BaseRVAdapter<GrowthExperienceBean, ItemGrowthExperienceRelationshipBinding, GrowthExperienceRelationshipRvAdapter.ViewHolder> {
+
+ private GrowthExperienceActivityViewModel viewModel;
+
+ public GrowthExperienceRelationshipRvAdapter(Context context) {
+ super(context);
+ }
+
+ public GrowthExperienceRelationshipRvAdapter(Context context, GrowthExperienceActivityViewModel viewModel) {
+ super(context);
+ this.viewModel = viewModel;
+ }
+
+ @Override
+ protected int getLayoutId() {
+ return R.layout.item_growth_experience_relationship;
+ }
+
+ @Override
+ protected ViewHolder getViewHolder(ItemGrowthExperienceRelationshipBinding itemBind) {
+ return new ViewHolder(itemBind);
+ }
+
+ @Override
+ protected void onBind(ViewHolder holder, int position) {
+ holder.getBinding().setBean(mDataList.get(position));
+ if (position % 2 != 0){
+ holder.getBinding().cardView.setCardBackgroundColor(mContext.getColor(R.color.color_card_blue));
+ }else {
+ holder.getBinding().cardView.setCardBackgroundColor(mContext.getColor(R.color.color_card_pink));
+ }
+ holder.getBinding().layoutTitle.setOnClickListener(new View.OnClickListener() {
+ @Override
+ public void onClick(View view) {
+ if (holder.isExpended){
+ int initialHeight = holder.getBinding().cardView.getMeasuredHeight();
+ int collapsedHeight = holder.getBinding().layoutTitle.getMeasuredHeight();
+ int distanceToCollapse = (int) (initialHeight - collapsedHeight);
+
+ Animation a = new Animation() {
+ @Override
+ protected void applyTransformation(float interpolatedTime, Transformation t) {
+ if (interpolatedTime == 1){
+ }
+ holder.getBinding().cardView.getLayoutParams().height = (int) (initialHeight - (distanceToCollapse * interpolatedTime));
+ holder.getBinding().cardView.requestLayout();
+ }
+
+ @Override
+ public boolean willChangeBounds() {
+ return true;
+ }
+ };
+ a.setDuration(500);
+ holder.getBinding().cardView.startAnimation(a);
+ holder.isExpended = false;
+ }else{
+ final int initialHeight = holder.getBinding().cardView.getMeasuredHeight();
+ holder.getBinding().cardView.measure(FrameLayout.LayoutParams.MATCH_PARENT, FrameLayout.LayoutParams.WRAP_CONTENT);
+ int targetHeight = holder.getBinding().cardView.getMeasuredHeight();
+ int distanceToExpand = targetHeight - initialHeight;
+ Animation a = new Animation() {
+ @Override
+ protected void applyTransformation(float interpolatedTime, Transformation t) {
+ if (interpolatedTime == 1){
+ }
+ holder.getBinding().cardView.getLayoutParams().height = (int) (initialHeight + (distanceToExpand * interpolatedTime));
+ holder.getBinding().cardView.requestLayout();
+ }
+
+ @Override
+ public boolean willChangeBounds() {
+ return true;
+ }
+ };
+ a.setDuration(500);
+ holder.getBinding().cardView.startAnimation(a);
+ holder.isExpended = true;
+ }
+ }
+ });
+ holder.getBinding().layoutContent.setOnClickListener(v -> {
+ AppManager.getAppManager().startActivity(
+ new Intent(getRecyclerView().getContext(), GrowthExperienceActivity.class)
+ .putExtra("bean",mDataList.get(position)));
+ });
+ }
+
+ public static class ViewHolder extends BaseViewHolder<ItemGrowthExperienceRelationshipBinding>{
+ private boolean isExpended;
+
+ public ViewHolder(ItemGrowthExperienceRelationshipBinding binding) {
+ super(binding);
+ }
+ }
+
+}
+
+
diff --git a/app/src/main/java/com/application/zhangshi_app_android/bean/GrowthExperienceBean.java b/app/src/main/java/com/application/zhangshi_app_android/bean/GrowthExperienceBean.java
index 2dd0127..88bf538 100644
--- a/app/src/main/java/com/application/zhangshi_app_android/bean/GrowthExperienceBean.java
+++ b/app/src/main/java/com/application/zhangshi_app_android/bean/GrowthExperienceBean.java
@@ -10,22 +10,32 @@
*/
public class GrowthExperienceBean implements Serializable {
private String idName;
+ private String witness;
private String usedName;
private String gender;
+ private String associate;
private String nationality;
private String ethnicGroup;
private String marriageCondition;
private String politicalStatus;
private String contactNumber;
private String idNumber;
+ private String residenceNumber;
+ private String reason;
private String address;
+ private String identity;
private String duringTime;
+ private String duringYear;
private String relationship;
private String School;
private String passCheck;
private String abroadZone;
private List<String> url;
-
+ public GrowthExperienceBean(String mDuringYear,String school,String name){
+ idName=name;
+ School=school;
+ duringYear=mDuringYear;
+ }
public String getAddress() { return address; }
public void setAddress(String value) { this.address = value; }
@@ -33,11 +43,17 @@
public void setIdName(String value) { this.idName = value; }
public String getUsedName() { return usedName; }
public void setUsedName(String value) { this.usedName = value; }
+ public String getAssociate() { return associate; }
+ public void setAssociate(String value) { this.associate = value; }
-
+ public String getWitness() { return witness; }
+ public void setWitness(String value) { this.witness = value; }
+ public String getIdentity() { return identity; }
+ public void setIdentity(String value) { this.identity = value; }
public String getGender() { return gender; }
public void setGender(String value) { this.gender = value; }
-
+ public String getReason() { return reason; }
+ public void setReason(String value) { this.reason = value; }
public String getNationality() { return nationality; }
public void setNationality(String value) { this.nationality = value; }
@@ -55,9 +71,12 @@
public String getIdNumber() { return idNumber; }
public void setIdNumber(String value) { this.idNumber = value; }
-
+ public String getResidenceNumber() { return idNumber; }
+ public void setResidenceNumber(String value) { this.idNumber = value; }
public String getDuringTime() { return duringTime; }
public void setDuringTime(String value) { this.duringTime = value; }
+ public String getDuringYear() { return duringYear; }
+ public void setDuringYear(String value) { this.duringYear = value; }
public String getSchool() { return School; }
public void setSchool(String value) { this.School = value; }
diff --git a/app/src/main/java/com/application/zhangshi_app_android/bean/GrowthExperienceRequestBean.java b/app/src/main/java/com/application/zhangshi_app_android/bean/GrowthExperienceRequestBean.java
index 6176878..7f56dba 100644
--- a/app/src/main/java/com/application/zhangshi_app_android/bean/GrowthExperienceRequestBean.java
+++ b/app/src/main/java/com/application/zhangshi_app_android/bean/GrowthExperienceRequestBean.java
@@ -11,6 +11,8 @@
private String idName;
private String usedName;
+
+ private String witness;
private String gender;
private String nationality;
private String ethnicGroup;
@@ -18,8 +20,13 @@
private String politicalStatus;
private String contactNumber;
private String idNumber;
+ private String residenceNumber;
+ private String associate;
+ private String reason;
private String address;
private String duringTime;
+ private String duringYear;
+ private String identity;
private String School;
private String passCheck;
private String abroadZone;
@@ -38,10 +45,15 @@
public void setIdName(String value) {
this.idName = value;
}
+ public String getWitness() { return witness; }
+ public void setWitness(String value) { this.witness = value; }
public String getGender() { return gender; }
public void setGender(String value) { this.gender = value; }
-
+ public String getReason() { return reason; }
+ public void setReason(String value) { this.reason = value; }
+ public String getAssociate() { return associate; }
+ public void setAssociate(String value) { this.associate = value; }
public String getNationality() { return nationality; }
public void setNationality(String value) { this.nationality = value; }
@@ -59,6 +71,10 @@
public String getIdNumber() { return idNumber; }
public void setIdNumber(String value) { this.idNumber = value; }
+ public String getResidenceNumber() { return idNumber; }
+ public void setResidenceNumber(String value) { this.idNumber = value; }
+ public String getIdentity() { return identity; }
+ public void setIdentity(String value) { this.identity = value; }
public int getPageNum() {
return pageNum;
@@ -78,6 +94,8 @@
}
public String getDuringTime() { return duringTime; }
public void setDuringTime(String value) { this.duringTime = value; }
+ public String getDuringYear() { return duringYear; }
+ public void setDuringYear(String value) { this.duringYear = value; }
public String getSchool() { return School; }
public void setSchool(String value) { this.School = value; }
public String getPassCheck() { return passCheck; }
diff --git a/app/src/main/java/com/application/zhangshi_app_android/bean/GrowthExperienceResponseBean.java b/app/src/main/java/com/application/zhangshi_app_android/bean/GrowthExperienceResponseBean.java
index 0a10a3a..600127c 100644
--- a/app/src/main/java/com/application/zhangshi_app_android/bean/GrowthExperienceResponseBean.java
+++ b/app/src/main/java/com/application/zhangshi_app_android/bean/GrowthExperienceResponseBean.java
@@ -7,5 +7,19 @@
* @desc 鑾峰彇鎴愰暱缁忓巻鐨勮繑鍥炵被
*/
public class GrowthExperienceResponseBean {
+ private List<GrowthExperienceBean> data;
+ private long pageNum;
+ private long pageSize;
+ private long total;
+ public List<GrowthExperienceBean> getData() { return data; }
+ public void setData(List<GrowthExperienceBean> value) { this.data = value; }
+ public long getPageNum() { return pageNum; }
+ public void setPageNum(long value) { this.pageNum = value; }
+
+ public long getPageSize() { return pageSize; }
+ public void setPageSize(long value) { this.pageSize = value; }
+
+ public long getTotal() { return total; }
+ public void setTotal(long value) { this.total = value; }
}
diff --git a/app/src/main/java/com/application/zhangshi_app_android/data/DataRepository.java b/app/src/main/java/com/application/zhangshi_app_android/data/DataRepository.java
index cff6cf6..0ebf908 100644
--- a/app/src/main/java/com/application/zhangshi_app_android/data/DataRepository.java
+++ b/app/src/main/java/com/application/zhangshi_app_android/data/DataRepository.java
@@ -9,6 +9,8 @@
import com.application.zhangshi_app_android.bean.FamilyMemorabiliaBean;
import com.application.zhangshi_app_android.bean.FamilyMemorabiliaRequestBean;
import com.application.zhangshi_app_android.bean.FamilyMemorabiliaResponseBean;
+import com.application.zhangshi_app_android.bean.GrowthExperienceBean;
+import com.application.zhangshi_app_android.bean.GrowthExperienceResponseBean;
import com.application.zhangshi_app_android.bean.HomeDevicesResponseBean;
import com.application.zhangshi_app_android.bean.LoginRequestBean;
import com.application.zhangshi_app_android.bean.LoginResponseBean;
@@ -136,6 +138,12 @@
public Observable<ResultData<HomeDevicesResponseBean>> getHomeDevices(Map<String, Object> paramsMap) {
return mHttpDataSource.getHomeDevices(paramsMap);
}
+ /**
+ * 鑾峰彇鎴愰暱缁忓巻
+ */
+ public Observable<ResultData<GrowthExperienceResponseBean>> getGrowthExperience(Map<String, Object> paramsMap) {
+ return mHttpDataSource.getGrowthExperience(paramsMap);
+ }
/**
* @see LocalDataSourceImpl
diff --git a/app/src/main/java/com/application/zhangshi_app_android/data/source/HttpDataSource.java b/app/src/main/java/com/application/zhangshi_app_android/data/source/HttpDataSource.java
index 734bf19..191667b 100644
--- a/app/src/main/java/com/application/zhangshi_app_android/data/source/HttpDataSource.java
+++ b/app/src/main/java/com/application/zhangshi_app_android/data/source/HttpDataSource.java
@@ -6,6 +6,7 @@
import com.application.zhangshi_app_android.bean.FamilyMemorabiliaBean;
import com.application.zhangshi_app_android.bean.FamilyMemorabiliaRequestBean;
import com.application.zhangshi_app_android.bean.FamilyMemorabiliaResponseBean;
+import com.application.zhangshi_app_android.bean.GrowthExperienceResponseBean;
import com.application.zhangshi_app_android.bean.HomeDevicesResponseBean;
import com.application.zhangshi_app_android.bean.LoginRequestBean;
import com.application.zhangshi_app_android.bean.LoginResponseBean;
@@ -71,4 +72,11 @@
* 鑾峰彇瀹跺涵璁惧
*/
Observable<ResultData<HomeDevicesResponseBean>> getHomeDevices(Map<String, Object> paramsMap);
+
+ /**
+ * 鑾峰彇鎴愰暱缁忓巻
+ */
+ Observable<ResultData<GrowthExperienceResponseBean>> getGrowthExperience(Map<String, Object> paramsMap);
}
+
+
diff --git a/app/src/main/java/com/application/zhangshi_app_android/data/source/http/ApiService.java b/app/src/main/java/com/application/zhangshi_app_android/data/source/http/ApiService.java
index d2b9d0a..d647cce 100644
--- a/app/src/main/java/com/application/zhangshi_app_android/data/source/http/ApiService.java
+++ b/app/src/main/java/com/application/zhangshi_app_android/data/source/http/ApiService.java
@@ -6,6 +6,7 @@
import com.application.zhangshi_app_android.bean.FamilyMemorabiliaBean;
import com.application.zhangshi_app_android.bean.FamilyMemorabiliaRequestBean;
import com.application.zhangshi_app_android.bean.FamilyMemorabiliaResponseBean;
+import com.application.zhangshi_app_android.bean.GrowthExperienceResponseBean;
import com.application.zhangshi_app_android.bean.HomeDevicesResponseBean;
import com.application.zhangshi_app_android.bean.LoginRequestBean;
import com.application.zhangshi_app_android.bean.LoginResponseBean;
@@ -91,4 +92,10 @@
*/
@GET("")//TODO 鑾峰彇瀹跺涵璁惧
Observable<ResultData<HomeDevicesResponseBean>> getHomeDevices(@QueryMap Map<String, Object> paramsMap);
+
+ /**
+ * 鑾峰彇鎴愰暱缁忓巻锛堜富瑕佸涔犲強宸ヤ綔缁忓巻锛�
+ */
+ @GET("/growthExperience")
+ Observable<ResultData<GrowthExperienceResponseBean>> getGrowthExperience(@QueryMap Map<String, Object> paramsMap);
}
diff --git a/app/src/main/java/com/application/zhangshi_app_android/data/source/http/HttpDataSourceImpl.java b/app/src/main/java/com/application/zhangshi_app_android/data/source/http/HttpDataSourceImpl.java
index fc81677..3b71fbb 100644
--- a/app/src/main/java/com/application/zhangshi_app_android/data/source/http/HttpDataSourceImpl.java
+++ b/app/src/main/java/com/application/zhangshi_app_android/data/source/http/HttpDataSourceImpl.java
@@ -7,6 +7,7 @@
import com.application.zhangshi_app_android.bean.FamilyMemorabiliaBean;
import com.application.zhangshi_app_android.bean.FamilyMemorabiliaRequestBean;
import com.application.zhangshi_app_android.bean.FamilyMemorabiliaResponseBean;
+import com.application.zhangshi_app_android.bean.GrowthExperienceResponseBean;
import com.application.zhangshi_app_android.bean.HomeDevicesResponseBean;
import com.application.zhangshi_app_android.bean.LoginRequestBean;
import com.application.zhangshi_app_android.bean.LoginResponseBean;
@@ -125,4 +126,12 @@
public Observable<ResultData<HomeDevicesResponseBean>> getHomeDevices(Map<String, Object> paramsMap) {
return apiService.getHomeDevices(paramsMap);
}
+
+ /**
+ * 鑾峰彇鎴愰暱缁忓巻
+ */
+ @Override
+ public Observable<ResultData<GrowthExperienceResponseBean>> getGrowthExperience(Map<String, Object> paramsMap) {
+ return apiService.getGrowthExperience(paramsMap);
+ }
}
diff --git a/app/src/main/java/com/application/zhangshi_app_android/ui/function/GrowthExperienceActivity.java b/app/src/main/java/com/application/zhangshi_app_android/ui/function/GrowthExperienceActivity.java
index 5f08ed5..1ee6cfc 100644
--- a/app/src/main/java/com/application/zhangshi_app_android/ui/function/GrowthExperienceActivity.java
+++ b/app/src/main/java/com/application/zhangshi_app_android/ui/function/GrowthExperienceActivity.java
@@ -1,9 +1,24 @@
package com.application.zhangshi_app_android.ui.function;
+import android.graphics.drawable.ColorDrawable;
+import android.view.View;
+import android.view.ViewGroup;
+import android.widget.PopupWindow;
+
+import androidx.databinding.DataBindingUtil;
+
+import com.android.app_base.utils.ScreenSizeUtils;
+import com.android.app_base.widget.LinearItemDecoration;
import com.application.zhangshi_app_android.BR;
import com.application.zhangshi_app_android.R;
+import com.application.zhangshi_app_android.adapter.FamilyAssetsRvAdapter;
+import com.application.zhangshi_app_android.adapter.GrowthExperiencePrimaryRvAdapter;
+import com.application.zhangshi_app_android.bean.GrowthExperienceBean;
import com.application.zhangshi_app_android.databinding.ActivityGrowthExperienceBinding;
import com.application.zhangshi_app_android.ui.DLBaseActivity;
+
+import java.util.ArrayList;
+import java.util.List;
/**
* @author Gss
@@ -11,6 +26,8 @@
* @desc 鎴愰暱缁忓巻 GrowthExperienceActivity
*/
public class GrowthExperienceActivity extends DLBaseActivity<ActivityGrowthExperienceBinding,GrowthExperienceActivityViewModel> {
+ private GrowthExperiencePrimaryRvAdapter adapter;
+
@Override
public int getLayoutId() {
@@ -24,24 +41,68 @@
@Override
public void initParam() {
-
+ GrowthExperienceBean bean = new GrowthExperienceBean("name", "date", "content");
+ List<GrowthExperienceBean> dataList=new ArrayList<>();
+ dataList.add(new GrowthExperienceBean("2010-2016","**灏忓","寮犱笁"));
+ dataList.add(new GrowthExperienceBean("2017-2020","**涓","鏉庡洓"));
+ adapter=new GrowthExperiencePrimaryRvAdapter(this,dataList);
}
+
+
@Override
public void initView() {
+ adapter = new GrowthExperiencePrimaryRvAdapter(this);
+ LinearItemDecoration itemDecoration = new LinearItemDecoration();
+ itemDecoration.setBottomSpace((int) getResources().getDimension(com.android.app_base.R.dimen.dp_12));
+ itemDecoration.setHorizontalSpace((int) getResources().getDimension(com.android.app_base.R.dimen.dp_20));
+ itemDecoration.setFirstTop((int) getResources().getDimension(com.android.app_base.R.dimen.dp_20));
+ binding.rvPrimary.addItemDecoration(itemDecoration);
+ binding.rvPrimary.setAdapter(adapter);
+ binding.rvRelationship.addItemDecoration(itemDecoration);
+ binding.rvRelationship.setAdapter(adapter);
+ binding.rvCertificates.addItemDecoration(itemDecoration);
+ binding.rvCertificates.setAdapter(adapter);
+ binding.rvAbroad.addItemDecoration(itemDecoration);
+ binding.rvAbroad.setAdapter(adapter);
}
@Override
public void initData() {
-
+ viewModel.getGrowthExperience();
}
@Override
public void initLiveDataObserve() {
+ ActivityGrowthExperienceBinding binding1= DataBindingUtil.setContentView(this,R.layout.activity_growth_experience);
+ ActivityGrowthExperienceBinding binding2= DataBindingUtil.setContentView(this,R.layout.activity_growth_experience);
+ ActivityGrowthExperienceBinding binding3= DataBindingUtil.setContentView(this,R.layout.activity_growth_experience);
+ ActivityGrowthExperienceBinding binding4= DataBindingUtil.setContentView(this,R.layout.activity_growth_experience);
+ viewModel.getDataListLiveData().observe(this, GrowthExperienceBeans -> {
+ adapter.setData(GrowthExperienceBeans);
+ });
}
-
+ private PopupWindow initPopUpWindow(View view){
+ PopupWindow popupWindow = new PopupWindow(this);
+ // 璁剧疆甯冨眬鏂囦欢
+ popupWindow.setContentView(view);
+ // 涓轰簡閬垮厤閮ㄥ垎鏈哄瀷涓嶆樉绀猴紝闇�瑕侀噸鏂拌缃竴涓嬪楂�
+ popupWindow.setWidth(ViewGroup.LayoutParams.WRAP_CONTENT);
+ popupWindow.setHeight(ViewGroup.LayoutParams.WRAP_CONTENT);
+ // 璁剧疆pop閫忔槑鏁堟灉
+ popupWindow.setBackgroundDrawable(new ColorDrawable(0x0000));
+ // 璁剧疆pop鍑哄叆鍔ㄧ敾
+ popupWindow.setAnimationStyle(com.android.app_base.R.style.pop_add);
+ // 璁剧疆pop鑾峰彇鐒︾偣锛屽鏋滀负false鐐瑰嚮杩斿洖鎸夐挳浼氶��鍑哄綋鍓岮ctivity锛屽鏋減op涓湁Editor鐨勮瘽锛宖ocusable蹇呴』瑕佷负true
+ popupWindow.setFocusable(true);
+ // 璁剧疆pop鍙偣鍑伙紝涓篺alse鐐瑰嚮浜嬩欢鏃犳晥锛岄粯璁や负true
+ popupWindow.setTouchable(true);
+ // 璁剧疆鐐瑰嚮pop澶栦晶娑堝け锛岄粯璁や负false锛涘湪focusable涓簍rue鏃剁偣鍑诲渚у缁堟秷澶�
+ popupWindow.setOutsideTouchable(false);
+ return popupWindow;
+ }
}
diff --git a/app/src/main/java/com/application/zhangshi_app_android/ui/function/GrowthExperienceActivityViewModel.java b/app/src/main/java/com/application/zhangshi_app_android/ui/function/GrowthExperienceActivityViewModel.java
index 1ad74bc..0fcbc9f 100644
--- a/app/src/main/java/com/application/zhangshi_app_android/ui/function/GrowthExperienceActivityViewModel.java
+++ b/app/src/main/java/com/application/zhangshi_app_android/ui/function/GrowthExperienceActivityViewModel.java
@@ -8,16 +8,26 @@
import androidx.lifecycle.MutableLiveData;
import androidx.lifecycle.ViewModelProvider;
+import com.android.app_base.base.StateViewEnum;
import com.android.app_base.http.ResultData;
import com.android.app_base.manager.AppManager;
import com.android.app_base.utils.RxUtils;
import com.android.app_base.utils.ToastUtils;
import com.android.app_base.base.viewmodel.BaseViewModel;
import com.application.zhangshi_app_android.R;
+import com.application.zhangshi_app_android.bean.FamilyAssetsBean;
+import com.application.zhangshi_app_android.bean.FamilyAssetsResponseBean;
import com.application.zhangshi_app_android.bean.FamilyMemorabiliaBean;
import com.application.zhangshi_app_android.bean.GrowthExperienceBean;
+import com.application.zhangshi_app_android.bean.GrowthExperienceResponseBean;
+import com.application.zhangshi_app_android.bean.HomeDevicesBean;
import com.application.zhangshi_app_android.data.DataRepository;
+import java.text.ParseException;
+import java.text.SimpleDateFormat;
+import java.util.Comparator;
+import java.util.Date;
+import java.util.HashMap;
import java.util.List;
import io.reactivex.Observer;
@@ -28,6 +38,7 @@
* @desc 鎴愰暱缁忓巻 viewModel
*/
public class GrowthExperienceActivityViewModel extends BaseViewModel<DataRepository> {
+ private MutableLiveData<List<GrowthExperienceBean>> dataListLiveData;//鏁版嵁
public GrowthExperienceActivityViewModel(@NonNull Application application) {
super(application);
@@ -36,5 +47,82 @@
protected DataRepository initModel() {
return DataRepository.getInstance();
}
+ public void getGrowthExperience(){
+ model.getGrowthExperience(new HashMap<>())
+ .compose(RxUtils.schedulersTransformer())
+ .subscribe(new Observer<ResultData<GrowthExperienceResponseBean>>() {
+ @Override
+ public void onSubscribe(Disposable d) {
+ addSubscribe(d);
+ }
+ @Override
+ public void onNext(ResultData<GrowthExperienceResponseBean> data) {
+ if (data.getCode() == CODE_SUCCESS){
+ if (data.getData().getData().isEmpty()){
+ changeStateView(StateViewEnum.DATA_NULL);
+ }else {
+ changeStateView(StateViewEnum.HIDE);
+ dataListLiveData.postValue(data.getData().getData());
+ }
+ }else {
+ messageLiveData.postValue(data.getMsg());
+ }
+ }
+
+
+ @Override
+ public void onError(Throwable e) {
+ messageLiveData.postValue(e.getMessage());
+ }
+
+ @Override
+ public void onComplete() {
+
+ }
+ });
+ }
+
+
+ public MutableLiveData<List<GrowthExperienceBean>> getDataListLiveData() {
+ if (dataListLiveData == null){
+ dataListLiveData = new MutableLiveData<>();
+ }
+ return dataListLiveData;
+ }
+
+ public void setDataListLiveData(MutableLiveData<List<GrowthExperienceBean>> dataListLiveData) {
+ this.dataListLiveData = dataListLiveData;
+ }
+
+ public void sortDataList(int type){
+ List<GrowthExperienceBean> list = dataListLiveData.getValue();
+ if (list == null || list.isEmpty()){
+ return;
+ }
+
+ list.sort(new Comparator<GrowthExperienceBean>() {
+ @Override
+ public int compare(GrowthExperienceBean o1, GrowthExperienceBean o2) {
+ SimpleDateFormat format = new SimpleDateFormat("yyyy-yyyy", java.util.Locale.getDefault());
+ Date date1 = null;
+ Date date2 = null;
+ try {
+ date1 = format.parse(o1.getDuringYear());
+ date2 = format.parse(o2.getDuringYear());
+ } catch (ParseException e) {
+ throw new RuntimeException(e);
+ }
+ if (date1 != null && date2 != null) {
+ if (type == 0){
+ return date2.compareTo(date1);
+ }else {
+ return date1.compareTo(date2);
+ }
+ }
+ return 0;
+ }
+ });
+ dataListLiveData.postValue(list);
+ }
}
diff --git a/app/src/main/res/layout/activity_growth_experience.xml b/app/src/main/res/layout/activity_growth_experience.xml
index df8eb8f..9a7157f 100644
--- a/app/src/main/res/layout/activity_growth_experience.xml
+++ b/app/src/main/res/layout/activity_growth_experience.xml
@@ -172,7 +172,7 @@
<TextView
android:layout_width="wrap_content"
android:layout_height="@dimen/dp_20"
- android:text="鍚嶆棌"
+ android:text="姘戞棌"
android:textColor="#88000000"
android:textSize="@dimen/sp_12" />
@@ -418,7 +418,7 @@
</LinearLayout>
<androidx.recyclerview.widget.RecyclerView
- android:id="@+id/recyclerView"
+ android:id="@+id/rv_primary"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/color_normal_background"
@@ -465,7 +465,7 @@
android:background="@color/color_normal_background"
android:layout_marginTop="16dp"
tools:itemCount="3"
- tools:listitem="@layout/item_growth_experience_primary" />
+ tools:listitem="@layout/item_growth_experience_relationship" />
</LinearLayout>
@@ -571,7 +571,7 @@
android:background="@color/color_normal_background"
android:layout_marginTop="16dp"
tools:itemCount="3"
- tools:listitem="@layout/item_growth_experience_primary" />
+ tools:listitem="@layout/item_growth_experience_holder_condition" />
</LinearLayout>
@@ -615,7 +615,7 @@
android:layout_marginTop="16dp"
app:layout_constraintTop_toBottomOf="@+id/layout_11"
tools:itemCount="3"
- tools:listitem="@layout/item_growth_experience_primary" />
+ tools:listitem="@layout/item_growth_experience_abroad_condition" />
</LinearLayout>
<TextView
diff --git a/app/src/main/res/layout/item_growth_experiece_abroad_condition.xml b/app/src/main/res/layout/item_growth_experience_abroad_condition.xml
similarity index 88%
rename from app/src/main/res/layout/item_growth_experiece_abroad_condition.xml
rename to app/src/main/res/layout/item_growth_experience_abroad_condition.xml
index 5866693..1287bd9 100644
--- a/app/src/main/res/layout/item_growth_experiece_abroad_condition.xml
+++ b/app/src/main/res/layout/item_growth_experience_abroad_condition.xml
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<layout xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:app="http://schemas.android.com/apk/res-auto">
+ xmlns:app="http://schemas.android.com/apk/res-auto"
+ xmlns:tools="http://schemas.android.com/tools">
<data>
<variable
@@ -39,7 +40,9 @@
android:layout_marginStart="24dp"
android:textSize="@dimen/sp_16"
android:textColor="@color/black"
+ android:text="@{bean.abroadZone}"
android:layout_weight="1"
+ tools:text="棣欐腐"
android:textStyle="bold"
/>
<TextView
@@ -47,13 +50,16 @@
android:layout_height="wrap_content"
android:textSize="@dimen/sp_16"
android:textColor="@color/black"
+ android:text="@{bean.duringTime}"
android:textStyle="bold"
android:layout_marginEnd="24dp"
android:layout_alignParentEnd="true"
android:layout_centerVertical="true"
+ tools:text="2010.01-2020.01"
/>
</RelativeLayout>
<LinearLayout
+ android:id="@+id/layout_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
@@ -76,7 +82,8 @@
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:text="鎺翰"
+ tools:text="鎺翰"
+ android:text="@{bean.reason}"
android:textColor="@color/black"
android:textSize="@dimen/sp_12"
android:textStyle="bold"
diff --git a/app/src/main/res/layout/item_growth_experience_holder_condition.xml b/app/src/main/res/layout/item_growth_experience_holder_condition.xml
index 8af7f84..8689a4f 100644
--- a/app/src/main/res/layout/item_growth_experience_holder_condition.xml
+++ b/app/src/main/res/layout/item_growth_experience_holder_condition.xml
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<layout xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:app="http://schemas.android.com/apk/res-auto">
+ xmlns:app="http://schemas.android.com/apk/res-auto"
+ xmlns:tools="http://schemas.android.com/tools">
<data>
<variable
@@ -38,7 +39,9 @@
android:layout_marginStart="24dp"
android:textSize="@dimen/sp_16"
android:textColor="@color/black"
+ android:text="@{bean.passCheck}"
android:layout_weight="1"
+ tools:text="鎶ょ収"
android:textStyle="bold"
/>
<TextView
@@ -46,13 +49,16 @@
android:layout_height="wrap_content"
android:textSize="@dimen/sp_16"
android:textColor="@color/black"
+ android:text="@{bean.duringTime}"
android:textStyle="bold"
android:layout_marginEnd="24dp"
android:layout_alignParentEnd="true"
android:layout_centerVertical="true"
+ tools:text="2010.01-2020.01"
/>
</RelativeLayout>
<LinearLayout
+ android:id="@+id/layout_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
@@ -99,8 +105,10 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="@color/black"
+ android:text="@{bean.residenceNumber}"
android:textSize="@dimen/sp_12"
android:textStyle="bold"
+ tools:text="123456789012345"
/>
</LinearLayout>
diff --git a/app/src/main/res/layout/item_growth_experience_primary.xml b/app/src/main/res/layout/item_growth_experience_primary.xml
index 85ec1c7..151d2ed 100644
--- a/app/src/main/res/layout/item_growth_experience_primary.xml
+++ b/app/src/main/res/layout/item_growth_experience_primary.xml
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<layout xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:app="http://schemas.android.com/apk/res-auto">
+ xmlns:app="http://schemas.android.com/apk/res-auto"
+ xmlns:tools="http://schemas.android.com/tools">
<data>
<variable
@@ -38,7 +39,9 @@
android:layout_marginStart="24dp"
android:textSize="@dimen/sp_16"
android:textColor="@color/black"
+ android:text="@{bean.duringYear}"
android:layout_weight="1"
+ tools:text="2010-2016"
android:textStyle="bold"
/>
<TextView
@@ -46,13 +49,16 @@
android:layout_height="wrap_content"
android:textSize="@dimen/sp_16"
android:textColor="@color/black"
+ android:text="@{bean.School}"
android:textStyle="bold"
android:layout_marginEnd="24dp"
android:layout_alignParentEnd="true"
android:layout_centerVertical="true"
+ tools:text="**灏忓"
/>
</RelativeLayout>
<LinearLayout
+ android:id="@+id/layout_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
@@ -75,6 +81,7 @@
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
+ android:text="@{bean.witness}"
android:textColor="@color/black"
android:textSize="@dimen/sp_12"
android:textStyle="bold"
diff --git a/app/src/main/res/layout/item_growth_experience_relationship.xml b/app/src/main/res/layout/item_growth_experience_relationship.xml
index a90a5c3..1cfdf1b 100644
--- a/app/src/main/res/layout/item_growth_experience_relationship.xml
+++ b/app/src/main/res/layout/item_growth_experience_relationship.xml
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<layout xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:app="http://schemas.android.com/apk/res-auto">
+ xmlns:app="http://schemas.android.com/apk/res-auto"
+ xmlns:tools="http://schemas.android.com/tools">
<data>
<variable
@@ -38,7 +39,9 @@
android:layout_marginStart="24dp"
android:textSize="@dimen/sp_16"
android:textColor="@color/black"
+ android:text="@{bean.relationship}"
android:layout_weight="1"
+ tools:text="澶"
android:textStyle="bold"
/>
<TextView
@@ -46,13 +49,16 @@
android:layout_height="wrap_content"
android:textSize="@dimen/sp_16"
android:textColor="@color/black"
+ android:text="@{bean.associate}"
android:textStyle="bold"
android:layout_marginEnd="24dp"
android:layout_alignParentEnd="true"
android:layout_centerVertical="true"
+ tools:text="寮犱笁"
/>
</RelativeLayout>
<LinearLayout
+ android:id="@+id/layout_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
@@ -75,7 +81,7 @@
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:text="寮犳皬鍏徃"
+ android:text="@{bean.School}"
android:textColor="@color/black"
android:textSize="@dimen/sp_12"
android:textStyle="bold"
@@ -98,7 +104,7 @@
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:text="缁忕悊"
+ android:text="@{bean.identity}"
android:textColor="@color/black"
android:textSize="@dimen/sp_12"
android:textStyle="bold"
@@ -122,6 +128,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="@color/black"
+ android:text="@{bean.politicalStatus}"
android:textSize="@dimen/sp_12"
android:textStyle="bold"
/>
--
Gitblit v1.9.1