提交 2aef863a authored 作者: lgd's avatar lgd

1.修改激活顺序

2.//todo  回款管理的客户接口
上级 3a257b52
...@@ -42,7 +42,7 @@ public class ActivationUserBean { ...@@ -42,7 +42,7 @@ public class ActivationUserBean {
private String status; private String status;
private String erpId; private String erpId;
private int deptId; private int deptId;
private Object deptName; private String deptName;
private Object verifyCode; private Object verifyCode;
public Object getCreatedBy() { public Object getCreatedBy() {
...@@ -165,11 +165,11 @@ public class ActivationUserBean { ...@@ -165,11 +165,11 @@ public class ActivationUserBean {
this.deptId = deptId; this.deptId = deptId;
} }
public Object getDeptName() { public String getDeptName() {
return deptName; return deptName;
} }
public void setDeptName(Object deptName) { public void setDeptName(String deptName) {
this.deptName = deptName; this.deptName = deptName;
} }
......
package com.wd.workoffice.ui.activity.login; package com.wd.workoffice.ui.activity.login;
import android.os.Bundle;
import android.text.Editable; import android.text.Editable;
import android.text.TextUtils; import android.text.TextUtils;
import android.text.TextWatcher; import android.text.TextWatcher;
import android.view.View; import android.view.View;
import android.widget.Button; import android.widget.Button;
import android.widget.EditText; import android.widget.EditText;
import android.widget.LinearLayout;
import android.widget.TextView; import android.widget.TextView;
import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSON;
import com.wd.workoffice.R; import com.wd.workoffice.R;
import com.wd.workoffice.app.WorkToolBarActivity; import com.wd.workoffice.app.WorkToolBarActivity;
...@@ -15,6 +18,7 @@ import com.wd.workoffice.bean.workEnum.CodeType; ...@@ -15,6 +18,7 @@ import com.wd.workoffice.bean.workEnum.CodeType;
import com.wd.workoffice.contract.ErpActivationContract; import com.wd.workoffice.contract.ErpActivationContract;
import com.wd.workoffice.presenter.ErpActivationPresenter; import com.wd.workoffice.presenter.ErpActivationPresenter;
import com.wd.workoffice.util.WorkUtils; import com.wd.workoffice.util.WorkUtils;
import butterknife.BindView; import butterknife.BindView;
import butterknife.ButterKnife; import butterknife.ButterKnife;
import butterknife.OnClick; import butterknife.OnClick;
...@@ -26,15 +30,18 @@ import flexible.xd.android_base.utils.ToastUtil; ...@@ -26,15 +30,18 @@ import flexible.xd.android_base.utils.ToastUtil;
* */ * */
public class ErpActivationOneActivity extends WorkToolBarActivity implements ErpActivationContract.View { public class ErpActivationOneActivity extends WorkToolBarActivity implements ErpActivationContract.View {
@BindView(R.id.et_phone) @BindView(R.id.et_phone)
EditText etPhone; EditText etPhone;
@BindView(R.id.tv_discover) @BindView(R.id.tv_discover)
TextView tvDiscover; TextView tvDiscover;
@BindView(R.id.et_staff_code) @BindView(R.id.et_staff_code)
EditText etStaffCode; TextView etStaffCode;
@BindView(R.id.tv_dep)
TextView tvDep;
@BindView(R.id.ll_dep)
LinearLayout llDep;
@BindView(R.id.et_name) @BindView(R.id.et_name)
EditText etName; TextView etName;
@BindView(R.id.et_code) @BindView(R.id.et_code)
EditText etCode; EditText etCode;
@BindView(R.id.tv_code) @BindView(R.id.tv_code)
...@@ -111,7 +118,7 @@ public class ErpActivationOneActivity extends WorkToolBarActivity implements Erp ...@@ -111,7 +118,7 @@ public class ErpActivationOneActivity extends WorkToolBarActivity implements Erp
switch (view.getId()) { switch (view.getId()) {
case R.id.tv_discover: case R.id.tv_discover:
String discover = etPhone.getText().toString(); String discover = etPhone.getText().toString();
if (!RegexUtils.isMobileSimple(discover)){ if (!RegexUtils.isMobileSimple(discover)) {
toast("请输入正确的手机号"); toast("请输入正确的手机号");
return; return;
} }
...@@ -119,10 +126,10 @@ public class ErpActivationOneActivity extends WorkToolBarActivity implements Erp ...@@ -119,10 +126,10 @@ public class ErpActivationOneActivity extends WorkToolBarActivity implements Erp
break; break;
case R.id.tv_code: case R.id.tv_code:
String phone = etPhone.getText().toString(); String phone = etPhone.getText().toString();
erpActivationPresenter.getCode(phone,CodeType.REGISTER.getName()); erpActivationPresenter.getCode(phone, CodeType.REGISTER.getName());
break; break;
case R.id.btn_next: case R.id.btn_next:
if (infoData==null){ if (infoData == null) {
toast("请检测用户信息"); toast("请检测用户信息");
return; return;
} }
...@@ -142,6 +149,7 @@ public class ErpActivationOneActivity extends WorkToolBarActivity implements Erp ...@@ -142,6 +149,7 @@ public class ErpActivationOneActivity extends WorkToolBarActivity implements Erp
infoData = data; infoData = data;
etName.setText(data.getNickName()); etName.setText(data.getNickName());
etStaffCode.setText(data.getErpId()); etStaffCode.setText(data.getErpId());
tvDep.setText(data.getDeptName());
} }
@Override @Override
...@@ -153,7 +161,8 @@ public class ErpActivationOneActivity extends WorkToolBarActivity implements Erp ...@@ -153,7 +161,8 @@ public class ErpActivationOneActivity extends WorkToolBarActivity implements Erp
@Override @Override
public void verifySuccess() { public void verifySuccess() {
startActivity(ErpActivationTwoActivity.class, startActivity(ErpActivationTwoActivity.class,
"phone",etPhone.getText().toString(),"code",etCode.getText().toString(), "phone", etPhone.getText().toString(), "code", etCode.getText().toString(),
"info",JSON.toJSONString(infoData)); "info", JSON.toJSONString(infoData));
} }
} }
...@@ -71,6 +71,9 @@ public class ErpActivationTwoActivity extends WorkToolBarActivity { ...@@ -71,6 +71,9 @@ public class ErpActivationTwoActivity extends WorkToolBarActivity {
ActivationUserBean info = JSON.parseObject(getIntent().getStringExtra("info"), ActivationUserBean.class); ActivationUserBean info = JSON.parseObject(getIntent().getStringExtra("info"), ActivationUserBean.class);
param.put("email", info.getEmail()); param.put("email", info.getEmail());
param.put("nickName", info.getNickName()); param.put("nickName", info.getNickName());
param.put("deptId", info.getDeptId());
param.put("ofRegisterNewDept", 0);
etName.setText(info.getUserName());
} }
@Override @Override
...@@ -199,21 +202,21 @@ public class ErpActivationTwoActivity extends WorkToolBarActivity { ...@@ -199,21 +202,21 @@ public class ErpActivationTwoActivity extends WorkToolBarActivity {
toast("两次输入的密码不一致"); toast("两次输入的密码不一致");
return; return;
} }
if (dep == null) { // if (dep == null) {
toast("请选择部门"); // toast("请选择部门");
return; // return;
} // }
param.put("userName", name); param.put("userName", name);
param.put("password", pwd); param.put("password", pwd);
param.put("ofRegisterNewDept", dep.getOfRegisterNewDept()); // param.put("ofRegisterNewDept", dep.getOfRegisterNewDept());
if (dep.getOfRegisterNewDept() == 1) { // if (dep.getOfRegisterNewDept() == 1) {
param.put("newDeptName", dep.getName()); // param.put("newDeptName", dep.getName());
param.put("newDeptErpId", dep.getCode()); // param.put("newDeptErpId", dep.getCode());
param.put("newDeptType", dep.getType()); // param.put("newDeptType", dep.getType());
} else { // } else {
param.put("deptId", dep.getId()); // param.put("deptId", dep.getId());
} // }
submit(); submit();
break; break;
case R.id.tv_go_protocol: case R.id.tv_go_protocol:
......
...@@ -50,8 +50,8 @@ ...@@ -50,8 +50,8 @@
android:layout_marginLeft="10mm" android:layout_marginLeft="10mm"
android:layout_weight="1" android:layout_weight="1"
android:background="@null" android:background="@null"
android:inputType="phone"
android:hint="输入手机号检测是否为ERP员工" android:hint="输入手机号检测是否为ERP员工"
android:inputType="phone"
android:textSize="12sp" /> android:textSize="12sp" />
<TextView <TextView
...@@ -80,19 +80,47 @@ ...@@ -80,19 +80,47 @@
android:layout_marginLeft="13mm" android:layout_marginLeft="13mm"
android:background="@mipmap/login_phone" /> android:background="@mipmap/login_phone" />
<EditText <TextView
android:id="@+id/et_staff_code" android:id="@+id/et_staff_code"
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_centerVertical="true" android:layout_centerVertical="true"
android:layout_marginLeft="10mm" android:layout_marginLeft="10mm"
android:layout_weight="1" android:layout_weight="1"
android:gravity="center_vertical"
android:background="@null" android:background="@null"
android:hint="员工编号" android:hint="员工编号"
android:textSize="12sp" /> android:textSize="12sp" />
</LinearLayout> </LinearLayout>
<LinearLayout
android:id="@+id/ll_dep"
android:layout_width="match_parent"
android:layout_height="50mm"
android:layout_centerInParent="true"
android:layout_marginTop="20mm"
android:background="@drawable/shape_login_et"
android:gravity="center_vertical">
<ImageView
android:layout_width="20mm"
android:layout_height="20mm"
android:layout_marginLeft="13mm"
android:background="@mipmap/login_pwd" />
<TextView
android:id="@+id/tv_dep"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_centerVertical="true"
android:layout_marginLeft="10mm"
android:layout_weight="1"
android:hint="员工部门"
android:gravity="center_vertical"
android:textSize="12sp" />
</LinearLayout>
<LinearLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="50mm" android:layout_height="50mm"
...@@ -107,7 +135,7 @@ ...@@ -107,7 +135,7 @@
android:layout_marginLeft="13mm" android:layout_marginLeft="13mm"
android:background="@mipmap/login_phone" /> android:background="@mipmap/login_phone" />
<EditText <TextView
android:id="@+id/et_name" android:id="@+id/et_name"
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="match_parent" android:layout_height="match_parent"
...@@ -115,6 +143,7 @@ ...@@ -115,6 +143,7 @@
android:layout_marginLeft="10mm" android:layout_marginLeft="10mm"
android:layout_weight="1" android:layout_weight="1"
android:background="@null" android:background="@null"
android:gravity="center_vertical"
android:hint="员工姓名" android:hint="员工姓名"
android:textSize="12sp" /> android:textSize="12sp" />
...@@ -161,9 +190,9 @@ ...@@ -161,9 +190,9 @@
android:id="@+id/btn_next" android:id="@+id/btn_next"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="50mm" android:layout_height="50mm"
android:background="@drawable/selector_btn"
android:layout_marginHorizontal="58mm" android:layout_marginHorizontal="58mm"
android:layout_marginTop="40mm" android:layout_marginTop="40mm"
android:background="@drawable/selector_btn"
android:text="下一步" android:text="下一步"
android:textColor="@color/white" android:textColor="@color/white"
android:textSize="20sp" /> android:textSize="20sp" />
...@@ -172,9 +201,9 @@ ...@@ -172,9 +201,9 @@
<TextView <TextView
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="match_parent" android:layout_height="match_parent"
android:gravity="bottom"
android:layout_gravity="center_horizontal|bottom" android:layout_gravity="center_horizontal|bottom"
android:layout_marginBottom="30mm" android:layout_marginBottom="30mm"
android:gravity="bottom"
android:text="注册即代表同意《软件服务协议》及隐私协议" android:text="注册即代表同意《软件服务协议》及隐私协议"
android:textColor="@color/flexible_text_sup" android:textColor="@color/flexible_text_sup"
android:textSize="13sp" /> android:textSize="13sp" />
......
...@@ -115,6 +115,7 @@ ...@@ -115,6 +115,7 @@
<LinearLayout <LinearLayout
android:id="@+id/ll_dep" android:id="@+id/ll_dep"
android:visibility="gone"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="50mm" android:layout_height="50mm"
android:layout_centerInParent="true" android:layout_centerInParent="true"
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论