Browse Source

1、提示语字体颜色
2、出库添加字段

RaoMeng 5 years ago
parent
commit
4613a70691

+ 3 - 0
app/src/main/java/com/uas/pda_smart_com/adapter/StockTaskMultipleAdapter.java

@@ -61,6 +61,7 @@ public class StockTaskMultipleAdapter extends BaseAdapter {
     }
     }
 
 
     private void initializeViews(StockTaskMultipleBean object, final ViewHolder holder) {
     private void initializeViews(StockTaskMultipleBean object, final ViewHolder holder) {
+        holder.stockTaskMultipleOrispeccode.setText(object.getPR_ORISPECCODE());
         holder.stockTaskMultipleProdcode.setText(object.getPD_PRODCODE());
         holder.stockTaskMultipleProdcode.setText(object.getPD_PRODCODE());
         holder.stockTaskMultipleWaitNum.setText(CommonUtil.doubleFormat(object.getPD_RESTQTY()));
         holder.stockTaskMultipleWaitNum.setText(CommonUtil.doubleFormat(object.getPD_RESTQTY()));
         holder.stockTaskMultipleSum.setText(CommonUtil.doubleFormat(object.getPD_OUTQTY()));
         holder.stockTaskMultipleSum.setText(CommonUtil.doubleFormat(object.getPD_OUTQTY()));
@@ -98,6 +99,7 @@ public class StockTaskMultipleAdapter extends BaseAdapter {
     }
     }
 
 
     protected class ViewHolder {
     protected class ViewHolder {
+        private TextView stockTaskMultipleOrispeccode;
         private TextView stockTaskMultipleProdcode;
         private TextView stockTaskMultipleProdcode;
         private TextView stockTaskMultipleWaitNum;
         private TextView stockTaskMultipleWaitNum;
         private TextView stockTaskMultipleSum;
         private TextView stockTaskMultipleSum;
@@ -111,6 +113,7 @@ public class StockTaskMultipleAdapter extends BaseAdapter {
         private TextView stockTaskMultipleSpreadTv;
         private TextView stockTaskMultipleSpreadTv;
 
 
         public ViewHolder(View view) {
         public ViewHolder(View view) {
+            stockTaskMultipleOrispeccode = (TextView) view.findViewById(R.id.stock_task_multiple_orispeccode);
             stockTaskMultipleProdcode = (TextView) view.findViewById(R.id.stock_task_multiple_prodcode);
             stockTaskMultipleProdcode = (TextView) view.findViewById(R.id.stock_task_multiple_prodcode);
             stockTaskMultipleWaitNum = (TextView) view.findViewById(R.id.stock_task_multiple_wait_num);
             stockTaskMultipleWaitNum = (TextView) view.findViewById(R.id.stock_task_multiple_wait_num);
             stockTaskMultipleSum = (TextView) view.findViewById(R.id.stock_task_multiple_sum);
             stockTaskMultipleSum = (TextView) view.findViewById(R.id.stock_task_multiple_sum);

+ 9 - 0
app/src/main/java/com/uas/pda_smart_com/bean/MaterialInformationBean.java

@@ -42,6 +42,7 @@ public class MaterialInformationBean {
          * BA_REMAIN : 23
          * BA_REMAIN : 23
          */
          */
 
 
+        private String PR_ORISPECCODE;
         private String PD_PRODCODE;
         private String PD_PRODCODE;
         private String PR_DETAIL;
         private String PR_DETAIL;
         private String PR_SPEC;
         private String PR_SPEC;
@@ -52,6 +53,14 @@ public class MaterialInformationBean {
         private String PD_BATCHCODE;
         private String PD_BATCHCODE;
         private double BAR_REMAIN;
         private double BAR_REMAIN;
 
 
+        public String getPR_ORISPECCODE() {
+            return PR_ORISPECCODE;
+        }
+
+        public void setPR_ORISPECCODE(String PR_ORISPECCODE) {
+            this.PR_ORISPECCODE = PR_ORISPECCODE;
+        }
+
         public double getBAR_REMAIN() {
         public double getBAR_REMAIN() {
             return BAR_REMAIN;
             return BAR_REMAIN;
         }
         }

+ 9 - 0
app/src/main/java/com/uas/pda_smart_com/bean/StockTaskMultipleBean.java

@@ -21,6 +21,7 @@ public class StockTaskMultipleBean {
      * NOS : [{"PI_INOUTNO":"MG12333","PD_OUTQTY":12,"PD_RESTQTY":12}]
      * NOS : [{"PI_INOUTNO":"MG12333","PD_OUTQTY":12,"PD_RESTQTY":12}]
      */
      */
 
 
+    private String PR_ORISPECCODE;
     private String PD_PRODCODE;
     private String PD_PRODCODE;
     private String PR_DETAIL;
     private String PR_DETAIL;
     private String PR_SPEC;
     private String PR_SPEC;
@@ -33,6 +34,14 @@ public class StockTaskMultipleBean {
     private double BAR_REMAIN;
     private double BAR_REMAIN;
     private List<NOSBean> NOS;
     private List<NOSBean> NOS;
 
 
+    public String getPR_ORISPECCODE() {
+        return PR_ORISPECCODE;
+    }
+
+    public void setPR_ORISPECCODE(String PR_ORISPECCODE) {
+        this.PR_ORISPECCODE = PR_ORISPECCODE;
+    }
+
     public String getPD_PRODCODE() {
     public String getPD_PRODCODE() {
         return PD_PRODCODE;
         return PD_PRODCODE;
     }
     }

+ 18 - 6
app/src/main/java/com/uas/pda_smart_com/fragment/IOCOutMakeMaterialOper.java

@@ -285,6 +285,7 @@ public class IOCOutMakeMaterialOper extends BaseFragment implements View.OnClick
                             }
                             }
                         } else {
                         } else {
                             mCollectResultTextView.setVisibility(View.VISIBLE);
                             mCollectResultTextView.setVisibility(View.VISIBLE);
+                            mCollectResultTextView.setTextColor(getResources().getColor(R.color.green));
                             mCollectResultTextView.setText(null);
                             mCollectResultTextView.setText(null);
                             JSONArray listArray = dataObject.optJSONArray("nolist");
                             JSONArray listArray = dataObject.optJSONArray("nolist");
                             if (mCollectType.equals("byBarcode") || mCollectType.equals("byBatchcode")) {
                             if (mCollectType.equals("byBarcode") || mCollectType.equals("byBatchcode")) {
@@ -311,7 +312,7 @@ public class IOCOutMakeMaterialOper extends BaseFragment implements View.OnClick
                                 }
                                 }
 
 
                                 mCollectResultTextView.setText(barcodeResult);
                                 mCollectResultTextView.setText(barcodeResult);
-
+                                mCollectResultTextView.setTextColor(getResources().getColor(R.color.green));
 
 
                                 mBarcodeTableLayout.setVisibility(View.GONE);
                                 mBarcodeTableLayout.setVisibility(View.GONE);
                                 mBoxTableLayout.setVisibility(View.GONE);
                                 mBoxTableLayout.setVisibility(View.GONE);
@@ -353,7 +354,7 @@ public class IOCOutMakeMaterialOper extends BaseFragment implements View.OnClick
                                 }
                                 }
 
 
                                 mCollectResultTextView.setText(boxResult);
                                 mCollectResultTextView.setText(boxResult);
-
+                                mCollectResultTextView.setTextColor(getResources().getColor(R.color.green));
 
 
                                 mBarcodeTableLayout.setVisibility(View.GONE);
                                 mBarcodeTableLayout.setVisibility(View.GONE);
                                 mBoxTableLayout.setVisibility(View.GONE);
                                 mBoxTableLayout.setVisibility(View.GONE);
@@ -386,7 +387,8 @@ public class IOCOutMakeMaterialOper extends BaseFragment implements View.OnClick
                                 MaterialInformationBean.DataBean materialInformationBean = JsonTools.parseJsonToBean(nextObject.toString(), MaterialInformationBean.DataBean.class);
                                 MaterialInformationBean.DataBean materialInformationBean = JsonTools.parseJsonToBean(nextObject.toString(), MaterialInformationBean.DataBean.class);
                                 if (materialInformationBean != null) {
                                 if (materialInformationBean != null) {
                                     String materialInfo =
                                     String materialInfo =
-                                            "物料:" + (materialInformationBean.getPD_PRODCODE() == null ? "" : materialInformationBean.getPD_PRODCODE())
+                                            "型号:" + (materialInformationBean.getPR_ORISPECCODE() == null ? "" : materialInformationBean.getPR_ORISPECCODE())
+                                                    + "物料:" + (materialInformationBean.getPD_PRODCODE() == null ? "" : materialInformationBean.getPD_PRODCODE())
                                                     + "; 名称规格:" + (materialInformationBean.getPR_DETAIL() == null ? "" : materialInformationBean.getPR_DETAIL())
                                                     + "; 名称规格:" + (materialInformationBean.getPR_DETAIL() == null ? "" : materialInformationBean.getPR_DETAIL())
                                                     + "  " + (materialInformationBean.getPR_SPEC() == null ? "" : materialInformationBean.getPR_SPEC())
                                                     + "  " + (materialInformationBean.getPR_SPEC() == null ? "" : materialInformationBean.getPR_SPEC())
                                                     + "; 未备料数:" + (materialInformationBean.getPD_RESTQTY() == null ? "" : materialInformationBean.getPD_RESTQTY())
                                                     + "; 未备料数:" + (materialInformationBean.getPD_RESTQTY() == null ? "" : materialInformationBean.getPD_RESTQTY())
@@ -681,7 +683,8 @@ public class IOCOutMakeMaterialOper extends BaseFragment implements View.OnClick
                         MaterialInformationBean materialInformationBean = JsonTools.parseJsonToBean(s, MaterialInformationBean.class);
                         MaterialInformationBean materialInformationBean = JsonTools.parseJsonToBean(s, MaterialInformationBean.class);
                         if (materialInformationBean != null && materialInformationBean.getData() != null) {
                         if (materialInformationBean != null && materialInformationBean.getData() != null) {
                             String materialInfo =
                             String materialInfo =
-                                    "物料:" + (materialInformationBean.getData().getPD_PRODCODE() == null ? "" : materialInformationBean.getData().getPD_PRODCODE())
+                                    "型号:" + (materialInformationBean.getData().getPR_ORISPECCODE() == null ? "" : materialInformationBean.getData().getPR_ORISPECCODE())
+                                            + "物料:" + (materialInformationBean.getData().getPD_PRODCODE() == null ? "" : materialInformationBean.getData().getPD_PRODCODE())
                                             + "; 名称规格:" + (materialInformationBean.getData().getPR_DETAIL() == null ? "" : materialInformationBean.getData().getPR_DETAIL())
                                             + "; 名称规格:" + (materialInformationBean.getData().getPR_DETAIL() == null ? "" : materialInformationBean.getData().getPR_DETAIL())
                                             + "  " + (materialInformationBean.getData().getPR_SPEC() == null ? "" : materialInformationBean.getData().getPR_SPEC())
                                             + "  " + (materialInformationBean.getData().getPR_SPEC() == null ? "" : materialInformationBean.getData().getPR_SPEC())
                                             + "; 未备料数:" + (materialInformationBean.getData().getPD_RESTQTY() == null ? "" : materialInformationBean.getData().getPD_RESTQTY())
                                             + "; 未备料数:" + (materialInformationBean.getData().getPD_RESTQTY() == null ? "" : materialInformationBean.getData().getPD_RESTQTY())
@@ -830,6 +833,7 @@ public class IOCOutMakeMaterialOper extends BaseFragment implements View.OnClick
                         }
                         }
                     } else {
                     } else {
                         mCollectResultTextView.setVisibility(View.VISIBLE);
                         mCollectResultTextView.setVisibility(View.VISIBLE);
+                        mCollectResultTextView.setTextColor(getResources().getColor(R.color.green));
                         mCollectResultTextView.setText(null);
                         mCollectResultTextView.setText(null);
                         JSONArray listArray = dataObject.optJSONArray("nolist");
                         JSONArray listArray = dataObject.optJSONArray("nolist");
                         if (mCollectType.equals("byBarcode") || mCollectType.equals("byBatchcode")) {
                         if (mCollectType.equals("byBarcode") || mCollectType.equals("byBatchcode")) {
@@ -853,6 +857,7 @@ public class IOCOutMakeMaterialOper extends BaseFragment implements View.OnClick
                             }
                             }
 
 
                             mCollectResultTextView.setText(barcodeResult);
                             mCollectResultTextView.setText(barcodeResult);
+                            mCollectResultTextView.setTextColor(getResources().getColor(R.color.green));
 
 
 
 
                             mBarcodeTableLayout.setVisibility(View.GONE);
                             mBarcodeTableLayout.setVisibility(View.GONE);
@@ -895,6 +900,7 @@ public class IOCOutMakeMaterialOper extends BaseFragment implements View.OnClick
                             }
                             }
 
 
                             mCollectResultTextView.setText(boxResult);
                             mCollectResultTextView.setText(boxResult);
+                            mCollectResultTextView.setTextColor(getResources().getColor(R.color.green));
 
 
 
 
                             mBarcodeTableLayout.setVisibility(View.GONE);
                             mBarcodeTableLayout.setVisibility(View.GONE);
@@ -928,7 +934,8 @@ public class IOCOutMakeMaterialOper extends BaseFragment implements View.OnClick
                             MaterialInformationBean.DataBean materialInformationBean = JsonTools.parseJsonToBean(nextObject.toString(), MaterialInformationBean.DataBean.class);
                             MaterialInformationBean.DataBean materialInformationBean = JsonTools.parseJsonToBean(nextObject.toString(), MaterialInformationBean.DataBean.class);
                             if (materialInformationBean != null) {
                             if (materialInformationBean != null) {
                                 String materialInfo =
                                 String materialInfo =
-                                        "物料:" + (materialInformationBean.getPD_PRODCODE() == null ? "" : materialInformationBean.getPD_PRODCODE())
+                                        "型号:" + (materialInformationBean.getPR_ORISPECCODE() == null ? "" : materialInformationBean.getPR_ORISPECCODE())
+                                                + "物料:" + (materialInformationBean.getPD_PRODCODE() == null ? "" : materialInformationBean.getPD_PRODCODE())
                                                 + "; 名称规格:" + (materialInformationBean.getPR_DETAIL() == null ? "" : materialInformationBean.getPR_DETAIL())
                                                 + "; 名称规格:" + (materialInformationBean.getPR_DETAIL() == null ? "" : materialInformationBean.getPR_DETAIL())
                                                 + "  " + (materialInformationBean.getPR_SPEC() == null ? "" : materialInformationBean.getPR_SPEC())
                                                 + "  " + (materialInformationBean.getPR_SPEC() == null ? "" : materialInformationBean.getPR_SPEC())
                                                 + "; 未备料数:" + (materialInformationBean.getPD_RESTQTY() == null ? "" : materialInformationBean.getPD_RESTQTY())
                                                 + "; 未备料数:" + (materialInformationBean.getPD_RESTQTY() == null ? "" : materialInformationBean.getPD_RESTQTY())
@@ -957,6 +964,7 @@ public class IOCOutMakeMaterialOper extends BaseFragment implements View.OnClick
                     CommonUtil.editTextGetFocus(etBarCode);
                     CommonUtil.editTextGetFocus(etBarCode);
                     String errorToast = CommonUtil.showErrorToast(volleyError, true);
                     String errorToast = CommonUtil.showErrorToast(volleyError, true);
                     mCollectResultTextView.setVisibility(View.VISIBLE);
                     mCollectResultTextView.setVisibility(View.VISIBLE);
+                    mCollectResultTextView.setTextColor(getResources().getColor(R.color.red));
                     mCollectResultTextView.setText(errorToast);
                     mCollectResultTextView.setText(errorToast);
                 }
                 }
 
 
@@ -1578,6 +1586,7 @@ public class IOCOutMakeMaterialOper extends BaseFragment implements View.OnClick
                         }
                         }
                     } else {
                     } else {
                         mCollectResultTextView.setVisibility(View.VISIBLE);
                         mCollectResultTextView.setVisibility(View.VISIBLE);
+                        mCollectResultTextView.setTextColor(getResources().getColor(R.color.green));
                         mCollectResultTextView.setText(null);
                         mCollectResultTextView.setText(null);
                         JSONArray listArray = dataObject.optJSONArray("nolist");
                         JSONArray listArray = dataObject.optJSONArray("nolist");
                         if (mCollectType.equals("byBarcode") || mCollectType.equals("byBatchcode")) {
                         if (mCollectType.equals("byBarcode") || mCollectType.equals("byBatchcode")) {
@@ -1604,6 +1613,7 @@ public class IOCOutMakeMaterialOper extends BaseFragment implements View.OnClick
                             }
                             }
 
 
                             mCollectResultTextView.setText(barcodeResult);
                             mCollectResultTextView.setText(barcodeResult);
+                            mCollectResultTextView.setTextColor(getResources().getColor(R.color.green));
 
 
 
 
                             mBarcodeTableLayout.setVisibility(View.GONE);
                             mBarcodeTableLayout.setVisibility(View.GONE);
@@ -1646,6 +1656,7 @@ public class IOCOutMakeMaterialOper extends BaseFragment implements View.OnClick
                             }
                             }
 
 
                             mCollectResultTextView.setText(boxResult);
                             mCollectResultTextView.setText(boxResult);
+                            mCollectResultTextView.setTextColor(getResources().getColor(R.color.green));
 
 
 
 
                             mBarcodeTableLayout.setVisibility(View.GONE);
                             mBarcodeTableLayout.setVisibility(View.GONE);
@@ -1679,7 +1690,8 @@ public class IOCOutMakeMaterialOper extends BaseFragment implements View.OnClick
                             MaterialInformationBean.DataBean materialInformationBean = JsonTools.parseJsonToBean(nextObject.toString(), MaterialInformationBean.DataBean.class);
                             MaterialInformationBean.DataBean materialInformationBean = JsonTools.parseJsonToBean(nextObject.toString(), MaterialInformationBean.DataBean.class);
                             if (materialInformationBean != null) {
                             if (materialInformationBean != null) {
                                 String materialInfo =
                                 String materialInfo =
-                                        "物料:" + (materialInformationBean.getPD_PRODCODE() == null ? "" : materialInformationBean.getPD_PRODCODE())
+                                        "型号:" + (materialInformationBean.getPR_ORISPECCODE() == null ? "" : materialInformationBean.getPR_ORISPECCODE())
+                                                + "物料:" + (materialInformationBean.getPD_PRODCODE() == null ? "" : materialInformationBean.getPD_PRODCODE())
                                                 + "; 名称规格:" + (materialInformationBean.getPR_DETAIL() == null ? "" : materialInformationBean.getPR_DETAIL())
                                                 + "; 名称规格:" + (materialInformationBean.getPR_DETAIL() == null ? "" : materialInformationBean.getPR_DETAIL())
                                                 + "  " + (materialInformationBean.getPR_SPEC() == null ? "" : materialInformationBean.getPR_SPEC())
                                                 + "  " + (materialInformationBean.getPR_SPEC() == null ? "" : materialInformationBean.getPR_SPEC())
                                                 + "; 未备料数:" + (materialInformationBean.getPD_RESTQTY() == null ? "" : materialInformationBean.getPD_RESTQTY())
                                                 + "; 未备料数:" + (materialInformationBean.getPD_RESTQTY() == null ? "" : materialInformationBean.getPD_RESTQTY())

+ 1 - 0
app/src/main/java/com/uas/pda_smart_com/fragment/MaterialOutStockTaskMultipleFragment.java

@@ -205,6 +205,7 @@ public class MaterialOutStockTaskMultipleFragment extends BaseFragment {
                                     if (dataObject != null) {
                                     if (dataObject != null) {
                                         StockTaskMultipleBean stockTaskItemBean = new StockTaskMultipleBean();
                                         StockTaskMultipleBean stockTaskItemBean = new StockTaskMultipleBean();
 
 
+                                        stockTaskItemBean.setPR_ORISPECCODE(JsonUtils.optStringNotNull(dataObject, "PR_ORISPECCODE"));
                                         stockTaskItemBean.setPD_PRODCODE(JsonUtils.optStringNotNull(dataObject, "PD_PRODCODE"));
                                         stockTaskItemBean.setPD_PRODCODE(JsonUtils.optStringNotNull(dataObject, "PD_PRODCODE"));
                                         stockTaskItemBean.setPR_DETAIL(JsonUtils.optStringNotNull(dataObject, "PR_DETAIL"));
                                         stockTaskItemBean.setPR_DETAIL(JsonUtils.optStringNotNull(dataObject, "PR_DETAIL"));
                                         stockTaskItemBean.setPR_SPEC(JsonUtils.optStringNotNull(dataObject, "PR_SPEC"));
                                         stockTaskItemBean.setPR_SPEC(JsonUtils.optStringNotNull(dataObject, "PR_SPEC"));

+ 8 - 0
app/src/main/res/layout/item_list_stock_task_multiple.xml

@@ -14,6 +14,14 @@
         android:orientation="vertical"
         android:orientation="vertical"
         android:padding="@dimen/spacing_big">
         android:padding="@dimen/spacing_big">
 
 
+        <TextView
+            android:id="@+id/stock_task_multiple_orispeccode"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:textColor="@color/text_blue"
+            android:textStyle="bold"
+            tools:text="PR_ORISPECCODE" />
+
         <TextView
         <TextView
             android:id="@+id/stock_task_multiple_prodcode"
             android:id="@+id/stock_task_multiple_prodcode"
             android:layout_width="wrap_content"
             android:layout_width="wrap_content"