提交 ccdc0bad authored 作者: lgd's avatar lgd

1.退货详情

上级 9c7e8c34
...@@ -146,6 +146,15 @@ public class ReturnApplyBean { ...@@ -146,6 +146,15 @@ public class ReturnApplyBean {
private Object boxCode; private Object boxCode;
private String backStockName; private String backStockName;
private String lot; private String lot;
private String action;
public String getAction() {
return action;
}
public void setAction(String action) {
this.action = action;
}
public String getLot() { public String getLot() {
return lot; return lot;
......
...@@ -20,6 +20,7 @@ import com.wd.workoffice.bean.workEnum.OrderType; ...@@ -20,6 +20,7 @@ import com.wd.workoffice.bean.workEnum.OrderType;
import com.wd.workoffice.bean.workEnum.PagePermissionType; import com.wd.workoffice.bean.workEnum.PagePermissionType;
import com.wd.workoffice.retrofit.RtfUtils; import com.wd.workoffice.retrofit.RtfUtils;
import com.wd.workoffice.retrofit.WorkObserver; import com.wd.workoffice.retrofit.WorkObserver;
import com.wd.workoffice.util.MathUtils;
import com.wd.workoffice.util.WorkUtils; import com.wd.workoffice.util.WorkUtils;
import org.greenrobot.eventbus.EventBus; import org.greenrobot.eventbus.EventBus;
...@@ -37,7 +38,7 @@ import io.reactivex.Observable; ...@@ -37,7 +38,7 @@ import io.reactivex.Observable;
import io.reactivex.disposables.Disposable; import io.reactivex.disposables.Disposable;
/** /**
* 退详情 * 退详情
* author : flexible * author : flexible
* email : lgd19940421@163.com * email : lgd19940421@163.com
* github: https://github.com/FlexibleXd * github: https://github.com/FlexibleXd
...@@ -131,6 +132,14 @@ public class ReturnDetailActivity extends WorkToolBarActivity { ...@@ -131,6 +132,14 @@ public class ReturnDetailActivity extends WorkToolBarActivity {
View viewLine6; View viewLine6;
@BindView(R.id.tv_dep6) @BindView(R.id.tv_dep6)
TextView tvDep6; TextView tvDep6;
@BindView(R.id.tv_title_desc)
TextView tvTitleDesc;
@BindView(R.id.tv_return_num_desc)
TextView tvReturnNumDesc;
@BindView(R.id.ll_stock)
RelativeLayout llStock;
@BindView(R.id.tv_return_type_desc)
TextView tvReturnTypeDesc;
private ReturnApplyBean.RecordsBean info; private ReturnApplyBean.RecordsBean info;
private String orderType; private String orderType;
...@@ -155,17 +164,23 @@ public class ReturnDetailActivity extends WorkToolBarActivity { ...@@ -155,17 +164,23 @@ public class ReturnDetailActivity extends WorkToolBarActivity {
tvName.setText(info.getProductSimpleCode()); tvName.setText(info.getProductSimpleCode());
tvProName.setText(info.getProductName()); tvProName.setText(info.getProductName());
tvProCode.setText(info.getProductSoleCode()); tvProCode.setText(info.getProductSoleCode());
tvReturnNum.setText(String.valueOf(info.getProductAmount())); tvReturnNum.setText(MathUtils.converData(info.getProductAmount(), 3));
tvReturnType.setText(info.getReturnTypeName()); tvReturnType.setText(info.getReturnTypeName());
tvStock.setText(info.getBackStockName()); tvStock.setText(info.getBackStockName());
tvPerson.setText(String.valueOf(info.getCreatedByName())); tvPerson.setText(info.getCreatedByName());
tvTime.setText(info.getCreatedTime()); tvTime.setText(info.getCreatedTime());
tvLot.setText(info.getLot()); tvLot.setText(info.getLot());
tvRemark.setText(String.valueOf(info.getApplyRemark())); tvRemark.setText(info.getApplyRemark());
tvStatus.setText(WorkUtils.getReturnStatus(Integer.valueOf(info.getStatus()))); tvStatus.setText(WorkUtils.getReturnStatus(Integer.valueOf(info.getStatus())));
changeProcess(info.getStatus()); changeProcess(info.getStatus());
changeCheckView(info.getStatus()); changeCheckView(info.getStatus());
changePermission(info.getStatus()); changePermission(info.getStatus());
if (TextUtils.equals(info.getAction(), "2")) {
tvTitleDesc.setText("报废详情");
tvReturnNumDesc.setText("报废数量");
tvReturnTypeDesc.setText("报废类型");
setTitle("报废详情");
}
} }
/** /**
...@@ -175,7 +190,7 @@ public class ReturnDetailActivity extends WorkToolBarActivity { ...@@ -175,7 +190,7 @@ public class ReturnDetailActivity extends WorkToolBarActivity {
*/ */
private void changeCheckView(String status) { private void changeCheckView(String status) {
if (TextUtils.equals(orderType, OrderType.SALE.getCode())) { if (TextUtils.equals(orderType, OrderType.SALE.getCode())) {
if (status.startsWith("1") && (!status.endsWith("4")&&!status.endsWith("5"))) { if (status.startsWith("1") && (!status.endsWith("4") && !status.endsWith("5"))) {
llBottom.setVisibility(View.VISIBLE); llBottom.setVisibility(View.VISIBLE);
llCheck.setVisibility(View.VISIBLE); llCheck.setVisibility(View.VISIBLE);
} else { } else {
...@@ -183,7 +198,7 @@ public class ReturnDetailActivity extends WorkToolBarActivity { ...@@ -183,7 +198,7 @@ public class ReturnDetailActivity extends WorkToolBarActivity {
llCheck.setVisibility(View.GONE); llCheck.setVisibility(View.GONE);
} }
} else if (TextUtils.equals(orderType, OrderType.OUT_BUY.getCode())) { } else if (TextUtils.equals(orderType, OrderType.OUT_BUY.getCode())) {
if (status.startsWith("1") && (!status.endsWith("4")&&!status.endsWith("5"))) { if (status.startsWith("1") && (!status.endsWith("4") && !status.endsWith("5"))) {
llBottom.setVisibility(View.VISIBLE); llBottom.setVisibility(View.VISIBLE);
llCheck.setVisibility(View.VISIBLE); llCheck.setVisibility(View.VISIBLE);
} else { } else {
...@@ -294,7 +309,7 @@ public class ReturnDetailActivity extends WorkToolBarActivity { ...@@ -294,7 +309,7 @@ public class ReturnDetailActivity extends WorkToolBarActivity {
tvTop3.setText("通过"); tvTop3.setText("通过");
tvTop4.setText("通过"); tvTop4.setText("通过");
tvTop5.setText("驳回"); tvTop5.setText("驳回");
}else if (status.endsWith("5")) { } else if (status.endsWith("5")) {
changeProcessView(viewNode2, viewLine2, 0); changeProcessView(viewNode2, viewLine2, 0);
changeProcessView(viewNode3, viewLine3, 0); changeProcessView(viewNode3, viewLine3, 0);
changeProcessView(viewNode4, viewLine4, 0); changeProcessView(viewNode4, viewLine4, 0);
......
...@@ -270,6 +270,7 @@ ...@@ -270,6 +270,7 @@
android:background="@color/red_btn_bg" /> android:background="@color/red_btn_bg" />
<TextView <TextView
android:id="@+id/tv_title_desc"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginLeft="10mm" android:layout_marginLeft="10mm"
...@@ -287,6 +288,7 @@ ...@@ -287,6 +288,7 @@
android:paddingVertical="15mm"> android:paddingVertical="15mm">
<TextView <TextView
android:id="@+id/tv_return_num_desc"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="退货数量" /> android:text="退货数量" />
...@@ -329,6 +331,7 @@ ...@@ -329,6 +331,7 @@
android:paddingVertical="15mm"> android:paddingVertical="15mm">
<TextView <TextView
android:id="@+id/tv_return_type_desc"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="退货类型" /> android:text="退货类型" />
...@@ -342,6 +345,7 @@ ...@@ -342,6 +345,7 @@
</RelativeLayout> </RelativeLayout>
<RelativeLayout <RelativeLayout
android:id="@+id/ll_stock"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="center" android:layout_gravity="center"
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论