diff --git a/app/src/main/java/com/example/jingyuan_mes/entity/store/ProductOutSubmit.java b/app/src/main/java/com/example/jingyuan_mes/entity/store/ProductOutSubmit.java index 425a92e..f2decb7 100644 --- a/app/src/main/java/com/example/jingyuan_mes/entity/store/ProductOutSubmit.java +++ b/app/src/main/java/com/example/jingyuan_mes/entity/store/ProductOutSubmit.java @@ -1,42 +1,52 @@ package com.example.jingyuan_mes.entity.store; +import androidx.databinding.BaseObservable; + /** * @author wanghao * @date 2024/2/27 15:42 */ -public class ProductOutSubmit { - - /** - * productOutstockId : 1 - * locationCode : 123 - * productBarcode : 12 - */ - - private int productOutstockId; - private String locationCode; - private String productBarcode; - - public int getProductOutstockId() { - return productOutstockId; - } - - public void setProductOutstockId(int productOutstockId) { - this.productOutstockId = productOutstockId; - } - - public String getLocationCode() { - return locationCode; - } - - public void setLocationCode(String locationCode) { - this.locationCode = locationCode; - } - - public String getProductBarcode() { - return productBarcode; - } - - public void setProductBarcode(String productBarcode) { - this.productBarcode = productBarcode; - } +public class ProductOutSubmit extends BaseObservable { + + /** + * productOutstockId : 1 + * locationCode : 123 + * productBarcode : 12 + */ + + private int productOutstockId; + private String locationCode; + private String productBarcode; + + public int getProductOutstockId() { + return productOutstockId; + } + + public void setProductOutstockId(int productOutstockId) { + this.productOutstockId = productOutstockId; + notifyChange(); + } + + public String getLocationCode() { + return locationCode; + } + + public void setLocationCode(String locationCode) { + this.locationCode = locationCode; + notifyChange(); + } + + public String getProductBarcode() { + return productBarcode; + } + + public void setProductBarcode(String productBarcode) { + this.productBarcode = productBarcode; + } + + public void clear(){ + this.locationCode = null; + this.productBarcode = null; + notifyChange(); + } } diff --git a/app/src/main/java/com/example/jingyuan_mes/store/ProductOutInfoActivity.java b/app/src/main/java/com/example/jingyuan_mes/store/ProductOutInfoActivity.java index d1d7ca1..c3861b5 100644 --- a/app/src/main/java/com/example/jingyuan_mes/store/ProductOutInfoActivity.java +++ b/app/src/main/java/com/example/jingyuan_mes/store/ProductOutInfoActivity.java @@ -74,6 +74,7 @@ public class ProductOutInfoActivity extends BaseActivity { super.onSuccess(response); var body = response.body(); if (body.getCode() == 200) { + submit.clear(); initRequest(id); } Toast.makeText(context, body.getMsg(), Toast.LENGTH_SHORT).show(); diff --git a/app/src/main/res/layout/item_product_out_apply.xml b/app/src/main/res/layout/item_product_out_apply.xml index a11e02c..76f9673 100644 --- a/app/src/main/res/layout/item_product_out_apply.xml +++ b/app/src/main/res/layout/item_product_out_apply.xml @@ -12,7 +12,7 @@ android:orientation="vertical" android:background="@drawable/san_text_bg" android:layout_width="match_parent" - android:layout_height="300dp" + android:layout_height="335dp" android:layout_marginTop="5dp" android:padding="4dp"> @@ -53,6 +53,24 @@ android:text='@{vm.materialName}' /> + + + + + + +