ソースを参照

成品检验添加【备注】字段

RaoMeng 5 年 前
コミット
62aeec03d1

+ 4 - 1
app/src/main/java/com/uas/pda_smart_sa/fragment/ProductCheckFragment.java

@@ -40,7 +40,7 @@ import java.util.List;
  * Desc: 成品检验
  */
 public class ProductCheckFragment extends BaseFragment implements View.OnClickListener {
-    private ClearableEditText mBoxEditText, mRealNumEditText;
+    private ClearableEditText mBoxEditText, mRealNumEditText, mRemarkEditText;
     private ImageView mScanImageView;
     private RecyclerView mRecyclerView;
     private TextView mQualifiedTv, mUnqualifiedTv;
@@ -71,6 +71,8 @@ public class ProductCheckFragment extends BaseFragment implements View.OnClickLi
         mUnqualifiedTv = root.findViewById(R.id.product_check_unqualified_tv);
         mSpotCheckLinearLayout = root.findViewById(R.id.product_check_spotcheck_ll);
         mRealNumEditText = root.findViewById(R.id.product_check_realnum_et);
+        mRemarkEditText = root.findViewById(R.id.product_check_remark_et);
+
         mRecyclerView = root.findViewById(R.id.product_check_result_rv);
         mRecyclerView.setLayoutManager(new LinearLayoutManager(mActivity));
         mCaptionValueBeans = new ArrayList<>();
@@ -234,6 +236,7 @@ public class ProductCheckFragment extends BaseFragment implements View.OnClickLi
                 .addParam("boxCode", mBoxcode)
                 .addParam("isNg", Boolean.toString(isNg))
                 .addParam("realCheckNum", realnum)
+                .addParam("remark", mRemarkEditText.getText().toString().trim())
                 .addParam("checkItems", JSON.toJSONString(mSpotCheckBeans))
                 .build(), new HttpCallback() {
             @Override

+ 91 - 68
app/src/main/res/layout/fragment_product_check.xml

@@ -39,98 +39,121 @@
         android:orientation="vertical"
         android:visibility="gone">
 
-        <LinearLayout
+        <android.support.v4.widget.NestedScrollView
             android:layout_width="match_parent"
             android:layout_height="0dp"
             android:layout_weight="1"
-            android:orientation="vertical">
-
-            <android.support.v7.widget.RecyclerView
-                android:id="@+id/product_check_result_rv"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:layout_marginTop="16dp" />
+            android:paddingBottom="6dp">
 
             <LinearLayout
                 android:layout_width="match_parent"
                 android:layout_height="wrap_content"
-                android:padding="4dp">
-
-                <TextView
-                    style="@style/CaptionText"
-                    android:text="实际抽样数:" />
-
-                <com.uas.pda_smart_sa.view.ClearableEditText
-                    android:id="@+id/product_check_realnum_et"
-                    style="@style/EditTextLineStyle"
-                    android:inputType="number"
-                    android:minHeight="32dp"
-                    tools:text="value" />
-            </LinearLayout>
+                android:orientation="vertical">
 
+                <android.support.v7.widget.RecyclerView
+                    android:id="@+id/product_check_result_rv"
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="16dp" />
 
-            <LinearLayout
-                android:id="@+id/product_check_spotcheck_ll"
-                android:layout_width="match_parent"
-                android:layout_height="match_parent"
-                android:orientation="vertical"
-                android:visibility="gone">
+                <LinearLayout
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:padding="4dp">
 
-                <TextView
-                    style="@style/CaptionText"
-                    android:layout_marginTop="8dp"
-                    android:padding="4dp"
-                    android:text="抽检项目"
-                    android:textColor="@color/black" />
+                    <TextView
+                        style="@style/CaptionText"
+                        android:text="实际抽样数:" />
+
+                    <com.uas.pda_smart_sa.view.ClearableEditText
+                        android:id="@+id/product_check_realnum_et"
+                        style="@style/EditTextLineStyle"
+                        android:inputType="number"
+                        android:minHeight="32dp"
+                        tools:text="value" />
+                </LinearLayout>
 
                 <LinearLayout
                     android:layout_width="match_parent"
                     android:layout_height="wrap_content"
-                    android:layout_marginTop="10dp">
+                    android:padding="4dp">
 
                     <TextView
-                        android:layout_width="0dp"
-                        android:layout_height="wrap_content"
-                        android:layout_weight="1"
-                        android:background="@drawable/shape_table_head_left"
-                        android:gravity="center"
-                        android:maxLines="1"
-                        android:padding="4dp"
-                        android:singleLine="true"
-                        android:text="抽检项目"
-                        android:textColor="@color/black" />
+                        style="@style/CaptionText"
+                        android:text="备注:" />
+
+                    <com.uas.pda_smart_sa.view.ClearableEditText
+                        android:id="@+id/product_check_remark_et"
+                        style="@style/EditTextLineStyle"
+                        android:inputType="number"
+                        android:minHeight="32dp"
+                        tools:text="value" />
+                </LinearLayout>
+
+                <LinearLayout
+                    android:id="@+id/product_check_spotcheck_ll"
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:orientation="vertical"
+                    android:visibility="gone">
 
                     <TextView
-                        android:layout_width="0dp"
-                        android:layout_height="wrap_content"
-                        android:layout_weight="1"
-                        android:background="@drawable/shape_table_head_left"
-                        android:gravity="center"
-                        android:maxLines="1"
+                        style="@style/CaptionText"
+                        android:layout_marginTop="8dp"
                         android:padding="4dp"
-                        android:singleLine="true"
-                        android:text="抽检数"
+                        android:text="抽检项目"
                         android:textColor="@color/black" />
 
-                    <TextView
-                        android:layout_width="0dp"
+                    <LinearLayout
+                        android:layout_width="match_parent"
                         android:layout_height="wrap_content"
-                        android:layout_weight="1"
-                        android:background="@drawable/shape_table_head_right"
-                        android:gravity="center"
-                        android:maxLines="1"
-                        android:padding="4dp"
-                        android:singleLine="true"
-                        android:text="不合格数"
-                        android:textColor="@color/black" />
+                        android:layout_marginTop="10dp">
+
+                        <TextView
+                            android:layout_width="0dp"
+                            android:layout_height="wrap_content"
+                            android:layout_weight="1"
+                            android:background="@drawable/shape_table_head_left"
+                            android:gravity="center"
+                            android:maxLines="1"
+                            android:padding="4dp"
+                            android:singleLine="true"
+                            android:text="抽检项目"
+                            android:textColor="@color/black" />
+
+                        <TextView
+                            android:layout_width="0dp"
+                            android:layout_height="wrap_content"
+                            android:layout_weight="1"
+                            android:background="@drawable/shape_table_head_left"
+                            android:gravity="center"
+                            android:maxLines="1"
+                            android:padding="4dp"
+                            android:singleLine="true"
+                            android:text="抽检数"
+                            android:textColor="@color/black" />
+
+                        <TextView
+                            android:layout_width="0dp"
+                            android:layout_height="wrap_content"
+                            android:layout_weight="1"
+                            android:background="@drawable/shape_table_head_right"
+                            android:gravity="center"
+                            android:maxLines="1"
+                            android:padding="4dp"
+                            android:singleLine="true"
+                            android:text="不合格数"
+                            android:textColor="@color/black" />
+                    </LinearLayout>
+
+                    <android.support.v7.widget.RecyclerView
+                        android:id="@+id/product_check_spotcheck_rv"
+                        android:layout_width="match_parent"
+                        android:layout_height="wrap_content" />
                 </LinearLayout>
-
-                <android.support.v7.widget.RecyclerView
-                    android:id="@+id/product_check_spotcheck_rv"
-                    android:layout_width="match_parent"
-                    android:layout_height="match_parent" />
             </LinearLayout>
-        </LinearLayout>
+
+        </android.support.v4.widget.NestedScrollView>
 
         <LinearLayout
             android:layout_width="match_parent"

+ 2 - 2
build.gradle

@@ -44,8 +44,8 @@ ext {
             targetSdkVersion : 28,
             compileSdkVersion: 28,
             buildToolsVersion: "28.0.3",
-            versionCode      : 12,
-            versionName      : "v1.2.0"
+            versionCode      : 13,
+            versionName      : "v1.3.0"
     ]
 
     depsVersion = [