人口基础信息修改
This commit is contained in:
parent
819aea5751
commit
64eddab2a7
@ -10,8 +10,8 @@
|
|||||||
{
|
{
|
||||||
"type": "SINGLE",
|
"type": "SINGLE",
|
||||||
"filters": [],
|
"filters": [],
|
||||||
"versionCode": 12,
|
"versionCode": 13,
|
||||||
"versionName": "1.1.1",
|
"versionName": "1.1.2",
|
||||||
"outputFile": "app-release.apk"
|
"outputFile": "app-release.apk"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
@ -1,5 +1,7 @@
|
|||||||
package com.tenlionsoft.baselib.core.beans;
|
package com.tenlionsoft.baselib.core.beans;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 作者: adam
|
* 作者: adam
|
||||||
* 日期: 2021/7/12 - 4:17 下午
|
* 日期: 2021/7/12 - 4:17 下午
|
||||||
@ -23,6 +25,7 @@ public class PersonSearchBean {
|
|||||||
private String genderDictionaryName;
|
private String genderDictionaryName;
|
||||||
private String gridId;
|
private String gridId;
|
||||||
private String gridName;
|
private String gridName;
|
||||||
|
private List<GridPersonListBean> gridPersonList;
|
||||||
private String idCardNumber;
|
private String idCardNumber;
|
||||||
private String maritalStatus;
|
private String maritalStatus;
|
||||||
private String maritalStatusDictionaryName;
|
private String maritalStatusDictionaryName;
|
||||||
@ -43,17 +46,10 @@ public class PersonSearchBean {
|
|||||||
private String religion;
|
private String religion;
|
||||||
private String religionDictionaryName;
|
private String religionDictionaryName;
|
||||||
private String serviceSpace;
|
private String serviceSpace;
|
||||||
|
private String subtype;
|
||||||
private String telephone;
|
private String telephone;
|
||||||
private String type;
|
private String type;
|
||||||
|
|
||||||
public String getType() {
|
|
||||||
return type;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setType(String type) {
|
|
||||||
this.type = type;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getAreaCode() {
|
public String getAreaCode() {
|
||||||
return areaCode;
|
return areaCode;
|
||||||
}
|
}
|
||||||
@ -174,6 +170,14 @@ public class PersonSearchBean {
|
|||||||
this.gridName = gridName;
|
this.gridName = gridName;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public List<GridPersonListBean> getGridPersonList() {
|
||||||
|
return gridPersonList;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setGridPersonList(List<GridPersonListBean> gridPersonList) {
|
||||||
|
this.gridPersonList = gridPersonList;
|
||||||
|
}
|
||||||
|
|
||||||
public String getIdCardNumber() {
|
public String getIdCardNumber() {
|
||||||
return idCardNumber;
|
return idCardNumber;
|
||||||
}
|
}
|
||||||
@ -334,6 +338,14 @@ public class PersonSearchBean {
|
|||||||
this.serviceSpace = serviceSpace;
|
this.serviceSpace = serviceSpace;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public String getSubtype() {
|
||||||
|
return subtype;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSubtype(String subtype) {
|
||||||
|
this.subtype = subtype;
|
||||||
|
}
|
||||||
|
|
||||||
public String getTelephone() {
|
public String getTelephone() {
|
||||||
return telephone;
|
return telephone;
|
||||||
}
|
}
|
||||||
@ -341,4 +353,42 @@ public class PersonSearchBean {
|
|||||||
public void setTelephone(String telephone) {
|
public void setTelephone(String telephone) {
|
||||||
this.telephone = telephone;
|
this.telephone = telephone;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public String getType() {
|
||||||
|
return type;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setType(String type) {
|
||||||
|
this.type = type;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class GridPersonListBean {
|
||||||
|
private String gridUserId;
|
||||||
|
private String gridUserName;
|
||||||
|
private String gridUserPhone;
|
||||||
|
|
||||||
|
public String getGridUserId() {
|
||||||
|
return gridUserId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setGridUserId(String gridUserId) {
|
||||||
|
this.gridUserId = gridUserId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getGridUserName() {
|
||||||
|
return gridUserName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setGridUserName(String gridUserName) {
|
||||||
|
this.gridUserName = gridUserName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getGridUserPhone() {
|
||||||
|
return gridUserPhone;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setGridUserPhone(String gridUserPhone) {
|
||||||
|
this.gridUserPhone = gridUserPhone;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -28,6 +28,7 @@ public class BaseUrlApi {
|
|||||||
public static final String BASE_LIBRARY_IP = IP + SYS_LIBRARY;
|
public static final String BASE_LIBRARY_IP = IP + SYS_LIBRARY;
|
||||||
public static final String BASE_TASK_IP = IP + SYS_TASK;
|
public static final String BASE_TASK_IP = IP + SYS_TASK;
|
||||||
public static final String BASE_PERSON_IP = IP + SYS_POPULATION;
|
public static final String BASE_PERSON_IP = IP + SYS_POPULATION;
|
||||||
|
// public static final String BASE_PERSON_IP = "http://192.168.0.115:8080/" + SYS_POPULATION;//TODO 测试
|
||||||
public static final String BASE_HOUSE_IP = IP + SYS_HOUSE;
|
public static final String BASE_HOUSE_IP = IP + SYS_HOUSE;
|
||||||
public static final String BASE_SECURITY_IP = IP + SYS_SECURITY;
|
public static final String BASE_SECURITY_IP = IP + SYS_SECURITY;
|
||||||
public static final String BASE_VISITS_IP = IP + SYS_VISITS;
|
public static final String BASE_VISITS_IP = IP + SYS_VISITS;
|
||||||
|
@ -23,12 +23,14 @@ import android.text.TextUtils;
|
|||||||
import android.text.TextWatcher;
|
import android.text.TextWatcher;
|
||||||
import android.util.DisplayMetrics;
|
import android.util.DisplayMetrics;
|
||||||
import android.view.Display;
|
import android.view.Display;
|
||||||
|
import android.view.KeyEvent;
|
||||||
import android.view.LayoutInflater;
|
import android.view.LayoutInflater;
|
||||||
import android.view.MotionEvent;
|
import android.view.MotionEvent;
|
||||||
import android.view.TouchDelegate;
|
import android.view.TouchDelegate;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
import android.view.WindowManager;
|
import android.view.WindowManager;
|
||||||
import android.view.animation.LinearInterpolator;
|
import android.view.animation.LinearInterpolator;
|
||||||
|
import android.view.inputmethod.EditorInfo;
|
||||||
import android.view.inputmethod.InputMethodManager;
|
import android.view.inputmethod.InputMethodManager;
|
||||||
import android.webkit.WebView;
|
import android.webkit.WebView;
|
||||||
import android.widget.Button;
|
import android.widget.Button;
|
||||||
@ -293,6 +295,19 @@ public abstract class BaseActivity extends AppCompatActivity {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
mEtAppSearchContent.setOnEditorActionListener(new TextView.OnEditorActionListener() {
|
||||||
|
@Override
|
||||||
|
public boolean onEditorAction(TextView v, int actionId, KeyEvent event) {
|
||||||
|
if (actionId == EditorInfo.IME_ACTION_SEARCH) {
|
||||||
|
hideSoftKeyboard();
|
||||||
|
mEtAppSearchContent.clearFocus();
|
||||||
|
doSearchByTitle();
|
||||||
|
return true;
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
mIvClearSearch.setOnClickListener(v -> clearSearchContent());
|
mIvClearSearch.setOnClickListener(v -> clearSearchContent());
|
||||||
//设置默认title
|
//设置默认title
|
||||||
mIvAppSearchIcon.setVisibility(View.GONE);
|
mIvAppSearchIcon.setVisibility(View.GONE);
|
||||||
|
@ -0,0 +1,202 @@
|
|||||||
|
package com.tenlionsoft.baselib.core.widget.views;
|
||||||
|
|
||||||
|
import android.app.Activity;
|
||||||
|
import android.app.Dialog;
|
||||||
|
import android.content.Context;
|
||||||
|
import android.content.Intent;
|
||||||
|
import android.graphics.drawable.ColorDrawable;
|
||||||
|
import android.net.Uri;
|
||||||
|
import android.os.Bundle;
|
||||||
|
import android.text.TextUtils;
|
||||||
|
import android.util.DisplayMetrics;
|
||||||
|
import android.view.Gravity;
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.Window;
|
||||||
|
import android.view.WindowManager;
|
||||||
|
import android.view.inputmethod.InputMethodManager;
|
||||||
|
import android.widget.EditText;
|
||||||
|
|
||||||
|
import androidx.recyclerview.widget.LinearLayoutManager;
|
||||||
|
import androidx.recyclerview.widget.RecyclerView;
|
||||||
|
|
||||||
|
import com.bigkoo.pickerview.view.TimePickerView;
|
||||||
|
import com.hjq.toast.ToastUtils;
|
||||||
|
import com.tenlionsoft.baselib.R;
|
||||||
|
import com.tenlionsoft.baselib.core.beans.PersonSearchBean;
|
||||||
|
import com.tenlionsoft.baselib.core.widget.base.BaseRecyclerAdapter;
|
||||||
|
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 作者 : Adam on 2018/7/23.
|
||||||
|
* 邮箱 : itgaojian@163.com
|
||||||
|
* 描述 : 时间加输入
|
||||||
|
*/
|
||||||
|
public class CenterGridPhoneListView extends Dialog {
|
||||||
|
|
||||||
|
private boolean iscancelable;
|
||||||
|
private boolean isBackCancelable;
|
||||||
|
private View view;
|
||||||
|
private Context context;
|
||||||
|
private int gravity;
|
||||||
|
private OnChoseListener mListener;
|
||||||
|
private boolean mIsShow;
|
||||||
|
private boolean mIsShowOther;
|
||||||
|
private TimePickerView mTimePicker;
|
||||||
|
private EditText mEtContent;
|
||||||
|
private SimpleDateFormat mDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
||||||
|
private List<PersonSearchBean.GridPersonListBean> mGridList = new ArrayList<>();
|
||||||
|
|
||||||
|
private CenterGridPhoneListView(Context context, boolean isCancelable, boolean isBackCancelable, int gravity,
|
||||||
|
boolean isShow, boolean isShowOther, List gridList) {
|
||||||
|
super(context, R.style.dialog_center_alpha);
|
||||||
|
this.context = context;
|
||||||
|
this.gravity = gravity;
|
||||||
|
this.iscancelable = isCancelable;
|
||||||
|
this.isBackCancelable = isBackCancelable;
|
||||||
|
this.mIsShow = isShow;
|
||||||
|
this.mIsShowOther = isShowOther;
|
||||||
|
this.mGridList = gridList;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onCreate(Bundle savedInstanceState) {
|
||||||
|
super.onCreate(savedInstanceState);
|
||||||
|
view = LayoutInflater.from(context).inflate(R.layout.dialog_base_grid_list, null);
|
||||||
|
setContentView(view);
|
||||||
|
setCancelable(true);
|
||||||
|
setCanceledOnTouchOutside(true);
|
||||||
|
RecyclerView mRlvGrid = view.findViewById(R.id.rlv_grids);
|
||||||
|
GridTextAdapter adapter = new GridTextAdapter(context, mGridList);
|
||||||
|
mRlvGrid.setLayoutManager(new LinearLayoutManager(context));
|
||||||
|
mRlvGrid.setAdapter(adapter);
|
||||||
|
adapter.addOnItemClickListener(gridPersonListBean -> {
|
||||||
|
if (!TextUtils.isEmpty(gridPersonListBean.getGridUserPhone())) {
|
||||||
|
this.dismiss();
|
||||||
|
doCall(gridPersonListBean.getGridUserPhone());
|
||||||
|
}
|
||||||
|
});
|
||||||
|
DisplayMetrics displayMetrics = context.getResources().getDisplayMetrics();
|
||||||
|
Window window = this.getWindow();
|
||||||
|
window.setGravity(Gravity.CENTER);
|
||||||
|
window.setWindowAnimations(R.style.dialog_center_alpha);
|
||||||
|
WindowManager.LayoutParams params = window.getAttributes();
|
||||||
|
params.width = (int) (displayMetrics.widthPixels * 0.9);
|
||||||
|
params.height = WindowManager.LayoutParams.WRAP_CONTENT;
|
||||||
|
window.setAttributes(params);
|
||||||
|
window.setBackgroundDrawable(new ColorDrawable());
|
||||||
|
}
|
||||||
|
|
||||||
|
public void HideSoftKeyBoardDialog(Activity activity) {
|
||||||
|
try {
|
||||||
|
InputMethodManager imm = (InputMethodManager) activity.getSystemService(activity.INPUT_METHOD_SERVICE);
|
||||||
|
imm.hideSoftInputFromWindow(mEtContent.getWindowToken(), 0);
|
||||||
|
} catch (Exception ex) {
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void doCall(String gridUserPhone) {
|
||||||
|
if (!TextUtils.isEmpty(gridUserPhone)) {
|
||||||
|
Intent intent = new Intent(Intent.ACTION_DIAL);
|
||||||
|
Uri data = Uri.parse("tel:" + gridUserPhone);
|
||||||
|
intent.setData(data);
|
||||||
|
context.startActivity(intent);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void doConfirm() {
|
||||||
|
if (checkParams()) {
|
||||||
|
String time = "";
|
||||||
|
String content = mEtContent.getText().toString().trim();
|
||||||
|
mListener.doConfirm(time, content);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 校验参数
|
||||||
|
*/
|
||||||
|
private boolean checkParams() {
|
||||||
|
String content = mEtContent.getText().toString().trim();
|
||||||
|
if (TextUtils.isEmpty(content)) {
|
||||||
|
ToastUtils.show("请输入原由");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public void addOnChoseListener(OnChoseListener listener) {
|
||||||
|
this.mListener = listener;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 选择
|
||||||
|
*
|
||||||
|
* @param i
|
||||||
|
*/
|
||||||
|
private void choseType(int i) {
|
||||||
|
this.dismiss();
|
||||||
|
}
|
||||||
|
|
||||||
|
public interface OnChoseListener {
|
||||||
|
void doConfirm(String list, String ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class DialogBuilder {
|
||||||
|
private Context mContext;
|
||||||
|
private boolean isCancelable;
|
||||||
|
private boolean mIsBackable;
|
||||||
|
private int mGravity = Gravity.BOTTOM;
|
||||||
|
private OnChoseListener mListener;
|
||||||
|
private boolean mIsShowOther;
|
||||||
|
|
||||||
|
public DialogBuilder(Context context) {
|
||||||
|
this.mContext = context;
|
||||||
|
}
|
||||||
|
|
||||||
|
public DialogBuilder setIscancelable(boolean iscancelable) {
|
||||||
|
this.isCancelable = iscancelable;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public DialogBuilder setIsBackCancelable(boolean isBackCancelable) {
|
||||||
|
this.mIsBackable = isBackCancelable;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public DialogBuilder setShowLocation(int gravity) {
|
||||||
|
this.mGravity = gravity;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
private boolean mIsShow;
|
||||||
|
|
||||||
|
public DialogBuilder setIsShowFile(boolean isShowFile) {
|
||||||
|
mIsShow = isShowFile;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public DialogBuilder setIsShowOther(boolean isShow) {
|
||||||
|
mIsShowOther = isShow;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
private List<PersonSearchBean.GridPersonListBean> mList;
|
||||||
|
|
||||||
|
public DialogBuilder setList(List<PersonSearchBean.GridPersonListBean> list) {
|
||||||
|
this.mList = list;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public CenterGridPhoneListView build() {
|
||||||
|
return new CenterGridPhoneListView(this.mContext, this.isCancelable, this.mIsBackable, this.mGravity,
|
||||||
|
mIsShow, mIsShowOther, mList);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,31 @@
|
|||||||
|
package com.tenlionsoft.baselib.core.widget.views;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.text.TextUtils;
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
|
||||||
|
import com.tenlionsoft.baselib.R;
|
||||||
|
import com.tenlionsoft.baselib.core.beans.PersonSearchBean;
|
||||||
|
import com.tenlionsoft.baselib.core.widget.base.BaseRecyclerAdapter;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public class GridTextAdapter extends BaseRecyclerAdapter<PersonSearchBean.GridPersonListBean, GridTextViewHolder> {
|
||||||
|
public GridTextAdapter(Context ctx, List<PersonSearchBean.GridPersonListBean> list) {
|
||||||
|
super(ctx, list);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public GridTextViewHolder createHolder(ViewGroup parent, int viewType) {
|
||||||
|
View itemView = LayoutInflater.from(mContext).inflate(R.layout.item_grid_phone, parent, false);
|
||||||
|
return new GridTextViewHolder(itemView);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void bindHolder(GridTextViewHolder gridTextViewHolder, int i) {
|
||||||
|
gridTextViewHolder.mTvName.setText(mData.get(i).getGridUserName());
|
||||||
|
gridTextViewHolder.mTvPhone.setText(TextUtils.isEmpty(mData.get(i).getGridUserPhone())?"未录入":mData.get(i).getGridUserPhone());
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,22 @@
|
|||||||
|
package com.tenlionsoft.baselib.core.widget.views;
|
||||||
|
|
||||||
|
import android.view.View;
|
||||||
|
import android.widget.LinearLayout;
|
||||||
|
import android.widget.TextView;
|
||||||
|
|
||||||
|
import androidx.annotation.NonNull;
|
||||||
|
import androidx.recyclerview.widget.RecyclerView;
|
||||||
|
|
||||||
|
import com.tenlionsoft.baselib.R;
|
||||||
|
|
||||||
|
public class GridTextViewHolder extends RecyclerView.ViewHolder {
|
||||||
|
public TextView mTvName;
|
||||||
|
public TextView mTvPhone;
|
||||||
|
public LinearLayout mLlGrid;
|
||||||
|
public GridTextViewHolder(@NonNull View itemView) {
|
||||||
|
super(itemView);
|
||||||
|
mTvName=itemView.findViewById(R.id.tv_name);
|
||||||
|
mTvPhone= itemView.findViewById(R.id.tv_phone);
|
||||||
|
mLlGrid=itemView.findViewById(R.id.ll_grid);
|
||||||
|
}
|
||||||
|
}
|
26
baselib/src/main/res/layout/dialog_base_grid_list.xml
Executable file
26
baselib/src/main/res/layout/dialog_base_grid_list.xml
Executable file
@ -0,0 +1,26 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_margin="20dp"
|
||||||
|
android:background="@drawable/shp_rectangle_white"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:padding="8dp"
|
||||||
|
android:text="网格员"
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="18sp" />
|
||||||
|
|
||||||
|
|
||||||
|
<LinearLayout style="@style/item_gray_vertical">
|
||||||
|
|
||||||
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
|
android:id="@+id/rlv_grids"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
36
baselib/src/main/res/layout/item_grid_phone.xml
Normal file
36
baselib/src/main/res/layout/item_grid_phone.xml
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:id="@+id/ll_grid"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:paddingLeft="10dp"
|
||||||
|
android:paddingTop="3dp"
|
||||||
|
android:paddingRight="10dp"
|
||||||
|
android:paddingBottom="3dp">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_name"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="@dimen/text_14"
|
||||||
|
tools:text="姓名" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_phone"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:text="未录入"
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="@dimen/text_14" />
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="15dp"
|
||||||
|
android:layout_height="15dp"
|
||||||
|
android:src="@drawable/ic_call_answer" />
|
||||||
|
</LinearLayout>
|
@ -146,7 +146,7 @@
|
|||||||
<TextView
|
<TextView
|
||||||
style="@style/item_title_23"
|
style="@style/item_title_23"
|
||||||
android:layout_gravity="center_vertical"
|
android:layout_gravity="center_vertical"
|
||||||
android:text="名族" />
|
android:text="民族" />
|
||||||
|
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
|
@ -45,6 +45,9 @@ allprojects {
|
|||||||
maven {
|
maven {
|
||||||
url "https://jitpack.io"
|
url "https://jitpack.io"
|
||||||
}
|
}
|
||||||
|
maven{
|
||||||
|
url "https://repo1.maven.org/maven2"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -55,8 +58,8 @@ ext {
|
|||||||
gCompileSdkVersion = 30
|
gCompileSdkVersion = 30
|
||||||
gMinSdkVersion = 21
|
gMinSdkVersion = 21
|
||||||
gTargetSdkVersion = 30
|
gTargetSdkVersion = 30
|
||||||
gVersionCode = 12
|
gVersionCode = 13
|
||||||
gVersionName = '1.1.1'
|
gVersionName = '1.1.2'
|
||||||
gBuildToolsVersion = "29.0.2"
|
gBuildToolsVersion = "29.0.2"
|
||||||
// gVersionCode=26
|
// gVersionCode=26
|
||||||
// gVersionName='1.3.0'
|
// gVersionName='1.3.0'
|
||||||
|
@ -0,0 +1,56 @@
|
|||||||
|
package com.tengshisoft.commonmodule.adapters;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.graphics.Color;
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
|
||||||
|
import com.tengshisoft.commonmodule.beans.AreaGridListBean;
|
||||||
|
import com.tenlionsoft.baselib.R;
|
||||||
|
import com.tenlionsoft.baselib.core.widget.base.BaseRecyclerAdapter;
|
||||||
|
import com.tenlionsoft.baselib.core.widget.base.ConditionHolder;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 作者: adam
|
||||||
|
* 日期: 2021/10/20 - 11:18 上午
|
||||||
|
* 邮箱: itgaojian@163.com
|
||||||
|
* 描述:网格筛选
|
||||||
|
*/
|
||||||
|
public class ConditionAreaGridAdapter extends BaseRecyclerAdapter<AreaGridListBean.RowsBean, ConditionHolder> {
|
||||||
|
public List<AreaGridListBean.RowsBean> mSelBeans = new ArrayList<>();
|
||||||
|
|
||||||
|
public ConditionAreaGridAdapter(Context ctx, List<AreaGridListBean.RowsBean> list) {
|
||||||
|
super(ctx, list);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ConditionHolder createHolder(ViewGroup parent, int viewType) {
|
||||||
|
View view = LayoutInflater.from(mContext).inflate(R.layout.item_condition_sel, parent, false);
|
||||||
|
return new ConditionHolder(view);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void bindHolder(ConditionHolder holder, int i) {
|
||||||
|
AreaGridListBean.RowsBean bean = mData.get(i);
|
||||||
|
holder.mTvName.setText(bean.getGridName());
|
||||||
|
holder.mCbCheck.setOnCheckedChangeListener(null);
|
||||||
|
holder.mTvName.setTextColor(bean.isCheck() ? Color.parseColor("#1296db") : Color.BLACK);
|
||||||
|
holder.mCbCheck.setChecked(bean.isCheck());
|
||||||
|
holder.mCbCheck.setOnCheckedChangeListener((buttonView, isChecked) -> mLis.onItemCheckChange(bean, isChecked, i));
|
||||||
|
holder.itemView.setOnClickListener(v -> mLis.onItemCheckChange(bean, !bean.isCheck(), i));
|
||||||
|
}
|
||||||
|
|
||||||
|
private OnItemCheckChange mLis;
|
||||||
|
|
||||||
|
public void addOnitemCheckChange(OnItemCheckChange lis) {
|
||||||
|
this.mLis = lis;
|
||||||
|
}
|
||||||
|
|
||||||
|
public interface OnItemCheckChange {
|
||||||
|
void onItemCheckChange(AreaGridListBean.RowsBean bean, boolean isCheck, int pos);
|
||||||
|
}
|
||||||
|
}
|
@ -1,5 +1,7 @@
|
|||||||
package com.tengshisoft.commonmodule.beans;
|
package com.tengshisoft.commonmodule.beans;
|
||||||
|
|
||||||
|
import com.contrarywind.interfaces.IPickerViewData;
|
||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
@ -39,7 +41,7 @@ public class AreaGridListBean {
|
|||||||
this.rows = rows;
|
this.rows = rows;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static class RowsBean implements Serializable {
|
public static class RowsBean implements Serializable, IPickerViewData {
|
||||||
private String areaCode;
|
private String areaCode;
|
||||||
private String areaName;
|
private String areaName;
|
||||||
private String fillColor;
|
private String fillColor;
|
||||||
@ -184,5 +186,10 @@ public class AreaGridListBean {
|
|||||||
public void setRelationIdArray(List<?> relationIdArray) {
|
public void setRelationIdArray(List<?> relationIdArray) {
|
||||||
this.relationIdArray = relationIdArray;
|
this.relationIdArray = relationIdArray;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String getPickerViewText() {
|
||||||
|
return gridName;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,84 @@
|
|||||||
|
package com.tengshisoft.commonmodule.views;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.graphics.Color;
|
||||||
|
import android.util.DisplayMetrics;
|
||||||
|
import android.view.Gravity;
|
||||||
|
import android.view.View;
|
||||||
|
|
||||||
|
import androidx.recyclerview.widget.LinearLayoutManager;
|
||||||
|
import androidx.recyclerview.widget.RecyclerView;
|
||||||
|
|
||||||
|
import com.tengshisoft.commonmodule.adapters.ConditionAreaGridAdapter;
|
||||||
|
import com.tengshisoft.commonmodule.beans.AreaGridListBean;
|
||||||
|
import com.tenlionsoft.baselib.R;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import razerdp.basepopup.BasePopupWindow;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 作者: adam
|
||||||
|
* 日期: 2021/9/30 - 2:58 下午
|
||||||
|
* 邮箱: itgaojian@163.com
|
||||||
|
* 描述: 条件选择-网格
|
||||||
|
*/
|
||||||
|
public class ConditionAreaGridPopup extends BasePopupWindow {
|
||||||
|
private List<AreaGridListBean.RowsBean> mDatas;
|
||||||
|
private RecyclerView mRlvConditions;
|
||||||
|
private ConditionAreaGridAdapter mAdapter;
|
||||||
|
private OnListPopupItemClickListener mOnListPopupItemClickListener;
|
||||||
|
|
||||||
|
public ConditionAreaGridPopup(Context context, List<AreaGridListBean.RowsBean> datas) {
|
||||||
|
super(context);
|
||||||
|
View view = createPopupById(R.layout.popup_condition_layout);
|
||||||
|
RecyclerView rlvCondition = view.findViewById(R.id.rlv_conditions);
|
||||||
|
if (datas == null) {
|
||||||
|
mDatas = new ArrayList<>();
|
||||||
|
} else {
|
||||||
|
mDatas = datas;
|
||||||
|
}
|
||||||
|
mAdapter = new ConditionAreaGridAdapter(context, mDatas);
|
||||||
|
rlvCondition.setLayoutManager(new LinearLayoutManager(context));
|
||||||
|
rlvCondition.setAdapter(mAdapter);
|
||||||
|
setContentView(view);
|
||||||
|
|
||||||
|
setBackgroundColor(Color.parseColor("#11000000"));
|
||||||
|
setPopupGravity(Gravity.BOTTOM | Gravity.CENTER);
|
||||||
|
DisplayMetrics displayMetrics = context.getResources().getDisplayMetrics();
|
||||||
|
int height = (int) (displayMetrics.heightPixels * 0.5);
|
||||||
|
setHeight(height);
|
||||||
|
mAdapter.addOnitemCheckChange((bean, isCheck, pos) -> {
|
||||||
|
if (isCheck) {
|
||||||
|
mAdapter.mSelBeans.clear();
|
||||||
|
mAdapter.mSelBeans.add(bean);
|
||||||
|
bean.setCheck(isCheck);
|
||||||
|
mOnListPopupItemClickListener.onItemClick(bean, isCheck, pos);
|
||||||
|
}
|
||||||
|
if (isCheck) {
|
||||||
|
if (true) {
|
||||||
|
for (int i = 0; i < mAdapter.getData().size(); i++) {
|
||||||
|
if (!mAdapter.getData().get(i).getGridId().equals(bean.getGridId())) {
|
||||||
|
mAdapter.getData().get(i).setCheck(false);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
mAdapter.notifyDataSetChanged();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public OnListPopupItemClickListener getOnListPopupItemClickListener() {
|
||||||
|
return mOnListPopupItemClickListener;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setOnListPopupItemClickListener(OnListPopupItemClickListener onListPopupItemClickListener) {
|
||||||
|
mOnListPopupItemClickListener = onListPopupItemClickListener;
|
||||||
|
}
|
||||||
|
|
||||||
|
public interface OnListPopupItemClickListener {
|
||||||
|
void onItemClick(AreaGridListBean.RowsBean bean, boolean isCheck, int pos);
|
||||||
|
}
|
||||||
|
}
|
BIN
commonmodule/src/main/res/drawable-xhdpi/ic_arrow_sort_gray.png
Normal file
BIN
commonmodule/src/main/res/drawable-xhdpi/ic_arrow_sort_gray.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 211 B |
@ -2,6 +2,7 @@ package com.tengshisoft.gridmodule.incident.activitys.populace;
|
|||||||
|
|
||||||
import android.app.AlertDialog;
|
import android.app.AlertDialog;
|
||||||
import android.app.ProgressDialog;
|
import android.app.ProgressDialog;
|
||||||
|
import android.content.Intent;
|
||||||
import android.graphics.Color;
|
import android.graphics.Color;
|
||||||
import android.text.TextUtils;
|
import android.text.TextUtils;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
@ -9,9 +10,11 @@ import android.view.inputmethod.EditorInfo;
|
|||||||
import android.widget.Button;
|
import android.widget.Button;
|
||||||
import android.widget.EditText;
|
import android.widget.EditText;
|
||||||
import android.widget.ImageView;
|
import android.widget.ImageView;
|
||||||
|
import android.widget.LinearLayout;
|
||||||
import android.widget.ProgressBar;
|
import android.widget.ProgressBar;
|
||||||
import android.widget.TextView;
|
import android.widget.TextView;
|
||||||
|
|
||||||
|
import androidx.annotation.Nullable;
|
||||||
import androidx.recyclerview.widget.LinearLayoutManager;
|
import androidx.recyclerview.widget.LinearLayoutManager;
|
||||||
import androidx.recyclerview.widget.RecyclerView;
|
import androidx.recyclerview.widget.RecyclerView;
|
||||||
|
|
||||||
@ -20,13 +23,16 @@ import com.alibaba.android.arouter.launcher.ARouter;
|
|||||||
import com.hjq.toast.ToastUtils;
|
import com.hjq.toast.ToastUtils;
|
||||||
import com.scwang.smart.refresh.layout.SmartRefreshLayout;
|
import com.scwang.smart.refresh.layout.SmartRefreshLayout;
|
||||||
import com.tengshisoft.commonmodule.adapters.CensusPersonAdapter;
|
import com.tengshisoft.commonmodule.adapters.CensusPersonAdapter;
|
||||||
|
import com.tengshisoft.commonmodule.beans.AreaGridListBean;
|
||||||
import com.tengshisoft.commonmodule.beans.CensusPersonBean;
|
import com.tengshisoft.commonmodule.beans.CensusPersonBean;
|
||||||
import com.tengshisoft.commonmodule.beans.SuccessBean;
|
import com.tengshisoft.commonmodule.beans.SuccessBean;
|
||||||
import com.tengshisoft.commonmodule.nets.GridApis;
|
import com.tengshisoft.commonmodule.nets.GridApis;
|
||||||
|
import com.tengshisoft.commonmodule.views.ConditionAreaGridPopup;
|
||||||
import com.tengshisoft.gridmodule.R;
|
import com.tengshisoft.gridmodule.R;
|
||||||
import com.tengshisoft.gridmodule.R2;
|
import com.tengshisoft.gridmodule.R2;
|
||||||
import com.tenlionsoft.baselib.constant.PathConfig;
|
import com.tenlionsoft.baselib.constant.PathConfig;
|
||||||
import com.tenlionsoft.baselib.core.retrofit_net.RetrofitManager;
|
import com.tenlionsoft.baselib.core.retrofit_net.RetrofitManager;
|
||||||
|
import com.tenlionsoft.baselib.core.retrofit_net.conver.RxTransformer;
|
||||||
import com.tenlionsoft.baselib.core.widget.base.BaseActivity;
|
import com.tenlionsoft.baselib.core.widget.base.BaseActivity;
|
||||||
import com.tenlionsoft.baselib.core.widget.views.CenterBaseInputView;
|
import com.tenlionsoft.baselib.core.widget.views.CenterBaseInputView;
|
||||||
import com.tenlionsoft.baselib.core.widget.views.ItemSplitDivider;
|
import com.tenlionsoft.baselib.core.widget.views.ItemSplitDivider;
|
||||||
@ -67,6 +73,10 @@ public class CensusBaseActivity extends BaseActivity {
|
|||||||
EditText mEtSearchCentent;
|
EditText mEtSearchCentent;
|
||||||
@BindView(R2.id.iv_clear)
|
@BindView(R2.id.iv_clear)
|
||||||
ImageView mIvClear;
|
ImageView mIvClear;
|
||||||
|
@BindView(R2.id.tv_grid)
|
||||||
|
TextView mTvGrid;
|
||||||
|
@BindView(R2.id.ll_grid)
|
||||||
|
LinearLayout mLlGrid;
|
||||||
private Unbinder mBind;
|
private Unbinder mBind;
|
||||||
private int mCurPage = 1;
|
private int mCurPage = 1;
|
||||||
private CensusPersonAdapter mAdapter;
|
private CensusPersonAdapter mAdapter;
|
||||||
@ -131,7 +141,7 @@ public class CensusBaseActivity extends BaseActivity {
|
|||||||
});
|
});
|
||||||
refreshView(STATE_LOAD_SUCCESS);
|
refreshView(STATE_LOAD_SUCCESS);
|
||||||
setStateView(13);
|
setStateView(13);
|
||||||
refreshData();
|
getMineGridList();
|
||||||
mEtSearchCentent.setOnEditorActionListener((v, actionId, event) -> {
|
mEtSearchCentent.setOnEditorActionListener((v, actionId, event) -> {
|
||||||
if (actionId == EditorInfo.IME_ACTION_SEARCH) {
|
if (actionId == EditorInfo.IME_ACTION_SEARCH) {
|
||||||
hideSoftKeyboard();
|
hideSoftKeyboard();
|
||||||
@ -159,9 +169,79 @@ public class CensusBaseActivity extends BaseActivity {
|
|||||||
});
|
});
|
||||||
mIvClear.setOnClickListener(v -> {
|
mIvClear.setOnClickListener(v -> {
|
||||||
mEtSearchCentent.setText("");
|
mEtSearchCentent.setText("");
|
||||||
mKeywords="";
|
mKeywords = "";
|
||||||
refreshData();
|
refreshData();
|
||||||
});
|
});
|
||||||
|
mTvGrid.setOnClickListener(v -> onShowGrid());
|
||||||
|
}
|
||||||
|
|
||||||
|
private List<AreaGridListBean.RowsBean> mGridList;
|
||||||
|
private AreaGridListBean.RowsBean mSelGrid;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 选择网格
|
||||||
|
*/
|
||||||
|
private void onShowGrid() {
|
||||||
|
ConditionAreaGridPopup conditionPopup = new ConditionAreaGridPopup(mActivity, mGridList);
|
||||||
|
conditionPopup.setOnListPopupItemClickListener((bean, isCheck, pos) -> {
|
||||||
|
if (isCheck) {
|
||||||
|
//选中了
|
||||||
|
mSelGrid = bean;
|
||||||
|
mTvGrid.setText(mSelGrid.getGridName());
|
||||||
|
} else {
|
||||||
|
//清除了选项
|
||||||
|
mSelGrid = null;
|
||||||
|
mTvGrid.setText("网格");
|
||||||
|
}
|
||||||
|
refreshData();
|
||||||
|
conditionPopup.dismiss();
|
||||||
|
});
|
||||||
|
conditionPopup.showPopupWindow(mTvGrid);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private void getMineGridList() {
|
||||||
|
RetrofitManager.getInstance()
|
||||||
|
.create(GridApis.class)
|
||||||
|
.getMineGridList(UserLgUtils.getToken())
|
||||||
|
.compose(RxTransformer.getTransformer())
|
||||||
|
.subscribe(new Observer<List<AreaGridListBean.RowsBean>>() {
|
||||||
|
@Override
|
||||||
|
public void onSubscribe(@androidx.annotation.NonNull Disposable d) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onNext(@androidx.annotation.NonNull List<AreaGridListBean.RowsBean> rowsBeans) {
|
||||||
|
if (rowsBeans.size() > 0) {
|
||||||
|
mGridList = rowsBeans;
|
||||||
|
mSelGrid = mGridList.get(0);
|
||||||
|
if (mGridList.size() > 1) {
|
||||||
|
mGridList.get(0).setCheck(true);
|
||||||
|
mLlGrid.setVisibility(View.VISIBLE);
|
||||||
|
mTvGrid.setText(mSelGrid.getGridName());
|
||||||
|
} else {
|
||||||
|
mLlGrid.setVisibility(View.GONE);
|
||||||
|
}
|
||||||
|
refreshData();
|
||||||
|
} else {
|
||||||
|
mLlGrid.setVisibility(View.GONE);
|
||||||
|
ToastUtils.show("您暂未分配网格");
|
||||||
|
setStateView(15);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onError(@androidx.annotation.NonNull Throwable e) {
|
||||||
|
ExceptionHandler.handleException(e);
|
||||||
|
setStateView(16);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onComplete() {
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -208,7 +288,7 @@ public class CensusBaseActivity extends BaseActivity {
|
|||||||
dialog1.show();
|
dialog1.show();
|
||||||
RetrofitManager.getInstance()
|
RetrofitManager.getInstance()
|
||||||
.create(GridApis.class)
|
.create(GridApis.class)
|
||||||
.doDelBaseInfo(bean.getBasePopulationInfoId(),"", UserLgUtils.getToken())
|
.doDelBaseInfo(bean.getBasePopulationInfoId(), "", UserLgUtils.getToken())
|
||||||
.subscribeOn(Schedulers.io())
|
.subscribeOn(Schedulers.io())
|
||||||
.observeOn(AndroidSchedulers.mainThread())
|
.observeOn(AndroidSchedulers.mainThread())
|
||||||
.subscribe(new Observer<SuccessBean>() {
|
.subscribe(new Observer<SuccessBean>() {
|
||||||
@ -253,7 +333,7 @@ public class CensusBaseActivity extends BaseActivity {
|
|||||||
.build(PathConfig.PATH_MODULE_GRID_ACTIVITY_POPULACE_BASE_ADD)
|
.build(PathConfig.PATH_MODULE_GRID_ACTIVITY_POPULACE_BASE_ADD)
|
||||||
.withString("title", "人口基础信息编辑")
|
.withString("title", "人口基础信息编辑")
|
||||||
.withString("id", bean.getBasePopulationInfoId())
|
.withString("id", bean.getBasePopulationInfoId())
|
||||||
.navigation();
|
.navigation(mActivity,12);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -265,7 +345,18 @@ public class CensusBaseActivity extends BaseActivity {
|
|||||||
ARouter.getInstance()
|
ARouter.getInstance()
|
||||||
.build(PathConfig.PATH_MODULE_GRID_ACTIVITY_POPULACE_BASE_DETAIL)
|
.build(PathConfig.PATH_MODULE_GRID_ACTIVITY_POPULACE_BASE_DETAIL)
|
||||||
.withString("id", bean.getBasePopulationInfoId())
|
.withString("id", bean.getBasePopulationInfoId())
|
||||||
.navigation();
|
.navigation(mActivity, 12);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onActivityResult(int requestCode, int resultCode, @Nullable Intent data) {
|
||||||
|
if (requestCode == 12) {
|
||||||
|
if (resultCode == 13) {
|
||||||
|
refreshData();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
super.onActivityResult(requestCode, resultCode, data);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -279,6 +370,7 @@ public class CensusBaseActivity extends BaseActivity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void refreshData() {
|
private void refreshData() {
|
||||||
|
setStateView(13);
|
||||||
getUpcomingList(1, null);
|
getUpcomingList(1, null);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -294,7 +386,8 @@ public class CensusBaseActivity extends BaseActivity {
|
|||||||
mCurPage = page;
|
mCurPage = page;
|
||||||
RetrofitManager.getInstance()
|
RetrofitManager.getInstance()
|
||||||
.create(GridApis.class)
|
.create(GridApis.class)
|
||||||
.getBaseInfoList(page + "", mKeywords, "1",UserLgUtils.getToken())
|
.getBaseInfoList(mSelGrid == null ? "" : mSelGrid.getGridId(), page + "", mKeywords, "1",
|
||||||
|
UserLgUtils.getToken())
|
||||||
.subscribeOn(Schedulers.io())
|
.subscribeOn(Schedulers.io())
|
||||||
.observeOn(AndroidSchedulers.mainThread())
|
.observeOn(AndroidSchedulers.mainThread())
|
||||||
.subscribe(new Observer<CensusPersonBean>() {
|
.subscribe(new Observer<CensusPersonBean>() {
|
||||||
|
@ -8,7 +8,6 @@ import android.widget.TextView;
|
|||||||
|
|
||||||
import com.alibaba.android.arouter.facade.annotation.Route;
|
import com.alibaba.android.arouter.facade.annotation.Route;
|
||||||
import com.hjq.toast.ToastUtils;
|
import com.hjq.toast.ToastUtils;
|
||||||
import com.tengshisoft.commonmodule.beans.CensusPersonBean;
|
|
||||||
import com.tengshisoft.commonmodule.beans.SuccessBean;
|
import com.tengshisoft.commonmodule.beans.SuccessBean;
|
||||||
import com.tengshisoft.commonmodule.nets.GridApis;
|
import com.tengshisoft.commonmodule.nets.GridApis;
|
||||||
import com.tengshisoft.gridmodule.R;
|
import com.tengshisoft.gridmodule.R;
|
||||||
@ -109,8 +108,56 @@ public class CensusBaseDetailActivity extends BaseActivity {
|
|||||||
refreshView(STATE_LOAD_LOADING);
|
refreshView(STATE_LOAD_LOADING);
|
||||||
mId = getIntent().getStringExtra("id");
|
mId = getIntent().getStringExtra("id");
|
||||||
getDetailData(mId);
|
getDetailData(mId);
|
||||||
mBtnDel.setOnClickListener(v -> onShowDelReason());
|
mBtnDel.setOnClickListener(v -> doUnbindInfo());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 解绑人员
|
||||||
|
*/
|
||||||
|
private void doUnbindInfo() {
|
||||||
|
AlertDialog.Builder builder = new AlertDialog.Builder(mActivity);
|
||||||
|
builder.setTitle("提示")
|
||||||
|
.setMessage("您确定要解绑该人员吗?")
|
||||||
|
.setPositiveButton("确定", (dialog, which) -> {
|
||||||
|
dialog.dismiss();
|
||||||
|
ProgressDialog dialog1 = UIUtil.initDialog(mActivity, "解绑中...");
|
||||||
|
dialog1.show();
|
||||||
|
RetrofitManager.getInstance()
|
||||||
|
.create(GridApis.class)
|
||||||
|
.doUnbindBaseInfo(mId, UserLgUtils.getToken())
|
||||||
|
.subscribeOn(Schedulers.io())
|
||||||
|
.observeOn(AndroidSchedulers.mainThread())
|
||||||
|
.subscribe(new Observer<SuccessBean>() {
|
||||||
|
@Override
|
||||||
|
public void onSubscribe(@NonNull Disposable d) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onNext(@NonNull SuccessBean successBean) {
|
||||||
|
dialog1.dismiss();
|
||||||
|
ToastUtils.show("解绑成功");
|
||||||
|
setResult(13);
|
||||||
|
finish();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onError(@NonNull Throwable e) {
|
||||||
|
dialog1.dismiss();
|
||||||
|
ExceptionHandler.handleException(e);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onComplete() {
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
|
})
|
||||||
|
.setNegativeButton("取消", (dialog, which) -> dialog.dismiss())
|
||||||
|
.create()
|
||||||
|
.show();
|
||||||
|
}
|
||||||
|
|
||||||
private void onShowDelReason() {
|
private void onShowDelReason() {
|
||||||
CenterBaseInputView intputView = new CenterBaseInputView.DialogBuilder(mActivity).build();
|
CenterBaseInputView intputView = new CenterBaseInputView.DialogBuilder(mActivity).build();
|
||||||
intputView.addOnChoseListener((time, content) -> {
|
intputView.addOnChoseListener((time, content) -> {
|
||||||
@ -120,6 +167,7 @@ public class CensusBaseDetailActivity extends BaseActivity {
|
|||||||
});
|
});
|
||||||
intputView.show();
|
intputView.show();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取详细信息
|
* 获取详细信息
|
||||||
*
|
*
|
||||||
@ -127,32 +175,32 @@ public class CensusBaseDetailActivity extends BaseActivity {
|
|||||||
*/
|
*/
|
||||||
private void getDetailData(String id) {
|
private void getDetailData(String id) {
|
||||||
RetrofitManager.getInstance()
|
RetrofitManager.getInstance()
|
||||||
.create(GridApis.class)
|
.create(GridApis.class)
|
||||||
.getBaseInfoDetailById(id, UserLgUtils.getToken())
|
.getBaseInfoDetailById(id, UserLgUtils.getToken())
|
||||||
.subscribeOn(Schedulers.io())
|
.subscribeOn(Schedulers.io())
|
||||||
.observeOn(AndroidSchedulers.mainThread())
|
.observeOn(AndroidSchedulers.mainThread())
|
||||||
.subscribe(new Observer<PersonSearchBean>() {
|
.subscribe(new Observer<PersonSearchBean>() {
|
||||||
@Override
|
@Override
|
||||||
public void onSubscribe(@NonNull Disposable d) {
|
public void onSubscribe(@NonNull Disposable d) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onNext(@NonNull PersonSearchBean searchBaseInfoBean) {
|
public void onNext(@NonNull PersonSearchBean searchBaseInfoBean) {
|
||||||
setDataToView(searchBaseInfoBean, 0);
|
setDataToView(searchBaseInfoBean, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onError(@NonNull Throwable e) {
|
public void onError(@NonNull Throwable e) {
|
||||||
ExceptionHandler.handleException(e);
|
ExceptionHandler.handleException(e);
|
||||||
refreshView(STATE_LOAD_ERROR);
|
refreshView(STATE_LOAD_ERROR);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onComplete() {
|
public void onComplete() {
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -161,45 +209,45 @@ public class CensusBaseDetailActivity extends BaseActivity {
|
|||||||
private void doDelBean(String content) {
|
private void doDelBean(String content) {
|
||||||
AlertDialog.Builder builder = new AlertDialog.Builder(mActivity);
|
AlertDialog.Builder builder = new AlertDialog.Builder(mActivity);
|
||||||
builder.setTitle("提示")
|
builder.setTitle("提示")
|
||||||
.setMessage("确定要删除该条信息吗?")
|
.setMessage("确定要删除该条信息吗?")
|
||||||
.setPositiveButton("确定", (dialog, which) -> {
|
.setPositiveButton("确定", (dialog, which) -> {
|
||||||
dialog.dismiss();
|
dialog.dismiss();
|
||||||
ProgressDialog dialog1 = UIUtil.initDialog(mActivity, "删除中...");
|
ProgressDialog dialog1 = UIUtil.initDialog(mActivity, "删除中...");
|
||||||
dialog1.show();
|
dialog1.show();
|
||||||
RetrofitManager.getInstance()
|
RetrofitManager.getInstance()
|
||||||
.create(GridApis.class)
|
.create(GridApis.class)
|
||||||
.doDelBaseInfo(mId,content, UserLgUtils.getToken())
|
.doDelBaseInfo(mId, content, UserLgUtils.getToken())
|
||||||
.subscribeOn(Schedulers.io())
|
.subscribeOn(Schedulers.io())
|
||||||
.observeOn(AndroidSchedulers.mainThread())
|
.observeOn(AndroidSchedulers.mainThread())
|
||||||
.subscribe(new Observer<SuccessBean>() {
|
.subscribe(new Observer<SuccessBean>() {
|
||||||
@Override
|
@Override
|
||||||
public void onSubscribe(@NonNull Disposable d) {
|
public void onSubscribe(@NonNull Disposable d) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onNext(@NonNull SuccessBean successBean) {
|
public void onNext(@NonNull SuccessBean successBean) {
|
||||||
dialog1.dismiss();
|
dialog1.dismiss();
|
||||||
ToastUtils.show("删除成功");
|
ToastUtils.show("删除成功");
|
||||||
setResult(13);
|
setResult(13);
|
||||||
finish();
|
finish();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onError(@NonNull Throwable e) {
|
public void onError(@NonNull Throwable e) {
|
||||||
dialog1.dismiss();
|
dialog1.dismiss();
|
||||||
ExceptionHandler.handleException(e);
|
ExceptionHandler.handleException(e);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onComplete() {
|
public void onComplete() {
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
})
|
})
|
||||||
.setNegativeButton("取消", (dialog, which) -> dialog.dismiss())
|
.setNegativeButton("取消", (dialog, which) -> dialog.dismiss())
|
||||||
.create()
|
.create()
|
||||||
.show();
|
.show();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -224,12 +272,12 @@ public class CensusBaseDetailActivity extends BaseActivity {
|
|||||||
mEtPhone.setText(bean.getTelephone());//联系方式
|
mEtPhone.setText(bean.getTelephone());//联系方式
|
||||||
mEtCensusDetail.setText(bean.getNativePlaceAddr());//户籍地详址
|
mEtCensusDetail.setText(bean.getNativePlaceAddr());//户籍地详址
|
||||||
mEtCurDetail.setText(bean.getCurrentResidenceAddr());//现在详细地址
|
mEtCurDetail.setText(bean.getCurrentResidenceAddr());//现在详细地址
|
||||||
if(!TextUtils.isEmpty(bean.getType())){
|
if (!TextUtils.isEmpty(bean.getType())) {
|
||||||
switch (bean.getType()){
|
switch (bean.getType()) {
|
||||||
case "1":
|
case "1":
|
||||||
mTvType.setText("户籍人口");
|
mTvType.setText("户籍人口");
|
||||||
break;
|
break;
|
||||||
case"2":
|
case "2":
|
||||||
mTvType.setText("常住人口");
|
mTvType.setText("常住人口");
|
||||||
break;
|
break;
|
||||||
case "3":
|
case "3":
|
||||||
|
@ -166,6 +166,10 @@ public class CensusBaseEnterActivity extends BaseActivity {
|
|||||||
mBind = ButterKnife.bind(this);
|
mBind = ButterKnife.bind(this);
|
||||||
mId = getIntent().getStringExtra("id");
|
mId = getIntent().getStringExtra("id");
|
||||||
String title = getIntent().getStringExtra("title");
|
String title = getIntent().getStringExtra("title");
|
||||||
|
String idCard = getIntent().getStringExtra("idCard");
|
||||||
|
if(!TextUtils.isEmpty(idCard)){
|
||||||
|
mEtIdentity.setText(idCard);
|
||||||
|
}
|
||||||
if (!TextUtils.isEmpty(mId)) {
|
if (!TextUtils.isEmpty(mId)) {
|
||||||
//编辑
|
//编辑
|
||||||
refreshView(STATE_LOAD_LOADING);
|
refreshView(STATE_LOAD_LOADING);
|
||||||
@ -197,6 +201,7 @@ public class CensusBaseEnterActivity extends BaseActivity {
|
|||||||
.navigation(mActivity, 15);
|
.navigation(mActivity, 15);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
mTvArea.setOnClickListener(v -> onShowArea());
|
mTvArea.setOnClickListener(v -> onShowArea());
|
||||||
mEtIdentity.addTextChangedListener(new TextChange() {
|
mEtIdentity.addTextChangedListener(new TextChange() {
|
||||||
@Override
|
@Override
|
||||||
@ -282,6 +287,7 @@ public class CensusBaseEnterActivity extends BaseActivity {
|
|||||||
public void onNext(@NonNull SuccessBean successBean) {
|
public void onNext(@NonNull SuccessBean successBean) {
|
||||||
dialog.dismiss();
|
dialog.dismiss();
|
||||||
ToastUtils.show("新增成功");
|
ToastUtils.show("新增成功");
|
||||||
|
setResult(13);
|
||||||
finish();
|
finish();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -317,6 +323,7 @@ public class CensusBaseEnterActivity extends BaseActivity {
|
|||||||
public void onNext(@NonNull SuccessBean successBean) {
|
public void onNext(@NonNull SuccessBean successBean) {
|
||||||
dialog.dismiss();
|
dialog.dismiss();
|
||||||
ToastUtils.show("修改成功");
|
ToastUtils.show("修改成功");
|
||||||
|
setResult(13);
|
||||||
finish();
|
finish();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -419,7 +426,7 @@ public class CensusBaseEnterActivity extends BaseActivity {
|
|||||||
}
|
}
|
||||||
String nation = mTvNation.getText().toString().trim();
|
String nation = mTvNation.getText().toString().trim();
|
||||||
if (TextUtils.isEmpty(nation)) {
|
if (TextUtils.isEmpty(nation)) {
|
||||||
ToastUtils.show("请选择名族");
|
ToastUtils.show("请选择民族");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
String marry = mTvMarry.getText().toString().trim();
|
String marry = mTvMarry.getText().toString().trim();
|
||||||
|
@ -2,7 +2,10 @@ package com.tengshisoft.gridmodule.incident.activitys.populace;
|
|||||||
|
|
||||||
import android.app.AlertDialog;
|
import android.app.AlertDialog;
|
||||||
import android.app.ProgressDialog;
|
import android.app.ProgressDialog;
|
||||||
|
import android.content.DialogInterface;
|
||||||
import android.content.Intent;
|
import android.content.Intent;
|
||||||
|
import android.graphics.Color;
|
||||||
|
import android.net.Uri;
|
||||||
import android.text.TextUtils;
|
import android.text.TextUtils;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
import android.view.inputmethod.EditorInfo;
|
import android.view.inputmethod.EditorInfo;
|
||||||
@ -14,22 +17,34 @@ import android.widget.ProgressBar;
|
|||||||
import android.widget.TextView;
|
import android.widget.TextView;
|
||||||
|
|
||||||
import androidx.annotation.Nullable;
|
import androidx.annotation.Nullable;
|
||||||
|
import androidx.recyclerview.widget.LinearLayoutManager;
|
||||||
|
import androidx.recyclerview.widget.RecyclerView;
|
||||||
|
|
||||||
import com.alibaba.android.arouter.facade.annotation.Route;
|
import com.alibaba.android.arouter.facade.annotation.Route;
|
||||||
import com.alibaba.android.arouter.launcher.ARouter;
|
import com.alibaba.android.arouter.launcher.ARouter;
|
||||||
|
import com.bigkoo.pickerview.builder.OptionsPickerBuilder;
|
||||||
|
import com.bigkoo.pickerview.view.OptionsPickerView;
|
||||||
|
import com.google.gson.Gson;
|
||||||
import com.hjq.toast.ToastUtils;
|
import com.hjq.toast.ToastUtils;
|
||||||
import com.tengshisoft.commonmodule.adapters.CensusPersonAdapter;
|
import com.tengshisoft.commonmodule.adapters.CensusPersonAdapter;
|
||||||
|
import com.tengshisoft.commonmodule.beans.AreaGridListBean;
|
||||||
import com.tengshisoft.commonmodule.beans.CensusPersonBean;
|
import com.tengshisoft.commonmodule.beans.CensusPersonBean;
|
||||||
|
import com.tengshisoft.commonmodule.beans.SavePersonBean;
|
||||||
import com.tengshisoft.commonmodule.beans.SuccessBean;
|
import com.tengshisoft.commonmodule.beans.SuccessBean;
|
||||||
import com.tengshisoft.commonmodule.nets.GridApis;
|
import com.tengshisoft.commonmodule.nets.GridApis;
|
||||||
import com.tengshisoft.gridmodule.R;
|
import com.tengshisoft.gridmodule.R;
|
||||||
import com.tengshisoft.gridmodule.R2;
|
import com.tengshisoft.gridmodule.R2;
|
||||||
import com.tenlionsoft.baselib.constant.PathConfig;
|
import com.tenlionsoft.baselib.constant.PathConfig;
|
||||||
|
import com.tenlionsoft.baselib.core.beans.DicBean;
|
||||||
import com.tenlionsoft.baselib.core.beans.PersonSearchBean;
|
import com.tenlionsoft.baselib.core.beans.PersonSearchBean;
|
||||||
import com.tenlionsoft.baselib.core.retrofit_net.RetrofitManager;
|
import com.tenlionsoft.baselib.core.retrofit_net.RetrofitManager;
|
||||||
|
import com.tenlionsoft.baselib.core.retrofit_net.conver.RxTransformer;
|
||||||
import com.tenlionsoft.baselib.core.widget.base.BaseActivity;
|
import com.tenlionsoft.baselib.core.widget.base.BaseActivity;
|
||||||
import com.tenlionsoft.baselib.core.widget.views.CenterBaseInputView;
|
import com.tenlionsoft.baselib.core.widget.views.CenterBaseInputView;
|
||||||
|
import com.tenlionsoft.baselib.core.widget.views.CenterGridPhoneListView;
|
||||||
|
import com.tenlionsoft.baselib.core.widget.views.GridTextAdapter;
|
||||||
import com.tenlionsoft.baselib.utils.ExceptionHandler;
|
import com.tenlionsoft.baselib.utils.ExceptionHandler;
|
||||||
|
import com.tenlionsoft.baselib.utils.LogUtils;
|
||||||
import com.tenlionsoft.baselib.utils.UIUtil;
|
import com.tenlionsoft.baselib.utils.UIUtil;
|
||||||
import com.tenlionsoft.baselib.utils.UserLgUtils;
|
import com.tenlionsoft.baselib.utils.UserLgUtils;
|
||||||
|
|
||||||
@ -43,6 +58,8 @@ import io.reactivex.rxjava3.annotations.NonNull;
|
|||||||
import io.reactivex.rxjava3.core.Observer;
|
import io.reactivex.rxjava3.core.Observer;
|
||||||
import io.reactivex.rxjava3.disposables.Disposable;
|
import io.reactivex.rxjava3.disposables.Disposable;
|
||||||
import io.reactivex.rxjava3.schedulers.Schedulers;
|
import io.reactivex.rxjava3.schedulers.Schedulers;
|
||||||
|
import okhttp3.MediaType;
|
||||||
|
import okhttp3.RequestBody;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 人口基础信息搜索
|
* 人口基础信息搜索
|
||||||
@ -67,38 +84,44 @@ public class CensusBaseSearchActivity extends BaseActivity {
|
|||||||
TextView mTvBaseGrid;
|
TextView mTvBaseGrid;
|
||||||
@BindView(R2.id.tv_base_name)
|
@BindView(R2.id.tv_base_name)
|
||||||
TextView mTvBaseName;//姓名
|
TextView mTvBaseName;//姓名
|
||||||
@BindView(R2.id.tv_base_former_name)
|
|
||||||
TextView mTvBaseFormerName;//曾用名
|
|
||||||
@BindView(R2.id.tv_base_gender)
|
@BindView(R2.id.tv_base_gender)
|
||||||
TextView mTvBaseGender;//性别
|
TextView mTvBaseGender;//性别
|
||||||
@BindView(R2.id.tv_base_id_card)
|
@BindView(R2.id.tv_base_id_card)
|
||||||
TextView mTvBaseIdCard;//身份证
|
TextView mTvBaseIdCard;//身份证
|
||||||
@BindView(R2.id.tv_base_phone)
|
@BindView(R2.id.tv_base_phone)
|
||||||
TextView mTvBasePhone;//联系电话
|
TextView mTvBasePhone;//联系电话
|
||||||
@BindView(R2.id.tv_base_nation)
|
// @BindView(R2.id.tv_base_nation)
|
||||||
TextView mTvBaseNation;//名族
|
// TextView mTvBaseNation;//民族
|
||||||
@BindView(R2.id.tv_base_register_loc)
|
|
||||||
TextView mTvBaseRegisterLoc;//户籍地
|
|
||||||
// @BindView(R2.id.tv_base_cur_loc)
|
|
||||||
// TextView mTvBaseCurLoc;//现住址
|
|
||||||
@BindView(R2.id.tv_base_cur_address)
|
|
||||||
TextView mTvBaseCurAddress;//现住址详情
|
|
||||||
@BindView(R2.id.ll_person_info)
|
@BindView(R2.id.ll_person_info)
|
||||||
LinearLayout mLlPersonInfo;
|
LinearLayout mLlPersonInfo;
|
||||||
@BindView(R2.id.btn_page_search)
|
@BindView(R2.id.btn_page_search)
|
||||||
Button mBtnSearch;
|
Button mBtnSearch;
|
||||||
@BindView(R2.id.btn_edit)
|
@BindView(R2.id.rlv_grids)
|
||||||
Button mBtnEdit;
|
RecyclerView mRlvGrid;
|
||||||
|
@BindView(R2.id.ll_edit)
|
||||||
@BindView(R2.id.btn_detail)
|
LinearLayout mLlEdit;
|
||||||
Button mBtnDetail;
|
@BindView(R2.id.tv_grid)
|
||||||
|
TextView mTvGrid;
|
||||||
|
@BindView(R2.id.tv_type)
|
||||||
|
TextView mTvType;
|
||||||
|
@BindView(R2.id.tv_grid_hint)
|
||||||
|
TextView mTvGridHint;
|
||||||
|
@BindView(R2.id.btn_confirm)
|
||||||
|
Button mBtnSave;
|
||||||
|
@BindView(R2.id.tv_base_type)
|
||||||
|
TextView mTvBaseType;
|
||||||
|
@BindView(R2.id.tv_grids_list_hint)
|
||||||
|
TextView mTvGridsListHint;
|
||||||
|
private List<DicBean> mTypeList;//人口类型
|
||||||
|
|
||||||
private int mCurPage = 1;
|
private int mCurPage = 1;
|
||||||
private CensusPersonAdapter mAdapter;
|
private CensusPersonAdapter mAdapter;
|
||||||
|
private OptionsPickerView<DicBean> mTypePicker;
|
||||||
|
private DicBean mSelTypeBean;
|
||||||
private List<CensusPersonBean.RowsBean> mDatas = new ArrayList<>();
|
private List<CensusPersonBean.RowsBean> mDatas = new ArrayList<>();
|
||||||
|
|
||||||
|
private OptionsPickerView<AreaGridListBean.RowsBean> mGridPicker;
|
||||||
|
private AreaGridListBean.RowsBean mSelGrid;
|
||||||
private String mKeywords = "";
|
private String mKeywords = "";
|
||||||
private @NonNull PersonSearchBean mBean;
|
private @NonNull PersonSearchBean mBean;
|
||||||
|
|
||||||
@ -141,29 +164,115 @@ public class CensusBaseSearchActivity extends BaseActivity {
|
|||||||
});
|
});
|
||||||
mIvClear.setOnClickListener(v -> {
|
mIvClear.setOnClickListener(v -> {
|
||||||
mBean = null;
|
mBean = null;
|
||||||
|
mLlEdit.setVisibility(View.GONE);
|
||||||
mEtSearchCentent.setText("");
|
mEtSearchCentent.setText("");
|
||||||
mTvBaseArea.setText("");
|
mTvBaseArea.setText("");
|
||||||
mTvBaseGrid.setText("");
|
mTvBaseGrid.setText("");
|
||||||
mTvBaseName.setText("");
|
mTvBaseName.setText("");
|
||||||
mTvBaseFormerName.setText("");
|
|
||||||
mTvBaseGender.setText("");
|
mTvBaseGender.setText("");
|
||||||
mTvBaseIdCard.setText("");//身份证
|
mTvBaseIdCard.setText("");//身份证
|
||||||
mTvBasePhone.setText("");//联系电话
|
mTvBasePhone.setText("");//联系电话
|
||||||
mTvBaseNation.setText("");//名族
|
|
||||||
mTvBaseRegisterLoc.setText("");//户籍地
|
|
||||||
mTvBaseCurAddress.setText("");//现住址详情
|
|
||||||
setStateView(12);
|
setStateView(12);
|
||||||
});
|
});
|
||||||
mBtnEdit.setOnClickListener(v -> {
|
// mBtnEdit.setOnClickListener(v -> {
|
||||||
if (mBean != null && !TextUtils.isEmpty(mBean.getBasePopulationInfoId())) {
|
// if (mBean != null && !TextUtils.isEmpty(mBean.getBasePopulationInfoId())) {
|
||||||
doEditBean();
|
// doEditBean();
|
||||||
}
|
// }
|
||||||
});
|
// });
|
||||||
mBtnDetail.setOnClickListener(v -> {
|
// mBtnDetail.setOnClickListener(v -> {
|
||||||
if (mBean != null && !TextUtils.isEmpty(mBean.getBasePopulationInfoId())) {
|
// if (mBean != null && !TextUtils.isEmpty(mBean.getBasePopulationInfoId())) {
|
||||||
showDetail();
|
// showDetail();
|
||||||
}
|
// }
|
||||||
});
|
// });
|
||||||
|
mTypeList = new ArrayList<>();
|
||||||
|
DicBean bean1 = new DicBean();
|
||||||
|
bean1.setDataName("户籍人口");
|
||||||
|
bean1.setDataId("1");
|
||||||
|
|
||||||
|
DicBean bean2 = new DicBean();
|
||||||
|
bean2.setDataName("常住人口");
|
||||||
|
bean2.setDataId("2");
|
||||||
|
DicBean bean3 = new DicBean();
|
||||||
|
bean3.setDataName("外来人口");
|
||||||
|
bean3.setDataId("3");
|
||||||
|
mTypeList.add(bean1);
|
||||||
|
mTypeList.add(bean2);
|
||||||
|
mTypeList.add(bean3);
|
||||||
|
mTvGrid.setOnClickListener(v -> onShowGrid());
|
||||||
|
mTvType.setOnClickListener(v -> onShowType());
|
||||||
|
mBtnSave.setOnClickListener(v -> doSaveEdit());
|
||||||
|
getMineGridList();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void doSaveEdit() {
|
||||||
|
if (checkParams()) {
|
||||||
|
ProgressDialog dialog = UIUtil.initDialog(mActivity, "修改中...");
|
||||||
|
dialog.show();
|
||||||
|
RetrofitManager.getInstance()
|
||||||
|
.create(GridApis.class)
|
||||||
|
.doEditPopulaceInfo(mBean.getBasePopulationInfoId(), mSelTypeBean.getDataId(),
|
||||||
|
mSelGrid.getGridId(), UserLgUtils.getToken())
|
||||||
|
.subscribeOn(Schedulers.io())
|
||||||
|
.observeOn(AndroidSchedulers.mainThread())
|
||||||
|
.subscribe(new Observer<SuccessBean>() {
|
||||||
|
@Override
|
||||||
|
public void onSubscribe(@NonNull Disposable d) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onNext(@NonNull SuccessBean successBean) {
|
||||||
|
dialog.dismiss();
|
||||||
|
ToastUtils.show("修改成功");
|
||||||
|
setStateView(13);
|
||||||
|
doSearchPersonByIdCard();
|
||||||
|
mBean = null;
|
||||||
|
mLlEdit.setVisibility(View.GONE);
|
||||||
|
mEtSearchCentent.setText("");
|
||||||
|
mTvBaseArea.setText("");
|
||||||
|
mTvBaseGrid.setText("");
|
||||||
|
mTvBaseName.setText("");
|
||||||
|
mTvBaseGender.setText("");
|
||||||
|
mTvBaseIdCard.setText("");//身份证
|
||||||
|
mTvBasePhone.setText("");//联系电话
|
||||||
|
mSelGrid = null;
|
||||||
|
mSelTypeBean = null;
|
||||||
|
mTvGrid.setText("");
|
||||||
|
mTvType.setText("");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onError(@NonNull Throwable e) {
|
||||||
|
dialog.dismiss();
|
||||||
|
ExceptionHandler.handleException(e);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onComplete() {
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 显示网格选择
|
||||||
|
*/
|
||||||
|
private void onShowGrid() {
|
||||||
|
if (mGridPicker == null) {
|
||||||
|
mGridPicker = new OptionsPickerBuilder(mActivity, (o1, o2, o3, v) -> {
|
||||||
|
mSelGrid = mGridList.get(o1);
|
||||||
|
mTvGrid.setText(mSelGrid.getGridName());
|
||||||
|
})
|
||||||
|
.setTitleText("请选择")
|
||||||
|
.setCancelColor(Color.parseColor("#1189FF"))
|
||||||
|
.setSubmitColor(Color.parseColor("#1189FF"))
|
||||||
|
.setTitleColor(Color.parseColor("#1189FF"))
|
||||||
|
.build();
|
||||||
|
mGridPicker.setPicker(mGridList);
|
||||||
|
}
|
||||||
|
mGridPicker.show();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -176,13 +285,10 @@ public class CensusBaseSearchActivity extends BaseActivity {
|
|||||||
mTvBaseArea.setText("");
|
mTvBaseArea.setText("");
|
||||||
mTvBaseGrid.setText("");
|
mTvBaseGrid.setText("");
|
||||||
mTvBaseName.setText("");
|
mTvBaseName.setText("");
|
||||||
mTvBaseFormerName.setText("");
|
|
||||||
mTvBaseGender.setText("");
|
mTvBaseGender.setText("");
|
||||||
mTvBaseIdCard.setText("");//身份证
|
mTvBaseIdCard.setText("");//身份证
|
||||||
mTvBasePhone.setText("");//联系电话
|
mTvBasePhone.setText("");//联系电话
|
||||||
mTvBaseNation.setText("");//名族
|
mLlEdit.setVisibility(View.GONE);
|
||||||
mTvBaseRegisterLoc.setText("");//户籍地
|
|
||||||
mTvBaseCurAddress.setText("");//现住址详情
|
|
||||||
setStateView(12);
|
setStateView(12);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -210,6 +316,7 @@ public class CensusBaseSearchActivity extends BaseActivity {
|
|||||||
setBaseInfo(personSearchBean);
|
setBaseInfo(personSearchBean);
|
||||||
} else {
|
} else {
|
||||||
setStateView(15);
|
setStateView(15);
|
||||||
|
showAddDialog();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -226,6 +333,60 @@ public class CensusBaseSearchActivity extends BaseActivity {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void showAddDialog() {
|
||||||
|
AlertDialog.Builder builder = new AlertDialog.Builder(mActivity);
|
||||||
|
builder.setTitle("提示")
|
||||||
|
.setMessage("该人员信息未搜索到,现在去新增吗?")
|
||||||
|
.setPositiveButton("确定", (dialog, which) -> {
|
||||||
|
dialog.dismiss();
|
||||||
|
ARouter.getInstance()
|
||||||
|
.build(PathConfig.PATH_MODULE_GRID_ACTIVITY_POPULACE_BASE_ADD)
|
||||||
|
.withString("title", "人口基础信息录入")
|
||||||
|
.withString("idCard",mEtSearchCentent.getText().toString().trim())
|
||||||
|
.navigation();
|
||||||
|
})
|
||||||
|
.setNegativeButton("取消", (dialog, which) -> dialog.dismiss())
|
||||||
|
.create()
|
||||||
|
.show();
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private List<AreaGridListBean.RowsBean> mGridList;
|
||||||
|
|
||||||
|
private void getMineGridList() {
|
||||||
|
RetrofitManager.getInstance()
|
||||||
|
.create(GridApis.class)
|
||||||
|
.getMineGridList(UserLgUtils.getToken())
|
||||||
|
.compose(RxTransformer.getTransformer())
|
||||||
|
.subscribe(new Observer<List<AreaGridListBean.RowsBean>>() {
|
||||||
|
@Override
|
||||||
|
public void onSubscribe(@androidx.annotation.NonNull Disposable d) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onNext(@androidx.annotation.NonNull List<AreaGridListBean.RowsBean> rowsBeans) {
|
||||||
|
if (rowsBeans.size() > 0) {
|
||||||
|
mGridList = rowsBeans;
|
||||||
|
if (rowsBeans.size() == 1) {
|
||||||
|
mSelGrid = rowsBeans.get(0);
|
||||||
|
mTvGrid.setText(mSelGrid.getGridName());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onError(@androidx.annotation.NonNull Throwable e) {
|
||||||
|
ExceptionHandler.handleException(e);
|
||||||
|
setStateView(16);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onComplete() {
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
private void onShowDelReason(CensusPersonBean.RowsBean bean, int pos) {
|
private void onShowDelReason(CensusPersonBean.RowsBean bean, int pos) {
|
||||||
CenterBaseInputView intputView = new CenterBaseInputView.DialogBuilder(mActivity).build();
|
CenterBaseInputView intputView = new CenterBaseInputView.DialogBuilder(mActivity).build();
|
||||||
@ -298,6 +459,26 @@ public class CensusBaseSearchActivity extends BaseActivity {
|
|||||||
.navigation();
|
.navigation();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 人口类型
|
||||||
|
*/
|
||||||
|
private void onShowType() {
|
||||||
|
if (mTypePicker == null) {
|
||||||
|
mTypePicker = new OptionsPickerBuilder(mActivity, (o1, o2, o3, v) -> {
|
||||||
|
mSelTypeBean = mTypeList.get(o1);
|
||||||
|
mTvType.setText(mSelTypeBean.getDataName());
|
||||||
|
})
|
||||||
|
.setTitleText("请选择")
|
||||||
|
.setCancelColor(Color.parseColor("#1189FF"))
|
||||||
|
.setSubmitColor(Color.parseColor("#1189FF"))
|
||||||
|
.setTitleColor(Color.parseColor("#1189FF"))
|
||||||
|
.build();
|
||||||
|
mTypePicker.setPicker(mTypeList);
|
||||||
|
}
|
||||||
|
mTypePicker.show();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 显示详情
|
* 显示详情
|
||||||
*/
|
*/
|
||||||
@ -365,13 +546,111 @@ public class CensusBaseSearchActivity extends BaseActivity {
|
|||||||
mTvBaseArea.setText(mBaseInfo.getAreaNames());
|
mTvBaseArea.setText(mBaseInfo.getAreaNames());
|
||||||
mTvBaseGrid.setText(mBaseInfo.getGridName());
|
mTvBaseGrid.setText(mBaseInfo.getGridName());
|
||||||
mTvBaseName.setText(mBaseInfo.getFullName());
|
mTvBaseName.setText(mBaseInfo.getFullName());
|
||||||
mTvBaseFormerName.setText(mBaseInfo.getNameUsedBefore());
|
|
||||||
mTvBaseGender.setText(mBaseInfo.getGenderDictionaryName());
|
mTvBaseGender.setText(mBaseInfo.getGenderDictionaryName());
|
||||||
mTvBaseIdCard.setText(mBaseInfo.getIdCardNumber());//身份证
|
mTvBaseIdCard.setText(mBaseInfo.getIdCardNumber());//身份证
|
||||||
mTvBasePhone.setText(mBaseInfo.getTelephone());//联系电话
|
mTvBasePhone.setText(mBaseInfo.getTelephone());//联系电话
|
||||||
mTvBaseNation.setText(mBaseInfo.getNationDictionaryName());//名族
|
if (!TextUtils.isEmpty(mBaseInfo.getType())) {
|
||||||
mTvBaseRegisterLoc.setText(mBaseInfo.getNativePlaceAddr());//户籍地
|
switch (mBaseInfo.getType()) {
|
||||||
mTvBaseCurAddress.setText(mBaseInfo.getCurrentResidenceAddr());//现住址详情
|
case "1":
|
||||||
|
mTvBaseType.setText("户籍人口");
|
||||||
|
break;
|
||||||
|
case "2":
|
||||||
|
mTvBaseType.setText("常住人口");
|
||||||
|
break;
|
||||||
|
case "3":
|
||||||
|
mTvBaseType.setText("外来人口");
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (mBaseInfo.getGridPersonList() != null && mBaseInfo.getGridPersonList().size() > 0) {
|
||||||
|
mRlvGrid.setVisibility(View.VISIBLE);
|
||||||
|
mTvGridsListHint.setVisibility(View.GONE);
|
||||||
|
GridTextAdapter adapter = new GridTextAdapter(mActivity, mBaseInfo.getGridPersonList());
|
||||||
|
mRlvGrid.setLayoutManager(new LinearLayoutManager(mActivity));
|
||||||
|
mRlvGrid.setAdapter(adapter);
|
||||||
|
adapter.addOnItemClickListener(gridPersonListBean -> {
|
||||||
|
if (!TextUtils.isEmpty(gridPersonListBean.getGridUserPhone())) {
|
||||||
|
doCall(gridPersonListBean.getGridUserPhone());
|
||||||
|
}
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
mTvGridsListHint.setVisibility(View.VISIBLE);
|
||||||
|
mRlvGrid.setVisibility(View.GONE);
|
||||||
|
}
|
||||||
|
//判断是自己网格 别人网格 无网格
|
||||||
|
if (TextUtils.isEmpty(mBaseInfo.getGridId())) {
|
||||||
|
//无网格
|
||||||
|
mLlEdit.setVisibility(View.VISIBLE);
|
||||||
|
mTvGridHint.setVisibility(View.GONE);
|
||||||
|
} else {
|
||||||
|
if (mGridList != null && mGridList.size() > 0) {
|
||||||
|
boolean flag = false;
|
||||||
|
for (int i = 0; i < mGridList.size(); i++) {
|
||||||
|
if (mGridList.get(i).getGridId().equals(mBaseInfo.getGridId())) {
|
||||||
|
flag = true;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (flag) {
|
||||||
|
//自己网格
|
||||||
|
mLlEdit.setVisibility(View.VISIBLE);
|
||||||
|
mTvGridHint.setVisibility(View.GONE);
|
||||||
|
} else {
|
||||||
|
//别人
|
||||||
|
mLlEdit.setVisibility(View.GONE);
|
||||||
|
mTvGridHint.setVisibility(View.VISIBLE);
|
||||||
|
mTvGridHint.setText("该人员已绑定至" + mBaseInfo.getAreaNames() + "/" + mBaseInfo.getGridName() + "下," +
|
||||||
|
"如绑定错误,请联系现在绑定的网格员进行解绑。");
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
mTvGridHint.setVisibility(View.GONE);
|
||||||
|
mLlEdit.setVisibility(View.GONE);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void doCall(String gridUserPhone) {
|
||||||
|
if (!TextUtils.isEmpty(gridUserPhone)) {
|
||||||
|
Intent intent = new Intent(Intent.ACTION_DIAL);
|
||||||
|
Uri data = Uri.parse("tel:" + gridUserPhone);
|
||||||
|
intent.setData(data);
|
||||||
|
startActivity(intent);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private boolean checkParams() {
|
||||||
|
if (mSelGrid == null) {
|
||||||
|
ToastUtils.show("请选择所属网格");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if (mSelTypeBean == null) {
|
||||||
|
ToastUtils.show("请选择人员类型");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
private RequestBody buildParams() {
|
||||||
|
SavePersonBean bean = new SavePersonBean();
|
||||||
|
bean.setGridName(mSelGrid.getGridName());
|
||||||
|
bean.setGridId(mSelGrid.getGridId());
|
||||||
|
bean.setType(mSelTypeBean.getDataId());
|
||||||
|
Gson gson = new Gson();
|
||||||
|
String obj = gson.toJson(bean);
|
||||||
|
RequestBody requestBody = RequestBody.create(obj, MediaType.parse("application/json; charset=utf-8"));
|
||||||
|
return requestBody;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 显示网格员电话列表
|
||||||
|
*/
|
||||||
|
private void onShowGridPhone(List<PersonSearchBean.GridPersonListBean> list) {
|
||||||
|
CenterGridPhoneListView intputView = new CenterGridPhoneListView.DialogBuilder(mActivity)
|
||||||
|
.setList(list)
|
||||||
|
.build();
|
||||||
|
intputView.show();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -2,6 +2,7 @@ package com.tengshisoft.gridmodule.incident.activitys.populace;
|
|||||||
|
|
||||||
import android.app.AlertDialog;
|
import android.app.AlertDialog;
|
||||||
import android.app.ProgressDialog;
|
import android.app.ProgressDialog;
|
||||||
|
import android.content.Intent;
|
||||||
import android.graphics.Color;
|
import android.graphics.Color;
|
||||||
import android.text.TextUtils;
|
import android.text.TextUtils;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
@ -9,9 +10,11 @@ import android.view.inputmethod.EditorInfo;
|
|||||||
import android.widget.Button;
|
import android.widget.Button;
|
||||||
import android.widget.EditText;
|
import android.widget.EditText;
|
||||||
import android.widget.ImageView;
|
import android.widget.ImageView;
|
||||||
|
import android.widget.LinearLayout;
|
||||||
import android.widget.ProgressBar;
|
import android.widget.ProgressBar;
|
||||||
import android.widget.TextView;
|
import android.widget.TextView;
|
||||||
|
|
||||||
|
import androidx.annotation.Nullable;
|
||||||
import androidx.recyclerview.widget.LinearLayoutManager;
|
import androidx.recyclerview.widget.LinearLayoutManager;
|
||||||
import androidx.recyclerview.widget.RecyclerView;
|
import androidx.recyclerview.widget.RecyclerView;
|
||||||
|
|
||||||
@ -20,13 +23,16 @@ import com.alibaba.android.arouter.launcher.ARouter;
|
|||||||
import com.hjq.toast.ToastUtils;
|
import com.hjq.toast.ToastUtils;
|
||||||
import com.scwang.smart.refresh.layout.SmartRefreshLayout;
|
import com.scwang.smart.refresh.layout.SmartRefreshLayout;
|
||||||
import com.tengshisoft.commonmodule.adapters.CensusPersonAdapter;
|
import com.tengshisoft.commonmodule.adapters.CensusPersonAdapter;
|
||||||
|
import com.tengshisoft.commonmodule.beans.AreaGridListBean;
|
||||||
import com.tengshisoft.commonmodule.beans.CensusPersonBean;
|
import com.tengshisoft.commonmodule.beans.CensusPersonBean;
|
||||||
import com.tengshisoft.commonmodule.beans.SuccessBean;
|
import com.tengshisoft.commonmodule.beans.SuccessBean;
|
||||||
import com.tengshisoft.commonmodule.nets.GridApis;
|
import com.tengshisoft.commonmodule.nets.GridApis;
|
||||||
|
import com.tengshisoft.commonmodule.views.ConditionAreaGridPopup;
|
||||||
import com.tengshisoft.gridmodule.R;
|
import com.tengshisoft.gridmodule.R;
|
||||||
import com.tengshisoft.gridmodule.R2;
|
import com.tengshisoft.gridmodule.R2;
|
||||||
import com.tenlionsoft.baselib.constant.PathConfig;
|
import com.tenlionsoft.baselib.constant.PathConfig;
|
||||||
import com.tenlionsoft.baselib.core.retrofit_net.RetrofitManager;
|
import com.tenlionsoft.baselib.core.retrofit_net.RetrofitManager;
|
||||||
|
import com.tenlionsoft.baselib.core.retrofit_net.conver.RxTransformer;
|
||||||
import com.tenlionsoft.baselib.core.widget.base.BaseActivity;
|
import com.tenlionsoft.baselib.core.widget.base.BaseActivity;
|
||||||
import com.tenlionsoft.baselib.core.widget.views.CenterBaseInputView;
|
import com.tenlionsoft.baselib.core.widget.views.CenterBaseInputView;
|
||||||
import com.tenlionsoft.baselib.core.widget.views.ItemSplitDivider;
|
import com.tenlionsoft.baselib.core.widget.views.ItemSplitDivider;
|
||||||
@ -67,6 +73,10 @@ public class CensusExitrActivity extends BaseActivity {
|
|||||||
EditText mEtSearchCentent;
|
EditText mEtSearchCentent;
|
||||||
@BindView(R2.id.iv_clear)
|
@BindView(R2.id.iv_clear)
|
||||||
ImageView mIvClear;
|
ImageView mIvClear;
|
||||||
|
@BindView(R2.id.tv_grid)
|
||||||
|
TextView mTvGrid;
|
||||||
|
@BindView(R2.id.ll_grid)
|
||||||
|
LinearLayout mLlGrid;
|
||||||
private Unbinder mBind;
|
private Unbinder mBind;
|
||||||
private int mCurPage = 1;
|
private int mCurPage = 1;
|
||||||
private CensusPersonAdapter mAdapter;
|
private CensusPersonAdapter mAdapter;
|
||||||
@ -131,7 +141,7 @@ public class CensusExitrActivity extends BaseActivity {
|
|||||||
});
|
});
|
||||||
refreshView(STATE_LOAD_SUCCESS);
|
refreshView(STATE_LOAD_SUCCESS);
|
||||||
setStateView(13);
|
setStateView(13);
|
||||||
refreshData();
|
getMineGridList();
|
||||||
|
|
||||||
mEtSearchCentent.setOnEditorActionListener((v, actionId, event) -> {
|
mEtSearchCentent.setOnEditorActionListener((v, actionId, event) -> {
|
||||||
if (actionId == EditorInfo.IME_ACTION_SEARCH) {
|
if (actionId == EditorInfo.IME_ACTION_SEARCH) {
|
||||||
@ -163,7 +173,7 @@ public class CensusExitrActivity extends BaseActivity {
|
|||||||
mKeywords = "";
|
mKeywords = "";
|
||||||
refreshData();
|
refreshData();
|
||||||
});
|
});
|
||||||
|
mTvGrid.setOnClickListener(v -> onShowGrid());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -255,7 +265,7 @@ public class CensusExitrActivity extends BaseActivity {
|
|||||||
.build(PathConfig.PATH_MODULE_GRID_ACTIVITY_POPULACE_BASE_ADD)
|
.build(PathConfig.PATH_MODULE_GRID_ACTIVITY_POPULACE_BASE_ADD)
|
||||||
.withString("title", "人口基础信息编辑")
|
.withString("title", "人口基础信息编辑")
|
||||||
.withString("id", bean.getBasePopulationInfoId())
|
.withString("id", bean.getBasePopulationInfoId())
|
||||||
.navigation();
|
.navigation(mActivity,12);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -267,7 +277,88 @@ public class CensusExitrActivity extends BaseActivity {
|
|||||||
ARouter.getInstance()
|
ARouter.getInstance()
|
||||||
.build(PathConfig.PATH_MODULE_GRID_ACTIVITY_POPULACE_BASE_DETAIL)
|
.build(PathConfig.PATH_MODULE_GRID_ACTIVITY_POPULACE_BASE_DETAIL)
|
||||||
.withString("id", bean.getBasePopulationInfoId())
|
.withString("id", bean.getBasePopulationInfoId())
|
||||||
.navigation();
|
.navigation(mActivity,12);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private List<AreaGridListBean.RowsBean> mGridList;
|
||||||
|
private AreaGridListBean.RowsBean mSelGrid;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 选择网格
|
||||||
|
*/
|
||||||
|
private void onShowGrid() {
|
||||||
|
ConditionAreaGridPopup conditionPopup = new ConditionAreaGridPopup(mActivity, mGridList);
|
||||||
|
conditionPopup.setOnListPopupItemClickListener((bean, isCheck, pos) -> {
|
||||||
|
if (isCheck) {
|
||||||
|
//选中了
|
||||||
|
mSelGrid = bean;
|
||||||
|
mTvGrid.setText(mSelGrid.getGridName());
|
||||||
|
} else {
|
||||||
|
//清除了选项
|
||||||
|
mSelGrid = null;
|
||||||
|
mTvGrid.setText("网格");
|
||||||
|
}
|
||||||
|
refreshData();
|
||||||
|
conditionPopup.dismiss();
|
||||||
|
});
|
||||||
|
conditionPopup.showPopupWindow(mTvGrid);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private void getMineGridList() {
|
||||||
|
RetrofitManager.getInstance()
|
||||||
|
.create(GridApis.class)
|
||||||
|
.getMineGridList(UserLgUtils.getToken())
|
||||||
|
.compose(RxTransformer.getTransformer())
|
||||||
|
.subscribe(new Observer<List<AreaGridListBean.RowsBean>>() {
|
||||||
|
@Override
|
||||||
|
public void onSubscribe(@androidx.annotation.NonNull Disposable d) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onNext(@androidx.annotation.NonNull List<AreaGridListBean.RowsBean> rowsBeans) {
|
||||||
|
if (rowsBeans.size() > 0) {
|
||||||
|
mGridList = rowsBeans;
|
||||||
|
mSelGrid = mGridList.get(0);
|
||||||
|
if (mGridList.size() > 1) {
|
||||||
|
mGridList.get(0).setCheck(true);
|
||||||
|
mLlGrid.setVisibility(View.VISIBLE);
|
||||||
|
mTvGrid.setText(mSelGrid.getGridName());
|
||||||
|
} else {
|
||||||
|
mLlGrid.setVisibility(View.GONE);
|
||||||
|
}
|
||||||
|
refreshData();
|
||||||
|
} else {
|
||||||
|
mLlGrid.setVisibility(View.GONE);
|
||||||
|
ToastUtils.show("您暂未分配网格");
|
||||||
|
setStateView(15);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onError(@androidx.annotation.NonNull Throwable e) {
|
||||||
|
ExceptionHandler.handleException(e);
|
||||||
|
setStateView(16);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onComplete() {
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onActivityResult(int requestCode, int resultCode, @Nullable Intent data) {
|
||||||
|
if (requestCode == 12) {
|
||||||
|
if (resultCode == 13) {
|
||||||
|
refreshData();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
super.onActivityResult(requestCode, resultCode, data);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -281,6 +372,7 @@ public class CensusExitrActivity extends BaseActivity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void refreshData() {
|
private void refreshData() {
|
||||||
|
setStateView(13);
|
||||||
getUpcomingList(1, null);
|
getUpcomingList(1, null);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -296,7 +388,7 @@ public class CensusExitrActivity extends BaseActivity {
|
|||||||
mCurPage = page;
|
mCurPage = page;
|
||||||
RetrofitManager.getInstance()
|
RetrofitManager.getInstance()
|
||||||
.create(GridApis.class)
|
.create(GridApis.class)
|
||||||
.getBaseInfoList(page + "", mKeywords, "3", UserLgUtils.getToken())
|
.getBaseInfoList(mSelGrid ==null? "":mSelGrid.getGridId(),page + "", mKeywords, "3", UserLgUtils.getToken())
|
||||||
.subscribeOn(Schedulers.io())
|
.subscribeOn(Schedulers.io())
|
||||||
.observeOn(AndroidSchedulers.mainThread())
|
.observeOn(AndroidSchedulers.mainThread())
|
||||||
.subscribe(new Observer<CensusPersonBean>() {
|
.subscribe(new Observer<CensusPersonBean>() {
|
||||||
|
@ -2,6 +2,7 @@ package com.tengshisoft.gridmodule.incident.activitys.populace;
|
|||||||
|
|
||||||
import android.app.AlertDialog;
|
import android.app.AlertDialog;
|
||||||
import android.app.ProgressDialog;
|
import android.app.ProgressDialog;
|
||||||
|
import android.content.Intent;
|
||||||
import android.graphics.Color;
|
import android.graphics.Color;
|
||||||
import android.text.TextUtils;
|
import android.text.TextUtils;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
@ -9,9 +10,11 @@ import android.view.inputmethod.EditorInfo;
|
|||||||
import android.widget.Button;
|
import android.widget.Button;
|
||||||
import android.widget.EditText;
|
import android.widget.EditText;
|
||||||
import android.widget.ImageView;
|
import android.widget.ImageView;
|
||||||
|
import android.widget.LinearLayout;
|
||||||
import android.widget.ProgressBar;
|
import android.widget.ProgressBar;
|
||||||
import android.widget.TextView;
|
import android.widget.TextView;
|
||||||
|
|
||||||
|
import androidx.annotation.Nullable;
|
||||||
import androidx.recyclerview.widget.LinearLayoutManager;
|
import androidx.recyclerview.widget.LinearLayoutManager;
|
||||||
import androidx.recyclerview.widget.RecyclerView;
|
import androidx.recyclerview.widget.RecyclerView;
|
||||||
|
|
||||||
@ -20,13 +23,16 @@ import com.alibaba.android.arouter.launcher.ARouter;
|
|||||||
import com.hjq.toast.ToastUtils;
|
import com.hjq.toast.ToastUtils;
|
||||||
import com.scwang.smart.refresh.layout.SmartRefreshLayout;
|
import com.scwang.smart.refresh.layout.SmartRefreshLayout;
|
||||||
import com.tengshisoft.commonmodule.adapters.CensusPersonAdapter;
|
import com.tengshisoft.commonmodule.adapters.CensusPersonAdapter;
|
||||||
|
import com.tengshisoft.commonmodule.beans.AreaGridListBean;
|
||||||
import com.tengshisoft.commonmodule.beans.CensusPersonBean;
|
import com.tengshisoft.commonmodule.beans.CensusPersonBean;
|
||||||
import com.tengshisoft.commonmodule.beans.SuccessBean;
|
import com.tengshisoft.commonmodule.beans.SuccessBean;
|
||||||
import com.tengshisoft.commonmodule.nets.GridApis;
|
import com.tengshisoft.commonmodule.nets.GridApis;
|
||||||
|
import com.tengshisoft.commonmodule.views.ConditionAreaGridPopup;
|
||||||
import com.tengshisoft.gridmodule.R;
|
import com.tengshisoft.gridmodule.R;
|
||||||
import com.tengshisoft.gridmodule.R2;
|
import com.tengshisoft.gridmodule.R2;
|
||||||
import com.tenlionsoft.baselib.constant.PathConfig;
|
import com.tenlionsoft.baselib.constant.PathConfig;
|
||||||
import com.tenlionsoft.baselib.core.retrofit_net.RetrofitManager;
|
import com.tenlionsoft.baselib.core.retrofit_net.RetrofitManager;
|
||||||
|
import com.tenlionsoft.baselib.core.retrofit_net.conver.RxTransformer;
|
||||||
import com.tenlionsoft.baselib.core.widget.base.BaseActivity;
|
import com.tenlionsoft.baselib.core.widget.base.BaseActivity;
|
||||||
import com.tenlionsoft.baselib.core.widget.views.CenterBaseInputView;
|
import com.tenlionsoft.baselib.core.widget.views.CenterBaseInputView;
|
||||||
import com.tenlionsoft.baselib.core.widget.views.ItemSplitDivider;
|
import com.tenlionsoft.baselib.core.widget.views.ItemSplitDivider;
|
||||||
@ -67,6 +73,10 @@ public class CensusResidsActivity extends BaseActivity {
|
|||||||
EditText mEtSearchCentent;
|
EditText mEtSearchCentent;
|
||||||
@BindView(R2.id.iv_clear)
|
@BindView(R2.id.iv_clear)
|
||||||
ImageView mIvClear;
|
ImageView mIvClear;
|
||||||
|
@BindView(R2.id.tv_grid)
|
||||||
|
TextView mTvGrid;
|
||||||
|
@BindView(R2.id.ll_grid)
|
||||||
|
LinearLayout mLlGrid;
|
||||||
private Unbinder mBind;
|
private Unbinder mBind;
|
||||||
private int mCurPage = 1;
|
private int mCurPage = 1;
|
||||||
private CensusPersonAdapter mAdapter;
|
private CensusPersonAdapter mAdapter;
|
||||||
@ -99,7 +109,7 @@ public class CensusResidsActivity extends BaseActivity {
|
|||||||
@Override
|
@Override
|
||||||
public void initData() {
|
public void initData() {
|
||||||
mBind = ButterKnife.bind(this);
|
mBind = ButterKnife.bind(this);
|
||||||
mTvBaseTitle.setText("外来人口");
|
mTvBaseTitle.setText("常住人口");
|
||||||
mTvPublish.setVisibility(View.VISIBLE);
|
mTvPublish.setVisibility(View.VISIBLE);
|
||||||
mIvAppSearchIcon.setVisibility(View.VISIBLE);
|
mIvAppSearchIcon.setVisibility(View.VISIBLE);
|
||||||
mTvPublish.setText("新增");
|
mTvPublish.setText("新增");
|
||||||
@ -131,7 +141,7 @@ public class CensusResidsActivity extends BaseActivity {
|
|||||||
});
|
});
|
||||||
refreshView(STATE_LOAD_SUCCESS);
|
refreshView(STATE_LOAD_SUCCESS);
|
||||||
setStateView(13);
|
setStateView(13);
|
||||||
refreshData();
|
getMineGridList();
|
||||||
|
|
||||||
mEtSearchCentent.setOnEditorActionListener((v, actionId, event) -> {
|
mEtSearchCentent.setOnEditorActionListener((v, actionId, event) -> {
|
||||||
if (actionId == EditorInfo.IME_ACTION_SEARCH) {
|
if (actionId == EditorInfo.IME_ACTION_SEARCH) {
|
||||||
@ -163,7 +173,7 @@ public class CensusResidsActivity extends BaseActivity {
|
|||||||
mKeywords = "";
|
mKeywords = "";
|
||||||
refreshData();
|
refreshData();
|
||||||
});
|
});
|
||||||
|
mTvGrid.setOnClickListener(v -> onShowGrid());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -255,7 +265,7 @@ public class CensusResidsActivity extends BaseActivity {
|
|||||||
.build(PathConfig.PATH_MODULE_GRID_ACTIVITY_POPULACE_BASE_ADD)
|
.build(PathConfig.PATH_MODULE_GRID_ACTIVITY_POPULACE_BASE_ADD)
|
||||||
.withString("title", "人口基础信息编辑")
|
.withString("title", "人口基础信息编辑")
|
||||||
.withString("id", bean.getBasePopulationInfoId())
|
.withString("id", bean.getBasePopulationInfoId())
|
||||||
.navigation();
|
.navigation(mActivity, 12);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -267,7 +277,7 @@ public class CensusResidsActivity extends BaseActivity {
|
|||||||
ARouter.getInstance()
|
ARouter.getInstance()
|
||||||
.build(PathConfig.PATH_MODULE_GRID_ACTIVITY_POPULACE_BASE_DETAIL)
|
.build(PathConfig.PATH_MODULE_GRID_ACTIVITY_POPULACE_BASE_DETAIL)
|
||||||
.withString("id", bean.getBasePopulationInfoId())
|
.withString("id", bean.getBasePopulationInfoId())
|
||||||
.navigation();
|
.navigation(mActivity, 12);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -281,6 +291,7 @@ public class CensusResidsActivity extends BaseActivity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void refreshData() {
|
private void refreshData() {
|
||||||
|
setStateView(13);
|
||||||
getUpcomingList(1, null);
|
getUpcomingList(1, null);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -289,6 +300,86 @@ public class CensusResidsActivity extends BaseActivity {
|
|||||||
super.onResume();
|
super.onResume();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private List<AreaGridListBean.RowsBean> mGridList;
|
||||||
|
private AreaGridListBean.RowsBean mSelGrid;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 选择网格
|
||||||
|
*/
|
||||||
|
private void onShowGrid() {
|
||||||
|
ConditionAreaGridPopup conditionPopup = new ConditionAreaGridPopup(mActivity, mGridList);
|
||||||
|
conditionPopup.setOnListPopupItemClickListener((bean, isCheck, pos) -> {
|
||||||
|
if (isCheck) {
|
||||||
|
//选中了
|
||||||
|
mSelGrid = bean;
|
||||||
|
mTvGrid.setText(mSelGrid.getGridName());
|
||||||
|
} else {
|
||||||
|
//清除了选项
|
||||||
|
mSelGrid = null;
|
||||||
|
mTvGrid.setText("网格");
|
||||||
|
}
|
||||||
|
refreshData();
|
||||||
|
conditionPopup.dismiss();
|
||||||
|
});
|
||||||
|
conditionPopup.showPopupWindow(mTvGrid);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private void getMineGridList() {
|
||||||
|
RetrofitManager.getInstance()
|
||||||
|
.create(GridApis.class)
|
||||||
|
.getMineGridList(UserLgUtils.getToken())
|
||||||
|
.compose(RxTransformer.getTransformer())
|
||||||
|
.subscribe(new Observer<List<AreaGridListBean.RowsBean>>() {
|
||||||
|
@Override
|
||||||
|
public void onSubscribe(@androidx.annotation.NonNull Disposable d) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onNext(@androidx.annotation.NonNull List<AreaGridListBean.RowsBean> rowsBeans) {
|
||||||
|
if (rowsBeans.size() > 0) {
|
||||||
|
mGridList = rowsBeans;
|
||||||
|
mSelGrid = mGridList.get(0);
|
||||||
|
if (mGridList.size() > 1) {
|
||||||
|
mGridList.get(0).setCheck(true);
|
||||||
|
mLlGrid.setVisibility(View.VISIBLE);
|
||||||
|
mTvGrid.setText(mSelGrid.getGridName());
|
||||||
|
} else {
|
||||||
|
mLlGrid.setVisibility(View.GONE);
|
||||||
|
}
|
||||||
|
refreshData();
|
||||||
|
} else {
|
||||||
|
mLlGrid.setVisibility(View.GONE);
|
||||||
|
ToastUtils.show("您暂未分配网格");
|
||||||
|
setStateView(15);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onError(@androidx.annotation.NonNull Throwable e) {
|
||||||
|
ExceptionHandler.handleException(e);
|
||||||
|
setStateView(16);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onComplete() {
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onActivityResult(int requestCode, int resultCode, @Nullable Intent data) {
|
||||||
|
if (requestCode == 12) {
|
||||||
|
if (resultCode == 13) {
|
||||||
|
refreshData();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
super.onActivityResult(requestCode, resultCode, data);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取列表
|
* 获取列表
|
||||||
*/
|
*/
|
||||||
@ -296,7 +387,8 @@ public class CensusResidsActivity extends BaseActivity {
|
|||||||
mCurPage = page;
|
mCurPage = page;
|
||||||
RetrofitManager.getInstance()
|
RetrofitManager.getInstance()
|
||||||
.create(GridApis.class)
|
.create(GridApis.class)
|
||||||
.getBaseInfoList(page + "", mKeywords, "2", UserLgUtils.getToken())
|
.getBaseInfoList(mSelGrid == null ? "" : mSelGrid.getGridId(), page + "", mKeywords, "2",
|
||||||
|
UserLgUtils.getToken())
|
||||||
.subscribeOn(Schedulers.io())
|
.subscribeOn(Schedulers.io())
|
||||||
.observeOn(AndroidSchedulers.mainThread())
|
.observeOn(AndroidSchedulers.mainThread())
|
||||||
.subscribe(new Observer<CensusPersonBean>() {
|
.subscribe(new Observer<CensusPersonBean>() {
|
||||||
|
@ -233,6 +233,8 @@ public class CensusYoungListActivity extends BaseActivity {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onNext(CensusYoungListBean leaveListBean) {
|
public void onNext(CensusYoungListBean leaveListBean) {
|
||||||
|
mSrlContent.finishLoadMore();
|
||||||
|
mSrlContent.finishRefresh();
|
||||||
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
||||||
++mCurPage;
|
++mCurPage;
|
||||||
if (page == 1) {
|
if (page == 1) {
|
||||||
@ -252,7 +254,7 @@ public class CensusYoungListActivity extends BaseActivity {
|
|||||||
mSrlContent.setNoMoreData(false);
|
mSrlContent.setNoMoreData(false);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
mSrlContent.finishLoadMore();
|
|
||||||
mSrlContent.setNoMoreData(true);
|
mSrlContent.setNoMoreData(true);
|
||||||
if (page > 1) {
|
if (page > 1) {
|
||||||
refreshView(STATE_LOAD_SUCCESS);
|
refreshView(STATE_LOAD_SUCCESS);
|
||||||
|
@ -172,6 +172,8 @@ public class YoungCaseListActivity extends BaseActivity {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onNext(@NonNull YoungCaseListBean communityListBean) {
|
public void onNext(@NonNull YoungCaseListBean communityListBean) {
|
||||||
|
mSrlContent.finishLoadMore();
|
||||||
|
mSrlContent.finishRefresh();
|
||||||
if (mDialog != null && mDialog.isShowing()) {
|
if (mDialog != null && mDialog.isShowing()) {
|
||||||
mDialog.dismiss();
|
mDialog.dismiss();
|
||||||
}
|
}
|
||||||
|
@ -236,6 +236,8 @@ public class CensusMigrantListActivity extends BaseActivity {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onNext(MigrantListBean leaveListBean) {
|
public void onNext(MigrantListBean leaveListBean) {
|
||||||
|
mSrlContent.finishLoadMore();
|
||||||
|
mSrlContent.finishRefresh();
|
||||||
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
||||||
++mCurPage;
|
++mCurPage;
|
||||||
if (page == 1) {
|
if (page == 1) {
|
||||||
|
@ -231,6 +231,8 @@ public class CensusRearListActivity extends BaseActivity {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onNext(RearListBean leaveListBean) {
|
public void onNext(RearListBean leaveListBean) {
|
||||||
|
mSrlContent.finishLoadMore();
|
||||||
|
mSrlContent.finishRefresh();
|
||||||
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
||||||
++mCurPage;
|
++mCurPage;
|
||||||
if (page == 1) {
|
if (page == 1) {
|
||||||
|
@ -235,6 +235,8 @@ public class CensusRegisterListActivity extends BaseActivity {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onNext(CensusRegisterListBean leaveListBean) {
|
public void onNext(CensusRegisterListBean leaveListBean) {
|
||||||
|
mSrlContent.finishLoadMore();
|
||||||
|
mSrlContent.finishRefresh();
|
||||||
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
||||||
++mCurPage;
|
++mCurPage;
|
||||||
if (page == 1) {
|
if (page == 1) {
|
||||||
|
@ -236,6 +236,8 @@ public class CensusOutboundListActivity extends BaseActivity {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onNext(OutboundListBean leaveListBean) {
|
public void onNext(OutboundListBean leaveListBean) {
|
||||||
|
mSrlContent.finishLoadMore();
|
||||||
|
mSrlContent.finishRefresh();
|
||||||
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
||||||
++mCurPage;
|
++mCurPage;
|
||||||
if (page == 1) {
|
if (page == 1) {
|
||||||
|
@ -237,6 +237,8 @@ public class CensusAidsListActivity extends BaseActivity {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onNext(CensusAidsListBean leaveListBean) {
|
public void onNext(CensusAidsListBean leaveListBean) {
|
||||||
|
mSrlContent.finishLoadMore();
|
||||||
|
mSrlContent.finishRefresh();
|
||||||
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
||||||
++mCurPage;
|
++mCurPage;
|
||||||
if (page == 1) {
|
if (page == 1) {
|
||||||
|
@ -237,6 +237,8 @@ public class CensusCorrctListActivity extends BaseActivity {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onNext(CensusCorrectListBean leaveListBean) {
|
public void onNext(CensusCorrectListBean leaveListBean) {
|
||||||
|
mSrlContent.finishLoadMore();
|
||||||
|
mSrlContent.finishRefresh();
|
||||||
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
||||||
++mCurPage;
|
++mCurPage;
|
||||||
if (page == 1) {
|
if (page == 1) {
|
||||||
|
@ -234,6 +234,8 @@ public class CensusDrugListActivity extends BaseActivity {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onNext(CensusDrugListBean leaveListBean) {
|
public void onNext(CensusDrugListBean leaveListBean) {
|
||||||
|
mSrlContent.finishLoadMore();
|
||||||
|
mSrlContent.finishRefresh();
|
||||||
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
||||||
++mCurPage;
|
++mCurPage;
|
||||||
if (page == 1) {
|
if (page == 1) {
|
||||||
|
@ -237,6 +237,8 @@ public class CensusSpecialCriminalListActivity extends BaseActivity {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onNext(CensusCriminalListBean leaveListBean) {
|
public void onNext(CensusCriminalListBean leaveListBean) {
|
||||||
|
mSrlContent.finishLoadMore();
|
||||||
|
mSrlContent.finishRefresh();
|
||||||
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
||||||
++mCurPage;
|
++mCurPage;
|
||||||
if (page == 1) {
|
if (page == 1) {
|
||||||
|
@ -234,6 +234,8 @@ public class CensusTroubleListActivity extends BaseActivity {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onNext(CensusTroubleListBean leaveListBean) {
|
public void onNext(CensusTroubleListBean leaveListBean) {
|
||||||
|
mSrlContent.finishLoadMore();
|
||||||
|
mSrlContent.finishRefresh();
|
||||||
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
if (leaveListBean != null && leaveListBean.getRows() != null && leaveListBean.getRows().size() > 0) {
|
||||||
++mCurPage;
|
++mCurPage;
|
||||||
if (page == 1) {
|
if (page == 1) {
|
||||||
|
@ -31,62 +31,104 @@
|
|||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="10dp"
|
android:layout_marginTop="10dp"
|
||||||
android:gravity="center_vertical"
|
android:orientation="vertical">
|
||||||
android:orientation="horizontal">
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="0dp"
|
android:id="@+id/ll_grid"
|
||||||
android:layout_height="35dp"
|
android:layout_width="match_parent"
|
||||||
android:layout_marginLeft="10dp"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginRight="10dp"
|
android:orientation="horizontal"
|
||||||
android:layout_weight="1"
|
android:paddingLeft="15dp"
|
||||||
android:background="@drawable/shp_rectangle_white_01"
|
android:paddingRight="15dp">
|
||||||
|
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="所属网格:"
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="@dimen/text_14" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_grid"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:clickable="true"
|
||||||
|
android:drawableRight="@drawable/ic_arrow_sort_gray"
|
||||||
|
android:focusable="true"
|
||||||
|
android:gravity="center"
|
||||||
|
android:maxLines="1"
|
||||||
|
android:minWidth="100dp"
|
||||||
|
android:paddingTop="5dp"
|
||||||
|
android:paddingBottom="5dp"
|
||||||
|
android:text="网格"
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="14dp"
|
||||||
|
android:textStyle="bold" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
android:gravity="center_vertical"
|
android:gravity="center_vertical"
|
||||||
android:orientation="horizontal">
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
<EditText
|
|
||||||
android:id="@+id/et_search_centent"
|
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="35dp"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginRight="10dp"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:background="@null"
|
android:background="@drawable/shp_rectangle_white_01"
|
||||||
android:drawableLeft="@color/line"
|
android:gravity="center_vertical"
|
||||||
android:gravity="left|center"
|
android:orientation="horizontal">
|
||||||
android:hint="请输入关键字进行搜索"
|
|
||||||
android:imeOptions="actionSearch"
|
|
||||||
android:inputType="text"
|
<EditText
|
||||||
android:paddingLeft="5dp"
|
android:id="@+id/et_search_centent"
|
||||||
android:textColor="@color/black"
|
android:layout_width="0dp"
|
||||||
android:textSize="12sp"
|
android:layout_height="match_parent"
|
||||||
tools:text="" />
|
android:layout_weight="1"
|
||||||
|
android:background="@null"
|
||||||
|
android:drawableLeft="@color/line"
|
||||||
|
android:gravity="left|center"
|
||||||
|
android:hint="请输入关键字进行搜索"
|
||||||
|
android:imeOptions="actionSearch"
|
||||||
|
android:inputType="text"
|
||||||
|
android:paddingLeft="5dp"
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="12sp"
|
||||||
|
tools:text="" />
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/iv_clear"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:padding="8dp"
|
||||||
|
android:src="@drawable/ic_clear_edit" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/btn_page_search"
|
||||||
|
android:layout_width="58dp"
|
||||||
|
android:layout_height="30dp"
|
||||||
|
android:layout_marginRight="10dp"
|
||||||
|
android:background="@drawable/sel_btn_submit"
|
||||||
|
android:text="搜索"
|
||||||
|
android:textColor="@color/white" />
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:id="@+id/iv_clear"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:padding="8dp"
|
|
||||||
android:src="@drawable/ic_clear_edit" />
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<Button
|
|
||||||
android:id="@+id/btn_page_search"
|
|
||||||
android:layout_width="58dp"
|
|
||||||
android:layout_height="30dp"
|
|
||||||
android:layout_marginRight="10dp"
|
|
||||||
android:background="@drawable/sel_btn_submit"
|
|
||||||
android:text="搜索"
|
|
||||||
android:textColor="@color/white" />
|
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
<com.scwang.smart.refresh.layout.SmartRefreshLayout
|
<com.scwang.smart.refresh.layout.SmartRefreshLayout
|
||||||
android:id="@+id/srl_content"
|
android:id="@+id/srl_content"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
tools:visibility="gone"
|
android:layout_marginTop="10dp"
|
||||||
android:layout_marginTop="10dp">
|
tools:visibility="gone">
|
||||||
|
|
||||||
<androidx.recyclerview.widget.RecyclerView
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
android:id="@+id/rlv_persons"
|
android:id="@+id/rlv_persons"
|
||||||
|
@ -293,7 +293,7 @@
|
|||||||
android:layout_marginLeft="10dp"
|
android:layout_marginLeft="10dp"
|
||||||
android:layout_marginRight="10dp"
|
android:layout_marginRight="10dp"
|
||||||
android:background="@drawable/sel_btn_gray_red"
|
android:background="@drawable/sel_btn_gray_red"
|
||||||
android:text="删除"
|
android:text="解绑"
|
||||||
android:textColor="@color/black" />
|
android:textColor="@color/black" />
|
||||||
|
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
@ -31,62 +31,102 @@
|
|||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="10dp"
|
android:layout_marginTop="10dp"
|
||||||
android:gravity="center_vertical"
|
android:orientation="vertical">
|
||||||
android:orientation="horizontal">
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="0dp"
|
android:id="@+id/ll_grid"
|
||||||
android:layout_height="35dp"
|
android:layout_width="match_parent"
|
||||||
android:layout_marginLeft="10dp"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginRight="10dp"
|
android:orientation="horizontal"
|
||||||
android:layout_weight="1"
|
android:paddingLeft="15dp"
|
||||||
android:background="@drawable/shp_rectangle_white_01"
|
android:paddingRight="15dp">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="所属网格:"
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="@dimen/text_14" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_grid"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:clickable="true"
|
||||||
|
android:drawableRight="@drawable/ic_arrow_sort_gray"
|
||||||
|
android:focusable="true"
|
||||||
|
android:gravity="center"
|
||||||
|
android:maxLines="1"
|
||||||
|
android:minWidth="100dp"
|
||||||
|
android:paddingTop="5dp"
|
||||||
|
android:paddingBottom="5dp"
|
||||||
|
android:text="网格"
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="14dp"
|
||||||
|
android:textStyle="bold" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
android:gravity="center_vertical"
|
android:gravity="center_vertical"
|
||||||
android:orientation="horizontal">
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
<EditText
|
|
||||||
android:id="@+id/et_search_centent"
|
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="35dp"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginRight="10dp"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:background="@null"
|
android:background="@drawable/shp_rectangle_white_01"
|
||||||
android:drawableLeft="@color/line"
|
android:gravity="center_vertical"
|
||||||
android:gravity="left|center"
|
android:orientation="horizontal">
|
||||||
android:hint="请输入关键字进行搜索"
|
|
||||||
android:imeOptions="actionSearch"
|
|
||||||
android:inputType="text"
|
<EditText
|
||||||
android:paddingLeft="5dp"
|
android:id="@+id/et_search_centent"
|
||||||
android:textColor="@color/black"
|
android:layout_width="0dp"
|
||||||
android:textSize="12sp"
|
android:layout_height="match_parent"
|
||||||
tools:text="" />
|
android:layout_weight="1"
|
||||||
|
android:background="@null"
|
||||||
|
android:drawableLeft="@color/line"
|
||||||
|
android:gravity="left|center"
|
||||||
|
android:hint="请输入关键字进行搜索"
|
||||||
|
android:imeOptions="actionSearch"
|
||||||
|
android:inputType="text"
|
||||||
|
android:paddingLeft="5dp"
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="12sp"
|
||||||
|
tools:text="" />
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/iv_clear"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:padding="8dp"
|
||||||
|
android:src="@drawable/ic_clear_edit" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/btn_page_search"
|
||||||
|
android:layout_width="58dp"
|
||||||
|
android:layout_height="30dp"
|
||||||
|
android:layout_marginRight="10dp"
|
||||||
|
android:background="@drawable/sel_btn_submit"
|
||||||
|
android:text="搜索"
|
||||||
|
android:textColor="@color/white" />
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:id="@+id/iv_clear"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:padding="8dp"
|
|
||||||
android:src="@drawable/ic_clear_edit" />
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<Button
|
|
||||||
android:id="@+id/btn_page_search"
|
|
||||||
android:layout_width="58dp"
|
|
||||||
android:layout_height="30dp"
|
|
||||||
android:layout_marginRight="10dp"
|
|
||||||
android:background="@drawable/sel_btn_submit"
|
|
||||||
android:text="搜索"
|
|
||||||
android:textColor="@color/white" />
|
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
<com.scwang.smart.refresh.layout.SmartRefreshLayout
|
<com.scwang.smart.refresh.layout.SmartRefreshLayout
|
||||||
android:id="@+id/srl_content"
|
android:id="@+id/srl_content"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
tools:visibility="gone"
|
android:layout_marginTop="10dp"
|
||||||
android:layout_marginTop="10dp">
|
tools:visibility="gone">
|
||||||
|
|
||||||
<androidx.recyclerview.widget.RecyclerView
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
android:id="@+id/rlv_persons"
|
android:id="@+id/rlv_persons"
|
||||||
|
@ -31,62 +31,102 @@
|
|||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="10dp"
|
android:layout_marginTop="10dp"
|
||||||
android:gravity="center_vertical"
|
android:orientation="vertical">
|
||||||
android:orientation="horizontal">
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="0dp"
|
android:id="@+id/ll_grid"
|
||||||
android:layout_height="35dp"
|
android:layout_width="match_parent"
|
||||||
android:layout_marginLeft="10dp"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginRight="10dp"
|
android:orientation="horizontal"
|
||||||
android:layout_weight="1"
|
android:paddingLeft="15dp"
|
||||||
android:background="@drawable/shp_rectangle_white_01"
|
android:paddingRight="15dp">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="所属网格:"
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="@dimen/text_14" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_grid"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:clickable="true"
|
||||||
|
android:drawableRight="@drawable/ic_arrow_sort_gray"
|
||||||
|
android:focusable="true"
|
||||||
|
android:gravity="center"
|
||||||
|
android:maxLines="1"
|
||||||
|
android:minWidth="100dp"
|
||||||
|
android:paddingTop="5dp"
|
||||||
|
android:paddingBottom="5dp"
|
||||||
|
android:text="网格"
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="14dp"
|
||||||
|
android:textStyle="bold" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
android:gravity="center_vertical"
|
android:gravity="center_vertical"
|
||||||
android:orientation="horizontal">
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
<EditText
|
|
||||||
android:id="@+id/et_search_centent"
|
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="35dp"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginRight="10dp"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:background="@null"
|
android:background="@drawable/shp_rectangle_white_01"
|
||||||
android:drawableLeft="@color/line"
|
android:gravity="center_vertical"
|
||||||
android:gravity="left|center"
|
android:orientation="horizontal">
|
||||||
android:hint="请输入关键字进行搜索"
|
|
||||||
android:imeOptions="actionSearch"
|
|
||||||
android:inputType="text"
|
<EditText
|
||||||
android:paddingLeft="5dp"
|
android:id="@+id/et_search_centent"
|
||||||
android:textColor="@color/black"
|
android:layout_width="0dp"
|
||||||
android:textSize="12sp"
|
android:layout_height="match_parent"
|
||||||
tools:text="" />
|
android:layout_weight="1"
|
||||||
|
android:background="@null"
|
||||||
|
android:drawableLeft="@color/line"
|
||||||
|
android:gravity="left|center"
|
||||||
|
android:hint="请输入关键字进行搜索"
|
||||||
|
android:imeOptions="actionSearch"
|
||||||
|
android:inputType="text"
|
||||||
|
android:paddingLeft="5dp"
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="12sp"
|
||||||
|
tools:text="" />
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/iv_clear"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:padding="8dp"
|
||||||
|
android:src="@drawable/ic_clear_edit" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/btn_page_search"
|
||||||
|
android:layout_width="58dp"
|
||||||
|
android:layout_height="30dp"
|
||||||
|
android:layout_marginRight="10dp"
|
||||||
|
android:background="@drawable/sel_btn_submit"
|
||||||
|
android:text="搜索"
|
||||||
|
android:textColor="@color/white" />
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:id="@+id/iv_clear"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:padding="8dp"
|
|
||||||
android:src="@drawable/ic_clear_edit" />
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<Button
|
|
||||||
android:id="@+id/btn_page_search"
|
|
||||||
android:layout_width="58dp"
|
|
||||||
android:layout_height="30dp"
|
|
||||||
android:layout_marginRight="10dp"
|
|
||||||
android:background="@drawable/sel_btn_submit"
|
|
||||||
android:text="搜索"
|
|
||||||
android:textColor="@color/white" />
|
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
<com.scwang.smart.refresh.layout.SmartRefreshLayout
|
<com.scwang.smart.refresh.layout.SmartRefreshLayout
|
||||||
android:id="@+id/srl_content"
|
android:id="@+id/srl_content"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
tools:visibility="gone"
|
android:layout_marginTop="10dp"
|
||||||
android:layout_marginTop="10dp">
|
tools:visibility="gone">
|
||||||
|
|
||||||
<androidx.recyclerview.widget.RecyclerView
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
android:id="@+id/rlv_persons"
|
android:id="@+id/rlv_persons"
|
||||||
|
@ -101,19 +101,55 @@
|
|||||||
<TextView
|
<TextView
|
||||||
style="@style/issue_report_title"
|
style="@style/issue_report_title"
|
||||||
android:padding="8dp"
|
android:padding="8dp"
|
||||||
android:text="基础信息" />
|
android:text="人员信息" />
|
||||||
|
|
||||||
<Button
|
|
||||||
android:id="@+id/btn_edit"
|
|
||||||
android:layout_width="58dp"
|
|
||||||
android:layout_height="30dp"
|
|
||||||
android:layout_alignParentRight="true"
|
|
||||||
android:layout_marginRight="10dp"
|
|
||||||
android:background="@drawable/sel_btn_submit"
|
|
||||||
android:text="编辑"
|
|
||||||
android:textColor="@color/white" />
|
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
|
<LinearLayout style="@style/item_white_vertical">
|
||||||
|
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/item_title_vertical_23"
|
||||||
|
android:layout_gravity="center_vertical"
|
||||||
|
android:text="网格员" />
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginRight="10dp"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
|
android:id="@+id/rlv_grids"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
tools:visibility="gone"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_grids_list_hint"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_centerInParent="true"
|
||||||
|
android:layout_marginStart="10dp"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:layout_marginEnd="10dp"
|
||||||
|
android:layout_marginBottom="10dp"
|
||||||
|
android:text="暂无数据" />
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_grid_hint"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:padding="10dp"
|
||||||
|
android:textColor="@color/red_ff"
|
||||||
|
android:textSize="12dp" />
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout style="@style/item_white">
|
<LinearLayout style="@style/item_white">
|
||||||
|
|
||||||
|
|
||||||
@ -168,16 +204,17 @@
|
|||||||
<TextView
|
<TextView
|
||||||
style="@style/item_title_23"
|
style="@style/item_title_23"
|
||||||
android:layout_gravity="center_vertical"
|
android:layout_gravity="center_vertical"
|
||||||
android:text="曾用名" />
|
android:text="人口类型" />
|
||||||
|
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tv_base_former_name"
|
android:id="@+id/tv_base_type"
|
||||||
style="@style/item_content_23"
|
style="@style/item_content_23"
|
||||||
android:hint="未录入" />
|
android:hint="未录入" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout style="@style/item_white">
|
<LinearLayout style="@style/item_white">
|
||||||
|
|
||||||
|
|
||||||
@ -227,65 +264,82 @@
|
|||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout style="@style/item_white">
|
<!-- <LinearLayout style="@style/item_white">-->
|
||||||
|
|
||||||
<TextView
|
<!-- <TextView-->
|
||||||
style="@style/item_title_23"
|
<!-- style="@style/item_title_23"-->
|
||||||
android:layout_gravity="center_vertical"
|
<!-- android:layout_gravity="center_vertical"-->
|
||||||
android:text="名族" />
|
<!-- android:text="民族" />-->
|
||||||
|
|
||||||
|
|
||||||
<TextView
|
<!-- <TextView-->
|
||||||
android:id="@+id/tv_base_nation"
|
<!-- android:id="@+id/tv_base_nation"-->
|
||||||
style="@style/item_content_23"
|
<!-- style="@style/item_content_23"-->
|
||||||
android:hint="未录入" />
|
<!-- android:hint="未录入" />-->
|
||||||
|
|
||||||
</LinearLayout>
|
<!-- </LinearLayout>-->
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
<LinearLayout style="@style/item_white">
|
android:id="@+id/ll_edit"
|
||||||
|
|
||||||
<TextView
|
|
||||||
style="@style/item_title_23"
|
|
||||||
android:layout_gravity="center_vertical"
|
|
||||||
android:text="籍贯地址" />
|
|
||||||
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/tv_base_register_loc"
|
|
||||||
style="@style/item_content_23"
|
|
||||||
android:hint="未录入" />
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout style="@style/item_white">
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
style="@style/item_title_23"
|
|
||||||
android:layout_gravity="center_vertical"
|
|
||||||
android:text="现住址" />
|
|
||||||
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/tv_base_cur_address"
|
|
||||||
style="@style/item_content_23"
|
|
||||||
android:hint="未录入" />
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
<Button
|
|
||||||
android:id="@+id/btn_detail"
|
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="30dp"
|
android:layout_height="wrap_content"
|
||||||
android:layout_alignParentRight="true"
|
android:orientation="vertical">
|
||||||
android:layout_margin="10dp"
|
|
||||||
android:layout_marginRight="10dp"
|
|
||||||
android:background="@drawable/sel_btn_submit"
|
|
||||||
android:text="详情"
|
|
||||||
android:textColor="@color/white" />
|
|
||||||
|
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/issue_report_title"
|
||||||
|
android:padding="8dp"
|
||||||
|
android:text="信息修改" />
|
||||||
|
|
||||||
|
<LinearLayout style="@style/item_white">
|
||||||
|
|
||||||
|
<ImageView style="@style/style_hint_star" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/item_title_23"
|
||||||
|
android:layout_gravity="center_vertical"
|
||||||
|
android:text="所属网格" />
|
||||||
|
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_grid"
|
||||||
|
style="@style/item_content_23"
|
||||||
|
android:drawableRight="@drawable/ic_arrow_sort_gray"
|
||||||
|
android:hint="请选择所属网格" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout style="@style/item_white">
|
||||||
|
|
||||||
|
<ImageView style="@style/style_hint_star" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/item_title_23"
|
||||||
|
android:text="人口类型" />
|
||||||
|
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_type"
|
||||||
|
style="@style/item_content_23"
|
||||||
|
android:drawableRight="@drawable/ic_arrow_sort_gray"
|
||||||
|
android:hint="请选择人口类型" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/btn_confirm"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentBottom="true"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:background="@drawable/sel_btn_submit"
|
||||||
|
android:minHeight="0dp"
|
||||||
|
android:padding="10dp"
|
||||||
|
android:text="保    存"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
android:textSize="17dp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
</androidx.core.widget.NestedScrollView>
|
</androidx.core.widget.NestedScrollView>
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="match_parent"
|
||||||
android:layout_below="@id/ll_base_info"
|
android:layout_below="@id/ll_base_info"
|
||||||
android:layout_marginTop="-20dp"
|
android:layout_marginTop="-20dp"
|
||||||
android:background="@drawable/shape_rectangle_white_top">
|
android:background="@drawable/shape_rectangle_white_top">
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="match_parent"
|
||||||
android:layout_below="@id/ll_base_info"
|
android:layout_below="@id/ll_base_info"
|
||||||
android:layout_marginTop="-20dp"
|
android:layout_marginTop="-20dp"
|
||||||
android:background="@drawable/shape_rectangle_white_top">
|
android:background="@drawable/shape_rectangle_white_top">
|
||||||
|
@ -174,7 +174,7 @@
|
|||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tv_nation"
|
android:id="@+id/tv_nation"
|
||||||
style="@style/item_content_23"
|
style="@style/item_content_23"
|
||||||
android:hint="请选择名族" />
|
android:hint="请选择民族" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="match_parent"
|
||||||
android:layout_below="@id/ll_base_info"
|
android:layout_below="@id/ll_base_info"
|
||||||
android:layout_marginTop="-20dp"
|
android:layout_marginTop="-20dp"
|
||||||
android:background="@drawable/shape_rectangle_white_top">
|
android:background="@drawable/shape_rectangle_white_top">
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="match_parent"
|
||||||
android:layout_below="@id/ll_base_info"
|
android:layout_below="@id/ll_base_info"
|
||||||
android:layout_marginTop="-20dp"
|
android:layout_marginTop="-20dp"
|
||||||
android:background="@drawable/shape_rectangle_white_top">
|
android:background="@drawable/shape_rectangle_white_top">
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="match_parent"
|
||||||
android:layout_below="@id/ll_base_info"
|
android:layout_below="@id/ll_base_info"
|
||||||
android:layout_marginTop="-20dp"
|
android:layout_marginTop="-20dp"
|
||||||
android:background="@drawable/shape_rectangle_white_top">
|
android:background="@drawable/shape_rectangle_white_top">
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="match_parent"
|
||||||
android:layout_below="@id/ll_base_info"
|
android:layout_below="@id/ll_base_info"
|
||||||
android:layout_marginTop="-20dp"
|
android:layout_marginTop="-20dp"
|
||||||
android:background="@drawable/shape_rectangle_white_top">
|
android:background="@drawable/shape_rectangle_white_top">
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="match_parent"
|
||||||
android:layout_below="@id/ll_base_info"
|
android:layout_below="@id/ll_base_info"
|
||||||
android:layout_marginTop="-20dp"
|
android:layout_marginTop="-20dp"
|
||||||
android:background="@drawable/shape_rectangle_white_top">
|
android:background="@drawable/shape_rectangle_white_top">
|
||||||
|
@ -177,7 +177,7 @@
|
|||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tv_nation"
|
android:id="@+id/tv_nation"
|
||||||
style="@style/sel_text_arrow"
|
style="@style/sel_text_arrow"
|
||||||
android:hint="请选择名族" />
|
android:hint="请选择民族" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
@ -177,7 +177,7 @@
|
|||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tv_nation"
|
android:id="@+id/tv_nation"
|
||||||
style="@style/sel_text_arrow"
|
style="@style/sel_text_arrow"
|
||||||
android:hint="请选择名族" />
|
android:hint="请选择民族" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
@ -160,7 +160,7 @@
|
|||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tv_nation"
|
android:id="@+id/tv_nation"
|
||||||
style="@style/sel_text_arrow"
|
style="@style/sel_text_arrow"
|
||||||
android:hint="请选择名族" />
|
android:hint="请选择民族" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
@ -160,7 +160,7 @@
|
|||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tv_nation"
|
android:id="@+id/tv_nation"
|
||||||
style="@style/sel_text_arrow"
|
style="@style/sel_text_arrow"
|
||||||
android:hint="请选择名族" />
|
android:hint="请选择民族" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user